@icvdeveloper/common-module 0.0.74 → 0.0.76

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/module.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "v3plus-common-module",
3
3
  "configKey": "v3plusCommonModule",
4
- "version": "0.0.74"
4
+ "version": "0.0.76"
5
5
  }
@@ -8,6 +8,7 @@ import { useDateFormat } from "../../composables/useDateFormat";
8
8
  import { usePresenter } from "../../composables/usePresenter";
9
9
  import { Presenter } from "../../models/conference";
10
10
  import AgendaAccordion from "./components/AgendaListAccordion.vue";
11
+ import Calendar from "./components/Calendar.vue";
11
12
 
12
13
  type Props = {
13
14
  conference: Conference;
@@ -77,6 +78,13 @@ const presentersToComposables = (presenters: Presenter[]) => {
77
78
  <span class="text-lg hidden md:block md:flex-initial time-width md:mr-8" />
78
79
 
79
80
  <div class="flex-1 my-3">
81
+ <!-- ADD TO CALENDAR -->
82
+ <calendar
83
+ :key="conference.id"
84
+ class="mb-3"
85
+ :presentation="presentation"
86
+ :conference="conference"
87
+ />
80
88
  <h3 class="font-bold text-lg">Presenters</h3>
81
89
  <div class="flex flex-col space-y-3">
82
90
  <div
@@ -9,6 +9,7 @@ import { usePresenters } from "../../composables/usePresenters";
9
9
  import CommonAccordion from "../layouts/Accordion.vue";
10
10
  import Sponsor from "./components/Sponsor.vue";
11
11
  import PresentationLink from "./components/PresentationLink.vue";
12
+ import Calendar from "./components/Calendar.vue";
12
13
 
13
14
  type Props = {
14
15
  conference: Conference;
@@ -246,6 +247,14 @@ const presentersContainer = computed(() => {
246
247
  ></presentation-link>
247
248
  </div>
248
249
 
250
+ <!-- ADD TO CALENDAR -->
251
+ <calendar
252
+ :key="conference.id"
253
+ class="mb-3"
254
+ :presentation="presentation"
255
+ :conference="conference"
256
+ />
257
+
249
258
  <!-- PRESENTERS LIST (ACCORDION OR STANDARD/DIV) -->
250
259
  <component
251
260
  :is="presentersContainer"
@@ -0,0 +1,89 @@
1
+ <script lang="ts" setup>
2
+ import { ref, toRefs, computed } from "vue";
3
+ import { storeToRefs } from "pinia";
4
+ import { get } from "lodash-es";
5
+ import { DateTime } from 'luxon';
6
+ import { useTemplateConfigsStore } from "../../../store";
7
+ import 'add-to-calendar-button';
8
+ import { Conference } from "../../../models/conference";
9
+ import { Presentation } from "../../../models/conference";
10
+
11
+ type Props = {
12
+ conference: Conference;
13
+ presentation: Presentation;
14
+ };
15
+
16
+ const props = defineProps<Props>();
17
+
18
+ const { conference, presentation } = toRefs(props);
19
+
20
+ const { pagesConfigValue } = storeToRefs(useTemplateConfigsStore());
21
+
22
+ // Computed
23
+ const showAddToGoogleCalendar = computed((): boolean => {
24
+ return pagesConfigValue.value("agenda.add_to_google_calendar", false);
25
+ });
26
+
27
+ const showAddToMicrosoftCalendar = computed((): boolean => {
28
+ return pagesConfigValue.value("agenda.add_to_microsoft_calendar", false);
29
+ });
30
+
31
+ const presStartDate = computed((): string => {
32
+ return DateTime.fromSQL(
33
+ presentation.value.date,
34
+ { zone: conference.timezone }
35
+ ).toFormat("yyyy-MM-dd");
36
+ });
37
+
38
+ const presStartTime = computed((): string => {
39
+ return DateTime.fromSQL(
40
+ presentation.value.date,
41
+ { zone: conference.timezone }
42
+ ).toFormat("HH:mm");
43
+ });
44
+
45
+ const presEndTime = computed((): string => {
46
+ let duration: number = get(presentation.value, "duration", 3600) // default to 60 min
47
+ return DateTime.fromSQL(
48
+ presentation.value.date,
49
+ { zone: conference.timezone }
50
+ ).plus(duration * 1000).toFormat("HH:mm");
51
+ });
52
+
53
+ const calendarOptions = computed((): string => {
54
+ let opts = [];
55
+ if (showAddToGoogleCalendar) { opts.push('Google'); }
56
+ if (showAddToMicrosoftCalendar) { opts.push('iCal'); }
57
+ let optsQuoted = opts.map(opt => `'${opt}'`);
58
+ return optsQuoted.join(',');
59
+ });
60
+
61
+ const cssPath = computed((): string => {
62
+ // atcb.css required in template/playground public folder
63
+ return window.location.origin + "/atcb.css";
64
+ });
65
+
66
+ </script>
67
+
68
+ <template>
69
+ <div>
70
+ <add-to-calendar-button
71
+ :name="presentation.name"
72
+ :description="presentation.description"
73
+ :startDate="presStartDate"
74
+ :startTime="presStartTime"
75
+ :endTime="presEndTime"
76
+ :timeZone="conference.timezone"
77
+ :location="conference.location"
78
+ listStyle="dropdown"
79
+ trigger="click"
80
+ lightMode="bodyScheme"
81
+ buttonStyle="custom"
82
+ :customCss="cssPath"
83
+ hideIconButton
84
+ hideBackground
85
+ hideCheckmark
86
+ :options="calendarOptions"
87
+ ></add-to-calendar-button>
88
+ </div>
89
+ </template>
@@ -9,6 +9,7 @@ import { useClassBinding } from "../../composables/useClassBinding";
9
9
 
10
10
  interface Props {
11
11
  streamTestEnabled?: boolean;
12
+ showSupport?: boolean;
12
13
  showForm?: boolean;
13
14
  liveSupportUrl?: string;
14
15
  questionArray?: Array<{ q: string; a: string }>;
@@ -17,12 +18,13 @@ interface Props {
17
18
 
18
19
  const props = withDefaults(defineProps<Props>(), {
19
20
  streamTestEnabled: false,
21
+ showSupport: true,
20
22
  showForm: true,
21
23
  liveSupportUrl: "",
22
24
  questionArray: () => [
23
25
  {
24
26
  q: "<span class='font-bold'>Q: Have you run the pre-event streaming test?</span>",
25
- a: "<p>The most important step is to visit our <a href='/stream-test'>Pre-Event Test Stream</a> using the computer or device you will use for the live web event, and connecting with the same network connection you will use for the live web event. We begin webcasting a pre-event test stream one week prior to the event.</p><p> If you can see video, hear the sound, and see the test slide, you will most likely be ready for the web event.</p>",
27
+ a: "<p>The most important step is to visit our <a href='/stream-test'>Pre-Event Test Stream</a> using the computer or device you will use for the live web event, and connecting with the same network connection you will use for the live web event. We begin webcasting a pre-event test stream one week prior to the event.</p><p> If you can see video, and hear the audio, you will most likely be ready for the web event.</p>",
26
28
  },
27
29
  {
28
30
  q: "<span class='font-bold'>Q: What are the browser requirements?</span>",
@@ -38,11 +40,11 @@ const props = withDefaults(defineProps<Props>(), {
38
40
  },
39
41
  {
40
42
  q: "<span class='font-bold'>Q: Why is my video completely black (or displaying an error)?</span>",
41
- a: "<p>If your webcast does not start playing even after trying the abovefixes, the stream may have gone down due to technical issues at thelocation or out on the internet between the location of the event andyour computer. If this is the case, everyone else watching the streamwill be having the same issues as you. Send a message to tech supportusing the 'Support' link at the top of the player page. If you do notreceive a response within a few minutes, it is likely that the streamis down for everyone and that we are working on getting it back up.</,p>",
43
+ a: "<p>If your webcast does not start playing even after trying the above fixes, the stream may have gone down due to technical issues at thelocation or out on the internet between the location of the event and your computer. If this is the case, everyone else watching the streamwill be having the same issues as you. Send a message to tech supportusing the 'Support' link at the top of the player page. If you do not receive a response within a few minutes, it is likely that the stream is down for everyone and that we are working on getting it back up.</p>",
42
44
  },
43
45
  {
44
46
  q: "<span class='font-bold'>Q: Can I view the live stream on a mobile device?</span>",
45
- a: "<p>You can view the webcast from a mobile device, such as a cell phone,iPad, or tablet. We recommend that you be somewhere where there isfast, reliable WiFi or a strong data connection in order to avoid anyinterruptions. There are many versions of mobile operating systems onthe market today. We strive to make video playable on all devices,however while we try to create a universally playable stream, someolder devices may not be compatible.</p><p>Also, mobile bandwidth can fluctuate extensively from location tolocation. Because this is a live streaming protocol, a consistentsustained data rate is required for the stream to play properly.Unlike video on YouTube and other services, that will progressivelydownload the video, live video is constant, and if bandwidthfluctuates below a minimum data rate, even for a couple of seconds,the stream could be interrupted.</p>",
47
+ a: "<p>You can view the webcast from a mobile device, such as a cell phone, iPad, or tablet. We recommend that you be somewhere where there is fast, reliable WiFi or a strong data connection in order to avoid any interruptions. There are many versions of mobile operating systems onthe market today. We strive to make video playable on all devices, however while we try to create a universally playable stream, some older devices may not be compatible.</p><p>Also, mobile bandwidth can fluctuate extensively from location tolocation. Because this is a live streaming protocol, a consistent sustained data rate is required for the stream to play properly. Unlike video on YouTube and other services, that will progressively download the video, live video is constant, and if bandwidth fluctuates below a minimum data rate, even for a couple of seconds, the stream could be interrupted.</p>",
46
48
  },
47
49
  ],
48
50
  classObject: () => {
@@ -103,6 +105,7 @@ const { classBinding } = useClassBinding();
103
105
  </CommonAccordion>
104
106
  </template>
105
107
  <CommonAccordion
108
+ v-if="showSupport"
106
109
  :class="classBinding(classObject.components?.accordion, 'container', '')"
107
110
  :class-object="classObject.components.accordion"
108
111
  >
@@ -41,6 +41,8 @@ export type AgendaPlayerPageConfigs = {
41
41
  use_accordion: ToggleVariable;
42
42
  use_presenter_modal: ToggleVariable;
43
43
  sponsors: ToggleVariable;
44
+ add_to_google_calendar: ToggleVariable;
45
+ add_to_microsoft_calendar: ToggleVariable;
44
46
  group_tracks: SelectVariable;
45
47
  use_zoom_icon: ToggleVariable;
46
48
  use_play_icon: ToggleVariable;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@icvdeveloper/common-module",
3
- "version": "0.0.74",
3
+ "version": "0.0.76",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "exports": {
@@ -26,10 +26,12 @@
26
26
  "@nuxt/kit": "^3.0.0",
27
27
  "@nuxtjs/tailwindcss": "^6.1.3",
28
28
  "@pinia/nuxt": "^0.3.1",
29
+ "add-to-calendar-button": "^2.1.1",
29
30
  "analytics": "^0.8.1",
30
31
  "date-fns": "^2.29.1",
31
32
  "date-fns-tz": "^1.3.6",
32
33
  "lodash-es": "^4.17.21",
34
+ "luxon": "^3.2.1",
33
35
  "nprogress": "^0.2.0",
34
36
  "pinia": "^2.0.17",
35
37
  "pinia-plugin-persistedstate": "^2.1.1",