cja-phoenix 0.6.2 → 0.6.4
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/cja-phoenix.es.js +1952 -1899
- package/dist/style.css +1 -1
- package/dist/types/components/index.d.ts +2 -1
- package/dist/types/components/structural/Drawer.vue.d.ts +83 -0
- package/package.json +1 -1
- package/src/assets/iconia/demo.html +85 -1
- package/src/assets/iconia/fonts/CGG-icomoon.eot +0 -0
- package/src/assets/iconia/fonts/CGG-icomoon.svg +6 -0
- package/src/assets/iconia/fonts/CGG-icomoon.ttf +0 -0
- package/src/assets/iconia/fonts/CGG-icomoon.woff +0 -0
- package/src/assets/iconia/selection.json +1 -1
- package/src/assets/iconia/style.css +23 -5
- package/src/assets/iconia/style.scss +35 -5
- package/src/assets/iconia/variables.scss +6 -0
- package/src/components/index.ts +2 -0
- package/src/components/structural/Drawer.vue +193 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
@font-face {
|
|
2
2
|
font-family: 'CGG-icomoon';
|
|
3
|
-
src: url('fonts/CGG-icomoon.eot?
|
|
4
|
-
src: url('fonts/CGG-icomoon.eot?
|
|
5
|
-
url('fonts/CGG-icomoon.ttf?
|
|
6
|
-
url('fonts/CGG-icomoon.woff?
|
|
7
|
-
url('fonts/CGG-icomoon.svg?
|
|
3
|
+
src: url('fonts/CGG-icomoon.eot?jsyom4');
|
|
4
|
+
src: url('fonts/CGG-icomoon.eot?jsyom4#iefix') format('embedded-opentype'),
|
|
5
|
+
url('fonts/CGG-icomoon.ttf?jsyom4') format('truetype'),
|
|
6
|
+
url('fonts/CGG-icomoon.woff?jsyom4') format('woff'),
|
|
7
|
+
url('fonts/CGG-icomoon.svg?jsyom4#CGG-icomoon') format('svg');
|
|
8
8
|
font-weight: normal;
|
|
9
9
|
font-style: normal;
|
|
10
10
|
font-display: block;
|
|
@@ -25,6 +25,24 @@
|
|
|
25
25
|
-moz-osx-font-smoothing: grayscale;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
+
.m-cgg-icon--facebook-2:before {
|
|
29
|
+
content: "\ea33";
|
|
30
|
+
}
|
|
31
|
+
.m-cgg-icon--linkedin-2:before {
|
|
32
|
+
content: "\ea34";
|
|
33
|
+
}
|
|
34
|
+
.m-cgg-icon--twitter-2:before {
|
|
35
|
+
content: "\ea35";
|
|
36
|
+
}
|
|
37
|
+
.m-cgg-icon--whatsapp-2:before {
|
|
38
|
+
content: "\ea36";
|
|
39
|
+
}
|
|
40
|
+
.m-cgg-icon--reddit:before {
|
|
41
|
+
content: "\ea37";
|
|
42
|
+
}
|
|
43
|
+
.m-cgg-icon--telegram:before {
|
|
44
|
+
content: "\ea38";
|
|
45
|
+
}
|
|
28
46
|
.m-cgg-icon--filters:before {
|
|
29
47
|
content: "\ea31";
|
|
30
48
|
}
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
@font-face {
|
|
4
4
|
font-family: '#{$icomoon-font-family}';
|
|
5
|
-
src: url('#{$icomoon-font-path}/#{$icomoon-font-family}.eot?
|
|
6
|
-
src: url('#{$icomoon-font-path}/#{$icomoon-font-family}.eot?
|
|
7
|
-
url('#{$icomoon-font-path}/#{$icomoon-font-family}.ttf?
|
|
8
|
-
url('#{$icomoon-font-path}/#{$icomoon-font-family}.woff?
|
|
9
|
-
url('#{$icomoon-font-path}/#{$icomoon-font-family}.svg?
|
|
5
|
+
src: url('#{$icomoon-font-path}/#{$icomoon-font-family}.eot?jsyom4');
|
|
6
|
+
src: url('#{$icomoon-font-path}/#{$icomoon-font-family}.eot?jsyom4#iefix') format('embedded-opentype'),
|
|
7
|
+
url('#{$icomoon-font-path}/#{$icomoon-font-family}.ttf?jsyom4') format('truetype'),
|
|
8
|
+
url('#{$icomoon-font-path}/#{$icomoon-font-family}.woff?jsyom4') format('woff'),
|
|
9
|
+
url('#{$icomoon-font-path}/#{$icomoon-font-family}.svg?jsyom4##{$icomoon-font-family}') format('svg');
|
|
10
10
|
font-weight: normal;
|
|
11
11
|
font-style: normal;
|
|
12
12
|
font-display: block;
|
|
@@ -27,6 +27,36 @@
|
|
|
27
27
|
-moz-osx-font-smoothing: grayscale;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
+
.m-cgg-icon--facebook-2 {
|
|
31
|
+
&:before {
|
|
32
|
+
content: $m-cgg-icon--facebook-2;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
.m-cgg-icon--linkedin-2 {
|
|
36
|
+
&:before {
|
|
37
|
+
content: $m-cgg-icon--linkedin-2;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
.m-cgg-icon--twitter-2 {
|
|
41
|
+
&:before {
|
|
42
|
+
content: $m-cgg-icon--twitter-2;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
.m-cgg-icon--whatsapp-2 {
|
|
46
|
+
&:before {
|
|
47
|
+
content: $m-cgg-icon--whatsapp-2;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
.m-cgg-icon--reddit {
|
|
51
|
+
&:before {
|
|
52
|
+
content: $m-cgg-icon--reddit;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
.m-cgg-icon--telegram {
|
|
56
|
+
&:before {
|
|
57
|
+
content: $m-cgg-icon--telegram;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
30
60
|
.m-cgg-icon--filters {
|
|
31
61
|
&:before {
|
|
32
62
|
content: $m-cgg-icon--filters;
|
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
$icomoon-font-family: "CGG-icomoon" !default;
|
|
2
2
|
$icomoon-font-path: "fonts" !default;
|
|
3
3
|
|
|
4
|
+
$m-cgg-icon--facebook-2: "\ea33";
|
|
5
|
+
$m-cgg-icon--linkedin-2: "\ea34";
|
|
6
|
+
$m-cgg-icon--twitter-2: "\ea35";
|
|
7
|
+
$m-cgg-icon--whatsapp-2: "\ea36";
|
|
8
|
+
$m-cgg-icon--reddit: "\ea37";
|
|
9
|
+
$m-cgg-icon--telegram: "\ea38";
|
|
4
10
|
$m-cgg-icon--filters: "\ea31";
|
|
5
11
|
$m-cgg-icon--search: "\ea32";
|
|
6
12
|
$m-cgg-icon--macro-step-contact: "\ea24";
|
package/src/components/index.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import Modal from "./structural/Modal.vue";
|
|
2
|
+
import Drawer from "./structural/Drawer.vue";
|
|
2
3
|
import CjaButton from "./structural/CjaButton.vue";
|
|
3
4
|
import LoadingSpinner from "./structural/LoadingSpinner.vue";
|
|
4
5
|
import ContentTabs from "./structural/ContentTabs.vue";
|
|
@@ -37,6 +38,7 @@ import InfoShowcase from "./composite/InfoShowcase.vue";
|
|
|
37
38
|
|
|
38
39
|
export {
|
|
39
40
|
Modal,
|
|
41
|
+
Drawer,
|
|
40
42
|
CjaButton,
|
|
41
43
|
TextInput,
|
|
42
44
|
PhoneInput,
|
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<Teleport to="body">
|
|
3
|
+
<Transition name="fade">
|
|
4
|
+
<div
|
|
5
|
+
class="drawer-backdrop"
|
|
6
|
+
v-if="backdrop && active"
|
|
7
|
+
@click="closeDrawer"
|
|
8
|
+
></div>
|
|
9
|
+
</Transition>
|
|
10
|
+
<Transition name="slide">
|
|
11
|
+
<div
|
|
12
|
+
class="drawer-container"
|
|
13
|
+
:class="[`drawer-${type}`, { active: active }]"
|
|
14
|
+
:style="{ height, ...cssVars }"
|
|
15
|
+
>
|
|
16
|
+
<slot></slot>
|
|
17
|
+
</div>
|
|
18
|
+
</Transition>
|
|
19
|
+
</Teleport>
|
|
20
|
+
</template>
|
|
21
|
+
|
|
22
|
+
<script lang="ts" setup>
|
|
23
|
+
import { ref } from "vue";
|
|
24
|
+
import { computed } from "vue";
|
|
25
|
+
|
|
26
|
+
const props = withDefaults(
|
|
27
|
+
defineProps<{
|
|
28
|
+
defaultActive?: boolean;
|
|
29
|
+
type?:
|
|
30
|
+
| "vertical-top"
|
|
31
|
+
| "vertical-bottom"
|
|
32
|
+
| "horizontal-left"
|
|
33
|
+
| "horizontal-right";
|
|
34
|
+
maxWidth?: {
|
|
35
|
+
md?: string;
|
|
36
|
+
lg?: string;
|
|
37
|
+
xl?: string;
|
|
38
|
+
};
|
|
39
|
+
height?: string;
|
|
40
|
+
backdrop?: boolean;
|
|
41
|
+
}>(),
|
|
42
|
+
{
|
|
43
|
+
defaultActive: false,
|
|
44
|
+
type: "vertical-bottom",
|
|
45
|
+
backdrop: false,
|
|
46
|
+
close: true,
|
|
47
|
+
maxWidth: () => ({
|
|
48
|
+
md: "min(calc(100% - 48px), 768px)",
|
|
49
|
+
lg: "min(calc(100% - 48px), 1024px)",
|
|
50
|
+
xl: "1024px",
|
|
51
|
+
}),
|
|
52
|
+
}
|
|
53
|
+
);
|
|
54
|
+
|
|
55
|
+
const cssVars = computed(() => ({
|
|
56
|
+
"--md-max-width": props.maxWidth.md,
|
|
57
|
+
"--lg-max-width": props.maxWidth.lg,
|
|
58
|
+
"--xl-max-width": props.maxWidth.xl,
|
|
59
|
+
}));
|
|
60
|
+
|
|
61
|
+
const active = ref(props.defaultActive);
|
|
62
|
+
|
|
63
|
+
const emit = defineEmits(["close", "open"]);
|
|
64
|
+
|
|
65
|
+
const openDrawer = () => {
|
|
66
|
+
active.value = true;
|
|
67
|
+
emit("open");
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
const closeDrawer = () => {
|
|
71
|
+
active.value = false;
|
|
72
|
+
emit("close");
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
const toggleDrawer = () => {
|
|
76
|
+
active.value = !active.value;
|
|
77
|
+
|
|
78
|
+
emit(active.value ? "open" : "close");
|
|
79
|
+
};
|
|
80
|
+
|
|
81
|
+
defineExpose({ active, openDrawer, closeDrawer, toggleDrawer });
|
|
82
|
+
</script>
|
|
83
|
+
|
|
84
|
+
<style lang="scss" scoped>
|
|
85
|
+
@import "../../assets/breakpoints.scss";
|
|
86
|
+
@import "../../assets/backdrop.scss";
|
|
87
|
+
|
|
88
|
+
.drawer-backdrop {
|
|
89
|
+
@include backdrop;
|
|
90
|
+
|
|
91
|
+
&.fade-enter-from,
|
|
92
|
+
&.fade-leave-to {
|
|
93
|
+
opacity: 0;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
&.fade-enter-to,
|
|
97
|
+
&.fade-leave-from {
|
|
98
|
+
opacity: 1;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.drawer-container {
|
|
103
|
+
position: fixed;
|
|
104
|
+
z-index: 1000;
|
|
105
|
+
width: 100%;
|
|
106
|
+
transition: all 0.3s ease-in-out;
|
|
107
|
+
|
|
108
|
+
@media screen and (min-width: $break-md-min) {
|
|
109
|
+
max-width: var(--md-max-width);
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
@media screen and (min-width: $break-lg-min) {
|
|
113
|
+
max-width: var(--lg-max-width);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
@media screen and (min-width: $break-xl-min) {
|
|
117
|
+
max-width: var(--xl-max-width);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
&.drawer-vertical-top {
|
|
121
|
+
top: 0;
|
|
122
|
+
|
|
123
|
+
&.active {
|
|
124
|
+
transform: translateY(0);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
&.slide-enter-from,
|
|
128
|
+
&.slide-leave-to {
|
|
129
|
+
transform: translateY(-100%);
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
&.slide-enter-to,
|
|
133
|
+
&.slide-leave-from {
|
|
134
|
+
transform: translateY(0);
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
&.drawer-vertical-bottom {
|
|
139
|
+
bottom: 0;
|
|
140
|
+
transform: translateY(100%);
|
|
141
|
+
|
|
142
|
+
&.active {
|
|
143
|
+
transform: translateY(0);
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
&.slide-enter-from,
|
|
147
|
+
&.slide-leave-to {
|
|
148
|
+
transform: translateY(100%);
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
&.slide-enter-to,
|
|
152
|
+
&.slide-leave-from {
|
|
153
|
+
transform: translateY(0);
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
&.drawer-horizontal-left {
|
|
158
|
+
left: 0;
|
|
159
|
+
|
|
160
|
+
&.active {
|
|
161
|
+
transform: translateX(0);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
&.slide-enter-from,
|
|
165
|
+
&.slide-leave-to {
|
|
166
|
+
transform: translateX(-100%);
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
&.slide-enter-to,
|
|
170
|
+
&.slide-leave-from {
|
|
171
|
+
transform: translateX(0);
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
&.drawer-horizontal-right {
|
|
176
|
+
right: 0;
|
|
177
|
+
|
|
178
|
+
&.active {
|
|
179
|
+
transform: translateX(0);
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
&.slide-enter-from,
|
|
183
|
+
&.slide-leave-to {
|
|
184
|
+
transform: translateX(100%);
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
&.slide-enter-to,
|
|
188
|
+
&.slide-leave-from {
|
|
189
|
+
transform: translateX(0);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
</style>
|