@energie360/ui-library 0.1.18 → 0.1.19
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/base/_input-resets.scss +3 -0
- package/components/card-highlight/card-highlight.scss +17 -0
- package/components/card-highlight/u-card-highlight.vue +32 -19
- package/components/chip/chip.scss +25 -0
- package/components/chip/u-chip.vue +31 -0
- package/components/index.js +4 -0
- package/components/rating/rating.scss +76 -0
- package/components/rating/u-rating.vue +79 -0
- package/dist/base-style.css +3 -0
- package/dist/base-style.css.map +1 -1
- package/elements/numeric-stepper/u-numeric-stepper.vue +35 -12
- package/i18n/i18n.ts +8 -0
- package/layout/index.js +2 -1
- package/layout/portal-content-aside/portal-content-aside.scss +35 -0
- package/layout/portal-content-aside/u-portal-content-aside.vue +15 -0
- package/layout/responsive-container/u-responsive-container.vue +35 -0
- package/modules/dialog/dialog.scss +4 -0
- package/modules/dialog/u-dialog.vue +2 -1
- package/package.json +1 -1
- package/wizard/index.js +1 -0
- package/wizard/wizard-top-bar/u-wizard-top-bar.vue +31 -0
- package/wizard/wizard-top-bar/wizard-top-bar.scss +35 -0
- package/layout/settings/settings.scss +0 -33
- package/layout/settings/u-settings-layout.vue +0 -19
package/base/_input-resets.scss
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
@use '../../base/abstracts' as a;
|
|
2
2
|
|
|
3
|
+
.card-highlight-container {
|
|
4
|
+
container: card-highlight / inline-size;
|
|
5
|
+
height: 100%;
|
|
6
|
+
|
|
7
|
+
@container card-highlight (width >= 900px) {
|
|
8
|
+
.card-highlight__image-col {
|
|
9
|
+
padding-right: var(--e-space-20);
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
|
|
3
14
|
.card-highlight {
|
|
4
15
|
position: relative;
|
|
5
16
|
display: flex;
|
|
@@ -53,6 +64,12 @@
|
|
|
53
64
|
flex: 1 1 auto;
|
|
54
65
|
max-width: 60%;
|
|
55
66
|
align-self: center;
|
|
67
|
+
display: flex;
|
|
68
|
+
justify-content: flex-end;
|
|
69
|
+
|
|
70
|
+
img {
|
|
71
|
+
max-height: a.rem(225);
|
|
72
|
+
}
|
|
56
73
|
|
|
57
74
|
@include a.bp(m) {
|
|
58
75
|
max-width: none;
|
|
@@ -5,7 +5,7 @@ import { UIcon } from '../../elements'
|
|
|
5
5
|
interface Props {
|
|
6
6
|
title?: string
|
|
7
7
|
text?: string
|
|
8
|
-
image
|
|
8
|
+
image?: Image
|
|
9
9
|
badgeIcon?: string
|
|
10
10
|
}
|
|
11
11
|
|
|
@@ -13,29 +13,42 @@ defineProps<Props>()
|
|
|
13
13
|
</script>
|
|
14
14
|
|
|
15
15
|
<template>
|
|
16
|
-
<div class="card-highlight">
|
|
17
|
-
<div class="card-
|
|
18
|
-
<
|
|
19
|
-
<
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
<
|
|
24
|
-
<
|
|
25
|
-
|
|
16
|
+
<div class="card-highlight-container">
|
|
17
|
+
<div class="card-highlight">
|
|
18
|
+
<div class="card-highlight__content-col">
|
|
19
|
+
<h3 v-if="$slots.title || title" class="card-highlight__title">
|
|
20
|
+
<slot name="title">{{ title }}</slot>
|
|
21
|
+
</h3>
|
|
22
|
+
|
|
23
|
+
<div v-if="$slots.text || text" class="card-highlight__text">
|
|
24
|
+
<slot name="text">
|
|
25
|
+
<div v-html="text"></div>
|
|
26
|
+
</slot>
|
|
27
|
+
</div>
|
|
26
28
|
</div>
|
|
27
|
-
</div>
|
|
28
29
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
30
|
+
<div v-if="$slots.image || image" class="card-highlight__image-col">
|
|
31
|
+
<div>
|
|
32
|
+
<slot name="image">
|
|
33
|
+
<img v-bind="image" />
|
|
34
|
+
</slot>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
34
37
|
|
|
35
|
-
|
|
36
|
-
|
|
38
|
+
<div v-if="badgeIcon" class="card-highlight__badge-icon">
|
|
39
|
+
<UIcon :name="badgeIcon" />
|
|
40
|
+
</div>
|
|
37
41
|
</div>
|
|
38
42
|
</div>
|
|
39
43
|
</template>
|
|
40
44
|
|
|
41
45
|
<style scoped lang="scss" src="./card-highlight.scss"></style>
|
|
46
|
+
<style scoped lang="scss">
|
|
47
|
+
@use '../../base/abstracts' as a;
|
|
48
|
+
|
|
49
|
+
.card-highlight__image-col {
|
|
50
|
+
:slotted(img) {
|
|
51
|
+
max-height: a.rem(225);
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
</style>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
@use '../../base/abstracts' as a;
|
|
2
|
+
|
|
3
|
+
.chip {
|
|
4
|
+
background-color: var(--e-c-mono-50);
|
|
5
|
+
border: 1px solid var(--e-c-mono-200);
|
|
6
|
+
border-radius: var(--e-brd-radius-2);
|
|
7
|
+
padding: var(--e-space-1_5) var(--e-space-2);
|
|
8
|
+
display: flex;
|
|
9
|
+
align-items: center;
|
|
10
|
+
column-gap: var(--e-space-1);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.chip__icon {
|
|
14
|
+
color: var(--e-c-mono-700);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.chip__label {
|
|
18
|
+
@include a.type(200, strong);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.chip__caption {
|
|
22
|
+
@include a.type(50, strong);
|
|
23
|
+
|
|
24
|
+
color: var(--e-c-mono-700);
|
|
25
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import { UIcon } from '../../elements'
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
caption?: string
|
|
6
|
+
label?: string
|
|
7
|
+
icon?: string
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
defineProps<Props>()
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<template>
|
|
14
|
+
<div class="chip">
|
|
15
|
+
<span v-if="icon" class="chip__icon">
|
|
16
|
+
<UIcon :name="icon"></UIcon>
|
|
17
|
+
</span>
|
|
18
|
+
|
|
19
|
+
<div class="chip__label">
|
|
20
|
+
<p v-if="$slots.caption || caption" class="chip__caption">
|
|
21
|
+
<slot name="caption">{{ caption }}</slot>
|
|
22
|
+
</p>
|
|
23
|
+
|
|
24
|
+
<p>
|
|
25
|
+
<slot>{{ label }}</slot>
|
|
26
|
+
</p>
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
</template>
|
|
30
|
+
|
|
31
|
+
<style scoped lang="scss" src="./chip.scss"></style>
|
package/components/index.js
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
* It's not recommended to import components from this file, because tree-shaking won't work then.
|
|
3
3
|
* -> https://vite.dev/guide/performance#avoid-barrel-files
|
|
4
4
|
*/
|
|
5
|
+
import exp from 'node:constants'
|
|
6
|
+
|
|
5
7
|
export { default as UAccordionItem } from './accordion-item/u-accordion-item.vue'
|
|
6
8
|
|
|
7
9
|
// Cards
|
|
@@ -64,3 +66,5 @@ export { default as UDataCardGroup } from './data-card-group/u-data-card-group.v
|
|
|
64
66
|
export { default as USearchGroup } from './search-group/u-search-group.vue'
|
|
65
67
|
export { default as USkeletonLoader } from './skeleton-loader/u-skeleton-loader.vue'
|
|
66
68
|
export { default as UCardHighlight } from './card-highlight/u-card-highlight.vue'
|
|
69
|
+
export { default as URating } from './rating/u-rating.vue'
|
|
70
|
+
export { default as UChip } from './chip/u-chip.vue'
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
@use '../../base/abstracts' as a;
|
|
2
|
+
@use '../../base/accessibility';
|
|
3
|
+
|
|
4
|
+
$ease-in-out-back: cubic-bezier(0.68, -0.55, 0.265, 1.55);
|
|
5
|
+
|
|
6
|
+
@keyframes thumbs-up-down-anim {
|
|
7
|
+
0% {
|
|
8
|
+
transform: rotate(-5deg);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
100% {
|
|
12
|
+
transform: rotate(0);
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.rating {
|
|
17
|
+
display: flex;
|
|
18
|
+
column-gap: var(--e-space-0_5);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.rating__button {
|
|
22
|
+
position: relative;
|
|
23
|
+
display: flex;
|
|
24
|
+
align-items: center;
|
|
25
|
+
justify-content: center;
|
|
26
|
+
width: a.rem(36);
|
|
27
|
+
height: a.rem(36);
|
|
28
|
+
color: var(--e-c-mono-700);
|
|
29
|
+
border-radius: var(--e-brd-radius-1);
|
|
30
|
+
transition: background-color a.$trs-default;
|
|
31
|
+
|
|
32
|
+
&:hover {
|
|
33
|
+
background-color: var(--e-c-mono-00);
|
|
34
|
+
|
|
35
|
+
.rating__button-tooltip {
|
|
36
|
+
opacity: 1;
|
|
37
|
+
transform: translateY(100%);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
&.up .icon {
|
|
42
|
+
transform-origin: bottom left;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
&.down .icon {
|
|
46
|
+
transform-origin: bottom right;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
&.active {
|
|
50
|
+
.icon {
|
|
51
|
+
animation-name: thumbs-up-down-anim;
|
|
52
|
+
animation-duration: var(--e-trs-duration-faster);
|
|
53
|
+
animation-iteration-count: 1;
|
|
54
|
+
animation-timing-function: $ease-in-out-back;
|
|
55
|
+
animation-delay: 50ms;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.rating__button-tooltip {
|
|
61
|
+
@include a.type(100);
|
|
62
|
+
|
|
63
|
+
position: absolute;
|
|
64
|
+
opacity: 0;
|
|
65
|
+
padding: var(--e-space-1) var(--e-space-2);
|
|
66
|
+
white-space: nowrap;
|
|
67
|
+
border-radius: var(--e-brd-radius-2);
|
|
68
|
+
background-color: var(--e-c-mono-900);
|
|
69
|
+
color: var(--e-c-mono-00);
|
|
70
|
+
bottom: calc(var(--e-space-2) * -1);
|
|
71
|
+
transform: translateY(85%);
|
|
72
|
+
transition:
|
|
73
|
+
opacity a.$trs-default,
|
|
74
|
+
transform a.$trs-default;
|
|
75
|
+
pointer-events: none;
|
|
76
|
+
}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import { ref } from 'vue'
|
|
3
|
+
import { UIcon } from '../../elements'
|
|
4
|
+
import { getTranslation } from '../../utils/translations/translate'
|
|
5
|
+
|
|
6
|
+
interface Props {
|
|
7
|
+
likeText?: string
|
|
8
|
+
dislikeText?: string
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
defineProps<Props>()
|
|
12
|
+
const emit = defineEmits(['like', 'dislike', 'cancel'])
|
|
13
|
+
|
|
14
|
+
const likeActive = ref(false)
|
|
15
|
+
const dislikeActive = ref(false)
|
|
16
|
+
|
|
17
|
+
const onLike = () => {
|
|
18
|
+
if (!likeActive.value) {
|
|
19
|
+
likeActive.value = true
|
|
20
|
+
dislikeActive.value = false
|
|
21
|
+
emit('like')
|
|
22
|
+
return
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
if (likeActive.value) {
|
|
26
|
+
likeActive.value = false
|
|
27
|
+
dislikeActive.value = false
|
|
28
|
+
emit('cancel')
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
const onDislike = () => {
|
|
32
|
+
if (!dislikeActive.value) {
|
|
33
|
+
dislikeActive.value = true
|
|
34
|
+
likeActive.value = false
|
|
35
|
+
emit('dislike')
|
|
36
|
+
return
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
if (dislikeActive.value) {
|
|
40
|
+
dislikeActive.value = false
|
|
41
|
+
likeActive.value = false
|
|
42
|
+
emit('cancel')
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
</script>
|
|
46
|
+
|
|
47
|
+
<template>
|
|
48
|
+
<div class="rating">
|
|
49
|
+
<button :class="['rating__button', 'up', { active: likeActive }]" type="button" @click="onLike">
|
|
50
|
+
<UIcon :name="likeActive ? 'thumbs-up-active' : 'thumbs-up'" />
|
|
51
|
+
|
|
52
|
+
<span class="visually-hidden">
|
|
53
|
+
{{ likeText || getTranslation('like') }}
|
|
54
|
+
</span>
|
|
55
|
+
|
|
56
|
+
<span class="rating__button-tooltip" aria-hidden="true">
|
|
57
|
+
{{ likeText || getTranslation('like') }}
|
|
58
|
+
</span>
|
|
59
|
+
</button>
|
|
60
|
+
|
|
61
|
+
<button
|
|
62
|
+
:class="['rating__button', 'down', { active: dislikeActive }]"
|
|
63
|
+
type="button"
|
|
64
|
+
@click="onDislike"
|
|
65
|
+
>
|
|
66
|
+
<UIcon :name="dislikeActive ? 'thumbs-down-active' : 'thumbs-down'" />
|
|
67
|
+
|
|
68
|
+
<span class="visually-hidden">
|
|
69
|
+
{{ dislikeText || getTranslation('dislike') }}
|
|
70
|
+
</span>
|
|
71
|
+
|
|
72
|
+
<span class="rating__button-tooltip" aria-hidden="true">
|
|
73
|
+
{{ dislikeText || getTranslation('dislike') }}
|
|
74
|
+
</span>
|
|
75
|
+
</button>
|
|
76
|
+
</div>
|
|
77
|
+
</template>
|
|
78
|
+
|
|
79
|
+
<style scoped lang="scss" src="./rating.scss"></style>
|
package/dist/base-style.css
CHANGED
package/dist/base-style.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sourceRoot":"","sources":["../base/main-base.scss","../node_modules/@energie360/design-tokens/dist/fonts/fonts.css","../base/_resets.scss","../base/abstracts/_resets.scss","../base/abstracts/_variables.scss","../base/abstracts/_functions.scss","../base/_input-resets.scss","../base/abstracts/_mixins.scss","../base/_html.scss","../base/_body.scss","../base/_focus-handling.scss","../node_modules/@energie360/design-tokens/dist/css/design-tokens.css"],"names":[],"mappings":";AAAA;AAAA;AAAA;AAAA;ACAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAqBA;AACQ;ACpBR;EACE;EACA;;;AAGF;AAAA;AAAA;AAAA;AAAA;AAAA;EAME;EACA;EACA;EACA;;;AAGF;EACE;EACA;;;AAGF;AAAA;AAAA;EAGE;;;AC1BA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;ADuBJ;AAAA;EAEE;EACA;EACA;;;AAGF;AAAA;AAAA;EAGE;;;AAGF;EACE;;;AAGF;AAAA;EAEE;EACA;;;AAGF;EACE;EACA;EACA;;;AErB+E;AChCjF;ACHA;AAAA;AAAA;EAGE;EACA;EACA;EACA;EACA;EACA;;;AAGF;AAAA;AAAA;EC8BE;EACA;EAKE;;;AD7BF;EACE;;AAGF;EACE;;;AAIJ;EACE;;;AAGF;EACE;EACA;;;AAIA;EACE;;;AAIJ;EACE;;;
|
|
1
|
+
{"version":3,"sourceRoot":"","sources":["../base/main-base.scss","../node_modules/@energie360/design-tokens/dist/fonts/fonts.css","../base/_resets.scss","../base/abstracts/_resets.scss","../base/abstracts/_variables.scss","../base/abstracts/_functions.scss","../base/_input-resets.scss","../base/abstracts/_mixins.scss","../base/_html.scss","../base/_body.scss","../base/_focus-handling.scss","../node_modules/@energie360/design-tokens/dist/css/design-tokens.css"],"names":[],"mappings":";AAAA;AAAA;AAAA;AAAA;ACAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAqBA;AACQ;ACpBR;EACE;EACA;;;AAGF;AAAA;AAAA;AAAA;AAAA;AAAA;EAME;EACA;EACA;EACA;;;AAGF;EACE;EACA;;;AAGF;AAAA;AAAA;EAGE;;;AC1BA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;ADuBJ;AAAA;EAEE;EACA;EACA;;;AAGF;AAAA;AAAA;EAGE;;;AAGF;EACE;;;AAGF;AAAA;EAEE;EACA;;;AAGF;EACE;EACA;EACA;;;AErB+E;AChCjF;ACHA;AAAA;AAAA;EAGE;EACA;EACA;EACA;EACA;EACA;;;AAGF;AAAA;AAAA;EC8BE;EACA;EAKE;;;AD7BF;EACE;;AAGF;EACE;;;AAIJ;EACE;;;AAGF;EACE;EACA;;;AAIA;EACE;;;AAIJ;EACE;;;AAGF;EAEE;;AAEA;EAEE;EACA;;;AEvDJ;EACE;EACA;EACA;;;AAGF;AAAA;AAAA;EAGE;;;ACTF;EACE;EACA;EACA;EACA;EACA;;;ACAF;EACE;;;AAGF;EACE;EACA;EACA;;;AAGF;EACE;;;ATQF;AACA;AACA;EACE;EACA;EACA;EACA;EACA,KACE;;AAIJ;AACA;EACE;EACA;EACA;EACA;EACA,KACE;;AU3CJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;AAAA;EAEA;AAAA;EAEA;AAAA;EAEA;AAAA;EAEA;;;AX7MA;AAAA;AAAA;AAAA;EACE","file":"base-style.css"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import UIcon from '../icon/u-icon.vue'
|
|
3
|
-
import { computed, ref, useTemplateRef, useId, nextTick } from 'vue'
|
|
3
|
+
import { computed, ref, useTemplateRef, useId, nextTick, onMounted } from 'vue'
|
|
4
4
|
import { getTranslation } from '../../utils/translations/translate'
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
@@ -29,6 +29,7 @@ const {
|
|
|
29
29
|
const cId = `numeric-stepper-${useId()}`
|
|
30
30
|
|
|
31
31
|
const model = defineModel<string | number>()
|
|
32
|
+
const emit = defineEmits(['input', 'focus', 'focusout'])
|
|
32
33
|
|
|
33
34
|
const input = useTemplateRef('input')
|
|
34
35
|
|
|
@@ -57,24 +58,24 @@ const onHoverOut = () => {
|
|
|
57
58
|
}
|
|
58
59
|
|
|
59
60
|
const onStepDown = () => {
|
|
60
|
-
|
|
61
|
+
input.value.stepDown()
|
|
62
|
+
model.value = Number(input.value.value)
|
|
63
|
+
|
|
61
64
|
nextTick(() => {
|
|
62
|
-
|
|
65
|
+
onInput()
|
|
63
66
|
})
|
|
64
67
|
}
|
|
65
68
|
|
|
66
69
|
const onStepUp = () => {
|
|
67
|
-
|
|
70
|
+
input.value.stepUp()
|
|
71
|
+
model.value = Number(input.value.value)
|
|
68
72
|
|
|
69
73
|
nextTick(() => {
|
|
70
|
-
|
|
74
|
+
onInput()
|
|
71
75
|
})
|
|
72
76
|
}
|
|
73
77
|
|
|
74
|
-
const
|
|
75
|
-
e.preventDefault()
|
|
76
|
-
e.stopPropagation()
|
|
77
|
-
|
|
78
|
+
const checkMinMax = () => {
|
|
78
79
|
if (min !== '') {
|
|
79
80
|
isMin.value = Number(model.value) <= Number(min)
|
|
80
81
|
}
|
|
@@ -84,16 +85,28 @@ const onInput = (e) => {
|
|
|
84
85
|
}
|
|
85
86
|
}
|
|
86
87
|
|
|
88
|
+
const onInput = () => {
|
|
89
|
+
checkMinMax()
|
|
90
|
+
|
|
91
|
+
// Is this necessary?
|
|
92
|
+
// If we use v-model this wouldn't be needed.
|
|
93
|
+
emit('input', model.value)
|
|
94
|
+
}
|
|
95
|
+
|
|
87
96
|
const stepButtonUpDisabled = computed(() => disabled || readonly || isMax.value)
|
|
88
97
|
const stepButtonDownDisabled = computed(() => disabled || readonly || isMin.value)
|
|
98
|
+
|
|
99
|
+
onMounted(() => {
|
|
100
|
+
checkMinMax()
|
|
101
|
+
})
|
|
89
102
|
</script>
|
|
90
103
|
|
|
91
104
|
<template>
|
|
92
105
|
<div :class="['numeric-stepper', classes]" @mouseenter="onHover" @mouseleave="onHoverOut">
|
|
93
106
|
<label class="visually-hidden" :for="cId">{{ label }}</label>
|
|
94
107
|
<div class="control">
|
|
95
|
-
<slot name="input"
|
|
96
|
-
|
|
108
|
+
<slot name="input">
|
|
109
|
+
<input
|
|
97
110
|
:id="cId"
|
|
98
111
|
ref="input"
|
|
99
112
|
v-model="model"
|
|
@@ -102,8 +115,12 @@ const stepButtonDownDisabled = computed(() => disabled || readonly || isMin.valu
|
|
|
102
115
|
:min
|
|
103
116
|
:max
|
|
104
117
|
:step
|
|
118
|
+
v-bind="$attrs"
|
|
119
|
+
@focus="$emit('focus', $event)"
|
|
120
|
+
@focusout="$emit('focusout', $event)"
|
|
105
121
|
@input="onInput"
|
|
106
|
-
|
|
122
|
+
/>
|
|
123
|
+
</slot>
|
|
107
124
|
</div>
|
|
108
125
|
|
|
109
126
|
<button
|
|
@@ -128,6 +145,12 @@ const stepButtonDownDisabled = computed(() => disabled || readonly || isMin.valu
|
|
|
128
145
|
<UIcon name="add"></UIcon>
|
|
129
146
|
</button>
|
|
130
147
|
</div>
|
|
148
|
+
|
|
149
|
+
<div class="error-message-container">
|
|
150
|
+
<slot name="error-message">
|
|
151
|
+
{{ errorMessage }}
|
|
152
|
+
</slot>
|
|
153
|
+
</div>
|
|
131
154
|
</template>
|
|
132
155
|
|
|
133
156
|
<style lang="scss" scoped>
|
package/i18n/i18n.ts
CHANGED
|
@@ -21,6 +21,8 @@ const translations = {
|
|
|
21
21
|
maxFileCountAllowed: 'Maximal $COUNT Dateien erlaubt.',
|
|
22
22
|
cancelSearch: 'Suche abbrechen',
|
|
23
23
|
download: 'Herunterladen',
|
|
24
|
+
like: 'Gefällt mir',
|
|
25
|
+
dislike: 'Gefällt mir nicht',
|
|
24
26
|
},
|
|
25
27
|
FR: {
|
|
26
28
|
yes: 'Ja',
|
|
@@ -44,6 +46,8 @@ const translations = {
|
|
|
44
46
|
maxFileCountAllowed: 'Maximum de $COUNT fichiers autorisés',
|
|
45
47
|
cancelSearch: 'Annuler la recherche',
|
|
46
48
|
download: 'Télécharger',
|
|
49
|
+
like: "J'aime ça",
|
|
50
|
+
dislike: "je ne l'aime pas",
|
|
47
51
|
},
|
|
48
52
|
IT: {
|
|
49
53
|
yes: 'Ja',
|
|
@@ -67,6 +71,8 @@ const translations = {
|
|
|
67
71
|
maxFileCountAllowed: 'Sono consentiti al massimo $COUNT file',
|
|
68
72
|
cancelSearch: 'annullare la ricerca',
|
|
69
73
|
download: 'scaricamento',
|
|
74
|
+
like: 'Mi piace',
|
|
75
|
+
dislike: 'Non mi piace',
|
|
70
76
|
},
|
|
71
77
|
EN: {
|
|
72
78
|
yes: 'Ja',
|
|
@@ -90,6 +96,8 @@ const translations = {
|
|
|
90
96
|
maxFileCountAllowed: 'Maximum $COUNT files allowed',
|
|
91
97
|
cancelSearch: 'Cancel search',
|
|
92
98
|
download: 'Download',
|
|
99
|
+
like: 'I like it',
|
|
100
|
+
dislike: 'I do not like it',
|
|
93
101
|
},
|
|
94
102
|
}
|
|
95
103
|
|
package/layout/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
export { default as USettingsLayout } from './settings/u-settings-layout.vue'
|
|
2
1
|
export { default as UPortalLayout } from './portal/u-portal.vue'
|
|
3
2
|
export { default as UTileGrid } from './tile-grid/u-tile-grid.vue'
|
|
4
3
|
export { default as UTileItem } from './tile-grid/u-tile-item.vue'
|
|
4
|
+
export { default as UResponsiveContainer } from './responsive-container/u-responsive-container.vue'
|
|
5
|
+
export { default as UPortalContentAside } from './portal-content-aside/u-portal-content-aside.vue'
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
@use '../../base/abstracts' as a;
|
|
2
|
+
|
|
3
|
+
.portal-content-aside-container {
|
|
4
|
+
container-type: inline-size;
|
|
5
|
+
|
|
6
|
+
@container (width <= 1020px) {
|
|
7
|
+
.portal-content-aside {
|
|
8
|
+
display: flex;
|
|
9
|
+
flex-direction: column;
|
|
10
|
+
row-gap: var(--e-space-6);
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.portal-content-aside {
|
|
16
|
+
display: grid;
|
|
17
|
+
grid-template-columns: auto a.rem(320);
|
|
18
|
+
grid-template-rows: repeat(2, auto);
|
|
19
|
+
grid-column-gap: var(--e-space-24);
|
|
20
|
+
grid-row-gap: var(--e-space-12);
|
|
21
|
+
|
|
22
|
+
// @include a.bp(lg) {
|
|
23
|
+
// display: flex;
|
|
24
|
+
// flex-direction: column;
|
|
25
|
+
// row-gap: var(--e-space-6);
|
|
26
|
+
// }
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.portal-content-aside__main {
|
|
30
|
+
grid-area: 1 / 1 / 3 / 2;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.portal-content-aside__aside {
|
|
34
|
+
grid-area: 1 / 2 / 3 / 3;
|
|
35
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="portal-content-aside-container">
|
|
3
|
+
<div class="portal-content-aside">
|
|
4
|
+
<div class="portal-content-aside__main">
|
|
5
|
+
<slot />
|
|
6
|
+
</div>
|
|
7
|
+
|
|
8
|
+
<aside class="portal-content-aside__aside">
|
|
9
|
+
<slot name="aside"></slot>
|
|
10
|
+
</aside>
|
|
11
|
+
</div>
|
|
12
|
+
</div>
|
|
13
|
+
</template>
|
|
14
|
+
|
|
15
|
+
<style scoped lang="scss" src="./portal-content-aside.scss"></style>
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import { onMounted, onUnmounted, useTemplateRef, ref } from 'vue'
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
breakpoint: number
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
const root = useTemplateRef('root')
|
|
9
|
+
const containerWidth = ref(0)
|
|
10
|
+
const resizeObserver = new ResizeObserver((entries) => {
|
|
11
|
+
containerWidth.value = entries[0].contentBoxSize[0].inlineSize
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
defineProps<Props>()
|
|
15
|
+
|
|
16
|
+
onMounted(() => {
|
|
17
|
+
resizeObserver.observe(root.value)
|
|
18
|
+
})
|
|
19
|
+
|
|
20
|
+
onUnmounted(() => {
|
|
21
|
+
resizeObserver.disconnect()
|
|
22
|
+
})
|
|
23
|
+
</script>
|
|
24
|
+
|
|
25
|
+
<template>
|
|
26
|
+
<div ref="root" class="responsive-container">
|
|
27
|
+
<template v-if="containerWidth >= breakpoint">
|
|
28
|
+
<slot name="above"></slot>
|
|
29
|
+
</template>
|
|
30
|
+
|
|
31
|
+
<template v-else>
|
|
32
|
+
<slot name="below"></slot>
|
|
33
|
+
</template>
|
|
34
|
+
</div>
|
|
35
|
+
</template>
|
|
@@ -11,6 +11,7 @@ interface Props {
|
|
|
11
11
|
headerImage?: Image
|
|
12
12
|
contentImage?: Image
|
|
13
13
|
closeBtnLabel?: string
|
|
14
|
+
autoHeight?: boolean
|
|
14
15
|
mobileDialogStyle?: 'modal' | 'slideout'
|
|
15
16
|
}
|
|
16
17
|
|
|
@@ -82,7 +83,7 @@ watch(visible, (newV) => {
|
|
|
82
83
|
},
|
|
83
84
|
]"
|
|
84
85
|
>
|
|
85
|
-
<div class="dialog">
|
|
86
|
+
<div :class="['dialog', { 'auto-height': autoHeight }]">
|
|
86
87
|
<div class="dialog__header-image-container">
|
|
87
88
|
<slot name="header-image">
|
|
88
89
|
<img v-bind="headerImage" />
|
package/package.json
CHANGED
package/wizard/index.js
CHANGED
|
@@ -3,3 +3,4 @@ export { default as UWizardOutro } from './wizard-outro/u-wizard-outro.vue'
|
|
|
3
3
|
export { default as UWizardLayout } from './wizard-layout/u-wizard-layout.vue'
|
|
4
4
|
export { default as UWizardLayoutBlock } from './wizard-layout/u-wizard-layout-block.vue'
|
|
5
5
|
export { default as UWizardLayoutElement } from './wizard-layout/u-wizard-layout-element.vue'
|
|
6
|
+
export { default as UWizardTopBar } from './wizard-top-bar/u-wizard-top-bar.vue'
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
<!--<script setup lang="ts">-->
|
|
2
|
+
<!--import { UIcon } from '../../elements'-->
|
|
3
|
+
|
|
4
|
+
<!--interface Props {-->
|
|
5
|
+
<!-- objectAddress?: string-->
|
|
6
|
+
<!--}-->
|
|
7
|
+
<!--</script>-->
|
|
8
|
+
|
|
9
|
+
<template>
|
|
10
|
+
<div class="wizard-top-bar">
|
|
11
|
+
<div class="container">
|
|
12
|
+
<div class="wizard-top-bar__inner">
|
|
13
|
+
<div class="wizard-top-bar__logo">
|
|
14
|
+
<img src="/static/ui-assets/images/logo.svg" alt="logo" />
|
|
15
|
+
</div>
|
|
16
|
+
|
|
17
|
+
<div class="wizard-top-bar__right-column">
|
|
18
|
+
<div class="wizard-top-bar__additional">
|
|
19
|
+
<slot name="additional"></slot>
|
|
20
|
+
</div>
|
|
21
|
+
|
|
22
|
+
<div class="wizard-top-bar__cta">
|
|
23
|
+
<slot name="cta"></slot>
|
|
24
|
+
</div>
|
|
25
|
+
</div>
|
|
26
|
+
</div>
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
</template>
|
|
30
|
+
|
|
31
|
+
<style scoped lang="scss" src="./wizard-top-bar.scss"></style>
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
@use '../../base/abstracts' as a;
|
|
2
|
+
@use '../../layout/container/container';
|
|
3
|
+
|
|
4
|
+
.wizard-top-bar__inner {
|
|
5
|
+
height: a.rem(98);
|
|
6
|
+
display: flex;
|
|
7
|
+
justify-content: space-between;
|
|
8
|
+
align-items: center;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.wizard-top-bar__logo {
|
|
12
|
+
flex: 0 0 auto;
|
|
13
|
+
|
|
14
|
+
img {
|
|
15
|
+
height: a.rem(40);
|
|
16
|
+
|
|
17
|
+
@include a.bp(lg) {
|
|
18
|
+
height: a.rem(24);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.wizard-top-bar__cta,
|
|
24
|
+
.wizard-top-bar__right-column {
|
|
25
|
+
display: flex;
|
|
26
|
+
column-gap: var(--e-space-6);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.wizard-top-bar__right-column {
|
|
30
|
+
.wizard-top-bar__additional {
|
|
31
|
+
@include a.bp(m) {
|
|
32
|
+
display: none;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
@use '../../base/abstracts' as a;
|
|
2
|
-
|
|
3
|
-
.settings-layout {
|
|
4
|
-
display: grid;
|
|
5
|
-
grid-template-columns: auto a.rem(320);
|
|
6
|
-
grid-template-rows: repeat(2, auto);
|
|
7
|
-
grid-column-gap: var(--e-space-24);
|
|
8
|
-
grid-row-gap: var(--e-space-12);
|
|
9
|
-
padding: var(--e-space-10) 0;
|
|
10
|
-
|
|
11
|
-
@include a.bp(lg) {
|
|
12
|
-
display: flex;
|
|
13
|
-
flex-direction: column;
|
|
14
|
-
row-gap: var(--e-space-6);
|
|
15
|
-
padding: var(--e-space-6) 0 var(--e-space-10);
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
.settings-layout__header {
|
|
20
|
-
grid-area: 1 / 1 / 2 / 3;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.settings-layout__main {
|
|
24
|
-
grid-area: 2 / 1 / 3 / 2;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.settings-layout__aside {
|
|
28
|
-
grid-area: 2 / 2 / 3 / 3;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.settings-layout__title {
|
|
32
|
-
@include a.type(500, strong);
|
|
33
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="settings-layout">
|
|
3
|
-
<div class="settings-layout__header">
|
|
4
|
-
<h1 class="settings-layout__title">
|
|
5
|
-
<slot name="title"></slot>
|
|
6
|
-
</h1>
|
|
7
|
-
</div>
|
|
8
|
-
|
|
9
|
-
<div class="settings-layout__main">
|
|
10
|
-
<slot name="main"></slot>
|
|
11
|
-
</div>
|
|
12
|
-
|
|
13
|
-
<aside class="settings-layout__aside">
|
|
14
|
-
<slot name="aside"></slot>
|
|
15
|
-
</aside>
|
|
16
|
-
</div>
|
|
17
|
-
</template>
|
|
18
|
-
|
|
19
|
-
<style scoped lang="scss" src="./settings.scss"></style>
|