Skip to content

Commit

Permalink
chore(corel): add eslintrc change, remove progress icon and update ty…
Browse files Browse the repository at this point in the history
…pes (#7050)
  • Loading branch information
pedrobonamin authored Jul 2, 2024
1 parent eb48516 commit 0659c27
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 138 deletions.
10 changes: 10 additions & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,16 @@ const config = {
},
},

// Ignore i18n in releases files. TODO: Remove this before moving releases to GA.
{
files: ['**/*/core/releases/**/*'],
rules: {
'i18next/no-literal-string': 'off',
'@sanity/i18n/no-attribute-string-literals': 'off',
'@sanity/i18n/no-attribute-template-literals': 'off',
},
},

// Files to disable i18n literals,
{
files: ['./**/*/__workshop__/**/*', './dev/**/*', './examples/**/*', '**/*/debug/**/*'],
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/* eslint-disable @sanity/i18n/no-attribute-string-literals */
/* eslint-disable i18next/no-literal-string */
import {SearchIcon} from '@sanity/icons'
import {Button, Card, Flex, Stack, TextInput} from '@sanity/ui'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import {Box, Card, Flex, Stack, Text} from '@sanity/ui'
import {useRouter} from 'sanity/router'

import {type BundleDocument} from '../../../store/bundles/types'
import {VersionBadge} from '../../../versions/components/VersionBadge'
import {shortRelativeDate} from '../../utils/shortRelativeDate'
import {BundleIcon} from '../BundleIcon/BundleIcon'
import {BundleMenuButton} from '../BundleMenuButton/BundleMenuButton'

type Props = {
Expand All @@ -26,7 +26,7 @@ export function BundleRow({bundle}: Props) {
>
<Flex align="center" gap={2}>
<Box flex="none">
<BundleIcon tone={bundle.tone} icon={bundle.icon} />
<VersionBadge tone={bundle.tone} icon={bundle.icon} />
</Box>
<Stack flex={1} space={2}>
<Flex align="center" gap={2}>
Expand Down

This file was deleted.

2 changes: 0 additions & 2 deletions packages/sanity/src/core/releases/constants.ts

This file was deleted.

5 changes: 2 additions & 3 deletions packages/sanity/src/core/releases/plugin/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import {route} from 'sanity/router'

import {definePlugin} from '../../config'
import {TOOL_NAME, TOOL_TITLE} from '../constants'
import {ReleasesTool} from '../tool/ReleasesTool'

/**
Expand All @@ -17,8 +16,8 @@ export const releases = definePlugin({

tools: [
{
name: TOOL_NAME,
title: TOOL_TITLE,
name: 'releases',
title: 'Releases',
component: ReleasesTool,
router: route.create('/', [route.create('/:bundleId')]),
},
Expand Down
2 changes: 0 additions & 2 deletions packages/sanity/src/core/releases/tool/BundleDetail.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/* eslint-disable @sanity/i18n/no-attribute-string-literals */
/* eslint-disable i18next/no-literal-string */
import {ArrowLeftIcon, PublishIcon, StarIcon} from '@sanity/icons'
import {Box, Button, Card, Flex, Text} from '@sanity/ui'
import {useMemo, useState} from 'react'
Expand Down
2 changes: 0 additions & 2 deletions packages/sanity/src/core/releases/tool/BundlesOverview.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/* eslint-disable @sanity/i18n/no-attribute-string-literals */
/* eslint-disable i18next/no-literal-string */
import {AddIcon} from '@sanity/icons'
import {Box, Button, type ButtonMode, Card, Container, Flex, Heading, Stack, Text} from '@sanity/ui'
import {isBefore} from 'date-fns'
Expand Down
2 changes: 1 addition & 1 deletion packages/sanity/src/core/store/bundles/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ export interface BundleDocument extends SanityDocument {
tone?: ButtonTone
icon?: IconSymbol
authorId: string
publishedAt?: Date
publishedAt?: string
}
2 changes: 1 addition & 1 deletion packages/sanity/src/core/tasks/plugin/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const TASKS_NAME = 'sanity/tasks'
* @beta
*/
export const tasks = definePlugin({
name: 'sanity/tasks',
name: TASKS_NAME,
// eslint-disable-next-line camelcase
__internal_tasks: {
footerAction: <TasksFooterOpenTasks />,
Expand Down

0 comments on commit 0659c27

Please sign in to comment.