Skip to content

Commit 6365936

Browse files
deiningdelucis
andauthored
Fixing typos (#3528)
Co-authored-by: Chris Swithinbank <[email protected]>
1 parent 7dafc44 commit 6365936

File tree

11 files changed

+23
-23
lines changed

11 files changed

+23
-23
lines changed

packages/file-icons-generator/config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export const seti = {
2323
less: 'json',
2424
},
2525
/**
26-
* Seti UI icons can be overriden to use another Seti UI icon.
26+
* Seti UI icons can be overridden to use another Seti UI icon.
2727
* The key is the icon name to override and the value is the Seti icon name to use instead.
2828
* The reason to support aliasing to another Seti UI icon is that some Seti UI icons can be
2929
* almost identical. For example, the `npm_ignored` icon used for `npm-debug.log` files is

packages/starlight/__e2e__/basics.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ test.describe('components', () => {
128128
expect((await tabs.boundingBox())?.y).toBe(initialBoundingBox?.y);
129129
});
130130

131-
test('syncs tabs with the same sync key if they do not consistenly use icons', async ({
131+
test('syncs tabs with the same sync key if they do not consistently use icons', async ({
132132
page,
133133
getProdServer,
134134
}) => {

packages/starlight/__tests__/basics/i18n.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ describe('processI18nConfig', () => {
6161
)
6262
).toThrowErrorMatchingInlineSnapshot(`
6363
"[AstroUserError]:
64-
Failed to get locale informations for the 'foo' locale.
64+
Failed to get locale information for the 'foo' locale.
6565
Hint:
6666
Make sure to provide a valid BCP-47 tags (e.g. en, ar, or zh-CN)."
6767
`);

packages/starlight/__tests__/i18n/translations-ec.test.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ test('adds default english translations with no i18n config', () => {
2424

2525
addTranslations(config, useTranslations);
2626

27-
expect(getExpressiveCodeOverridenLanguages()).toEqual(['en']);
27+
expect(getExpressiveCodeOverriddenLanguages()).toEqual(['en']);
2828
});
2929

3030
test('adds translations in a monolingual site with english as root locale', () => {
@@ -34,7 +34,7 @@ test('adds translations in a monolingual site with english as root locale', () =
3434

3535
addTranslations(config, useTranslations);
3636

37-
expect(getExpressiveCodeOverridenLanguages()).toEqual(['en']);
37+
expect(getExpressiveCodeOverriddenLanguages()).toEqual(['en']);
3838
});
3939

4040
test('adds translations in a monolingual site with french as root locale', () => {
@@ -44,7 +44,7 @@ test('adds translations in a monolingual site with french as root locale', () =>
4444

4545
addTranslations(config, useTranslations);
4646

47-
expect(getExpressiveCodeOverridenLanguages()).toEqual(['fr']);
47+
expect(getExpressiveCodeOverriddenLanguages()).toEqual(['fr']);
4848
});
4949

5050
test('add translations in a multilingual site with english as root locale', () => {
@@ -55,7 +55,7 @@ test('add translations in a multilingual site with english as root locale', () =
5555

5656
addTranslations(config, useTranslations);
5757

58-
expect(getExpressiveCodeOverridenLanguages()).toEqual(['en', 'fr']);
58+
expect(getExpressiveCodeOverriddenLanguages()).toEqual(['en', 'fr']);
5959
});
6060

6161
test('add translations in a multilingual site with french as root locale', () => {
@@ -66,7 +66,7 @@ test('add translations in a multilingual site with french as root locale', () =>
6666

6767
addTranslations(config, useTranslations);
6868

69-
expect(getExpressiveCodeOverridenLanguages()).toEqual(['fr', 'ru']);
69+
expect(getExpressiveCodeOverriddenLanguages()).toEqual(['fr', 'ru']);
7070
});
7171

7272
test('add translations in a multilingual site with english as default locale', () => {
@@ -80,7 +80,7 @@ test('add translations in a multilingual site with english as default locale', (
8080

8181
addTranslations(config, useTranslations);
8282

83-
expect(getExpressiveCodeOverridenLanguages()).toEqual(['en', 'fr']);
83+
expect(getExpressiveCodeOverriddenLanguages()).toEqual(['en', 'fr']);
8484
});
8585

8686
test('add translations in a multilingual site with french as default locale', () => {
@@ -94,7 +94,7 @@ test('add translations in a multilingual site with french as default locale', ()
9494

9595
addTranslations(config, useTranslations);
9696

97-
expect(getExpressiveCodeOverridenLanguages()).toEqual(['fr', 'ru']);
97+
expect(getExpressiveCodeOverriddenLanguages()).toEqual(['fr', 'ru']);
9898
});
9999

100100
test('does not add translations if the label does not exist', () => {
@@ -125,6 +125,6 @@ function getStarlightConfigAndUseTranslations(
125125
] as const;
126126
}
127127

128-
function getExpressiveCodeOverridenLanguages() {
128+
function getExpressiveCodeOverriddenLanguages() {
129129
return [...new Set(vi.mocked(pluginFramesTexts.overrideTexts).mock.calls.map(([lang]) => lang))];
130130
}

packages/starlight/__tests__/plugins/translations.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ describe('can access UI string in an Astro context', () => {
1717
expect(t).toBeTypeOf('function');
1818
// Include the default locale strings.
1919
expect(t('skipLink.label')).toBe('Skip to content');
20-
// Include a built-in translation overriden by a plugin.
20+
// Include a built-in translation overridden by a plugin.
2121
expect(t('search.label')).toBe('Search the thing');
2222
// Include a translation injected by a plugin.
2323
// @ts-expect-error - translation key injected by a test plugin.
@@ -28,7 +28,7 @@ describe('can access UI string in an Astro context', () => {
2828
const t = useTranslations('fr');
2929
// Include the default locale strings.
3030
expect(t('skipLink.label')).toBe('Aller au contenu');
31-
// Include a built-in translation overriden by a plugin.
31+
// Include a built-in translation overridden by a plugin.
3232
expect(t('search.label')).toBe('Rechercher le truc');
3333
// Include a translation injected by a plugin.
3434
// @ts-expect-error - translation key injected by a test plugin.
@@ -53,7 +53,7 @@ test('can access UI strings in the plugin context using useTranslations()', () =
5353

5454
// A built-in UI string.
5555
expect(uiStrings[0]).toBe('Skip to content');
56-
// A built-in UI string overriden by a plugin.
56+
// A built-in UI string overridden by a plugin.
5757
expect(uiStrings[1]).toBe('Rechercher le truc');
5858
// A UI string injected by a plugin.
5959
expect(uiStrings[2]).toBe('Do the Plugin 3 thing');

packages/starlight/__tests__/plugins/vitest.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export default defineVitestConfig({
2121
description: 'plugin 1',
2222
/**
2323
* The configuration received by a plugin should be the user provided configuration as-is
24-
* befor any Zod `transform`s are applied.
24+
* before any Zod `transform`s are applied.
2525
* To test this, we use this plugin to update the `favicon` value to a specific value if
2626
* the `favicon` config value is an object, which would mean that the associated Zod
2727
* `transform` was applied.

packages/starlight/__tests__/remark-rehype/asides.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ Some text
187187
);
188188
const pathCount = (res.code.match(/path/g) || []).length;
189189
// If we have two pairs of opening and closing tags of path,
190-
// we will have 4 occurences of that word.
190+
// we will have 4 occurrences of that word.
191191
expect(pathCount).eq(4);
192192
});
193193
});

packages/starlight/integrations/expressive-code/themes/night-owl-dark.jsonc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1781,7 +1781,7 @@
17811781
"keyword.operator.type",
17821782
"keyword.operator",
17831783
"keyword",
1784-
"punctuation.definintion.string",
1784+
"punctuation.definition.string",
17851785
"punctuation",
17861786
"variable.other.readwrite.js",
17871787
"storage.type",

packages/starlight/integrations/expressive-code/themes/night-owl-light.jsonc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1680,7 +1680,7 @@
16801680
"keyword.operator.type",
16811681
"keyword.operator",
16821682
"keyword",
1683-
"punctuation.definintion.string",
1683+
"punctuation.definition.string",
16841684
"punctuation",
16851685
"variable.other.readwrite.js",
16861686
"storage.type",

packages/starlight/utils/i18n.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import type { StarlightConfig } from './user-config';
1111
*/
1212
const wellKnownRTL = ['ar', 'fa', 'he', 'prs', 'ps', 'syc', 'ug', 'ur'];
1313

14-
/** Informations about the built-in default locale used as a fallback when no locales are defined. */
14+
/** Information about the built-in default locale used as a fallback when no locales are defined. */
1515
export const BuiltInDefaultLocale = { ...getLocaleInfo('en'), lang: 'en' };
1616

1717
/**
@@ -135,7 +135,7 @@ function getStarlightI18nConfig(
135135
};
136136
}
137137

138-
/** Infer Starlight locale informations based on a locale from an Astro i18n configuration. */
138+
/** Infer Starlight locale information based on a locale from an Astro i18n configuration. */
139139
function inferStarlightLocaleFromAstroLocale(astroLocale: AstroLocale) {
140140
const lang = isAstroLocaleExtendedConfig(astroLocale) ? astroLocale.codes[0] : astroLocale;
141141
return { ...getLocaleInfo(lang), lang };
@@ -159,7 +159,7 @@ function isAstroLocaleExtendedConfig(locale: AstroLocale): locale is AstroLocale
159159
return typeof locale !== 'string';
160160
}
161161

162-
/** Returns the locale informations such as a label and a direction based on a BCP-47 tag. */
162+
/** Returns the locale information such as a label and a direction based on a BCP-47 tag. */
163163
function getLocaleInfo(lang: string) {
164164
try {
165165
const locale = new Intl.Locale(lang);
@@ -171,7 +171,7 @@ function getLocaleInfo(lang: string) {
171171
};
172172
} catch {
173173
throw new AstroError(
174-
`Failed to get locale informations for the '${lang}' locale.`,
174+
`Failed to get locale information for the '${lang}' locale.`,
175175
'Make sure to provide a valid BCP-47 tags (e.g. en, ar, or zh-CN).'
176176
);
177177
}

0 commit comments

Comments
 (0)