@stamcat/craftsman 0.0.31-beta.0 → 0.0.31-beta.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stamcat/craftsman",
3
- "version": "0.0.31-beta.0",
3
+ "version": "0.0.31-beta.2",
4
4
  "type": "module",
5
5
  "description": "A powerful, lightweight framework for design systems",
6
6
  "repository": {
@@ -70,6 +70,12 @@
70
70
  "./styles/config": {
71
71
  "default": "./src/styles/_config.scss"
72
72
  },
73
+ "./styles/utilities/_functions": {
74
+ "default": "./src/styles/utilities/_functions.scss"
75
+ },
76
+ "./styles/utilities/_placeholders": {
77
+ "default": "./src/styles/utilities/_placeholders.scss"
78
+ },
73
79
  "./Button": {
74
80
  "types": "./src/components/Button/Button.d.ts",
75
81
  "default": "./src/components/Button/Button.esm.js"
@@ -3,6 +3,6 @@ export * from './utilities/constants';
3
3
  export * from './utilities/layout';
4
4
  export * from '../utilities/types';
5
5
  export * from './theme/theme';
6
- export type { AppTheme, ColorVariableName, ComponentThemeOverrides, CSSObject, LegacySerializedStyles, RegisteredComponent, Theme, ThemeProviderProps, WidthOverrides, Colors as ThemeColors, } from './theme/types';
6
+ export type { AppTheme, ColorVariableName, ComponentThemeOverrides, CSSObject, SerializedStyles, RegisteredComponent, Theme, ThemeProviderProps, WidthOverrides, Colors as ThemeColors, } from './theme/types';
7
7
  export { type RegisteredComponentName, componentSelectors } from './theme/components';
8
8
  export { ThemeProvider } from './components/ThemeProvider';
@@ -5,21 +5,21 @@ export type ColorVariableName = `--${ColorKey}`;
5
5
  export type CSSObject = {
6
6
  [key: string]: string | number | CSSObject | undefined;
7
7
  };
8
- export type LegacySerializedStyles = {
8
+ export type SerializedStyles = {
9
9
  name: string;
10
10
  styles: string;
11
- next?: LegacySerializedStyles;
11
+ next?: SerializedStyles;
12
12
  };
13
13
  export type RegisteredComponent = keyof typeof componentSelectors;
14
14
  export type ComponentThemeOverrides = {
15
- [K in RegisteredComponent]?: CSSObject | LegacySerializedStyles | string;
15
+ [K in RegisteredComponent]?: CSSObject | SerializedStyles | string;
16
16
  };
17
17
  export type Colors = Partial<Record<ColorVariableName, string>>;
18
18
  export type WidthOverrides = Partial<Record<LayoutWidthsType, number>>;
19
19
  export type Theme = {
20
20
  colors?: Colors;
21
21
  widths?: WidthOverrides;
22
- root?: CSSObject | LegacySerializedStyles | string;
22
+ root?: CSSObject | SerializedStyles | string;
23
23
  components?: ComponentThemeOverrides;
24
24
  };
25
25
  export type ThemeProviderProps = {
@@ -1,3 +1,3 @@
1
- import { CSSObject, LegacySerializedStyles } from './types';
2
- export declare function toCSSObject(value: CSSObject | LegacySerializedStyles): CSSObject;
1
+ import { CSSObject, SerializedStyles } from './types';
2
+ export declare function toCSSObject(value: CSSObject | SerializedStyles): CSSObject;
3
3
  export declare function cssObjectToCssText(selector: string, value: CSSObject): string;
@@ -6,34 +6,34 @@ var n = Object.fromEntries(e.options.map((e) => [e, `var(--w-${e}, ${t[e]}px)`])
6
6
  return "(min-width: 0px)";
7
7
  },
8
8
  get mobileMax() {
9
- return `(max-width: ${n.mobileMax}px)`;
9
+ return `(max-width: ${t.mobileMax}px)`;
10
10
  },
11
11
  get tablet() {
12
- return `(min-width: ${n.tablet}px)`;
12
+ return `(min-width: ${t.tablet}px)`;
13
13
  },
14
14
  get tabletMax() {
15
- return `(max-width: ${n.tabletMax}px)`;
15
+ return `(max-width: ${t.tabletMax}px)`;
16
16
  },
17
17
  get desktop() {
18
- return `(min-width: ${n.desktop}px)`;
18
+ return `(min-width: ${t.desktop}px)`;
19
19
  },
20
20
  get desktopMax() {
21
- return `(max-width: ${n.desktopMax}px)`;
21
+ return `(max-width: ${t.desktopMax}px)`;
22
22
  },
23
23
  get extDesktop() {
24
- return `(min-width: ${n.extDesktop}px)`;
24
+ return `(min-width: ${t.extDesktop}px)`;
25
25
  },
26
26
  get mobileOnly() {
27
- return `(min-width: 0px) and (max-width: ${n.mobileMax}px)`;
27
+ return `(min-width: 0px) and (max-width: ${t.mobileMax}px)`;
28
28
  },
29
29
  get tabletOnly() {
30
- return `(min-width: ${n.tablet}px) and (max-width: ${n.tabletMax}px)`;
30
+ return `(min-width: ${t.tablet}px) and (max-width: ${t.tabletMax}px)`;
31
31
  },
32
32
  get mobileTablet() {
33
- return `(min-width: 0px) and (max-width: ${n.tabletMax}px)`;
33
+ return `(min-width: 0px) and (max-width: ${t.tabletMax}px)`;
34
34
  },
35
35
  get desktopOnly() {
36
- return `(min-width: ${n.desktop}px) and (max-width: ${n.desktopMax}px)`;
36
+ return `(min-width: ${t.desktop}px) and (max-width: ${t.desktopMax}px)`;
37
37
  }
38
38
  }, i = (e, t = 1, r = !0) => {
39
39
  let i = n[e];