@explorer-1/vue 0.2.27 → 0.2.29
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/components.d.ts +1 -0
- package/dist/explorer-1-vue.js +3 -3
- package/dist/explorer-1-vue.umd.cjs +1 -1
- package/dist/src/components/AboutTheAuthor/AboutTheAuthor.stories.d.ts +30 -0
- package/dist/src/components/BaseImage/BaseImage.stories.d.ts +1 -1
- package/dist/src/components/BaseImage/BaseImage.vue.d.ts +1 -1
- package/dist/src/components/BlockLinkCard/BlockLinkCard.vue.d.ts +3 -3
- package/dist/src/components/DetailHeadline/DetailHeadline.vue.d.ts +10 -7
- package/dist/src/components/EventCard/EventCard.vue.d.ts +1 -1
- package/dist/src/components/MetadataEduResource/MetadataEduResource.vue.d.ts +1 -1
- package/dist/src/components/MetadataEvent/MetadataEvent.vue.d.ts +1 -1
- package/dist/src/components/MixinAnimationCaret/MixinAnimationCaret.stories.d.ts +1 -1
- package/dist/src/components/MixinAnimationCaret/MixinAnimationCaret.vue.d.ts +1 -1
- package/dist/src/components/SearchResultCard/SearchResultCard.vue.d.ts +3 -3
- package/dist/src/components/TextInput/TextInput.vue.d.ts +9 -9
- package/dist/src/interfaces.d.ts +7 -1
- package/dist/src/templates/edu/PageEduCollectionsDetail/PageEduCollectionsDetail.stories.d.ts +7 -7
- package/dist/src/templates/edu/PageEduLesson/PageEduLesson.stories.d.ts +2 -0
- package/dist/src/templates/edu/PageEduNewsDetail/PageEduNewsDetail.stories.d.ts +30 -0
- package/dist/src/templates/edu/PageEduTeachableMoment/PageEduTeachableMoment.stories.d.ts +2 -0
- package/dist/style.css +1 -1
- package/package.json +2 -2
- package/src/components/AboutTheAuthor/AboutTheAuthor.stories.js +50 -0
- package/src/components/AboutTheAuthor/AboutTheAuthor.vue +90 -0
- package/src/components/BaseAccordionItem/BaseAccordionItem.vue +1 -1
- package/src/components/BlockCardGrid/BlockCardGrid.vue +1 -1
- package/src/components/BlockLinkCard/BlockLinkCard.vue +1 -1
- package/src/components/BlockStreamfield/BlockStreamfield.vue +5 -3
- package/src/components/BlockText/BlockText.vue +3 -3
- package/src/components/CalendarButton/CalendarButton.vue +5 -4
- package/src/components/DetailHeadline/DetailHeadline.vue +2 -3
- package/src/components/MetaPanel/MetaPanel.stories.js +1 -1
- package/src/components/MetaPanel/MetaPanel.vue +3 -3
- package/src/components/MetaPanelItems/MetaPanelItems.vue +6 -9
- package/src/components/MetadataEduResource/MetadataEduResource.vue +1 -1
- package/src/components/MetadataEvent/MetadataEvent.stories.js +6 -4
- package/src/interfaces.ts +6 -1
- package/src/templates/edu/PageEduCollectionsDetail/PageEduCollectionsDetail.vue +1 -1
- package/src/templates/edu/PageEduExplainerArticle/PageEduExplainerArticle.stories.js +3 -1
- package/src/templates/edu/PageEduExplainerArticle/PageEduExplainerArticle.vue +24 -1
- package/src/templates/edu/PageEduLesson/PageEduLesson.stories.js +2 -0
- package/src/templates/edu/PageEduLesson/PageEduLesson.vue +9 -2
- package/src/templates/edu/PageEduNewsDetail/PageEduNewsDetail.stories.js +3 -8
- package/src/templates/edu/PageEduNewsDetail/PageEduNewsDetail.vue +11 -2
- package/src/templates/edu/PageEduTeachableMoment/PageEduTeachableMoment.stories.js +3 -0
- package/src/templates/edu/PageEduTeachableMoment/PageEduTeachableMoment.vue +9 -9
- package/src/templates/www/PageRoboticsDetail/PageRoboticsDetail.vue +1 -1
- package/src/utils/dayjs.js +2 -0
- package/src/utils/rangeifyGrades.ts +2 -2
|
@@ -11,6 +11,7 @@ import BlockStreamfield from './../../../components/BlockStreamfield/BlockStream
|
|
|
11
11
|
import BlockRelatedLinks from '../../../components/BlockRelatedLinks/BlockRelatedLinks.vue'
|
|
12
12
|
import NavJumpMenu from './../../../components/NavJumpMenu/NavJumpMenu.vue'
|
|
13
13
|
import HeroInlineMedia from './../../../components/HeroInlineMedia/HeroInlineMedia.vue'
|
|
14
|
+
import AboutTheAuthor from './../../../components/AboutTheAuthor/AboutTheAuthor.vue'
|
|
14
15
|
|
|
15
16
|
interface PageEduTeachableMomentProps {
|
|
16
17
|
data?: PageEduResourcesObject
|
|
@@ -66,10 +67,10 @@ const computedClass = computed((): string => {
|
|
|
66
67
|
:class="computedClass"
|
|
67
68
|
>
|
|
68
69
|
<NavJumpMenu
|
|
70
|
+
v-if="data.showJumpMenu"
|
|
69
71
|
ref="PageEduTeachableMomentJumpMenu"
|
|
70
72
|
:title="data.title"
|
|
71
73
|
:blocks="data.body"
|
|
72
|
-
:enabled="data.showJumpMenu"
|
|
73
74
|
dropdown-text="In this Teachable Moment"
|
|
74
75
|
/>
|
|
75
76
|
|
|
@@ -96,6 +97,7 @@ const computedClass = computed((): string => {
|
|
|
96
97
|
>
|
|
97
98
|
<DetailHeadline
|
|
98
99
|
:title="data.title"
|
|
100
|
+
:read-time="data.readTime"
|
|
99
101
|
label="Teachable Moment"
|
|
100
102
|
pill
|
|
101
103
|
/>
|
|
@@ -142,14 +144,12 @@ const computedClass = computed((): string => {
|
|
|
142
144
|
<BlockRelatedLinks :data="data.relatedLinks[0]" />
|
|
143
145
|
</LayoutHelper>
|
|
144
146
|
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
:items="data.relatedContent"
|
|
152
|
-
/>
|
|
147
|
+
<LayoutHelper
|
|
148
|
+
v-if="data.authors?.length"
|
|
149
|
+
indent="col-3"
|
|
150
|
+
>
|
|
151
|
+
<AboutTheAuthor :authors="data.authors" />
|
|
152
|
+
</LayoutHelper>
|
|
153
153
|
|
|
154
154
|
<LayoutHelper
|
|
155
155
|
v-if="data.lastPublishedAt"
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
<!-- facts -->
|
|
39
39
|
<BlockCardGrid
|
|
40
40
|
v-if="data.facts"
|
|
41
|
-
class="3xl:col-end-13 xl:col-end-11 md:px-4 lg:px-0 relative col-start-2 col-end-13 px-0 mt-12"
|
|
41
|
+
class="3xl:col-end-13 xl:col-end-11 md:px-4 lg:px-0 relative sm:col-start-2 sm:col-end-13 px-0 mt-12"
|
|
42
42
|
:cards="data.facts"
|
|
43
43
|
/>
|
|
44
44
|
</div>
|
package/src/utils/dayjs.js
CHANGED
|
@@ -2,6 +2,7 @@ import dayjs from 'dayjs'
|
|
|
2
2
|
import updateLocale from 'dayjs/plugin/updateLocale.js'
|
|
3
3
|
import localizedFormat from 'dayjs/plugin/localizedFormat.js'
|
|
4
4
|
import timezone from 'dayjs/plugin/timezone.js'
|
|
5
|
+
import utc from 'dayjs/plugin/utc.js'
|
|
5
6
|
import advancedFormat from 'dayjs/plugin/advancedFormat.js'
|
|
6
7
|
import duration from 'dayjs/plugin/duration.js'
|
|
7
8
|
import minMax from 'dayjs/plugin/minMax.js'
|
|
@@ -10,6 +11,7 @@ import minMax from 'dayjs/plugin/minMax.js'
|
|
|
10
11
|
import 'dayjs/locale/en-gb.js'
|
|
11
12
|
|
|
12
13
|
dayjs.extend(timezone)
|
|
14
|
+
dayjs.extend(utc)
|
|
13
15
|
dayjs.extend(advancedFormat)
|
|
14
16
|
dayjs.extend(localizedFormat)
|
|
15
17
|
dayjs.extend(updateLocale)
|
|
@@ -47,7 +47,7 @@ const rangeify = (a: number[]): string[] => {
|
|
|
47
47
|
return res
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
export const rangeifyGrades = (gradeLevels: GradeLevelsObject[]) => {
|
|
50
|
+
export const rangeifyGrades = (gradeLevels: GradeLevelsObject[], showLabel: boolean = true) => {
|
|
51
51
|
if (gradeLevels) {
|
|
52
52
|
const allAgesArray = gradeLevels.map((item) => {
|
|
53
53
|
if (item.gradeLevel === 'All Ages') return item.gradeLevel
|
|
@@ -65,7 +65,7 @@ export const rangeifyGrades = (gradeLevels: GradeLevelsObject[]) => {
|
|
|
65
65
|
if (filteredGrades?.length) {
|
|
66
66
|
const gradeString = filteredGrades.length > 0 ? 'Grades ' : 'Grade '
|
|
67
67
|
preparedGrades = filteredGrades
|
|
68
|
-
.map((grade, index) => (index === 0 ? gradeString + grade : grade))
|
|
68
|
+
.map((grade, index) => (index === 0 && showLabel ? gradeString + grade : grade))
|
|
69
69
|
.join(', ')
|
|
70
70
|
}
|
|
71
71
|
|