xv-webcomponents 0.1.16 → 0.1.17
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/LICENSE +21 -21
- package/README.md +129 -129
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/utils-c7652b74.js.map +1 -1
- package/dist/cjs/xv-accordion-v2_10.cjs.entry.js +265 -0
- package/dist/cjs/xv-accordion-v2_10.cjs.entry.js.map +1 -0
- package/dist/cjs/xv-breadcrumbs-v2.cjs.entry.js +22 -0
- package/dist/cjs/xv-breadcrumbs-v2.cjs.entry.js.map +1 -0
- package/dist/cjs/xv-webcomponents.cjs.js +1 -1
- package/dist/collection/components/xv-accordion/xv-accordion.js +2 -2
- package/dist/collection/components/xv-accordion/xv-accordion.js.map +1 -1
- package/dist/collection/components/xv-accordion-item/xv-accordion-item.js +3 -3
- package/dist/collection/components/xv-accordion-item/xv-accordion-item.js.map +1 -1
- package/dist/collection/components/xv-breadcrumbs/xv-breadcrumbs.js +2 -2
- package/dist/collection/components/xv-breadcrumbs/xv-breadcrumbs.js.map +1 -1
- package/dist/collection/components/xv-button/xv-button-v2.css +4 -1
- package/dist/collection/components/xv-button/xv-button.js +24 -2
- package/dist/collection/components/xv-button/xv-button.js.map +1 -1
- package/dist/collection/components/xv-card/xv-card.css +1 -1
- package/dist/collection/components/xv-card/xv-card.js +1 -1
- package/dist/collection/components/xv-card/xv-card.js.map +1 -1
- package/dist/collection/components/xv-checkbox/xv-checkbox.js +1 -1
- package/dist/collection/components/xv-link/xv-link.js +2 -2
- package/dist/collection/components/xv-link/xv-link.js.map +1 -1
- package/dist/collection/components/xv-progress-indicator/xv-progress-indicator.css +1 -0
- package/dist/collection/components/xv-progress-indicator/xv-progress-indicator.js +2 -2
- package/dist/collection/components/xv-progress-indicator/xv-progress-indicator.js.map +1 -1
- package/dist/collection/components/xv-progress-indicator-item/xv-progress-indicator-item.css +1 -1
- package/dist/collection/components/xv-progress-indicator-item/xv-progress-indicator-item.js +2 -2
- package/dist/collection/components/xv-progress-indicator-item/xv-progress-indicator-item.js.map +1 -1
- package/dist/collection/components/xv-tag/xv-tag.js +2 -2
- package/dist/collection/components/xv-tag/xv-tag.js.map +1 -1
- package/dist/collection/components/xv-tooltip/xv-tooltip.css +1 -0
- package/dist/collection/components/xv-tooltip/xv-tooltip.js +3 -3
- package/dist/collection/components/xv-tooltip/xv-tooltip.js.map +1 -1
- package/dist/collection/index.js.map +1 -1
- package/dist/collection/utils/utils.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/utils-9bb6333b.js.map +1 -1
- package/dist/esm/xv-accordion-v2_10.entry.js +252 -0
- package/dist/esm/xv-accordion-v2_10.entry.js.map +1 -0
- package/dist/esm/xv-breadcrumbs-v2.entry.js +18 -0
- package/dist/esm/xv-breadcrumbs-v2.entry.js.map +1 -0
- package/dist/esm/xv-webcomponents.js +1 -1
- package/dist/types/components/xv-button/xv-button.d.ts +2 -0
- package/dist/types/components.d.ts +98 -90
- package/dist/xv-webcomponents/p-08297c60.entry.js +2 -0
- package/dist/xv-webcomponents/p-08297c60.entry.js.map +1 -0
- package/dist/xv-webcomponents/p-6fe85516.entry.js +2 -0
- package/dist/xv-webcomponents/p-6fe85516.entry.js.map +1 -0
- package/dist/xv-webcomponents/p-a0b74d3c.js.map +1 -1
- package/dist/xv-webcomponents/xv-webcomponents.esm.js +1 -1
- package/dist/xv-webcomponents/xv-webcomponents.esm.js.map +1 -1
- package/package.json +51 -51
- package/dist/cjs/xv-accordion_10.cjs.entry.js +0 -263
- package/dist/cjs/xv-accordion_10.cjs.entry.js.map +0 -1
- package/dist/cjs/xv-breadcrumbs.cjs.entry.js +0 -22
- package/dist/cjs/xv-breadcrumbs.cjs.entry.js.map +0 -1
- package/dist/esm/xv-accordion_10.entry.js +0 -250
- package/dist/esm/xv-accordion_10.entry.js.map +0 -1
- package/dist/esm/xv-breadcrumbs.entry.js +0 -18
- package/dist/esm/xv-breadcrumbs.entry.js.map +0 -1
- package/dist/xv-webcomponents/p-41bd284c.entry.js +0 -2
- package/dist/xv-webcomponents/p-41bd284c.entry.js.map +0 -1
- package/dist/xv-webcomponents/p-948b7ef5.entry.js +0 -2
- package/dist/xv-webcomponents/p-948b7ef5.entry.js.map +0 -1
package/LICENSE
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 crossvertise
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 crossvertise
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,129 +1,129 @@
|
|
|
1
|
-
# @xv/webcomponents
|
|
2
|
-
|
|
3
|
-
**Reusable Web Components for XV Applications**
|
|
4
|
-
This repository contains Web Components built with Stencil.js to provide a modular and reusable UI across multiple applications.
|
|
5
|
-
|
|
6
|
-
---
|
|
7
|
-
|
|
8
|
-
## Features
|
|
9
|
-
|
|
10
|
-
**Reusable Web Components** – Designed for multiple XV applications
|
|
11
|
-
**Stencil.js Powered** – Built using modern Web Component standards
|
|
12
|
-
**Shadow DOM Support** – Encapsulated styles and functionality
|
|
13
|
-
**Brand-Specific Theming** – Automatically detects and applies brand styles
|
|
14
|
-
**Framework Agnostic** – Works with Angular, React, Vue, and plain HTML
|
|
15
|
-
|
|
16
|
-
---
|
|
17
|
-
|
|
18
|
-
## Folder Structure
|
|
19
|
-
|
|
20
|
-
```
|
|
21
|
-
xv-webcomponents/
|
|
22
|
-
│── src/
|
|
23
|
-
│ ├── components/ # Web Component source files
|
|
24
|
-
│ │ ├── button/
|
|
25
|
-
│ │ │ ├── xv-button.tsx
|
|
26
|
-
│ │ │ ├── xv-button.css
|
|
27
|
-
│ │ │ ├── xv-button.e2e.ts
|
|
28
|
-
│ │ │ ├── xv-button.spec.ts
|
|
29
|
-
│ │ ├── checkbox/
|
|
30
|
-
│ │ │ ├── xv-checkbox.tsx
|
|
31
|
-
│ │ │ ├── xv-checkbox.css
|
|
32
|
-
│ │ │ ├── xv-checkbox.e2e.ts
|
|
33
|
-
│ │ │ ├── xv-checkbox.spec.ts
|
|
34
|
-
│ ├── utils/ # Utility functions for components
|
|
35
|
-
│── dist/ # Compiled distribution files
|
|
36
|
-
│── loader/ # Loader scripts for consuming Web Components
|
|
37
|
-
│── package.json
|
|
38
|
-
│── README.md
|
|
39
|
-
│── stencil.config.ts # Stencil.js configuration
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
---
|
|
43
|
-
|
|
44
|
-
## Installation
|
|
45
|
-
|
|
46
|
-
To install the package from npm:
|
|
47
|
-
```bash
|
|
48
|
-
npm install xv-webcomponents
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
---
|
|
52
|
-
|
|
53
|
-
## Usage
|
|
54
|
-
|
|
55
|
-
### **Using in an HTML Page**
|
|
56
|
-
Simply include the Web Component in your HTML:
|
|
57
|
-
```html
|
|
58
|
-
<script type="module" src="https://cdn.yourcompany.com/xv-webcomponents/xv-webcomponents.esm.js"></script>
|
|
59
|
-
<xv-button-v2 label="Click Me" variant="accent"></xv-button-v2>
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
### **Using in an Angular Project**
|
|
63
|
-
First, import `CUSTOM_ELEMENTS_SCHEMA` in your module:
|
|
64
|
-
```typescript
|
|
65
|
-
import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
|
|
66
|
-
import { BrowserModule } from '@angular/platform-browser';
|
|
67
|
-
|
|
68
|
-
@NgModule({
|
|
69
|
-
declarations: [],
|
|
70
|
-
imports: [BrowserModule],
|
|
71
|
-
schemas: [CUSTOM_ELEMENTS_SCHEMA]
|
|
72
|
-
})
|
|
73
|
-
export class AppModule {}
|
|
74
|
-
```
|
|
75
|
-
Now, use the Web Component in your Angular templates:
|
|
76
|
-
```html
|
|
77
|
-
<xv-button-v2 label="Click Me" variant="primary"></xv-button-v2>
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
### **Using in a C# Razor Page (MVC)**
|
|
81
|
-
```html
|
|
82
|
-
<xv-button-v2 label="Submit" variant="secondary"></xv-button-v2>
|
|
83
|
-
```
|
|
84
|
-
|
|
85
|
-
### **Using in Sitefinity CMS**
|
|
86
|
-
Embed the Web Component inside a content block:
|
|
87
|
-
```html
|
|
88
|
-
<xv-button-v2 label="Learn More" variant="ghost"></xv-button-v2>
|
|
89
|
-
```
|
|
90
|
-
|
|
91
|
-
---
|
|
92
|
-
|
|
93
|
-
## 🛠 Development & Building
|
|
94
|
-
|
|
95
|
-
### **1️⃣ Build the Components**
|
|
96
|
-
To build all components:
|
|
97
|
-
```bash
|
|
98
|
-
npm run build
|
|
99
|
-
```
|
|
100
|
-
This generates compiled components inside the `dist/` folder.
|
|
101
|
-
|
|
102
|
-
### **2️⃣ Run Local Development Server**
|
|
103
|
-
To test components locally:
|
|
104
|
-
```bash
|
|
105
|
-
npm start
|
|
106
|
-
```
|
|
107
|
-
This starts a development server and watches for changes.
|
|
108
|
-
|
|
109
|
-
### **3️⃣ Publish to npm**
|
|
110
|
-
To publish a new version of the package:
|
|
111
|
-
```bash
|
|
112
|
-
npm version patch
|
|
113
|
-
npm publish --access public
|
|
114
|
-
```
|
|
115
|
-
|
|
116
|
-
---
|
|
117
|
-
|
|
118
|
-
## Contributing
|
|
119
|
-
|
|
120
|
-
### **Adding a New Component**
|
|
121
|
-
1. Generate a new component:
|
|
122
|
-
```bash
|
|
123
|
-
npm run generate component xv-new-component
|
|
124
|
-
```
|
|
125
|
-
2. Implement logic and styles inside `src/components/xv-new-component/`.
|
|
126
|
-
3. Test the component using Jest (`.spec.ts`) and e2e tests.
|
|
127
|
-
4. Run `npm run build` to generate the compiled version.
|
|
128
|
-
5. Commit changes and submit a pull request.
|
|
129
|
-
|
|
1
|
+
# @xv/webcomponents
|
|
2
|
+
|
|
3
|
+
**Reusable Web Components for XV Applications**
|
|
4
|
+
This repository contains Web Components built with Stencil.js to provide a modular and reusable UI across multiple applications.
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## Features
|
|
9
|
+
|
|
10
|
+
**Reusable Web Components** – Designed for multiple XV applications
|
|
11
|
+
**Stencil.js Powered** – Built using modern Web Component standards
|
|
12
|
+
**Shadow DOM Support** – Encapsulated styles and functionality
|
|
13
|
+
**Brand-Specific Theming** – Automatically detects and applies brand styles
|
|
14
|
+
**Framework Agnostic** – Works with Angular, React, Vue, and plain HTML
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## Folder Structure
|
|
19
|
+
|
|
20
|
+
```
|
|
21
|
+
xv-webcomponents/
|
|
22
|
+
│── src/
|
|
23
|
+
│ ├── components/ # Web Component source files
|
|
24
|
+
│ │ ├── button/
|
|
25
|
+
│ │ │ ├── xv-button.tsx
|
|
26
|
+
│ │ │ ├── xv-button.css
|
|
27
|
+
│ │ │ ├── xv-button.e2e.ts
|
|
28
|
+
│ │ │ ├── xv-button.spec.ts
|
|
29
|
+
│ │ ├── checkbox/
|
|
30
|
+
│ │ │ ├── xv-checkbox.tsx
|
|
31
|
+
│ │ │ ├── xv-checkbox.css
|
|
32
|
+
│ │ │ ├── xv-checkbox.e2e.ts
|
|
33
|
+
│ │ │ ├── xv-checkbox.spec.ts
|
|
34
|
+
│ ├── utils/ # Utility functions for components
|
|
35
|
+
│── dist/ # Compiled distribution files
|
|
36
|
+
│── loader/ # Loader scripts for consuming Web Components
|
|
37
|
+
│── package.json
|
|
38
|
+
│── README.md
|
|
39
|
+
│── stencil.config.ts # Stencil.js configuration
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
## Installation
|
|
45
|
+
|
|
46
|
+
To install the package from npm:
|
|
47
|
+
```bash
|
|
48
|
+
npm install xv-webcomponents
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## Usage
|
|
54
|
+
|
|
55
|
+
### **Using in an HTML Page**
|
|
56
|
+
Simply include the Web Component in your HTML:
|
|
57
|
+
```html
|
|
58
|
+
<script type="module" src="https://cdn.yourcompany.com/xv-webcomponents/xv-webcomponents.esm.js"></script>
|
|
59
|
+
<xv-button-v2 label="Click Me" variant="accent"></xv-button-v2>
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### **Using in an Angular Project**
|
|
63
|
+
First, import `CUSTOM_ELEMENTS_SCHEMA` in your module:
|
|
64
|
+
```typescript
|
|
65
|
+
import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
|
|
66
|
+
import { BrowserModule } from '@angular/platform-browser';
|
|
67
|
+
|
|
68
|
+
@NgModule({
|
|
69
|
+
declarations: [],
|
|
70
|
+
imports: [BrowserModule],
|
|
71
|
+
schemas: [CUSTOM_ELEMENTS_SCHEMA]
|
|
72
|
+
})
|
|
73
|
+
export class AppModule {}
|
|
74
|
+
```
|
|
75
|
+
Now, use the Web Component in your Angular templates:
|
|
76
|
+
```html
|
|
77
|
+
<xv-button-v2 label="Click Me" variant="primary"></xv-button-v2>
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### **Using in a C# Razor Page (MVC)**
|
|
81
|
+
```html
|
|
82
|
+
<xv-button-v2 label="Submit" variant="secondary"></xv-button-v2>
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
### **Using in Sitefinity CMS**
|
|
86
|
+
Embed the Web Component inside a content block:
|
|
87
|
+
```html
|
|
88
|
+
<xv-button-v2 label="Learn More" variant="ghost"></xv-button-v2>
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
---
|
|
92
|
+
|
|
93
|
+
## 🛠 Development & Building
|
|
94
|
+
|
|
95
|
+
### **1️⃣ Build the Components**
|
|
96
|
+
To build all components:
|
|
97
|
+
```bash
|
|
98
|
+
npm run build
|
|
99
|
+
```
|
|
100
|
+
This generates compiled components inside the `dist/` folder.
|
|
101
|
+
|
|
102
|
+
### **2️⃣ Run Local Development Server**
|
|
103
|
+
To test components locally:
|
|
104
|
+
```bash
|
|
105
|
+
npm start
|
|
106
|
+
```
|
|
107
|
+
This starts a development server and watches for changes.
|
|
108
|
+
|
|
109
|
+
### **3️⃣ Publish to npm**
|
|
110
|
+
To publish a new version of the package:
|
|
111
|
+
```bash
|
|
112
|
+
npm version patch
|
|
113
|
+
npm publish --access public
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
---
|
|
117
|
+
|
|
118
|
+
## Contributing
|
|
119
|
+
|
|
120
|
+
### **Adding a New Component**
|
|
121
|
+
1. Generate a new component:
|
|
122
|
+
```bash
|
|
123
|
+
npm run generate component xv-new-component
|
|
124
|
+
```
|
|
125
|
+
2. Implement logic and styles inside `src/components/xv-new-component/`.
|
|
126
|
+
3. Test the component using Jest (`.spec.ts`) and e2e tests.
|
|
127
|
+
4. Run `npm run build` to generate the compiled version.
|
|
128
|
+
5. Commit changes and submit a pull request.
|
|
129
|
+
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -8,7 +8,7 @@ const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
|
8
8
|
const defineCustomElements = async (win, options) => {
|
|
9
9
|
if (typeof window === 'undefined') return undefined;
|
|
10
10
|
await appGlobals.globalScripts();
|
|
11
|
-
return index.bootstrapLazy([["xv-
|
|
11
|
+
return index.bootstrapLazy([["xv-accordion-v2_10.cjs",[[1,"xv-accordion-v2",{"multiple":[4],"xvId":[1,"xv-id"],"value":[1025],"opened":[32],"toggleItem":[64]}],[1,"xv-accordion-v2-item",{"disabled":[4],"label":[1],"value":[1],"isOpen":[32]},[[16,"accordionChange","handleAccordionChange"]]],[1,"xv-button-v2",{"label":[1],"block":[4],"variant":[1],"disabled":[4]}],[1,"xv-card-v2",{"variant":[1],"media":[1],"header":[1],"body":[1],"footer":[1]}],[1,"xv-checkbox-v2"],[1,"xv-link-v2",{"href":[1],"target":[1],"disabled":[4],"size":[1],"variant":[1]}],[1,"xv-progress-indicator-v2",{"progress":[2]},null,{"progress":["updateChildItems"]}],[1,"xv-progress-indicator-v2-item",{"done":[4]}],[1,"xv-tag-v2",{"size":[1],"color":[1],"bg":[1],"disabled":[4],"closeable":[4]}],[1,"xv-tooltip-v2",{"message":[1],"position":[1]}]]],["xv-breadcrumbs-v2.cjs",[[1,"xv-breadcrumbs-v2"]]]], options);
|
|
12
12
|
};
|
|
13
13
|
|
|
14
14
|
exports.setNonce = index.setNonce;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"utils-c7652b74.js","mappings":";;SAAgB,MAAM,CAAC,KAAc,EAAE,MAAe,EAAE,IAAa;IACnE,OAAO,CAAC,KAAK,IAAI,EAAE,KAAK,MAAM,GAAG,IAAI,MAAM,EAAE,GAAG,EAAE,CAAC,IAAI,IAAI,GAAG,IAAI,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC;AACjF,CAAC;SAEe,YAAY;IAC1B,OAAO,sCAAsC,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC,IAC/D,CAAC,CAAC,CAAC,GAAG,MAAM,CAAC,eAAe,CAAC,IAAI,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC,EAAE,CAAC,CAChF,CAAC;AACJ;;;;;","names":[],"sources":["src/utils/utils.ts"],"sourcesContent":["export function format(first?: string, middle?: string, last?: string): string {\
|
|
1
|
+
{"file":"utils-c7652b74.js","mappings":";;SAAgB,MAAM,CAAC,KAAc,EAAE,MAAe,EAAE,IAAa;IACnE,OAAO,CAAC,KAAK,IAAI,EAAE,KAAK,MAAM,GAAG,IAAI,MAAM,EAAE,GAAG,EAAE,CAAC,IAAI,IAAI,GAAG,IAAI,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC;AACjF,CAAC;SAEe,YAAY;IAC1B,OAAO,sCAAsC,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC,IAC/D,CAAC,CAAC,CAAC,GAAG,MAAM,CAAC,eAAe,CAAC,IAAI,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC,EAAE,CAAC,CAChF,CAAC;AACJ;;;;;","names":[],"sources":["src/utils/utils.ts"],"sourcesContent":["export function format(first?: string, middle?: string, last?: string): string {\n return (first || '') + (middle ? ` ${middle}` : '') + (last ? ` ${last}` : '');\n}\n\nexport function uidGenerator() {\n return \"10000000-1000-4000-8000-100000000000\".replace(/[018]/g, c =>\n (+c ^ crypto.getRandomValues(new Uint8Array(1))[0] & 15 >> +c / 4).toString(16)\n );\n}\n"],"version":3}
|
|
@@ -0,0 +1,265 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-4d938647.js');
|
|
6
|
+
const utils = require('./utils-c7652b74.js');
|
|
7
|
+
|
|
8
|
+
const xvAccordionCss = ":host{display:block}";
|
|
9
|
+
const XvAccordionV2Style0 = xvAccordionCss;
|
|
10
|
+
|
|
11
|
+
const XvAccordion = class {
|
|
12
|
+
constructor(hostRef) {
|
|
13
|
+
index.registerInstance(this, hostRef);
|
|
14
|
+
this.accordionChange = index.createEvent(this, "accordionChange", 7);
|
|
15
|
+
this.multiple = false;
|
|
16
|
+
this.xvId = utils.uidGenerator();
|
|
17
|
+
this.opened = new Set();
|
|
18
|
+
}
|
|
19
|
+
async toggleItem(value) {
|
|
20
|
+
if (this.opened.has(value)) {
|
|
21
|
+
this.opened.delete(value);
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
if (!this.multiple)
|
|
25
|
+
this.opened.clear();
|
|
26
|
+
this.value = value;
|
|
27
|
+
this.opened.add(this.value);
|
|
28
|
+
}
|
|
29
|
+
this.accordionChange.emit({ opened: this.opened, id: this.xvId });
|
|
30
|
+
return { opened: this.opened, id: this.xvId };
|
|
31
|
+
}
|
|
32
|
+
componentWillLoad() {
|
|
33
|
+
if (this.value) {
|
|
34
|
+
return this.toggleItem(this.value);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
render() {
|
|
38
|
+
return (index.h(index.Host, { key: '66ebac5125b765878f7e21225f60f254bde5e07f', class: "xv-accordion", "data-id": this.xvId }, index.h("slot", { key: 'b5081e54395f14436a7f066fee6e75a48c9b797f' })));
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
XvAccordion.style = XvAccordionV2Style0;
|
|
42
|
+
|
|
43
|
+
const xvAccordionItemCss = ":host{border-top:1px solid var(--border-subtle-01);display:flex;flex-direction:column;font-family:var(--ff-body, inherit)}:host(.disabled) .label{color:var(--text-disabled)}:host(.disabled) .label:hover{cursor:initial;background-color:transparent}.label{padding:14px 16px;display:inline-flex;align-items:center;column-gap:20px;justify-content:space-between;text-align:left;color:var(--text-primary);font-size:14px;font-style:normal;font-weight:400;line-height:20px;letter-spacing:0.16px;background-color:transparent;transition:background-color 200ms ease-in-out}.label>span{overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical}.label:hover{cursor:pointer;background-color:var(--layer-hover-01)}.label:after{content:\"\";border:solid black;border-width:0 2px 2px 0;display:inline-block;padding:4.66px;transition:transform 100ms ease-in-out;transform:rotate(45deg)}.label.opened:after{transform:rotate(-135deg)}.content{padding:0 16px;text-align:left;color:var(--text-primary);font-size:14px;overflow:hidden;max-height:0;transition:max-height 300ms ease-in-out, padding 250ms ease 50ms}.content.opened{padding:14px 16px;max-height:500px}";
|
|
44
|
+
const XvAccordionV2ItemStyle0 = xvAccordionItemCss;
|
|
45
|
+
|
|
46
|
+
const XvAccordionItem = class {
|
|
47
|
+
constructor(hostRef) {
|
|
48
|
+
index.registerInstance(this, hostRef);
|
|
49
|
+
this.itemToggle = index.createEvent(this, "itemToggle", 7);
|
|
50
|
+
this.disabled = false;
|
|
51
|
+
this.isOpen = false;
|
|
52
|
+
}
|
|
53
|
+
handleAccordionChange(event) {
|
|
54
|
+
var _a;
|
|
55
|
+
const parentAccordionId = (_a = this.el.closest('[data-id]')) === null || _a === void 0 ? void 0 : _a.getAttribute('data-id');
|
|
56
|
+
if (event.detail.id !== parentAccordionId)
|
|
57
|
+
return;
|
|
58
|
+
this.isOpen = event.detail.opened.has(this.value);
|
|
59
|
+
}
|
|
60
|
+
toggle() {
|
|
61
|
+
var _a, _b;
|
|
62
|
+
if (this.disabled)
|
|
63
|
+
return;
|
|
64
|
+
this.isOpen = !this.isOpen;
|
|
65
|
+
(_b = (_a = this.el.closest('xv-accordion-v2')) === null || _a === void 0 ? void 0 : _a.toggleItem) === null || _b === void 0 ? void 0 : _b.call(_a, this.value);
|
|
66
|
+
}
|
|
67
|
+
render() {
|
|
68
|
+
return (index.h(index.Host, { key: '7d536c27a29b4f1e5a54ffb38c485102a4b22301', class: `${this.disabled ? 'disabled' : ''}` }, index.h("label", { key: 'bd35f139baa3fa9449e4391acb26ceffbeee61c4', class: `label ${this.isOpen ? 'opened' : 'closed'}`, onClick: this.toggle.bind(this) }, index.h("span", { key: '4b2a948ec962246557b480308e1a7df9712806a1' }, this.label)), index.h("div", { key: 'b88b7c9c9c724b6d6468c59df391c7ec41c99e97', class: `content ${this.isOpen ? 'opened' : 'closed'}` }, index.h("slot", { key: '61cb22aabcf159a31bab0a6cca01dc5478a580f1' }))));
|
|
69
|
+
}
|
|
70
|
+
get el() { return index.getElement(this); }
|
|
71
|
+
};
|
|
72
|
+
XvAccordionItem.style = XvAccordionV2ItemStyle0;
|
|
73
|
+
|
|
74
|
+
const xvButtonV2Css = "@charset \"UTF-8\";:host{--focus-border-width:2px;--focus-border-style:solid;--button-ghost:tarnsparent;--text-disabled-opacity:0.25;--button-border-radius:3px;--button-border-width:1px;--button-border-style:solid;--button-border-color-accent:#97BF0D;--button-border-color-primary:#273435;--button-border-color-secondary:#D1D1D1;--button-border-color-ghost:tarnsparent;--button-ghost-hover:tarnsparent;--button-ghost-active:rgba(139, 139, 139, 0.5);--button-accent-disabled:#D1D1D1;--button-primary-disabled:#D1D1D1;--button-secondary-disabled:#D1D1D1;--button-tertiary-disabled:tarnsparent;--button-ghost-disabled:tarnsparent}:host button{font-family:inherit;font-size:16px;font-weight:700;padding:0 20px;min-height:40px;line-height:40px;cursor:pointer;box-sizing:border-box;transition:background-color 0.2s ease-in-out, filter 0.2s ease-in-out, transform 0.1s ease-in-out, border-color 0.2s ease-in-out, border-width 0.2s ease-in-out, box-shadow 0.2s ease-in-out}:host button.xv-button-block{width:100%}.xv-button{}.xv-button.accent{background-color:var(--button-accent);color:var(--text-on-color);border:var(--button-border-width) var(--button-border-style) var(--button-border-color-accent);border-radius:var(--button-border-radius)}.xv-button.accent:hover{background-color:var(--button-accent-hover)}.xv-button.accent:active{background-color:var(--button-accent-active);color:var(--text-on-color)}.xv-button.accent:focus{outline:none;border:var(--focus-border-width) var(--focus-border-style) var(--focus);transition:border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out}.xv-button.accent:disabled{background-color:var(--button-accent-disabled);color:var(--text-on-color-disabled);border:var(--button-border-width) var(--button-border-style) var(--button-accent-disabled)}.xv-button.primary{background-color:var(--button-primary);color:var(--text-on-color);border:var(--button-border-width) var(--button-border-style) var(--button-border-color-primary);border-radius:var(--button-border-radius)}.xv-button.primary:hover{background-color:var(--button-primary-hover)}.xv-button.primary:active{background-color:var(--button-primary-active)}.xv-button.primary:focus{outline:none;border:var(--focus-border-width) var(--focus-border-style) var(--focus);transition:border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out}.xv-button.primary:disabled{background-color:var(--button-primary-disabled);color:var(--text-on-color-disabled);border:var(--button-border-width) var(--button-border-style) var(--button-primary-disabled)}.xv-button.secondary{background-color:var(--button-secondary);color:var(--text-primary);border:var(--button-border-width) var(--button-border-style) var(--button-border-color-secondary);border-radius:var(--button-border-radius)}.xv-button.secondary:hover{background-color:var(--button-secondary-hover)}.xv-button.secondary:active{background-color:var(--button-secondary-active)}.xv-button.secondary:focus{outline:none;border:var(--focus-border-width) var(--focus-border-style) var(--focus);transition:border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out}.xv-button.secondary:disabled{background-color:var(--button-secondary-disabled);color:var(--text-on-color-disabled)}.xv-button.tertiary{background-color:var(--button-ghost);color:var(--text-primary);border:var(--button-border-width) var(--button-border-style) var(--button-tertiary);border-radius:var(--button-border-radius)}.xv-button.tertiary:hover{background-color:var(--button-tertiary-hover)}.xv-button.tertiary:active{background-color:var(--button-tertiary-active)}.xv-button.tertiary:focus{outline:none;border:var(--focus-border-width) var(--focus-border-style) var(--focus);transition:border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out}.xv-button.tertiary:disabled{background-color:var(--button-tertiary-disabled);color:var(--text-disabled);opacity:var(--text-disabled-opacity)}.xv-button.ghost{background-color:var(--button-ghost);color:var(--text-primary);border:var(--button-border-width) var(--button-border-style) var(--button-border-color-ghost);border-radius:var(--button-border-radius)}.xv-button.ghost:hover{background-color:var(--button-ghost-hover)}.xv-button.ghost:active{background-color:var(--button-ghost-active)}.xv-button.ghost:focus{outline:none;border:var(--focus-border-width) var(--focus-border-style) var(--focus);transition:border-color 0.2s ease-in-out}.xv-button.ghost:disabled{background-color:var(--button-ghost-disabled);color:var(--text-disabled);opacity:var(--text-disabled-opacity)}";
|
|
75
|
+
const XvButtonV2Style0 = xvButtonV2Css;
|
|
76
|
+
|
|
77
|
+
const XvButton = class {
|
|
78
|
+
constructor(hostRef) {
|
|
79
|
+
index.registerInstance(this, hostRef);
|
|
80
|
+
this.buttonClick = index.createEvent(this, "buttonClick", 7);
|
|
81
|
+
/** Button label */
|
|
82
|
+
this.label = '';
|
|
83
|
+
/** Container width Button */
|
|
84
|
+
this.block = false;
|
|
85
|
+
/** Variant */
|
|
86
|
+
this.variant = 'primary';
|
|
87
|
+
/** Disabled state */
|
|
88
|
+
this.disabled = false;
|
|
89
|
+
/** Handle click only if not disabled */
|
|
90
|
+
this.handleClick = () => {
|
|
91
|
+
if (this.disabled) {
|
|
92
|
+
return;
|
|
93
|
+
}
|
|
94
|
+
this.buttonClick.emit();
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
render() {
|
|
98
|
+
return (index.h("button", { key: '4b6d2d71bd297a7b1e2a00ba36c8e4380395e696', class: `xv-button ${this.variant} ${this.block ? 'xv-button-block' : ''}`, disabled: this.disabled, onClick: this.handleClick }, index.h("slot", { key: '2934a04fa4aae539014f0a283444903dc9807888', name: "icon-left" }), index.h("slot", { key: '7139fa048b1f6e10f45853f7d1ff3b8cef1b9db6' }, this.label), index.h("slot", { key: 'ff326b3d02d3c4102f85132b890a595fcfec08d4', name: "icon-right" })));
|
|
99
|
+
}
|
|
100
|
+
};
|
|
101
|
+
XvButton.style = XvButtonV2Style0;
|
|
102
|
+
|
|
103
|
+
const xvCardCss = ":host{display:flex;flex-direction:column;border-radius:8px;border:1px solid var(--border-subtle-00);background:var(--layer-layer-02);box-shadow:0 1px 3px 1px rgba(39, 52, 53, 0.15), 0 1px 2px 0 rgba(39, 52, 53, 0.3);font-family:var(--ff-body, inherit);overflow:visible !important}:host(.xv-card_vertical){width:100% !important}:host(.xv-card_horizontal){flex-direction:row;display:flex;width:max-content}:host(.xv-card_horizontal) .xv-card_media__content,:host(.xv-card_horizontal) .xv-card_media ::slotted([slot=media]){min-height:100%;max-height:100%;max-width:160px;min-width:160px}.xv-card_content{padding:16px;display:flex;flex-direction:column;flex:1;text-align:left}.xv-card_media__content,.xv-card_media ::slotted([slot=media]){max-width:100%;min-width:100%;min-height:199px;max-height:199px;object-fit:cover;object-position:center}.xv-card_header__content,.xv-card_header ::slotted([slot=header]){margin:0 0 8px;color:var(--text-primary);font-size:16px;font-style:normal;font-weight:700;line-height:24px;letter-spacing:-0.6px}.xv-card_body{flex:1}.xv-card_body__content,.xv-card_body ::slotted([slot=body]){margin:0 0 8px;color:var(--text-secondary);font-size:14px;font-style:normal;font-weight:400;line-height:20px;letter-spacing:-0.1px}";
|
|
104
|
+
const XvCardV2Style0 = xvCardCss;
|
|
105
|
+
|
|
106
|
+
const XvCard = class {
|
|
107
|
+
constructor(hostRef) {
|
|
108
|
+
index.registerInstance(this, hostRef);
|
|
109
|
+
this.variant = 'vertical';
|
|
110
|
+
}
|
|
111
|
+
render() {
|
|
112
|
+
return (index.h(index.Host, { key: '347b7aed9ce24e2e048bb4e6d0b07b23f0f60d5b', class: `xv-card xv-card_${this.variant}`, part: this.variant }, index.h("div", { key: '9cd9f38cfe7d93fc271907fc8435033df860c246', class: "xv-card_media" }, index.h("slot", { key: '35e2bae3084a0e7d26e13c0e3116daa9895ea6c1', name: "media" }, this.media && index.h("img", { key: '60d4305b136766e447653cb399f92ae70e3d9430', class: "xv-card_media__content", src: this.media, alt: this.header }))), index.h("div", { key: '3751defc0abf18997dca82ae5b5d6601c6e9f60b', class: "xv-card_content" }, index.h("div", { key: 'cca74475b9e5dba03c82f77851fb503a5323ce3c', class: "xv-card_header" }, index.h("slot", { key: '02c4e3ddfb73bd56ef8f5b44a22bfe710654171a', name: "header" }, this.header && index.h("p", { key: '56998aa4742cc7576a023fcbe3e0892f312805ee', class: "xv-card_header__content" }, this.header))), index.h("div", { key: '86da97df293ff58dbcfe0a2b7bc25c98053ac6a2', class: "xv-card_body" }, index.h("slot", { key: 'ff8d6dc3ef8e437d28f237c415bf43382df85f19', name: "body" }, this.body && index.h("p", { key: '7e8e351ac0fa2100fc7929e81cc380a4a32e7019', class: "xv-card_body__content" }, this.header))), index.h("div", { key: 'dc9824b523f2dbdb4f88dc05ac0e490f9b04f529', class: "xv-card_footer" }, index.h("slot", { key: 'ea4fbffc436ee2ef43f481be7656aad07dfc55ce', name: "footer" }, this.footer)))));
|
|
113
|
+
}
|
|
114
|
+
};
|
|
115
|
+
XvCard.style = XvCardV2Style0;
|
|
116
|
+
|
|
117
|
+
const XvCheckbox = class {
|
|
118
|
+
constructor(hostRef) {
|
|
119
|
+
index.registerInstance(this, hostRef);
|
|
120
|
+
}
|
|
121
|
+
applyGlobalStyles() {
|
|
122
|
+
var _a;
|
|
123
|
+
const globalStyle = document.getElementById("brand-style");
|
|
124
|
+
if (globalStyle) {
|
|
125
|
+
const styleClone = document.createElement("style");
|
|
126
|
+
styleClone.innerHTML = `@import url('${globalStyle.href}');`;
|
|
127
|
+
(_a = this.el.shadowRoot) === null || _a === void 0 ? void 0 : _a.appendChild(styleClone);
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
componentWillLoad() {
|
|
131
|
+
this.applyGlobalStyles();
|
|
132
|
+
}
|
|
133
|
+
render() {
|
|
134
|
+
return (index.h("label", { key: '854b175975d81eaa3dd16ab5e5e7ecb8075da6a2', class: "checkbox-container" }, index.h("input", { key: '4a40abb6dcec0a634d1e2d40878e877771ffd94d', type: "checkbox" }), index.h("span", { key: '473ce5b6240284f96d2b9a4d759ee18182470c10', class: "checkmark" }), index.h("slot", { key: '664f0b742f6ee4e2d71e984031052b9e746189b9' })));
|
|
135
|
+
}
|
|
136
|
+
get el() { return index.getElement(this); }
|
|
137
|
+
};
|
|
138
|
+
|
|
139
|
+
const xvLinkCss = ":host{font-family:var(--ff-body, inherit)}:host(.xv-link_inline){display:inline-block}:host(.xv-link_inline) .xv-link{text-decoration-line:underline;text-decoration-style:solid;text-decoration-skip-ink:none;text-decoration-thickness:auto;text-underline-offset:auto;text-underline-position:from-font}:host(.xv-link_standalone){display:block}:host(.xv-link_standalone) .xv-link{text-decoration-line:none}.xv-link{display:inline-flex;gap:8px;align-items:center;color:var(--link-primary);font-family:var(--ff-body);font-style:normal;font-weight:400;transition:color 200ms ease-in-out}.xv-link:active{color:var(--text-primary)}.xv-link:visited{color:var(--link-visted)}.xv-link:hover{color:var(--link-primary-hover);cursor:pointer}.xv-link:disabled,.xv-link_disabled,.xv-link::part(disabled){color:var(--text-disabled);pointer-events:none;cursor:initial}.xv-link.sm{font-size:var(--fz-sm);line-height:137.5%}.xv-link.md{font-size:var(--fz-md);line-height:128.571%}.xv-link.lg{font-size:var(--fz-lg);line-height:133.333%}";
|
|
140
|
+
const XvLinkV2Style0 = xvLinkCss;
|
|
141
|
+
|
|
142
|
+
const XvLink = class {
|
|
143
|
+
constructor(hostRef) {
|
|
144
|
+
index.registerInstance(this, hostRef);
|
|
145
|
+
this.disabled = false;
|
|
146
|
+
this.size = 'md';
|
|
147
|
+
this.variant = 'inline';
|
|
148
|
+
}
|
|
149
|
+
preventLinkHandler(e) {
|
|
150
|
+
if (!this.disabled)
|
|
151
|
+
return;
|
|
152
|
+
e.preventDefault();
|
|
153
|
+
e.stopPropagation();
|
|
154
|
+
}
|
|
155
|
+
render() {
|
|
156
|
+
return (index.h(index.Host, { key: 'da2418a05379b0510c46ede0992a67bdc4847238', class: `xv-link_${this.variant}` }, index.h("a", { key: '5632ecb0da02799b43fbdcfa522243502a6c2a7a', href: this.href, onClick: this.preventLinkHandler.bind(this), class: `xv-link ${this.disabled ? 'xv-link_disabled' : ''} ${this.size}`, target: this.target }, index.h("slot", { key: '15efb0b41fbc63459d83ec104a972b645541cc80', name: "icon-left" }), index.h("slot", { key: '47aab9fa38e9d637a2b6fd838e14805602343aea' }), index.h("slot", { key: 'a103c85ea4c15c83045b9e52d5dcf19fdff45076', name: "icon-right" }))));
|
|
157
|
+
}
|
|
158
|
+
};
|
|
159
|
+
XvLink.style = XvLinkV2Style0;
|
|
160
|
+
|
|
161
|
+
const xvProgressIndicatorCss = ":host{display:flex;align-items:flex-start;justify-content:space-between;font-family:var(--ff-body, inherit);overflow-x:auto}";
|
|
162
|
+
const XvProgressIndicatorV2Style0 = xvProgressIndicatorCss;
|
|
163
|
+
|
|
164
|
+
const XvProgressIndicator = class {
|
|
165
|
+
constructor(hostRef) {
|
|
166
|
+
index.registerInstance(this, hostRef);
|
|
167
|
+
this.progress = 0;
|
|
168
|
+
}
|
|
169
|
+
// Update 'xv-progress-indicator-item' done status
|
|
170
|
+
updateChildItems() {
|
|
171
|
+
const items = this.el.children;
|
|
172
|
+
const itemsCount = this.el.childElementCount;
|
|
173
|
+
const progressPerItem = 100 / itemsCount;
|
|
174
|
+
if (!items.length || !itemsCount)
|
|
175
|
+
return;
|
|
176
|
+
Array.from(items).forEach((item, index) => {
|
|
177
|
+
const itemProgress = (index + 1) * progressPerItem;
|
|
178
|
+
const done = this.progress >= itemProgress;
|
|
179
|
+
item.setAttribute('done', done ? 'true' : 'false');
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
// Load initial done status
|
|
183
|
+
componentDidLoad() {
|
|
184
|
+
this.updateChildItems();
|
|
185
|
+
}
|
|
186
|
+
render() {
|
|
187
|
+
return (index.h(index.Host, { key: '009b89bf21bd093b84040e6ede3be78d5c402f53', class: "xv-progress-indicator" }, index.h("slot", { key: '8ca75f700170c5aeb2da17133080fcde7e667947' })));
|
|
188
|
+
}
|
|
189
|
+
get el() { return index.getElement(this); }
|
|
190
|
+
static get watchers() { return {
|
|
191
|
+
"progress": ["updateChildItems"]
|
|
192
|
+
}; }
|
|
193
|
+
};
|
|
194
|
+
XvProgressIndicator.style = XvProgressIndicatorV2Style0;
|
|
195
|
+
|
|
196
|
+
const xvProgressIndicatorItemCss = ":host(.xv-progress-indicator-item){display:flex;flex:1;flex-direction:column;align-items:center;justify-content:center;position:relative;padding:10px 16px}:host(.xv-progress-indicator-item):before{width:100%}:host(.xv-progress-indicator-item):before,:host(.xv-progress-indicator-item) .line{content:\"\";z-index:1;display:inline-block;position:absolute;top:0;left:0;right:0;height:2px;color:inherit;background-color:var(--border-subtle-01, grey)}:host(.xv-progress-indicator-item) .line{width:0;color:inherit;transition:width 250ms ease;background-color:var(--background-brand, currentColor)}:host(.xv-progress-indicator-item) .icon{display:flex;align-items:center;justify-content:center;width:22px;height:22px;max-width:22px;max-height:22px;border:2px dashed var(--icon-primary, currentColor);border-radius:50%}:host(.xv-progress-indicator-item) .icon svg{opacity:0;transition:opacity 500ms ease-in-out}:host(.xv-progress-indicator-item) .label{color:var(--text-primary);font-size:14px;font-style:normal;font-weight:400;line-height:18px;letter-spacing:0.16px}:host(.done) .icon{border-color:var(--background-brand, currentColor);color:var(--background-brand, inherit);border-style:solid}:host(.done) .icon svg{opacity:1}:host(.done) .line{width:100% !important;background-color:var(--background-brand, currentColor)}";
|
|
197
|
+
const XvProgressIndicatorV2ItemStyle0 = xvProgressIndicatorItemCss;
|
|
198
|
+
|
|
199
|
+
const XvProgressIndicatorItem = class {
|
|
200
|
+
constructor(hostRef) {
|
|
201
|
+
index.registerInstance(this, hostRef);
|
|
202
|
+
this.done = false;
|
|
203
|
+
}
|
|
204
|
+
render() {
|
|
205
|
+
return (index.h(index.Host, { key: 'e18a645a83758b1e6d1c1fe32e3aab8e75ff3e7b', class: `xv-progress-indicator-item ${this.done ? 'done' : ''}` }, index.h("span", { key: '000bfef67379218d2af3c3393432dbfc46c20707', class: "line" }), index.h("span", { key: 'c1056a34648ab5b55ddb56faa30f5be8ecae83cf', class: "icon" }, index.h("svg", { key: 'ce1d729b7464f044808577460714d279374a7e9f', xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 448 512", width: 14, height: 14 }, index.h("path", { key: 'c67e17743357ccd75295b3d1f354e6f8096dbde8', fill: "currentColor", d: "M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z" }))), index.h("p", { key: '593c6a4c187148315cade226fc7f272462445a0e', class: "label" }, index.h("slot", { key: 'c3ed988d5cc8722e5bd5200646bd5c824921dd27' }))));
|
|
206
|
+
}
|
|
207
|
+
get el() { return index.getElement(this); }
|
|
208
|
+
};
|
|
209
|
+
XvProgressIndicatorItem.style = XvProgressIndicatorV2ItemStyle0;
|
|
210
|
+
|
|
211
|
+
const xvTagCss = "@charset \"UTF-8\";:host{display:inline-flex;align-items:center;justify-content:space-between;border-radius:1000px;background-color:var(--background);color:var(--text-primary);font-family:var(--ff-body, inherit)}:host .xv-tag_content{padding-left:8px;padding-right:8px;color:inherit;font-family:var(--ff-body);font-style:normal;font-weight:400;line-height:16px;letter-spacing:0.32px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}:host .xv-tag_close{box-sizing:border-box;text-decoration:none;border:none;background-color:inherit;outline:none;border-spacing:0;list-style:none outside none;margin:0;padding:0;display:inline-flex;align-items:center;justify-content:center;border-radius:62px;width:15px;height:15px;text-align:left;color:inherit;text-indent:0;transition:opacity 300ms ease-in-out, filter 300ms ease-in-out}:host .xv-tag_close:hover{cursor:pointer;filter:brightness(80%)}:host .xv-tag_close:active{opacity:0.7}:host .xv-tag_close:focus{outline:1px solid currentColor}:host .xv-tag_close:after{overflow:hidden;width:inherit;height:inherit;color:inherit;font-size:16px;display:inline-flex;align-items:center;justify-content:center;content:\"×\"}:host(.sm){font-size:var(--fz-sm)}:host(.md){font-size:var(--fz-md)}:host(.md) .xv-tag_content{line-height:24px}:host(.md) .xv-tag_close{height:24px;width:24px}:host(.lg){font-size:var(--fz-lg)}:host(.lg) .xv-tag_content{line-height:26px}:host(.lg) .xv-tag_close{height:26px;width:26px}:host(.disabled){pointer-events:none;background-color:var(--layer-01);color:var(--text-disabled)}";
|
|
212
|
+
const XvTagV2Style0 = xvTagCss;
|
|
213
|
+
|
|
214
|
+
const XvTag = class {
|
|
215
|
+
constructor(hostRef) {
|
|
216
|
+
index.registerInstance(this, hostRef);
|
|
217
|
+
this.closeClick = index.createEvent(this, "closeClick", 7);
|
|
218
|
+
this.size = 'md';
|
|
219
|
+
this.color = '';
|
|
220
|
+
this.bg = '';
|
|
221
|
+
this.disabled = false;
|
|
222
|
+
this.closeable = false;
|
|
223
|
+
}
|
|
224
|
+
closeHandler(e) {
|
|
225
|
+
if (this.disabled)
|
|
226
|
+
return;
|
|
227
|
+
this.closeClick.emit(e);
|
|
228
|
+
}
|
|
229
|
+
render() {
|
|
230
|
+
return (index.h(index.Host, { key: '429e196f85e0b46f65822519d0e363671fd60a77', style: { color: this.color, background: this.bg }, class: `xv-tag ${this.disabled ? 'disabled' : ''} ${this.size}` }, index.h("div", { key: 'b2b919d599e662e07fad0cc0d2e933926911aea9', class: "xv-tag_content" }, index.h("slot", { key: '717f8e980099bb813a12342015661e9914cc1330' })), this.closeable && (index.h("button", { key: '31ea0d38544c9b422fcab3dd92718de0e4005be8', onClick: this.closeHandler.bind(this), class: "xv-tag_close" }))));
|
|
231
|
+
}
|
|
232
|
+
};
|
|
233
|
+
XvTag.style = XvTagV2Style0;
|
|
234
|
+
|
|
235
|
+
const xvTooltipCss = ":host{position:relative;display:inline-block;cursor:pointer;line-height:0.5}:host::before,:host::after{position:absolute;opacity:0;visibility:hidden;transition:opacity 0.2s ease-in-out, transform 0.2s ease-in-out;z-index:10}:host::before{content:attr(tooltip);background:var(--background-inverse, #333);color:var(--icon-inverse, #fff);padding:var(--gap-sm, 5px) var(--gap-md, 16px);border-radius:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:70vw;font-family:var(--fz-body, Tahoma);font-size:var(fz-md, 14px);font-weight:400;line-height:18px;letter-spacing:0.16px}:host::after{content:\"\";border:6px solid transparent}:host(:hover)::before,:host(:hover)::after,:host(:focus)::before,:host(:focus)::after{opacity:1;visibility:visible}:host(.xv-tooltip_top)::before{bottom:100%;left:50%;transform:translateX(-50%) translateY(-5px)}:host(.xv-tooltip_top)::after{bottom:100%;left:50%;border-top-color:var(--background-inverse, #333);transform:translateX(-50%) translateY(5px)}:host(.xv-tooltip_top-left)::before{bottom:100%;left:0;transform:translateY(-5px)}:host(.xv-tooltip_top-left)::after{bottom:100%;left:10px;border-top-color:black;transform:translateY(5px)}:host(.xv-tooltip_top-right)::before{bottom:100%;right:0;transform:translateY(-5px)}:host(.xv-tooltip_top-right)::after{bottom:100%;right:10px;border-top-color:var(--background-inverse, #333);transform:translateY(5px)}:host(.xv-tooltip_bottom)::before{top:100%;left:50%;transform:translateX(-50%) translateY(5px)}:host(.xv-tooltip_bottom)::after{top:100%;left:50%;border-bottom-color:black;transform:translateX(-50%) translateY(-5px)}:host(.xv-tooltip_bottom-left)::before{top:100%;left:0;transform:translateY(5px)}:host(.xv-tooltip_bottom-left)::after{top:100%;left:10px;border-bottom-color:var(--background-inverse, #333);transform:translateY(-5px)}:host(.xv-tooltip_bottom-right)::before{top:100%;right:0;transform:translateY(5px)}:host(.xv-tooltip_bottom-right)::after{top:100%;right:10px;border-bottom-color:var(--background-inverse, #333);transform:translateY(-5px)}:host(.xv-tooltip_left)::before{right:100%;top:50%;transform:translateY(-50%) translateX(-5px)}:host(.xv-tooltip_left)::after{right:100%;top:50%;border-left-color:var(--background-inverse, #333);transform:translateY(-50%) translateX(5px)}:host(.xv-tooltip_right)::before{left:100%;top:50%;transform:translateY(-50%) translateX(5px)}:host(.xv-tooltip_right)::after{left:100%;top:50%;border-right-color:var(--background-inverse, #333);transform:translateY(-50%) translateX(-5px)}";
|
|
236
|
+
const XvTooltipV2Style0 = xvTooltipCss;
|
|
237
|
+
|
|
238
|
+
const XvTooltip = class {
|
|
239
|
+
constructor(hostRef) {
|
|
240
|
+
index.registerInstance(this, hostRef);
|
|
241
|
+
/**
|
|
242
|
+
* Tooltip and arrow position related to element
|
|
243
|
+
* possible options: 'top' | 'top-left' | 'top-right' | 'bottom' | 'bottom-left' | 'bottom-right' | 'left' | 'right'.
|
|
244
|
+
* By default, "top"
|
|
245
|
+
*/
|
|
246
|
+
this.position = 'top';
|
|
247
|
+
}
|
|
248
|
+
render() {
|
|
249
|
+
return (index.h(index.Host, { key: '3896748ac459f1b401b4cd59b5ff163640811dce', tooltip: this.message, class: `xv-tooltip_${this.position}` }, index.h("slot", { key: '458ac3f69fe0b595af5bfbf16b7b99614a84bb8c' }, index.h("svg", { key: '32561cbbb87adcd9ef493a81c3edfd7e9c1f71ed', xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: 16, height: 16 }, index.h("path", { key: 'cb38fdc43b099b8fa080bf8a48fb736ff2c2cf80', fill: "currentColor", d: "M256 48a208 208 0 1 1 0 416 208 208 0 1 1 0-416zm0 464A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM216 336c-13.3 0-24 10.7-24 24s10.7 24 24 24l80 0c13.3 0 24-10.7 24-24s-10.7-24-24-24l-8 0 0-88c0-13.3-10.7-24-24-24l-48 0c-13.3 0-24 10.7-24 24s10.7 24 24 24l24 0 0 64-24 0zm40-144a32 32 0 1 0 0-64 32 32 0 1 0 0 64z" })))));
|
|
250
|
+
}
|
|
251
|
+
};
|
|
252
|
+
XvTooltip.style = XvTooltipV2Style0;
|
|
253
|
+
|
|
254
|
+
exports.xv_accordion_v2 = XvAccordion;
|
|
255
|
+
exports.xv_accordion_v2_item = XvAccordionItem;
|
|
256
|
+
exports.xv_button_v2 = XvButton;
|
|
257
|
+
exports.xv_card_v2 = XvCard;
|
|
258
|
+
exports.xv_checkbox_v2 = XvCheckbox;
|
|
259
|
+
exports.xv_link_v2 = XvLink;
|
|
260
|
+
exports.xv_progress_indicator_v2 = XvProgressIndicator;
|
|
261
|
+
exports.xv_progress_indicator_v2_item = XvProgressIndicatorItem;
|
|
262
|
+
exports.xv_tag_v2 = XvTag;
|
|
263
|
+
exports.xv_tooltip_v2 = XvTooltip;
|
|
264
|
+
|
|
265
|
+
//# sourceMappingURL=xv-accordion-v2_10.cjs.entry.js.map
|