-
-
Notifications
You must be signed in to change notification settings - Fork 95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: implmenet a use defaults system WIP fixes #1607 #1889
Conversation
…es instead fix(BTable): selectedItems not clearing values properly fixes bootstrap-vue-next#1878 fix(BTable): selectedItems with range not displaying class test(BTableLite): toggle details functionality test(BTable): selectedItems functioanlity
feat: implement global alias system fixes bootstrap-vue-next#1753 refactor: add bvn:: prefix to symbol keys refactor: fix typo in 'BCardImageProps' change to 'BCardImgProps'
Run & review this pull request in StackBlitz Codeflow. |
Also need to write docs for this section |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remember to revert main.ts
Just heading to sleep. 5min look seems nice. I'll have time next week to look at this and other stuff. Should we add the handeling of modelValue to useDefaults? pass emit to it, revert back to vueuse style handeling of it... Just an idea, not really sure about it. |
There are some examples of how its used. Its a bit strange code, all boilerplate. But its just a computed setter. |
@xvaara Something that I didn't think about is the fact that we don't know whether or not the modelvalue is bound. This causes a problem: const props = useDefaults<typeof _props>(_props, 'BAccordion')
const _modelValue = defineModel<string | undefined>({
default: undefined,
})
const modelValue = computed({
get: () => props.modelValue,
set: (v) => {
_modelValue.value = v
},
}) When we bind to props.modelValue when it's using the "passive" version of the modelValue, it's then bound to the wrong value. <BAccordion /> This won't work, because internally its supposed to be using the ref. However, since we bounded to the props, it fails. I'm not sure if there's a way to detect this (I don't think there is). Meaning, I think we may just have to refuse global options for modelValues |
…. Modifiers should behave more like native Vue modifiers (number modifier with unparseable value returns value as is) feat(BFormInput): type number performs the same as modifier feat(BCarouselSlide): allow individual interval for slides feat: global options system chore: update deps to fix some issues (nuxt useId, vue-tsc etc)
packages/bootstrap-vue-next/src/components/BAccordion/BAccordion.vue
Outdated
Show resolved
Hide resolved
feat: implement a use defaults system fixes #1607 feat: implement global alias system fixes #1753 refactor: add bvn:: prefix to symbol keys refactor: fix typo in 'BCardImageProps' change to 'BCardImgProps' feat(BFormInput)!: move props lazy, trim & number to v-model modifier. Modifiers should behave more like native Vue modifiers (number modifier with unparseable value returns value as is) feat(BFormInput): type number performs the same as modifier feat(BCarouselSlide): allow individual interval for slides chore: update deps to fix some issues (nuxt useId, vue-tsc etc) docs: global options, aliases feat(nuxt): automatically globally set teleportTo to feat(BreakpointProps)!: strongly type breakpoints. Instead of weak string | number => 1,2,3...'1','2','3'... refactor(BRow): use script setup instead of options api refactor(BCol): use script setup instead of options api |
* upstream/main: (23 commits) feat(BInput): Alias BFormInput to BInput fix(nuxt): dont teleport everything to #teleports -- selectively teleport based on body fixes bootstrap-vue-next#1898 chore: release main feat(nuxt): allow passthrough options to createBootstrap plugin chore: release main (bootstrap-vue-next#1894) feat: implmenet a use defaults system WIP fixes bootstrap-vue-next#1607 (bootstrap-vue-next#1889) docs(BCheckBox*): Small changes to get documentation to parity (bootstrap-vue-next#1873) docs: Add component reference link in the page table of contents sidebar fixed BTableLite item _showDetails BTable delete selection when primary-key chore: release main feat(BTable): add change event -- replaces bv `modelValue` see bootstrap-vue-next#1775 (comment) chore: release main fix(BTable): selectedItems not clearing values properly fixes bootstrap-vue-next#1878 (bootstrap-vue-next#1879) chore: release main (bootstrap-vue-next#1874) fix(BTable): Pass through original records to slots in most circumstances (bootstrap-vue-next#1869) chore: release main (bootstrap-vue-next#1867) feat(BTable): Allow dot in sortby key fix: update dependencies to fix a bug in vue compiler (bootstrap-vue-next#1866) chore: release main (bootstrap-vue-next#1859) ...
… (bootstrap-vue-next#1889) feat: implement a use defaults system fixes bootstrap-vue-next#1607 feat: implement global alias system fixes bootstrap-vue-next#1753 refactor: add bvn:: prefix to symbol keys refactor: fix typo in 'BCardImageProps' change to 'BCardImgProps' feat(BFormInput)!: move props lazy, trim & number to v-model modifier. Modifiers should behave more like native Vue modifiers (number modifier with unparseable value returns value as is) feat(BFormInput): type number performs the same as modifier feat(BCarouselSlide): allow individual interval for slides chore: update deps to fix some issues (nuxt useId, vue-tsc etc) docs: global options, aliases feat(nuxt): automatically globally set teleportTo to `#teleports` feat(BreakpointProps)!: strongly type breakpoints. Instead of weak string | number => 1,2,3...'1','2','3'... refactor(BRow): use script setup instead of options api refactor(BCol): use script setup instead of options api
Describe the PR
A clear and concise description of what the pull request does.
Small replication
A small replication or video walkthrough can help demonstrate the changes made. This is optional, but can help observe the intended changes. A mentioned issue that contains a replication also works.
PR checklist
What kind of change does this PR introduce? (check at least one)
fix(...)
feat(...)
fix(...)
docs(...)
The PR fulfills these requirements:
CHANGELOG
is generated from these messages, and determines the next version type. Pull requests that do not follow conventional commits or do not have an override will be denied