@opendesign-plus-test/components 0.0.1-rc.158 → 0.0.1-rc.159

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.
Files changed (47) hide show
  1. package/dist/chunk-OElCookieNotice.cjs.js +1 -1
  2. package/dist/chunk-OElCookieNotice.es.js +34 -22
  3. package/dist/components/meeting/utils.d.ts +1 -1
  4. package/dist/components/summit/OSummit.vue.d.ts +7 -0
  5. package/dist/components/summit/OSummitIntro.vue.d.ts +3 -0
  6. package/dist/components/summit/OSummitLive.vue.d.ts +7 -0
  7. package/dist/components/summit/OSummitSchedule.vue.d.ts +3 -0
  8. package/dist/components/summit/components/OSummitTabs.vue.d.ts +16 -0
  9. package/dist/components/summit/index.d.ts +83 -0
  10. package/dist/components/summit/types.d.ts +69 -0
  11. package/dist/components.cjs.js +39 -39
  12. package/dist/components.css +1 -1
  13. package/dist/components.es.js +10917 -10435
  14. package/dist/index.d.ts +1 -0
  15. package/dist/treeshaking/_virtual/icon-time.mjs +20 -0
  16. package/dist/treeshaking/components/activity/OActivityApproval.vue.mjs +20 -24
  17. package/dist/treeshaking/components/meeting/OMeetingCalendar.vue.mjs +10 -2
  18. package/dist/treeshaking/components/meeting/utils.d.ts +1 -1
  19. package/dist/treeshaking/components/summit/OSummit.css +13 -0
  20. package/dist/treeshaking/components/summit/OSummit.vue.d.ts +7 -0
  21. package/dist/treeshaking/components/summit/OSummit.vue.mjs +7 -0
  22. package/dist/treeshaking/components/summit/OSummit.vue2.mjs +49 -0
  23. package/dist/treeshaking/components/summit/OSummitIntro.css +27 -0
  24. package/dist/treeshaking/components/summit/OSummitIntro.vue.d.ts +3 -0
  25. package/dist/treeshaking/components/summit/OSummitIntro.vue.mjs +7 -0
  26. package/dist/treeshaking/components/summit/OSummitIntro.vue2.mjs +26 -0
  27. package/dist/treeshaking/components/summit/OSummitLive.css +103 -0
  28. package/dist/treeshaking/components/summit/OSummitLive.vue.d.ts +7 -0
  29. package/dist/treeshaking/components/summit/OSummitLive.vue.mjs +7 -0
  30. package/dist/treeshaking/components/summit/OSummitLive.vue2.mjs +135 -0
  31. package/dist/treeshaking/components/summit/OSummitSchedule.css +187 -0
  32. package/dist/treeshaking/components/summit/OSummitSchedule.vue.d.ts +3 -0
  33. package/dist/treeshaking/components/summit/OSummitSchedule.vue.mjs +8 -0
  34. package/dist/treeshaking/components/summit/OSummitSchedule.vue2.mjs +266 -0
  35. package/dist/treeshaking/components/summit/OSummitSchedule2.css +43 -0
  36. package/dist/treeshaking/components/summit/components/OSummitTabs.css +137 -0
  37. package/dist/treeshaking/components/summit/components/OSummitTabs.vue.d.ts +16 -0
  38. package/dist/treeshaking/components/summit/components/OSummitTabs.vue.mjs +7 -0
  39. package/dist/treeshaking/components/summit/components/OSummitTabs.vue2.mjs +155 -0
  40. package/dist/treeshaking/components/summit/index.d.ts +83 -0
  41. package/dist/treeshaking/components/summit/index.mjs +30 -0
  42. package/dist/treeshaking/components/summit/types.d.ts +69 -0
  43. package/dist/treeshaking/i18n/en.mjs +7 -1
  44. package/dist/treeshaking/i18n/zh.mjs +7 -1
  45. package/dist/treeshaking/index.d.ts +1 -0
  46. package/dist/treeshaking/index.mjs +5 -0
  47. package/package.json +1 -1
