@eox/itemfilter 1.8.0 → 1.9.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/dist/eox-itemfilter.js +1045 -1028
- package/dist/eox-itemfilter.umd.cjs +131 -132
- package/package.json +2 -1
- package/src/components/results.js +1 -1
- package/src/main.js +1 -1
- package/src/methods/results/create.js +7 -6
- package/src/style.eox.js +48 -53
- package/types/main.d.ts +1 -1
- package/types/methods/results/create.d.ts +2 -2
- package/types/methods/results/create.d.ts.map +1 -1
- package/types/style.eox.d.ts +1 -1
- package/types/style.eox.d.ts.map +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eox/itemfilter",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.9.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"devDependencies": {
|
|
6
6
|
"@types/geojson": "^7946.0.14",
|
|
@@ -48,6 +48,7 @@
|
|
|
48
48
|
"toolcool-range-slider": "^4.0.27"
|
|
49
49
|
},
|
|
50
50
|
"peerDependencies": {
|
|
51
|
+
"@eox/layout": "*",
|
|
51
52
|
"@eox/map": "*"
|
|
52
53
|
}
|
|
53
54
|
}
|
|
@@ -78,7 +78,7 @@ export class EOxItemFilterResults extends LitElement {
|
|
|
78
78
|
* Creates a list of items based on the aggregation property.
|
|
79
79
|
*
|
|
80
80
|
* @param {string} [aggregationProperty] - The property used for aggregation.
|
|
81
|
-
* @returns {import("lit").
|
|
81
|
+
* @returns {import("lit").TemplateResult} - The template result for the item list.
|
|
82
82
|
*/
|
|
83
83
|
#createItemList(aggregationProperty) {
|
|
84
84
|
return createItemListMethod(this, aggregationProperty);
|
package/src/main.js
CHANGED
|
@@ -238,7 +238,7 @@ export class EOxItemFilter extends LitElement {
|
|
|
238
238
|
this.expandMultipleResults = true;
|
|
239
239
|
|
|
240
240
|
/**
|
|
241
|
-
* Rendering type for results
|
|
241
|
+
* Rendering type for results. Can be `list`or `cards` (`cards` requires also importing the `eox-layout` element)
|
|
242
242
|
*
|
|
243
243
|
* @type String
|
|
244
244
|
*/
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { html, nothing } from "lit";
|
|
2
|
+
import { html as staticHtml, unsafeStatic } from "lit/static-html.js";
|
|
2
3
|
import { repeat } from "lit/directives/repeat.js";
|
|
3
4
|
import { when } from "lit/directives/when.js";
|
|
4
5
|
import { unsafeHTML } from "lit/directives/unsafe-html.js";
|
|
@@ -44,7 +45,7 @@ export function createItemDetailsMethod(
|
|
|
44
45
|
*
|
|
45
46
|
* @param {Object} EOxItemFilterResults - The EOxItemFilterResults component instance.
|
|
46
47
|
* @param {string} [aggregationProperty] - The property used for aggregation.
|
|
47
|
-
* @returns {import("lit").
|
|
48
|
+
* @returns {import("lit").TemplateResult} The HTML template for the item list view.
|
|
48
49
|
*/
|
|
49
50
|
export function createItemListMethod(
|
|
50
51
|
EOxItemFilterResults,
|
|
@@ -63,13 +64,13 @@ export function createItemListMethod(
|
|
|
63
64
|
? "highlighted"
|
|
64
65
|
: nothing;
|
|
65
66
|
|
|
66
|
-
return
|
|
67
|
-
|
|
67
|
+
return staticHtml`
|
|
68
|
+
${EOxItemFilterResults.resultType === "cards" ? unsafeStatic(`<eox-layout fill-grid>`) : unsafeStatic(`<ul>`)}
|
|
68
69
|
${repeat(
|
|
69
70
|
items,
|
|
70
71
|
(item) => item.id,
|
|
71
|
-
(item) =>
|
|
72
|
-
|
|
72
|
+
(item) => staticHtml`
|
|
73
|
+
${EOxItemFilterResults.resultType === "cards" ? unsafeStatic(`<eox-layout-item`) : unsafeStatic(`<li`)}
|
|
73
74
|
class=${className(item)}
|
|
74
75
|
@click=${() => {
|
|
75
76
|
if (EOxItemFilterResults.selectedResult === item) {
|
|
@@ -145,6 +146,6 @@ export function createItemListMethod(
|
|
|
145
146
|
</li>
|
|
146
147
|
`,
|
|
147
148
|
)}
|
|
148
|
-
|
|
149
|
+
${EOxItemFilterResults.resultType === "cards" ? unsafeStatic(`</eox-layout>`) : unsafeStatic(`</ul>`)}
|
|
149
150
|
`;
|
|
150
151
|
}
|
package/src/style.eox.js
CHANGED
|
@@ -54,10 +54,6 @@ li span {
|
|
|
54
54
|
display: flex;
|
|
55
55
|
align-items: center;
|
|
56
56
|
}
|
|
57
|
-
.cards li span {
|
|
58
|
-
display: block;
|
|
59
|
-
flex-basis: 100%;
|
|
60
|
-
}
|
|
61
57
|
li label {
|
|
62
58
|
display: flex;
|
|
63
59
|
align-items: center;
|
|
@@ -81,23 +77,11 @@ details > summary::-webkit-details-marker {
|
|
|
81
77
|
align-items: center;
|
|
82
78
|
text-transform: var(--text-transform);
|
|
83
79
|
}
|
|
84
|
-
.cards .title {
|
|
85
|
-
font-size: 16px;
|
|
86
|
-
font-weight: 600;
|
|
87
|
-
text-wrap: auto;
|
|
88
|
-
line-height: 19px;
|
|
89
|
-
}
|
|
90
80
|
.subtitle {
|
|
91
81
|
font-size: 11px;
|
|
92
82
|
opacity: .7;
|
|
93
83
|
margin-top: 6px;
|
|
94
84
|
}
|
|
95
|
-
.cards .subtitle {
|
|
96
|
-
font-size: 14px;
|
|
97
|
-
color: #757575;
|
|
98
|
-
text-wrap: auto;
|
|
99
|
-
line-height: 19px;
|
|
100
|
-
}
|
|
101
85
|
.image {
|
|
102
86
|
width: 24px;
|
|
103
87
|
height: 24px;
|
|
@@ -105,20 +89,6 @@ details > summary::-webkit-details-marker {
|
|
|
105
89
|
overflow: hidden;
|
|
106
90
|
margin-right: 8px;
|
|
107
91
|
}
|
|
108
|
-
.cards .image {
|
|
109
|
-
width: 100%;
|
|
110
|
-
height: 190px;
|
|
111
|
-
margin-bottom: 8px;
|
|
112
|
-
}
|
|
113
|
-
.cards .result-action {
|
|
114
|
-
position: absolute;
|
|
115
|
-
top: 0;
|
|
116
|
-
right: 0;
|
|
117
|
-
margin: 10px 12px;
|
|
118
|
-
padding: 6px;
|
|
119
|
-
background: white;
|
|
120
|
-
border-radius: 50%;
|
|
121
|
-
}
|
|
122
92
|
.title-container {
|
|
123
93
|
display: flex;
|
|
124
94
|
flex-direction: column;
|
|
@@ -201,7 +171,7 @@ ul#results li {
|
|
|
201
171
|
display: flex;
|
|
202
172
|
justify-content: space-between;
|
|
203
173
|
}
|
|
204
|
-
ul#results
|
|
174
|
+
ul#results .result-action {
|
|
205
175
|
display: flex;
|
|
206
176
|
align-items: center;
|
|
207
177
|
height: fit-content;
|
|
@@ -209,35 +179,60 @@ ul#results li .result-action {
|
|
|
209
179
|
opacity: .5;
|
|
210
180
|
transition: opacity .3s ease-in-out;
|
|
211
181
|
}
|
|
212
|
-
ul#results
|
|
182
|
+
ul#results .result-action:hover {
|
|
213
183
|
opacity: 1;
|
|
214
184
|
}
|
|
215
|
-
ul#results
|
|
185
|
+
ul#results .highlighted .result-action > * {
|
|
216
186
|
filter: invert(1);
|
|
217
187
|
}
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
width:
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
}
|
|
226
|
-
ul#results ul.cards li {
|
|
227
|
-
flex-basis: calc(33.3% - 77px);
|
|
228
|
-
min-width: 0;
|
|
229
|
-
align-self: flex-start;
|
|
188
|
+
eox-layout {
|
|
189
|
+
padding: .5rem var(--padding);
|
|
190
|
+
gap: var(--card-gap, 16px);
|
|
191
|
+
--column-width: var(--card-width, 300px);
|
|
192
|
+
--row-height: var(--card-height, 200px);
|
|
193
|
+
}
|
|
194
|
+
eox-layout-item {
|
|
230
195
|
position: relative;
|
|
196
|
+
border-radius: var(--card-border-radius, 8px);
|
|
231
197
|
}
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
198
|
+
eox-layout-item .image {
|
|
199
|
+
width: 100%;
|
|
200
|
+
height: 100%;
|
|
201
|
+
transition: filter .3s ease-in-out;
|
|
202
|
+
margin: 0;
|
|
203
|
+
}
|
|
204
|
+
eox-layout-item:hover .image {
|
|
205
|
+
filter: brightness(.5);
|
|
206
|
+
}
|
|
207
|
+
eox-layout-item .title-container {
|
|
208
|
+
position: absolute;
|
|
209
|
+
bottom: 0;
|
|
210
|
+
color: white;
|
|
211
|
+
padding: 20px;
|
|
212
|
+
box-sizing: border-box;
|
|
213
|
+
width: 100%;
|
|
214
|
+
background: linear-gradient(
|
|
215
|
+
to top,
|
|
216
|
+
rgba(0, 0, 0, 0.85),
|
|
217
|
+
transparent
|
|
218
|
+
);
|
|
219
|
+
padding-top: 25px;
|
|
220
|
+
}
|
|
221
|
+
eox-layout-item .title {
|
|
222
|
+
font-weight: bold;
|
|
223
|
+
}
|
|
224
|
+
eox-layout-item .result-action {
|
|
225
|
+
position: absolute;
|
|
226
|
+
top: 20px;
|
|
227
|
+
right: 20px;
|
|
228
|
+
background: #ffffffbb;
|
|
229
|
+
padding: 8px;
|
|
230
|
+
width: 24px;
|
|
231
|
+
height: 24px;
|
|
232
|
+
border-radius: 50%;
|
|
236
233
|
}
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
flex-basis: 100%;
|
|
240
|
-
}
|
|
234
|
+
ul#results eox-layout-item.highlighted .result-action > * {
|
|
235
|
+
filter: none;
|
|
241
236
|
}
|
|
242
237
|
section {
|
|
243
238
|
position: relative;
|
package/types/main.d.ts
CHANGED
|
@@ -240,7 +240,7 @@ export class EOxItemFilter extends LitElement {
|
|
|
240
240
|
*/
|
|
241
241
|
expandMultipleResults: boolean;
|
|
242
242
|
/**
|
|
243
|
-
* Rendering type for results
|
|
243
|
+
* Rendering type for results. Can be `list`or `cards` (`cards` requires also importing the `eox-layout` element)
|
|
244
244
|
*
|
|
245
245
|
* @type String
|
|
246
246
|
*/
|
|
@@ -11,7 +11,7 @@ export function createItemDetailsMethod(aggregationProperty: string, EOxItemFilt
|
|
|
11
11
|
*
|
|
12
12
|
* @param {Object} EOxItemFilterResults - The EOxItemFilterResults component instance.
|
|
13
13
|
* @param {string} [aggregationProperty] - The property used for aggregation.
|
|
14
|
-
* @returns {import("lit").
|
|
14
|
+
* @returns {import("lit").TemplateResult} The HTML template for the item list view.
|
|
15
15
|
*/
|
|
16
|
-
export function createItemListMethod(EOxItemFilterResults: any, aggregationProperty?: string): import("lit").
|
|
16
|
+
export function createItemListMethod(EOxItemFilterResults: any, aggregationProperty?: string): import("lit").TemplateResult;
|
|
17
17
|
//# sourceMappingURL=create.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../../src/methods/results/create.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../../src/methods/results/create.js"],"names":[],"mappings":"AAOA;;;;;;GAMG;AACH,6DAJW,MAAM,8BAEJ,OAAO,KAAK,EAAE,kBAAkB,CA4B5C;AAED;;;;;;GAMG;AACH,sFAHW,MAAM,GACJ,OAAO,KAAK,EAAE,cAAc,CAuGxC"}
|
package/types/style.eox.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const styleEOX: "\n:host, :root {\n --item-color: color-mix(\n in srgb,\n var(--primary-color) 10%,\n transparent\n );\n --item-hover-color: color-mix(\n in srgb,\n var(--secondary-color) 30%,\n transparent\n );\n --item-select-color: var(--primary-color);\n --inline-bg-color: color-mix(\n in srgb,\n var(--secondary-color) 10%,\n transparent\n );\n --border-color: color-mix(\n in srgb,\n #000000 20%,\n transparent\n );\n --background-color: var(--eox-background-color, transparent);\n --padding: 0.5rem;\n --text-transform: capitalize;\n --form-flex-direction: column;\n --filter-display: block;\n background-color: var(--background-color);\n}\n* {\n font-family: Roboto, sans-serif;\n}\nform#itemfilter {\n flex-direction: var(--form-flex-direction);\n}\neox-itemfilter-container {\n min-width: 200px;\n display: var(--filter-display);\n}\neox-itemfilter-results {\n flex-grow: 1;\n}\nul {\n padding-left: 0;\n margin-top: 0;\n}\nli {\n list-style: none;\n}\nli span {\n text-overflow: ellipsis;\n white-space: nowrap;\n display: flex;\n align-items: center;\n}\n.cards li span {\n display: block;\n flex-basis: 100%;\n}\nli label {\n display: flex;\n align-items: center;\n}\ndetails summary > * {\n display: inline;\n}\ndetails summary {\n display: flex;\n align-items: center;\n border-bottom: 1px solid #0002;\n padding: .5rem var(--padding);\n}\n\ndetails > summary::-webkit-details-marker {\n display: none;\n}\n\n.title {\n font-size: 13px;\n align-items: center;\n text-transform: var(--text-transform);\n}\n.cards .title {\n font-size: 16px;\n font-weight: 600;\n text-wrap: auto;\n line-height: 19px;\n}\n.subtitle {\n font-size: 11px;\n opacity: .7;\n margin-top: 6px;\n}\n.cards .subtitle {\n font-size: 14px;\n color: #757575;\n text-wrap: auto;\n line-height: 19px;\n}\n.image {\n width: 24px;\n height: 24px;\n object-fit: cover;\n overflow: hidden;\n margin-right: 8px;\n}\n.cards .image {\n width: 100%;\n height: 190px;\n margin-bottom: 8px;\n}\n.cards .result-action {\n position: absolute;\n top: 0;\n right: 0;\n margin: 10px 12px;\n padding: 6px;\n background: white;\n border-radius: 50%;\n}\n.title-container {\n display: flex;\n flex-direction: column;\n}\nh6.main-heading {\n font-size: 1rem;\n margin-block-start: 1.33em;\n margin-block-end: 1.33em;\n margin-top: var(--padding);\n padding: 0 var(--padding);\n}\ndetails summary .title {\n display: flex;\n font-weight: 500;\n}\ndetails.details-filter summary::after,\ndetails.details-results summary::before {\n content: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%230009' viewBox='0 0 24 24'%3E%3Ctitle%3Echevron-right%3C/title%3E%3Cpath d='M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z' /%3E%3C/svg%3E\");\n height: 24px;\n width: 24px;\n}\ndetails.details-filter summary::after {\n margin-left: auto;\n transform: rotate(90deg);\n}\ndetails[open] summary::before {\n transform: rotate(90deg);\n}\ndetails[open] summary::after {\n transform: rotate(270deg);\n}\neox-itemfilter-expandcontainer {\n max-height: 200px;\n}\neox-itemfilter-expandcontainer > [data-type=filter] {\n display: block;\n height: calc(100% - 32px);\n overflow-y: auto;\n overflow-x: hidden;\n padding: 0 var(--padding);\n}\n[data-type=filter] .title,\ndetails summary {\n text-transform: var(--text-transform);\n}\nli,\nlabel,\ndetails,\ninput[type=\"checkbox\"],\ninput[type=\"radio\"] {\n cursor: pointer;\n}\ninput[type=\"checkbox\"],\ninput[type=\"radio\"] {\n margin: 0;\n}\ninput[type=\"text\"] {\n box-sizing: border-box;\n width: 100%;\n margin-top: 0.5rem;\n margin-bottom: 0.5rem;\n padding: 5px 7px;\n border-radius: 4px;\n border: 1px solid var(--border-color);\n}\nsection:not(section:last-of-type) {\n margin-bottom: 1rem;\n}\n#section-results {\n overflow: hidden;\n flex: 1;\n display: flex;\n flex-direction: column;\n}\nul:not(#filters) > li {\n padding: 5px 0;\n}\nul#results li {\n padding: 5px var(--padding);\n display: flex;\n justify-content: space-between;\n}\nul#results li .result-action {\n display: flex;\n align-items: center;\n height: fit-content;\n line-height: 1;\n opacity: .5;\n transition: opacity .3s ease-in-out;\n}\nul#results li .result-action:hover {\n opacity: 1;\n}\nul#results li.highlighted .result-action > * {\n filter: invert(1);\n}\nul#results ul.cards {\n display: flex;\n flex-wrap: wrap;\n width: 100%;\n gap: 40px;\n margin: 20px 0;\n cursor: initial;\n}\nul#results ul.cards li {\n flex-basis: calc(33.3% - 77px);\n min-width: 0;\n align-self: flex-start;\n position: relative;\n}\n@media screen and (max-width: 768px) {\n ul#results ul.cards li {\n flex-basis: calc(50% - 70px);\n }\n}\n@media screen and (max-width: 480px) {\n ul#results ul.cards li {\n flex-basis: 100%;\n }\n}\nsection {\n position: relative;\n background-color: var(--background-color);\n}\nbutton#filter-reset {\n position: absolute;\n top: 0;\n right: var(--padding);\n padding: 2px 10px;\n}\n.count {\n display: flex;\n justify-content: center;\n align-items: center;\n background: var(--secondary-color);\n padding: 0 12px;\n height: 20px;\n border-radius: 10px;\n color: var(--primary-color);\n font-weight: 500;\n margin-left: 9px;\n}\neox-itemfilter-range,\ntc-range-slider {\n align-items: center;\n display: block;\n}\ntc-range-slider {\n width: calc(100% - 16px);\n margin-left: 8px;\n margin-right: 8px;\n --width: 100%;\n}\n.range-before,\n.range-after {\n font-size: small;\n}\n.range-before,\n.range-after {\n margin: 1rem 0px;\n}\n\nbutton.reset-icon:before {\n content: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23004170' viewBox='0 0 24 24'%3E%3Ctitle%3Eclose%3C/title%3E%3Cpath d='M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z' /%3E%3C/svg%3E\");\n}\neox-itemfilter-expandcontainer button.reset-icon {\n margin-left: 4px;\n margin-top: -5px;\n height: 14px;\n width: 14px;\n}\neox-itemfilter-expandcontainer button.reset-icon:before {\n height: 14px;\n width: 14px;\n}\n.inline-content {\n border: 1.5px solid var(--secondary-color);\n border-radius: 4px;\n max-height: 300px;\n overflow-y: auto;\n background: var(--inline-bg-color);\n margin-top: 4px;\n padding: 8px;\n}\n.inline-container {\n position: relative;\n align-items: center;\n}\n.inline-container-wrapper {\n width: 100%;\n position: relative;\n}\n.inline-container {\n position: relative;\n border: 1px solid var(--border-color);\n border-radius: 4px;\n height: 24px;\n padding: 8px;\n flex: 1;\n justify-content: space-between;\n cursor: text;\n transition: all 0.2s ease-in-out;\n display: flex;\n}\n.inline-container:hover {\n border: 1px solid var(--primary-color);\n}\n[popover] {\n position: fixed;\n top: 0;\n left: 0;\n margin: 0;\n padding: 0;\n background-color: var(--background-color);\n border: none;\n}\n.input-container {\n display: flex;\n flex: 1;\n align-items: center;\n}\n.input-container input,\n.input-container input:focus {\n height: 100%;\n border: none;\n outline: none;\n border: 0;\n min-width: 25%;\n}\n.button-container {\n display: flex;\n align-items: center;\n justify-content: center;\n position: absolute;\n right: 1px;\n top: 5px;\n height: calc(100% - 10px);\n width: 34px;\n background: white;\n}\nbutton.icon {\n color: #004170;\n height: 24px;\n font-size: large;\n width: unset;\n}\n.inline-container::-webkit-scrollbar {\n height: 2px;\n}\n.inline-container::-webkit-scrollbar-thumb {\n background: lightgrey;\n border-radius: 2px;\n}\n.hidden {\n height: 0;\n padding: 0;\n border: none;\n}\n.hidden:hover {\n border: none;\n}\n.chip-title {\n pointer-events: none;\n text-transform: var(--text-transform);\n}\n.chip {\n display: flex;\n align-items: center;\n background: var(--item-color);\n border-radius: 30px;\n margin-right: 4px;\n padding: 5px 10px;\n font-size: small;\n cursor: default;\n white-space: nowrap;\n}\n.chip.highlighted {\n background: var(--primary-color);\n color: white;\n}\n.chip-close {\n cursor: pointer;\n font-weight: 600;\n position: absolute;\n right: -25px;\n background: white;\n top: 0;\n height: 100%;\n display: flex;\n align-items: center;\n height: 24px;\n width: 24px;\n}\n.chip-close:before {\n position: absolute;\n text-indent: 0;\n line-height: initial;\n height: 24px;\n width: 24px;\n content: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23004170' viewBox='0 0 24 24'%3E%3Ctitle%3Eclose%3C/title%3E%3Cpath d='M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z' /%3E%3C/svg%3E\");\n}\n.chip-container {\n position: relative;\n max-width: 75%;\n}\n.autocomplete-container,\n.text-container {\n position: relative;\n align-items: center;\n width: 100%;\n box-sizing: border-box;\n justify-content: space-between;\n cursor: text;\n margin-top: 0.5rem;\n margin-bottom: 0.5rem;\n background: white;\n}\n.autocomplete-container-wrapper,\n.text-container-wrapper {\n position: relative;\n display: flex;\n align-items: center;\n flex: 1;\n overflow-x: auto;\n -ms-overflow-style: none;\n scrollbar-width: none;\n}\n.autocomplete-container-wrapper::-webkit-scrollbar {\n display: none;\n}\n.chip-wrapper {\n -ms-overflow-style: none;\n scrollbar-width: none;\n}\n.chip-wrapper::-webkit-scrollbar {\n display: none;\n width: 0;\n background: transparent;\n}\n.autocomplete-input,\n.text-input {\n flex: 1;\n border: 1px solid var(--border-color);\n outline: none;\n box-sizing: border-box;\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n min-width: 150px;\n}\ninput[type=\"text\"].text-input,\ninput[type=\"text\"].autocomplete-input {\n padding: 9px 6px !important;\n border-radius: 4px;\n}\n.text-input:hover,\n.autocomplete-input:hover {\n border: 1px solid var(--primary-color);\n}\n.text-input:invalid {\n border: 1px solid red;\n}\n.selected-items {\n display: flex;\n flex-wrap: nowrap;\n gap: 4px;\n}\n.select li:hover,\n.multiselect li:hover,\neox-itemfilter-results li:hover {\n background: var(--item-hover-color);\n}\neox-itemfilter-results li.highlighted {\n color: var(--background-color);\n background: var(--item-select-color);\n}\n.selected-item span {\n margin-right: 8px;\n}\n.selected-item button {\n background: none;\n border: none;\n color: #fff;\n cursor: pointer;\n font-size: 16px;\n line-height: 1;\n}\n.multiselect-container,\n.select-container {\n display: flex;\n flex-direction: column;\n gap: 4px;\n}\n.multiselect-container label,\n.select-container label {\n display: flex;\n align-items: center;\n cursor: pointer;\n}\n.multiselect-container input,\n.select-container input {\n margin-right: 8px;\n}\n.select-overflow {\n max-height: 185px;\n overflow-y: auto;\n}\n.chip-title strong {\n font-weight: 500;\n}\n.chip-wrapper {\n max-width: 100%;\n overflow-x: scroll;\n}\n.chip-container {\n display: flex;\n flex: 0;\n}\n.input-container.dirty-filter-input {\n margin-left: 25px;\n}\n.error-validation {\n position: relative;\n color: red;\n font-size: x-small;\n top: -8px;\n}\ninput {\n background-color: var(--background-color);\n}\n";
|
|
1
|
+
export const styleEOX: "\n:host, :root {\n --item-color: color-mix(\n in srgb,\n var(--primary-color) 10%,\n transparent\n );\n --item-hover-color: color-mix(\n in srgb,\n var(--secondary-color) 30%,\n transparent\n );\n --item-select-color: var(--primary-color);\n --inline-bg-color: color-mix(\n in srgb,\n var(--secondary-color) 10%,\n transparent\n );\n --border-color: color-mix(\n in srgb,\n #000000 20%,\n transparent\n );\n --background-color: var(--eox-background-color, transparent);\n --padding: 0.5rem;\n --text-transform: capitalize;\n --form-flex-direction: column;\n --filter-display: block;\n background-color: var(--background-color);\n}\n* {\n font-family: Roboto, sans-serif;\n}\nform#itemfilter {\n flex-direction: var(--form-flex-direction);\n}\neox-itemfilter-container {\n min-width: 200px;\n display: var(--filter-display);\n}\neox-itemfilter-results {\n flex-grow: 1;\n}\nul {\n padding-left: 0;\n margin-top: 0;\n}\nli {\n list-style: none;\n}\nli span {\n text-overflow: ellipsis;\n white-space: nowrap;\n display: flex;\n align-items: center;\n}\nli label {\n display: flex;\n align-items: center;\n}\ndetails summary > * {\n display: inline;\n}\ndetails summary {\n display: flex;\n align-items: center;\n border-bottom: 1px solid #0002;\n padding: .5rem var(--padding);\n}\n\ndetails > summary::-webkit-details-marker {\n display: none;\n}\n\n.title {\n font-size: 13px;\n align-items: center;\n text-transform: var(--text-transform);\n}\n.subtitle {\n font-size: 11px;\n opacity: .7;\n margin-top: 6px;\n}\n.image {\n width: 24px;\n height: 24px;\n object-fit: cover;\n overflow: hidden;\n margin-right: 8px;\n}\n.title-container {\n display: flex;\n flex-direction: column;\n}\nh6.main-heading {\n font-size: 1rem;\n margin-block-start: 1.33em;\n margin-block-end: 1.33em;\n margin-top: var(--padding);\n padding: 0 var(--padding);\n}\ndetails summary .title {\n display: flex;\n font-weight: 500;\n}\ndetails.details-filter summary::after,\ndetails.details-results summary::before {\n content: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%230009' viewBox='0 0 24 24'%3E%3Ctitle%3Echevron-right%3C/title%3E%3Cpath d='M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z' /%3E%3C/svg%3E\");\n height: 24px;\n width: 24px;\n}\ndetails.details-filter summary::after {\n margin-left: auto;\n transform: rotate(90deg);\n}\ndetails[open] summary::before {\n transform: rotate(90deg);\n}\ndetails[open] summary::after {\n transform: rotate(270deg);\n}\neox-itemfilter-expandcontainer {\n max-height: 200px;\n}\neox-itemfilter-expandcontainer > [data-type=filter] {\n display: block;\n height: calc(100% - 32px);\n overflow-y: auto;\n overflow-x: hidden;\n padding: 0 var(--padding);\n}\n[data-type=filter] .title,\ndetails summary {\n text-transform: var(--text-transform);\n}\nli,\nlabel,\ndetails,\ninput[type=\"checkbox\"],\ninput[type=\"radio\"] {\n cursor: pointer;\n}\ninput[type=\"checkbox\"],\ninput[type=\"radio\"] {\n margin: 0;\n}\ninput[type=\"text\"] {\n box-sizing: border-box;\n width: 100%;\n margin-top: 0.5rem;\n margin-bottom: 0.5rem;\n padding: 5px 7px;\n border-radius: 4px;\n border: 1px solid var(--border-color);\n}\nsection:not(section:last-of-type) {\n margin-bottom: 1rem;\n}\n#section-results {\n overflow: hidden;\n flex: 1;\n display: flex;\n flex-direction: column;\n}\nul:not(#filters) > li {\n padding: 5px 0;\n}\nul#results li {\n padding: 5px var(--padding);\n display: flex;\n justify-content: space-between;\n}\nul#results .result-action {\n display: flex;\n align-items: center;\n height: fit-content;\n line-height: 1;\n opacity: .5;\n transition: opacity .3s ease-in-out;\n}\nul#results .result-action:hover {\n opacity: 1;\n}\nul#results .highlighted .result-action > * {\n filter: invert(1);\n}\neox-layout {\n padding: .5rem var(--padding);\n gap: var(--card-gap, 16px);\n --column-width: var(--card-width, 300px);\n --row-height: var(--card-height, 200px);\n}\neox-layout-item {\n position: relative;\n border-radius: var(--card-border-radius, 8px);\n}\neox-layout-item .image {\n width: 100%;\n height: 100%;\n transition: filter .3s ease-in-out;\n margin: 0;\n}\neox-layout-item:hover .image {\n filter: brightness(.5);\n}\neox-layout-item .title-container {\n position: absolute;\n bottom: 0;\n color: white;\n padding: 20px;\n box-sizing: border-box;\n width: 100%;\n background: linear-gradient(\n to top,\n rgba(0, 0, 0, 0.85),\n transparent\n );\n padding-top: 25px;\n}\neox-layout-item .title {\n font-weight: bold;\n}\neox-layout-item .result-action {\n position: absolute;\n top: 20px;\n right: 20px;\n background: #ffffffbb;\n padding: 8px;\n width: 24px;\n height: 24px;\n border-radius: 50%;\n}\nul#results eox-layout-item.highlighted .result-action > * {\n filter: none;\n}\nsection {\n position: relative;\n background-color: var(--background-color);\n}\nbutton#filter-reset {\n position: absolute;\n top: 0;\n right: var(--padding);\n padding: 2px 10px;\n}\n.count {\n display: flex;\n justify-content: center;\n align-items: center;\n background: var(--secondary-color);\n padding: 0 12px;\n height: 20px;\n border-radius: 10px;\n color: var(--primary-color);\n font-weight: 500;\n margin-left: 9px;\n}\neox-itemfilter-range,\ntc-range-slider {\n align-items: center;\n display: block;\n}\ntc-range-slider {\n width: calc(100% - 16px);\n margin-left: 8px;\n margin-right: 8px;\n --width: 100%;\n}\n.range-before,\n.range-after {\n font-size: small;\n}\n.range-before,\n.range-after {\n margin: 1rem 0px;\n}\n\nbutton.reset-icon:before {\n content: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23004170' viewBox='0 0 24 24'%3E%3Ctitle%3Eclose%3C/title%3E%3Cpath d='M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z' /%3E%3C/svg%3E\");\n}\neox-itemfilter-expandcontainer button.reset-icon {\n margin-left: 4px;\n margin-top: -5px;\n height: 14px;\n width: 14px;\n}\neox-itemfilter-expandcontainer button.reset-icon:before {\n height: 14px;\n width: 14px;\n}\n.inline-content {\n border: 1.5px solid var(--secondary-color);\n border-radius: 4px;\n max-height: 300px;\n overflow-y: auto;\n background: var(--inline-bg-color);\n margin-top: 4px;\n padding: 8px;\n}\n.inline-container {\n position: relative;\n align-items: center;\n}\n.inline-container-wrapper {\n width: 100%;\n position: relative;\n}\n.inline-container {\n position: relative;\n border: 1px solid var(--border-color);\n border-radius: 4px;\n height: 24px;\n padding: 8px;\n flex: 1;\n justify-content: space-between;\n cursor: text;\n transition: all 0.2s ease-in-out;\n display: flex;\n}\n.inline-container:hover {\n border: 1px solid var(--primary-color);\n}\n[popover] {\n position: fixed;\n top: 0;\n left: 0;\n margin: 0;\n padding: 0;\n background-color: var(--background-color);\n border: none;\n}\n.input-container {\n display: flex;\n flex: 1;\n align-items: center;\n}\n.input-container input,\n.input-container input:focus {\n height: 100%;\n border: none;\n outline: none;\n border: 0;\n min-width: 25%;\n}\n.button-container {\n display: flex;\n align-items: center;\n justify-content: center;\n position: absolute;\n right: 1px;\n top: 5px;\n height: calc(100% - 10px);\n width: 34px;\n background: white;\n}\nbutton.icon {\n color: #004170;\n height: 24px;\n font-size: large;\n width: unset;\n}\n.inline-container::-webkit-scrollbar {\n height: 2px;\n}\n.inline-container::-webkit-scrollbar-thumb {\n background: lightgrey;\n border-radius: 2px;\n}\n.hidden {\n height: 0;\n padding: 0;\n border: none;\n}\n.hidden:hover {\n border: none;\n}\n.chip-title {\n pointer-events: none;\n text-transform: var(--text-transform);\n}\n.chip {\n display: flex;\n align-items: center;\n background: var(--item-color);\n border-radius: 30px;\n margin-right: 4px;\n padding: 5px 10px;\n font-size: small;\n cursor: default;\n white-space: nowrap;\n}\n.chip.highlighted {\n background: var(--primary-color);\n color: white;\n}\n.chip-close {\n cursor: pointer;\n font-weight: 600;\n position: absolute;\n right: -25px;\n background: white;\n top: 0;\n height: 100%;\n display: flex;\n align-items: center;\n height: 24px;\n width: 24px;\n}\n.chip-close:before {\n position: absolute;\n text-indent: 0;\n line-height: initial;\n height: 24px;\n width: 24px;\n content: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23004170' viewBox='0 0 24 24'%3E%3Ctitle%3Eclose%3C/title%3E%3Cpath d='M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z' /%3E%3C/svg%3E\");\n}\n.chip-container {\n position: relative;\n max-width: 75%;\n}\n.autocomplete-container,\n.text-container {\n position: relative;\n align-items: center;\n width: 100%;\n box-sizing: border-box;\n justify-content: space-between;\n cursor: text;\n margin-top: 0.5rem;\n margin-bottom: 0.5rem;\n background: white;\n}\n.autocomplete-container-wrapper,\n.text-container-wrapper {\n position: relative;\n display: flex;\n align-items: center;\n flex: 1;\n overflow-x: auto;\n -ms-overflow-style: none;\n scrollbar-width: none;\n}\n.autocomplete-container-wrapper::-webkit-scrollbar {\n display: none;\n}\n.chip-wrapper {\n -ms-overflow-style: none;\n scrollbar-width: none;\n}\n.chip-wrapper::-webkit-scrollbar {\n display: none;\n width: 0;\n background: transparent;\n}\n.autocomplete-input,\n.text-input {\n flex: 1;\n border: 1px solid var(--border-color);\n outline: none;\n box-sizing: border-box;\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n min-width: 150px;\n}\ninput[type=\"text\"].text-input,\ninput[type=\"text\"].autocomplete-input {\n padding: 9px 6px !important;\n border-radius: 4px;\n}\n.text-input:hover,\n.autocomplete-input:hover {\n border: 1px solid var(--primary-color);\n}\n.text-input:invalid {\n border: 1px solid red;\n}\n.selected-items {\n display: flex;\n flex-wrap: nowrap;\n gap: 4px;\n}\n.select li:hover,\n.multiselect li:hover,\neox-itemfilter-results li:hover {\n background: var(--item-hover-color);\n}\neox-itemfilter-results li.highlighted {\n color: var(--background-color);\n background: var(--item-select-color);\n}\n.selected-item span {\n margin-right: 8px;\n}\n.selected-item button {\n background: none;\n border: none;\n color: #fff;\n cursor: pointer;\n font-size: 16px;\n line-height: 1;\n}\n.multiselect-container,\n.select-container {\n display: flex;\n flex-direction: column;\n gap: 4px;\n}\n.multiselect-container label,\n.select-container label {\n display: flex;\n align-items: center;\n cursor: pointer;\n}\n.multiselect-container input,\n.select-container input {\n margin-right: 8px;\n}\n.select-overflow {\n max-height: 185px;\n overflow-y: auto;\n}\n.chip-title strong {\n font-weight: 500;\n}\n.chip-wrapper {\n max-width: 100%;\n overflow-x: scroll;\n}\n.chip-container {\n display: flex;\n flex: 0;\n}\n.input-container.dirty-filter-input {\n margin-left: 25px;\n}\n.error-validation {\n position: relative;\n color: red;\n font-size: x-small;\n top: -8px;\n}\ninput {\n background-color: var(--background-color);\n}\n";
|
|
2
2
|
//# sourceMappingURL=style.eox.d.ts.map
|
package/types/style.eox.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"style.eox.d.ts","sourceRoot":"","sources":["../src/style.eox.js"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"style.eox.d.ts","sourceRoot":"","sources":["../src/style.eox.js"],"names":[],"mappings":"AAAA,itWAiiBE"}
|