Files
orderPRO/resources/scss/modules/_sms-templates.scss
Jacek Pyziak 522c94a434 feat(124): sms templates CRUD + order picker
- Nowa tabela sms_templates (name + body + is_active) + minimalny CRUD.
- /settings/sms-templates: lista + formularz z paleta zmiennych (pill chips).
- Wydzielono Sms\SmsVariableResolver ze wspolna logika placeholderow;
  Email\VariableResolver staje sie cienka fasada — EmailSendingService bez zmian.
- Dropdown "Wybierz szablon" w zakladce SMS na /orders/{id} z fetch
  GET /orders/{id}/sms/template + OrderProAlerts.confirm przy nadpisaniu.
- Stopka SMSPLANET dalej doklejana wylacznie przez SmsConversationService
  (Phase 122 contract preserved).
- Sidebar Ustawien: nowy link "Szablony SMS".

Migration: 20260512_000112_create_sms_templates.sql (CREATE TABLE).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 21:37:51 +02:00

138 lines
2.1 KiB
SCSS

.sms-template-active-field {
display: flex;
align-items: flex-end;
gap: 8px;
}
.sms-template-active-label {
display: flex;
align-items: center;
gap: 6px;
}
.sms-template-active-text {
margin: 0;
}
.sms-template-counter {
font-size: 12px;
}
.sms-template-counter-warning {
color: #b45309;
margin-left: 8px;
}
.sms-template-actions {
white-space: nowrap;
display: flex;
flex-wrap: nowrap;
gap: 6px;
align-items: center;
}
.sms-template-actions > form {
display: inline-flex;
margin: 0;
}
.sms-var-panel {
border: 1px solid #e5e7eb;
border-radius: 8px;
background: #f9fafb;
padding: 12px 14px;
}
.sms-var-panel__head {
display: flex;
align-items: baseline;
justify-content: space-between;
gap: 12px;
margin-bottom: 8px;
}
.sms-var-panel__title {
font-size: 12px;
text-transform: uppercase;
letter-spacing: 0.04em;
color: #374151;
font-weight: 600;
margin: 0;
}
.sms-var-panel__hint {
font-size: 12px;
}
.sms-var-group {
padding: 8px 0;
border-top: 1px dashed #e5e7eb;
}
.sms-var-group:first-of-type {
border-top: 0;
padding-top: 0;
}
.sms-var-group__label {
font-size: 11px;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.04em;
color: #6b7280;
margin-bottom: 6px;
}
.sms-var-group__items {
display: flex;
flex-wrap: wrap;
gap: 6px;
}
.sms-var-item {
display: inline-flex;
align-items: center;
gap: 6px;
font-family: inherit;
font-size: 12px;
background: #fff;
border: 1px solid #d1d5db;
border-radius: 999px;
padding: 4px 10px;
cursor: pointer;
color: #1f2937;
line-height: 1.4;
transition: background-color 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}
.sms-var-item code {
font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
font-size: 11px;
color: #4338ca;
background: transparent;
padding: 0;
}
.sms-var-item__desc {
color: #6b7280;
font-size: 11px;
}
.sms-var-item:hover {
background: #eef2ff;
border-color: #6366f1;
color: #1e1b4b;
}
.sms-var-item:hover code {
color: #1e1b4b;
}
.sms-var-item:hover .sms-var-item__desc {
color: #312e81;
}
.order-sms-template-picker {
margin-bottom: 8px;
}