@accelint/design-system 0.5.0 → 0.5.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.
|
@@ -42,6 +42,7 @@ declare const TextField: (props: {
|
|
|
42
42
|
maxLength?: number | undefined;
|
|
43
43
|
minLength?: number | undefined;
|
|
44
44
|
pattern?: string | undefined;
|
|
45
|
+
enterKeyHint?: ("enter" | "done" | "go" | "next" | "previous" | "search" | "send") | undefined;
|
|
45
46
|
inputMode?: ("none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | "search") | undefined;
|
|
46
47
|
'aria-activedescendant'?: string | undefined;
|
|
47
48
|
'aria-autocomplete'?: ("none" | "inline" | "list" | "both") | undefined;
|
|
@@ -6,7 +6,7 @@ import { TooltipClassNames, TooltipMapping, TooltipRenderProps, TooltipProps, To
|
|
|
6
6
|
import 'type-fest';
|
|
7
7
|
|
|
8
8
|
declare const TooltipContext: react.Context<ContextValue<TooltipProps, HTMLDivElement>>;
|
|
9
|
-
declare const Tooltip: (props: Omit<react_aria_components.TooltipProps, "className" | "style" | "UNSTABLE_portalContainer"> & {
|
|
9
|
+
declare const Tooltip: (props: Omit<react_aria_components.TooltipProps, "children" | "className" | "style" | "UNSTABLE_portalContainer"> & {
|
|
10
10
|
classNames?: TooltipClassNames;
|
|
11
11
|
mapping?: Partial<TooltipMapping>;
|
|
12
12
|
} & {
|
|
@@ -35,7 +35,7 @@ type BaseTooltipTargetProps = BaseProps & {
|
|
|
35
35
|
};
|
|
36
36
|
type TooltipState = Omit<TooltipRenderProps, 'state'> & Required<Pick<TooltipProps$1, 'containerPadding' | 'crossOffset' | 'offset'>>;
|
|
37
37
|
type TooltipTargetState = Required<Pick<BaseTooltipTargetProps, 'focusable' | 'relative'>>;
|
|
38
|
-
type TooltipProps = Omit<TooltipProps$1, 'className' | 'style' | 'UNSTABLE_portalContainer'> & BaseTooltipProps;
|
|
38
|
+
type TooltipProps = Omit<TooltipProps$1, 'children' | 'className' | 'style' | 'UNSTABLE_portalContainer'> & BaseTooltipProps;
|
|
39
39
|
type TooltipTargetProps = PropsWithChildren<BaseTooltipTargetProps>;
|
|
40
40
|
|
|
41
41
|
export type { TooltipClassNames, TooltipMapping, TooltipProps, TooltipRenderProps, TooltipState, TooltipTargetProps, TooltipTargetState };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../node_modules/.pnpm/@ladle+react@4.1.2_@swc+helpers@0.5.15_@types+node@20.17.
|
|
1
|
+
{"version":3,"sources":["../../../../node_modules/.pnpm/@ladle+react@4.1.2_@swc+helpers@0.5.15_@types+node@20.17.23_@types+react@18.3.11_acorn@8.14.1_g6k2l37snfpgbjzqau27fi7cty/node_modules/@ladle/react/lib/app/exports.ts","../../src/ladle/actions.ts"],"names":[],"mappings":";;;;;;AA+CO,IAAM,MAAA,GAAS,CAAC,IAAiB,KAAA;AACtC,EAAA,MAAM,WAAY,MACf,CAAA,aAAA;AACH,EAAO,OAAA,CAAC,KAAa,GAAA,MAAA,KACnB,QAAS,CAAA;AAAA,IACP,MAAM,UAAW,CAAA,YAAA;AAAA,IACjB,KAAA,EAAO,EAAE,IAAA,EAAM,KAAM,EAAA;AAAA,IACrB,KAAO,EAAA;AAAA,GACR,CAAA;AACL,CAAA;;;ACtDO,SAAS,WAAc,IAA+B,EAAA;AAC3D,EAAA,OAAO,IAAK,CAAA,MAAA,CAAmB,CAAC,GAAA,EAAK,GAAQ,KAAA;AAC3C,IAAI,GAAA,CAAA,GAAG,CAAI,GAAA,MAAA,CAAO,GAAa,CAAA;AAE/B,IAAO,OAAA,GAAA;AAAA,GACT,EAAG,EAAE,CAAA;AACP","file":"actions.js","sourcesContent":["import type * as React from \"react\";\nimport { useLadleContext } from \"./src/context\";\nimport {\n StoryDecorator,\n ActionType,\n GlobalState,\n ThemeState,\n ModeState,\n GlobalAction,\n Config,\n KnownMeta,\n MetaJson as BaseMetaJson,\n MetaJsonStory as BaseMetaJsonStory,\n} from \"../shared/types\";\n\nimport * as msw from \"msw\";\nexport { msw };\n\nexport type { UserConfig } from \"../shared/types\";\nexport { useMDXComponents } from \"@mdx-js/react\";\nexport const Story = (props: any) => props.children;\nexport const Meta = (props: any) => props.children;\nexport const Description = (props: any) => props.children;\n\ntype ReactNodeWithoutObject =\n | React.ReactElement\n | string\n | number\n | boolean\n | null\n | undefined;\n\nexport { useLadleContext, ActionType, ThemeState, ModeState };\nexport type { StoryDecorator };\n\n// deprecated, linkTo is just easier to use\nexport const useLink = () => {\n const { dispatch } = useLadleContext();\n return (value: string) => dispatch({ type: ActionType.UpdateStory, value });\n};\n\nexport const linkTo = (value: string) => {\n const dispatch = (window as any)\n .ladleDispatch as React.Dispatch<GlobalAction>;\n return () => dispatch({ type: ActionType.UpdateStory, value });\n};\n\nexport const action = (name: string) => {\n const dispatch = (window as any)\n .ladleDispatch as React.Dispatch<GlobalAction>;\n return (event: any = undefined) =>\n dispatch({\n type: ActionType.UpdateAction,\n value: { name, event },\n clear: false,\n });\n};\n\nexport type GlobalProvider = React.FC<{\n globalState: GlobalState;\n dispatch: React.Dispatch<GlobalAction>;\n config: Config;\n children: ReactNodeWithoutObject;\n storyMeta?: Meta;\n}>;\n\nexport type SourceHeader = React.FC<{\n path: string;\n locStart: number;\n locEnd: number;\n}>;\n\nexport interface StoryDefault<P = {}> {\n args?: Args<P>;\n argTypes?: ArgTypes<P>;\n decorators?: StoryDecorator<P>[];\n meta?: Meta;\n title?: string;\n msw?: msw.RequestHandler[];\n parameters?: { [key: string]: any };\n}\n\nexport interface Story<P = {}> extends React.FC<P> {\n args?: Args<P>;\n argTypes?: ArgTypes<P>;\n decorators?: StoryDecorator<P>[];\n meta?: Meta;\n storyName?: string;\n msw?: msw.RequestHandler[];\n parameters?: { [key: string]: any };\n}\n\nexport type Args<\n P = {\n [key: string]: any;\n },\n> = Partial<P>;\n\nexport type ControlType =\n | \"select\"\n | \"multi-select\"\n | \"radio\"\n | \"inline-radio\"\n | \"check\"\n | \"inline-check\"\n | \"background\"\n | \"color\"\n | \"date\"\n | \"number\"\n | \"text\"\n | \"boolean\"\n | \"range\";\n\nexport interface ArgType<K = any> {\n control?: {\n name?: string;\n labels?: { [key: string]: string };\n type: ControlType;\n min?: number;\n max?: number;\n step?: number;\n [key: string]: any;\n };\n mapping?: { [key: string | number]: any };\n options?: K[] | unknown;\n defaultValue?: K;\n description?: string;\n name?: string;\n action?: string;\n [key: string]: any;\n}\n\nexport type ArgTypes<\n P = {\n [key: string]: any;\n },\n> = {\n [key in keyof P]?: ArgType<P[key]>;\n};\n\nexport interface Meta extends KnownMeta {\n [key: string]: any;\n}\n\nexport type MetaJson = BaseMetaJson<Meta>;\nexport type MetaJsonStory = BaseMetaJsonStory<Meta>;\n","import { action } from '@ladle/react';\n\nexport function actions<T>(...keys: (keyof T)[]): Partial<T> {\n return keys.reduce<Partial<T>>((acc, key) => {\n acc[key] = action(key as string) as T[keyof T];\n\n return acc;\n }, {});\n}\n"]}
|
package/dist/test/setup.js
CHANGED
|
@@ -3955,7 +3955,7 @@ if (typeof process === "undefined" || !process.env?.RTL_SKIP_AUTO_CLEANUP) {
|
|
|
3955
3955
|
}
|
|
3956
3956
|
}
|
|
3957
3957
|
|
|
3958
|
-
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.
|
|
3958
|
+
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.23_jsdom@25.0.1_msw@2.7.3_@types+node@20.17.23_typescript@5.6.3__terser@5.39.0/node_modules/vitest/dist/chunks/utils.Ck2hJTRs.js
|
|
3959
3959
|
function getWorkerState() {
|
|
3960
3960
|
const workerState = globalThis.__vitest_worker__;
|
|
3961
3961
|
if (!workerState) {
|
|
@@ -3969,7 +3969,7 @@ function getCurrentEnvironment() {
|
|
|
3969
3969
|
return state?.environment.name;
|
|
3970
3970
|
}
|
|
3971
3971
|
|
|
3972
|
-
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.
|
|
3972
|
+
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.23_jsdom@25.0.1_msw@2.7.3_@types+node@20.17.23_typescript@5.6.3__terser@5.39.0/node_modules/vitest/dist/chunks/index.CxRxs566.js
|
|
3973
3973
|
function getRunMode() {
|
|
3974
3974
|
return getWorkerState().config.mode;
|
|
3975
3975
|
}
|
|
@@ -3977,7 +3977,7 @@ function isRunningInBenchmark() {
|
|
|
3977
3977
|
return getRunMode() === "benchmark";
|
|
3978
3978
|
}
|
|
3979
3979
|
|
|
3980
|
-
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.
|
|
3980
|
+
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.23_jsdom@25.0.1_msw@2.7.3_@types+node@20.17.23_typescript@5.6.3__terser@5.39.0/node_modules/vitest/dist/chunks/benchmark.C8CRJYG4.js
|
|
3981
3981
|
var benchFns = /* @__PURE__ */ new WeakMap();
|
|
3982
3982
|
var benchOptsMap = /* @__PURE__ */ new WeakMap();
|
|
3983
3983
|
var bench = createBenchmark(function(name, fn2 = noop, options = {}) {
|
|
@@ -4006,7 +4006,7 @@ function formatName(name) {
|
|
|
4006
4006
|
return typeof name === "string" ? name : name instanceof Function ? name.name || "<anonymous>" : String(name);
|
|
4007
4007
|
}
|
|
4008
4008
|
|
|
4009
|
-
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.
|
|
4009
|
+
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.23_jsdom@25.0.1_msw@2.7.3_@types+node@20.17.23_typescript@5.6.3__terser@5.39.0/node_modules/vitest/dist/chunks/run-once.Sxe67Wng.js
|
|
4010
4010
|
var filesCount = /* @__PURE__ */ new Map();
|
|
4011
4011
|
var cache = /* @__PURE__ */ new Map();
|
|
4012
4012
|
function runOnce(fn2, key) {
|
|
@@ -4029,7 +4029,7 @@ function isFirstRun() {
|
|
|
4029
4029
|
return firstRun;
|
|
4030
4030
|
}
|
|
4031
4031
|
|
|
4032
|
-
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.
|
|
4032
|
+
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.23_jsdom@25.0.1_msw@2.7.3_@types+node@20.17.23_typescript@5.6.3__terser@5.39.0/node_modules/vitest/dist/chunks/_commonjsHelpers.BFTU3MAI.js
|
|
4033
4033
|
var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
|
|
4034
4034
|
function getDefaultExportFromCjs(x) {
|
|
4035
4035
|
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
@@ -4041,7 +4041,7 @@ function isChildProcess() {
|
|
|
4041
4041
|
return typeof process !== "undefined" && !!process.send;
|
|
4042
4042
|
}
|
|
4043
4043
|
|
|
4044
|
-
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.
|
|
4044
|
+
// ../../node_modules/.pnpm/vitest@2.1.3_@types+node@20.17.23_jsdom@25.0.1_msw@2.7.3_@types+node@20.17.23_typescript@5.6.3__terser@5.39.0/node_modules/vitest/dist/chunks/date.W2xKR2qe.js
|
|
4045
4045
|
var RealDate = Date;
|
|
4046
4046
|
var now = null;
|
|
4047
4047
|
var MockDate = class _MockDate extends RealDate {
|