Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 28 additions & 12 deletions eslint.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,19 @@ export default defineConfig([
'@intlify/vue-i18n/no-raw-text': [
'error',
{
attributes: {
'/.+/': [
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[performance] medium Priority

Issue: Potentially inefficient regex pattern /.+/ used for all element attributes
Context: The pattern /.+/ will match every element in the Vue templates, which could slow down linting on large components with many elements
Suggestion: Consider using more specific element patterns or grouping common attributes to avoid the catch-all regex that processes every single element

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If only...
But we could split this and some other slow rules out to a dedicated config (later).

'aria-label',
'aria-placeholder',
'aria-roledescription',
'aria-valuetext',
'label',
'placeholder',
'title',
'v-tooltip'
],
img: ['alt']
},
// Ignore strings that are:
// 1. Less than 2 characters
// 2. Only symbols/numbers/whitespace (no letters)
Expand All @@ -200,24 +213,27 @@ export default defineConfig([
ignoreNodes: ['md-icon', 'v-icon', 'pre', 'code', 'script', 'style'],
// Brand names and technical terms that shouldn't be translated
ignoreText: [
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[quality] low Priority

Issue: Inconsistent ordering in ignoreText array
Context: The array mixes different categories (file formats, units, brand names) without clear organization, making it harder to maintain
Suggestion: Consider grouping related items (units: GB/KB/MB/ms/px, formats: png/JSON/YAML, brands: ComfyUI/GitHub/OpenAI) or adding comments to document the organization

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's alphabetical, except for 1.2 MB

'ComfyUI',
'GitHub',
'OpenAI',
'API',
'URL',
'JSON',
'YAML',
'GPU',
'App Data:',
'App Path:',
'ComfyUI',
'CPU',
'RAM',
'fps',
'GB',
'MB',
'GitHub',
'GPU',
'JSON',
'KB',
'LoRA',
'MB',
'ms',
'fps',
'OpenAI',
'png',
'px',
'App Data:',
'App Path:'
'RAM',
'URL',
'YAML',
'1.2 MB'
]
}
]
Expand Down
2 changes: 1 addition & 1 deletion src/components/maskeditor/BrushSettingsPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
/>

<SliderControl
label="Stepsize"
:label="$t('maskEditor.stepSize')"
:min="1"
:max="100"
:step="1"
Expand Down
6 changes: 5 additions & 1 deletion src/components/queue/CompletionSummaryBanner.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,11 @@
class="inline-block h-6 w-6 overflow-hidden rounded-[6px] border-0 bg-secondary-background"
:style="{ marginLeft: idx === 0 ? '0' : '-12px' }"
>
<img :src="url" alt="preview" class="h-full w-full object-cover" />
<img
:src="url"
:alt="$t('sideToolbar.queueProgressOverlay.preview')"
class="h-full w-full object-cover"
/>
</span>
</span>

Expand Down
10 changes: 5 additions & 5 deletions src/components/widget/SampleModelSelector.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
<template #default="{ close }">
<IconTextButton
type="secondary"
label="Settings"
:label="$t('g.settings')"
@click="
() => {
close()
Expand All @@ -43,7 +43,7 @@
</IconTextButton>
<IconTextButton
type="primary"
label="Profile"
:label="$t('g.profile')"
@click="
() => {
close()
Expand All @@ -65,20 +65,20 @@
v-model="selectedFrameworks"
v-model:search-query="searchText"
class="w-[250px]"
label="Select Frameworks"
:label="$t('assetBrowser.selectFrameworks')"
:options="frameworkOptions"
:show-search-box="true"
:show-selected-count="true"
:show-clear-button="true"
/>
<MultiSelect
v-model="selectedProjects"
label="Select Projects"
:label="$t('assetBrowser.selectProjects')"
:options="projectOptions"
/>
<SingleSelect
v-model="selectedSort"
label="Sorting Type"
:label="$t('assetBrowser.sortingType')"
:options="sortOptions"
class="w-[135px]"
>
Expand Down
13 changes: 12 additions & 1 deletion src/locales/en/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@
"dropYourFileOr": "Drop your file or",
"back": "Back",
"next": "Next",
"submit": "Submit",
"install": "Install",
"installing": "Installing",
"overwrite": "Overwrite",
Expand Down Expand Up @@ -234,6 +235,7 @@
"frameNodes": "Frame Nodes",
"listening": "Listening...",
"ready": "Ready",
"playPause": "Play/Pause",
"playRecording": "Play Recording",
"playing": "Playing",
"stopPlayback": "Stop Playback",
Expand All @@ -242,7 +244,9 @@
"halfSpeed": "0.5x",
"1x": "1x",
"2x": "2x",
"beta": "BETA"
"beta": "BETA",
"profile": "Profile",
"noItems": "No items"
},
"manager": {
"title": "Custom Nodes Manager",
Expand Down Expand Up @@ -689,6 +693,7 @@
"currentNode": "Current node:",
"viewAllJobs": "View all jobs",
"running": "running",
"preview": "Preview",
"interruptAll": "Interrupt all running jobs",
"moreOptions": "More options",
"showAssets": "Show assets",
Expand Down Expand Up @@ -930,6 +935,7 @@
"thickness": "Thickness",
"opacity": "Opacity",
"hardness": "Hardness",
"stepSize": "Step Size",
"smoothingPrecision": "Smoothing Precision",
"resetToDefault": "Reset to Default",
"paintBucketSettings": "Paint Bucket Settings",
Expand Down Expand Up @@ -1835,6 +1841,7 @@
"title": "Subscription",
"titleUnsubscribed": "Subscribe to Comfy Cloud",
"comfyCloud": "Comfy Cloud",
"comfyCloudLogo": "Comfy Cloud Logo",
"beta": "BETA",
"perMonth": "USD / month",
"renewsDate": "Renews {date}",
Expand Down Expand Up @@ -2070,6 +2077,7 @@
"cloudSurvey_steps_making": "What do you plan on making?",
"assetBrowser": {
"assets": "Assets",
"assetCollection": "Asset collection",
"checkpoints": "Checkpoints",
"browseAssets": "Browse Assets",
"noAssetsFound": "No assets found",
Expand Down Expand Up @@ -2120,6 +2128,9 @@
"sortZA": "Z-A",
"sortRecent": "Recent",
"sortPopular": "Popular",
"selectFrameworks": "Select Frameworks",
"selectProjects": "Select Projects",
"sortingType": "Sorting Type",
"errorFileTooLarge": "File exceeds the maximum allowed size limit",
"errorFormatNotAllowed": "Only SafeTensor format is allowed",
"errorUnsafePickleScan": "CivitAI detected potentially unsafe code in this file",
Expand Down
2 changes: 1 addition & 1 deletion src/platform/assets/components/AssetGrid.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
data-component-id="AssetGrid"
:style="gridStyle"
role="grid"
aria-label="Asset collection"
:aria-label="$t('assetBrowser.assetCollection')"
:aria-rowcount="-1"
:aria-colcount="-1"
:aria-setsize="assets.length"
Expand Down
18 changes: 11 additions & 7 deletions src/platform/assets/components/MediaAssetMoreMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<IconTextButton
v-if="asset?.kind !== '3D'"
type="transparent"
label="Inspect asset"
:label="$t('queue.jobMenu.inspectAsset')"
@click="handleInspect"
>
<template #icon>
Expand All @@ -17,15 +17,19 @@
<IconTextButton
v-if="showAddToWorkflow"
type="transparent"
label="Add to current workflow"
:label="$t('queue.jobMenu.addToCurrentWorkflow')"
@click="handleAddToWorkflow"
>
<template #icon>
<i class="icon-[comfy--node] size-4" />
</template>
</IconTextButton>

<IconTextButton type="transparent" label="Download" @click="handleDownload">
<IconTextButton
type="transparent"
:label="$t('queue.jobMenu.download')"
@click="handleDownload"
>
<template #icon>
<i class="icon-[lucide--download] size-4" />
</template>
Expand All @@ -36,7 +40,7 @@
<IconTextButton
v-if="showWorkflowActions"
type="transparent"
label="Open as workflow in new tab"
:label="$t('queue.jobMenu.openAsWorkflowNewTab')"
@click="handleOpenWorkflow"
>
<template #icon>
Expand All @@ -47,7 +51,7 @@
<IconTextButton
v-if="showWorkflowActions"
type="transparent"
label="Export workflow"
:label="$t('queue.jobMenu.exportWorkflow')"
@click="handleExportWorkflow"
>
<template #icon>
Expand All @@ -60,7 +64,7 @@
<IconTextButton
v-if="showCopyJobId"
type="transparent"
label="Copy job ID"
:label="$t('queue.jobMenu.copyJobId')"
@click="handleCopyJobId"
>
<template #icon>
Expand All @@ -73,7 +77,7 @@
<IconTextButton
v-if="shouldShowDeleteButton"
type="transparent"
label="Delete"
:label="$t('queue.jobMenu.delete')"
@click="handleDelete"
>
<template #icon>
Expand Down
22 changes: 13 additions & 9 deletions src/platform/cloud/onboarding/CloudSurveyView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
<div class="flex justify-between pt-4">
<span />
<Button
label="Next"
:label="$t('g.next')"
:disabled="!validStep1"
class="h-10 w-full border-none text-white"
@click="goTo(2, activateCallback)"
Expand Down Expand Up @@ -84,20 +84,22 @@
<InputText
v-model="surveyData.useCaseOther"
class="w-full"
placeholder="Please specify"
:placeholder="
$t('cloudOnboarding.survey.options.industry.otherPlaceholder')
"
/>
</div>
</div>

<div class="flex gap-6 pt-4">
<Button
label="Back"
:label="$t('g.back')"
severity="secondary"
class="flex-1 text-white"
@click="goTo(1, activateCallback)"
/>
<Button
label="Next"
:label="$t('g.next')"
:disabled="!validStep2"
class="h-10 flex-1 text-white"
@click="goTo(3, activateCallback)"
Expand Down Expand Up @@ -137,20 +139,22 @@
<InputText
v-model="surveyData.industryOther"
class="w-full"
placeholder="Please specify"
:placeholder="
$t('cloudOnboarding.survey.options.industry.otherPlaceholder')
"
/>
</div>
</div>

<div class="flex gap-6 pt-4">
<Button
label="Back"
:label="$t('g.back')"
severity="secondary"
class="flex-1 text-white"
@click="goTo(2, activateCallback)"
/>
<Button
label="Next"
:label="$t('g.next')"
:disabled="!validStep3"
class="h-10 flex-1 border-none text-white"
@click="goTo(4, activateCallback)"
Expand Down Expand Up @@ -189,13 +193,13 @@

<div class="flex gap-6 pt-4">
<Button
label="Back"
:label="$t('g.back')"
severity="secondary"
class="flex-1 text-white"
@click="goTo(3, activateCallback)"
/>
<Button
label="Submit"
:label="$t('g.submit')"
:disabled="!validStep4 || isSubmitting"
:loading="isSubmitting"
class="h-10 flex-1 border-none text-white"
Expand Down
2 changes: 1 addition & 1 deletion src/platform/cloud/onboarding/components/CloudLogo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<div class="mx-auto flex h-[7%] max-h-[70px] w-5/6 items-end">
<img
src="/assets/images/comfy-cloud-logo.svg"
alt="Comfy Cloud Logo"
:alt="$t('subscription.comfyCloudLogo')"
class="h-3/4 max-h-10 w-auto"
/>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<div
role="button"
:tabindex="0"
aria-label="Play/Pause"
:aria-label="$t('g.playPause')"
class="flex size-6 cursor-pointer items-center justify-center rounded hover:bg-interface-menu-component-surface-hovered"
@click="togglePlayPause"
>
Expand Down Expand Up @@ -64,7 +64,7 @@
<div
role="button"
:tabindex="0"
aria-label="Volume"
:aria-label="$t('g.volume')"
class="flex size-6 cursor-pointer items-center justify-center rounded hover:bg-interface-menu-component-surface-hovered"
@click="toggleMute"
>
Expand All @@ -85,7 +85,7 @@
ref="optionsButtonRef"
role="button"
:tabindex="0"
aria-label="More Options"
:aria-label="$t('g.moreOptions')"
class="flex size-6 cursor-pointer items-center justify-center rounded hover:bg-interface-menu-component-surface-hovered"
@click="toggleOptionsMenu"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ const searchQuery = defineModel<string>('searchQuery')
class="absolute inset-0 flex items-center justify-center"
>
<i
title="No items"
:title="$t('g.noItems')"
class="icon-[lucide--circle-off] size-30 text-zinc-500/20"
/>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ function handleSortSelected(item: SortOption) {
v-model="searchQuery"
type="text"
:class="resetInputStyle"
placeholder="Search"
:placeholder="$t('g.search')"
/>
</label>

Expand Down
Loading
Loading