style(projects): format code

This commit is contained in:
Soybean
2023-12-14 21:45:29 +08:00
parent a176dc443e
commit a748166399
127 changed files with 2472 additions and 3006 deletions

View File

@ -4,24 +4,21 @@ import { Icon } from '@iconify/vue';
defineOptions({ name: 'SvgIcon' });
const props = defineProps<Props>();
/**
* props
* - support iconify and local svg icon
* - if icon and localIcon are passed at the same time, localIcon will be rendered first
* Props
*
* - Support iconify and local svg icon
* - If icon and localIcon are passed at the same time, localIcon will be rendered first
*/
interface Props {
/**
* iconify icon name
*/
/** Iconify icon name */
icon?: string;
/**
* local svg icon name
*/
/** Local svg icon name */
localIcon?: string;
}
const props = defineProps<Props>();
const attrs = useAttrs();
const bindAttrs = computed<{ class: string; style: string }>(() => ({
@ -39,9 +36,7 @@ const symbolId = computed(() => {
return `#${prefix}-${icon}`;
});
/**
* if localIcon is passed, render localIcon first
*/
/** If localIcon is passed, render localIcon first */
const renderLocalIcon = computed(() => props.localIcon || !props.icon);
</script>