@@ -0,0 +1,155 @@
1
+ import { defineComponent, ref, watch, nextTick, onMounted, openBlock, createElementBlock, normalizeClass, withDirectives, createElementVNode, createVNode, unref, withCtx, vShow, Fragment, renderList, toDisplayString, createCommentVNode } from "vue";
2
+ import { OIcon, OIconChevronLeft, OIconChevronRight } from "@opensig/opendesign";
3
+ import { useResizeObserver } from "@vueuse/core";
4
+ const _hoisted_1 = ["tabindex", "aria-disabled"];
5
+ const _hoisted_2 = ["onClick"];
6
+ const _hoisted_3 = ["tabindex", "aria-disabled"];
7
+ const _hoisted_4 = {
8
+ key: 1,
9
+ class: "o-summit-tabs-single"
10
+ };
11
+ const SCROLL_STEP = 3;
12
+ const _sfc_main = /* @__PURE__ */ defineComponent({
13
+ __name: "OSummitTabs",
14
+ props: {
15
+ modelValue: {},
16
+ items: {},
17
+ disabled: {}
18
+ },
19
+ emits: ["update:modelValue", "change"],
20
+ setup(__props, { emit: __emit }) {
21
+ const props = __props;
22
+ const emit = __emit;
23
+ const select = (idx) => {
24
+ emit("update:modelValue", idx);
25
+ emit("change", idx);
26
+ };
27
+ const scrollRef = ref(null);
28
+ const trackRef = ref(null);
29
+ const canScrollLeft = ref(false);
30
+ const canScrollRight = ref(false);
31
+ const isOverflowing = ref(false);
32
+ const updateArrows = () => {
33
+ const sc = scrollRef.value;
34
+ if (!sc) return;
35
+ const overflow = sc.scrollWidth - sc.clientWidth;
36
+ isOverflowing.value = overflow > 1;
37
+ canScrollLeft.value = sc.scrollLeft > 1;
38
+ canScrollRight.value = sc.scrollLeft < overflow - 1;
39
+ };
40
+ const firstVisibleIndex = () => {
41
+ const sc = scrollRef.value;
42
+ const track = trackRef.value;
43
+ if (!sc || !track) return 0;
44
+ const scLeft = sc.getBoundingClientRect().left;
45
+ const tabs = track.children;
46
+ for (let i = 0; i < tabs.length; i++) {
47
+ const el = tabs[i];
48
+ if (el.getBoundingClientRect().right > scLeft + 1) {
49
+ return i;
50
+ }
51
+ }
52
+ return 0;
53
+ };
54
+ const scrollTabs = (direction) => {
55
+ const sc = scrollRef.value;
56
+ const track = trackRef.value;
57
+ if (!sc || !track) return;
58
+ if (direction === -1 && !canScrollLeft.value) return;
59
+ if (direction === 1 && !canScrollRight.value) return;
60
+ const idx = firstVisibleIndex();
61
+ let target = idx + direction * SCROLL_STEP;
62
+ target = Math.max(0, Math.min(target, track.children.length - 1));
63
+ const targetEl = track.children[target];
64
+ if (targetEl) {
65
+ const delta = targetEl.getBoundingClientRect().left - sc.getBoundingClientRect().left;
66
+ sc.scrollTo({
67
+ left: sc.scrollLeft + delta,
68
+ behavior: "smooth"
69
+ });
70
+ }
71
+ };
72
+ useResizeObserver(scrollRef, updateArrows);
73
+ useResizeObserver(trackRef, updateArrows);
74
+ watch(
75
+ () => props.items.join("\0"),
76
+ () => {
77
+ nextTick(() => {
78
+ if (scrollRef.value) {
79
+ scrollRef.value.scrollTo({ left: 0 });
80
+ }
81
+ updateArrows();
82
+ });
83
+ }
84
+ );
85
+ onMounted(() => {
86
+ updateArrows();
87
+ });
88
+ return (_ctx, _cache) => {
89
+ return __props.items.length > 1 ? (openBlock(), createElementBlock("div", {
90
+ key: 0,
91
+ class: normalizeClass(["o-summit-tabs", { "is-overflowing": isOverflowing.value }])
92
+ }, [
93
+ withDirectives(createElementVNode("button", {
94
+ type: "button",
95
+ class: normalizeClass(["o-summit-tabs-arrow is-left", { "is-disabled": !canScrollLeft.value }]),
96
+ tabindex: canScrollLeft.value ? 0 : -1,
97
+ "aria-disabled": !canScrollLeft.value,
98
+ onClick: _cache[0] || (_cache[0] = ($event) => scrollTabs(-1))
99
+ }, [
100
+ createVNode(unref(OIcon), null, {
101
+ default: withCtx(() => [
102
+ createVNode(unref(OIconChevronLeft))
103
+ ]),
104
+ _: 1
105
+ })
106
+ ], 10, _hoisted_1), [
107
+ [vShow, isOverflowing.value]
108
+ ]),
109
+ createElementVNode("div", {
110
+ ref_key: "scrollRef",
111
+ ref: scrollRef,
112
+ class: "o-summit-tabs-scroller",
113
+ onScroll: updateArrows
114
+ }, [
115
+ createElementVNode("div", {
116
+ ref_key: "trackRef",
117
+ ref: trackRef,
118
+ class: "o-summit-tabs-track"
119
+ }, [
120
+ (openBlock(true), createElementBlock(Fragment, null, renderList(__props.items, (label, idx) => {
121
+ var _a;
122
+ return openBlock(), createElementBlock("button", {
123
+ key: idx,
124
+ class: normalizeClass(["o-summit-tab", {
125
+ "is-active": __props.modelValue === idx,
126
+ "is-disabled": (_a = __props.disabled) == null ? void 0 : _a.includes(idx)
127
+ }]),
128
+ onClick: ($event) => select(idx)
129
+ }, toDisplayString(label), 11, _hoisted_2);
130
+ }), 128))
131
+ ], 512)
132
+ ], 544),
133
+ withDirectives(createElementVNode("button", {
134
+ type: "button",
135
+ class: normalizeClass(["o-summit-tabs-arrow is-right", { "is-disabled": !canScrollRight.value }]),
136
+ tabindex: canScrollRight.value ? 0 : -1,
137
+ "aria-disabled": !canScrollRight.value,
138
+ onClick: _cache[1] || (_cache[1] = ($event) => scrollTabs(1))
139
+ }, [
140
+ createVNode(unref(OIcon), null, {
141
+ default: withCtx(() => [
142
+ createVNode(unref(OIconChevronRight))
143
+ ]),
144
+ _: 1
145
+ })
146
+ ], 10, _hoisted_3), [
147
+ [vShow, isOverflowing.value]
148
+ ])
149
+ ], 2)) : __props.items.length === 1 ? (openBlock(), createElementBlock("h4", _hoisted_4, toDisplayString(__props.items[0]), 1)) : createCommentVNode("", true);
150
+ };
151
+ }
152
+ });
153
+ export {
154
+ _sfc_main as default
155
+ };
@@ -0,0 +1,83 @@
1
+ import { App } from 'vue';
2
+ declare const OSummit: {
3
+ new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('./types').SummitPropsT> & Readonly<{
4
+ onLiveChange?: ((liveId: string | number) => any) | undefined;
5
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
6
+ liveChange: (liveId: string | number) => any;
7
+ }, import('vue').PublicProps, {}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, HTMLDivElement, import('vue').ComponentProvideOptions, {
8
+ P: {};
9
+ B: {};
10
+ D: {};
11
+ C: {};
12
+ M: {};
13
+ Defaults: {};
14
+ }, Readonly<import('./types').SummitPropsT> & Readonly<{
15
+ onLiveChange?: ((liveId: string | number) => any) | undefined;
16
+ }>, {}, {}, {}, {}, {}>;
17
+ __isFragment?: never;
18
+ __isTeleport?: never;
19
+ __isSuspense?: never;
20
+ } & import('vue').ComponentOptionsBase<Readonly<import('./types').SummitPropsT> & Readonly<{
21
+ onLiveChange?: ((liveId: string | number) => any) | undefined;
22
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
23
+ liveChange: (liveId: string | number) => any;
24
+ }, string, {}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & {
25
+ install(app: App): void;
26
+ };
27
+ declare const OSummitIntro: {
28
+ new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('./types').SummitIntroPropsT> & Readonly<{}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, import('vue').PublicProps, {}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, HTMLDivElement, import('vue').ComponentProvideOptions, {
29
+ P: {};
30
+ B: {};
31
+ D: {};
32
+ C: {};
33
+ M: {};
34
+ Defaults: {};
35
+ }, Readonly<import('./types').SummitIntroPropsT> & Readonly<{}>, {}, {}, {}, {}, {}>;
36
+ __isFragment?: never;
37
+ __isTeleport?: never;
38
+ __isSuspense?: never;
39
+ } & import('vue').ComponentOptionsBase<Readonly<import('./types').SummitIntroPropsT> & Readonly<{}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, {}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & {
40
+ install(app: App): void;
41
+ };
42
+ declare const OSummitLive: {
43
+ new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('./types').SummitLivePropsT> & Readonly<{
44
+ onChange?: ((liveId: string | number) => any) | undefined;
45
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
46
+ change: (liveId: string | number) => any;
47
+ }, import('vue').PublicProps, {}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, HTMLDivElement, import('vue').ComponentProvideOptions, {
48
+ P: {};
49
+ B: {};
50
+ D: {};
51
+ C: {};
52
+ M: {};
53
+ Defaults: {};
54
+ }, Readonly<import('./types').SummitLivePropsT> & Readonly<{
55
+ onChange?: ((liveId: string | number) => any) | undefined;
56
+ }>, {}, {}, {}, {}, {}>;
57
+ __isFragment?: never;
58
+ __isTeleport?: never;
59
+ __isSuspense?: never;
60
+ } & import('vue').ComponentOptionsBase<Readonly<import('./types').SummitLivePropsT> & Readonly<{
61
+ onChange?: ((liveId: string | number) => any) | undefined;
62
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
63
+ change: (liveId: string | number) => any;
64
+ }, string, {}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & {
65
+ install(app: App): void;
66
+ };
67
+ declare const OSummitSchedule: {
68
+ new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('./types').SummitSchedulePropsT> & Readonly<{}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, import('vue').PublicProps, {}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, HTMLDivElement, import('vue').ComponentProvideOptions, {
69
+ P: {};
70
+ B: {};
71
+ D: {};
72
+ C: {};
73
+ M: {};
74
+ Defaults: {};
75
+ }, Readonly<import('./types').SummitSchedulePropsT> & Readonly<{}>, {}, {}, {}, {}, {}>;
76
+ __isFragment?: never;
77
+ __isTeleport?: never;
78
+ __isSuspense?: never;
79
+ } & import('vue').ComponentOptionsBase<Readonly<import('./types').SummitSchedulePropsT> & Readonly<{}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, {}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & {
80
+ install(app: App): void;
81
+ };
82
+ export { OSummit, OSummitIntro, OSummitLive, OSummitSchedule, };
83
+ export * from './types';
@@ -0,0 +1,30 @@
1
+ import _OSummit from "./OSummit.vue.mjs";
2
+ import _OSummitIntro from "./OSummitIntro.vue.mjs";
3
+ import _OSummitLive from "./OSummitLive.vue.mjs";
4
+ import _OSummitSchedule from "./OSummitSchedule.vue.mjs";
5
+ const OSummit = Object.assign(_OSummit, {
6
+ install(app) {
7
+ app.component("OSummit", _OSummit);
8
+ }
9
+ });
10
+ const OSummitIntro = Object.assign(_OSummitIntro, {
11
+ install(app) {
12
+ app.component("OSummitIntro", _OSummitIntro);
13
+ }
14
+ });
15
+ const OSummitLive = Object.assign(_OSummitLive, {
16
+ install(app) {
17
+ app.component("OSummitLive", _OSummitLive);
18
+ }
19
+ });
20
+ const OSummitSchedule = Object.assign(_OSummitSchedule, {
21
+ install(app) {
22
+ app.component("OSummitSchedule", _OSummitSchedule);
23
+ }
24
+ });
25
+ export {
26
+ OSummit,
27
+ OSummitIntro,
28
+ OSummitLive,
29
+ OSummitSchedule
30
+ };
@@ -0,0 +1,69 @@
1
+ export interface SummitIntroPropsT {
2
+ title?: string;
3
+ descList: string[];
4
+ }
5
+ export interface SummitLiveRoomT {
6
+ id: number | string;
7
+ liveId: number | string;
8
+ name: string;
9
+ background?: string;
10
+ backgroundDark?: string;
11
+ }
12
+ export interface SummitLivePropsT {
13
+ section: SummitLiveSectionT;
14
+ liveUrl: string;
15
+ }
16
+ export interface SummitSpeakerT {
17
+ name: string;
18
+ positions: string[];
19
+ }
20
+ export interface SummitScheduleTopicT {
21
+ topic: string | string[];
22
+ speakers?: SummitSpeakerT[];
23
+ description?: string;
24
+ }
25
+ export interface SummitScheduleEntryT {
26
+ time: string;
27
+ topics: SummitScheduleTopicT[];
28
+ }
29
+ export interface SummitSchedulePropsT {
30
+ schedule: SummitScheduleT;
31
+ }
32
+ export interface SummitLiveSectionT {
33
+ title?: string;
34
+ dates?: string[];
35
+ rooms?: SummitLiveRoomT[][];
36
+ }
37
+ export interface SummitSubForumT {
38
+ id: number | string;
39
+ name: string;
40
+ detailMode?: 'popover';
41
+ items: SummitScheduleEntryT[];
42
+ }
43
+ export interface SummitSessionT {
44
+ id: string;
45
+ label: string;
46
+ duration?: string;
47
+ items?: SummitScheduleEntryT[];
48
+ subForums?: SummitSubForumT[];
49
+ }
50
+ export interface SummitCategoryT {
51
+ id: string;
52
+ name: string;
53
+ sessions: SummitSessionT[];
54
+ }
55
+ export interface SummitScheduleDayT {
56
+ dateLabel: string;
57
+ categories: SummitCategoryT[];
58
+ }
59
+ export interface SummitScheduleT {
60
+ title?: string;
61
+ days: SummitScheduleDayT[];
62
+ }
63
+ export interface SummitPropsT {
64
+ descList?: string[];
65
+ descTitle?: string;
66
+ live?: SummitLiveSectionT;
67
+ liveUrl?: string;
68
+ schedule?: SummitScheduleT;
69
+ }
@@ -405,7 +405,13 @@ const en = {
405
405
  "meeting.sendMinutesEmailExists": "该收件人已存在",
406
406
  "meeting.sendMinutesEmptyRecipient": "请至少保留一个收件人",
407
407
  "meeting.sendMinutesSent": "会议纪要已发送",
408
- "meeting.sendMinutesSubjectDefault": "[会议纪要] {0} ({1})"
408
+ "meeting.sendMinutesSubjectDefault": "[会议纪要] {0} ({1})",
409
+ // -------------------- 峰会(英文占位:暂用中文原文,等翻译) --------------------
410
+ "summit.introTitle": "大会简介",
411
+ "summit.scheduleTopicName": "议题名称:",
412
+ "summit.scheduleTopicDesc": "议题简介:",
413
+ "summit.scheduleSpeaker": "姓名:",
414
+ "summit.schedulePosition": "职位:"
409
415
  };
