@capillarytech/blaze-ui 2.0.2 → 2.0.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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Font configuration for Blaze UI
2
+ * Font configuration for Cap UI
3
3
  * Centralized font management for consistent typography across applications
4
4
  */
5
5
  export interface FontConfig {
@@ -11,7 +11,7 @@ export interface FontConfig {
11
11
  robotoWeights?: number[];
12
12
  }
13
13
  /**
14
- * Loads Blaze UI fonts into the document head
14
+ * Loads Cap UI fonts into the document head
15
15
  *
16
16
  * This function should be called once when your application initializes.
17
17
  * It's safe to call multiple times - it will check if fonts are already loaded.
@@ -20,19 +20,19 @@ export interface FontConfig {
20
20
  *
21
21
  * @example
22
22
  * ```typescript
23
- * import { loadBlazeUIFonts } from '@capillarytech/blaze-ui';
23
+ * import { loadCapUIFonts } from '@capillarytech/blaze-ui';
24
24
  *
25
25
  * // Load all fonts (default)
26
- * loadBlazeUIFonts();
26
+ * loadCapUIFonts();
27
27
  *
28
28
  * // Load only Roboto with custom weights
29
- * loadBlazeUIFonts({
29
+ * loadCapUIFonts({
30
30
  * loadMaterialIcons: false,
31
31
  * robotoWeights: [400, 500, 700]
32
32
  * });
33
33
  * ```
34
34
  */
35
- export declare const loadBlazeUIFonts: (config?: FontConfig) => void;
35
+ export declare const loadCapUIFonts: (config?: FontConfig) => void;
36
36
  /**
37
37
  * Creates HTML link tags for fonts (useful for SSR or static HTML)
38
38
  *
@@ -42,8 +42,8 @@ export declare const loadBlazeUIFonts: (config?: FontConfig) => void;
42
42
  * @example
43
43
  * ```html
44
44
  * <!-- In your HTML head -->
45
- * ${getBlazeUIFontLinks().join('\n')}
45
+ * ${getCapUIFontLinks().join('\n')}
46
46
  * ```
47
47
  */
48
- export declare const getBlazeUIFontLinks: (config?: FontConfig) => string[];
48
+ export declare const getCapUIFontLinks: (config?: FontConfig) => string[];
49
49
  //# sourceMappingURL=fonts.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"fonts.d.ts","sourceRoot":"","sources":["../../components/utils/fonts.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,WAAW,UAAU;IACzB,kDAAkD;IAClD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,qDAAqD;IACrD,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,2DAA2D;IAC3D,aAAa,CAAC,EAAE,MAAM,EAAE,CAAC;CAC1B;AA4FD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,eAAO,MAAM,gBAAgB,GAAI,SAAQ,UAAe,KAAG,IAU1D,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,mBAAmB,GAAI,SAAQ,UAAe,KAAG,MAAM,EAkBnE,CAAC"}
1
+ {"version":3,"file":"fonts.d.ts","sourceRoot":"","sources":["../../components/utils/fonts.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,WAAW,UAAU;IACzB,kDAAkD;IAClD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,qDAAqD;IACrD,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,2DAA2D;IAC3D,aAAa,CAAC,EAAE,MAAM,EAAE,CAAC;CAC1B;AA4FD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,eAAO,MAAM,cAAc,GAAI,SAAQ,UAAe,KAAG,IAUxD,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,iBAAiB,GAAI,SAAQ,UAAe,KAAG,MAAM,EAkBjE,CAAC"}
@@ -4,6 +4,13 @@ import { ThemeConfig } from 'antd-v5';
4
4
  * This function maps Capillary design tokens to Ant Design tokens,
5
5
  * eliminating the need for SCSS overrides.
6
6
  *
7
+ * **⚠️ Accessibility Note:**
8
+ * This function converts rem values to px for Ant Design theme tokens.
9
+ * This means Ant Design components will not scale with user browser font size settings,
10
+ * while Cap UI components (which use rem) will scale. This creates inconsistent
11
+ * behavior and violates WCAG 2.1 SC 1.4.4 (Resize text). Consider using rem values
12
+ * directly in theme config when Ant Design v6 supports it, or use CSS custom properties.
13
+ *
7
14
  * @param options - Optional theme configuration overrides
8
15
  * @returns Ant Design ThemeConfig object
9
16
  *
@@ -1 +1 @@
1
- {"version":3,"file":"getCapThemeConfig.d.ts","sourceRoot":"","sources":["../../components/utils/getCapThemeConfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAwCtC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAAG,WAAW,CAwP7E"}
1
+ {"version":3,"file":"getCapThemeConfig.d.ts","sourceRoot":"","sources":["../../components/utils/getCapThemeConfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAmEtC;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAAG,WAAW,CAsP7E"}
@@ -4,14 +4,14 @@ export * from './fonts';
4
4
  export type { FontConfig } from './fonts';
5
5
  export { getCapThemeConfig } from './getCapThemeConfig';
6
6
  /**
7
- * Configuration for Blaze UI initialization
7
+ * Configuration for Cap UI initialization
8
8
  */
9
- export interface BlazeUIConfig extends FontConfig {
9
+ export interface CapUIConfig extends FontConfig {
10
10
  /** Base font size for rem calculations (default: '14px') */
11
11
  baseFontSize?: string;
12
12
  }
13
13
  /**
14
- * Loads Blaze UI fonts and base styles (sanitize.css) together
14
+ * Loads Cap UI fonts and base styles (sanitize.css) together
15
15
  *
16
16
  * This is a convenience function that loads both fonts and base styles in one call.
17
17
  * It should be called once when your application initializes.
@@ -20,26 +20,26 @@ export interface BlazeUIConfig extends FontConfig {
20
20
  * - Webpack will typically deduplicate it if both resolve to the same module path in node_modules
21
21
  * - However, if you want to avoid any potential duplication, import fonts separately:
22
22
  * ```typescript
23
- * import { loadBlazeUIFonts } from '@capillarytech/blaze-ui/utils';
24
- * loadBlazeUIFonts();
23
+ * import { loadCapUIFonts } from '@capillarytech/blaze-ui/utils';
24
+ * loadCapUIFonts();
25
25
  * ```
26
26
  *
27
- * @param config - Blaze UI configuration options
27
+ * @param config - Cap UI configuration options
28
28
  *
29
29
  * @example
30
30
  * ```typescript
31
- * import { loadBlazeUI } from '@capillarytech/blaze-ui/utils';
31
+ * import { loadCapUI } from '@capillarytech/blaze-ui/utils';
32
32
  *
33
33
  * // Load everything with default base font size (14px)
34
- * loadBlazeUI();
34
+ * loadCapUI();
35
35
  *
36
36
  * // Load with custom font configuration and base font size
37
- * loadBlazeUI({
37
+ * loadCapUI({
38
38
  * loadMaterialIcons: false,
39
39
  * robotoWeights: [400, 500, 700],
40
40
  * baseFontSize: '16px'
41
41
  * });
42
42
  * ```
43
43
  */
44
- export declare const loadBlazeUI: (config?: BlazeUIConfig) => void;
44
+ export declare const loadCapUI: (config?: CapUIConfig) => void;
45
45
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../components/utils/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,UAAU,CAAC;AAElB,cAAc,SAAS,CAAC;AACxB,YAAY,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAExD;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,UAAU;IAC/C,4DAA4D;IAC5D,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,eAAO,MAAM,WAAW,GAAI,SAAQ,aAAkB,KAAG,IAWxD,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../components/utils/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,UAAU,CAAC;AAElB,cAAc,SAAS,CAAC;AACxB,YAAY,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAExD;;GAEG;AACH,MAAM,WAAW,WAAY,SAAQ,UAAU;IAC7C,4DAA4D;IAC5D,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,eAAO,MAAM,SAAS,GAAI,SAAQ,WAAgB,KAAG,IAWpD,CAAC"}