@opendesign-plus-test/components 0.0.1-rc.69 → 0.0.1-rc.71

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opendesign-plus-test/components",
3
- "version": "0.0.1-rc.69",
3
+ "version": "0.0.1-rc.71",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "public",
Binary file
@@ -29,6 +29,10 @@ const props = defineProps({
29
29
  type: Boolean,
30
30
  default: true,
31
31
  },
32
+ disabled: {
33
+ type: Boolean,
34
+ default: false,
35
+ },
32
36
  });
33
37
 
34
38
  const { changeLocale, locale } = useLocale();
@@ -66,12 +70,15 @@ const isCommon = computed(() => {
66
70
  <template>
67
71
  <div
68
72
  v-if="isCommon"
69
- :class="options.length <= 1 ? 'hide-lang' : 'header-lang'"
73
+ :class="[options.length <= 1 ? 'hide-lang' : 'header-lang', disabled ? 'is-disabled' : '']"
70
74
  >
71
75
  <ODropdown
72
76
  trigger="hover"
73
77
  optionPosition="bottom"
74
- option-wrap-class="dropdown"
78
+ :optionWrapClass="{
79
+ 'dropdown':true,
80
+ 'is-disabled': disabled,
81
+ }"
75
82
  >
76
83
  <div class="info-wrap">
77
84
  <OIcon class="icon">
@@ -95,7 +102,7 @@ const isCommon = computed(() => {
95
102
 
96
103
  <div
97
104
  v-else
98
- :class="options.length <= 1 ? 'hide-lang' : 'mobile-change-language'"
105
+ :class="[options.length <= 1 ? 'hide-lang' : 'mobile-change-language', disabled ? 'is-disabled' : '']"
99
106
  >
100
107
  <span
101
108
  v-for="item in options"
@@ -150,6 +157,21 @@ const isCommon = computed(() => {
150
157
  }
151
158
  }
152
159
  }
160
+
161
+ &.is-disabled {
162
+ .info-wrap {
163
+ color: var(--o-color-info4);
164
+ cursor: not-allowed;
165
+
166
+ &:hover {
167
+ color: var(--o-color-info4);
168
+ }
169
+
170
+ .o-icon {
171
+ color: inherit;
172
+ }
173
+ }
174
+ }
153
175
  .list {
154
176
  background: var(--o-color-fill2);
155
177
  cursor: pointer;
@@ -207,5 +229,25 @@ const isCommon = computed(() => {
207
229
  }
208
230
  }
209
231
  }
232
+
233
+ &.is-disabled {
234
+ span {
235
+ color: var(--o-color-info4);
236
+ cursor: not-allowed;
237
+ @include hover {
238
+ color: var(--o-color-info4);
239
+ }
240
+
241
+ &:after {
242
+ color: inherit;
243
+ }
244
+ }
245
+ }
246
+ }
247
+ </style>
248
+
249
+ <style lang="scss">
250
+ .o-dropdown-list.is-disabled {
251
+ display: none;
210
252
  }
211
253
  </style>
@@ -1,7 +1,8 @@
1
1
  <script setup lang="ts">
2
2
  import { computed, nextTick, onMounted, ref, watch } from 'vue';
3
3
  import {
4
- isClient, OFigure,
4
+ isClient,
5
+ OFigure,
5
6
  OIcon,
6
7
  OIconChevronLeft,
7
8
  OIconChevronRight,
@@ -17,7 +18,7 @@ import OMeetingCalendarList from './components/OMeetingCalendarList.vue';
17
18
  import IconEvent from '~icons/meeting/icon-event.svg';
18
19
  import IconSummit from '~icons/meeting/icon-summit.svg';
19
20
  import IconMeeting from '~icons/meeting/icon-meet.svg';
20
- import emptyImg from '@/assets/meeting/svg-icons/icon-empty.svg';
21
+ import emptyDefaultImg from '@/assets/meeting/empty.png';
21
22
  import { Locales } from '@/i18n';
22
23
  import { useMeetingConfig } from './composables/useMeetingConfig';
23
24
  import {
@@ -42,13 +43,11 @@ const props = withDefaults(defineProps<MeetingCalendarPropsT>(), {
42
43
  const { t, locale, meetingTabs, getConfig } = useMeetingConfig();
43
44
  const isEn = computed(() => locale.value === Locales.EN);
44
45
 
45
- const latestDay = ref<string>('');
46
46
  const dateList = ref<string[]>([]);
47
47
  const summitData = ref<SummitItemT[]>([]);
48
48
  const summitDates = ref<string[]>([]);
49
49
  const eventsData = ref<MeetingEventsItemT[]>([]);
50
50
  const eventsDates = ref<string[]>([]);
51
- const allDates = ref<string[]>([]);
52
51
  const meetingData = ref<MeetingItemT[]>([]);
53
52
  const limitTime = '2021-01-01';
54
53
  const tabType = ref<CalendarDataType>(CalendarDataType.ALL);
@@ -168,25 +167,28 @@ const getDateData = async (day?: string) => {
168
167
  getActivityData(date);
169
168
  getDateList(date);
170
169
 
171
- allDates.value = [...new Set([...dateList.value, ...summitDates.value, ...eventsDates.value])]
172
- .flat()
173
- .sort((a: string, b: string) => dayjs(a).isAfter(dayjs(b)) ? 1 : -1);
174
- if (!day) {
175
- if (!allDates.value.length) {
176
- latestDay.value = formatDate(new Date());
177
- } else {
178
- let find = [...allDates.value].reverse().find((v) => dayjs().isAfter(dayjs(v)));
179
- if (!find) {
180
- find = allDates.value.find((v) => dayjs(v).isAfter(dayjs()));
181
- }
182
- latestDay.value = formatDate(find);
183
- }
184
- }
185
170
  paramGetDaysData({
186
171
  date: date,
187
172
  type: tabType.value,
188
173
  });
189
174
  };
175
+ const allDates = computed<string[]>(() => {
176
+ return [...new Set([...dateList.value, ...summitDates.value, ...eventsDates.value])]
177
+ .flat()
178
+ .sort((a: string, b: string) => dayjs(a).isAfter(dayjs(b)) ? 1 : -1);
179
+ });
180
+
181
+ const latestDay = computed(() => {
182
+ if (!allDates.value.length) {
183
+ return formatDate(new Date());
184
+ } else {
185
+ let find = allDates.value.find((v) => dayjs(v).isAfter(dayjs()));
186
+ if (!find) {
187
+ find = [...allDates.value].reverse().find((v) => dayjs().isAfter(dayjs(v)));
188
+ }
189
+ return formatDate(find);
190
+ }
191
+ });
190
192
 
191
193
  const changeMeetingDay = useDebounceFn((day: string, event?: Event) => {
192
194
  if (isAutoClick.value) {
@@ -403,9 +405,9 @@ defineExpose({
403
405
  <slot name="empty">
404
406
  <OResult class="empty-result">
405
407
  <template #image>
406
- <OFigure class="img" :src="emptyImg" />
408
+ <OFigure class="img" :src="emptyImg ?? emptyDefaultImg" />
407
409
  </template>
408
- <template #description>{{ t('meeting.meetingEmptyText') }}</template>
410
+ <template #description>{{ emptyText ?? t('meeting.meetingEmptyText') }}</template>
409
411
  </OResult>
410
412
  </slot>
411
413
  </template>
@@ -459,7 +461,7 @@ defineExpose({
459
461
  display: flex;
460
462
  align-items: center;
461
463
  justify-content: space-between;
462
- height: 60px;
464
+ height: 58px;
463
465
  padding: 0 var(--o-gap-6);
464
466
  gap: var(--o-gap-6);
465
467
  border-bottom: 1px solid var(--o-color-control4);
@@ -809,24 +811,22 @@ defineExpose({
809
811
  }
810
812
 
811
813
  .title-list {
812
- display: flex;
813
- align-items: center;
814
- justify-content: center;
815
- padding: 14px 24px;
814
+ padding: 16px 0;
816
815
  position: relative;
817
- height: 60px;
816
+ height: 58px;
818
817
 
819
818
  @include respond('<=pad_v') {
820
819
  justify-content: space-between;
821
820
  padding: 0 16px;
822
- gap: 24px;
821
+ gap: var(--o-gap-4);
823
822
  height: auto;
824
823
  align-items: flex-start;
824
+ display: flex;
825
825
  }
826
826
  @include respond('phone') {
827
827
  flex-direction: column;
828
828
  align-items: center;
829
- gap: 8px;
829
+ gap: var(--o-gap-2);
830
830
  }
831
831
 
832
832
  &::after {
@@ -845,6 +845,9 @@ defineExpose({
845
845
  @include respond('<=pad_v') {
846
846
  display: inline-flex;
847
847
  }
848
+ @include respond('pad_v') {
849
+ max-width: 160px;
850
+ }
848
851
  @include respond('phone') {
849
852
  display: flex;
850
853
  width: 100%;
@@ -856,38 +859,30 @@ defineExpose({
856
859
  }
857
860
 
858
861
  .o-tab {
859
- display: flex;
860
- justify-content: center;
861
- align-items: flex-end;
862
- height: 60px;
862
+ --tab-nav-padding: 0 0 16px;
863
+ @include respond('laptop') {
864
+ --tab-nav-padding: 0 0 18px;
865
+ }
863
866
  @include respond('pad_h') {
864
867
  --tab-nav-gap: 24px;
865
- }
866
-
867
- @include respond-to('pad_v') {
868
- --tab-nav-justify: flex-end;
868
+ --tab-nav-padding: 0 0 18px;
869
869
  }
870
870
 
871
- @include respond('pad_v-laptop') {
872
- --tab-nav-padding: 0 0 14px;
873
- }
874
871
  @include respond('<=pad_v') {
875
872
  border-bottom: none;
876
873
  height: auto;
877
874
  .o-icon {
878
875
  display: none;
879
876
  }
880
- .o-tab-navs-container {
881
-
882
- .o-tab-nav {
883
- line-height: 32px;
884
- }
885
- }
886
877
  }
878
+ @include respond-to('pad_v') {
879
+ --tab-nav-justify: flex-end;
880
+ width: 50%;
881
+ --tab-nav-padding: 0 0 14px;
882
+ }
883
+
887
884
  @include respond('phone') {
888
- .o-tab-nav {
889
- line-height: 2;
890
- }
885
+ --tab-nav-padding: 0 0 4px;
891
886
  }
892
887
 
893
888
  .o-icon {
@@ -915,8 +910,21 @@ defineExpose({
915
910
  }
916
911
 
917
912
  .empty-result {
918
- --result-image-width: 200px;
919
- --result-image-height: 175px;
913
+ --result-image-width: 240px;
914
+ --result-image-height: 210px;
915
+ --result-desc-gap: var(--o-gap-4);
916
+
917
+ @include respond('laptop') {
918
+ --result-image-width: 200px;
919
+ --result-image-height: 175px;
920
+ --result-desc-gap: var(--o-gap-3);
921
+ }
922
+
923
+ @include respond('<=pad') {
924
+ --result-image-width: 160px;
925
+ --result-image-height: 140px;
926
+ --result-desc-gap: var(--o-gap-2);
927
+ }
920
928
 
921
929
  .o-result-description {
922
930
  @include tip1;
@@ -20,7 +20,7 @@ import { useScreen } from '@opendesign-plus/composables';
20
20
  import { useMeetingConfig } from './composables/useMeetingConfig';
21
21
  import OMeetingCalendarList from '@/components/meeting/components/OMeetingCalendarList.vue';
22
22
  import { formatDate } from '@/components/meeting/utils.ts';
23
- import emptyImg from '@/assets/meeting/svg-icons/icon-empty.svg';
23
+ import emptyDefaultImg from '@/assets/meeting/empty.png';
24
24
 
25
25
  const props = defineProps<{
26
26
  sigName: String;
@@ -28,6 +28,8 @@ const props = defineProps<{
28
28
  getDateListRequest: any;
29
29
  getEventsListRequest: any;
30
30
  dates: String[];
31
+ emptyImg?: any;
32
+ emptyText?: string;
31
33
  }>();
32
34
  const { t, meetingTabs } = useMeetingConfig();
33
35
  const { lePadV } = useScreen();
@@ -331,9 +333,9 @@ const list = computed(() => {
331
333
  <slot name="empty">
332
334
  <OResult class="empty-result">
333
335
  <template #image>
334
- <OFigure class="img" :src="emptyImg" />
336
+ <OFigure class="img" :src="emptyImg ?? emptyDefaultImg" />
335
337
  </template>
336
- <template #description>{{ t('meeting.meetingEmptyText') }}</template>
338
+ <template #description>{{ emptyText ?? t('meeting.meetingEmptyText') }}</template>
337
339
  </OResult>
338
340
  </slot>
339
341
  </template>
@@ -332,6 +332,10 @@ const computedList = computed<any[]>(() => {
332
332
  display: flex;
333
333
  align-items: center;
334
334
  justify-content: center;
335
+ @include respond('<=pad_v') {
336
+ min-height: auto;
337
+ padding: var(--o-gap-5) 0;
338
+ }
335
339
  }
336
340
 
337
341
 
@@ -56,6 +56,8 @@ export interface MeetingCalendarPropsT {
56
56
  groupType: MeetingGroupType;
57
57
  groups: string[];
58
58
  disableFormat?: boolean; //是否禁用日期格式化
59
+ emptyImg?: any;
60
+ emptyText?: string;
59
61
  }
60
62
 
61
63
  // 会议新增、修改
package/src/i18n/en.ts CHANGED
@@ -78,7 +78,7 @@ export default {
78
78
  'meeting.meetingGroup': 'Group',
79
79
  'meeting.selectSig': 'Select a SIG.',
80
80
  'meeting.selectGroup': 'Select a Group.',
81
- 'meeting.enterEtherpad': 'Enter Etherpad.',
81
+ 'meeting.enterEtherpad': 'Enter Meeting Minutes.',
82
82
  'meeting.etherpadDesc': 'A meeting assistant for recording meeting minutes and conversations.',
83
83
  'meeting.selectDate': 'Select a date.',
84
84
  'meeting.finishMeetingConfig': 'Complete the meeting settings.',
@@ -150,12 +150,12 @@ export default {
150
150
  'meeting.eventsTitle': 'Name',
151
151
  'meeting.summitTitle': 'Name',
152
152
  'meeting.meetingDetail': 'Details',
153
- 'meeting.meetingEtherpad': 'Etherpad',
153
+ 'meeting.meetingEtherpad': 'Meeting Minutes',
154
154
  'meeting.meetingReplay': 'Playback',
155
155
  'meeting.searchSubtitlePlaceholder': 'Enter',
156
156
  'meeting.detailHalfYearMeetings': '默认显示近半年的会议。',
157
157
  'meeting.tencent': 'Tencent',
158
- 'meeting.etherpad': 'Etherpad',
158
+ 'meeting.etherpad': 'Meeting Minutes',
159
159
  'common.confirm': 'Confirm',
160
160
  'common.cancel': 'Cancel',
161
161
  'common.copySuccess': 'Copied Successfully',