410
416
  export {
411
417
  en as default
@@ -408,7 +408,13 @@ const zh = {
408
408
  "meeting.sendMinutesEmailExists": "该收件人已存在",
409
409
  "meeting.sendMinutesEmptyRecipient": "请至少保留一个收件人",
410
410
  "meeting.sendMinutesSent": "会议纪要已发送",
411
- "meeting.sendMinutesSubjectDefault": "[会议纪要] {0} ({1})"
411
+ "meeting.sendMinutesSubjectDefault": "[会议纪要] {0} ({1})",
412
+ // -------------------- 峰会 --------------------
413
+ "summit.introTitle": "大会简介",
414
+ "summit.scheduleTopicName": "议题名称:",
415
+ "summit.scheduleTopicDesc": "议题简介:",
416
+ "summit.scheduleSpeaker": "姓名:",
417
+ "summit.schedulePosition": "职位:"
412
418
  };
413
419
  export {
414
420
  zh as default
@@ -20,4 +20,5 @@ export * from './components/meeting';
20
20
  export * from './components/search';
21
21
  export * from './components/section';
22
22
  export * from './components/sig';
23
+ export * from './components/summit';
23
24
  export * from './components/video';
@@ -19,6 +19,7 @@ import { OMeetingCalendar, OMeetingForm, OMeetingMinutes, OMeetingMyCalendar, OM
19
19
  import { OSearchInput } from "./components/search/index.mjs";
20
20
  import { OSection } from "./components/section/index.mjs";
21
21
  import { OSigDetail, OSigList } from "./components/sig/index.mjs";
22
+ import { OSummit, OSummitIntro, OSummitLive, OSummitSchedule } from "./components/summit/index.mjs";
22
23
  import { OVideoDetail } from "./components/video/index.mjs";
23
24
  import { CalendarDataType, MeetingGroupType } from "./components/meeting/types.mjs";
24
25
  import { EventsStatusT } from "./components/events/types.mjs";
@@ -66,6 +67,10 @@ export {
66
67
  OSection,
67
68
  OSigDetail,
68
69
  OSigList,
70
+ OSummit,
71
+ OSummitIntro,
72
+ OSummitLive,
73
+ OSummitSchedule,
69
74
  OVideoDetail,
70
75
  createSvgIcon
71
76
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opendesign-plus-test/components",
3
- "version": "0.0.1-rc.158",
3
+ "version": "0.0.1-rc.159",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "public",