@rufous/ui 0.1.63 → 0.2.0-beta.1

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 (154) hide show
  1. package/README.md +4 -0
  2. package/dist/Buttons/addButton.js +1 -0
  3. package/dist/Buttons/cancelButton.js +1 -0
  4. package/dist/Buttons/index.cjs +2 -2
  5. package/dist/Buttons/index.js +3 -2
  6. package/dist/Buttons/stdButton.js +1 -0
  7. package/dist/Buttons/submitButton.cjs +2 -2
  8. package/dist/Buttons/submitButton.js +3 -2
  9. package/dist/CheckBoxes/CheckBox.cjs +2 -2
  10. package/dist/CheckBoxes/CheckBox.js +4 -25
  11. package/dist/Contexts/rufousThemeProvider.cjs +132 -100
  12. package/dist/Contexts/rufousThemeProvider.js +3 -2
  13. package/dist/DataGrid/DataGrid.cjs +418 -0
  14. package/dist/DataGrid/DataGrid.d.cts +8 -0
  15. package/dist/DataGrid/DataGrid.d.ts +8 -0
  16. package/dist/DataGrid/DataGrid.js +9 -0
  17. package/dist/DataGrid/index.cjs +418 -0
  18. package/dist/DataGrid/index.d.cts +3 -0
  19. package/dist/DataGrid/index.d.ts +3 -0
  20. package/dist/DataGrid/index.js +8 -0
  21. package/dist/{TextFields/FloatingInput.d.cjs → DataGrid/types.cjs} +3 -3
  22. package/dist/DataGrid/types.d.cts +31 -0
  23. package/dist/DataGrid/types.d.ts +31 -0
  24. package/dist/Dialogs/BaseDialog.cjs +18 -10
  25. package/dist/Dialogs/BaseDialog.css +8355 -162
  26. package/dist/Dialogs/BaseDialog.d.cts +1 -0
  27. package/dist/Dialogs/BaseDialog.d.ts +1 -0
  28. package/dist/Dialogs/BaseDialog.js +33 -25
  29. package/dist/Dialogs/index.cjs +18 -10
  30. package/dist/Dialogs/index.css +8355 -162
  31. package/dist/Dialogs/index.js +33 -25
  32. package/dist/Editors/RichTextEditor.cjs +29477 -0
  33. package/dist/Editors/RichTextEditor.css +7179 -0
  34. package/dist/Editors/RichTextEditor.d.cts +57 -0
  35. package/dist/Editors/RichTextEditor.d.ts +57 -0
  36. package/dist/Editors/RichTextEditor.js +9 -0
  37. package/dist/Editors/index.cjs +29477 -0
  38. package/dist/Editors/index.css +7179 -0
  39. package/dist/Editors/index.d.cts +2 -0
  40. package/dist/Editors/index.d.ts +2 -0
  41. package/dist/Editors/index.js +8 -0
  42. package/dist/Progress/circularProgress.cjs +2 -2
  43. package/dist/Progress/circularProgress.d.cts +3 -3
  44. package/dist/Progress/circularProgress.d.ts +3 -3
  45. package/dist/Progress/circularProgress.js +2 -1
  46. package/dist/TextFields/AddressLookup.cjs +390 -0
  47. package/dist/TextFields/AddressLookup.d.cts +49 -0
  48. package/dist/TextFields/AddressLookup.d.ts +49 -0
  49. package/dist/TextFields/AddressLookup.js +11 -0
  50. package/dist/TextFields/FloatingInput.cjs +6 -4
  51. package/dist/TextFields/FloatingInput.d.cts +13 -19
  52. package/dist/TextFields/FloatingInput.d.ts +13 -19
  53. package/dist/TextFields/FloatingInput.js +4 -28
  54. package/dist/{chunk-AQXTOTWY.js → chunk-5DAOQ2V5.js} +19 -11
  55. package/dist/chunk-5QEWUCKT.js +303 -0
  56. package/dist/chunk-66HHM7VI.js +468 -0
  57. package/dist/chunk-7KRG7VNW.js +0 -0
  58. package/dist/{chunk-YRFUVQDN.js → chunk-CTBYVXFP.js} +2 -2
  59. package/dist/chunk-GJGRMMAQ.js +0 -0
  60. package/dist/chunk-HMG3FW2Q.js +97 -0
  61. package/dist/chunk-J6E3UO2W.js +402 -0
  62. package/dist/chunk-LI4N7JWK.js +39 -0
  63. package/dist/chunk-NEGQXBQV.js +29 -0
  64. package/dist/chunk-UPCMMCPQ.js +34 -0
  65. package/dist/{chunk-7YKG3WYS.js → chunk-YRLN3TBF.js} +1 -1
  66. package/dist/chunk-YXPBXCY5.js +89 -0
  67. package/dist/esm-5T53WHPT.js +27362 -0
  68. package/dist/icons/activateUserIcon.js +1 -0
  69. package/dist/icons/archivedIcon.js +1 -0
  70. package/dist/icons/assignGroupIcon.js +1 -0
  71. package/dist/icons/closeIcon.js +1 -0
  72. package/dist/icons/copyIcon.js +1 -0
  73. package/dist/icons/difficultyAllIcon.js +1 -0
  74. package/dist/icons/difficultyEasyIcon.js +1 -0
  75. package/dist/icons/difficultyHardIcon.js +1 -0
  76. package/dist/icons/difficultyMediumIcon.js +1 -0
  77. package/dist/icons/dollarIcon.js +1 -0
  78. package/dist/icons/downloadIcon.js +1 -0
  79. package/dist/icons/downloadPdfIcon.js +1 -0
  80. package/dist/icons/editChatIcon.js +1 -0
  81. package/dist/icons/editIcon.js +1 -0
  82. package/dist/icons/engagementIcon.js +1 -0
  83. package/dist/icons/functionIcon.js +1 -0
  84. package/dist/icons/helpOutlinedIcon.js +1 -0
  85. package/dist/icons/hierarchyIcon.js +1 -0
  86. package/dist/icons/inactiveGroupIcon.js +1 -0
  87. package/dist/icons/index.js +48 -47
  88. package/dist/icons/industryIcon.js +1 -0
  89. package/dist/icons/invoiceIcon.js +1 -0
  90. package/dist/icons/locationPinIcon.js +1 -0
  91. package/dist/icons/logsIcon.js +1 -0
  92. package/dist/icons/minExperienceIcon.js +1 -0
  93. package/dist/icons/nineDotMenuIcon.js +1 -0
  94. package/dist/icons/notificationIcon.js +1 -0
  95. package/dist/icons/projectIcon.js +1 -0
  96. package/dist/icons/qualificationsIcon.js +1 -0
  97. package/dist/icons/questionStatusAllIcon.js +1 -0
  98. package/dist/icons/questionStatusPrivateIcon.js +1 -0
  99. package/dist/icons/questionStatusPublicIcon.js +1 -0
  100. package/dist/icons/questionTypeAllIcon.js +1 -0
  101. package/dist/icons/questionTypeCodingIcon.js +1 -0
  102. package/dist/icons/questionTypeDescriptiveIcon.js +1 -0
  103. package/dist/icons/questionTypeMultipleIcon.js +1 -0
  104. package/dist/icons/questionTypeSingleIcon.js +1 -0
  105. package/dist/icons/refreshIcon.js +1 -0
  106. package/dist/icons/resendInviteIcon.js +1 -0
  107. package/dist/icons/rolesIcon.js +1 -0
  108. package/dist/icons/rufousAiIcon.js +1 -0
  109. package/dist/icons/rufousBirdIcon.js +1 -0
  110. package/dist/icons/rufousLauncherBird.js +1 -0
  111. package/dist/icons/sidebarIcon.js +1 -0
  112. package/dist/icons/softSkillsIcon.js +1 -0
  113. package/dist/icons/subscribeIcon.js +1 -0
  114. package/dist/icons/suspendUserIcon.js +1 -0
  115. package/dist/icons/technicalSkillsIcon.js +1 -0
  116. package/dist/icons/tickIcon.js +1 -0
  117. package/dist/icons/timerIcon.js +1 -0
  118. package/dist/icons/trashIcon.js +1 -0
  119. package/dist/icons/unArchivedIcon.js +1 -0
  120. package/dist/icons/unsubscribeIcon.js +1 -0
  121. package/dist/icons/uploadIcon.js +1 -0
  122. package/dist/icons/userAssignIcon.js +1 -0
  123. package/dist/icons/viewIcon.js +1 -0
  124. package/dist/icons/workItemIcon.js +1 -0
  125. package/dist/main.cjs +30440 -222
  126. package/dist/main.css +8355 -162
  127. package/dist/main.d.cts +7 -0
  128. package/dist/main.d.ts +7 -0
  129. package/dist/main.js +82 -56
  130. package/dist/style.css +1068 -163
  131. package/dist/styles/address-lookup.css +107 -0
  132. package/dist/styles/address-lookup.d.cts +2 -0
  133. package/dist/styles/address-lookup.d.ts +2 -0
  134. package/dist/styles/button.css +82 -110
  135. package/dist/styles/checkbox.css +60 -0
  136. package/dist/styles/checkbox.d.cts +2 -0
  137. package/dist/styles/checkbox.d.ts +2 -0
  138. package/dist/styles/datagrid.css +531 -0
  139. package/dist/styles/datagrid.d.cts +2 -0
  140. package/dist/styles/datagrid.d.ts +2 -0
  141. package/dist/styles/dialog.css +78 -51
  142. package/dist/styles/editor.css +211 -0
  143. package/dist/styles/editor.d.cts +2 -0
  144. package/dist/styles/editor.d.ts +2 -0
  145. package/dist/utils/constants.cjs +75 -69
  146. package/dist/utils/constants.d.cts +54 -56
  147. package/dist/utils/constants.d.ts +54 -56
  148. package/dist/utils/constants.js +2 -1
  149. package/package.json +13 -2
  150. package/dist/TextFields/FloatingInput.d.d.cts +0 -23
  151. package/dist/TextFields/FloatingInput.d.d.ts +0 -23
  152. package/dist/chunk-2FHTGYR4.js +0 -83
  153. package/dist/chunk-BCGCLMKA.js +0 -71
  154. /package/dist/{TextFields/FloatingInput.d.js → DataGrid/types.js} +0 -0
