@sebgroup/green-core 1.0.0-beta.9 → 1.0.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/components/dropdown/dropdown.d.ts +30 -3
- package/index.js +388 -90
- package/package.json +7 -1
- package/primitives/listbox/listbox.d.ts +5 -1
- package/primitives/popover/popover.d.ts +6 -1
- package/primitives/popover/topLayerOverTransforms.middleware.d.ts +28 -0
- package/transitional-styles.js +639 -485
- package/utils/decorators/index.d.ts +1 -0
- package/utils/decorators/watch-media-query.d.ts +31 -0
- package/utils/helpers/custom-element-scoping.d.ts +1 -0
- package/utils/helpers/transitional-styles.d.ts +4 -1
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sebgroup/green-core",
|
|
3
3
|
"description": "A carefully crafted set of Web Components, laying the foundation of the Green Design System.",
|
|
4
|
-
"version": "1.0.0
|
|
4
|
+
"version": "1.0.0",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"module": "index.js",
|
|
7
7
|
"type": "module",
|
|
@@ -20,6 +20,12 @@
|
|
|
20
20
|
"registry": "https://registry.npmjs.org/",
|
|
21
21
|
"access": "public"
|
|
22
22
|
},
|
|
23
|
+
"dependencies": {
|
|
24
|
+
"@floating-ui/dom": "^1.5.3",
|
|
25
|
+
"@lit/localize": "^0.11.4",
|
|
26
|
+
"lit": "^2.8.0",
|
|
27
|
+
"reflect-metadata": "^0.1.13"
|
|
28
|
+
},
|
|
23
29
|
"exports": {
|
|
24
30
|
".": {
|
|
25
31
|
"types": "./index.d.ts",
|
|
@@ -21,6 +21,10 @@ export declare class GdsListbox extends LitElement implements OptionsContainer {
|
|
|
21
21
|
* Controls whether the listbox allows multiple selection or not.
|
|
22
22
|
*/
|
|
23
23
|
multiple: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Delegate function for comparing option values.
|
|
26
|
+
*/
|
|
27
|
+
compareWith: (a: any, b: any) => boolean;
|
|
24
28
|
constructor();
|
|
25
29
|
/**
|
|
26
30
|
* Returns a list of all `gds-option` elements in the listbox.
|
|
@@ -38,7 +42,7 @@ export declare class GdsListbox extends LitElement implements OptionsContainer {
|
|
|
38
42
|
* Returns a list of all selected `gds-option` elements in the listbox.
|
|
39
43
|
*/
|
|
40
44
|
get selection(): GdsOption[];
|
|
41
|
-
set selection(values:
|
|
45
|
+
set selection(values: any[]);
|
|
42
46
|
connectedCallback(): void;
|
|
43
47
|
/**
|
|
44
48
|
* Focuses the first selected option in the listbox.
|
|
@@ -23,9 +23,14 @@ export declare class GdsPopover extends LitElement {
|
|
|
23
23
|
* Optional trigger element for the popover.
|
|
24
24
|
*/
|
|
25
25
|
trigger: HTMLElement | undefined;
|
|
26
|
+
/**
|
|
27
|
+
* Optional trigger element for the popover.
|
|
28
|
+
*/
|
|
29
|
+
label: string | undefined;
|
|
26
30
|
private _handleTriggerChanged;
|
|
27
31
|
connectedCallback(): void;
|
|
28
32
|
disconnectedCallback(): void;
|
|
29
33
|
render(): import("lit-html").TemplateResult<1>;
|
|
30
|
-
private
|
|
34
|
+
private _handleOpenChange;
|
|
35
|
+
private _handleMobileLayout;
|
|
31
36
|
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Temporary implemenation of topLayerOverTransforms middleware snagged from here: https://github.com/floating-ui/floating-ui/issues/1842
|
|
3
|
+
*
|
|
4
|
+
* This solved positioning issues when a popover is opened from a parent element that is using transforms.
|
|
5
|
+
*
|
|
6
|
+
* As soon as this is merged in FloatingUI we can remove this and use the official version.
|
|
7
|
+
*/
|
|
8
|
+
export declare const topLayerOverTransforms: () => {
|
|
9
|
+
name: string;
|
|
10
|
+
fn(middlewareArguments: any): Promise<{
|
|
11
|
+
x: any;
|
|
12
|
+
y: any;
|
|
13
|
+
data: {
|
|
14
|
+
x: number;
|
|
15
|
+
y: number;
|
|
16
|
+
};
|
|
17
|
+
}>;
|
|
18
|
+
};
|
|
19
|
+
export declare function isLastTraversableNode(node: any): boolean;
|
|
20
|
+
export declare function getUAString(): any;
|
|
21
|
+
export declare function getParentNode(node: any): any;
|
|
22
|
+
export declare function getNodeName(node: any): any;
|
|
23
|
+
export declare function getDocumentElement(node: any): any;
|
|
24
|
+
export declare function isNode(value: any): boolean;
|
|
25
|
+
export declare function isWindow(value: any): any;
|
|
26
|
+
export declare function getWindow(node: any): any;
|
|
27
|
+
export declare function isShadowRoot(node: any): boolean;
|
|
28
|
+
export declare function isHTMLElement(value: any): boolean;
|