@icvdeveloper/common-module 0.0.1
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/README.md +6 -0
- package/dist/module.cjs +5 -0
- package/dist/module.d.ts +9 -0
- package/dist/module.json +8 -0
- package/dist/module.mjs +102051 -0
- package/dist/runtime/@types/configVariables.d.ts +78 -0
- package/dist/runtime/@types/configVariables.mjs +0 -0
- package/dist/runtime/analytics.d.ts +8 -0
- package/dist/runtime/analytics.mjs +38 -0
- package/dist/runtime/assets/scss/_agenda.scss +47 -0
- package/dist/runtime/assets/scss/_animations.scss +11 -0
- package/dist/runtime/assets/scss/_container_variants.scss +26 -0
- package/dist/runtime/assets/scss/_custom.scss +364 -0
- package/dist/runtime/assets/scss/_footer.scss +20 -0
- package/dist/runtime/assets/scss/_forms.scss +29 -0
- package/dist/runtime/assets/scss/_functions.scss +24 -0
- package/dist/runtime/assets/scss/_header.scss +41 -0
- package/dist/runtime/assets/scss/_index_production.scss +45 -0
- package/dist/runtime/assets/scss/_transitions.scss +24 -0
- package/dist/runtime/assets/scss/_variables.scss +62 -0
- package/dist/runtime/assets/scss/_variables2.scss +0 -0
- package/dist/runtime/assets/scss/_webcast.scss +141 -0
- package/dist/runtime/assets/scss/index.scss +42 -0
- package/dist/runtime/assets/svg/answer.svg +14 -0
- package/dist/runtime/assets/svg/avatar.svg +1 -0
- package/dist/runtime/assets/svg/bell-icon.svg +3 -0
- package/dist/runtime/assets/svg/chat-icon.svg +1 -0
- package/dist/runtime/assets/svg/checkmark-icon.svg +1 -0
- package/dist/runtime/assets/svg/close-icon.svg +1 -0
- package/dist/runtime/assets/svg/icon-avatar.svg +1 -0
- package/dist/runtime/assets/svg/icon-close.svg +1 -0
- package/dist/runtime/assets/svg/icon-down-arrow.svg +1 -0
- package/dist/runtime/assets/svg/icon-facebook.svg +1 -0
- package/dist/runtime/assets/svg/icon-info.svg +3 -0
- package/dist/runtime/assets/svg/icon-linkedin.svg +1 -0
- package/dist/runtime/assets/svg/icon-new-window.svg +11 -0
- package/dist/runtime/assets/svg/icon-offline.svg +3 -0
- package/dist/runtime/assets/svg/icon-online.svg +3 -0
- package/dist/runtime/assets/svg/icon-person.svg +3 -0
- package/dist/runtime/assets/svg/icon-play.svg +3 -0
- package/dist/runtime/assets/svg/icon-star-filled.svg +30 -0
- package/dist/runtime/assets/svg/icon-star.svg +25 -0
- package/dist/runtime/assets/svg/icon-twitter.svg +1 -0
- package/dist/runtime/assets/svg/icon-video-chat.svg +14 -0
- package/dist/runtime/assets/svg/icon-website.svg +3 -0
- package/dist/runtime/assets/svg/icon-youtube.svg +1 -0
- package/dist/runtime/assets/svg/icon-zoom.svg +10 -0
- package/dist/runtime/assets/svg/notification-icon.svg +32 -0
- package/dist/runtime/assets/svg/offline-icon.svg +1 -0
- package/dist/runtime/assets/svg/online-icon.svg +3 -0
- package/dist/runtime/assets/svg/peer2peer.svg +3 -0
- package/dist/runtime/assets/svg/phone.svg +1 -0
- package/dist/runtime/assets/svg/plus-icon.svg +1 -0
- package/dist/runtime/assets/svg/red-icon.svg +3 -0
- package/dist/runtime/assets/svg/reject.svg +14 -0
- package/dist/runtime/assets/svg/search-icon.svg +3 -0
- package/dist/runtime/components/affiliates/AffiliatePage.vue +16 -0
- package/dist/runtime/components/agenda/AgendaTabbed.vue +342 -0
- package/dist/runtime/components/agenda/components/InfoLink.vue +55 -0
- package/dist/runtime/components/agenda/components/PlayIcon.vue +48 -0
- package/dist/runtime/components/agenda/components/PresentationLink.vue +147 -0
- package/dist/runtime/components/agenda/components/Sponsor.vue +108 -0
- package/dist/runtime/components/auth/LoginFullWidth.vue +76 -0
- package/dist/runtime/components/core/CountdownTimer.vue +275 -0
- package/dist/runtime/components/core/DynamicHtml.vue +16 -0
- package/dist/runtime/components/core/DynamicHtml.vue.d.ts +2 -0
- package/dist/runtime/components/core/Modal.vue +84 -0
- package/dist/runtime/components/core/SvgIcon.vue +119 -0
- package/dist/runtime/components/core/ZoomModal.vue +37 -0
- package/dist/runtime/components/events/EventHeader.vue +131 -0
- package/dist/runtime/components/events/PastEvents.vue +150 -0
- package/dist/runtime/components/events/UpcomingEvents.vue +145 -0
- package/dist/runtime/components/forms/ErrorField.vue +19 -0
- package/dist/runtime/components/forms/Message.vue +25 -0
- package/dist/runtime/components/forms/SearchInput.vue +30 -0
- package/dist/runtime/components/forms/SupportForm.vue +109 -0
- package/dist/runtime/components/forms/TextArea.vue +26 -0
- package/dist/runtime/components/forms/TextInput.vue +22 -0
- package/dist/runtime/components/layouts/Accordion.vue +76 -0
- package/dist/runtime/components/presenters/PresenterListing.vue +89 -0
- package/dist/runtime/components/presenters/PresenterModal.vue +83 -0
- package/dist/runtime/composables/useAgenda.d.ts +81 -0
- package/dist/runtime/composables/useAgenda.mjs +178 -0
- package/dist/runtime/composables/useAnalytics.d.ts +7 -0
- package/dist/runtime/composables/useAnalytics.mjs +10 -0
- package/dist/runtime/composables/useApi.d.ts +1 -0
- package/dist/runtime/composables/useApi.mjs +16 -0
- package/dist/runtime/composables/useConferenceHelpers.d.ts +65 -0
- package/dist/runtime/composables/useConferenceHelpers.mjs +270 -0
- package/dist/runtime/composables/useDateFormat.d.ts +12 -0
- package/dist/runtime/composables/useDateFormat.mjs +21 -0
- package/dist/runtime/composables/useLogin.d.ts +30 -0
- package/dist/runtime/composables/useLogin.mjs +58 -0
- package/dist/runtime/composables/usePresentation.d.ts +53 -0
- package/dist/runtime/composables/usePresentation.mjs +98 -0
- package/dist/runtime/composables/usePresenter.d.ts +15 -0
- package/dist/runtime/composables/usePresenter.mjs +67 -0
- package/dist/runtime/composables/usePresenters.d.ts +13 -0
- package/dist/runtime/composables/usePresenters.mjs +21 -0
- package/dist/runtime/composables/useV3plusCommonModule.d.ts +2 -0
- package/dist/runtime/composables/useV3plusCommonModule.mjs +2 -0
- package/dist/runtime/models/affiliate.d.ts +1 -0
- package/dist/runtime/models/affiliate.mjs +0 -0
- package/dist/runtime/models/authUser.d.ts +16 -0
- package/dist/runtime/models/authUser.mjs +0 -0
- package/dist/runtime/models/conference.d.ts +124 -0
- package/dist/runtime/models/conference.mjs +18 -0
- package/dist/runtime/models/globalConfig.d.ts +80 -0
- package/dist/runtime/models/globalConfig.mjs +0 -0
- package/dist/runtime/models/group.d.ts +14 -0
- package/dist/runtime/models/group.mjs +0 -0
- package/dist/runtime/models/icons.d.ts +18 -0
- package/dist/runtime/models/icons.mjs +0 -0
- package/dist/runtime/models/navigationConfig.d.ts +8 -0
- package/dist/runtime/models/navigationConfig.mjs +0 -0
- package/dist/runtime/models/pagesConfig.d.ts +169 -0
- package/dist/runtime/models/pagesConfig.mjs +0 -0
- package/dist/runtime/models/portal.d.ts +8 -0
- package/dist/runtime/models/portal.mjs +0 -0
- package/dist/runtime/models/templateConfig.d.ts +44 -0
- package/dist/runtime/models/templateConfig.mjs +0 -0
- package/dist/runtime/plugin.d.ts +2 -0
- package/dist/runtime/plugin.mjs +55 -0
- package/dist/runtime/store/affiliates.d.ts +12 -0
- package/dist/runtime/store/affiliates.mjs +35 -0
- package/dist/runtime/store/auth.d.ts +14 -0
- package/dist/runtime/store/auth.mjs +32 -0
- package/dist/runtime/store/conferences.d.ts +13 -0
- package/dist/runtime/store/conferences.mjs +86 -0
- package/dist/runtime/store/navigationConfig.d.ts +7 -0
- package/dist/runtime/store/navigationConfig.mjs +14 -0
- package/dist/runtime/store/portal.d.ts +9 -0
- package/dist/runtime/store/portal.mjs +39 -0
- package/dist/runtime/store/support.d.ts +3 -0
- package/dist/runtime/store/support.mjs +20 -0
- package/dist/runtime/store/templateConfigs.d.ts +20 -0
- package/dist/runtime/store/templateConfigs.mjs +84 -0
- package/dist/runtime/v3plusCommonPlugin.d.ts +14 -0
- package/dist/runtime/v3plusCommonPlugin.mjs +8 -0
- package/dist/types.d.ts +10 -0
- package/package.json +57 -0
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
<script lang="ts" setup>
|
|
2
|
+
import { find } from "lodash";
|
|
3
|
+
import { Sponsor as SponsorModel } from "../../../models/conference";
|
|
4
|
+
|
|
5
|
+
type Props = {
|
|
6
|
+
sponsor: SponsorModel;
|
|
7
|
+
size?: string;
|
|
8
|
+
inline?: boolean;
|
|
9
|
+
hideLabel?: boolean;
|
|
10
|
+
enabledSponsors?: SponsorModel[];
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
14
|
+
size: "default",
|
|
15
|
+
inline: false,
|
|
16
|
+
hideLabel: false,
|
|
17
|
+
enabledSponsors: () => {
|
|
18
|
+
return [];
|
|
19
|
+
},
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
const { sponsor, size, inline, hideLabel, enabledSponsors } = toRefs(props);
|
|
23
|
+
|
|
24
|
+
// data
|
|
25
|
+
const showModal = ref<boolean>(false);
|
|
26
|
+
const enabledSponsor = ref<SponsorModel | null>(null);
|
|
27
|
+
|
|
28
|
+
// methods
|
|
29
|
+
const handleClick = () => {
|
|
30
|
+
if (enabledSponsors.value.length > 0) {
|
|
31
|
+
const sponsorResult = find(enabledSponsors.value, { id: sponsor.value.id });
|
|
32
|
+
|
|
33
|
+
if (sponsorResult && sponsorResult.vanity === 1) {
|
|
34
|
+
enabledSponsor.value = sponsorResult;
|
|
35
|
+
showModal.value = true;
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
window.open(sponsor.value.website, "_blank");
|
|
41
|
+
};
|
|
42
|
+
</script>
|
|
43
|
+
|
|
44
|
+
<template>
|
|
45
|
+
<div class="flex flex-col lg:flex-row flex-1 items-center">
|
|
46
|
+
<div :class="size">
|
|
47
|
+
<div :class="inline ? 'flex-1 items-center' : 'w-full'">
|
|
48
|
+
<h2
|
|
49
|
+
v-if="!hideLabel"
|
|
50
|
+
:class="{
|
|
51
|
+
'inline-block lg:pr-5 pb-2 lg:pb-0': inline,
|
|
52
|
+
'pb-2': !inline,
|
|
53
|
+
}"
|
|
54
|
+
class="text-center uppercase font-medium"
|
|
55
|
+
>
|
|
56
|
+
{{ sponsor.label }}
|
|
57
|
+
</h2>
|
|
58
|
+
</div>
|
|
59
|
+
<div :class="inline ? 'flex-1 items-center pb-2 lg:pb-0' : 'w-full'">
|
|
60
|
+
<img
|
|
61
|
+
:class="{ block: !inline }"
|
|
62
|
+
class="sponsor-img m-auto cursor-pointer"
|
|
63
|
+
:src="sponsor.photo"
|
|
64
|
+
@click="handleClick()"
|
|
65
|
+
/>
|
|
66
|
+
</div>
|
|
67
|
+
</div>
|
|
68
|
+
|
|
69
|
+
<CommonModal :visible="showModal">
|
|
70
|
+
<template #modal-body>
|
|
71
|
+
<CommonAffiliatePage
|
|
72
|
+
v-if="enabledSponsor"
|
|
73
|
+
:affiliate="enabledSponsor"
|
|
74
|
+
></CommonAffiliatePage>
|
|
75
|
+
</template>
|
|
76
|
+
</CommonModal>
|
|
77
|
+
</div>
|
|
78
|
+
</template>
|
|
79
|
+
|
|
80
|
+
<style lang="scss">
|
|
81
|
+
.small {
|
|
82
|
+
h2 {
|
|
83
|
+
font-size: 14px;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
img {
|
|
87
|
+
max-height: 35px !important;
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.medium {
|
|
92
|
+
h2 {
|
|
93
|
+
font-size: 0.9em;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
img {
|
|
97
|
+
max-height: 40px;
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.default {
|
|
102
|
+
width: 100%;
|
|
103
|
+
|
|
104
|
+
img {
|
|
105
|
+
max-height: 60px;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
</style>
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
<script lang="ts" setup>
|
|
2
|
+
import { storeToRefs } from "pinia";
|
|
3
|
+
import { Conference } from "../../models/conference";
|
|
4
|
+
import { useLogin } from "../../composables/useLogin";
|
|
5
|
+
|
|
6
|
+
interface Props {
|
|
7
|
+
conference?: Conference | null;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
11
|
+
conference: null,
|
|
12
|
+
});
|
|
13
|
+
|
|
14
|
+
const { conference } = toRefs<Props>(props);
|
|
15
|
+
|
|
16
|
+
const { globalConfigValue } = storeToRefs(useTemplateConfigsStore());
|
|
17
|
+
|
|
18
|
+
// Methods
|
|
19
|
+
const { loginError, handleLogin, email, password, tooManySessions, showReset } =
|
|
20
|
+
useLogin(conference);
|
|
21
|
+
</script>
|
|
22
|
+
|
|
23
|
+
<template>
|
|
24
|
+
<div class="px-2">
|
|
25
|
+
<div class="flex flex-1 flex-col text-center pt-8">
|
|
26
|
+
<h1 class="mb-3 heading-color-3">Log In</h1>
|
|
27
|
+
<Message
|
|
28
|
+
v-if="loginError"
|
|
29
|
+
:success="false"
|
|
30
|
+
class="w-full max-w-xs mx-auto"
|
|
31
|
+
>
|
|
32
|
+
Invalid email or password.
|
|
33
|
+
<br />
|
|
34
|
+
<a
|
|
35
|
+
v-if="!globalConfigValue('secure_site_access_enabled', false)"
|
|
36
|
+
href="/login/email"
|
|
37
|
+
>Forgot Your Password?</a
|
|
38
|
+
>
|
|
39
|
+
<a
|
|
40
|
+
v-if="globalConfigValue('secure_site_access_enabled', false)"
|
|
41
|
+
class="cursor-pointer"
|
|
42
|
+
@click="showReset"
|
|
43
|
+
>Forgot Your Password?</a
|
|
44
|
+
>
|
|
45
|
+
</Message>
|
|
46
|
+
|
|
47
|
+
<div class="max-w-xs mx-auto" @keyup.enter="handleLogin()">
|
|
48
|
+
<input
|
|
49
|
+
v-model="email"
|
|
50
|
+
type="email"
|
|
51
|
+
placeholder="Email"
|
|
52
|
+
class="form-input contrast-border mb-2"
|
|
53
|
+
/>
|
|
54
|
+
<input
|
|
55
|
+
v-model="password"
|
|
56
|
+
type="password"
|
|
57
|
+
placeholder="password"
|
|
58
|
+
class="form-input contrast-border mb-5"
|
|
59
|
+
/>
|
|
60
|
+
<button v-if="!tooManySessions" class="btn" @click="handleLogin()">
|
|
61
|
+
Log In
|
|
62
|
+
</button>
|
|
63
|
+
<Message
|
|
64
|
+
v-if="tooManySessions"
|
|
65
|
+
:success="false"
|
|
66
|
+
class="w-full max-w-xs mx-auto"
|
|
67
|
+
>
|
|
68
|
+
This user access is logged in on another device!
|
|
69
|
+
</Message>
|
|
70
|
+
<button v-if="tooManySessions" class="btn" @click="handleLogin(true)">
|
|
71
|
+
Sign out other Device
|
|
72
|
+
</button>
|
|
73
|
+
</div>
|
|
74
|
+
</div>
|
|
75
|
+
</div>
|
|
76
|
+
</template>
|
|
@@ -0,0 +1,275 @@
|
|
|
1
|
+
<script lang="ts" setup>
|
|
2
|
+
import { storeToRefs } from "pinia";
|
|
3
|
+
import {
|
|
4
|
+
isBefore,
|
|
5
|
+
differenceInDays,
|
|
6
|
+
differenceInHours,
|
|
7
|
+
differenceInMinutes,
|
|
8
|
+
differenceInSeconds,
|
|
9
|
+
addDays,
|
|
10
|
+
addHours,
|
|
11
|
+
addMinutes,
|
|
12
|
+
} from "date-fns";
|
|
13
|
+
|
|
14
|
+
interface Props {
|
|
15
|
+
date: string;
|
|
16
|
+
isCompact?: boolean;
|
|
17
|
+
showDays?: boolean;
|
|
18
|
+
showHours?: boolean;
|
|
19
|
+
showMinutes?: boolean;
|
|
20
|
+
showSeconds?: boolean;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
24
|
+
isCompact: false,
|
|
25
|
+
showDays: true,
|
|
26
|
+
showHours: true,
|
|
27
|
+
showMinutes: true,
|
|
28
|
+
showSeconds: true,
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
// reactive data
|
|
32
|
+
const isCounting = ref<boolean>(true);
|
|
33
|
+
const days = ref<number>(0);
|
|
34
|
+
const hours = ref<number>(0);
|
|
35
|
+
const minutes = ref<number>(0);
|
|
36
|
+
const seconds = ref<number>(0);
|
|
37
|
+
const loopTimer = ref<NodeJS.Timer | null>(null);
|
|
38
|
+
const { pagesConfigValue } = storeToRefs(useTemplateConfigsStore());
|
|
39
|
+
|
|
40
|
+
// emits
|
|
41
|
+
const emit = defineEmits(["complete"]);
|
|
42
|
+
|
|
43
|
+
// computed
|
|
44
|
+
const eventHasBegunText = computed(() => {
|
|
45
|
+
return (
|
|
46
|
+
pagesConfigValue.value("main.countdown_event_has_begun_text") ||
|
|
47
|
+
"The Event Has Begun"
|
|
48
|
+
);
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
const clockStyle = computed(() => {
|
|
52
|
+
return pagesConfigValue.value("main.countdown_timer_style", "windows");
|
|
53
|
+
});
|
|
54
|
+
|
|
55
|
+
const fontClass = computed(() => {
|
|
56
|
+
const fontBase = "text-countdown-int font-bold";
|
|
57
|
+
return props.isCompact === true
|
|
58
|
+
? fontBase + " text-xl lg:text-2xl"
|
|
59
|
+
: fontBase + " text-2xl lg:text-4xl";
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
// methods
|
|
63
|
+
const updateCountdown = () => {
|
|
64
|
+
if (!isBefore(new Date(), new Date(props.date))) {
|
|
65
|
+
isCounting.value = false;
|
|
66
|
+
emit("complete");
|
|
67
|
+
clearInterval(loopTimer.value);
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
days.value = differenceInDays(new Date(props.date), new Date());
|
|
72
|
+
hours.value = differenceInHours(
|
|
73
|
+
new Date(props.date),
|
|
74
|
+
addDays(new Date(), days.value)
|
|
75
|
+
);
|
|
76
|
+
|
|
77
|
+
minutes.value = differenceInMinutes(
|
|
78
|
+
new Date(props.date),
|
|
79
|
+
addDays(addHours(new Date(), hours.value), days.value)
|
|
80
|
+
);
|
|
81
|
+
seconds.value = differenceInSeconds(
|
|
82
|
+
new Date(props.date),
|
|
83
|
+
addDays(
|
|
84
|
+
addHours(addMinutes(new Date(), minutes.value), hours.value),
|
|
85
|
+
days.value
|
|
86
|
+
)
|
|
87
|
+
);
|
|
88
|
+
};
|
|
89
|
+
|
|
90
|
+
const startCountdown = () => {
|
|
91
|
+
updateCountdown();
|
|
92
|
+
loopTimer.value = setInterval(() => {
|
|
93
|
+
updateCountdown();
|
|
94
|
+
}, 1000);
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
// on mount
|
|
98
|
+
onMounted(() => {
|
|
99
|
+
startCountdown();
|
|
100
|
+
});
|
|
101
|
+
</script>
|
|
102
|
+
|
|
103
|
+
<template>
|
|
104
|
+
<div
|
|
105
|
+
class="countdown-timer"
|
|
106
|
+
:class="{ compact: isCompact, fullsize: !isCompact }"
|
|
107
|
+
>
|
|
108
|
+
<div
|
|
109
|
+
class="countdown-container flex flex-col pt-8 mx-4 text-center justify-center items-center content-center"
|
|
110
|
+
>
|
|
111
|
+
<div class="flex-initial">
|
|
112
|
+
<h1 v-if="isCounting" class="m-0 p-0 heading-color-3">EVENT BEGINS</h1>
|
|
113
|
+
<h1 v-if="!isCounting" class="m-0 p-0 heading-color-3">
|
|
114
|
+
{{ eventHasBegunText }}
|
|
115
|
+
</h1>
|
|
116
|
+
</div>
|
|
117
|
+
|
|
118
|
+
<div
|
|
119
|
+
v-if="isCounting"
|
|
120
|
+
class="units-container flex text-center p-6 pt-4 mt-4 items-center border border-color-accent-1 accent-color-3"
|
|
121
|
+
>
|
|
122
|
+
<!-- Days -->
|
|
123
|
+
<div
|
|
124
|
+
v-if="showDays"
|
|
125
|
+
class="item-container"
|
|
126
|
+
:class="{ dropshade: clockStyle == 'dials' }"
|
|
127
|
+
>
|
|
128
|
+
<div class="unit-label-container" :class="clockStyle">days</div>
|
|
129
|
+
<div class="unit-container contrast-border" :class="clockStyle">
|
|
130
|
+
<div v-if="clockStyle == 'windows'" :class="fontClass">
|
|
131
|
+
{{ days }}
|
|
132
|
+
</div>
|
|
133
|
+
<transition v-if="clockStyle == 'dials'" name="slide" mode="out-in">
|
|
134
|
+
<div :key="days" :class="fontClass">{{ days }}</div>
|
|
135
|
+
</transition>
|
|
136
|
+
</div>
|
|
137
|
+
</div>
|
|
138
|
+
</div>
|
|
139
|
+
</div>
|
|
140
|
+
</div>
|
|
141
|
+
</template>
|
|
142
|
+
|
|
143
|
+
<style lang="scss" scoped>
|
|
144
|
+
.countdown-timer.compact {
|
|
145
|
+
.countdown-container {
|
|
146
|
+
@apply pt-0 mx-0;
|
|
147
|
+
}
|
|
148
|
+
h1 {
|
|
149
|
+
@apply text-xl;
|
|
150
|
+
}
|
|
151
|
+
.units-container {
|
|
152
|
+
@apply p-4 mt-1;
|
|
153
|
+
}
|
|
154
|
+
.unit-container.windows {
|
|
155
|
+
width: 60px;
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
/* label + number container */
|
|
160
|
+
.item-container {
|
|
161
|
+
@apply flex flex-col;
|
|
162
|
+
}
|
|
163
|
+
/* days hrs min sec labels */
|
|
164
|
+
.unit-label-container {
|
|
165
|
+
@apply text-xs font-light;
|
|
166
|
+
height: 18px;
|
|
167
|
+
}
|
|
168
|
+
.unit-label-container.windows {
|
|
169
|
+
@apply pb-4 uppercase tracking-wide;
|
|
170
|
+
}
|
|
171
|
+
.unit-label-container.dials {
|
|
172
|
+
@apply mx-0;
|
|
173
|
+
padding-top: 2px;
|
|
174
|
+
border-top: 1px solid #eee;
|
|
175
|
+
border-left: 1px solid #eee;
|
|
176
|
+
border-right: 1px solid #ccc;
|
|
177
|
+
border-bottom: 1px solid #ddd;
|
|
178
|
+
background-image: linear-gradient(#fafafa, #efefef, #e6e6e6);
|
|
179
|
+
}
|
|
180
|
+
.unit-label-container.dials.last {
|
|
181
|
+
width: 67px;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
/* number boxes */
|
|
185
|
+
.unit-container {
|
|
186
|
+
@apply flex text-center items-center justify-center overflow-hidden;
|
|
187
|
+
}
|
|
188
|
+
.unit-container.windows {
|
|
189
|
+
@apply mx-1 px-2 border-4 rounded-lg shadow-md;
|
|
190
|
+
width: 70px;
|
|
191
|
+
}
|
|
192
|
+
.unit-container.dials {
|
|
193
|
+
@apply mx-0 shadow;
|
|
194
|
+
width: 70px;
|
|
195
|
+
height: 36px;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
/* numbers */
|
|
199
|
+
.text-countdown-int {
|
|
200
|
+
//color: $heading-color-6;
|
|
201
|
+
}
|
|
202
|
+
.countdown-timer.compact .text-countdown-unit {
|
|
203
|
+
@apply pb-1;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
/* dropshade for dials */
|
|
207
|
+
.dropshade {
|
|
208
|
+
position: relative;
|
|
209
|
+
overflow: hidden;
|
|
210
|
+
}
|
|
211
|
+
.dropshade:before,
|
|
212
|
+
.dropshade:after {
|
|
213
|
+
content: "";
|
|
214
|
+
position: absolute;
|
|
215
|
+
z-index: 1;
|
|
216
|
+
top: 18px;
|
|
217
|
+
bottom: 0px;
|
|
218
|
+
width: 85px;
|
|
219
|
+
-webkit-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.2);
|
|
220
|
+
-moz-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.2);
|
|
221
|
+
box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.2);
|
|
222
|
+
-webkit-border-radius: 15px / 80px;
|
|
223
|
+
-moz-border-radius: 15px / 80px;
|
|
224
|
+
border-radius: 10px / 80px;
|
|
225
|
+
background-image: linear-gradient(
|
|
226
|
+
rgba(0, 0, 0, 0),
|
|
227
|
+
rgba(0, 0, 0, 0),
|
|
228
|
+
rgba(0, 0, 0, 0.1)
|
|
229
|
+
);
|
|
230
|
+
}
|
|
231
|
+
.dropshade:before {
|
|
232
|
+
left: -84px;
|
|
233
|
+
}
|
|
234
|
+
.dropshade:after {
|
|
235
|
+
left: -14px;
|
|
236
|
+
}
|
|
237
|
+
.dropshade.last:after {
|
|
238
|
+
left: -18px;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
/* lg: dials */
|
|
242
|
+
@screen lg {
|
|
243
|
+
.countdown-timer.fullsize {
|
|
244
|
+
.unit-container.windows,
|
|
245
|
+
.unit-container.dials {
|
|
246
|
+
width: 80px;
|
|
247
|
+
height: 46px;
|
|
248
|
+
}
|
|
249
|
+
.unit-label-container.dials.last {
|
|
250
|
+
width: 77px;
|
|
251
|
+
}
|
|
252
|
+
.dropshade:before {
|
|
253
|
+
left: -84px;
|
|
254
|
+
}
|
|
255
|
+
.dropshade:after {
|
|
256
|
+
left: -4px;
|
|
257
|
+
}
|
|
258
|
+
.dropshade.last:after {
|
|
259
|
+
left: -8px;
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
/* dials transitions */
|
|
265
|
+
.slide-leave-active,
|
|
266
|
+
.slide-enter-active {
|
|
267
|
+
transition: 0.3s;
|
|
268
|
+
}
|
|
269
|
+
.slide-enter {
|
|
270
|
+
transform: translate(0, -100%);
|
|
271
|
+
}
|
|
272
|
+
.slide-leave-active {
|
|
273
|
+
transform: translate(0, 100%);
|
|
274
|
+
}
|
|
275
|
+
</style>
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
import { h } from "vue";
|
|
3
|
+
export default defineComponent({
|
|
4
|
+
props: {
|
|
5
|
+
template: {
|
|
6
|
+
type: String,
|
|
7
|
+
default: ""
|
|
8
|
+
}
|
|
9
|
+
},
|
|
10
|
+
setup(props, context) {
|
|
11
|
+
return () => h("span", {
|
|
12
|
+
innerHtml: props.template
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
</script>
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
interface Props {
|
|
3
|
+
visible?: boolean;
|
|
4
|
+
modalSize?: string;
|
|
5
|
+
noScroll?: boolean;
|
|
6
|
+
showClose?: boolean;
|
|
7
|
+
usePadding?: boolean;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
11
|
+
visible: false,
|
|
12
|
+
modalSize: "25",
|
|
13
|
+
noScroll: false,
|
|
14
|
+
showClose: true,
|
|
15
|
+
usePadding: true,
|
|
16
|
+
});
|
|
17
|
+
|
|
18
|
+
const emit = defineEmits(["trigger", "clicked"]);
|
|
19
|
+
|
|
20
|
+
const { visible, modalSize, noScroll, showClose, usePadding } = toRefs(props);
|
|
21
|
+
|
|
22
|
+
const modalClass = computed(() => {
|
|
23
|
+
const padding = usePadding ? "p-6" : "";
|
|
24
|
+
const classes = `relative w-full ${padding} m-auto flex-col flex rounded shadow bg-white modal-box`;
|
|
25
|
+
if (noScroll) {
|
|
26
|
+
return classes + ` max-h-full overflow-hidden`;
|
|
27
|
+
} else {
|
|
28
|
+
return classes + ` overflow-y-auto`;
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
const closeModal = () => {
|
|
33
|
+
emit("trigger");
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
const clicked = () => {
|
|
37
|
+
emit("clicked");
|
|
38
|
+
};
|
|
39
|
+
</script>
|
|
40
|
+
|
|
41
|
+
<template>
|
|
42
|
+
<Transition>
|
|
43
|
+
<div
|
|
44
|
+
v-if="visible"
|
|
45
|
+
class="fixed top-0 bottom-0 left-0 right-0 z-50 flex bg-smoke-light p-3"
|
|
46
|
+
@click="clicked"
|
|
47
|
+
>
|
|
48
|
+
<div
|
|
49
|
+
class="custom-max-width"
|
|
50
|
+
:class="modalClass"
|
|
51
|
+
:style="'--maxw: ' + modalSize + '%;'"
|
|
52
|
+
>
|
|
53
|
+
<span
|
|
54
|
+
v-if="showClose"
|
|
55
|
+
class="absolute top-0 bottom-0 right-0 py-2 px-3 z-30 max-h-1em"
|
|
56
|
+
>
|
|
57
|
+
<button class="p-1" @click="closeModal()">
|
|
58
|
+
<span>X</span>
|
|
59
|
+
</button>
|
|
60
|
+
</span>
|
|
61
|
+
|
|
62
|
+
<slot name="modal-title" />
|
|
63
|
+
<slot name="modal-body" />
|
|
64
|
+
</div>
|
|
65
|
+
</div>
|
|
66
|
+
</Transition>
|
|
67
|
+
</template>
|
|
68
|
+
|
|
69
|
+
<style lang="scss" scoped>
|
|
70
|
+
.max-h-1em {
|
|
71
|
+
max-height: 1em;
|
|
72
|
+
}
|
|
73
|
+
.bg-smoke-light {
|
|
74
|
+
background-color: rgba(0, 0, 0, 0.4);
|
|
75
|
+
}
|
|
76
|
+
.custom-max-width {
|
|
77
|
+
@screen lg {
|
|
78
|
+
max-width: calc(var(--maxw) * 1.25);
|
|
79
|
+
}
|
|
80
|
+
@screen xl {
|
|
81
|
+
max-width: var(--maxw);
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
</style>
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
<script lang="ts" setup>
|
|
2
|
+
import { find, get } from "lodash";
|
|
3
|
+
import { defineAsyncComponent } from "vue";
|
|
4
|
+
import { Icon, Icons } from "../../models/icons";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Delay importing only the icon file that we need
|
|
8
|
+
*/
|
|
9
|
+
const icons: Icons = {
|
|
10
|
+
person: {
|
|
11
|
+
color: "#333",
|
|
12
|
+
component: defineAsyncComponent(
|
|
13
|
+
() => import("../../assets/svg/icon-person.svg")
|
|
14
|
+
),
|
|
15
|
+
},
|
|
16
|
+
info: {
|
|
17
|
+
color: "#4286f4",
|
|
18
|
+
component: defineAsyncComponent(
|
|
19
|
+
() => import("../../assets/svg/icon-info.svg")
|
|
20
|
+
),
|
|
21
|
+
},
|
|
22
|
+
twitter: {
|
|
23
|
+
color: "#1CB7EB",
|
|
24
|
+
component: defineAsyncComponent(
|
|
25
|
+
() => import("../../assets/svg/icon-twitter.svg")
|
|
26
|
+
),
|
|
27
|
+
},
|
|
28
|
+
facebook: {
|
|
29
|
+
color: "#4E71A8",
|
|
30
|
+
component: defineAsyncComponent(
|
|
31
|
+
() => import("../../assets/svg/icon-facebook.svg")
|
|
32
|
+
),
|
|
33
|
+
},
|
|
34
|
+
linkedin: {
|
|
35
|
+
color: "#4E71A8",
|
|
36
|
+
component: defineAsyncComponent(
|
|
37
|
+
() => import("../../assets/svg/icon-linkedin.svg")
|
|
38
|
+
),
|
|
39
|
+
},
|
|
40
|
+
youtube: {
|
|
41
|
+
color: "#CA3737",
|
|
42
|
+
component: defineAsyncComponent(
|
|
43
|
+
() => import("../../assets/svg/icon-youtube.svg")
|
|
44
|
+
),
|
|
45
|
+
},
|
|
46
|
+
website: {
|
|
47
|
+
color: "#4286f4",
|
|
48
|
+
component: defineAsyncComponent(
|
|
49
|
+
() => import("../../assets/svg/icon-website.svg")
|
|
50
|
+
),
|
|
51
|
+
},
|
|
52
|
+
newwindow: {
|
|
53
|
+
color: "#333",
|
|
54
|
+
component: defineAsyncComponent(
|
|
55
|
+
() => import("../../assets/svg/icon-new-window.svg")
|
|
56
|
+
),
|
|
57
|
+
},
|
|
58
|
+
playarrow: {
|
|
59
|
+
color: "#CA3737",
|
|
60
|
+
component: defineAsyncComponent(
|
|
61
|
+
() => import("../../assets/svg/icon-play.svg")
|
|
62
|
+
),
|
|
63
|
+
},
|
|
64
|
+
zoom: {
|
|
65
|
+
color: "#333",
|
|
66
|
+
component: defineAsyncComponent(
|
|
67
|
+
() => import("../../assets/svg/icon-zoom.svg")
|
|
68
|
+
),
|
|
69
|
+
},
|
|
70
|
+
downarrow: {
|
|
71
|
+
color: "#333",
|
|
72
|
+
component: defineAsyncComponent(
|
|
73
|
+
() => import("../../assets/svg/icon-down-arrow.svg")
|
|
74
|
+
),
|
|
75
|
+
},
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
type Props = {
|
|
79
|
+
icon?: keyof Icons;
|
|
80
|
+
grayScale?: boolean;
|
|
81
|
+
width?: string;
|
|
82
|
+
};
|
|
83
|
+
|
|
84
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
85
|
+
icon: "info",
|
|
86
|
+
grayScale: false,
|
|
87
|
+
width: "20px",
|
|
88
|
+
});
|
|
89
|
+
|
|
90
|
+
const { icon, grayScale, width } = toRefs(props);
|
|
91
|
+
|
|
92
|
+
// computed
|
|
93
|
+
const iconDims = computed(() => ({
|
|
94
|
+
width: width.value,
|
|
95
|
+
height: width.value,
|
|
96
|
+
}));
|
|
97
|
+
|
|
98
|
+
const iconStyle = computed(() => {
|
|
99
|
+
if (!grayScale.value) {
|
|
100
|
+
return {
|
|
101
|
+
fill: icons[icon.value].color,
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
return {
|
|
106
|
+
fill: "#666",
|
|
107
|
+
};
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
const iconComponent = computed(() => {
|
|
111
|
+
return icons[icon.value].component;
|
|
112
|
+
});
|
|
113
|
+
</script>
|
|
114
|
+
|
|
115
|
+
<template>
|
|
116
|
+
<div :style="iconDims">
|
|
117
|
+
<component :is="iconComponent" :style="iconStyle" />
|
|
118
|
+
</div>
|
|
119
|
+
</template>
|