mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 01:56:46 +00:00
feat(editor): Update icons to Lucide icons (#16231)
Co-authored-by: Mutasem Aldmour <mutasem@n8n.io>
This commit is contained in:
@@ -1,11 +1,8 @@
|
||||
<script setup lang="ts">
|
||||
import { computed } from 'vue';
|
||||
import { useI18n } from '@n8n/i18n';
|
||||
import {
|
||||
type Project,
|
||||
type ProjectIcon as ProjectIconType,
|
||||
ProjectTypes,
|
||||
} from '@/types/projects.types';
|
||||
import { type Project, ProjectTypes } from '@/types/projects.types';
|
||||
import { isIconOrEmoji, type IconOrEmoji } from '@n8n/design-system/components/N8nIconPicker/types';
|
||||
|
||||
type Props = {
|
||||
currentProject: Project;
|
||||
@@ -23,13 +20,15 @@ const emit = defineEmits<{
|
||||
|
||||
const i18n = useI18n();
|
||||
|
||||
const projectIcon = computed((): ProjectIconType => {
|
||||
const projectIcon = computed((): IconOrEmoji => {
|
||||
if (props.currentProject?.type === ProjectTypes.Personal) {
|
||||
return { type: 'icon', value: 'user' };
|
||||
} else if (props.currentProject?.name) {
|
||||
return props.currentProject.icon ?? { type: 'icon', value: 'layer-group' };
|
||||
return isIconOrEmoji(props.currentProject.icon)
|
||||
? props.currentProject.icon
|
||||
: { type: 'icon', value: 'layers' };
|
||||
} else {
|
||||
return { type: 'icon', value: 'home' };
|
||||
return { type: 'icon', value: 'house' };
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user