@ambuj.bhaskar/react-component-library 0.6.1 → 0.6.2

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.
package/dist/index.d.ts CHANGED
@@ -248,15 +248,56 @@ declare type SVGprops = React.ComponentProps<"svg">;
248
248
 
249
249
  declare type TextSize = "xs" | "s" | "m" | "l" | "xl";
250
250
 
251
- declare type Theme = {
252
- [key: string]: string | Theme;
251
+ declare type Theme = Partial<{
252
+ common: {
253
+ primary: string;
254
+ secondary: string;
255
+ highlight: string;
256
+ success: string;
257
+ warning: string;
258
+ error: string;
259
+ info: string;
260
+ disabled: string;
261
+ };
262
+ text: {
263
+ primary: string;
264
+ secondary: string;
265
+ tertiary: string;
266
+ disabled: string;
267
+ };
268
+ background: {
269
+ primary: string;
270
+ };
271
+ surface: {
272
+ fill: {
273
+ primary: string;
274
+ secondary: string;
275
+ tertiary: string;
276
+ };
277
+ border: {
278
+ primary: string;
279
+ secondary: string;
280
+ tertiary: string;
281
+ };
282
+ };
283
+ }> & UnknownObject;
284
+
285
+ declare type ThemeObject = {
286
+ name: string;
287
+ palette: Theme;
253
288
  };
254
289
 
255
290
  export declare const ThemeProvider: ({ theme, children }: ThemeProviderProps) => JSX_2.Element;
256
291
 
257
- declare interface ThemeProviderProps {
258
- theme: Theme;
292
+ declare type ThemeProviderProps = {
293
+ theme: ThemeObject;
259
294
  children: ReactNode;
260
- }
295
+ };
296
+
297
+ declare type UnknownObject = {
298
+ [key: string]: unknown;
299
+ };
300
+
301
+ export declare const useTheme: () => Record<string, string>;
261
302
 
262
303
  export { }