Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.
 
 
 
 
 

236 řádky
6.1 KiB

  1. @use '../atoms/variables' as *;
  2. @use '../atoms/mixins' as *;
  3. // ─── CRUD Seiten Layout ────────────────────────────────────────────────────────
  4. .crud-page {
  5. max-width: $content-max-width;
  6. margin: 0 auto;
  7. padding: $space-6;
  8. @include tablet { padding: $space-4; }
  9. }
  10. .crud-page__header {
  11. display: flex;
  12. align-items: center;
  13. justify-content: space-between;
  14. margin-bottom: $space-6;
  15. }
  16. .crud-page__title {
  17. font-size: $font-size-xl;
  18. font-weight: $font-weight-bold;
  19. color: $color-text-dark;
  20. }
  21. // ─── Liste ─────────────────────────────────────────────────────────────────────
  22. .crud-list {
  23. @include card;
  24. overflow: hidden;
  25. }
  26. // ─── Zeile ─────────────────────────────────────────────────────────────────────
  27. .crud-row {
  28. border-bottom: 1px solid rgba($color-border, 0.5);
  29. transition: opacity 0.28s ease, transform 0.28s ease;
  30. &:last-child { border-bottom: none; }
  31. &--removing {
  32. opacity: 0;
  33. transform: translateX(12px);
  34. }
  35. &--new {
  36. opacity: 0;
  37. transform: translateY(-4px);
  38. }
  39. }
  40. .crud-row__display {
  41. display: flex;
  42. align-items: center;
  43. gap: $space-4;
  44. padding: $space-4 $space-6;
  45. transition: background $transition-fast;
  46. @include tablet { padding: $space-4; }
  47. &:hover {
  48. background: rgba(var(--color-primary-rgb), 0.05);
  49. .crud-row__btn { opacity: 1; }
  50. }
  51. }
  52. .crud-row__info {
  53. flex: 1;
  54. min-width: 0;
  55. }
  56. .crud-row__name {
  57. font-size: $font-size-base;
  58. font-weight: $font-weight-bold;
  59. color: $color-text-dark;
  60. }
  61. .crud-row__meta {
  62. font-size: $font-size-sm;
  63. color: $color-text-muted;
  64. margin-left: $space-2;
  65. font-weight: $font-weight-regular;
  66. }
  67. .crud-row__actions {
  68. display: flex;
  69. align-items: center;
  70. gap: $space-2;
  71. flex-shrink: 0;
  72. }
  73. .crud-row__btn {
  74. @include icon-btn;
  75. opacity: 0;
  76. color: $color-text-muted;
  77. svg { width: $icon-svg-size; height: $icon-svg-size; }
  78. &--edit:hover { background: rgba(var(--color-primary-rgb), 0.1); color: var(--color-primary); }
  79. &--delete:hover{ background: rgba($color-error, 0.1); color: $color-error; }
  80. @media (hover: none) { opacity: 1; }
  81. @include tablet { opacity: 1; }
  82. }
  83. // ─── Edit-Formular innerhalb der Zeile ─────────────────────────────────────────
  84. .crud-row__edit {
  85. padding: $space-4 $space-6;
  86. background: rgba(var(--color-primary-rgb), 0.04);
  87. border-top: 1px solid rgba($color-border, 0.5);
  88. @include tablet { padding: $space-4; }
  89. }
  90. // ─── Create-Formular oben ──────────────────────────────────────────────────────
  91. .crud-create {
  92. @include card($color-card);
  93. padding: $space-5 $space-6;
  94. margin-bottom: $space-4;
  95. display: none;
  96. &--visible { display: block; }
  97. @include tablet { padding: $space-4; }
  98. }
  99. // ─── Tabs (Aktiv / Archiviert) ─────────────────────────────────────────────────
  100. .crud-tabs {
  101. display: inline-flex;
  102. @include card;
  103. border-radius: $radius-pill;
  104. padding: 3px;
  105. margin-bottom: $space-4;
  106. }
  107. .crud-tab {
  108. padding: $space-1 $space-5;
  109. border: none;
  110. background: transparent;
  111. border-radius: $radius-pill;
  112. font-family: $font-family-base;
  113. font-size: $font-size-sm;
  114. font-weight: $font-weight-medium;
  115. color: $color-text-muted;
  116. cursor: pointer;
  117. transition: background $transition-fast, color $transition-fast;
  118. &:hover { color: $color-text-dark; }
  119. &--active {
  120. background: var(--color-primary);
  121. color: var(--header-text);
  122. }
  123. }
  124. // ─── Archivierte Zeile ─────────────────────────────────────────────────────────
  125. .crud-row--archived {
  126. .crud-row__name {
  127. color: $color-text-muted;
  128. text-decoration: line-through;
  129. text-decoration-color: rgba($color-text-muted, 0.5);
  130. }
  131. }
  132. .crud-row__btn--restore {
  133. &:hover { background: rgba($color-activate-light, 0.12); color: $color-activate; }
  134. }
  135. // ─── Gruppen-Header (z.B. Verrechenbar / Nicht-verrechenbar) ──────────────────
  136. .crud-list__group {
  137. & + & {
  138. border-top: 2px solid $color-border;
  139. }
  140. }
  141. .crud-list__group-label {
  142. padding: $space-3 $space-6;
  143. font-size: $font-size-xs;
  144. font-weight: $font-weight-bold;
  145. color: $color-text-muted;
  146. text-transform: uppercase;
  147. letter-spacing: 0.06em;
  148. background: rgba(var(--color-primary-rgb), 0.03);
  149. border-bottom: 1px solid rgba($color-border, 0.5);
  150. }
  151. // ─── Lexoffice ────────────────────────────────────────────────────────────────
  152. .lexoffice-select-wrap {
  153. position: relative;
  154. display: flex;
  155. align-items: flex-start;
  156. gap: $space-2;
  157. width: 100%;
  158. > :first-child {
  159. flex: 1;
  160. min-width: 0;
  161. }
  162. }
  163. .lexoffice-reload {
  164. @include icon-btn;
  165. flex-shrink: 0;
  166. color: $color-text-muted;
  167. margin-top: 2px;
  168. svg { width: $icon-svg-size; height: $icon-svg-size; }
  169. &:hover {
  170. background: rgba(var(--color-primary-rgb), 0.1);
  171. color: var(--color-primary);
  172. }
  173. &:disabled {
  174. opacity: 0.4;
  175. pointer-events: none;
  176. }
  177. }
  178. // ─── Checkbox-Label (Verrechenbar-Feld) ────────────────────────────────────────
  179. .crud-checkbox-label {
  180. display: flex;
  181. align-items: center;
  182. gap: $space-2;
  183. cursor: pointer;
  184. font-size: $font-size-base;
  185. color: $color-text-base;
  186. input[type="checkbox"] {
  187. width: 16px;
  188. height: 16px;
  189. cursor: pointer;
  190. flex-shrink: 0;
  191. accent-color: var(--color-primary);
  192. }
  193. }