@shohojdhara/atomix 0.6.1 → 0.6.3

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 (67) hide show
  1. package/README.md +510 -106
  2. package/dist/atomix.css +30 -24
  3. package/dist/atomix.css.map +1 -1
  4. package/dist/atomix.min.css +6 -6
  5. package/dist/atomix.min.css.map +1 -1
  6. package/dist/atomix.umd.js +1 -1
  7. package/dist/atomix.umd.js.map +1 -1
  8. package/dist/atomix.umd.min.js +1 -1
  9. package/dist/charts.d.ts +11 -2
  10. package/dist/charts.js +294 -139
  11. package/dist/charts.js.map +1 -1
  12. package/dist/core.d.ts +14 -39
  13. package/dist/core.js +297 -145
  14. package/dist/core.js.map +1 -1
  15. package/dist/forms.d.ts +11 -1
  16. package/dist/forms.js +385 -185
  17. package/dist/forms.js.map +1 -1
  18. package/dist/heavy.d.ts +9 -0
  19. package/dist/heavy.js +297 -143
  20. package/dist/heavy.js.map +1 -1
  21. package/dist/index.d.ts +156 -164
  22. package/dist/index.esm.js +391 -203
  23. package/dist/index.esm.js.map +1 -1
  24. package/dist/index.js +391 -203
  25. package/dist/index.js.map +1 -1
  26. package/dist/index.min.js +1 -1
  27. package/dist/index.min.js.map +1 -1
  28. package/dist/theme.d.ts +14 -6
  29. package/dist/theme.js +2 -9
  30. package/dist/theme.js.map +1 -1
  31. package/package.json +26 -26
  32. package/src/components/AtomixGlass/AtomixGlass.tsx +1 -1
  33. package/src/components/AtomixGlass/AtomixGlassContainer.tsx +8 -1
  34. package/src/components/AtomixGlass/deprecated/AtomixGlass.deprecated.tsx +390 -0
  35. package/src/components/AtomixGlass/glass-utils.ts +29 -0
  36. package/src/components/AtomixGlass/stories/Playground.stories.tsx +32 -1
  37. package/src/components/Button/Button.stories.tsx +1 -1
  38. package/src/components/Button/Button.tsx +6 -5
  39. package/src/components/Card/Card.tsx +2 -2
  40. package/src/components/Dropdown/Dropdown.tsx +1 -0
  41. package/src/components/EdgePanel/EdgePanel.tsx +1 -3
  42. package/src/components/Form/Select.test.tsx +75 -0
  43. package/src/components/Form/Select.tsx +348 -252
  44. package/src/components/Form/SelectOption.tsx +16 -10
  45. package/src/components/index.ts +1 -1
  46. package/src/layouts/CssGrid/index.ts +1 -0
  47. package/src/lib/composables/shared-mouse-tracker.ts +62 -6
  48. package/src/lib/composables/useAtomixGlass.ts +241 -139
  49. package/src/lib/composables/useAtomixGlassStyles.ts +201 -149
  50. package/src/lib/constants/components.ts +54 -35
  51. package/src/lib/theme/config/configLoader.ts +1 -1
  52. package/src/lib/theme/test/testTheme.ts +2 -2
  53. package/src/lib/theme/utils/themeUtils.ts +98 -110
  54. package/src/lib/types/components.ts +29 -65
  55. package/src/styles/01-settings/_settings.spacing.scss +6 -1
  56. package/src/styles/03-generic/_generic.reset.scss +1 -1
  57. package/src/styles/06-components/_components.atomix-glass.scss +20 -29
  58. package/src/styles/06-components/_components.data-table.scss +5 -4
  59. package/src/styles/06-components/_components.dynamic-background.scss +9 -8
  60. package/src/styles/06-components/_components.footer.scss +8 -7
  61. package/src/styles/06-components/_components.hero.scss +2 -2
  62. package/src/styles/06-components/_components.messages.scss +16 -16
  63. package/src/styles/06-components/_components.navbar.scss +2 -0
  64. package/src/styles/06-components/_components.select.scss +15 -2
  65. package/src/styles/06-components/_components.upload.scss +3 -3
  66. package/CHANGELOG.md +0 -165
  67. package/src/lib/theme/devtools/DesignTokensCustomizer.stories.tsx +0 -215
