@surreal-ui/catalog 0.12.0 → 0.13.0
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/README.md +16 -16
- package/dist/{chunk-ZYD3ZW7Q.js → chunk-FJC5GAN5.js} +1 -0
- package/dist/node.d.ts +24 -1
- package/dist/node.js +90 -0
- package/dist/react/editor.js +1 -1
- package/dist/react/flair.js +1 -1
- package/dist/react/index.d.ts +20 -1
- package/dist/react/index.js +6 -0
- package/dist/registry.d.ts +8 -0
- package/dist/sources/bar-chart/react.tsx +1 -1
- package/dist/sources/braid/react.tsx +1 -1
- package/dist/sources/donut-chart/react.tsx +1 -1
- package/dist/sources/flow/react.tsx +1 -1
- package/dist/sources/gauge/react.tsx +1 -1
- package/dist/sources/line-chart/react.tsx +1 -1
- package/dist/sources/lineage/react.tsx +1 -1
- package/dist/sources/mindmap/react.tsx +1 -1
- package/dist/sources/sparkline/react.tsx +1 -1
- package/dist/sources/timeline/react.tsx +1 -1
- package/dist/sources/weave/react.tsx +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -40,22 +40,22 @@ npm install @surreal-ui/catalog
|
|
|
40
40
|
|
|
41
41
|
React 18+ or Svelte 5. Install `@pixerate/flair` or `@pixerate/editor` only if you use the components that come from them.
|
|
42
42
|
|
|
43
|
-
| Entry point | What it has
|
|
44
|
-
| ------------------------------------ |
|
|
45
|
-
| `@surreal-ui/catalog` | The catalog API: components, categories, aesthetics, contracts, packs
|
|
46
|
-
| `@surreal-ui/catalog/lazy` | The same metadata, with each React component loaded on demand
|
|
47
|
-
| `@surreal-ui/catalog/react` | React components
|
|
48
|
-
| `@surreal-ui/catalog/react/flair` | Components drawn by Flair (needs `@pixerate/flair`)
|
|
49
|
-
| `@surreal-ui/catalog/react/editor` | Charts from editor (needs `@pixerate/editor`)
|
|
50
|
-
| `@surreal-ui/catalog/svelte` | Svelte 5 components (`/svelte/lazy` to load them on demand)
|
|
51
|
-
| `@surreal-ui/catalog/components.css` | The styles every component needs
|
|
52
|
-
| `@surreal-ui/catalog/aesthetics/*` | One CSS pack per aesthetic, e.g. `@surreal-ui/catalog/aesthetics/ink.css`
|
|
53
|
-
| `@surreal-ui/catalog/web` | WebComponents: importing it defines `<surreal-button>`, `<surreal-theme>`, …
|
|
54
|
-
| `@surreal-ui/catalog/node` | `installSkills` (Node only)
|
|
55
|
-
| `@surreal-ui/catalog/naming` | Naming helpers shared by the packages, the CLI and the service
|
|
56
|
-
| `@surreal-ui/catalog/registry` | The hosted registry's item types (shadcn registry-item compatible)
|
|
57
|
-
| `@surreal-ui/catalog/theme` | A `Theme` as Tailwind v4 custom properties
|
|
58
|
-
| `@surreal-ui/catalog/look` | The deterministic look checks (contrast, hit targets, reduced motion)
|
|
43
|
+
| Entry point | What it has |
|
|
44
|
+
| ------------------------------------ | ----------------------------------------------------------------------------- |
|
|
45
|
+
| `@surreal-ui/catalog` | The catalog API: components, categories, aesthetics, contracts, packs |
|
|
46
|
+
| `@surreal-ui/catalog/lazy` | The same metadata, with each React component loaded on demand |
|
|
47
|
+
| `@surreal-ui/catalog/react` | React components, and `useRoleColors` for components drawn by a provider |
|
|
48
|
+
| `@surreal-ui/catalog/react/flair` | Components drawn by Flair (needs `@pixerate/flair`) |
|
|
49
|
+
| `@surreal-ui/catalog/react/editor` | Charts and diagrams from editor (needs `@pixerate/editor`; diagrams `dagre`) |
|
|
50
|
+
| `@surreal-ui/catalog/svelte` | Svelte 5 components (`/svelte/lazy` to load them on demand) |
|
|
51
|
+
| `@surreal-ui/catalog/components.css` | The styles every component needs |
|
|
52
|
+
| `@surreal-ui/catalog/aesthetics/*` | One CSS pack per aesthetic, e.g. `@surreal-ui/catalog/aesthetics/ink.css` |
|
|
53
|
+
| `@surreal-ui/catalog/web` | WebComponents: importing it defines `<surreal-button>`, `<surreal-theme>`, … |
|
|
54
|
+
| `@surreal-ui/catalog/node` | `installSkills`, `catalogRegistryItem` (what `surreal add` copies; Node only) |
|
|
55
|
+
| `@surreal-ui/catalog/naming` | Naming helpers shared by the packages, the CLI and the service |
|
|
56
|
+
| `@surreal-ui/catalog/registry` | The hosted registry's item types (shadcn registry-item compatible) |
|
|
57
|
+
| `@surreal-ui/catalog/theme` | A `Theme` as Tailwind v4 custom properties |
|
|
58
|
+
| `@surreal-ui/catalog/look` | The deterministic look checks (contrast, hit targets, reduced motion) |
|
|
59
59
|
|
|
60
60
|
## 🚀 Drop in
|
|
61
61
|
|
package/dist/node.d.ts
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
import { CatalogComponent } from './index.js';
|
|
2
|
+
import { RegistryItem } from './registry.js';
|
|
3
|
+
import { PlatformLanguage } from '@pixerate/schemas';
|
|
4
|
+
import '@pixerate/schemas/genui';
|
|
5
|
+
import './theme-V1Iz-HmC.js';
|
|
6
|
+
|
|
1
7
|
/** The skills in the package, by folder name. */
|
|
2
8
|
declare const SURREAL_SKILLS: readonly [{
|
|
3
9
|
readonly name: "surreal-use";
|
|
@@ -42,4 +48,21 @@ declare function skillsSource(): string;
|
|
|
42
48
|
*/
|
|
43
49
|
declare function installSkills(options?: InstallSkillsOptions): InstalledSkills;
|
|
44
50
|
|
|
45
|
-
|
|
51
|
+
/** This package's dist folder: beside the built module, or ../dist from the sources. */
|
|
52
|
+
declare function catalogDistDir(): string;
|
|
53
|
+
/**
|
|
54
|
+
* The npm packages a component's code imports (bare specifiers, by package name), plus the peers
|
|
55
|
+
* those entries need, without the framework itself. Sorted.
|
|
56
|
+
*/
|
|
57
|
+
declare function codeDependencies(code: string): string[];
|
|
58
|
+
/** The frameworks this release ships a type's source for. */
|
|
59
|
+
declare function catalogFrameworks(component: CatalogComponent, dist?: string): PlatformLanguage[];
|
|
60
|
+
/**
|
|
61
|
+
* The files `surreal add` writes for a catalog type: its implementation for the framework, its
|
|
62
|
+
* stylesheet and the aesthetic's pack, with every package the code imports as a dependency (for an
|
|
63
|
+
* engine type, its provider). Null if the release has no source for that framework; throws for an
|
|
64
|
+
* unknown aesthetic.
|
|
65
|
+
*/
|
|
66
|
+
declare function catalogRegistryItem(component: CatalogComponent, framework: PlatformLanguage, aestheticId: string, dist?: string): RegistryItem | null;
|
|
67
|
+
|
|
68
|
+
export { DEFAULT_SKILLS_DIR, type InstallSkillsOptions, type InstalledSkillFile, type InstalledSkills, SURREAL_SKILLS, type SurrealSkillName, catalogDistDir, catalogFrameworks, catalogRegistryItem, codeDependencies, installSkills, skillsSource };
|
package/dist/node.js
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
import {
|
|
2
|
+
AESTHETICS,
|
|
3
|
+
getAesthetic
|
|
4
|
+
} from "./chunk-BV22DQWK.js";
|
|
5
|
+
import "./chunk-HMNTTISG.js";
|
|
6
|
+
|
|
1
7
|
// src/skills.ts
|
|
2
8
|
import fs from "fs";
|
|
3
9
|
import path from "path";
|
|
@@ -67,9 +73,93 @@ function installSkills(options = {}) {
|
|
|
67
73
|
}
|
|
68
74
|
return { dir, skills: wanted, files };
|
|
69
75
|
}
|
|
76
|
+
|
|
77
|
+
// src/registry-item.ts
|
|
78
|
+
import fs2 from "fs";
|
|
79
|
+
import path2 from "path";
|
|
80
|
+
import { fileURLToPath as fileURLToPath2 } from "url";
|
|
81
|
+
var SOURCE = {
|
|
82
|
+
react: { file: "react.tsx", ext: "tsx" },
|
|
83
|
+
svelte: { file: "svelte.svelte", ext: "svelte" },
|
|
84
|
+
webcomponent: { file: "element.ts", ext: "ts" }
|
|
85
|
+
};
|
|
86
|
+
var FRAMEWORKS = /* @__PURE__ */ new Set(["react", "react-dom", "svelte"]);
|
|
87
|
+
var ENTRY_PEERS = {
|
|
88
|
+
// Diagram layout (diagramUiComponents) needs dagre.
|
|
89
|
+
"@pixerate/editor/canvas": ["@dagrejs/dagre"]
|
|
90
|
+
};
|
|
91
|
+
function catalogDistDir() {
|
|
92
|
+
const here = path2.dirname(fileURLToPath2(import.meta.url));
|
|
93
|
+
return fs2.existsSync(path2.join(here, "sources")) ? here : path2.resolve(here, "../dist");
|
|
94
|
+
}
|
|
95
|
+
function codeDependencies(code) {
|
|
96
|
+
const deps = /* @__PURE__ */ new Set();
|
|
97
|
+
for (const m of code.matchAll(/(?:from\s+|import\s+|import\()\s*['"]([^'"./][^'"]*)['"]/g)) {
|
|
98
|
+
const spec = m[1];
|
|
99
|
+
const parts = spec.split("/");
|
|
100
|
+
const name = spec.startsWith("@") ? parts.slice(0, 2).join("/") : parts[0];
|
|
101
|
+
if (FRAMEWORKS.has(name)) continue;
|
|
102
|
+
deps.add(name);
|
|
103
|
+
for (const peer of ENTRY_PEERS[spec] ?? []) deps.add(peer);
|
|
104
|
+
}
|
|
105
|
+
return [...deps].sort();
|
|
106
|
+
}
|
|
107
|
+
function catalogFrameworks(component, dist = catalogDistDir()) {
|
|
108
|
+
const dir = path2.join(dist, "sources", component.id);
|
|
109
|
+
return Object.keys(SOURCE).filter(
|
|
110
|
+
(f) => fs2.existsSync(path2.join(dir, SOURCE[f].file))
|
|
111
|
+
);
|
|
112
|
+
}
|
|
113
|
+
function catalogRegistryItem(component, framework, aestheticId, dist = catalogDistDir()) {
|
|
114
|
+
const src = SOURCE[framework];
|
|
115
|
+
const dir = path2.join(dist, "sources", component.id);
|
|
116
|
+
const main = path2.join(dir, src.file);
|
|
117
|
+
if (!fs2.existsSync(main)) return null;
|
|
118
|
+
if (!getAesthetic(aestheticId))
|
|
119
|
+
throw new Error(
|
|
120
|
+
`Unknown aesthetic "${aestheticId}". Available: ${AESTHETICS.map((a) => a.id).join(", ")}`
|
|
121
|
+
);
|
|
122
|
+
const code = fs2.readFileSync(main, "utf8");
|
|
123
|
+
const files = [
|
|
124
|
+
{ path: `${component.export}.${src.ext}`, content: code, type: "registry:ui" }
|
|
125
|
+
];
|
|
126
|
+
const style = path2.join(dir, "style.css");
|
|
127
|
+
if (fs2.existsSync(style))
|
|
128
|
+
files.push({
|
|
129
|
+
path: `${component.id}.css`,
|
|
130
|
+
content: fs2.readFileSync(style, "utf8"),
|
|
131
|
+
type: "registry:ui"
|
|
132
|
+
});
|
|
133
|
+
files.push({
|
|
134
|
+
path: `aesthetic-${aestheticId}.css`,
|
|
135
|
+
content: fs2.readFileSync(path2.join(dist, "aesthetics", `${aestheticId}.css`), "utf8"),
|
|
136
|
+
type: "registry:ui"
|
|
137
|
+
});
|
|
138
|
+
return {
|
|
139
|
+
name: component.id,
|
|
140
|
+
type: "registry:ui",
|
|
141
|
+
title: component.name,
|
|
142
|
+
description: component.description,
|
|
143
|
+
dependencies: codeDependencies(code),
|
|
144
|
+
files,
|
|
145
|
+
meta: {
|
|
146
|
+
aestheticId,
|
|
147
|
+
componentTypeId: component.id,
|
|
148
|
+
version: component.source.version ?? "",
|
|
149
|
+
framework,
|
|
150
|
+
symbolName: component.export,
|
|
151
|
+
runtime: component.runtime,
|
|
152
|
+
...component.source.provider !== "manual" ? { provider: component.source.provider } : {}
|
|
153
|
+
}
|
|
154
|
+
};
|
|
155
|
+
}
|
|
70
156
|
export {
|
|
71
157
|
DEFAULT_SKILLS_DIR,
|
|
72
158
|
SURREAL_SKILLS,
|
|
159
|
+
catalogDistDir,
|
|
160
|
+
catalogFrameworks,
|
|
161
|
+
catalogRegistryItem,
|
|
162
|
+
codeDependencies,
|
|
73
163
|
installSkills,
|
|
74
164
|
skillsSource
|
|
75
165
|
};
|
package/dist/react/editor.js
CHANGED
package/dist/react/flair.js
CHANGED
package/dist/react/index.d.ts
CHANGED
|
@@ -23,6 +23,25 @@ declare function withAesthetic<P extends object>(Component: React.ComponentType<
|
|
|
23
23
|
/** An old aesthetic-prefixed export as the type plus its aesthetic, with the old props mapped. */
|
|
24
24
|
declare function deprecatedAlias<P extends object>(Component: React.ComponentType<P>, spec: DeprecatedSpec): React.ForwardRefExoticComponent<Record<string, unknown> & React.RefAttributes<unknown>>;
|
|
25
25
|
|
|
26
|
+
/**
|
|
27
|
+
* For components synced from providers (Flair, editor): the aesthetic's colour roles and colour
|
|
28
|
+
* scheme where the component sits, read from the `--sui-<role>` variables its aesthetic pack sets.
|
|
29
|
+
* They are read after mount and again whenever an ancestor's class, data-theme or data-aesthetic
|
|
30
|
+
* changes, or the OS colour scheme does, so switching aesthetic or theme restyles them.
|
|
31
|
+
*/
|
|
32
|
+
type Rgb = [number, number, number];
|
|
33
|
+
interface RoleColors {
|
|
34
|
+
/** Role → CSS colour as computed (`rgb(…)`). */
|
|
35
|
+
css: Record<string, string>;
|
|
36
|
+
/** Role → [r, g, b] in 0–1, as Flair's colour controls take. */
|
|
37
|
+
rgb: Record<string, Rgb>;
|
|
38
|
+
scheme: 'light' | 'dark';
|
|
39
|
+
}
|
|
40
|
+
/** Reads the roles at an element. Undefined until every role resolves (no aesthetic pack loaded yet). */
|
|
41
|
+
declare function readRoleColors(el: Element, roles: readonly string[]): RoleColors | undefined;
|
|
42
|
+
/** The roles at `ref`, kept current as aesthetics and themes change. */
|
|
43
|
+
declare function useRoleColors(ref: React.RefObject<Element | null>, roles: readonly string[]): RoleColors | undefined;
|
|
44
|
+
|
|
26
45
|
interface BadgeProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
27
46
|
tone?: 'neutral' | 'accent' | 'danger';
|
|
28
47
|
}
|
|
@@ -123,4 +142,4 @@ interface TextareaProps extends Omit<React.TextareaHTMLAttributes<HTMLTextAreaEl
|
|
|
123
142
|
}
|
|
124
143
|
declare const Textarea: React.ForwardRefExoticComponent<TextareaProps & React.RefAttributes<HTMLTextAreaElement>>;
|
|
125
144
|
|
|
126
|
-
export { Badge, type BadgeProps, Button, type ButtonProps, Card, type CardProps, Checkbox, type CheckboxProps, DeprecatedSpec, Input, type InputProps, Kbd, type KbdProps, Label, type LabelProps, Progress, type ProgressProps, Separator, type SeparatorProps, Skeleton, type SkeletonProps, Spinner, type SpinnerProps, SurrealTheme, type SurrealThemeProps, Switch, type SwitchProps, Textarea, type TextareaProps, ThemeMode, deprecatedAlias, useAesthetic, useStructure, withAesthetic };
|
|
145
|
+
export { Badge, type BadgeProps, Button, type ButtonProps, Card, type CardProps, Checkbox, type CheckboxProps, DeprecatedSpec, Input, type InputProps, Kbd, type KbdProps, Label, type LabelProps, Progress, type ProgressProps, type Rgb, type RoleColors, Separator, type SeparatorProps, Skeleton, type SkeletonProps, Spinner, type SpinnerProps, SurrealTheme, type SurrealThemeProps, Switch, type SwitchProps, Textarea, type TextareaProps, ThemeMode, deprecatedAlias, readRoleColors, useAesthetic, useRoleColors, useStructure, withAesthetic };
|
package/dist/react/index.js
CHANGED
|
@@ -25,6 +25,10 @@ import {
|
|
|
25
25
|
import {
|
|
26
26
|
Switch
|
|
27
27
|
} from "../chunk-F5CUZM5I.js";
|
|
28
|
+
import {
|
|
29
|
+
readRoleColors,
|
|
30
|
+
useRoleColors
|
|
31
|
+
} from "../chunk-FJC5GAN5.js";
|
|
28
32
|
import {
|
|
29
33
|
Badge
|
|
30
34
|
} from "../chunk-LABYZELU.js";
|
|
@@ -59,7 +63,9 @@ export {
|
|
|
59
63
|
Switch,
|
|
60
64
|
Textarea,
|
|
61
65
|
deprecatedAlias,
|
|
66
|
+
readRoleColors,
|
|
62
67
|
useAesthetic,
|
|
68
|
+
useRoleColors,
|
|
63
69
|
useStructure,
|
|
64
70
|
withAesthetic
|
|
65
71
|
};
|
package/dist/registry.d.ts
CHANGED
|
@@ -25,6 +25,10 @@ interface RegistryItem {
|
|
|
25
25
|
framework: PlatformLanguage;
|
|
26
26
|
themeSupport?: string;
|
|
27
27
|
symbolName?: string;
|
|
28
|
+
/** `engine`: a provider's runtime draws it from data (#38); `code` otherwise. */
|
|
29
|
+
runtime?: 'code' | 'engine';
|
|
30
|
+
/** For a provider's component: who draws it (`editor`, `flair`). */
|
|
31
|
+
provider?: string;
|
|
28
32
|
};
|
|
29
33
|
}
|
|
30
34
|
interface RegistryIndexItem {
|
|
@@ -35,6 +39,10 @@ interface RegistryIndexItem {
|
|
|
35
39
|
aesthetics: string[];
|
|
36
40
|
dependencies: string[];
|
|
37
41
|
registryDependencies?: string[];
|
|
42
|
+
/** `engine` types (#38) are drawn by a provider's runtime; served from the catalog release. */
|
|
43
|
+
runtime?: 'code' | 'engine';
|
|
44
|
+
/** Frameworks it can be added for, when not every one. */
|
|
45
|
+
frameworks?: PlatformLanguage[];
|
|
38
46
|
}
|
|
39
47
|
|
|
40
48
|
export { DEFAULT_REGISTRY_URL, type RegistryIndexItem, type RegistryItem, type RegistryItemFile };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by packages/catalog/scripts/sync-providers.ts from @pixerate/editor 0.336.0 (bar-chart). Do not edit.
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { uiComponents } from '@pixerate/editor/chart';
|
|
4
|
-
import { useRoleColors } from '
|
|
4
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
5
5
|
|
|
6
6
|
const ROLES = ['surface', 'ink', 'ink-muted', 'border', 'accent'] as const;
|
|
7
7
|
const COMPONENT = uiComponents().find((c) => c.id === 'bar-chart')!;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { uiComponents } from '@pixerate/editor/chart';
|
|
4
4
|
import { createLinkFocus } from '@pixerate/editor/tools';
|
|
5
|
-
import { useRoleColors } from '
|
|
5
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
6
6
|
|
|
7
7
|
const ROLES = ['surface', 'ink', 'accent'] as const;
|
|
8
8
|
const COMPONENT = uiComponents().find((c) => c.id === 'braid')!;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by packages/catalog/scripts/sync-providers.ts from @pixerate/editor 0.336.0 (donut-chart). Do not edit.
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { uiComponents } from '@pixerate/editor/chart';
|
|
4
|
-
import { useRoleColors } from '
|
|
4
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
5
5
|
|
|
6
6
|
const ROLES = ['surface', 'ink', 'accent'] as const;
|
|
7
7
|
const COMPONENT = uiComponents().find((c) => c.id === 'donut-chart')!;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by packages/catalog/scripts/sync-providers.ts from @pixerate/editor 0.336.0 (flow). Do not edit.
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { diagramUiComponents } from '@pixerate/editor/canvas';
|
|
4
|
-
import { useRoleColors } from '
|
|
4
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
5
5
|
|
|
6
6
|
const ROLES = ['surface', 'surface-raised', 'ink', 'ink-muted', 'border', 'accent'] as const;
|
|
7
7
|
const COMPONENT = diagramUiComponents().find((c) => c.id === 'flow')!;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by packages/catalog/scripts/sync-providers.ts from @pixerate/flair 0.121.0 (gauge). Do not edit.
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { FlairEffect } from '@pixerate/flair/react';
|
|
4
|
-
import { useRoleColors } from '
|
|
4
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
5
5
|
|
|
6
6
|
const ROLES = ['success', 'warning', 'danger', 'accent', 'surface', 'ink'] as const;
|
|
7
7
|
const CONTROLS: Record<string, string> = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by packages/catalog/scripts/sync-providers.ts from @pixerate/editor 0.336.0 (line-chart). Do not edit.
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { uiComponents } from '@pixerate/editor/chart';
|
|
4
|
-
import { useRoleColors } from '
|
|
4
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
5
5
|
|
|
6
6
|
const ROLES = ['surface', 'ink', 'ink-muted', 'border', 'accent'] as const;
|
|
7
7
|
const COMPONENT = uiComponents().find((c) => c.id === 'line-chart')!;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { uiComponents } from '@pixerate/editor/chart';
|
|
4
4
|
import { createLinkFocus } from '@pixerate/editor/tools';
|
|
5
|
-
import { useRoleColors } from '
|
|
5
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
6
6
|
|
|
7
7
|
const ROLES = ['surface', 'ink', 'ink-muted', 'accent'] as const;
|
|
8
8
|
const COMPONENT = uiComponents().find((c) => c.id === 'lineage')!;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by packages/catalog/scripts/sync-providers.ts from @pixerate/editor 0.336.0 (mindmap). Do not edit.
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { diagramUiComponents } from '@pixerate/editor/canvas';
|
|
4
|
-
import { useRoleColors } from '
|
|
4
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
5
5
|
|
|
6
6
|
const ROLES = ['surface', 'surface-raised', 'ink', 'ink-muted', 'border', 'accent'] as const;
|
|
7
7
|
const COMPONENT = diagramUiComponents().find((c) => c.id === 'mindmap')!;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by packages/catalog/scripts/sync-providers.ts from @pixerate/editor 0.336.0 (sparkline). Do not edit.
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { uiComponents } from '@pixerate/editor/chart';
|
|
4
|
-
import { useRoleColors } from '
|
|
4
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
5
5
|
|
|
6
6
|
const ROLES = ['accent'] as const;
|
|
7
7
|
const COMPONENT = uiComponents().find((c) => c.id === 'sparkline')!;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by packages/catalog/scripts/sync-providers.ts from @pixerate/editor 0.336.0 (timeline). Do not edit.
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { diagramUiComponents } from '@pixerate/editor/canvas';
|
|
4
|
-
import { useRoleColors } from '
|
|
4
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
5
5
|
|
|
6
6
|
const ROLES = ['surface', 'surface-raised', 'ink', 'ink-muted', 'border', 'accent'] as const;
|
|
7
7
|
const COMPONENT = diagramUiComponents().find((c) => c.id === 'timeline')!;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { uiComponents } from '@pixerate/editor/chart';
|
|
4
4
|
import { createLinkFocus } from '@pixerate/editor/tools';
|
|
5
|
-
import { useRoleColors } from '
|
|
5
|
+
import { useRoleColors } from '@surreal-ui/catalog/react';
|
|
6
6
|
|
|
7
7
|
const ROLES = ['surface', 'surface-raised', 'ink', 'ink-muted', 'border', 'accent'] as const;
|
|
8
8
|
const COMPONENT = uiComponents().find((c) => c.id === 'weave')!;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@surreal-ui/catalog",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.13.0",
|
|
4
4
|
"description": "Drop-in UI components with a catalog API and aesthetic packs: one implementation per component type, restyled by aesthetics defined as skills.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Pixerate",
|