input.css 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. @tailwind base;
  2. @tailwind components;
  3. @tailwind utilities;
  4. @layer base {
  5. /* Hide native spinner buttons on every number input app-wide. The
  6. team prefers keyboard typing over the tiny, inconsistent UA
  7. controls. */
  8. input[type="number"]::-webkit-outer-spin-button,
  9. input[type="number"]::-webkit-inner-spin-button {
  10. -webkit-appearance: none;
  11. margin: 0;
  12. }
  13. input[type="number"] {
  14. -moz-appearance: textfield;
  15. appearance: textfield;
  16. }
  17. }
  18. @layer utilities {
  19. /* Phase 13: the Focus filter temporarily hides entire sw columns when the
  20. focused worker has no assignment on any visible row. Separate from the
  21. .hidden set driven by the Columns dropdown so clearing Focus restores
  22. the user's manual column picks. */
  23. .focus-auto-hidden {
  24. display: none;
  25. }
  26. }
  27. @layer components {
  28. /* Phase 15: big-screen / beamer presentation scope. Applied via
  29. views/sprints/present.php on the root <main>. Tightens typography
  30. and cell padding so the task table fits the viewport without
  31. horizontal scroll at 1920×1080; hides drag handles and per-row
  32. delete buttons (not meaningful during a group discussion). */
  33. .beamer-root table {
  34. table-layout: fixed;
  35. font-size: clamp(0.75rem, 0.95vw, 1.05rem);
  36. }
  37. .beamer-root td,
  38. .beamer-root th {
  39. padding: 0.25rem 0.35rem;
  40. }
  41. .beamer-root .handle,
  42. .beamer-root [data-delete-task] {
  43. display: none;
  44. }
  45. /* JS-driven toggle (sprint-planner.js): when the rendered task table
  46. is wider than the viewport, rotate worker-column headers to save
  47. horizontal space. Leaves non-worker headers (Task / Owner / Prio
  48. / Tot) untouched. */
  49. .beamer-vertical-headers thead th[data-sort-col^="sw-"] {
  50. writing-mode: vertical-rl;
  51. transform: rotate(180deg);
  52. padding: 0.5rem 0.25rem;
  53. }
  54. /* Phase 18: per-cell task-assignment status. Each <td> holding a
  55. day input also wraps it in a .assign-cell with an
  56. .assign-status-* color class. The class is on the wrapper so
  57. both the day input/span and the chevron-only <select> share
  58. the tint. The selector itself shows only its native arrow —
  59. no text, no width — so it sits as a tiny chevron next to the
  60. day field. */
  61. .assign-cell {
  62. display: inline-flex;
  63. align-items: center;
  64. gap: 1px;
  65. padding: 1px;
  66. border-radius: 0.25rem;
  67. line-height: 1;
  68. }
  69. .assign-status-zugewiesen { background-color: transparent; }
  70. .assign-status-gestartet { background-color: theme('colors.yellow.200'); }
  71. .assign-status-abgeschlossen { background-color: theme('colors.green.200'); }
  72. .assign-status-abgebrochen { background-color: theme('colors.red.200'); }
  73. .dark .assign-status-gestartet { background-color: theme('colors.yellow.700'); }
  74. .dark .assign-status-abgeschlossen { background-color: theme('colors.green.700'); }
  75. .dark .assign-status-abgebrochen { background-color: theme('colors.red.700'); }
  76. /* Inputs/spans inside a coloured cell get a transparent background
  77. so the wrapper tint shows through; the day input keeps its own
  78. focus ring. */
  79. .assign-cell:not(.assign-status-zugewiesen) input[data-assign],
  80. .assign-cell:not(.assign-status-zugewiesen) > .font-mono {
  81. background-color: transparent;
  82. }
  83. .assign-status-select {
  84. /* Strip the native <select> body — keep only the dropdown
  85. chevron. We hide the text by sizing the box to zero width
  86. plus padding for the arrow, and rely on each browser's
  87. default arrow rendering. */
  88. width: 1.1rem;
  89. min-width: 0;
  90. padding: 0;
  91. margin: 0;
  92. border: 0;
  93. background-color: transparent;
  94. font-size: 0; /* hide selected option text */
  95. line-height: 1;
  96. color: transparent; /* fallback if font-size:0 fails */
  97. cursor: pointer;
  98. }
  99. .assign-status-select:focus {
  100. outline: 2px solid theme('colors.slate.400');
  101. outline-offset: 1px;
  102. border-radius: 2px;
  103. }
  104. .assign-status-select option {
  105. font-size: 0.875rem;
  106. color: theme('colors.slate.900');
  107. }
  108. .dark .assign-status-select option {
  109. color: theme('colors.slate.100');
  110. background-color: theme('colors.slate.800');
  111. }
  112. }