package/README.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # @rufous/ui
2
2
 
3
+ > [!CAUTION]
4
+ > **Stability: Experimental / Beta**
5
+ > This package is currently in early development. Breaking changes, bugs, and API updates are expected. We recommend using it in non-critical environments until a stable `1.0.0` version is released.
6
+
3
7
  A lightweight React UI component library with theming, buttons, inputs, dialogs, progress and a rich icon set.
4
8
 
5
9
  ---
@@ -1,6 +1,7 @@
1
1
  import {
2
2
  addButton_default
3
3
  } from "../chunk-U7SARO5B.js";
4
+ import "../chunk-LI4N7JWK.js";
4
5
  export {
5
6
  addButton_default as default
6
7
  };
@@ -1,6 +1,7 @@
1
1
  import {
2
2
  cancelButton_default
3
3
  } from "../chunk-BMMDUQDJ.js";
4
+ import "../chunk-LI4N7JWK.js";
4
5
  export {
5
6
  cancelButton_default as default
6
7
  };
@@ -48,7 +48,7 @@ var React3 = __toESM(require("react"), 1);
48
48
 
49
49
  // lib/Progress/circularProgress.tsx
50
50
  var React2 = __toESM(require("react"), 1);
51
- var CircularProgess = ({
51
+ var CircularProgress = ({
52
52
  size = 50,
53
53
  color = "#a81c08",
54
54
  ...props
@@ -72,7 +72,7 @@ var CircularProgess = ({
72
72
  ))
73
73
  );
74
74
  };
75
- var circularProgress_default = CircularProgess;
75
+ var circularProgress_default = CircularProgress;
76
76
 
77
77
  // lib/Buttons/submitButton.tsx
78
78
  var SubmitButton = ({
@@ -10,8 +10,9 @@ import {
10
10
  } from "../chunk-R3GARAVJ.js";
11
11
  import {
12
12
  submitButton_default
13
- } from "../chunk-7YKG3WYS.js";
14
- import "../chunk-YRFUVQDN.js";
13
+ } from "../chunk-YRLN3TBF.js";
14
+ import "../chunk-CTBYVXFP.js";
15
+ import "../chunk-LI4N7JWK.js";
15
16
  export {
16
17
  addButton_default as AddButton,
17
18
  cancelButton_default as CancelButton,
@@ -1,6 +1,7 @@
1
1
  import {
2
2
  stdButton_default
3
3
  } from "../chunk-R3GARAVJ.js";
4
+ import "../chunk-LI4N7JWK.js";
4
5
  export {
5
6
  stdButton_default as default
6
7
  };
@@ -36,7 +36,7 @@ var React2 = __toESM(require("react"), 1);
36
36
 
37
37
  // lib/Progress/circularProgress.tsx
38
38
  var React = __toESM(require("react"), 1);
39
- var CircularProgess = ({
39
+ var CircularProgress = ({
40
40
  size = 50,
41
41
  color = "#a81c08",
42
42
  ...props
@@ -60,7 +60,7 @@ var CircularProgess = ({
60
60
  ))
61
61
  );
62
62
  };
63
- var circularProgress_default = CircularProgess;
63
+ var circularProgress_default = CircularProgress;
64
64
 
65
65
  // lib/Buttons/submitButton.tsx
66
66
  var SubmitButton = ({
@@ -1,7 +1,8 @@
1
1
  import {
2
2
  submitButton_default
3
- } from "../chunk-7YKG3WYS.js";
4
- import "../chunk-YRFUVQDN.js";
3
+ } from "../chunk-YRLN3TBF.js";
4
+ import "../chunk-CTBYVXFP.js";
5
+ import "../chunk-LI4N7JWK.js";
5
6
  export {
6
7
  submitButton_default as default
7
8
  };
@@ -26,7 +26,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  ));
27
27
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
28
 
29
- // lib/CheckBoxes/CheckBox.jsx
29
+ // lib/CheckBoxes/CheckBox.tsx
30
30
  var CheckBox_exports = {};
31
31
  __export(CheckBox_exports, {
32
32
  Checkbox: () => Checkbox
@@ -43,7 +43,7 @@ var Checkbox = ({
43
43
  style
44
44
  }) => {
45
45
  const handleChange = (e) => {
46
- onChange(e.target.checked);
46
+ if (onChange) onChange(e.target.checked);
47
47
  };
48
48
  return /* @__PURE__ */ import_react.default.createElement("div", { className: "checkbox-wrapper-13" }, /* @__PURE__ */ import_react.default.createElement("label", { className: `${className}`, style }, /* @__PURE__ */ import_react.default.createElement(
49
49
  "input",
@@ -1,28 +1,7 @@
1
- // lib/CheckBoxes/CheckBox.jsx
2
- import React from "react";
3
- var Checkbox = ({
4
- id,
5
- label,
6
- checked,
7
- onChange,
8
- disabled = false,
9
- className = "",
10
- style
11
- }) => {
12
- const handleChange = (e) => {
13
- onChange(e.target.checked);
14
- };
15
- return /* @__PURE__ */ React.createElement("div", { className: "checkbox-wrapper-13" }, /* @__PURE__ */ React.createElement("label", { className: `${className}`, style }, /* @__PURE__ */ React.createElement(
16
- "input",
17
- {
18
- id,
19
- type: "checkbox",
20
- checked,
21
- onChange: handleChange,
22
- disabled
23
- }
24
- ), label && /* @__PURE__ */ React.createElement("span", { className: "checkbox-label" }, label)));
25
- };
1
+ import {
2
+ Checkbox
3
+ } from "../chunk-NEGQXBQV.js";
4
+ import "../chunk-LI4N7JWK.js";
26
5
  export {
27
6
  Checkbox
28
7
  };
@@ -37,133 +37,165 @@ var import_react = __toESM(require("react"), 1);
37
37
 
38
38
  // lib/utils/constants.ts
39
39
  var APP_THEMES = {
40
- default: {
41
- name: "Default",
42
- primaryColor: "#707070",
43
- secondaryColor: "#e0e0e0",
44
- backgroundColor: "#f5f5f5",
45
- surfaceColor: "#ffffff",
46
- iconColor: "#707070",
47
- textColor: "#2d2d2d",
48
- textSecondaryColor: "#6f6f6f",
49
- borderColor: "#dcdcdc",
50
- hoverColor: "#d4d4d4",
51
- activeColor: "#5a5a5a",
52
- button: {
53
- background: "#707070",
54
- text: "#ffffff",
55
- hoverBackground: "#5f5f5f",
56
- disabledBackground: "#cfcfcf"
57
- },
58
- input: {
59
- background: "#ffffff",
60
- text: "#2d2d2d",
61
- border: "#ccc",
62
- placeholder: "#999",
63
- focusBorder: "#707070"
64
- },
65
- card: {
66
- background: "#ffffff",
67
- shadow: "0 1px 3px rgba(0,0,0,0.1)"
68
- },
69
- sidebar: {
70
- background: "#e8e8e8",
71
- text: "#2d2d2d",
72
- hover: "#dcdcdc"
73
- },
74
- success: "#4CAF50",
75
- warning: "#FFC107",
76
- error: "#F44336"
77
- },
78
40
  rufous: {
79
41
  name: "Rufous",
80
- primaryColor: "#a81c08",
81
- secondaryColor: "#f7d4cc",
82
- backgroundColor: "#fff8f7",
83
- surfaceColor: "#fff",
84
- iconColor: "#a81c08",
85
- textColor: "#2d2d2d",
86
- textSecondaryColor: "#6f6f6f",
87
- borderColor: "#e5e5e5",
88
- hoverColor: "#f3c2b9",
89
- activeColor: "#c01708",
90
- button: {
91
- background: "#a81c08",
92
- text: "#ffffff",
93
- hoverBackground: "#8f1907",
94
- disabledBackground: "#f4cccc"
95
- },
96
- input: {
42
+ light: {
43
+ primary: "#a41b06",
44
+ secondary: "#8b1605",
97
45
  background: "#ffffff",
46
+ surface: "#ffffff",
98
47
  text: "#2d2d2d",
99
- border: "#ccc",
100
- placeholder: "#999",
101
- focusBorder: "#a81c08"
102
- },
103
- card: {
104
- background: "#ffffff",
105
- shadow: "0 1px 3px rgba(0,0,0,0.1)"
48
+ textSecondary: "#666666",
49
+ border: "#e0e0e0",
50
+ hover: "#fff5f5",
51
+ selection: "#fce4ec",
52
+ icon: "#a41b06",
53
+ get customStyles() {
54
+ return {
55
+ iconColor: this.icon,
56
+ primaryColor: this.primary,
57
+ secondaryColor: this.secondary
58
+ };
59
+ }
106
60
  },
107
- sidebar: {
108
- background: "#fff0ed",
109
- text: "#2d2d2d",
110
- hover: "#f5e0dc"
61
+ dark: {
62
+ primary: "#dc2626",
63
+ secondary: "#a41b06",
64
+ background: "#121212",
65
+ surface: "#1e1e1e",
66
+ text: "#f5f5f5",
67
+ textSecondary: "#b0b0b0",
68
+ border: "#333333",
69
+ hover: "#2d1a1a",
70
+ selection: "#4a1212",
71
+ icon: "#dc2626",
72
+ get customStyles() {
73
+ return {
74
+ iconColor: this.icon,
75
+ primaryColor: this.primary,
76
+ secondaryColor: this.secondary
77
+ };
78
+ }
79
+ }
80
+ },
81
+ slate: {
82
+ name: "Slate",
83
+ light: {
84
+ primary: "#334155",
85
+ secondary: "#475569",
86
+ background: "#f8fafc",
87
+ surface: "#ffffff",
88
+ text: "#0f172a",
89
+ textSecondary: "#64748b",
90
+ border: "#e2e8f0",
91
+ hover: "#f1f5f9",
92
+ selection: "#e0f2fe",
93
+ icon: "#334155",
94
+ get customStyles() {
95
+ return {
96
+ iconColor: this.icon,
97
+ primaryColor: this.primary,
98
+ secondaryColor: this.secondary
99
+ };
100
+ }
111
101
  },
112
- success: "#4CAF50",
113
- warning: "#FFC107",
114
- error: "#F44336"
102
+ dark: {
103
+ primary: "#94a3b8",
104
+ secondary: "#64748b",
105
+ background: "#0f172a",
106
+ surface: "#1e293b",
107
+ text: "#f1f5f9",
108
+ textSecondary: "#94a3b8",
109
+ border: "#334155",
110
+ hover: "#1e293b",
111
+ selection: "#0c4a6e",
112
+ icon: "#94a3b8",
113
+ get customStyles() {
114
+ return {
115
+ iconColor: this.icon,
116
+ primaryColor: this.primary,
117
+ secondaryColor: this.secondary
118
+ };
119
+ }
120
+ }
115
121
  }
116
122
  };
117
123
 
118
124
  // lib/Contexts/rufousThemeProvider.tsx
119
125
  var RufousThemeContext = (0, import_react.createContext)(null);
120
126
  var RufousThemeProvider = ({ children }) => {
121
- const [committedThemeKey, setCommittedThemeKey] = (0, import_react.useState)("default");
122
- const [previewThemeKey, setPreviewThemeKey] = (0, import_react.useState)("default");
123
- const [settings, setSettings] = (0, import_react.useState)(null);
124
- const getGeneralSettings = async () => {
125
- try {
126
- const theme = localStorage.getItem("theme") || "default";
127
- setCommittedThemeKey(theme);
128
- setPreviewThemeKey(theme);
129
- } catch (err) {
130
- console.error("Error fetching general settings:", err);
131
- }
132
- };
127
+ const [colorScheme, setColorScheme] = (0, import_react.useState)("rufous");
128
+ const [mode, setMode] = (0, import_react.useState)("light");
133
129
  (0, import_react.useEffect)(() => {
134
- getGeneralSettings();
130
+ const savedScheme = localStorage.getItem("colorScheme") || "rufous";
131
+ const savedMode = localStorage.getItem("themeMode") || "light";
132
+ setColorScheme(savedScheme);
133
+ setMode(savedMode);
135
134
  }, []);
136
- const fullTheme = (0, import_react.useMemo)(() => {
135
+ const themeVars = (0, import_react.useMemo)(() => {
136
+ const config = APP_THEMES[colorScheme][mode];
137
137
  return {
138
- themeKey: previewThemeKey || settings.theme,
139
- customStyles: APP_THEMES[previewThemeKey || settings.theme]
138
+ "--rufous-primary-color": config.primary,
139
+ "--rufous-secondary-color": config.secondary,
140
+ "--rufous-background-color": config.background,
141
+ "--rufous-surface-color": config.surface,
142
+ "--rufous-text-color": config.text,
143
+ "--rufous-text-secondary": config.textSecondary,
144
+ "--rufous-border-color": config.border,
145
+ "--rufous-hover-color": config.hover,
146
+ "--rufous-selection-color": config.selection,
147
+ "--rufous-icon-color": config.icon,
148
+ // Keep legacy variables for backward compatibility during transition
149
+ "--primary-color": config.primary,
150
+ "--background-color": config.background,
151
+ "--text-color": config.text,
152
+ "--border-color": config.border,
153
+ "--surface-color": config.surface
140
154
  };
141
- }, [previewThemeKey, settings]);
142
- const previewTheme = (key) => setPreviewThemeKey(key);
143
- const saveTheme = (inputKey) => {
144
- const key = inputKey || previewThemeKey || settings.theme;
145
- localStorage.setItem("theme", key);
146
- setCommittedThemeKey(key);
155
+ }, [colorScheme, mode]);
156
+ const toggleMode = () => {
157
+ const newMode = mode === "light" ? "dark" : "light";
158
+ setMode(newMode);
159
+ };
160
+ const changeScheme = (scheme) => {
161
+ if (APP_THEMES[scheme]) {
162
+ setColorScheme(scheme);
163
+ }
164
+ };
165
+ const saveTheme = () => {
166
+ localStorage.setItem("colorScheme", colorScheme);
167
+ localStorage.setItem("themeMode", mode);
168
+ };
169
+ const updateSettings = (settings) => {
170
+ if (!settings) return;
171
+ if (settings.theme && APP_THEMES[settings.theme]) {
172
+ setColorScheme(settings.theme);
173
+ }
174
+ if (settings.mode) {
175
+ setMode(settings.mode);
176
+ }
147
177
  };
148
- const cancelTheme = () => setPreviewThemeKey(committedThemeKey);
149
178
  return /* @__PURE__ */ import_react.default.createElement(
150
179
  RufousThemeContext.Provider,
151
180
  {
152
181
  value: {
153
- theme: fullTheme,
154
- previewTheme,
182
+ colorScheme,
183
+ mode,
184
+ toggleMode,
185
+ changeScheme,
186
+ previewTheme: changeScheme,
187
+ updateSettings,
155
188
  saveTheme,
156
- cancelTheme,
157
- currentThemeKey: previewThemeKey,
158
- committedThemeKey,
159
- settings,
160
- updateSettings: (v) => setSettings(v)
189
+ theme: APP_THEMES[colorScheme][mode],
190
+ // Direct access to current theme config
191
+ themeConfig: APP_THEMES[colorScheme][mode]
161
192
  }
162
193
  },
163
194
  /* @__PURE__ */ import_react.default.createElement(
164
195
  "div",
165
196
  {
166
- className: `theme-${previewThemeKey || committedThemeKey || "default"}`
197
+ className: `rufous-theme-root scheme-${colorScheme} mode-${mode}`,
198
+ style: themeVars
167
199
  },
168
200
  children
169
201
  )
@@ -1,8 +1,9 @@
1
1
  import {
2
2
  RufousThemeProvider,
3
3
  useRufousTheme
4
- } from "../chunk-BCGCLMKA.js";
5
- import "../chunk-2FHTGYR4.js";
4
+ } from "../chunk-HMG3FW2Q.js";
5
+ import "../chunk-YXPBXCY5.js";
6
+ import "../chunk-LI4N7JWK.js";
6
7
  export {
7
8
  RufousThemeProvider,
8
9
  useRufousTheme