Skip to content

Commit

Permalink
feat: search-v2, part 2 (#101)
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuagraber authored Jan 2, 2025
2 parents b2f21ad + 8b0f125 commit c1a1356
Show file tree
Hide file tree
Showing 84 changed files with 4,119 additions and 575 deletions.
6 changes: 6 additions & 0 deletions .husky/post-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/usr/bin/env sh
[ -n "$CI" ] && exit 0

. "$(dirname -- "$0")/_/husky.sh"

npm run docs
2 changes: 1 addition & 1 deletion .husky/pre-push
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npm run docs && npm run test:ci
npm run test:ci
2 changes: 1 addition & 1 deletion commitlint.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
export default {
extends: ['@commitlint/config-conventional'],
rules: {
'footer-max-length': [2, 'never']
'footer-max-length': [0]
}
};
3 changes: 3 additions & 0 deletions docs/components.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
- [Form](../src/components/Form//README.md)
- [Header](../src/components/Header//README.md)
- [Input](../src/components/Input//README.md)
- [InputDatePicker](../src/components/InputDatePicker//README.md)
- [InputRadio](../src/components/InputRadio//README.md)
- [InputSelect](../src/components/InputSelect//README.md)
- [Nav](../src/components/Nav//README.md)
- [QuickSearchForm](../src/components/QuickSearchForm//README.md)
- [Spinner](../src/components/Spinner//README.md)
171 changes: 165 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
"@semantic-release/changelog": "^6.0.3",
"@semantic-release/git": "^10.0.1",
"@semantic-release/release-notes-generator": "^12.1.0",
"@types/lodash": "^4.17.13",
"@types/node": "^20.8.9",
"@typescript-eslint/eslint-plugin": "^6.9.1",
"@typescript-eslint/parser": "^6.9.1",
Expand Down Expand Up @@ -85,8 +86,14 @@
"vue-tsc": "^1.8.22"
},
"dependencies": {
"@fortawesome/fontawesome-svg-core": "^6.6.0",
"@fortawesome/free-brands-svg-icons": "^6.6.0",
"@fortawesome/free-regular-svg-icons": "^6.6.0",
"@fortawesome/free-solid-svg-icons": "^6.6.0",
"@fortawesome/vue-fontawesome": "^3.0.8",
"@vuelidate/core": "^2.0.3",
"@vuelidate/validators": "^2.0.4",
"@vuepic/vue-datepicker": "^10.0.0",
"fs-extra": "^11.1.1",
"happy-dom": "^6.0.4",
"minimist": "^1.2.8",
Expand Down
4 changes: 2 additions & 2 deletions scripts/update-docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ done

# create a commit, only if there are changes
if git diff --quiet docs/$output_file; then
echo -e "No new component README files detected.\nProceeding with push"
echo -e "No new component README files detected.\nNo new commit will be created."
exit 0
else
commit_msg="chore(docs): auto-update to component docs"

echo "New README files detected, committing updated docs/$output_file file..."
git add docs/$output_file && git commit -m "$commit_msg" --no-verify && echo "Commit finished, proceeding with push"
git add docs/$output_file && git commit -m "$commit_msg" --no-verify && echo "Updated documentation added to the TOC in \`docs/components.md\` and committed."
fi
18 changes: 17 additions & 1 deletion src/components/Button/PdapButton.vue
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
<template>
<button :class="classes">
<slot />
<slot v-if="!isLoading" />
<Spinner v-if="isLoading" :show="isLoading" />
</button>
</template>

<script setup lang="ts">
// Imports
import { reactive } from 'vue';
import { Spinner } from '../Spinner';
// Types
import { PdapButtonProps } from './types';
Expand Down Expand Up @@ -74,3 +76,17 @@ export default {
}
}
</style>

<style scoped>
@media (prefers-reduced-motion: no-preference) {
.v-enter-active,
.v-leave-active {
transition: opacity 0.5s ease;
}
.v-enter-from,
.v-leave-to {
opacity: 0;
}
}
</style>
6 changes: 5 additions & 1 deletion src/components/Button/__snapshots__/button.spec.ts.snap
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html

exports[`Renders button component > Renders a button 1`] = `<button class="pdap-button pdap-button-primary">Button Content</button>`;
exports[`Renders button component > Renders a button 1`] = `
<button class="pdap-button pdap-button-primary">Button Content
<!--v-if-->
</button>
`;
Loading

0 comments on commit c1a1356

Please sign in to comment.