@saooti/octopus-sdk 37.0.5 → 37.0.7
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 +2 -2
- package/index.html +1 -0
- package/index.ts +21 -21
- package/package.json +26 -20
- package/public/css/fonts/icomoon.eot +0 -0
- package/public/css/fonts/icomoon.svg +1 -1
- package/public/css/fonts/icomoon.ttf +0 -0
- package/public/css/fonts/icomoon.woff +0 -0
- package/public/css/fonts/montserrat/Montserrat-Black.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-BlackItalic.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-Bold.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-BoldItalic.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-ExtraBold.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-ExtraBoldItalic.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-ExtraLight.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-ExtraLightItalic.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-Italic.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-Light.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-LightItalic.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-Medium.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-MediumItalic.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-Regular.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-SemiBold.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-SemiBoldItalic.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-Thin.ttf +0 -0
- package/public/css/fonts/montserrat/Montserrat-ThinItalic.ttf +0 -0
- package/public/css/fonts/montserrat/style.css +28 -0
- package/public/css/fonts/style.css +5 -5
- package/src/App.vue +69 -60
- package/src/api/classicCrud.ts +12 -12
- package/src/api/initialize.ts +1 -1
- package/src/assets/bootstrap.scss +9 -0
- package/src/assets/general.scss +1 -1
- package/src/assets/share.scss +1 -1
- package/src/components/display/aggregator/RssSection.vue +3 -3
- package/src/components/display/categories/CategoryChooser.vue +73 -60
- package/src/components/display/categories/CategoryFilter.vue +134 -90
- package/src/components/display/categories/CategoryList.vue +76 -62
- package/src/components/display/comments/AddCommentModal.vue +44 -44
- package/src/components/display/comments/CommentBasicView.vue +38 -30
- package/src/components/display/comments/CommentInput.vue +122 -110
- package/src/components/display/comments/CommentItem.vue +144 -102
- package/src/components/display/comments/CommentList.vue +117 -85
- package/src/components/display/comments/CommentParentInfo.vue +18 -15
- package/src/components/display/comments/CommentPlayer.vue +39 -41
- package/src/components/display/comments/CommentSection.vue +68 -53
- package/src/components/display/edit/EditBox.vue +7 -7
- package/src/components/display/edit/EditBoxRadio.vue +3 -4
- package/src/components/display/edit/EditCommentBox.vue +34 -36
- package/src/components/display/emission/EmissionInlineList.vue +75 -63
- package/src/components/display/emission/EmissionItem.vue +47 -35
- package/src/components/display/emission/EmissionList.vue +111 -83
- package/src/components/display/emission/EmissionPlayerItem.vue +89 -89
- package/src/components/display/filter/AdvancedSearch.vue +81 -73
- package/src/components/display/filter/CategorySearchFilter.vue +27 -25
- package/src/components/display/filter/DateFilter.vue +38 -38
- package/src/components/display/filter/MonetizableFilter.vue +16 -14
- package/src/components/display/filter/ProductorSearch.vue +55 -47
- package/src/components/display/filter/RubriqueChoice.vue +42 -27
- package/src/components/display/filter/RubriqueFilter.vue +130 -85
- package/src/components/display/filter/SearchOrder.vue +16 -11
- package/src/components/display/list/ListPaginate.vue +72 -70
- package/src/components/display/list/PaginateParams.vue +29 -30
- package/src/components/display/list/PaginateSection.vue +210 -0
- package/src/components/display/list/SwiperList.vue +28 -32
- package/src/components/display/live/CountDown.vue +12 -14
- package/src/components/display/live/LiveHorizontalList.vue +60 -50
- package/src/components/display/live/LiveItem.vue +42 -26
- package/src/components/display/live/LiveList.vue +92 -65
- package/src/components/display/live/RadioCurrently.vue +47 -42
- package/src/components/display/live/RadioImage.vue +40 -42
- package/src/components/display/live/RadioItem.vue +15 -22
- package/src/components/display/live/RadioList.vue +24 -21
- package/src/components/display/live/RadioPlanning.vue +105 -68
- package/src/components/display/organisation/OrganisationChooser.vue +58 -42
- package/src/components/display/organisation/OrganisationChooserLight.vue +27 -19
- package/src/components/display/participant/ParticipantItem.vue +89 -76
- package/src/components/display/participant/ParticipantList.vue +90 -60
- package/src/components/display/playlist/PlaylistItem.vue +32 -35
- package/src/components/display/playlist/PlaylistList.vue +70 -52
- package/src/components/display/playlist/PodcastList.vue +61 -50
- package/src/components/display/playlist/PodcastPlaylistInlineList.vue +47 -38
- package/src/components/display/podcasts/AnimatorsItem.vue +17 -15
- package/src/components/display/podcasts/ParticipantDescription.vue +21 -22
- package/src/components/display/podcasts/PodcastFilterList.vue +28 -26
- package/src/components/display/podcasts/PodcastImage.vue +129 -138
- package/src/components/display/podcasts/PodcastInlineList.vue +33 -29
- package/src/components/display/podcasts/PodcastInlineListClassic.vue +91 -71
- package/src/components/display/podcasts/PodcastInlineListTemplate.vue +94 -85
- package/src/components/display/podcasts/PodcastItem.vue +96 -90
- package/src/components/display/podcasts/PodcastItemInfo.vue +63 -65
- package/src/components/display/podcasts/PodcastList.vue +115 -84
- package/src/components/display/podcasts/PodcastModuleBox.vue +95 -104
- package/src/components/display/podcasts/PodcastPlayBar.vue +45 -32
- package/src/components/display/podcasts/PodcastSwiperList.vue +65 -55
- package/src/components/display/podcasts/TagList.vue +33 -37
- package/src/components/display/rubriques/RubriqueChooser.vue +70 -51
- package/src/components/display/rubriques/RubriqueList.vue +117 -89
- package/src/components/display/sharing/PlayerParameters.vue +45 -42
- package/src/components/display/sharing/QrCode.vue +52 -46
- package/src/components/display/sharing/ShareButtons.vue +25 -27
- package/src/components/display/sharing/ShareButtonsIntern.vue +182 -155
- package/src/components/display/sharing/ShareDistribution.vue +101 -67
- package/src/components/display/sharing/SharePlayer.vue +207 -127
- package/src/components/display/sharing/SharePlayerColors.vue +15 -15
- package/src/components/display/sharing/SharePlayerRadio.vue +62 -39
- package/src/components/display/sharing/SharePlayerTypes.vue +93 -55
- package/src/components/display/sharing/SubscribeButtons.vue +83 -32
- package/src/components/display/studio/RecordingItemButton.vue +3 -3
- package/src/components/form/ClassicCheckbox.vue +32 -31
- package/src/components/form/ClassicDatePicker.vue +47 -49
- package/src/components/form/ClassicInputText.vue +99 -98
- package/src/components/form/ClassicLoading.vue +11 -14
- package/src/components/form/ClassicMultiselect.vue +125 -126
- package/src/components/form/ClassicRadio.vue +15 -18
- package/src/components/form/ClassicSearch.vue +17 -23
- package/src/components/form/ClassicSelect.vue +35 -27
- package/src/components/form/{Wysiwyg.vue → ClassicWysiwyg.vue} +94 -109
- package/src/components/misc/AcpmImage.vue +26 -0
- package/src/components/misc/ClassicAccordion.vue +69 -0
- package/src/components/misc/ClassicNav.vue +117 -0
- package/src/components/misc/ClassicPopover.vue +212 -0
- package/src/components/misc/{Spinner.vue → ClassicSpinner.vue} +14 -15
- package/src/components/misc/ErrorMessage.vue +9 -17
- package/src/components/misc/FooterSection.vue +198 -0
- package/src/components/misc/HomeDropdown.vue +67 -64
- package/src/components/misc/LeftMenu.vue +115 -79
- package/src/components/misc/ProgressBar.vue +36 -32
- package/src/components/misc/SnackBar.vue +169 -0
- package/src/components/misc/TopBar.vue +161 -115
- package/src/components/misc/modal/ClassicModal.vue +99 -103
- package/src/components/misc/modal/ClipboardModal.vue +21 -23
- package/src/components/misc/modal/MessageModal.vue +22 -28
- package/src/components/misc/modal/NewsletterModal.vue +139 -113
- package/src/components/misc/modal/QrCodeModal.vue +14 -17
- package/src/components/misc/modal/ShareModalPlayer.vue +44 -60
- package/src/components/misc/player/PlayerCompact.vue +47 -62
- package/src/components/misc/player/{Player.vue → PlayerComponent.vue} +54 -46
- package/src/components/misc/player/PlayerLarge.vue +66 -62
- package/src/components/misc/player/PlayerProgressBar.vue +40 -30
- package/src/components/misc/player/PlayerTimeline.vue +32 -36
- package/src/components/misc/player/radio/RadioHistory.vue +62 -59
- package/src/components/misc/player/radio/RadioProgressBar.vue +44 -35
- package/src/components/mixins/cookies.ts +11 -10
- package/src/components/mixins/displayMethods.ts +5 -4
- package/src/components/mixins/handle403.ts +9 -9
- package/src/components/mixins/imageProxy.ts +14 -7
- package/src/components/mixins/init.ts +31 -16
- package/src/components/mixins/orgaComputed.ts +7 -7
- package/src/components/mixins/organisationFilter.ts +36 -22
- package/src/components/mixins/player/playerComment.ts +46 -37
- package/src/components/mixins/player/playerDisplay.ts +122 -87
- package/src/components/mixins/player/playerLive.ts +65 -43
- package/src/components/mixins/player/playerLogic.ts +133 -88
- package/src/components/mixins/player/playerTranscript.ts +48 -30
- package/src/components/mixins/radio/fetchRadioData.ts +40 -23
- package/src/components/mixins/selenium.ts +2 -2
- package/src/components/mixins/tagOfMixins.ts +11 -11
- package/src/components/pages/CategoryPage.vue +43 -0
- package/src/components/pages/{Emission.vue → EmissionPage.vue} +98 -67
- package/src/components/pages/{Emissions.vue → EmissionsPage.vue} +51 -44
- package/src/components/pages/Error403Page.vue +20 -19
- package/src/components/pages/HomePage.vue +144 -0
- package/src/components/pages/LivesPage.vue +66 -0
- package/src/components/pages/PageNotFound.vue +33 -22
- package/src/components/pages/{Participant.vue → ParticipantPage.vue} +63 -49
- package/src/components/pages/{Participants.vue → ParticipantsPage.vue} +9 -9
- package/src/components/pages/PlaylistPage.vue +175 -0
- package/src/components/pages/{Playlists.vue → PlaylistsPage.vue} +16 -14
- package/src/components/pages/PodcastPage.vue +365 -0
- package/src/components/pages/PodcastsPage.vue +152 -0
- package/src/components/pages/RadioPage.vue +131 -0
- package/src/components/pages/RubriquePage.vue +45 -0
- package/src/components/pages/{Search.vue → SearchPage.vue} +19 -19
- package/src/helper/dom.ts +1 -1
- package/src/helper/duration.ts +10 -4
- package/src/helper/useEventListener.ts +7 -8
- package/src/i18n.ts +31 -30
- package/src/locale/de.ts +263 -257
- package/src/locale/educationen.ts +13 -13
- package/src/locale/educationfr.ts +1 -1
- package/src/locale/en.ts +323 -324
- package/src/locale/es.ts +325 -318
- package/src/locale/fr.ts +330 -324
- package/src/locale/it.ts +332 -328
- package/src/locale/messages.ts +9 -9
- package/src/locale/sl.ts +315 -319
- package/src/main.ts +28 -31
- package/src/router/router.ts +218 -198
- package/src/shims-tsx.d.ts +1 -1
- package/src/shims-vue.d.ts +1 -1
- package/src/stores/ApiStore.ts +44 -44
- package/src/stores/AuthStore.ts +24 -16
- package/src/stores/CommentStore.ts +13 -11
- package/src/stores/FilterStore.ts +25 -15
- package/src/stores/GeneralStore.ts +15 -15
- package/src/stores/ParamSdkStore.ts +179 -137
- package/src/stores/PlayerStore.ts +139 -125
- package/src/stores/class/adserver/adserverConfig.ts +1 -1
- package/src/stores/class/adserver/adserverOtherEmission.ts +9 -9
- package/src/stores/class/cartouchier/cartouche.ts +4 -4
- package/src/stores/class/cartouchier/cartouchier.ts +2 -2
- package/src/stores/class/conference/conference.ts +10 -9
- package/src/stores/class/conference/conferenceMessage.ts +2 -2
- package/src/stores/class/conference/conferenceParticipant.ts +1 -1
- package/src/stores/class/conference/studioCall.ts +6 -6
- package/src/stores/class/contract/contractOrganisation.ts +5 -5
- package/src/stores/class/ftp/ftpEmission.ts +9 -9
- package/src/stores/class/ftp/testFtpEmission.ts +4 -4
- package/src/stores/class/general/audioView.ts +19 -19
- package/src/stores/class/general/category.ts +1 -1
- package/src/stores/class/general/classicSelectType.ts +2 -3
- package/src/stores/class/general/customPlayer.ts +8 -8
- package/src/stores/class/general/emission.ts +20 -21
- package/src/stores/class/general/fetchParam.ts +8 -2
- package/src/stores/class/general/initState.ts +31 -31
- package/src/stores/class/general/interfacePageable.ts +13 -13
- package/src/stores/class/general/ituneCategory.ts +4 -4
- package/src/stores/class/general/listReturn.ts +12 -12
- package/src/stores/class/general/media.ts +7 -7
- package/src/stores/class/general/organisation.ts +9 -10
- package/src/stores/class/general/pageable.ts +10 -10
- package/src/stores/class/general/participant.ts +7 -7
- package/src/stores/class/general/player.ts +30 -28
- package/src/stores/class/general/playlist.ts +17 -19
- package/src/stores/class/general/podcast.ts +19 -19
- package/src/stores/class/general/sortPageable.ts +4 -4
- package/src/stores/class/general/soundcastCategory.ts +7 -7
- package/src/stores/class/ouestFrance/ofTag.ts +34 -34
- package/src/stores/class/ouestFrance/ofTagInfo.ts +9 -9
- package/src/stores/class/ouestFrance/ofTagPage.ts +7 -7
- package/src/stores/class/ouestFrance/ofTagSeo.ts +7 -7
- package/src/stores/class/ouestFrance/ofTagVente.ts +6 -6
- package/src/stores/class/ouestFrance/ofTagWithParents.ts +20 -20
- package/src/stores/class/radio/canal.ts +4 -4
- package/src/stores/class/radio/live.ts +6 -6
- package/src/stores/class/radio/mix.ts +16 -16
- package/src/stores/class/radio/playlistMedia.ts +7 -7
- package/src/stores/class/radio/recurrence.ts +54 -54
- package/src/stores/class/rss/rssEmission.ts +13 -13
- package/src/stores/class/rss/rssInfo.ts +7 -7
- package/src/stores/class/rubrique/rubriquage.ts +2 -2
- package/src/stores/class/rubrique/rubrique.ts +1 -1
- package/src/stores/class/stat/statArrayIncome.ts +5 -5
- package/src/stores/class/stat/statArrayObject.ts +26 -26
- package/src/stores/class/stat/statGraph.ts +6 -6
- package/src/stores/class/user/person.ts +4 -2
- package/src/stores/class/user/profile.ts +4 -2
- package/src/stores/class/user/userKeycloak.ts +4 -5
- package/src/components/display/list/Paginate.vue +0 -181
- package/src/components/misc/Accordion.vue +0 -78
- package/src/components/misc/Footer.vue +0 -165
- package/src/components/misc/Nav.vue +0 -119
- package/src/components/misc/Popover.vue +0 -193
- package/src/components/misc/Snackbar.vue +0 -168
- package/src/components/pages/Category.vue +0 -41
- package/src/components/pages/Home.vue +0 -125
- package/src/components/pages/Lives.vue +0 -64
- package/src/components/pages/Playlist.vue +0 -164
- package/src/components/pages/Podcast.vue +0 -307
- package/src/components/pages/Podcasts.vue +0 -146
- package/src/components/pages/Radio.vue +0 -122
- package/src/components/pages/Rubrique.vue +0 -42
|
@@ -1,59 +1,55 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<DatePicker
|
|
3
3
|
ref="datePicker"
|
|
4
|
-
:model-value="undefined!==range ? range : date"
|
|
5
|
-
:model-modifiers="{ range:undefined!==range }"
|
|
4
|
+
:model-value="undefined !== range ? range : date"
|
|
5
|
+
:model-modifiers="{ range: undefined !== range }"
|
|
6
6
|
:mode="mode"
|
|
7
7
|
color="green"
|
|
8
8
|
is24hr
|
|
9
9
|
:max-date="isMaxDate ? now : undefined"
|
|
10
10
|
:min-date="isMinDate ? now : undefined"
|
|
11
11
|
:columns="columnNumber"
|
|
12
|
-
:is-inline="columnNumber>1"
|
|
12
|
+
:is-inline="columnNumber > 1"
|
|
13
13
|
:update-on-input="conditionEdit"
|
|
14
14
|
:masks="isMask ? masks : undefined"
|
|
15
15
|
:time-accuracy="timeAccuracy"
|
|
16
|
-
@update:
|
|
16
|
+
@update:model-value="$emit('updateDate', $event)"
|
|
17
17
|
>
|
|
18
|
-
<template
|
|
19
|
-
v-
|
|
20
|
-
#default="{ inputValue, inputEvents }"
|
|
21
|
-
>
|
|
22
|
-
<input
|
|
23
|
-
:class="templateClass"
|
|
24
|
-
:value="inputValue"
|
|
25
|
-
v-on="inputEvents"
|
|
26
|
-
>
|
|
18
|
+
<template v-if="templateClass" #default="{ inputValue, inputEvents }">
|
|
19
|
+
<input :class="templateClass" :value="inputValue" v-on="inputEvents" />
|
|
27
20
|
</template>
|
|
28
21
|
</DatePicker>
|
|
29
22
|
</template>
|
|
30
23
|
|
|
31
24
|
<script lang="ts">
|
|
32
|
-
import dayjs from
|
|
33
|
-
import { DatePicker } from
|
|
34
|
-
import { defineComponent } from
|
|
25
|
+
import dayjs from "dayjs";
|
|
26
|
+
import { DatePicker } from "v-calendar";
|
|
27
|
+
import { defineComponent } from "vue";
|
|
35
28
|
export default defineComponent({
|
|
36
29
|
components: {
|
|
37
30
|
DatePicker,
|
|
38
31
|
},
|
|
39
32
|
props: {
|
|
40
|
-
date: { default: undefined, type: Date},
|
|
41
|
-
range: {
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
33
|
+
date: { default: undefined, type: Date },
|
|
34
|
+
range: {
|
|
35
|
+
default: undefined,
|
|
36
|
+
type: Object as () => { start: Date; end: Date },
|
|
37
|
+
},
|
|
38
|
+
isMaxDate: { default: false, type: Boolean },
|
|
39
|
+
isMinDate: { default: false, type: Boolean },
|
|
40
|
+
columnNumber: { default: 1, type: Number },
|
|
41
|
+
timeAccuracy: { default: 2, type: Number },
|
|
42
|
+
templateClass: { default: undefined, type: String },
|
|
43
|
+
mode: { default: "dateTime", type: String },
|
|
44
|
+
isMask: { default: false, type: Boolean },
|
|
45
|
+
conditionEdit: { default: true, type: Boolean },
|
|
50
46
|
},
|
|
51
47
|
|
|
52
|
-
emits: [
|
|
48
|
+
emits: ["updateDate", "update:date"],
|
|
53
49
|
data() {
|
|
54
50
|
return {
|
|
55
51
|
masks: {
|
|
56
|
-
input:
|
|
52
|
+
input: "YYYY-MM-DD",
|
|
57
53
|
},
|
|
58
54
|
};
|
|
59
55
|
},
|
|
@@ -61,29 +57,31 @@ export default defineComponent({
|
|
|
61
57
|
now(): Date {
|
|
62
58
|
return dayjs().toDate();
|
|
63
59
|
},
|
|
64
|
-
}
|
|
65
|
-
})
|
|
60
|
+
},
|
|
61
|
+
});
|
|
66
62
|
</script>
|
|
67
63
|
<style lang="scss">
|
|
68
|
-
@import
|
|
69
|
-
@import
|
|
70
|
-
.octopus-app{
|
|
71
|
-
.vc-base-select select{
|
|
64
|
+
@import "@scss/_variables.scss";
|
|
65
|
+
@import "v-calendar/dist/style.css";
|
|
66
|
+
.octopus-app {
|
|
67
|
+
.vc-base-select select {
|
|
72
68
|
border: 0 !important;
|
|
73
69
|
}
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
70
|
+
.vc-select select {
|
|
71
|
+
padding: 0 !important;
|
|
72
|
+
}
|
|
73
|
+
.vc-date {
|
|
74
|
+
.vc-month,
|
|
75
|
+
.vc-day,
|
|
76
|
+
.vc-year {
|
|
77
|
+
color: $octopus-primary-color !important;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
.vc-highlight {
|
|
81
|
+
background-color: $octopus-primary-color !important;
|
|
82
|
+
}
|
|
83
|
+
.vc-select select:focus {
|
|
84
|
+
border-color: $octopus-primary-color !important;
|
|
85
|
+
}
|
|
88
86
|
}
|
|
89
|
-
</style>
|
|
87
|
+
</style>
|
|
@@ -4,25 +4,22 @@
|
|
|
4
4
|
<label
|
|
5
5
|
class="form-label"
|
|
6
6
|
:for="inputId"
|
|
7
|
-
:class="displayLabel?'':'d-none'"
|
|
8
|
-
|
|
7
|
+
:class="displayLabel ? '' : 'd-none'"
|
|
8
|
+
>{{ label }}</label
|
|
9
|
+
>
|
|
9
10
|
<template v-if="popover">
|
|
10
11
|
<span
|
|
11
|
-
:id="'popover'+inputId"
|
|
12
|
+
:id="'popover' + inputId"
|
|
12
13
|
role="button"
|
|
13
14
|
class="saooti-help m-0"
|
|
14
15
|
tabindex="0"
|
|
15
16
|
:title="$t('Help')"
|
|
16
17
|
/>
|
|
17
|
-
<
|
|
18
|
-
:target="'popover'+inputId"
|
|
19
|
-
>
|
|
18
|
+
<ClassicPopover :target="'popover' + inputId">
|
|
20
19
|
<!-- eslint-disable vue/no-v-html -->
|
|
21
|
-
<div
|
|
22
|
-
v-html="popover"
|
|
23
|
-
/>
|
|
20
|
+
<div v-html="popover" />
|
|
24
21
|
<!-- eslint-enable -->
|
|
25
|
-
</
|
|
22
|
+
</ClassicPopover>
|
|
26
23
|
</template>
|
|
27
24
|
</div>
|
|
28
25
|
<input
|
|
@@ -35,127 +32,131 @@
|
|
|
35
32
|
:data-selenium="dataSelenium"
|
|
36
33
|
:data-value="textValue"
|
|
37
34
|
:maxlength="inputMaxLengthField"
|
|
38
|
-
:readonly="readonly?'readonly':undefined"
|
|
35
|
+
:readonly="readonly ? 'readonly' : undefined"
|
|
39
36
|
:class="{
|
|
40
|
-
'border border-danger':
|
|
37
|
+
'border border-danger':
|
|
38
|
+
forceError || (isError && (undefined !== textValue || canBeNull)),
|
|
41
39
|
}"
|
|
42
40
|
:disabled="isDisable"
|
|
43
|
-
|
|
41
|
+
/>
|
|
44
42
|
<textarea
|
|
45
43
|
v-else-if="isTextarea"
|
|
46
44
|
:id="inputId"
|
|
47
45
|
v-model="textValue"
|
|
48
46
|
:data-selenium="dataSelenium"
|
|
49
47
|
:placeholder="placeholder"
|
|
50
|
-
:readonly="readonly?'readonly':undefined"
|
|
48
|
+
:readonly="readonly ? 'readonly' : undefined"
|
|
51
49
|
class="form-input"
|
|
52
50
|
:class="{
|
|
53
|
-
'border border-danger':
|
|
51
|
+
'border border-danger':
|
|
52
|
+
forceError || (isError && (undefined !== textValue || canBeNull)),
|
|
54
53
|
}"
|
|
55
54
|
:disabled="isDisable"
|
|
56
55
|
/>
|
|
57
|
-
<
|
|
56
|
+
<ClassicWysiwyg
|
|
58
57
|
v-else
|
|
59
58
|
v-model:content="textValue"
|
|
60
|
-
:error-description="
|
|
59
|
+
:error-description="
|
|
60
|
+
forceError || (isError && (undefined !== textValue || canBeNull))
|
|
61
|
+
"
|
|
61
62
|
:is-disabled="isDisable"
|
|
62
63
|
/>
|
|
63
64
|
<div class="d-flex justify-content-between">
|
|
64
|
-
<div
|
|
65
|
-
|
|
66
|
-
class="h6"
|
|
67
|
-
>
|
|
68
|
-
{{ $t('Characters number calculated over HTML code') }}
|
|
65
|
+
<div v-if="isWysiwyg" class="h6">
|
|
66
|
+
{{ $t("Characters number calculated over HTML code") }}
|
|
69
67
|
</div>
|
|
70
|
-
<div
|
|
71
|
-
v-else-if="''!==indicText"
|
|
72
|
-
class="text-indic"
|
|
73
|
-
>
|
|
68
|
+
<div v-else-if="'' !== indicText" class="text-indic">
|
|
74
69
|
{{ indicText }}
|
|
75
70
|
</div>
|
|
76
71
|
<div
|
|
77
|
-
v-else-if="
|
|
72
|
+
v-else-if="
|
|
73
|
+
forceError || (isError && (undefined !== textValue || canBeNull))
|
|
74
|
+
"
|
|
78
75
|
class="text-danger"
|
|
79
76
|
>
|
|
80
77
|
{{ errorText }}
|
|
81
78
|
</div>
|
|
82
79
|
<p
|
|
83
|
-
v-if="0!==maxLength"
|
|
80
|
+
v-if="0 !== maxLength"
|
|
84
81
|
class="counter-align-right"
|
|
85
82
|
:class="{ 'text-danger': !valueLengthValid }"
|
|
86
83
|
>
|
|
87
|
-
{{ countValue +
|
|
84
|
+
{{ countValue + " / " + maxLength }}
|
|
88
85
|
</p>
|
|
89
86
|
</div>
|
|
90
87
|
</div>
|
|
91
88
|
</template>
|
|
92
89
|
<script lang="ts">
|
|
93
|
-
import { defineAsyncComponent, defineComponent } from
|
|
94
|
-
const
|
|
95
|
-
() => import(
|
|
90
|
+
import { defineAsyncComponent, defineComponent } from "vue";
|
|
91
|
+
const ClassicPopover = defineAsyncComponent(
|
|
92
|
+
() => import("../misc/ClassicPopover.vue"),
|
|
96
93
|
);
|
|
97
|
-
const
|
|
98
|
-
() => import(
|
|
94
|
+
const ClassicWysiwyg = defineAsyncComponent(
|
|
95
|
+
() => import("./ClassicWysiwyg.vue"),
|
|
99
96
|
);
|
|
100
97
|
export default defineComponent({
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
98
|
+
components: {
|
|
99
|
+
ClassicWysiwyg,
|
|
100
|
+
ClassicPopover,
|
|
104
101
|
},
|
|
105
102
|
props: {
|
|
106
103
|
inputId: { default: "", type: String },
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
isTextarea: {default: false, type: Boolean},
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
isDisable: {default: false, type: Boolean},
|
|
118
|
-
indicText:{ default: "", type: String },
|
|
119
|
-
dataSelenium:{ default: "", type: String },
|
|
120
|
-
placeholder:{ default: "", type: String },
|
|
121
|
-
popover: {default: undefined, type:String},
|
|
122
|
-
readonly: {default: false, type: Boolean},
|
|
123
|
-
forceError: {default: false, type: Boolean},
|
|
124
|
-
displayLabel:{default: true, type: Boolean},
|
|
104
|
+
label: { default: "", type: String },
|
|
105
|
+
textInit: { default: undefined, type: String },
|
|
106
|
+
maxLength: { default: 0, type: Number },
|
|
107
|
+
errorText: { default: "", type: String },
|
|
108
|
+
isTextarea: { default: false, type: Boolean },
|
|
109
|
+
isWysiwyg: { default: false, type: Boolean },
|
|
110
|
+
regex: { default: undefined, type: RegExp },
|
|
111
|
+
canBeNull: { default: false, type: Boolean },
|
|
112
|
+
inputMaxLengthField: { default: undefined, type: Number },
|
|
113
|
+
errorVariable: { default: true, type: Boolean },
|
|
114
|
+
isDisable: { default: false, type: Boolean },
|
|
115
|
+
indicText: { default: "", type: String },
|
|
116
|
+
dataSelenium: { default: "", type: String },
|
|
117
|
+
placeholder: { default: "", type: String },
|
|
118
|
+
popover: { default: undefined, type: String },
|
|
119
|
+
readonly: { default: false, type: Boolean },
|
|
120
|
+
forceError: { default: false, type: Boolean },
|
|
121
|
+
displayLabel: { default: true, type: Boolean },
|
|
125
122
|
},
|
|
126
|
-
emits: [
|
|
127
|
-
|
|
123
|
+
emits: ["update:textInit", "update:errorVariable"],
|
|
124
|
+
data() {
|
|
128
125
|
return {
|
|
129
|
-
textValue: undefined as string|undefined,
|
|
130
|
-
|
|
131
|
-
|
|
126
|
+
textValue: undefined as string | undefined,
|
|
127
|
+
};
|
|
128
|
+
},
|
|
132
129
|
computed: {
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
130
|
+
isError(): boolean {
|
|
131
|
+
return (
|
|
132
|
+
!this.valueTrimValid || !this.valueLengthValid || !this.valueRegexValid
|
|
133
|
+
);
|
|
134
|
+
},
|
|
136
135
|
countValue(): number {
|
|
137
|
-
if(this.textValue){
|
|
136
|
+
if (this.textValue) {
|
|
138
137
|
return this.textValue.length;
|
|
139
138
|
}
|
|
140
139
|
return 0;
|
|
141
140
|
},
|
|
142
141
|
valueTrimValid(): boolean {
|
|
143
|
-
|
|
144
|
-
if(!this.textValue){
|
|
142
|
+
if (!this.canBeNull) {
|
|
143
|
+
if (!this.textValue) {
|
|
145
144
|
return false;
|
|
146
145
|
}
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
146
|
+
return 0 !== this.textValue.trim().length;
|
|
147
|
+
}
|
|
148
|
+
return true;
|
|
150
149
|
},
|
|
151
150
|
valueLengthValid(): boolean {
|
|
152
|
-
|
|
151
|
+
if (0 === this.maxLength) {
|
|
152
|
+
return true;
|
|
153
|
+
}
|
|
153
154
|
return this.maxLength >= this.countValue;
|
|
154
155
|
},
|
|
155
|
-
|
|
156
|
+
valueRegexValid(): boolean {
|
|
156
157
|
if (this.regex !== undefined) {
|
|
157
|
-
if(!this.textValue || ""===this.textValue){
|
|
158
|
-
if(this.canBeNull){
|
|
158
|
+
if (!this.textValue || "" === this.textValue) {
|
|
159
|
+
if (this.canBeNull) {
|
|
159
160
|
return true;
|
|
160
161
|
}
|
|
161
162
|
return false;
|
|
@@ -166,38 +167,38 @@ export default defineComponent({
|
|
|
166
167
|
},
|
|
167
168
|
},
|
|
168
169
|
watch: {
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
textValue(){
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
170
|
+
isError() {
|
|
171
|
+
this.$emit("update:errorVariable", this.isError);
|
|
172
|
+
},
|
|
173
|
+
textValue() {
|
|
174
|
+
if (this.textInit !== this.textValue) {
|
|
175
|
+
this.$emit("update:textInit", this.textValue);
|
|
176
|
+
}
|
|
177
|
+
},
|
|
178
|
+
textInit() {
|
|
179
|
+
if (this.textInit !== this.textValue) {
|
|
180
|
+
this.textValue = this.textInit;
|
|
181
|
+
}
|
|
182
|
+
},
|
|
182
183
|
},
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
if(this.errorVariable !== this.isError){
|
|
186
|
-
this.$emit(
|
|
184
|
+
mounted() {
|
|
185
|
+
this.textValue = this.textInit;
|
|
186
|
+
if (this.errorVariable !== this.isError) {
|
|
187
|
+
this.$emit("update:errorVariable", this.isError);
|
|
187
188
|
}
|
|
188
|
-
|
|
189
|
+
},
|
|
189
190
|
});
|
|
190
191
|
</script>
|
|
191
192
|
<style lang="scss">
|
|
192
|
-
.octopus-app .classic-input-text{
|
|
193
|
-
.text-indic{
|
|
193
|
+
.octopus-app .classic-input-text {
|
|
194
|
+
.text-indic {
|
|
194
195
|
font-style: italic;
|
|
195
196
|
font-size: 0.7rem;
|
|
196
197
|
color: #666;
|
|
197
198
|
}
|
|
198
|
-
textarea{
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
199
|
+
textarea {
|
|
200
|
+
height: auto;
|
|
201
|
+
min-height: 120px;
|
|
202
|
+
}
|
|
202
203
|
}
|
|
203
|
-
</style>
|
|
204
|
+
</style>
|
|
@@ -3,30 +3,27 @@
|
|
|
3
3
|
v-if="loadingText"
|
|
4
4
|
class="d-flex align-items-center justify-content-center"
|
|
5
5
|
>
|
|
6
|
-
<
|
|
6
|
+
<ClassicSpinner class="me-3" />
|
|
7
7
|
<div class="h3 mt-2">
|
|
8
8
|
{{ loadingText }}
|
|
9
9
|
</div>
|
|
10
10
|
</div>
|
|
11
|
-
<div
|
|
12
|
-
v-else-if="errorText"
|
|
13
|
-
class="text-center text-danger"
|
|
14
|
-
>
|
|
11
|
+
<div v-else-if="errorText" class="text-center text-danger">
|
|
15
12
|
<h3>{{ errorText }}</h3>
|
|
16
13
|
</div>
|
|
17
14
|
</template>
|
|
18
15
|
|
|
19
16
|
<script lang="ts">
|
|
20
|
-
import
|
|
21
|
-
import { defineComponent } from
|
|
17
|
+
import ClassicSpinner from "../misc/ClassicSpinner.vue";
|
|
18
|
+
import { defineComponent } from "vue";
|
|
22
19
|
export default defineComponent({
|
|
23
20
|
name: "ClassicLoading",
|
|
24
|
-
components:{
|
|
25
|
-
|
|
21
|
+
components: {
|
|
22
|
+
ClassicSpinner,
|
|
26
23
|
},
|
|
27
24
|
props: {
|
|
28
|
-
loadingText: { default: undefined, type: String},
|
|
29
|
-
errorText: { default: undefined, type: String},
|
|
30
|
-
}
|
|
31
|
-
})
|
|
32
|
-
</script>
|
|
25
|
+
loadingText: { default: undefined, type: String },
|
|
26
|
+
errorText: { default: undefined, type: String },
|
|
27
|
+
},
|
|
28
|
+
});
|
|
29
|
+
</script>
|