@rarui/components 1.16.0 → 1.18.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/CHANGELOG.md +18 -0
- package/custom-elements.json +377 -1
- package/dist/index.d.ts +301 -0
- package/dist/index.js +356 -155
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -16804,6 +16804,130 @@ declare const iconButtonStyles: {
|
|
|
16804
16804
|
|
|
16805
16805
|
type IconButtonVariants = NonNullable<RecipeVariants<typeof iconButtonStyles.iconButton>>;
|
|
16806
16806
|
|
|
16807
|
+
declare const styles$6: {
|
|
16808
|
+
container: RuntimeFn<{
|
|
16809
|
+
/**
|
|
16810
|
+
* Determines the visual style of the input, affecting its border
|
|
16811
|
+
*/
|
|
16812
|
+
appearance: {
|
|
16813
|
+
success: {
|
|
16814
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16815
|
+
":hover": {
|
|
16816
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16817
|
+
};
|
|
16818
|
+
":focus": {
|
|
16819
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16820
|
+
};
|
|
16821
|
+
};
|
|
16822
|
+
error: {
|
|
16823
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16824
|
+
":hover": {
|
|
16825
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16826
|
+
};
|
|
16827
|
+
":focus": {
|
|
16828
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16829
|
+
};
|
|
16830
|
+
};
|
|
16831
|
+
};
|
|
16832
|
+
/**
|
|
16833
|
+
* Determines if the input have borders or not.
|
|
16834
|
+
* @default true
|
|
16835
|
+
*/
|
|
16836
|
+
border: {
|
|
16837
|
+
true: {
|
|
16838
|
+
borderWidth: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16839
|
+
};
|
|
16840
|
+
false: {
|
|
16841
|
+
borderWidth: number;
|
|
16842
|
+
};
|
|
16843
|
+
};
|
|
16844
|
+
size: {
|
|
16845
|
+
large: {
|
|
16846
|
+
height: "3rem";
|
|
16847
|
+
};
|
|
16848
|
+
medium: {
|
|
16849
|
+
height: "2.5rem";
|
|
16850
|
+
};
|
|
16851
|
+
small: {
|
|
16852
|
+
height: "2rem";
|
|
16853
|
+
};
|
|
16854
|
+
};
|
|
16855
|
+
}>;
|
|
16856
|
+
input: RuntimeFn<{
|
|
16857
|
+
/**
|
|
16858
|
+
* Places a divider between the input and the leading components
|
|
16859
|
+
* @default true
|
|
16860
|
+
*/
|
|
16861
|
+
divider: {
|
|
16862
|
+
false: {};
|
|
16863
|
+
};
|
|
16864
|
+
/**
|
|
16865
|
+
* Specifies the size of the input, controlling its dimensions.
|
|
16866
|
+
* @default medium
|
|
16867
|
+
*/
|
|
16868
|
+
size: {
|
|
16869
|
+
large: {
|
|
16870
|
+
fontSize: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16871
|
+
lineHeight: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16872
|
+
};
|
|
16873
|
+
medium: {
|
|
16874
|
+
fontSize: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16875
|
+
lineHeight: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16876
|
+
};
|
|
16877
|
+
small: {
|
|
16878
|
+
fontSize: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16879
|
+
lineHeight: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16880
|
+
padding: `0 var(--${string})` | `0 var(--${string}, ${string})`;
|
|
16881
|
+
};
|
|
16882
|
+
};
|
|
16883
|
+
}>;
|
|
16884
|
+
leading: RuntimeFn<{
|
|
16885
|
+
position: {
|
|
16886
|
+
start: {
|
|
16887
|
+
borderRightWidth: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16888
|
+
};
|
|
16889
|
+
end: {
|
|
16890
|
+
borderLeftWidth: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16891
|
+
};
|
|
16892
|
+
};
|
|
16893
|
+
divider: {
|
|
16894
|
+
true: {
|
|
16895
|
+
borderStyle: "solid";
|
|
16896
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16897
|
+
};
|
|
16898
|
+
false: {
|
|
16899
|
+
borderRightWidth: number;
|
|
16900
|
+
borderLeftWidth: number;
|
|
16901
|
+
};
|
|
16902
|
+
};
|
|
16903
|
+
appearance: {
|
|
16904
|
+
success: {
|
|
16905
|
+
color: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16906
|
+
backgroundColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16907
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16908
|
+
};
|
|
16909
|
+
error: {
|
|
16910
|
+
color: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16911
|
+
backgroundColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16912
|
+
borderColor: `var(--${string})` | `var(--${string}, ${string})`;
|
|
16913
|
+
};
|
|
16914
|
+
};
|
|
16915
|
+
size: {
|
|
16916
|
+
large: {
|
|
16917
|
+
padding: `0 var(--${string})` | `0 var(--${string}, ${string})`;
|
|
16918
|
+
};
|
|
16919
|
+
medium: {
|
|
16920
|
+
padding: `0 var(--${string})` | `0 var(--${string}, ${string})`;
|
|
16921
|
+
};
|
|
16922
|
+
small: {
|
|
16923
|
+
padding: `0 var(--${string})` | `0 var(--${string}, ${string})`;
|
|
16924
|
+
};
|
|
16925
|
+
};
|
|
16926
|
+
}>;
|
|
16927
|
+
};
|
|
16928
|
+
|
|
16929
|
+
type InputVariants = NonNullable<RecipeVariants<typeof styles$6.container> & RecipeVariants<typeof styles$6.input>>;
|
|
16930
|
+
|
|
16807
16931
|
declare const styles$5: {
|
|
16808
16932
|
label: RuntimeFn<{
|
|
16809
16933
|
/**
|
|
@@ -17377,6 +17501,33 @@ interface CardSprinkle {
|
|
|
17377
17501
|
backgroundColor?: AddDollar<keyof typeof cardBackgroundColorProperties> | Conditions<AddDollar<keyof typeof cardBackgroundColorProperties>>;
|
|
17378
17502
|
}
|
|
17379
17503
|
|
|
17504
|
+
declare const modalStyles: {
|
|
17505
|
+
modal: RuntimeFn<{
|
|
17506
|
+
/**
|
|
17507
|
+
* Padding properties are used to generate space around the content area of an Accordion.Body..
|
|
17508
|
+
* @default base
|
|
17509
|
+
*/
|
|
17510
|
+
padding: {
|
|
17511
|
+
base: {
|
|
17512
|
+
padding: `var(--${string}) var(--${string})` | `var(--${string}) var(--${string}, ${string})` | `var(--${string}, ${string}) var(--${string})` | `var(--${string}, ${string}) var(--${string}, ${string})`;
|
|
17513
|
+
};
|
|
17514
|
+
none: {
|
|
17515
|
+
padding: number;
|
|
17516
|
+
};
|
|
17517
|
+
};
|
|
17518
|
+
}>;
|
|
17519
|
+
overlay: string;
|
|
17520
|
+
};
|
|
17521
|
+
|
|
17522
|
+
type ModalVariants = Omit<NonNullable<RecipeVariants<typeof modalStyles.modal>>, "selected">;
|
|
17523
|
+
type ModalDynamicProperties = Pick<StandardLonghandProperties, "maxWidth">;
|
|
17524
|
+
interface ModalSprinkle extends ModalDynamicProperties {
|
|
17525
|
+
/**
|
|
17526
|
+
* The zIndex property specifies the stack order of the box.
|
|
17527
|
+
*/
|
|
17528
|
+
zIndex?: AddDollar<keyof typeof zIndexProperties> | Conditions<AddDollar<keyof typeof zIndexProperties>>;
|
|
17529
|
+
}
|
|
17530
|
+
|
|
17380
17531
|
declare const paginationStyles: {
|
|
17381
17532
|
container: RuntimeFn<{
|
|
17382
17533
|
size: {
|
|
@@ -17674,6 +17825,8 @@ interface ChipTyping extends ChipSprinkle {
|
|
|
17674
17825
|
}
|
|
17675
17826
|
type ChipProps = ChipTyping & ChipVariants;
|
|
17676
17827
|
|
|
17828
|
+
type InputProps = InputVariants;
|
|
17829
|
+
|
|
17677
17830
|
interface DropdownTyping {
|
|
17678
17831
|
/**
|
|
17679
17832
|
* A common feature of select dropdowns is that the dropdown matches the width of the reference regardless of its contents.
|
|
@@ -17801,6 +17954,36 @@ interface CardHeaderProps {
|
|
|
17801
17954
|
description?: string;
|
|
17802
17955
|
}
|
|
17803
17956
|
|
|
17957
|
+
interface ModalTyping {
|
|
17958
|
+
/**
|
|
17959
|
+
* Whether the modal is open or not.
|
|
17960
|
+
*/
|
|
17961
|
+
open: boolean;
|
|
17962
|
+
/**
|
|
17963
|
+
* Specifies the ID of the portal element where the modal should be rendered.
|
|
17964
|
+
* This can be useful for rendering the modal in a different part of the DOM, such as a modal or overlay.
|
|
17965
|
+
*/
|
|
17966
|
+
portalId?: string;
|
|
17967
|
+
/**
|
|
17968
|
+
* Callback fired when the component requests to be closed.
|
|
17969
|
+
* @TJS-type (open: boolean) => void;
|
|
17970
|
+
*/
|
|
17971
|
+
onDismiss: (open: boolean) => void;
|
|
17972
|
+
}
|
|
17973
|
+
type ModalProps = ModalTyping & ModalSprinkle & ModalVariants;
|
|
17974
|
+
|
|
17975
|
+
interface ModalHeaderTypings {
|
|
17976
|
+
/**
|
|
17977
|
+
* The title to display in the Modal header.
|
|
17978
|
+
*/
|
|
17979
|
+
title?: string;
|
|
17980
|
+
/**
|
|
17981
|
+
* The subtitle to display in the Modal header.
|
|
17982
|
+
*/
|
|
17983
|
+
subtitle?: string;
|
|
17984
|
+
}
|
|
17985
|
+
type ModalHeaderProps = ModalHeaderTypings;
|
|
17986
|
+
|
|
17804
17987
|
type LinkProps = LinkVariants;
|
|
17805
17988
|
|
|
17806
17989
|
interface PaginationTyping {
|
|
@@ -18395,6 +18578,51 @@ declare class RaruiIconButton extends LitElement {
|
|
|
18395
18578
|
render(): TemplateResult<1>;
|
|
18396
18579
|
}
|
|
18397
18580
|
|
|
18581
|
+
declare global {
|
|
18582
|
+
interface HTMLElementTagNameMap {
|
|
18583
|
+
"rarui-input": RaruiInput;
|
|
18584
|
+
}
|
|
18585
|
+
}
|
|
18586
|
+
/**
|
|
18587
|
+
* ## Rarui Input
|
|
18588
|
+
* ---
|
|
18589
|
+
* Input component allows users to enter and edit text.
|
|
18590
|
+
*
|
|
18591
|
+
* See [a complete document](https://rarui.rarolabs.com.br/docs/components-web-components/input/input) for more details.
|
|
18592
|
+
*/
|
|
18593
|
+
type InputProperties = Partial<InputProps> & {
|
|
18594
|
+
/**
|
|
18595
|
+
* The value of the input element.
|
|
18596
|
+
*/
|
|
18597
|
+
value?: string;
|
|
18598
|
+
/**
|
|
18599
|
+
* Placeholder text for the input element.
|
|
18600
|
+
*/
|
|
18601
|
+
placeholder?: string;
|
|
18602
|
+
/**
|
|
18603
|
+
* Whether the input is disabled.
|
|
18604
|
+
* @default false
|
|
18605
|
+
*/
|
|
18606
|
+
disabled?: boolean;
|
|
18607
|
+
};
|
|
18608
|
+
|
|
18609
|
+
declare class RaruiInput extends LitElement {
|
|
18610
|
+
size: InputProperties["size"];
|
|
18611
|
+
appearance?: InputProperties["appearance"];
|
|
18612
|
+
border: InputProperties["border"];
|
|
18613
|
+
divider: InputProperties["divider"];
|
|
18614
|
+
disabled: InputProperties["disabled"];
|
|
18615
|
+
value: string;
|
|
18616
|
+
placeholder?: string;
|
|
18617
|
+
static styles: CSSResult;
|
|
18618
|
+
render(): TemplateResult<1>;
|
|
18619
|
+
private _focusInput;
|
|
18620
|
+
private _onInput;
|
|
18621
|
+
private _onChange;
|
|
18622
|
+
private _onFocus;
|
|
18623
|
+
private _onBlur;
|
|
18624
|
+
}
|
|
18625
|
+
|
|
18398
18626
|
declare global {
|
|
18399
18627
|
interface HTMLElementTagNameMap {
|
|
18400
18628
|
"rarui-radio-button": RaruiRadioButton;
|
|
@@ -18651,3 +18879,76 @@ declare class RaruiCard extends LitElement {
|
|
|
18651
18879
|
static styles: CSSResult;
|
|
18652
18880
|
render(): TemplateResult<1>;
|
|
18653
18881
|
}
|
|
18882
|
+
|
|
18883
|
+
declare global {
|
|
18884
|
+
interface HTMLElementTagNameMap {
|
|
18885
|
+
"rarui-modal": RaruiModal;
|
|
18886
|
+
}
|
|
18887
|
+
}
|
|
18888
|
+
/**
|
|
18889
|
+
* ## Rarui Modal
|
|
18890
|
+
* ---
|
|
18891
|
+
* The modal component provides a base for popovers, suspended forms, tutorials, or any other content above the UI main surface.
|
|
18892
|
+
*
|
|
18893
|
+
See [a complete document](https://rarui.rarolabs.com.br/docs/components-web-components/surface/modal) for more details.
|
|
18894
|
+
*/
|
|
18895
|
+
type ModalProperties = Omit<Partial<ModalProps>, "onDismiss">;
|
|
18896
|
+
|
|
18897
|
+
declare class RaruiModal extends LitElement {
|
|
18898
|
+
sprinkleAttrs: Record<string, string>;
|
|
18899
|
+
padding: ModalProperties["padding"];
|
|
18900
|
+
portalId: ModalProperties["portalId"];
|
|
18901
|
+
open: ModalProperties["open"];
|
|
18902
|
+
maxWidth: ModalProperties["maxWidth"];
|
|
18903
|
+
dialog: HTMLElement;
|
|
18904
|
+
static styles: CSSResult;
|
|
18905
|
+
cleanupAutoUpdate?: () => void;
|
|
18906
|
+
connectedCallback(): void;
|
|
18907
|
+
disconnectedCallback(): void;
|
|
18908
|
+
firstUpdated(): void;
|
|
18909
|
+
updated(changed: Map<string, any>): void;
|
|
18910
|
+
private getPortalRoot;
|
|
18911
|
+
private handleKeyDown;
|
|
18912
|
+
private dismiss;
|
|
18913
|
+
render(): TemplateResult<1>;
|
|
18914
|
+
}
|
|
18915
|
+
|
|
18916
|
+
declare global {
|
|
18917
|
+
interface HTMLElementTagNameMap {
|
|
18918
|
+
"rarui-modal-header": RaruiModalHeader;
|
|
18919
|
+
}
|
|
18920
|
+
}
|
|
18921
|
+
/**
|
|
18922
|
+
* ## Rarui Modal Header
|
|
18923
|
+
* ---
|
|
18924
|
+
* The modal component provides a base for popovers, suspended forms, tutorials, or any other content above the UI main surface.
|
|
18925
|
+
*
|
|
18926
|
+
See [a complete document](https://rarui.rarolabs.com.br/docs/components-web-components/surface/modal) for more details.
|
|
18927
|
+
*/
|
|
18928
|
+
type ModalHeaderProperties = ModalHeaderProps;
|
|
18929
|
+
|
|
18930
|
+
declare class RaruiModalHeader extends LitElement {
|
|
18931
|
+
title: string;
|
|
18932
|
+
subtitle: ModalHeaderProperties["subtitle"];
|
|
18933
|
+
private handleClose;
|
|
18934
|
+
render(): TemplateResult<1>;
|
|
18935
|
+
}
|
|
18936
|
+
|
|
18937
|
+
declare global {
|
|
18938
|
+
interface HTMLElementTagNameMap {
|
|
18939
|
+
"rarui-theme-provider": RaruiThemeProvider;
|
|
18940
|
+
}
|
|
18941
|
+
}
|
|
18942
|
+
type Theme = "dark" | "base";
|
|
18943
|
+
|
|
18944
|
+
declare class RaruiThemeProvider extends LitElement {
|
|
18945
|
+
theme: Theme;
|
|
18946
|
+
private previousTheme?;
|
|
18947
|
+
protected createRenderRoot(): this;
|
|
18948
|
+
static styles: CSSResult;
|
|
18949
|
+
connectedCallback(): void;
|
|
18950
|
+
updated(changedProperties: Map<string, unknown>): void;
|
|
18951
|
+
disconnectedCallback(): void;
|
|
18952
|
+
private applyTheme;
|
|
18953
|
+
render(): TemplateResult<1>;
|
|
18954
|
+
}
|