@lazar-ui/kit 0.6.0 → 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/CHANGELOG.md +21 -0
- package/dist/accordion.js +1 -1
- package/dist/breadcrumbs.js +1 -1
- package/dist/checkbox.css +1 -0
- package/dist/checkbox.d.ts +35 -10
- package/dist/checkbox.js +40 -2
- package/dist/dialog.css +1 -1
- package/dist/dialog.js +44 -37
- package/dist/drawer.css +1 -1
- package/dist/drawer.js +93 -72
- package/dist/empty-state.css +1 -1
- package/dist/empty-state.js +48 -29
- package/dist/{getComponentSlots-DD4iju8N.mjs → getComponentSlots-DwAYUFNk.mjs} +1 -1
- package/dist/getDecorationStyle-BCBONKEl.mjs +7 -0
- package/dist/heading.js +31 -5
- package/dist/input.js +124 -86
- package/dist/isValidReactNode-CmYwTWCE.mjs +18 -0
- package/dist/menu.css +1 -1
- package/dist/menu.js +103 -46
- package/dist/pagination.js +60 -48
- package/dist/radio.css +1 -1
- package/dist/radio.js +98 -42
- package/dist/table.css +1 -1
- package/dist/table.js +74 -25
- package/dist/tabs.css +1 -1
- package/dist/tabs.js +72 -30
- package/dist/text.js +48 -6
- package/dist/utils.d.ts +75 -2
- package/dist/utils.js +17 -14
- package/package.json +1 -1
- package/dist/Actions-CEIXfLKN.mjs +0 -26
- package/dist/Actions.css +0 -1
- package/dist/ActiveFilters-BJojmc-d.mjs +0 -29
- package/dist/ActiveFilters.css +0 -1
- package/dist/Cell-BPBvEyeL.mjs +0 -21
- package/dist/Cell.css +0 -1
- package/dist/Checkbox-Chfzm1Z9.mjs +0 -46
- package/dist/Checkbox.css +0 -1
- package/dist/Content-ru2X8iBx.mjs +0 -13
- package/dist/Content.css +0 -1
- package/dist/Group-DyDpeqOP.mjs +0 -16
- package/dist/Group.css +0 -1
- package/dist/Header-Clhgyr0J.mjs +0 -29
- package/dist/Header.css +0 -1
- package/dist/Heading-CL47Fqe7.mjs +0 -30
- package/dist/InputBase-BHZWQT9-.mjs +0 -46
- package/dist/Item-JbyvZy05.mjs +0 -66
- package/dist/Item.css +0 -1
- package/dist/Panel-Q06TIYep.mjs +0 -12
- package/dist/Provider-CBfZpO45.mjs +0 -12
- package/dist/Row-C-3TXoDz.mjs +0 -15
- package/dist/Row.css +0 -1
- package/dist/Tab-CR0KvVaA.mjs +0 -39
- package/dist/Tab.css +0 -1
- package/dist/Text-DiOqZt8E.mjs +0 -49
- package/dist/Title-aOeFD24v.mjs +0 -13
- package/dist/Title.css +0 -1
- package/dist/Toolbar-BJQy4qFI.mjs +0 -11
- package/dist/Toolbar.css +0 -1
- package/dist/Trigger-C_4De6l1.mjs +0 -11
- package/dist/actions.d.ts +0 -13
- package/dist/actions.js +0 -4
- package/dist/active-filters.d.ts +0 -35
- package/dist/active-filters.js +0 -4
- package/dist/cell.d.ts +0 -20
- package/dist/cell.js +0 -4
- package/dist/content.d.ts +0 -8
- package/dist/content.js +0 -4
- package/dist/context.d.ts +0 -44
- package/dist/context.js +0 -7
- package/dist/enums-BnuDYTua.mjs +0 -4
- package/dist/enums-CiPhZomh.mjs +0 -6
- package/dist/enums-DUZMBQDd.mjs +0 -7
- package/dist/group.d.ts +0 -12
- package/dist/group.js +0 -4
- package/dist/header.d.ts +0 -21
- package/dist/header.js +0 -4
- package/dist/input-base.d.ts +0 -29
- package/dist/input-base.js +0 -4
- package/dist/isValidReactNode-D1buElhX.mjs +0 -17
- package/dist/item.d.ts +0 -16
- package/dist/item.js +0 -4
- package/dist/panel.d.ts +0 -9
- package/dist/panel.js +0 -4
- package/dist/row.d.ts +0 -12
- package/dist/row.js +0 -4
- package/dist/tab.d.ts +0 -30
- package/dist/tab.js +0 -4
- package/dist/title.d.ts +0 -8
- package/dist/title.js +0 -4
- package/dist/toolbar.d.ts +0 -20
- package/dist/toolbar.js +0 -4
- package/dist/trigger.d.ts +0 -8
- package/dist/trigger.js +0 -4
- package/dist/typography.d.ts +0 -126
- package/dist/typography.js +0 -6
- package/dist/useTabsContext-DdF09jQq.mjs +0 -11
- /package/dist/{Heading.css → heading.css} +0 -0
- /package/dist/{InputBase.css → input.css} +0 -0
- /package/dist/{Text.css → text.css} +0 -0
package/dist/Title.css
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
._root_1ae0y_1{color:var(--dialog-title-color);font-family:var(--dialog-title-font-family);font-size:var(--dialog-title-font-size);font-style:normal;font-weight:var(--dialog-title-weight);line-height:var(--dialog-title-line-height);max-height:100%}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import './Toolbar.css';const r = "Table.Toolbar", a = "_root_d4szt_6", c = {
|
|
3
|
-
root: a
|
|
4
|
-
}, e = (o) => {
|
|
5
|
-
const { children: t } = o;
|
|
6
|
-
return /* @__PURE__ */ s("div", { className: c.root, children: t });
|
|
7
|
-
};
|
|
8
|
-
e.displayName = r;
|
|
9
|
-
export {
|
|
10
|
-
e as T
|
|
11
|
-
};
|
package/dist/Toolbar.css
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
:root{--toolbar-gap: var(--lui-space-3);--toolbar-padding: var(--lui-space-3) 0}._root_d4szt_6{align-items:center;display:flex;gap:var(--toolbar-gap);padding:var(--toolbar-padding)}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { jsx as p } from "react/jsx-runtime";
|
|
2
|
-
import { usePopoverContext as a } from "./popover.js";
|
|
3
|
-
import { E as n } from "./enums-DUZMBQDd.mjs";
|
|
4
|
-
const s = (e) => {
|
|
5
|
-
const { children: o } = e, { triggerRef: t, state: r } = a();
|
|
6
|
-
return /* @__PURE__ */ p("span", { "aria-expanded": r.isOpen, "aria-haspopup": "true", onClick: () => r.toggle(), ref: t, children: o });
|
|
7
|
-
};
|
|
8
|
-
s.displayName = n.TRIGGER;
|
|
9
|
-
export {
|
|
10
|
-
s as T
|
|
11
|
-
};
|
package/dist/actions.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Wrapper for action buttons inside EmptyState.
|
|
5
|
-
* Accepts only `<Button>` components as children.
|
|
6
|
-
* Auto-assigns variant based on position:
|
|
7
|
-
* - first child → `primary`
|
|
8
|
-
* - subsequent children → `secondary`
|
|
9
|
-
* unless the Button already has an explicit `variant` prop.
|
|
10
|
-
*/
|
|
11
|
-
export declare const Actions: default_2.FC<default_2.PropsWithChildren>;
|
|
12
|
-
|
|
13
|
-
export { }
|
package/dist/actions.js
DELETED
package/dist/active-filters.d.ts
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Table.ActiveFilters — displays active filter chips with individual remove buttons
|
|
5
|
-
* and an optional "Clear all" button.
|
|
6
|
-
*
|
|
7
|
-
* Returns `null` when there are no active filters.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```tsx
|
|
11
|
-
* <Table.ActiveFilters
|
|
12
|
-
* filters={[
|
|
13
|
-
* { key: 'status', label: 'Status', value: 'Active' },
|
|
14
|
-
* { key: 'role', label: 'Role', value: 'Admin' },
|
|
15
|
-
* ]}
|
|
16
|
-
* onRemove={(key) => console.log('remove', key)}
|
|
17
|
-
* onClearAll={() => console.log('clear all')}
|
|
18
|
-
* />
|
|
19
|
-
* ```
|
|
20
|
-
*/
|
|
21
|
-
export declare const ActiveFilters: default_2.FC<IActiveFiltersProps>;
|
|
22
|
-
|
|
23
|
-
export declare interface IActiveFiltersProps {
|
|
24
|
-
filters: IFilterItem[];
|
|
25
|
-
onRemove: (key: string) => void;
|
|
26
|
-
onClearAll?: () => void;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export declare interface IFilterItem {
|
|
30
|
-
key: string;
|
|
31
|
-
label: string;
|
|
32
|
-
value: string;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
export { }
|
package/dist/active-filters.js
DELETED
package/dist/cell.d.ts
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Table cell. Must be used as a child of `<Table.Row>`.
|
|
5
|
-
* Supports text alignment and header styling via `as="th"`.
|
|
6
|
-
*/
|
|
7
|
-
export declare const Cell: default_2.FC<IProps>;
|
|
8
|
-
|
|
9
|
-
declare interface IProps extends default_2.PropsWithChildren {
|
|
10
|
-
/** Text alignment. */
|
|
11
|
-
align?: 'left' | 'center' | 'right';
|
|
12
|
-
/** HTML tag: `'td'` (default) or `'th'`. */
|
|
13
|
-
as?: 'td' | 'th';
|
|
14
|
-
/** Tooltip text (native `title` attribute). */
|
|
15
|
-
title?: string;
|
|
16
|
-
/** Cell width. */
|
|
17
|
-
width?: string;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export { }
|
package/dist/cell.js
DELETED
package/dist/content.d.ts
DELETED
package/dist/content.js
DELETED
package/dist/context.d.ts
DELETED
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import { Context as Context_2 } from 'react';
|
|
2
|
-
import { default as default_2 } from 'react';
|
|
3
|
-
|
|
4
|
-
export declare const Context: Context_2<IContext | null>;
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Enumerates the variants of a Tabs component.
|
|
8
|
-
*/
|
|
9
|
-
declare enum ETabsVariant {
|
|
10
|
-
/** Tabs are displayed as toggle buttons. */
|
|
11
|
-
BUTTONS = "buttons",
|
|
12
|
-
/** Default display of Tabs. */
|
|
13
|
-
DEFAULT = "default"
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Tabs Context.
|
|
18
|
-
*/
|
|
19
|
-
declare interface IContext {
|
|
20
|
-
/** Index of current active tab. */
|
|
21
|
-
activeIndex: number;
|
|
22
|
-
/** Base ID for generating IDs for ARIA. */
|
|
23
|
-
baseId: string;
|
|
24
|
-
/** Active tab change handler. */
|
|
25
|
-
setActiveTab: (index: number) => void;
|
|
26
|
-
/** Get panel ID. */
|
|
27
|
-
getPanelId: (index: number) => string;
|
|
28
|
-
/** Get tab ID. */
|
|
29
|
-
getTabId: (index: number) => string;
|
|
30
|
-
/** Variant. */
|
|
31
|
-
variant: ETabsVariant;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
declare interface IProps extends default_2.PropsWithChildren {
|
|
35
|
-
defaultActiveIndex?: number;
|
|
36
|
-
onTabChange?: (index: number) => void;
|
|
37
|
-
variant: ETabsVariant;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
export declare const Provider: default_2.FC<IProps>;
|
|
41
|
-
|
|
42
|
-
export declare const useTabsContext: () => IContext;
|
|
43
|
-
|
|
44
|
-
export { }
|
package/dist/context.js
DELETED
package/dist/enums-BnuDYTua.mjs
DELETED
package/dist/enums-CiPhZomh.mjs
DELETED
package/dist/enums-DUZMBQDd.mjs
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
const a = "Menu", t = "bottom start";
|
|
2
|
-
var T = ((r) => (r.CHECKBOX = `${a}.Checkbox`, r.CONTENT = `${a}.Content`, r.GROUP = `${a}.Group`, r.ITEM = `${a}.Item`, r.SEPARATOR = `${a}.Separator`, r.TRIGGER = `${a}.Trigger`, r))(T || {});
|
|
3
|
-
export {
|
|
4
|
-
t as D,
|
|
5
|
-
T as E,
|
|
6
|
-
a
|
|
7
|
-
};
|
package/dist/group.d.ts
DELETED
package/dist/group.js
DELETED
package/dist/header.d.ts
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Drawer Header sub-component.
|
|
5
|
-
*
|
|
6
|
-
* Renders the title and a close button.
|
|
7
|
-
* Must be used within a Drawer component.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```tsx
|
|
11
|
-
* <Drawer.Header>
|
|
12
|
-
* Drawer Title
|
|
13
|
-
* </Drawer.Header>
|
|
14
|
-
* ```
|
|
15
|
-
*/
|
|
16
|
-
export declare const Header: default_2.FC<IHeaderProps>;
|
|
17
|
-
|
|
18
|
-
export declare interface IHeaderProps extends default_2.PropsWithChildren {
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export { }
|
package/dist/header.js
DELETED
package/dist/input-base.d.ts
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
export declare interface IInputProps extends Omit<default_2.InputHTMLAttributes<HTMLInputElement>, 'prefix' | 'suffix' | 'size' | 'onChange' | 'onBlur' | 'onFocus'> {
|
|
4
|
-
ref?: default_2.Ref<HTMLInputElement>;
|
|
5
|
-
invalid?: boolean;
|
|
6
|
-
size?: TInputSize;
|
|
7
|
-
before?: default_2.ReactNode;
|
|
8
|
-
after?: default_2.ReactNode;
|
|
9
|
-
onChange?: (value: string) => void;
|
|
10
|
-
onBlur?: (e: default_2.FocusEvent<HTMLInputElement>) => void;
|
|
11
|
-
onFocus?: (e: default_2.FocusEvent<HTMLInputElement>) => void;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* Base Input component. Renders a native `<input>` with support for `before`/`after` slots, sizing, and invalid/disabled states.
|
|
16
|
-
* All native `<input>` attributes are passed through automatically.
|
|
17
|
-
*
|
|
18
|
-
* @example
|
|
19
|
-
* ```tsx
|
|
20
|
-
* <Input placeholder="Enter text" />
|
|
21
|
-
* <Input size="lg" invalid placeholder="Error" />
|
|
22
|
-
* <Input before={<SearchIcon />} placeholder="Search" />
|
|
23
|
-
* ```
|
|
24
|
-
*/
|
|
25
|
-
export declare const Input: default_2.FC<IInputProps>;
|
|
26
|
-
|
|
27
|
-
declare type TInputSize = 'sm' | 'md' | 'lg';
|
|
28
|
-
|
|
29
|
-
export { }
|
package/dist/input-base.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { isValidElement as y } from "react";
|
|
2
|
-
const c = (t) => t.type ? typeof t.type == "string" ? t.type : "displayName" in t.type ? t.type.displayName : t.type.name : "", r = (t, i) => t === i, n = (t, i, o = !0) => {
|
|
3
|
-
const s = Array.isArray(t);
|
|
4
|
-
let a = !1;
|
|
5
|
-
if (y(i)) {
|
|
6
|
-
const e = c(i);
|
|
7
|
-
s ? a = t.some((p) => r(p, e)) : a = r(t, e);
|
|
8
|
-
}
|
|
9
|
-
if (!a && o) {
|
|
10
|
-
let e = t;
|
|
11
|
-
s && (e = t.join(", ")), console.warn("Invalid React node. Node should be an instance of %s", e);
|
|
12
|
-
}
|
|
13
|
-
return a;
|
|
14
|
-
};
|
|
15
|
-
export {
|
|
16
|
-
n as i
|
|
17
|
-
};
|
package/dist/item.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
export declare interface IItemProps extends TNativeInputProps, default_2.PropsWithChildren {
|
|
4
|
-
/** The value of the radio button. Required for group integration. */
|
|
5
|
-
value: string;
|
|
6
|
-
/** Description text displayed below the option label. */
|
|
7
|
-
description?: default_2.ReactNode;
|
|
8
|
-
/** Ref to the native input element. */
|
|
9
|
-
ref?: default_2.Ref<HTMLInputElement>;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
export declare const Item: default_2.FC<IItemProps>;
|
|
13
|
-
|
|
14
|
-
declare type TNativeInputProps = Omit<default_2.InputHTMLAttributes<HTMLInputElement>, 'type' | 'name' | 'checked' | 'size' | 'className'>;
|
|
15
|
-
|
|
16
|
-
export { }
|
package/dist/item.js
DELETED
package/dist/panel.d.ts
DELETED
package/dist/panel.js
DELETED
package/dist/row.d.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
declare interface IProps extends default_2.PropsWithChildren {
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Table row. Must be used as a child of `<Table>`.
|
|
8
|
-
* Accepts `<Table.Cell>` children.
|
|
9
|
-
*/
|
|
10
|
-
export declare const Row: default_2.FC<IProps>;
|
|
11
|
-
|
|
12
|
-
export { }
|
package/dist/row.js
DELETED
package/dist/tab.d.ts
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
export declare interface ITabProps {
|
|
4
|
-
/** Index at list of tabs. */
|
|
5
|
-
index?: number;
|
|
6
|
-
/** Disabled tab flag. */
|
|
7
|
-
disabled?: boolean;
|
|
8
|
-
/** Label. */
|
|
9
|
-
label: string;
|
|
10
|
-
/** HTML tabindex attribute. */
|
|
11
|
-
tabIndex?: number;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* Individual tab button. Must be used as a child of `<Tabs>`.
|
|
16
|
-
*
|
|
17
|
-
* Manages its active/disabled state via parent context and sets proper ARIA attributes (`role="tab"`, `aria-selected`, `aria-controls`).
|
|
18
|
-
*
|
|
19
|
-
* @example
|
|
20
|
-
* ```tsx
|
|
21
|
-
* <Tabs defaultActiveIndex={0}>
|
|
22
|
-
* <Tabs.Tab label="First" />
|
|
23
|
-
* <Tabs.Tab label="Second" disabled />
|
|
24
|
-
* <Tabs.Tab label="Third" />
|
|
25
|
-
* </Tabs>
|
|
26
|
-
* ```
|
|
27
|
-
*/
|
|
28
|
-
export declare const Tab: default_2.FC<ITabProps>;
|
|
29
|
-
|
|
30
|
-
export { }
|
package/dist/tab.js
DELETED
package/dist/title.d.ts
DELETED
package/dist/title.js
DELETED
package/dist/toolbar.d.ts
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
export declare interface IToolbarProps extends default_2.PropsWithChildren {
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Table.Toolbar — a simple flex-wrapper that sits above the Table
|
|
8
|
-
* and contains arbitrary controls (inputs, buttons, filters, etc.).
|
|
9
|
-
*
|
|
10
|
-
* @example
|
|
11
|
-
* ```tsx
|
|
12
|
-
* <Table.Toolbar>
|
|
13
|
-
* <Input placeholder="Search..." />
|
|
14
|
-
* <Button>Export</Button>
|
|
15
|
-
* </Table.Toolbar>
|
|
16
|
-
* ```
|
|
17
|
-
*/
|
|
18
|
-
export declare const Toolbar: default_2.FC<IToolbarProps>;
|
|
19
|
-
|
|
20
|
-
export { }
|
package/dist/toolbar.js
DELETED
package/dist/trigger.d.ts
DELETED
package/dist/trigger.js
DELETED
package/dist/typography.d.ts
DELETED
|
@@ -1,126 +0,0 @@
|
|
|
1
|
-
import { default as default_2 } from 'react';
|
|
2
|
-
|
|
3
|
-
declare enum EHeadingColor {
|
|
4
|
-
PRIMARY = "primary",
|
|
5
|
-
SECONDARY = "secondary",
|
|
6
|
-
TERTIARY = "tertiary",
|
|
7
|
-
DISABLED = "disabled",
|
|
8
|
-
BRAND = "brand"
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
declare enum EHeadingSize {
|
|
12
|
-
XS = "xs",
|
|
13
|
-
SM = "sm",
|
|
14
|
-
MD = "md",
|
|
15
|
-
LG = "lg"
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
declare enum ETextColor {
|
|
19
|
-
PRIMARY = "primary",
|
|
20
|
-
SECONDARY = "secondary",
|
|
21
|
-
TERTIARY = "tertiary",
|
|
22
|
-
DISABLED = "disabled",
|
|
23
|
-
BRAND = "brand"
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
declare enum ETextSize {
|
|
27
|
-
XS = "xs",
|
|
28
|
-
SM = "sm",
|
|
29
|
-
MD = "md",
|
|
30
|
-
LG = "lg"
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
declare enum ETextWeight {
|
|
34
|
-
NORMAL = "normal",
|
|
35
|
-
MEDIUM = "medium",
|
|
36
|
-
SEMIBOLD = "semibold",
|
|
37
|
-
BOLD = "bold"
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
/**
|
|
41
|
-
* Heading component. Renders a semantic HTML heading (`h1`–`h6`) with preset
|
|
42
|
-
* font-size, font-weight, line-height, and optional letter-spacing.
|
|
43
|
-
*
|
|
44
|
-
* Each size maps to a predefined set of CSS tokens for consistent typography across the UI.
|
|
45
|
-
*
|
|
46
|
-
* @example
|
|
47
|
-
* ```tsx
|
|
48
|
-
* <Heading as="h1" size="lg">Page title</Heading>
|
|
49
|
-
* ```
|
|
50
|
-
*
|
|
51
|
-
* @example
|
|
52
|
-
* ```tsx
|
|
53
|
-
* <Heading size="xs" color="secondary">Subtitle</Heading>
|
|
54
|
-
* ```
|
|
55
|
-
*/
|
|
56
|
-
export declare const Heading: default_2.FC<IHeadingProps>;
|
|
57
|
-
|
|
58
|
-
export declare interface IHeadingProps extends default_2.PropsWithChildren {
|
|
59
|
-
/** HTML tag to render. Default: `h2`. */
|
|
60
|
-
as?: THeadingTag;
|
|
61
|
-
/** Heading size. Default: `sm`. */
|
|
62
|
-
size?: THeadingSize;
|
|
63
|
-
/** Text color token. */
|
|
64
|
-
color?: THeadingColor;
|
|
65
|
-
/** Truncate text with ellipsis (single-line). */
|
|
66
|
-
truncate?: boolean;
|
|
67
|
-
/** Ref to the root heading element. */
|
|
68
|
-
ref?: default_2.Ref<HTMLHeadingElement>;
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
export declare interface ITextProps extends default_2.PropsWithChildren {
|
|
72
|
-
/** HTML-тег для рендера корневого элемента. По умолчанию `p`. */
|
|
73
|
-
as?: TTextTag;
|
|
74
|
-
/** Размер текста. По умолчанию `sm`. */
|
|
75
|
-
size?: TTextSize;
|
|
76
|
-
/** Насыщенность шрифта. По умолчанию `normal`. */
|
|
77
|
-
weight?: TTextWeight;
|
|
78
|
-
/** Цвет текста из дизайн-системы. Если не передан — используется наследованный цвет. */
|
|
79
|
-
color?: TTextColor;
|
|
80
|
-
/** Обрезать текст с многоточием (одна строка, `text-overflow: ellipsis`). */
|
|
81
|
-
truncate?: boolean;
|
|
82
|
-
/** Подчёркивание: `true` для обычного underline, `'dotted'` для пунктирного подчёркивания. */
|
|
83
|
-
underline?: boolean | 'dotted';
|
|
84
|
-
/** Зачёркивание текста (`text-decoration: line-through`). */
|
|
85
|
-
strikethrough?: boolean;
|
|
86
|
-
/** Ref на корневой элемент. */
|
|
87
|
-
ref?: default_2.Ref<HTMLElement>;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
/**
|
|
91
|
-
* Text — компонент для отображения основного текста.
|
|
92
|
-
*
|
|
93
|
-
* Поддерживает размеры от 12px (xs) до 16px (lg), различные насыщенности шрифта
|
|
94
|
-
* и цвета из дизайн-системы. Подходит для параграфов, лейблов, аннотаций.
|
|
95
|
-
*
|
|
96
|
-
* В отличие от Heading, Text не имеет встроенного жирного начертания —
|
|
97
|
-
* вес управляется отдельным пропом `weight`.
|
|
98
|
-
*
|
|
99
|
-
* @example
|
|
100
|
-
* ```tsx
|
|
101
|
-
* <Text size="lg" weight="medium">Основной текст</Text>
|
|
102
|
-
* ```
|
|
103
|
-
*
|
|
104
|
-
* @example
|
|
105
|
-
* ```tsx
|
|
106
|
-
* <Text size="xs" color="secondary" as="span">Аннотация</Text>
|
|
107
|
-
* ```
|
|
108
|
-
*/
|
|
109
|
-
declare const Text_2: default_2.ForwardRefExoticComponent<Omit<ITextProps, "ref"> & default_2.RefAttributes<HTMLElement>>;
|
|
110
|
-
export { Text_2 as Text }
|
|
111
|
-
|
|
112
|
-
declare type THeadingColor = `${EHeadingColor}`;
|
|
113
|
-
|
|
114
|
-
declare type THeadingSize = `${EHeadingSize}`;
|
|
115
|
-
|
|
116
|
-
declare type THeadingTag = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
|
|
117
|
-
|
|
118
|
-
declare type TTextColor = `${ETextColor}`;
|
|
119
|
-
|
|
120
|
-
declare type TTextSize = `${ETextSize}`;
|
|
121
|
-
|
|
122
|
-
declare type TTextTag = 'p' | 'span' | 'div';
|
|
123
|
-
|
|
124
|
-
declare type TTextWeight = `${ETextWeight}`;
|
|
125
|
-
|
|
126
|
-
export { }
|
package/dist/typography.js
DELETED
|
File without changes
|
|
File without changes
|
|
File without changes
|