package/dist/theme.d.ts CHANGED
@@ -1176,6 +1176,20 @@ declare function applyComponentTheme(component: string, style?: React.CSSPropert
1176
1176
  */
1177
1177
  declare function useComponentTheme(component: string, variant?: string, size?: string, tokens?: Partial<DesignTokens>): (property: string) => string;
1178
1178
 
1179
+ /**
1180
+ * Theme Manager Utility Functions
1181
+ *
1182
+ * Helper functions for theme operations including CSS loading, DOM manipulation,
1183
+ * and theme validation.
1184
+ */
1185
+
1186
+ /**
1187
+ * Detect system theme preference
1188
+ *
1189
+ * @returns 'dark' if system prefers dark mode, 'light' otherwise
1190
+ */
1191
+ declare const getSystemTheme: () => "light" | "dark";
1192
+
1179
1193
  /**
1180
1194
  * Theme Utilities
1181
1195
  *
@@ -1245,12 +1259,6 @@ declare function toggleTheme(options?: ThemeSwitcherOptions): ThemeMode;
1245
1259
  * @returns Current theme mode or 'light' if not set
1246
1260
  */
1247
1261
  declare function getCurrentTheme(storageKey?: string): ThemeMode;
1248
- /**
1249
- * Get system theme preference
1250
- *
1251
- * @returns 'dark' if system prefers dark mode, 'light' otherwise
1252
- */
1253
- declare function getSystemTheme(): ThemeMode;
1254
1262
  /**
1255
1263
  * Initialize theme based on saved preference or system preference
1256
1264
  *
package/dist/theme.js CHANGED
@@ -1671,7 +1671,7 @@ class ThemeLogger {
1671
1671
  document.body && document.body.setAttribute(dataAttribute, themeName),
1672
1672
  // Also set on documentElement for broader compatibility
1673
1673
  document.documentElement.setAttribute(dataAttribute, themeName));
1674
- }, isValidThemeName = themeName => !(!themeName || "string" != typeof themeName) && /^[a-z0-9]+(-[a-z0-9]+)*$/.test(themeName), createLocalStorageAdapter = () => ({
1674
+ }, getSystemTheme = () => isServer() ? "light" : window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light", isValidThemeName = themeName => !(!themeName || "string" != typeof themeName) && /^[a-z0-9]+(-[a-z0-9]+)*$/.test(themeName), createLocalStorageAdapter = () => ({
1675
1675
  getItem: key => {
1676
1676
  if (isServer()) return null;
1677
1677
  try {
@@ -1708,6 +1708,7 @@ class ThemeLogger {
1708
1708
  applyThemeAttributes: applyThemeAttributes,
1709
1709
  buildThemePath: buildThemePath,
1710
1710
  createLocalStorageAdapter: createLocalStorageAdapter,
1711
+ getSystemTheme: getSystemTheme,
1711
1712
  isBrowser: isBrowser,
1712
1713
  isServer: isServer,
1713
1714
  isValidThemeName: isValidThemeName,
@@ -1870,14 +1871,6 @@ const _reduceInstanceProperty = getDefaultExportFromCjs((function(it) {
1870
1871
  return "undefined" == typeof window ? "light" : localStorage.getItem(storageKey) || "light";
1871
1872
  }
1872
1873
 
1873
- /**
1874
- * Get system theme preference
1875
- *
1876
- * @returns 'dark' if system prefers dark mode, 'light' otherwise
1877
- */ function getSystemTheme() {
1878
- return "undefined" == typeof window ? "light" : window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
1879
- }
1880
-
1881
1874
  /**
1882
1875
  * Initialize theme based on saved preference or system preference
1883
1876
  *