Skip to content

Commit

Permalink
Merge branch 'main' into UI-367
Browse files Browse the repository at this point in the history
  • Loading branch information
GhitaNektt committed Jun 14, 2024
2 parents 1553414 + 82ed487 commit c7fda77
Show file tree
Hide file tree
Showing 12 changed files with 207 additions and 31 deletions.
9 changes: 9 additions & 0 deletions bump.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
export default {
files: [
'package.json',
'packages/core/package.json',
'packages/icons/package.json',
'packages/visuals/package.json',
'packages/vue3/package.json',
],
};
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@youcan/ui",
"version": "2.6.5",
"version": "2.6.7",
"packageManager": "[email protected]",
"engines": {
"node": "^20.9.0",
Expand All @@ -14,11 +14,11 @@
"lint": "pnpm eslint && pnpm stylelint",
"lint:fix": "pnpm eslint --fix && pnpm stylelint --fix",
"prepare": "pnpm -r run stub",
"release": "pnpm build && bumpp package.json packages/*/package.json --commit \"[chore]: Release v\" --push --tag && pnpm -r release"
"release": "pnpm build && bumpp --commit \"[chore]: Release v\" --push --tag && pnpm -r release"
},
"devDependencies": {
"@youcan/eslint-config": "2.5.6-beta.7",
"bumpp": "^8.2.1",
"bumpp": "^9.4.1",
"eslint": "^8.33.0",
"mitata": "^0.1.6",
"postcss-html": "^1.5.0",
Expand Down
17 changes: 16 additions & 1 deletion packages/alto/src/components/Color/ColorInput.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import { nextTick, ref } from 'vue';
import { nextTick, onMounted, onUnmounted, ref } from 'vue';
import { onClickOutside } from '@vueuse/core';
import type { ColorInputProps } from './types';
import { ColorPicker } from '~/components';
Expand Down Expand Up @@ -38,7 +38,22 @@ function toggle(override = !show.value) {
function updateModelValue(value: string) {
emit('update:modelValue', value);
}
function handleScroll() {
if (show.value) {
show.value = false;
}
}
onClickOutside(picker, () => toggle(false));
onMounted(() => {
window.addEventListener('scroll', handleScroll);
});
onUnmounted(() => {
window.removeEventListener('scroll', handleScroll);
});
</script>

<template>
Expand Down
8 changes: 8 additions & 0 deletions packages/alto/src/components/Dropdown/Dropdown.vue
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,15 @@ function setItems(items: DropdownValue[]) {
itemsList.value = Array.isArray(items) ? items : [];
}
function handleWindowScroll() {
if (show.value) {
show.value = false;
}
}
onMounted(() => {
window.addEventListener('resize', handleResize);
window.addEventListener('scroll', handleWindowScroll);
dropdown.value?.addEventListener('keydown', handleKeypress);
Expand All @@ -278,6 +285,7 @@ onMounted(() => {
onUnmounted(() => {
window.removeEventListener('resize', handleResize);
window.removeEventListener('keydown', handleKeypress);
window.removeEventListener('scroll', handleWindowScroll);
});
watch(() => props.items, (newValue) => {
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@youcan/ui-core",
"type": "module",
"version": "2.6.5",
"version": "2.6.7",
"description": "",
"author": "YouCan <[email protected]> (https://github.com/youcan-shop/)",
"homepage": "https://github.com/youcan-shop/youcan-ui",
Expand Down
2 changes: 1 addition & 1 deletion packages/icons/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@youcan/ui-icons",
"type": "module",
"version": "2.6.5",
"version": "2.6.7",
"description": "YouCan icon set in Iconify JSON format",
"author": "YouCan <[email protected]> (https://github.com/youcan-shop/)",
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion packages/visuals/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@youcan/ui-visuals",
"type": "module",
"version": "2.6.5",
"version": "2.6.7",
"description": "YouCan visuals set in Iconify JSON format",
"author": "YouCan <[email protected]> (https://github.com/youcan-shop/)",
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion packages/vue3/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@youcan/ui-vue3",
"version": "2.6.5",
"version": "2.6.7",
"description": "YouCan Vue3 components library",
"author": "YouCan <[email protected]> (https://github.com/youcan-shop/)",
"license": "MIT",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ function handleCheck(e: Event) {
<style scoped>
.resource {
display: flex;
justify-content: start;
justify-content: flex-start;
padding: 0 16px;
transition: background-color 0.3s;
border-bottom: var(--border);
Expand Down
2 changes: 1 addition & 1 deletion packages/vue3/src/components/Skeleton/Skeleton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ withDefaults(
flex-direction: column;
width: 100%;
row-gap: 15px;
justify-items: start;
justify-items: flex-start;
}
.pulse {
Expand Down
2 changes: 1 addition & 1 deletion packages/vue3/src/components/Table/Table.vue
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ function selectRow(index: number, data: boolean) {
display: flex;
box-sizing: border-box;
align-items: center;
justify-content: start;
justify-content: flex-start;
width: 100%;
overflow: auto hidden;
}
Expand Down
Loading

0 comments on commit c7fda77

Please sign in to comment.