From 80d06242622ec8e2ec4459f8da85815d4e5fab69 Mon Sep 17 00:00:00 2001 From: Sara Tavares <29093946+stavares843@users.noreply.github.com> Date: Fri, 28 Oct 2022 03:32:02 +0100 Subject: [PATCH] fix(typos): add github action to prevent typos + fix typos (#9598) * feat(ci): fix typos * [create-pull-request] automated change * Update index.tsx * Update README.fr.md * Create .misspell-fixer.ignore * Update constant.dart * [create-pull-request] automated change * Update database.tsx * [create-pull-request] automated change * [create-pull-request] automated change Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- .github/workflows/fix-typos.yml | 19 ++++++++++++++ .misspell-fixer.ignore | 1 + .../reference/docs/guides/database/tables.mdx | 2 +- .../docs/guides/integrations/polyscale.mdx | 2 +- apps/reference/docs/guides/with-flutter.mdx | 18 ++++++------- apps/reference/generator/legacy.ts | 4 +-- apps/www/_blog/2021-03-31-supabase-cli.mdx | 2 +- apps/www/_blog/2022-08-16-supabase-js-v2.mdx | 2 +- ...postgres-extension-for-json-validation.mdx | 2 +- ...trello-board-with-supabase-and-angular.mdx | 2 +- apps/www/pages/blog.tsx | 2 +- apps/www/styles/index.css | 2 +- .../lib/components/avatar.dart | 2 +- .../lib/pages/account_page.dart | 8 +++--- .../lib/pages/login_page.dart | 2 +- .../src/components/Breadcrumb/Breadcrumb.tsx | 6 ++--- .../ui/src/components/Divider/Divider.tsx | 2 +- .../components/Dropdown/Dropdown.stories.tsx | 26 +++++++++---------- .../ui/src/components/Dropdown/Dropdown.tsx | 6 ++--- .../ui/src/components/Modal/Modal.stories.tsx | 2 +- packages/ui/src/components/Modal/Modal.tsx | 6 ++--- .../components/Popover/Popover.stories.tsx | 4 +-- .../ui/src/components/Popover/Popover.tsx | 6 ++--- .../ui/src/components/SidePanel/SidePanel.tsx | 6 ++--- packages/ui/src/lib/theme/defaultTheme.ts | 8 +++--- .../common/ForeignTableModal/index.tsx | 2 +- .../header/filter/FilterPopover.tsx | 2 +- .../components/header/sort/SortPopover.tsx | 2 +- .../Account/NewAccessTokenButton.tsx | 2 +- .../Auth/Policies/PolicyEditor/index.tsx | 6 ++--- .../Policies/PolicyTableRow/PolicyRow.tsx | 2 +- .../interfaces/Auth/Users/UserDropdown.tsx | 2 +- .../AddPaymentMethodForm.tsx | 2 +- .../Billing/ExitSurvey/ExitSurvey.tsx | 2 +- .../PaymentSummaryPanel.tsx | 2 +- .../interfaces/Billing/ProUpgrade.tsx | 2 +- .../Database/Backups/PITR/PITRSelection.tsx | 6 ++--- .../Extensions/EnableExtensionModal.tsx | 4 +-- .../Database/Extensions/ExtensionCard.tsx | 4 +-- .../Database/Extensions/Extensions.tsx | 4 +-- .../Database/Functions/CreateFunction.tsx | 16 ++++++------ .../CreateHook/ServiceConfigForm/index.tsx | 6 ++--- .../Database/Hooks/CreateHook/index.tsx | 8 +++--- .../Database/Triggers/CreateTrigger.tsx | 4 +-- .../DeleteOrganizationButton.tsx | 4 +-- .../TeamSettings/InviteMemberButton.tsx | 2 +- .../TeamSettings/MemberActions.tsx | 4 +-- .../Organization/TeamSettings/MembersView.tsx | 2 +- .../interfaces/Settings/API/JWTSettings.tsx | 2 +- .../interfaces/Settings/Logs/LogTable.tsx | 2 +- .../LogsErrorRenderers.stories.tsx | 2 +- .../Settings/Logs/LogsFilterPopover.tsx | 2 +- .../Settings/Logs/UpgradePrompt.tsx | 2 +- .../ColumnEditor/ColumnEditor.tsx | 4 +-- .../ColumnEditor/InputWithSuggestions.tsx | 2 +- .../SidePanelEditor/RowEditor/RowEditor.tsx | 2 +- .../SidePanelEditor/TableEditor/Column.tsx | 6 ++--- .../TableEditor/TableEditor.tsx | 4 +-- .../FeedbackDropdown/FeedbackWidget.tsx | 2 +- .../LayoutHeader/HelpPopover.tsx | 2 +- .../NotificationsPopover/index.tsx | 8 +++--- .../LayoutHeader/OrgDropdown.tsx | 2 +- .../LayoutHeader/ProjectDropdown.tsx | 2 +- .../NavigationBar/NavigationBar.tsx | 2 +- .../ProjectLayout/ProjectPausedState.tsx | 2 +- .../layouts/SQLEditorLayout/SQLEditorMenu.tsx | 2 +- .../layouts/StorageLayout/StorageMenu.tsx | 2 +- .../TableEditorLayout/TableEditorMenu.tsx | 2 +- .../Dropdown/OrganizationDropdown.js | 2 +- .../to-be-cleaned/SqlEditor/RenameQuery.js | 2 +- .../Storage/CreateBucketModal.tsx | 2 +- .../StorageExplorer/FileExplorerRow.js | 2 +- .../StoragePolicies/StoragePolicies.js | 2 +- .../StoragePoliciesBucketRow.js | 2 +- .../StoragePolicies/StoragePoliciesEditor.js | 6 ++--- .../StorageSettings/StorageSettings.tsx | 2 +- .../components/ui/DatePicker/DatePicker.tsx | 2 +- studio/components/ui/Dialogs/ConfirmDialog.js | 2 +- .../components/ui/Modals/TextConfirmModal.tsx | 4 +-- studio/lib/common/fetch/base.ts | 4 +-- .../[ref]/settings/billing/update/index.tsx | 2 +- .../pages/project/[ref]/settings/database.tsx | 2 +- .../pages/projects/LogsPreviewer.test.js | 2 +- 83 files changed, 172 insertions(+), 152 deletions(-) create mode 100644 .github/workflows/fix-typos.yml create mode 100644 .misspell-fixer.ignore diff --git a/.github/workflows/fix-typos.yml b/.github/workflows/fix-typos.yml new file mode 100644 index 00000000000..faa0e01c84d --- /dev/null +++ b/.github/workflows/fix-typos.yml @@ -0,0 +1,19 @@ +name: Automatically fix typos +on: + push: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + ref: master + - uses: sobolevn/misspell-fixer-action@master + - uses: peter-evans/create-pull-request@v2.4.4 + env: + ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true' + with: + token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.misspell-fixer.ignore b/.misspell-fixer.ignore new file mode 100644 index 00000000000..7c90f6e4788 --- /dev/null +++ b/.misspell-fixer.ignore @@ -0,0 +1 @@ +^./i18n diff --git a/apps/reference/docs/guides/database/tables.mdx b/apps/reference/docs/guides/database/tables.mdx index ed9292a9f3e..7f4d0e914ca 100644 --- a/apps/reference/docs/guides/database/tables.mdx +++ b/apps/reference/docs/guides/database/tables.mdx @@ -160,7 +160,7 @@ In the example above, we have: 1. created a column called `id` 1. assigned the data type `bigint` 1. instructed the database that this should be `generated always as identity`, which means that Postgres will automatically assign a unique number to this column. -1. Becuase it's unique, we can also use it as our `primary key`. +1. Because it's unique, we can also use it as our `primary key`. We could also use `generated by default as identity`, which would allow us to insert our own unique values. diff --git a/apps/reference/docs/guides/integrations/polyscale.mdx b/apps/reference/docs/guides/integrations/polyscale.mdx index 412f94ff2c1..1eae5729d0f 100644 --- a/apps/reference/docs/guides/integrations/polyscale.mdx +++ b/apps/reference/docs/guides/integrations/polyscale.mdx @@ -48,7 +48,7 @@ Your cache is now created. PolyScale automatically checks to see that your datab ## Step 2: Connect to your PolyScale Cache -Using your PolyScale cache is simple -- instead of connecting to your Supabase database directly, you'll replace your orignal connection string with the PolyScale connection string in your application. +Using your PolyScale cache is simple -- instead of connecting to your Supabase database directly, you'll replace your original connection string with the PolyScale connection string in your application. For example, if your original connection string was: `postgres://postgres:zqSPGHFAbPLvVCKw@db.rogpiubvixysbakciwqz.supabase.co:5432` diff --git a/apps/reference/docs/guides/with-flutter.mdx b/apps/reference/docs/guides/with-flutter.mdx index d71bcafea34..b531e6112e5 100644 --- a/apps/reference/docs/guides/with-flutter.mdx +++ b/apps/reference/docs/guides/with-flutter.mdx @@ -249,7 +249,7 @@ class _LoginPageState extends State { } on AuthException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected error occured'); + context.showErrorSnackBar(message: 'Unexpected error occurred'); } setState(() { @@ -346,7 +346,7 @@ class _AccountPageState extends State { } on PostgrestException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected exception occured'); + context.showErrorSnackBar(message: 'Unexpected exception occurred'); } setState(() { @@ -376,7 +376,7 @@ class _AccountPageState extends State { } on PostgrestException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpeted error occured'); + context.showErrorSnackBar(message: 'Unexpeted error occurred'); } setState(() { _loading = false; @@ -389,7 +389,7 @@ class _AccountPageState extends State { } on AuthException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected error occured'); + context.showErrorSnackBar(message: 'Unexpected error occurred'); } if (mounted) { Navigator.of(context).pushReplacementNamed('/'); @@ -619,7 +619,7 @@ class _AvatarState extends State { } } catch (error) { if (mounted) { - context.showErrorSnackBar(message: 'Unexpected error occured'); + context.showErrorSnackBar(message: 'Unexpected error occurred'); } } @@ -670,7 +670,7 @@ class _AccountPageState extends State { } on PostgrestException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected exception occured'); + context.showErrorSnackBar(message: 'Unexpected exception occurred'); } setState(() { @@ -700,7 +700,7 @@ class _AccountPageState extends State { } on PostgrestException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpeted error occured'); + context.showErrorSnackBar(message: 'Unexpeted error occurred'); } setState(() { _loading = false; @@ -713,7 +713,7 @@ class _AccountPageState extends State { } on AuthException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected error occured'); + context.showErrorSnackBar(message: 'Unexpected error occurred'); } if (mounted) { Navigator.of(context).pushReplacementNamed('/'); @@ -734,7 +734,7 @@ class _AccountPageState extends State { } on PostgrestException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected error has occured'); + context.showErrorSnackBar(message: 'Unexpected error has occurred'); } if (!mounted) { return; diff --git a/apps/reference/generator/legacy.ts b/apps/reference/generator/legacy.ts index 6a2b906af3f..c2d03442d7b 100644 --- a/apps/reference/generator/legacy.ts +++ b/apps/reference/generator/legacy.ts @@ -54,7 +54,7 @@ export default async function gen(inputFileName: string, outputDir: string) { const description = pageSpec.description || - tsDocCommentToMdComment(getDescriptionFromDefintion(tsDefinition)) + tsDocCommentToMdComment(getDescriptionFromDefinition(tsDefinition)) // Create page const content = Page({ @@ -107,7 +107,7 @@ function generateParameters(tsDefinition: any) { return methodListGroup(parameters) } -function getDescriptionFromDefintion(tsDefinition) { +function getDescriptionFromDefinition(tsDefinition) { if (!tsDefinition) return null if ( ['Method', 'Constructor', 'Constructor signature'].includes( diff --git a/apps/www/_blog/2021-03-31-supabase-cli.mdx b/apps/www/_blog/2021-03-31-supabase-cli.mdx index 51cfaf6e55d..b24682700de 100644 --- a/apps/www/_blog/2021-03-31-supabase-cli.mdx +++ b/apps/www/_blog/2021-03-31-supabase-cli.mdx @@ -153,7 +153,7 @@ docker run supabase/pgadmin-schema-diff \ > diff_demo.sql Starting schema diff... -Comparision started......0% +Comparison started......0% Comparing Event Triggers...2% Comparing Extensions...4% Comparing Languages...8% diff --git a/apps/www/_blog/2022-08-16-supabase-js-v2.mdx b/apps/www/_blog/2022-08-16-supabase-js-v2.mdx index f195da5b5c6..711954ce122 100644 --- a/apps/www/_blog/2022-08-16-supabase-js-v2.mdx +++ b/apps/www/_blog/2022-08-16-supabase-js-v2.mdx @@ -186,7 +186,7 @@ const supabase = createClient(apiURL, apiKey, { }) ``` -This is clearer for developers - if you're only using some parts of Supabase, you only recieve the hints for those parts. +This is clearer for developers - if you're only using some parts of Supabase, you only receive the hints for those parts.
diff --git a/apps/www/_blog/2022-08-19-pg-jsonschema-a-postgres-extension-for-json-validation.mdx b/apps/www/_blog/2022-08-19-pg-jsonschema-a-postgres-extension-for-json-validation.mdx index fedddcb4bb8..52f14bd8c01 100644 --- a/apps/www/_blog/2022-08-19-pg-jsonschema-a-postgres-extension-for-json-validation.mdx +++ b/apps/www/_blog/2022-08-19-pg-jsonschema-a-postgres-extension-for-json-validation.mdx @@ -32,7 +32,7 @@ If our application receives data via a webhook: }, "payload": { { - "sucess": true, + "success": true, "content": { "account_id": "d928b484-16bd-4f10-a827-3eb959b4cc14", "event": "SUBSCRIBED", diff --git a/apps/www/_blog/2022-08-24-building-a-realtime-trello-board-with-supabase-and-angular.mdx b/apps/www/_blog/2022-08-24-building-a-realtime-trello-board-with-supabase-and-angular.mdx index 8e608762b6e..74e199254fc 100644 --- a/apps/www/_blog/2022-08-24-building-a-realtime-trello-board-with-supabase-and-angular.mdx +++ b/apps/www/_blog/2022-08-24-building-a-realtime-trello-board-with-supabase-and-angular.mdx @@ -1307,7 +1307,7 @@ To continue, bring up the **src/app/services/data.service.ts** and add this addi Now that we can easily get all the updates to our relevant tables in realtime, we just need to handle them accordingly. -This is just a matter of finding out which **event** occured (INSERT, UPDATE, DELETE) and then applying the changes to our local data to add, change or remove data. +This is just a matter of finding out which **event** occurred (INSERT, UPDATE, DELETE) and then applying the changes to our local data to add, change or remove data. Go ahead by finally implementing our function in the **src/app/components/inside/board/board.component.ts** that we left open until now: diff --git a/apps/www/pages/blog.tsx b/apps/www/pages/blog.tsx index 6be2ff2453d..3e020c9533b 100644 --- a/apps/www/pages/blog.tsx +++ b/apps/www/pages/blog.tsx @@ -39,7 +39,7 @@ function Blog(props: any) { const router = useRouter() useEffect(() => { - // contruct an array of blog posts + // construct an array of blog posts // not inluding the first blog post const shiftedBlogs = [...props.blogs] shiftedBlogs.shift() diff --git a/apps/www/styles/index.css b/apps/www/styles/index.css index 0770adef451..a9175b6623a 100644 --- a/apps/www/styles/index.css +++ b/apps/www/styles/index.css @@ -156,7 +156,7 @@ h6 { */ /* Database page */ -.dashboard-tabs div[role='seperator'] { +.dashboard-tabs div[role='separator'] { @apply border border-gray-50 dark:border-gray-700; } diff --git a/examples/user-management/flutter-user-management/lib/components/avatar.dart b/examples/user-management/flutter-user-management/lib/components/avatar.dart index 826366d76c1..8bd3ab13244 100644 --- a/examples/user-management/flutter-user-management/lib/components/avatar.dart +++ b/examples/user-management/flutter-user-management/lib/components/avatar.dart @@ -80,7 +80,7 @@ class _AvatarState extends State { } } catch (error) { if (mounted) { - context.showErrorSnackBar(message: 'Unexpected error occured'); + context.showErrorSnackBar(message: 'Unexpected error occurred'); } } diff --git a/examples/user-management/flutter-user-management/lib/pages/account_page.dart b/examples/user-management/flutter-user-management/lib/pages/account_page.dart index ac7d4fc13b6..7fc66e26525 100644 --- a/examples/user-management/flutter-user-management/lib/pages/account_page.dart +++ b/examples/user-management/flutter-user-management/lib/pages/account_page.dart @@ -35,7 +35,7 @@ class _AccountPageState extends State { } on PostgrestException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected exception occured'); + context.showErrorSnackBar(message: 'Unexpected exception occurred'); } setState(() { @@ -65,7 +65,7 @@ class _AccountPageState extends State { } on PostgrestException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpeted error occured'); + context.showErrorSnackBar(message: 'Unexpeted error occurred'); } setState(() { _loading = false; @@ -78,7 +78,7 @@ class _AccountPageState extends State { } on AuthException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected error occured'); + context.showErrorSnackBar(message: 'Unexpected error occurred'); } if (mounted) { Navigator.of(context).pushReplacementNamed('/'); @@ -99,7 +99,7 @@ class _AccountPageState extends State { } on PostgrestException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected error has occured'); + context.showErrorSnackBar(message: 'Unexpected error has occurred'); } if (!mounted) { return; diff --git a/examples/user-management/flutter-user-management/lib/pages/login_page.dart b/examples/user-management/flutter-user-management/lib/pages/login_page.dart index b7f8bf491a3..f4bcbbcdac1 100644 --- a/examples/user-management/flutter-user-management/lib/pages/login_page.dart +++ b/examples/user-management/flutter-user-management/lib/pages/login_page.dart @@ -36,7 +36,7 @@ class _LoginPageState extends State { } on AuthException catch (error) { context.showErrorSnackBar(message: error.message); } catch (error) { - context.showErrorSnackBar(message: 'Unexpected error occured'); + context.showErrorSnackBar(message: 'Unexpected error occurred'); } setState(() { diff --git a/packages/ui/src/components/Breadcrumb/Breadcrumb.tsx b/packages/ui/src/components/Breadcrumb/Breadcrumb.tsx index 6b32edf834b..65d97cbb722 100644 --- a/packages/ui/src/components/Breadcrumb/Breadcrumb.tsx +++ b/packages/ui/src/components/Breadcrumb/Breadcrumb.tsx @@ -11,14 +11,14 @@ interface Props { const Breadcrumb = ({ className, style, children, spacing = 'small' }: Props) => { let classes = [BreadcrumbStyle['sbui-breadcrumb--container']] - let seperatorClasses = [BreadcrumbStyle['sbui-breadcrumb--separator']] + let separatorClasses = [BreadcrumbStyle['sbui-breadcrumb--separator']] if (className) { classes.push(className) } if (spacing) { - seperatorClasses.push(`sbui-breadcrumb--separator-${spacing}`) + separatorClasses.push(`sbui-breadcrumb--separator-${spacing}`) } return ( @@ -27,7 +27,7 @@ const Breadcrumb = ({ className, style, children, spacing = 'small' }: Props) =>
  • {child} {idx + 1 < children!.length && ( -
  • ))} diff --git a/packages/ui/src/components/Divider/Divider.tsx b/packages/ui/src/components/Divider/Divider.tsx index c1b0607899f..7030dff9e56 100644 --- a/packages/ui/src/components/Divider/Divider.tsx +++ b/packages/ui/src/components/Divider/Divider.tsx @@ -37,7 +37,7 @@ export default function Divider({ return (
    {children && ( diff --git a/packages/ui/src/components/Dropdown/Dropdown.stories.tsx b/packages/ui/src/components/Dropdown/Dropdown.stories.tsx index d1f825a5772..36a13dfd86c 100644 --- a/packages/ui/src/components/Dropdown/Dropdown.stories.tsx +++ b/packages/ui/src/components/Dropdown/Dropdown.stories.tsx @@ -68,7 +68,7 @@ export const DefaultFull = (args: any) => {
    , - , + , Group label, console.log('clicked')}> Account @@ -76,17 +76,17 @@ export const DefaultFull = (args: any) => { Settings ⌘+T , - , + , Show subtitles , - , + , Red Blue Green , - , + , { Blue Green , - , + , Group label, console.log('clicked')}> Account @@ -112,7 +112,7 @@ export const DefaultFull = (args: any) => { , - , + , }> Log out , @@ -142,7 +142,7 @@ export const Default = (args: any) => ( , - , + , Group label, console.log('clicked')}> Account @@ -150,7 +150,7 @@ export const Default = (args: any) => ( Settings ⌘+T , - , + , }>Log out, ]} > @@ -172,7 +172,7 @@ export const doNotcloseOverlay = (args: any) => ( Signed in as tom@example.com , - , + , Account, Settings, @@ -207,10 +207,10 @@ export const withCustomStyles = (args: any) => ( Signed in as tom@example.com , - , + , Account, Settings, - , + ,