@hadoku/task-ui-components 0.0.0-stage → 4.20.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (169) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +917 -2
  3. package/dist/app-header.css +288 -0
  4. package/dist/bento.css +143 -0
  5. package/dist/button.css +227 -0
  6. package/dist/components/AppHeader.d.ts +61 -0
  7. package/dist/components/AppHeader.d.ts.map +1 -0
  8. package/dist/components/AppHeader.js +23 -0
  9. package/dist/components/AppHeader.js.map +1 -0
  10. package/dist/components/BentoCard.d.ts +23 -0
  11. package/dist/components/BentoCard.d.ts.map +1 -0
  12. package/dist/components/BentoCard.js +49 -0
  13. package/dist/components/BentoCard.js.map +1 -0
  14. package/dist/components/BentoGrid.d.ts +24 -0
  15. package/dist/components/BentoGrid.d.ts.map +1 -0
  16. package/dist/components/BentoGrid.js +22 -0
  17. package/dist/components/BentoGrid.js.map +1 -0
  18. package/dist/components/Button.d.ts +28 -0
  19. package/dist/components/Button.d.ts.map +1 -0
  20. package/dist/components/Button.js +51 -0
  21. package/dist/components/Button.js.map +1 -0
  22. package/dist/components/ConnectedSettings.d.ts +53 -0
  23. package/dist/components/ConnectedSettings.d.ts.map +1 -0
  24. package/dist/components/ConnectedSettings.js +368 -0
  25. package/dist/components/ConnectedSettings.js.map +1 -0
  26. package/dist/components/ConnectedThemePicker.d.ts +52 -0
  27. package/dist/components/ConnectedThemePicker.d.ts.map +1 -0
  28. package/dist/components/ConnectedThemePicker.js +32 -0
  29. package/dist/components/ConnectedThemePicker.js.map +1 -0
  30. package/dist/components/ContextMenu.d.ts +22 -0
  31. package/dist/components/ContextMenu.d.ts.map +1 -0
  32. package/dist/components/ContextMenu.js +23 -0
  33. package/dist/components/ContextMenu.js.map +1 -0
  34. package/dist/components/HadokuThemePicker.d.ts +27 -0
  35. package/dist/components/HadokuThemePicker.d.ts.map +1 -0
  36. package/dist/components/HadokuThemePicker.js +19 -0
  37. package/dist/components/HadokuThemePicker.js.map +1 -0
  38. package/dist/components/LoadingSkeleton.d.ts +14 -0
  39. package/dist/components/LoadingSkeleton.d.ts.map +1 -0
  40. package/dist/components/LoadingSkeleton.js +62 -0
  41. package/dist/components/LoadingSkeleton.js.map +1 -0
  42. package/dist/components/Modal.d.ts +39 -0
  43. package/dist/components/Modal.d.ts.map +1 -0
  44. package/dist/components/Modal.js +106 -0
  45. package/dist/components/Modal.js.map +1 -0
  46. package/dist/components/NumberInput.d.ts +26 -0
  47. package/dist/components/NumberInput.d.ts.map +1 -0
  48. package/dist/components/NumberInput.js +131 -0
  49. package/dist/components/NumberInput.js.map +1 -0
  50. package/dist/components/Select.d.ts +52 -0
  51. package/dist/components/Select.d.ts.map +1 -0
  52. package/dist/components/Select.js +281 -0
  53. package/dist/components/Select.js.map +1 -0
  54. package/dist/components/SettingsModal.d.ts +69 -0
  55. package/dist/components/SettingsModal.d.ts.map +1 -0
  56. package/dist/components/SettingsModal.js +141 -0
  57. package/dist/components/SettingsModal.js.map +1 -0
  58. package/dist/components/ThemeIcons.d.ts +26 -0
  59. package/dist/components/ThemeIcons.d.ts.map +1 -0
  60. package/dist/components/ThemeIcons.js +74 -0
  61. package/dist/components/ThemeIcons.js.map +1 -0
  62. package/dist/components/ThemePicker.d.ts +28 -0
  63. package/dist/components/ThemePicker.d.ts.map +1 -0
  64. package/dist/components/ThemePicker.js +101 -0
  65. package/dist/components/ThemePicker.js.map +1 -0
  66. package/dist/components/Toast.d.ts +13 -0
  67. package/dist/components/Toast.d.ts.map +1 -0
  68. package/dist/components/Toast.js +70 -0
  69. package/dist/components/Toast.js.map +1 -0
  70. package/dist/components/Toaster.d.ts +19 -0
  71. package/dist/components/Toaster.d.ts.map +1 -0
  72. package/dist/components/Toaster.js +19 -0
  73. package/dist/components/Toaster.js.map +1 -0
  74. package/dist/components/Tooltip.d.ts +49 -0
  75. package/dist/components/Tooltip.d.ts.map +1 -0
  76. package/dist/components/Tooltip.js +143 -0
  77. package/dist/components/Tooltip.js.map +1 -0
  78. package/dist/context-menu.css +11 -0
  79. package/dist/controls.css +137 -0
  80. package/dist/hooks/useReducedMotion.d.ts +7 -0
  81. package/dist/hooks/useReducedMotion.d.ts.map +1 -0
  82. package/dist/hooks/useReducedMotion.js +25 -0
  83. package/dist/hooks/useReducedMotion.js.map +1 -0
  84. package/dist/hooks/useToast.d.ts +18 -0
  85. package/dist/hooks/useToast.d.ts.map +1 -0
  86. package/dist/hooks/useToast.js +28 -0
  87. package/dist/hooks/useToast.js.map +1 -0
  88. package/dist/icon-btn.css +64 -0
  89. package/dist/index.d.ts +49 -0
  90. package/dist/index.d.ts.map +1 -0
  91. package/dist/index.js +75 -0
  92. package/dist/index.js.map +1 -0
  93. package/dist/lib/menuPlacement.d.ts +16 -0
  94. package/dist/lib/menuPlacement.d.ts.map +1 -0
  95. package/dist/lib/menuPlacement.js +19 -0
  96. package/dist/lib/menuPlacement.js.map +1 -0
  97. package/dist/lib/selectMenus.d.ts +30 -0
  98. package/dist/lib/selectMenus.d.ts.map +1 -0
  99. package/dist/lib/selectMenus.js +236 -0
  100. package/dist/lib/selectMenus.js.map +1 -0
  101. package/dist/lib/settingsClient.d.ts +144 -0
  102. package/dist/lib/settingsClient.d.ts.map +1 -0
  103. package/dist/lib/settingsClient.js +157 -0
  104. package/dist/lib/settingsClient.js.map +1 -0
  105. package/dist/lib/themeScope.d.ts +19 -0
  106. package/dist/lib/themeScope.d.ts.map +1 -0
  107. package/dist/lib/themeScope.js +10 -0
  108. package/dist/lib/themeScope.js.map +1 -0
  109. package/dist/lib/titleTooltips.d.ts +38 -0
  110. package/dist/lib/titleTooltips.d.ts.map +1 -0
  111. package/dist/lib/titleTooltips.js +166 -0
  112. package/dist/lib/titleTooltips.js.map +1 -0
  113. package/dist/lib/tooltipPlacement.d.ts +14 -0
  114. package/dist/lib/tooltipPlacement.d.ts.map +1 -0
  115. package/dist/lib/tooltipPlacement.js +34 -0
  116. package/dist/lib/tooltipPlacement.js.map +1 -0
  117. package/dist/modal.css +129 -0
  118. package/dist/number-input.css +131 -0
  119. package/dist/scrollbar.css +165 -0
  120. package/dist/select.css +251 -0
  121. package/dist/styles.css +1866 -0
  122. package/dist/task-ui-components.css +1866 -0
  123. package/dist/theme-picker.css +219 -0
  124. package/dist/toaster.css +159 -0
  125. package/dist/tooltip.css +103 -0
  126. package/dist/types/index.d.ts +37 -0
  127. package/dist/types/index.d.ts.map +1 -0
  128. package/package.json +60 -4
  129. package/src/app-header.css +288 -0
  130. package/src/bento.css +143 -0
  131. package/src/button.css +227 -0
  132. package/src/components/AppHeader.tsx +87 -0
  133. package/src/components/BentoCard.tsx +72 -0
  134. package/src/components/BentoGrid.tsx +48 -0
  135. package/src/components/Button.tsx +81 -0
  136. package/src/components/ConnectedSettings.tsx +545 -0
  137. package/src/components/ConnectedThemePicker.tsx +79 -0
  138. package/src/components/ContextMenu.tsx +48 -0
  139. package/src/components/HadokuThemePicker.tsx +39 -0
  140. package/src/components/LoadingSkeleton.tsx +84 -0
  141. package/src/components/Modal.tsx +171 -0
  142. package/src/components/NumberInput.tsx +161 -0
  143. package/src/components/Select.tsx +359 -0
  144. package/src/components/SettingsModal.tsx +235 -0
  145. package/src/components/ThemeIcons.tsx +127 -0
  146. package/src/components/ThemePicker.tsx +149 -0
  147. package/src/components/Toast.tsx +92 -0
  148. package/src/components/Toaster.tsx +43 -0
  149. package/src/components/Tooltip.tsx +212 -0
  150. package/src/context-menu.css +11 -0
  151. package/src/controls.css +137 -0
  152. package/src/hooks/useReducedMotion.ts +36 -0
  153. package/src/hooks/useToast.ts +57 -0
  154. package/src/icon-btn.css +64 -0
  155. package/src/index.ts +153 -0
  156. package/src/lib/menuPlacement.ts +31 -0
  157. package/src/lib/selectMenus.ts +303 -0
  158. package/src/lib/settingsClient.ts +425 -0
  159. package/src/lib/themeScope.ts +23 -0
  160. package/src/lib/titleTooltips.ts +236 -0
  161. package/src/lib/tooltipPlacement.ts +59 -0
  162. package/src/modal.css +129 -0
  163. package/src/number-input.css +131 -0
  164. package/src/scrollbar.css +165 -0
  165. package/src/select.css +251 -0
  166. package/src/theme-picker.css +219 -0
  167. package/src/toaster.css +159 -0
  168. package/src/tooltip.css +103 -0
  169. package/src/types/index.ts +43 -0
