Skip to content

Commit

Permalink
refactor(core): move ReviewChangesContext to singletons
Browse files Browse the repository at this point in the history
  • Loading branch information
binoy14 committed Apr 29, 2024
1 parent cab8131 commit 79e4bfa
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import {createContext} from 'react'

import {type ReviewChangesContextValue} from './types'
import type {ReviewChangesContextValue} from 'sanity'

/**
* @internal
Expand Down
1 change: 1 addition & 0 deletions packages/sanity/src/_singletons/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,5 @@ export * from './form/studio/DocumentFieldActionsContext'
export * from './form/studio/FormCallbacksContext'
export * from './form/studio/PresenceContext'
export * from './form/studio/ReferenceInputOptionsContext'
export * from './form/studio/reviewChanges/ReviewChangesContext'
export * from './form/studio/ValidationContext'
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {type ReactElement, type ReactNode, useMemo} from 'react'
import {ReviewChangesContext} from 'sanity/_singletons'

import {ReviewChangesContext} from './ReviewChangesContext'
import {type ReviewChangesContextValue} from './types'

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
export * from './ReviewChangesContext'
export * from './types'
export * from './useReviewChanges'
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {useContext} from 'react'
import {ReviewChangesContext} from 'sanity/_singletons'

import {ReviewChangesContext} from './ReviewChangesContext'
import {type ReviewChangesContextValue} from './types'

/**
Expand Down

0 comments on commit 79e4bfa

Please sign in to comment.