index
int64
0
0
repo_id
stringlengths
16
181
file_path
stringlengths
28
270
content
stringlengths
1
11.6M
__index_level_0__
int64
0
10k
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/states/onViewSortsChangeScopedState.ts
import { createScopedState } from '@/ui/utilities/recoil-scope/utils/createScopedState'; import { ViewSort } from '@/views/types/ViewSort'; export const onViewSortsChangeScopedState = createScopedState< ((sorts: ViewSort[]) => void | Promise<void>) | undefined >({ key: 'onViewSortsChangeScopedState', defaultValu...
2,700
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/states/savedViewFieldsScopedFamilyState.ts
import { createScopedFamilyState } from '@/ui/utilities/recoil-scope/utils/createScopedFamilyState'; import { ViewField } from '../types/ViewField'; export const savedViewFieldsScopedFamilyState = createScopedFamilyState< ViewField[], string >({ key: 'savedViewFieldsScopedFamilyState', defaultValue: [], });
2,701
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/states/savedViewFiltersScopedFamilyState.ts
import { createScopedFamilyState } from '@/ui/utilities/recoil-scope/utils/createScopedFamilyState'; import { ViewFilter } from '../types/ViewFilter'; export const savedViewFiltersScopedFamilyState = createScopedFamilyState< ViewFilter[], string >({ key: 'savedViewFiltersScopedFamilyState', defaultValue: [], ...
2,702
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/states/savedViewSortsScopedFamilyState.ts
import { createScopedFamilyState } from '@/ui/utilities/recoil-scope/utils/createScopedFamilyState'; import { ViewSort } from '../types/ViewSort'; export const savedViewSortsScopedFamilyState = createScopedFamilyState< ViewSort[], string >({ key: 'savedViewSortsScopedFamilyState', defaultValue: [], });
2,703
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/states/viewEditModeScopedState.ts
import { createScopedState } from '@/ui/utilities/recoil-scope/utils/createScopedState'; export const viewEditModeScopedState = createScopedState< 'none' | 'edit' | 'create' >({ key: 'viewEditModeScopedState', defaultValue: 'none', });
2,704
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/states/viewObjectMetadataIdScopeState.ts
import { createScopedState } from '@/ui/utilities/recoil-scope/utils/createScopedState'; export const viewObjectMetadataIdScopeState = createScopedState< string | undefined >({ key: 'viewObjectMetadataIdScopeState', defaultValue: undefined, });
2,705
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/states/viewTypeScopedState.ts
import { createScopedState } from '@/ui/utilities/recoil-scope/utils/createScopedState'; import { ViewType } from '../types/ViewType'; export const viewTypeScopedState = createScopedState<ViewType>({ key: 'viewTypeScopedState', defaultValue: ViewType.Table, });
2,706
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/states/viewsScopedState.ts
import { createScopedState } from '@/ui/utilities/recoil-scope/utils/createScopedState'; import { View } from '../types/View'; export const viewsScopedState = createScopedState<View[]>({ key: 'viewsScopedState', defaultValue: [], });
2,707
0
petrpan-code/twentyhq/twenty/front/src/modules/views/states
petrpan-code/twentyhq/twenty/front/src/modules/views/states/selectors/canPersistViewFiltersScopedFamilySelector.ts
import { selectorFamily } from 'recoil'; import { isDeeplyEqual } from '~/utils/isDeeplyEqual'; import { currentViewFiltersScopedFamilyState } from '../currentViewFiltersScopedFamilyState'; import { savedViewFiltersScopedFamilyState } from '../savedViewFiltersScopedFamilyState'; export const canPersistViewFiltersSco...
2,708
0
petrpan-code/twentyhq/twenty/front/src/modules/views/states
petrpan-code/twentyhq/twenty/front/src/modules/views/states/selectors/canPersistViewSortsScopedFamilySelector.ts
import { selectorFamily } from 'recoil'; import { isDeeplyEqual } from '~/utils/isDeeplyEqual'; import { currentViewSortsScopedFamilyState } from '../currentViewSortsScopedFamilyState'; import { savedViewSortsScopedFamilyState } from '../savedViewSortsScopedFamilyState'; export const canPersistViewSortsScopedFamilyS...
2,709
0
petrpan-code/twentyhq/twenty/front/src/modules/views/states
petrpan-code/twentyhq/twenty/front/src/modules/views/states/selectors/currentViewScopedSelector.ts
import { createScopedSelector } from '@/ui/utilities/recoil-scope/utils/createScopedSelector'; import { View } from '@/views/types/View'; import { currentViewIdScopedState } from '../currentViewIdScopedState'; import { viewsByIdScopedSelector } from './viewsByIdScopedSelector'; export const currentViewScopedSelector...
2,710
0
petrpan-code/twentyhq/twenty/front/src/modules/views/states
petrpan-code/twentyhq/twenty/front/src/modules/views/states/selectors/savedViewFieldByKeyScopedFamilySelector.ts
import { selectorFamily } from 'recoil'; import { ViewField } from '@/views/types/ViewField'; import { savedViewFieldsScopedFamilyState } from '../savedViewFieldsScopedFamilyState'; export const savedViewFieldByKeyScopedFamilySelector = selectorFamily({ key: 'savedViewFieldByKeyScopedFamilySelector', get: ({...
2,711
0
petrpan-code/twentyhq/twenty/front/src/modules/views/states
petrpan-code/twentyhq/twenty/front/src/modules/views/states/selectors/savedViewFiltersByKeyScopedFamilySelector.ts
import { selectorFamily } from 'recoil'; import { ViewFilter } from '@/views/types/ViewFilter'; import { savedViewFiltersScopedFamilyState } from '../savedViewFiltersScopedFamilyState'; export const savedViewFiltersByKeyScopedFamilySelector = selectorFamily({ key: 'savedViewFiltersByKeyScopedFamilySelector', get...
2,712
0
petrpan-code/twentyhq/twenty/front/src/modules/views/states
petrpan-code/twentyhq/twenty/front/src/modules/views/states/selectors/savedViewSortsByKeyScopedFamilySelector.ts
import { selectorFamily } from 'recoil'; import { ViewSort } from '@/views/types/ViewSort'; import { savedViewSortsScopedFamilyState } from '../savedViewSortsScopedFamilyState'; export const savedViewSortsByKeyScopedFamilySelector = selectorFamily({ key: 'savedViewSortsByKeyScopedFamilySelector', get: ({ sco...
2,713
0
petrpan-code/twentyhq/twenty/front/src/modules/views/states
petrpan-code/twentyhq/twenty/front/src/modules/views/states/selectors/savedViewSortsFamilySelector.ts
import { selectorFamily } from 'recoil'; import { savedViewSortsScopedFamilyState } from '../savedViewSortsScopedFamilyState'; export const savedViewSortsFamilySelector = selectorFamily({ key: 'savedViewSortsFamilySelector', get: ({ scopeId, viewId }: { scopeId: string; viewId: string }) => ({ get }) => ...
2,714
0
petrpan-code/twentyhq/twenty/front/src/modules/views/states
petrpan-code/twentyhq/twenty/front/src/modules/views/states/selectors/viewsByIdScopedSelector.ts
import { selectorFamily } from 'recoil'; import { View } from '@/views/types/View'; import { viewsScopedState } from '../viewsScopedState'; export const viewsByIdScopedSelector = selectorFamily< Record<string, View>, string >({ key: 'viewsByIdScopedSelector', get: (scopeId) => ({ get }) => get(...
2,715
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/GraphQLView.ts
import { PaginatedObjectTypeResults } from '@/object-record/types/PaginatedObjectTypeResults'; import { ViewField } from '@/views/types/ViewField'; import { ViewFilter } from '@/views/types/ViewFilter'; import { ViewSort } from '@/views/types/ViewSort'; export type GraphQLView = { id: string; name: string; objec...
2,716
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/View.ts
export type View = { id: string; name: string; objectMetadataId: string; };
2,717
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/ViewField.ts
import { FieldMetadata } from '@/ui/object/field/types/FieldMetadata'; import { BoardFieldDefinition } from '@/ui/object/record-board/types/BoardFieldDefinition'; import { ColumnDefinition } from '@/ui/object/record-table/types/ColumnDefinition'; export type ViewField = { id: string; fieldMetadataId: string; pos...
2,718
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/ViewFilter.ts
import { FilterDefinition } from '@/ui/object/object-filter-dropdown/types/FilterDefinition'; import { ViewFilterOperand } from './ViewFilterOperand'; export type ViewFilter = { id: string; fieldMetadataId: string; operand: ViewFilterOperand; value: string; displayValue: string; definition: FilterDefiniti...
2,719
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/ViewFilterOperand.ts
export enum ViewFilterOperand { Is = 'is', IsNotNull = 'isNotNull', IsNot = 'isNot', LessThan = 'lessThan', GreaterThan = 'greaterThan', Contains = 'contains', DoesNotContain = 'doesNotContain', }
2,720
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/ViewSort.ts
import { SortDefinition } from '@/ui/object/object-sort-dropdown/types/SortDefinition'; import { SortDirection } from '@/ui/object/object-sort-dropdown/types/SortDirection'; export type ViewSort = { id: string; fieldMetadataId: string; direction: SortDirection; definition: SortDefinition; };
2,721
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/ViewSortDirection.ts
export enum ViewSortDirection { Asc = 'asc', Desc = 'desc', }
2,722
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/ViewType.ts
export enum ViewType { Table = 'table', Kanban = 'kanban', }
2,723
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/types/ViewsHotkeyScope.ts
export enum ViewsHotkeyScope { ListDropdown = 'views-list-dropdown', CreateDropdown = 'views-create-dropdown', }
2,724
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/utils/getViewScopedStateValuesFromSnapshot.ts
import { Snapshot } from 'recoil'; import { getScopedState } from '@/ui/utilities/recoil-scope/utils/getScopedState'; import { getSnapshotValue } from '@/ui/utilities/recoil-scope/utils/getSnapshotValue'; import { UNDEFINED_FAMILY_ITEM_ID } from '../constants'; import { currentViewIdScopedState } from '../states/curr...
2,725
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/utils/getViewScopedStatesFromSnapshot.ts
import { Snapshot } from 'recoil'; import { getScopedState } from '@/ui/utilities/recoil-scope/utils/getScopedState'; import { getSnapshotValue } from '@/ui/utilities/recoil-scope/utils/getSnapshotValue'; import { UNDEFINED_FAMILY_ITEM_ID } from '../constants'; import { currentViewIdScopedState } from '../states/curr...
2,726
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/utils/mapColumnDefinitionToViewField.ts
import { FieldMetadata } from '@/ui/object/field/types/FieldMetadata'; import { ColumnDefinition } from '@/ui/object/record-table/types/ColumnDefinition'; import { ViewField } from '../types/ViewField'; export const mapColumnDefinitionsToViewFields = ( columnDefinitions: ColumnDefinition<FieldMetadata>[], ): ViewFi...
2,727
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/utils/mapViewFieldsToBoardFieldDefinitions.ts
import { FieldMetadata } from '@/ui/object/field/types/FieldMetadata'; import { BoardFieldDefinition } from '@/ui/object/record-board/types/BoardFieldDefinition'; import { assertNotNull } from '~/utils/assert'; import { ViewField } from '../types/ViewField'; export const mapViewFieldsToBoardFieldDefinitions = ( vie...
2,728
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/utils/mapViewFieldsToColumnDefinitions.ts
import { FieldMetadata } from '@/ui/object/field/types/FieldMetadata'; import { ColumnDefinition } from '@/ui/object/record-table/types/ColumnDefinition'; import { assertNotNull } from '~/utils/assert'; import { ViewField } from '../types/ViewField'; export const mapViewFieldsToColumnDefinitions = ( viewFields: Vie...
2,729
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/utils/mapViewFiltersToFilters.ts
import { Filter } from '@/ui/object/object-filter-dropdown/types/Filter'; import { ViewFilter } from '../types/ViewFilter'; export const mapViewFiltersToFilters = ( viewFilters: ViewFilter[], ): Filter[] => { return viewFilters.map((viewFilter) => { return { fieldMetadataId: viewFilter.fieldMetadataId, ...
2,730
0
petrpan-code/twentyhq/twenty/front/src/modules/views
petrpan-code/twentyhq/twenty/front/src/modules/views/utils/mapViewSortsToSorts.ts
import { Sort } from '@/ui/object/object-sort-dropdown/types/Sort'; import { ViewSort } from '../types/ViewSort'; export const mapViewSortsToSorts = (viewSorts: ViewSort[]): Sort[] => { return viewSorts.map((viewSort) => { return { fieldMetadataId: viewSort.fieldMetadataId, direction: viewSort.direc...
2,731
0
petrpan-code/twentyhq/twenty/front/src/modules/views/utils
petrpan-code/twentyhq/twenty/front/src/modules/views/utils/internal/getViewScopedStates.ts
import { getScopedFamilyState } from '@/ui/utilities/recoil-scope/utils/getScopedFamilyState'; import { getScopedSelector } from '@/ui/utilities/recoil-scope/utils/getScopedSelector'; import { getScopedState } from '@/ui/utilities/recoil-scope/utils/getScopedState'; import { currentViewIdScopedState } from '@/views/sta...
2,732
0
petrpan-code/twentyhq/twenty/front/src/modules/workspace-member
petrpan-code/twentyhq/twenty/front/src/modules/workspace-member/types/WorkspaceMember.ts
export type ColorScheme = 'Dark' | 'Light' | 'System'; export type WorkspaceMember = { id: string; name: { firstName: string; lastName: string; }; avatarUrl?: string | null; locale: string; colorScheme?: ColorScheme; };
2,733
0
petrpan-code/twentyhq/twenty/front/src/modules/workspace
petrpan-code/twentyhq/twenty/front/src/modules/workspace/components/WorkspaceInviteLink.tsx
import { useTheme } from '@emotion/react'; import styled from '@emotion/styled'; import { IconCopy, IconLink } from '@/ui/display/icon'; import { useSnackBar } from '@/ui/feedback/snack-bar-manager/hooks/useSnackBar'; import { Button } from '@/ui/input/button/components/Button'; import { TextInput } from '@/ui/input/c...
2,734
0
petrpan-code/twentyhq/twenty/front/src/modules/workspace
petrpan-code/twentyhq/twenty/front/src/modules/workspace/components/WorkspaceMemberCard.tsx
import styled from '@emotion/styled'; import { OverflowingTextWithTooltip } from '@/ui/display/tooltip/OverflowingTextWithTooltip'; import { Avatar } from '@/users/components/Avatar'; import { WorkspaceMember } from '@/workspace-member/types/WorkspaceMember'; const StyledContainer = styled.div` background: ${({ the...
2,735
0
petrpan-code/twentyhq/twenty/front/src/modules/workspace/graphql
petrpan-code/twentyhq/twenty/front/src/modules/workspace/graphql/mutations/deleteCurrentWorkspace.ts
import { gql } from '@apollo/client'; export const DELETE_CURRENT_WORKSPACE = gql` mutation DeleteCurrentWorkspace { deleteCurrentWorkspace { id } } `;
2,736
0
petrpan-code/twentyhq/twenty/front/src/modules/workspace/graphql
petrpan-code/twentyhq/twenty/front/src/modules/workspace/graphql/mutations/updateWorkspace.ts
import { gql } from '@apollo/client'; export const UPDATE_WORKSPACE = gql` mutation UpdateWorkspace($input: UpdateWorkspaceInput!) { updateWorkspace(data: $input) { id domainName displayName logo allowImpersonation } } `;
2,737
0
petrpan-code/twentyhq/twenty/front/src/modules/workspace/graphql
petrpan-code/twentyhq/twenty/front/src/modules/workspace/graphql/mutations/uploadWorkspaceLogo.ts
import { gql } from '@apollo/client'; export const UPLOAD_WORKSPACE_LOGO = gql` mutation UploadWorkspaceLogo($file: Upload!) { uploadWorkspaceLogo(file: $file) } `;
2,738
0
petrpan-code/twentyhq/twenty/front/src/modules/workspace/graphql
petrpan-code/twentyhq/twenty/front/src/modules/workspace/graphql/queries/getWorkspaceFromInviteHash.ts
import { gql } from '@apollo/client'; export const GET_WORKSPACE_FROM_INVITE_HASH = gql` query GetWorkspaceFromInviteHash($inviteHash: String!) { findWorkspaceFromInviteHash(inviteHash: $inviteHash) { id displayName logo allowImpersonation } } `;
2,739
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/auth/CreateProfile.tsx
import { useCallback } from 'react'; import { Controller, SubmitHandler, useForm } from 'react-hook-form'; import { useNavigate } from 'react-router-dom'; import styled from '@emotion/styled'; import { zodResolver } from '@hookform/resolvers/zod'; import { useRecoilState } from 'recoil'; import { Key } from 'ts-key-enu...
2,740
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/auth/CreateWorkspace.tsx
import { useCallback } from 'react'; import { Controller, SubmitHandler, useForm } from 'react-hook-form'; import { useNavigate } from 'react-router-dom'; import styled from '@emotion/styled'; import { zodResolver } from '@hookform/resolvers/zod'; import { useSetRecoilState } from 'recoil'; import { z } from 'zod'; im...
2,741
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/auth/SignInUp.tsx
import { SignInUpForm } from '../../modules/auth/sign-in-up/components/SignInUpForm'; export const SignInUp = () => <SignInUpForm />;
2,742
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/auth/VerifyEffect.tsx
import { useEffect } from 'react'; import { useNavigate, useSearchParams } from 'react-router-dom'; import { isNonEmptyString } from '@sniptt/guards'; import { useRecoilValue } from 'recoil'; import { useAuth } from '@/auth/hooks/useAuth'; import { useIsLogged } from '@/auth/hooks/useIsLogged'; import { currentWorkspa...
2,743
0
petrpan-code/twentyhq/twenty/front/src/pages/auth
petrpan-code/twentyhq/twenty/front/src/pages/auth/__stories__/CreateProfile.stories.tsx
import { getOperationName } from '@apollo/client/utilities'; import { Meta, StoryObj } from '@storybook/react'; import { within } from '@storybook/testing-library'; import { graphql } from 'msw'; import { AppPath } from '@/types/AppPath'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/Page...
2,744
0
petrpan-code/twentyhq/twenty/front/src/pages/auth
petrpan-code/twentyhq/twenty/front/src/pages/auth/__stories__/CreateWorkspace.stories.tsx
import { getOperationName } from '@apollo/client/utilities'; import { Meta, StoryObj } from '@storybook/react'; import { within } from '@storybook/testing-library'; import { graphql } from 'msw'; import { AppPath } from '@/types/AppPath'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/Page...
2,745
0
petrpan-code/twentyhq/twenty/front/src/pages/auth
petrpan-code/twentyhq/twenty/front/src/pages/auth/__stories__/SignInUp.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { fireEvent, within } from '@storybook/testing-library'; import { AppPath } from '@/types/AppPath'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { Sign...
2,746
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/companies/CompaniesMockMode.tsx
import styled from '@emotion/styled'; import { IconBuildingSkyscraper } from '@/ui/display/icon'; import { PageBody } from '@/ui/layout/page/PageBody'; import { PageContainer } from '@/ui/layout/page/PageContainer'; import { PageHeader } from '@/ui/layout/page/PageHeader'; const StyledTableContainer = styled.div` d...
2,747
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/impersonate/ImpersonateEffect.tsx
import { useCallback, useEffect } from 'react'; import { useNavigate, useParams } from 'react-router-dom'; import { isNonEmptyString } from '@sniptt/guards'; import { useRecoilState, useSetRecoilState } from 'recoil'; import { useIsLogged } from '@/auth/hooks/useIsLogged'; import { currentUserState } from '@/auth/stat...
2,748
0
petrpan-code/twentyhq/twenty/front/src/pages/impersonate
petrpan-code/twentyhq/twenty/front/src/pages/impersonate/__stories__/ImpersonateEffect.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { AppPath } from '@/types/AppPath'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { ImpersonateEffect } from '....
2,749
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/not-found/NotFound.tsx
import { useNavigate } from 'react-router-dom'; import styled from '@emotion/styled'; import { MainButton } from '@/ui/input/button/components/MainButton'; import { useIsMobile } from '@/ui/utilities/responsive/hooks/useIsMobile'; import { CompaniesMockMode } from '../companies/CompaniesMockMode'; const StyledBackDr...
2,750
0
petrpan-code/twentyhq/twenty/front/src/pages/not-found
petrpan-code/twentyhq/twenty/front/src/pages/not-found/__stories__/NotFound.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { within } from '@storybook/testing-library'; import { ComponentWithRouterDecorator } from '~/testing/decorators/ComponentWithRouterDecorator'; import { PageDecoratorArgs } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graph...
2,751
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/opportunities/Opportunities.tsx
import styled from '@emotion/styled'; import { CompanyBoard } from '@/companies/board/components/CompanyBoard'; import { CompanyBoardRecoilScopeContext } from '@/companies/states/recoil-scope-contexts/CompanyBoardRecoilScopeContext'; import { useUpdateOneObjectRecord } from '@/object-record/hooks/useUpdateOneObjectRec...
2,752
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/opportunities/opportunitiesBoardOptions.tsx
import { CompanyBoardCard } from '@/companies/components/CompanyBoardCard'; import { NewOpportunityButton } from '@/companies/components/NewOpportunityButton'; import { BoardOptions } from '@/ui/object/record-board/types/BoardOptions'; export const opportunitiesBoardOptions: BoardOptions = { newCardComponent: <NewOp...
2,753
0
petrpan-code/twentyhq/twenty/front/src/pages/opportunities
petrpan-code/twentyhq/twenty/front/src/pages/opportunities/__stories__/Opportunities.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { userEvent, within } from '@storybook/testing-library'; import { AppPath } from '@/types/AppPath'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { Oppo...
2,754
0
petrpan-code/twentyhq/twenty/front/src/pages/opportunities
petrpan-code/twentyhq/twenty/front/src/pages/opportunities/constants/opportunityBoardFilterDefinitions.tsx
import { Opportunity } from '@/pipeline/types/Opportunity'; import { FilterDefinitionByEntity } from '@/ui/object/object-filter-dropdown/types/FilterDefinitionByEntity'; export const opportunityBoardFilterDefinitions: FilterDefinitionByEntity<Opportunity>[] = [ { fieldMetadataId: 'amount', label: 'Am...
2,755
0
petrpan-code/twentyhq/twenty/front/src/pages/opportunities
petrpan-code/twentyhq/twenty/front/src/pages/opportunities/constants/opportunityBoardSortDefinitions.tsx
import { SortDefinition } from '@/ui/object/object-sort-dropdown/types/SortDefinition'; export const opportunityBoardSortDefinitions: SortDefinition[] = [ { fieldMetadataId: 'createdAt', label: 'Creation', iconName: 'IconCalendarEvent', }, { fieldMetadataId: 'amount', label: 'Amount', ico...
2,756
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/settings/SettingsExperience.tsx
import styled from '@emotion/styled'; import { SettingsPageContainer } from '@/settings/components/SettingsPageContainer'; import { IconSettings } from '@/ui/display/icon'; import { H1Title } from '@/ui/display/typography/components/H1Title'; import { H2Title } from '@/ui/display/typography/components/H2Title'; import...
2,757
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/settings/SettingsProfile.tsx
import styled from '@emotion/styled'; import { SettingsPageContainer } from '@/settings/components/SettingsPageContainer'; import { DeleteAccount } from '@/settings/profile/components/DeleteAccount'; import { EmailField } from '@/settings/profile/components/EmailField'; import { NameFields } from '@/settings/profile/c...
2,758
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/settings/SettingsWorkspace.tsx
import styled from '@emotion/styled'; import { SettingsPageContainer } from '@/settings/components/SettingsPageContainer'; import { DeleteWorkspace } from '@/settings/profile/components/DeleteWorkspace'; import { NameField } from '@/settings/workspace/components/NameField'; import { ToggleImpersonate } from '@/setting...
2,759
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/settings/SettingsWorkspaceMembers.tsx
import { useState } from 'react'; import styled from '@emotion/styled'; import { useRecoilValue } from 'recoil'; import { currentWorkspaceState } from '@/auth/states/currentWorkspaceState'; import { useDeleteOneObjectRecord } from '@/object-record/hooks/useDeleteOneObjectRecord'; import { useFindManyObjectRecords } fr...
2,760
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/__stories__/SettingsExperience.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { SettingsExperience } from '../SettingsExperience'; const meta: Meta<PageDecoratorArgs> = { title: 'Pages/Set...
2,761
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/__stories__/SettingsProfile.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { within } from '@storybook/testing-library'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { SettingsProfile } from '../SettingsProfile'; const meta: ...
2,762
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/__stories__/SettingsWorkspace.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { SettingsWorkspace } from '../SettingsWorkspace'; const meta: Meta<PageDecoratorArgs> = { title: 'Pages/Setti...
2,763
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/__stories__/SettingsWorkspaceMembers.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { within } from '@storybook/testing-library'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { SettingsWorkspace...
2,764
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/SettingsNewObject.tsx
import { useState } from 'react'; import { useNavigate } from 'react-router-dom'; import { useObjectMetadataItemForSettings } from '@/object-metadata/hooks/useObjectMetadataItemForSettings'; import { getObjectSlug } from '@/object-metadata/utils/getObjectSlug'; import { SaveAndCancelButtons } from '@/settings/componen...
2,765
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/SettingsObjectDetail.tsx
import { useEffect } from 'react'; import { useNavigate, useParams } from 'react-router-dom'; import styled from '@emotion/styled'; import { useFieldMetadataItem } from '@/object-metadata/hooks/useFieldMetadataItem'; import { useObjectMetadataItemForSettings } from '@/object-metadata/hooks/useObjectMetadataItemForSett...
2,766
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/SettingsObjectEdit.tsx
import { useEffect, useState } from 'react'; import { useNavigate, useParams } from 'react-router-dom'; import { useObjectMetadataItemForSettings } from '@/object-metadata/hooks/useObjectMetadataItemForSettings'; import { getObjectSlug } from '@/object-metadata/utils/getObjectSlug'; import { SaveAndCancelButtons } fro...
2,767
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/SettingsObjectFieldEdit.tsx
import { useEffect } from 'react'; import { useNavigate, useParams } from 'react-router-dom'; import { useFieldMetadataItem } from '@/object-metadata/hooks/useFieldMetadataItem'; import { useObjectMetadataItemForSettings } from '@/object-metadata/hooks/useObjectMetadataItemForSettings'; import { useRelationMetadata } ...
2,768
0
petrpan-code/twentyhq/twenty/front/src/pages/settings
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/SettingsObjects.tsx
import { useNavigate } from 'react-router-dom'; import { useTheme } from '@emotion/react'; import styled from '@emotion/styled'; import { useObjectMetadataItemForSettings } from '@/object-metadata/hooks/useObjectMetadataItemForSettings'; import { getObjectSlug } from '@/object-metadata/utils/getObjectSlug'; import { S...
2,769
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/SettingsObjectNewField/SettingsObjectNewFieldStep1.tsx
import { useEffect, useState } from 'react'; import { useNavigate, useParams } from 'react-router-dom'; import styled from '@emotion/styled'; import { useFieldMetadataItem } from '@/object-metadata/hooks/useFieldMetadataItem'; import { useObjectMetadataItemForSettings } from '@/object-metadata/hooks/useObjectMetadataI...
2,770
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/SettingsObjectNewField/SettingsObjectNewFieldStep2.tsx
import { useEffect, useState } from 'react'; import { useNavigate, useParams } from 'react-router-dom'; import { useCreateOneRelationMetadata } from '@/object-metadata/hooks/useCreateOneRelationMetadata'; import { useFieldMetadataItem } from '@/object-metadata/hooks/useFieldMetadataItem'; import { useObjectMetadataIte...
2,771
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__/SettingsNewObject.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { userEvent, within } from '@storybook/testing-library'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { Settin...
2,772
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__/SettingsObjectDetail.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { SettingsObjectDetail } from '../SettingsObjectDetail'; const meta: Me...
2,773
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__/SettingsObjectEdit.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { SettingsObjectEdit } from '../SettingsObjectEdit'; const meta: Meta<P...
2,774
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__/SettingsObjectFieldEdit.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { SettingsObjectFieldEdit } from '../SettingsObjectFieldEdit'; const meta: Meta<PageDecoratorArgs> = { title: ...
2,775
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__/SettingsObjects.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { within } from '@storybook/testing-library'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { SettingsObjects }...
2,776
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__/SettingsObjectNewField/SettingsObjectNewFieldStep1.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { SettingsObjectNewFieldStep1 } from '../../SettingsObjectNewField/Setti...
2,777
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__
petrpan-code/twentyhq/twenty/front/src/pages/settings/data-model/__stories__/SettingsObjectNewField/SettingsObjectNewFieldStep2.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { SettingsObjectNewFieldStep2 } from '../../SettingsObjectNewField/Setti...
2,778
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys/SettingsDevelopersApiKeyDetail.tsx
import { useEffect } from 'react'; import { useNavigate, useParams } from 'react-router-dom'; import styled from '@emotion/styled'; import { DateTime } from 'luxon'; import { useRecoilState } from 'recoil'; import { useOptimisticEvict } from '@/apollo/optimistic-effect/hooks/useOptimisticEvict'; import { useCreateOneO...
2,779
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys/SettingsDevelopersApiKeys.tsx
import { useState } from 'react'; import { useNavigate } from 'react-router-dom'; import styled from '@emotion/styled'; import { useOptimisticEffect } from '@/apollo/optimistic-effect/hooks/useOptimisticEffect'; import { useObjectMetadataItem } from '@/object-metadata/hooks/useObjectMetadataItem'; import { getRecordOp...
2,780
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys/SettingsDevelopersApiKeysNew.tsx
import { useState } from 'react'; import { useNavigate } from 'react-router-dom'; import { DateTime } from 'luxon'; import { useCreateOneObjectRecord } from '@/object-record/hooks/useCreateOneObjectRecord'; import { SaveAndCancelButtons } from '@/settings/components/SaveAndCancelButtons/SaveAndCancelButtons'; import {...
2,781
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys/__stories__/SettingsDevelopersApiKeys.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { SettingsDevelopersApiKeys } from '~/pages/settings/developers/api-keys/SettingsDevelopersApiKeys'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { slee...
2,782
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys/__stories__/SettingsDevelopersApiKeysDetail.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { SettingsDevelopersApiKeyDetail } from '~/pages/settings/developers/api-keys/SettingsDevelopersApiKeyDetail'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; imp...
2,783
0
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys
petrpan-code/twentyhq/twenty/front/src/pages/settings/developers/api-keys/__stories__/SettingsDevelopersApiKeysNew.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { SettingsDevelopersApiKeysNew } from '~/pages/settings/developers/api-keys/SettingsDevelopersApiKeysNew'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import ...
2,784
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/tasks/Tasks.tsx
import styled from '@emotion/styled'; import { TasksRecoilScopeContext } from '@/activities/states/recoil-scope-contexts/TasksRecoilScopeContext'; import { PageAddTaskButton } from '@/activities/tasks/components/PageAddTaskButton'; import { TaskGroups } from '@/activities/tasks/components/TaskGroups'; import { IconArc...
2,785
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/tasks/TasksEffect.tsx
import { useEffect } from 'react'; import { useRecoilValue } from 'recoil'; import { currentWorkspaceMemberState } from '@/auth/states/currentWorkspaceMemberState'; import { useFilter } from '@/ui/object/object-filter-dropdown/hooks/useFilter'; import { ViewFilterOperand } from '@/views/types/ViewFilterOperand'; impo...
2,786
0
petrpan-code/twentyhq/twenty/front/src/pages
petrpan-code/twentyhq/twenty/front/src/pages/tasks/tasks-filter-definitions.tsx
import { Activity } from '@/activities/types/Activity'; import { IconUserCircle } from '@/ui/display/icon'; import { FilterDefinitionByEntity } from '@/ui/object/object-filter-dropdown/types/FilterDefinitionByEntity'; export const tasksFilterDefinitions: FilterDefinitionByEntity<Activity>[] = [ { fieldMetadataId...
2,787
0
petrpan-code/twentyhq/twenty/front/src/pages/tasks
petrpan-code/twentyhq/twenty/front/src/pages/tasks/__stories__/Tasks.stories.tsx
import { Meta, StoryObj } from '@storybook/react'; import { AppPath } from '@/types/AppPath'; import { PageDecorator, PageDecoratorArgs, } from '~/testing/decorators/PageDecorator'; import { graphqlMocks } from '~/testing/graphqlMocks'; import { sleep } from '~/testing/sleep'; import { Tasks } from '../Tasks'; c...
2,788
0
petrpan-code/twentyhq/twenty/front/src
petrpan-code/twentyhq/twenty/front/src/testing/ComponentStorybookLayout.tsx
import styled from '@emotion/styled'; const StyledLayout = styled.div<{ width?: number }>` background: ${({ theme }) => theme.background.primary}; border: 1px solid ${({ theme }) => theme.border.color.light}; border-radius: 5px; display: flex; flex-direction: row; height: fit-content; max-width: calc(1...
2,789
0
petrpan-code/twentyhq/twenty/front/src
petrpan-code/twentyhq/twenty/front/src/testing/FullHeightStorybookLayout.tsx
import styled from '@emotion/styled'; const StyledLayout = styled.div` display: flex; flex-direction: row; height: calc(100vh - 32px); width: calc(100vw - 32px); `; type FullHeightStorybookLayoutProps = { children: JSX.Element; }; export const FullHeightStorybookLayout = ({ children, }: FullHeightStorybo...
2,790
0
petrpan-code/twentyhq/twenty/front/src
petrpan-code/twentyhq/twenty/front/src/testing/InitializeHotkeyStorybookHook.tsx
import { useEffect } from 'react'; import { useSetHotkeyScope } from '@/ui/utilities/hotkey/hooks/useSetHotkeyScope'; import { AppHotkeyScope } from '@/ui/utilities/hotkey/types/AppHotkeyScope'; export const InitializeHotkeyStorybookHookEffect = () => { const setHotkeyScope = useSetHotkeyScope(); useEffect(() =>...
2,791
0
petrpan-code/twentyhq/twenty/front/src
petrpan-code/twentyhq/twenty/front/src/testing/graphqlMocks.ts
import { getOperationName } from '@apollo/client/utilities'; import { graphql } from 'msw'; import { CREATE_EVENT } from '@/analytics/graphql/queries/createEvent'; import { GET_CLIENT_CONFIG } from '@/client-config/graphql/queries/getClientConfig'; import { FIND_MANY_METADATA_OBJECTS } from '@/object-metadata/graphql/...
2,792
0
petrpan-code/twentyhq/twenty/front/src
petrpan-code/twentyhq/twenty/front/src/testing/mockedClient.ts
import { ApolloClient, InMemoryCache } from '@apollo/client'; export const mockedClient = new ApolloClient({ uri: process.env.REACT_APP_SERVER_BASE_URL + '/graphql', cache: new InMemoryCache(), });
2,793
0
petrpan-code/twentyhq/twenty/front/src
petrpan-code/twentyhq/twenty/front/src/testing/sleep.ts
export const sleep = async (ms: number) => new Promise((resolve) => { setTimeout(resolve, ms); });
2,794
0
petrpan-code/twentyhq/twenty/front/src
petrpan-code/twentyhq/twenty/front/src/testing/types.ts
import { ElementType } from 'react'; import { StoryObj } from '@storybook/react'; import { CatalogDimension, CatalogOptions, } from './decorators/CatalogDecorator'; export type CatalogStory< StoryType extends StoryObj<ComponentType>, ComponentType extends ElementType, > = { args?: StoryType['args']; argTy...
2,795
0
petrpan-code/twentyhq/twenty/front/src/testing
petrpan-code/twentyhq/twenty/front/src/testing/decorators/CatalogDecorator.tsx
import { ComponentProps, JSX } from 'react'; import styled from '@emotion/styled'; import { isNumber, isString } from '@sniptt/guards'; import { Decorator } from '@storybook/react'; const StyledColumnTitle = styled.h1` font-size: ${({ theme }) => theme.font.size.lg}; font-weight: ${({ theme }) => theme.font.weight...
2,796
0
petrpan-code/twentyhq/twenty/front/src/testing
petrpan-code/twentyhq/twenty/front/src/testing/decorators/ComponentDecorator.tsx
import { Decorator } from '@storybook/react'; import { ComponentStorybookLayout } from '../ComponentStorybookLayout'; export const ComponentDecorator: Decorator = (Story, context) => { const { container } = context.parameters; return ( <ComponentStorybookLayout width={container?.width}> <Story /> <...
2,797
0
petrpan-code/twentyhq/twenty/front/src/testing
petrpan-code/twentyhq/twenty/front/src/testing/decorators/ComponentWithRecoilScopeDecorator.tsx
import { Decorator } from '@storybook/react'; import { RecoilScope } from '@/ui/utilities/recoil-scope/components/RecoilScope'; export const ComponentWithRecoilScopeDecorator: Decorator = ( Story, context, ) => ( <RecoilScope CustomRecoilScopeContext={context.parameters.customRecoilScopeContext} > <St...
2,798
0
petrpan-code/twentyhq/twenty/front/src/testing
petrpan-code/twentyhq/twenty/front/src/testing/decorators/ComponentWithRouterDecorator.tsx
import { MemoryRouter } from 'react-router-dom'; import { Decorator } from '@storybook/react'; import { ComponentStorybookLayout } from '../ComponentStorybookLayout'; export const ComponentWithRouterDecorator: Decorator = (Story) => ( <ComponentStorybookLayout> <MemoryRouter> <Story /> </MemoryRouter>...
2,799