@@ -0,0 +1,219 @@
1
+ /**
2
+ * ThemePicker Component Styles
3
+ * Beautiful theme picker with light/dark pill design
4
+ *
5
+ * Required CSS Variables (should be defined by @wolffm/themes):
6
+ * --color-text
7
+ * --color-primary
8
+ * --color-primary-hover
9
+ * --color-primary-bg
10
+ * --color-bg-card
11
+ * --color-text-secondary
12
+ * --hdk-shadow-focus-sm
13
+ * --hdk-shadow-md
14
+ * --hdk-shadow-lg
15
+ * --transition-fast (e.g., 0.15s ease)
16
+ * --hdk-space-sm (e.g., 8px)
17
+ * --hdk-space-md (e.g., 12px)
18
+ * --hdk-space-lg (e.g., 16px)
19
+ * --hdk-text-lg (e.g., 18px)
20
+ * --font-weight-semibold (e.g., 600)
21
+ */
22
+
23
+ @import './icon-btn.css';
24
+
25
+ .theme-picker {
26
+ position: relative;
27
+ }
28
+
29
+ /* Theme toggle button: styled by the shared .app-header__icon-btn
30
+ * (icon-btn.css). `.theme-toggle-btn` stays on the element as a hook only —
31
+ * giving it values again would be the second copy that drifts. */
32
+
33
+ /* Theme picker overlay - covers entire viewport for click-outside detection */
34
+ .theme-picker__overlay {
35
+ position: fixed;
36
+ top: 0;
37
+ left: 0;
38
+ right: 0;
39
+ bottom: 0;
40
+ z-index: 99;
41
+ background: transparent;
42
+ }
43
+
44
+ /* Theme picker dropdown - positioned relative to picker button */
45
+ .theme-picker__dropdown {
46
+ position: absolute;
47
+ top: 0;
48
+ left: calc(100% + var(--hdk-space-md));
49
+ z-index: 100;
50
+ display: flex;
51
+ flex-direction: column;
52
+ align-items: flex-start;
53
+ gap: var(--hdk-space-sm);
54
+ }
55
+
56
+ /* Inner row: pill tower + settings icon side-by-side */
57
+ .theme-picker__main {
58
+ display: flex;
59
+ align-items: flex-start;
60
+ gap: var(--hdk-space-md);
61
+ }
62
+
63
+ /* Open-left modifier: dropdown opens to the left of the toggle */
64
+ .theme-picker--open-left .theme-picker__dropdown {
65
+ left: auto;
66
+ right: calc(100% + var(--hdk-space-md));
67
+ }
68
+
69
+ .theme-picker--open-left .theme-picker__main {
70
+ flex-direction: row-reverse;
71
+ }
72
+
73
+ /* Theme pill tower - has the shadow */
74
+ .theme-picker__pills {
75
+ display: flex;
76
+ flex-direction: column;
77
+ gap: 0; /* No gap - pancake stack */
78
+ border-radius: 12px;
79
+ overflow: hidden;
80
+ box-shadow: var(--hdk-shadow-lg); /* Shadow on pill tower only */
81
+ }
82
+
83
+ /* Theme pill - contains light and dark buttons */
84
+ .theme-pill {
85
+ display: flex;
86
+ gap: 0;
87
+ background: transparent;
88
+ border: none;
89
+ transition: all var(--transition-fast, 0.15s ease);
90
+ }
91
+
92
+ /* Separator line between pills */
93
+ .theme-pill:not(:last-child) {
94
+ border-bottom: 1px solid rgba(0, 0, 0, 0.08);
95
+ }
96
+
97
+ /* Theme pill buttons */
98
+ .theme-pill__btn {
99
+ flex: 1;
100
+ display: flex;
101
+ align-items: center;
102
+ justify-content: center;
103
+ padding: calc(var(--hdk-space-lg) * 1.2); /* 20% bigger total (10% + 10%) */
104
+ border: none;
105
+ background: transparent;
106
+ cursor: pointer;
107
+ transition: all var(--transition-fast, 0.15s ease);
108
+ position: relative;
109
+ overflow: visible; /* Allow border to show */
110
+ }
111
+
112
+ /* The light/dark pills are the mode toggle itself: they must always LOOK light
113
+ and dark so the control reads correctly whichever theme is active. These
114
+ literals are deliberate and are the one place theme tokens must not be used. */
115
+
116
+ /* Light button default style */
117
+ .theme-pill__btn--light {
118
+ background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
119
+ color: #1e293b;
120
+ border-right: 1px solid rgba(0, 0, 0, 0.1);
121
+ }
122
+
123
+ /* Dark button default style - more cyber with darker background and blue tint */
124
+ .theme-pill__btn--dark {
125
+ background: linear-gradient(135deg, #0f172a 0%, #020617 100%);
126
+ color: #64748b;
127
+ border-left: 1px solid rgba(100, 116, 139, 0.1);
128
+ }
129
+
130
+ /* First pill top-left corner rounding - rounded corner instead of full circle */
131
+ .theme-pill:first-child .theme-pill__btn--light {
132
+ border-top-left-radius: 12px;
133
+ }
134
+
135
+ /* First pill top-right corner rounding */
136
+ .theme-pill:first-child .theme-pill__btn--dark {
137
+ border-top-right-radius: 12px;
138
+ }
139
+
140
+ /* Last pill bottom-left corner rounding */
141
+ .theme-pill:last-child .theme-pill__btn--light {
142
+ border-bottom-left-radius: 12px;
143
+ }
144
+
145
+ /* Last pill bottom-right corner rounding */
146
+ .theme-pill:last-child .theme-pill__btn--dark {
147
+ border-bottom-right-radius: 12px;
148
+ }
149
+
150
+ .theme-pill__btn--light:hover {
151
+ background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
152
+ color: var(--color-primary);
153
+ }
154
+
155
+ .theme-pill__btn--dark:hover {
156
+ background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
157
+ color: #cbd5e1;
158
+ }
159
+
160
+ /* Active states - with proper border radius that doesn't clip, 10% bigger border */
161
+ .theme-pill__btn--light.active {
162
+ background: linear-gradient(135deg, #ffffff 0%, #f0f9ff 100%);
163
+ color: var(--color-primary);
164
+ box-shadow: inset 0 0 0 2.2px var(--color-primary); /* Uses theme primary color */
165
+ font-weight: var(--font-weight-semibold, 600);
166
+ }
167
+
168
+ .theme-pill__btn--dark.active {
169
+ background: linear-gradient(135deg, #020617 0%, #000000 100%);
170
+ color: var(--color-primary); /* Use theme primary color */
171
+ box-shadow: inset 0 0 0 2.2px var(--color-primary); /* Use theme primary color */
172
+ font-weight: var(--font-weight-semibold, 600);
173
+ /* Add glow effect for cyber look */
174
+ filter: brightness(1.1);
175
+ }
176
+
177
+ /* Icon container - reduced by ~15% (24px -> 20px) */
178
+ .theme-pill__icon {
179
+ display: flex;
180
+ align-items: center;
181
+ justify-content: center;
182
+ width: 20px;
183
+ height: 20px;
184
+ }
185
+
186
+ .theme-pill__icon svg {
187
+ width: 100%;
188
+ height: 100%;
189
+ }
190
+
191
+ /* Settings icon button - circular, separate from pill tower */
192
+ .theme-picker__settings-icon {
193
+ display: flex;
194
+ align-items: center;
195
+ justify-content: center;
196
+ width: 44px;
197
+ height: 44px;
198
+ padding: 0;
199
+ border: none;
200
+ background: var(--color-bg-card);
201
+ color: var(--color-text-secondary);
202
+ cursor: pointer;
203
+ transition: all var(--transition-fast, 0.15s ease);
204
+ border-radius: 50%; /* Circular */
205
+ box-shadow: var(--hdk-shadow-md);
206
+ flex-shrink: 0;
207
+ }
208
+
209
+ .theme-picker__settings-icon:hover {
210
+ background: var(--color-primary-bg);
211
+ color: var(--color-on-primary-bg);
212
+ transform: rotate(45deg);
213
+ box-shadow: var(--hdk-shadow-lg);
214
+ }
215
+
216
+ .theme-picker__settings-icon svg {
217
+ width: 20px;
218
+ height: 20px;
219
+ }
@@ -0,0 +1,159 @@
1
+ /**
2
+ * Toast Notification Styles
3
+ */
4
+
5
+ .toast-container {
6
+ position: fixed;
7
+ z-index: 10000;
8
+ display: flex;
9
+ gap: 12px;
10
+ pointer-events: none;
11
+ max-width: 500px;
12
+ }
13
+
14
+ /* Position variants */
15
+ .toast-container--top-left {
16
+ top: 20px;
17
+ left: 20px;
18
+ flex-direction: column;
19
+ }
20
+
21
+ .toast-container--top-center {
22
+ top: 20px;
23
+ left: 50%;
24
+ transform: translateX(-50%);
25
+ flex-direction: column;
26
+ width: calc(100% - 40px);
27
+ }
28
+
29
+ .toast-container--top-right {
30
+ top: 20px;
31
+ right: 20px;
32
+ flex-direction: column;
33
+ }
34
+
35
+ .toast-container--bottom-left {
36
+ bottom: 20px;
37
+ left: 20px;
38
+ flex-direction: column-reverse;
39
+ }
40
+
41
+ .toast-container--bottom-center {
42
+ bottom: 20px;
43
+ left: 50%;
44
+ transform: translateX(-50%);
45
+ flex-direction: column-reverse;
46
+ width: calc(100% - 40px);
47
+ }
48
+
49
+ .toast-container--bottom-right {
50
+ bottom: 20px;
51
+ right: 20px;
52
+ flex-direction: column-reverse;
53
+ }
54
+
55
+ .toast {
56
+ display: flex;
57
+ align-items: center;
58
+ gap: 12px;
59
+ padding: 14px 20px;
60
+ background: var(--color-bg-card);
61
+ border: 1px solid var(--color-border-light);
62
+ border-radius: var(--hdk-radius-lg);
63
+ box-shadow: var(--hdk-shadow-md);
64
+ min-width: 280px;
65
+ max-width: 100%;
66
+ opacity: 0;
67
+ transform: translateY(30px) scale(0.9);
68
+ transition:
69
+ opacity 0.5s ease-out,
70
+ transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1),
71
+ box-shadow 0.3s ease;
72
+ pointer-events: auto;
73
+ }
74
+
75
+ .toast--visible {
76
+ opacity: 1;
77
+ transform: translateY(0) scale(1);
78
+ }
79
+
80
+ .toast__icon {
81
+ flex-shrink: 0;
82
+ }
83
+
84
+ .toast__message {
85
+ flex: 1;
86
+ font-size: 14px;
87
+ color: var(--color-text);
88
+ line-height: 1.4;
89
+ }
90
+
91
+ /* Toast type variants - using colored shadows for subtle emphasis */
92
+ .toast--success {
93
+ box-shadow:
94
+ 0 0 0 1px var(--success-color, #10b981),
95
+ 0 4px 12px rgba(16, 185, 129, 0.15),
96
+ 0 2px 4px rgba(0, 0, 0, 0.1);
97
+ }
98
+
99
+ .toast--success .toast__icon {
100
+ color: var(--success-color, #10b981);
101
+ }
102
+
103
+ .toast--error {
104
+ box-shadow:
105
+ 0 0 0 1px var(--error-color, #ef4444),
106
+ 0 4px 12px rgba(239, 68, 68, 0.15),
107
+ 0 2px 4px rgba(0, 0, 0, 0.1);
108
+ }
109
+
110
+ .toast--error .toast__icon {
111
+ color: var(--error-color, #ef4444);
112
+ }
113
+
114
+ .toast--warning {
115
+ box-shadow:
116
+ 0 0 0 1px var(--warning-color, #f59e0b),
117
+ 0 4px 12px rgba(245, 158, 11, 0.15),
118
+ 0 2px 4px rgba(0, 0, 0, 0.1);
119
+ }
120
+
121
+ .toast--warning .toast__icon {
122
+ color: var(--warning-color, #f59e0b);
123
+ }
124
+
125
+ .toast--info {
126
+ box-shadow:
127
+ 0 0 0 1px var(--info-color, var(--accent-color, #3b82f6)),
128
+ 0 4px 12px rgba(59, 130, 246, 0.15),
129
+ 0 2px 4px rgba(0, 0, 0, 0.1);
130
+ }
131
+
132
+ .toast--info .toast__icon {
133
+ color: var(--info-color, var(--accent-color, #3b82f6));
134
+ }
135
+
136
+ /* Mobile adjustments */
137
+ @media (max-width: 768px) {
138
+ .toast-container {
139
+ max-width: none;
140
+ }
141
+
142
+ .toast-container--top-left,
143
+ .toast-container--top-right,
144
+ .toast-container--bottom-left,
145
+ .toast-container--bottom-right {
146
+ left: 10px;
147
+ right: 10px;
148
+ }
149
+
150
+ .toast-container--top-center,
151
+ .toast-container--bottom-center {
152
+ width: calc(100% - 20px);
153
+ }
154
+
155
+ .toast {
156
+ min-width: unset;
157
+ padding: 12px 16px;
158
+ }
159
+ }
@@ -0,0 +1,103 @@
1
+ /* Tooltip styles for @wolffm/task-ui-components.
2
+ *
3
+ * import '@wolffm/task-ui-components/tooltip.css'
4
+ *
5
+ * `inverse` paints body text colour as the surface and the page background
6
+ * as the text — the same pair as body copy, flipped, so its contrast is the
7
+ * theme's own text contrast in every theme.
8
+ */
9
+
10
+ .hdk-tooltip {
11
+ --_tip-bg: var(--color-text);
12
+ --_tip-fg: var(--color-bg);
13
+ --_tip-border: transparent;
14
+ /* Overwritten inline once placed: where the anchor's centre falls. */
15
+ --hdk-tooltip-arrow: 50%;
16
+
17
+ position: fixed;
18
+ z-index: 1100;
19
+ max-width: min(280px, calc(100vw - 16px));
20
+ padding: 6px 10px;
21
+ font-size: var(--hdk-text-xs);
22
+ font-weight: var(--font-weight-normal);
23
+ line-height: 1.4;
24
+ text-align: left;
25
+ white-space: normal;
26
+ overflow-wrap: break-word;
27
+ color: var(--_tip-fg);
28
+ background-color: var(--_tip-bg);
29
+ border: 1px solid var(--_tip-border);
30
+ border-radius: var(--hdk-radius);
31
+ box-shadow: var(--hdk-shadow-md);
32
+ /* A fade, never a slide: a transform puts the bubble on its own layer, so
33
+ * its 1px border smears across rows mid-slide and visibly snaps back into
34
+ * place when the transition ends. */
35
+ opacity: 0;
36
+ transition: opacity var(--transition-fast);
37
+ }
38
+
39
+ .hdk-tooltip--visible {
40
+ opacity: 1;
41
+ }
42
+
43
+ .hdk-tooltip--card {
44
+ --_tip-bg: var(--color-bg-card);
45
+ --_tip-fg: var(--color-text);
46
+ --_tip-border: var(--color-border);
47
+
48
+ box-shadow: var(--hdk-shadow-lg);
49
+ }
50
+
51
+ /* A `title=` string from installTitleTooltips: plain text, and its line
52
+ * breaks are real (a native title shows them too). */
53
+ .hdk-tooltip--plain {
54
+ white-space: pre-line;
55
+ }
56
+
57
+ .hdk-tooltip--primary {
58
+ --_tip-bg: var(--color-primary);
59
+ --_tip-fg: var(--color-on-primary);
60
+ }
61
+
62
+ /* ── arrow ────────────────────────────────────────────────────────────── */
63
+
64
+ /* A rotated square sharing the bubble's fill and border; only its two outer
65
+ * edges carry the border, so it reads as one shape with the bubble. */
66
+ .hdk-tooltip::after {
67
+ content: '';
68
+ position: absolute;
69
+ width: 8px;
70
+ height: 8px;
71
+ background-color: var(--_tip-bg);
72
+ border: 1px solid var(--_tip-border);
73
+ border-top-color: transparent;
74
+ border-left-color: transparent;
75
+ }
76
+
77
+ .hdk-tooltip--top::after {
78
+ top: 100%;
79
+ left: var(--hdk-tooltip-arrow);
80
+ translate: -50% -50%;
81
+ rotate: 45deg;
82
+ }
83
+
84
+ .hdk-tooltip--bottom::after {
85
+ bottom: 100%;
86
+ left: var(--hdk-tooltip-arrow);
87
+ translate: -50% 50%;
88
+ rotate: -135deg;
89
+ }
90
+
91
+ .hdk-tooltip--left::after {
92
+ left: 100%;
93
+ top: var(--hdk-tooltip-arrow);
94
+ translate: -50% -50%;
95
+ rotate: -45deg;
96
+ }
97
+
98
+ .hdk-tooltip--right::after {
99
+ right: 100%;
100
+ top: var(--hdk-tooltip-arrow);
101
+ translate: 50% -50%;
102
+ rotate: 135deg;
103
+ }
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Type definitions for @wolffm/task-ui-components
3
+ */
4
+ import type { ReactNode } from 'react';
5
+ export type { ThemeName, ThemeFamily, ThemeMode } from '@wolffm/themes';
6
+ import type { ThemeName, ThemeFamily } from '@wolffm/themes';
7
+ /**
8
+ * Dropdown placement direction
9
+ * - 'right': Opens to the right of the toggle button (default)
10
+ * - 'left': Opens to the left of the toggle button
11
+ * - 'auto': Automatically detects edge collisions and flips direction
12
+ */
13
+ export type DropdownPlacement = 'left' | 'right' | 'auto';
14
+ /**
15
+ * Theme picker component props
16
+ */
17
+ export interface ThemePickerProps {
18
+ /** Current active theme */
19
+ currentTheme: ThemeName;
20
+ /** Whether the theme picker dropdown is visible */
21
+ isOpen: boolean;
22
+ /** Available theme families */
23
+ themeFamilies: ThemeFamily[];
24
+ /** Callback when theme is changed */
25
+ onThemeChange: (theme: ThemeName) => void;
26
+ /** Callback to toggle picker visibility */
27
+ onToggle: () => void;
28
+ /** Optional callback when settings icon is clicked */
29
+ onSettingsClick?: () => void;
30
+ /** Optional: Function to get icon for current theme (for toggle button) */
31
+ getThemeIcon?: (theme: ThemeName) => ReactNode;
32
+ /** Optional: CSS class name for the container */
33
+ className?: string;
34
+ /** Optional: Direction the dropdown opens. Defaults to 'auto' (edge detection) */
35
+ dropdownPlacement?: DropdownPlacement;
36
+ }
37
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAKtC,YAAY,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AACvE,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AAE5D;;;;;GAKG;AACH,MAAM,MAAM,iBAAiB,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,CAAA;AAEzD;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,2BAA2B;IAC3B,YAAY,EAAE,SAAS,CAAA;IACvB,mDAAmD;IACnD,MAAM,EAAE,OAAO,CAAA;IACf,+BAA+B;IAC/B,aAAa,EAAE,WAAW,EAAE,CAAA;IAC5B,qCAAqC;IACrC,aAAa,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,IAAI,CAAA;IACzC,2CAA2C;IAC3C,QAAQ,EAAE,MAAM,IAAI,CAAA;IACpB,sDAAsD;IACtD,eAAe,CAAC,EAAE,MAAM,IAAI,CAAA;IAC5B,2EAA2E;IAC3E,YAAY,CAAC,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,SAAS,CAAA;IAC9C,iDAAiD;IACjD,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,kFAAkF;IAClF,iBAAiB,CAAC,EAAE,iBAAiB,CAAA;CACtC"}
package/package.json CHANGED
@@ -1,6 +1,62 @@
1
1
  {
2
2
  "name": "@hadoku/task-ui-components",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "4.20.4",
4
+ "description": "Reusable UI components with Bento grid and metallic gradient support",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "types": "dist/index.d.ts",
8
+ "files": [
9
+ "dist",
10
+ "src",
11
+ "README.md",
12
+ "LICENSE"
13
+ ],
14
+ "exports": {
15
+ ".": {
16
+ "types": "./dist/index.d.ts",
17
+ "import": "./dist/index.js",
18
+ "require": "./dist/index.js"
19
+ },
20
+ "./theme-picker.css": "./dist/theme-picker.css",
21
+ "./app-header.css": "./dist/app-header.css",
22
+ "./toaster.css": "./dist/toaster.css",
23
+ "./context-menu.css": "./dist/context-menu.css",
24
+ "./bento.css": "./dist/bento.css",
25
+ "./modal.css": "./dist/modal.css",
26
+ "./button.css": "./dist/button.css",
27
+ "./select.css": "./dist/select.css",
28
+ "./tooltip.css": "./dist/tooltip.css",
29
+ "./scrollbar.css": "./dist/scrollbar.css",
30
+ "./icon-btn.css": "./dist/icon-btn.css",
31
+ "./controls.css": "./dist/controls.css",
32
+ "./number-input.css": "./dist/number-input.css",
33
+ "./title-tooltips": {
34
+ "types": "./dist/lib/titleTooltips.d.ts",
35
+ "import": "./dist/lib/titleTooltips.js"
36
+ },
37
+ "./select-menus": {
38
+ "types": "./dist/lib/selectMenus.d.ts",
39
+ "import": "./dist/lib/selectMenus.js"
40
+ },
41
+ "./package.json": "./package.json"
42
+ },
43
+ "keywords": [
44
+ "theme-picker",
45
+ "ui-components",
46
+ "react",
47
+ "themes",
48
+ "task-management"
49
+ ],
50
+ "author": "wolffm",
51
+ "license": "MIT",
52
+ "peerDependencies": {
53
+ "@wolffm/themes": "*",
54
+ "react": "^18.0.0 || ^19.0.0",
55
+ "react-dom": "^18.0.0 || ^19.0.0"
56
+ },
57
+ "repository": {
58
+ "type": "git",
59
+ "url": "https://github.com/WolffM/hadoku-task.git",
60
+ "directory": "task-ui-components"
61
+ }
62
+ }