-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* reorganizing search result cards in stories, adding search result list to stories * more organization of cards in stories * moving calendar chip to a component and adapting other components to use it instead of duplicated code * adding event metadata to BlockLinkCard * adding MetadateEduResource component, renaming EventMetadata to MetadataEvent * finished adding metadata to blocklinkcard for resources * fixing minor type errors, adding word 'Grades' to rangeifyGrades method * adding icons needed for resource metadata * fixing build errors * updating SearchResultCard * finish search cards * fixing tags in listing hero pages to match pill strategy * fixing accessibility and smoke tests * lint * fixes from visual regression testing
- Loading branch information
1 parent
857b23a
commit 6ca65fa
Showing
40 changed files
with
2,575 additions
and
515 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.IconProfile { | ||
width: 1em; | ||
height: 1em; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.IconSubject { | ||
width: 1em; | ||
height: 1em; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
...src/components/BaseTag/BaseTag.stories.js → ...c/components/BasePill/BasePill.stories.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
<script setup lang="ts"> | ||
import { computed } from 'vue' | ||
import type { Attributes } from './../../interfaces' | ||
import { eduMetadataDictionary } from './../../constants' | ||
// using borders to vertically center wonky font face | ||
const variantMap: Attributes = { | ||
primary: 'bg-primary border-primary', | ||
secondary: 'bg-secondary border-secondary', | ||
action: 'bg-action border-action' | ||
} | ||
const sizeMap: Attributes = { | ||
sm: 'text-xs border-t-2 py-1 px-2.5', | ||
md: 'text-xs lg:text-base border-t py-1.5 px-3.5', | ||
lg: 'text-base lg:text-lg border-t pt-1.5 pb-1 px-5' | ||
} | ||
interface BasePillProps { | ||
variant?: string | ||
size?: string | ||
contentType?: string | ||
} | ||
// define props | ||
const props = withDefaults(defineProps<BasePillProps>(), { | ||
variant: 'primary', | ||
size: 'md', | ||
contentType: undefined | ||
}) | ||
const metadataType = computed(() => { | ||
const validContentTypes = Object.keys(eduMetadataDictionary) | ||
return props.contentType && validContentTypes.includes(props.contentType) | ||
? props.contentType | ||
: undefined | ||
}) | ||
const metadataAttrs = computed(() => { | ||
if (metadataType.value) { | ||
return eduMetadataDictionary[metadataType.value] | ||
} | ||
return { variant: undefined, label: undefined } | ||
}) | ||
</script> | ||
<template> | ||
<p | ||
:class="`${variantMap[metadataAttrs.variant || props.variant]} ${sizeMap[props.size]}`" | ||
class="ThemeVariantLight text-contrast-none inline-block text-white font-bold edu:font-extrabold rounded-full leading-tight m-0 uppercase print:border-none print:px-0" | ||
> | ||
<template v-if="metadataAttrs.label"> {{ metadataAttrs.label }} </template> | ||
<template v-else> <slot /></template> | ||
<span class="sr-only">.</span> | ||
</p> | ||
</template> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.