Skip to content

Commit

Permalink
fix: remove vite.config temp file
Browse files Browse the repository at this point in the history
  • Loading branch information
pedrobonamin committed Nov 4, 2024
1 parent dc5175f commit e2e5574
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 67 deletions.
90 changes: 45 additions & 45 deletions apps/page-builder-demo/src/sanity.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -694,30 +694,6 @@ export type FrontPageQueryResult = null | {
style: null
}

// Source: ./src/app/dnd/page.tsx
// Variable: dndPageQuery
// Query: *[_type == "dndTestPage"]{ _id, title, children }[0]
export type DndPageQueryResult = {
_id: string
title: string | null
children: Array<{
title?: string
childrenStrings?: Array<string>
children?: Array<{
title?: string
children?: Array<{
title?: string
_type: 'dndTestItemChildL2'
_key: string
}>
_type: 'dndTestItemChildL1'
_key: string
}>
_type: 'dndTestItem'
_key: string
}> | null
} | null

// Source: ./src/app/products/page.tsx
// Variable: productsPageQuery
// Query: *[_type == "product" && defined(slug.current)]{ _id, title, description, slug, "media": media[0] }
Expand Down Expand Up @@ -758,6 +734,30 @@ export type ProductsPageQueryResult = Array<{
} | null
}>

// Source: ./src/app/dnd/page.tsx
// Variable: dndPageQuery
// Query: *[_type == "dndTestPage"]{ _id, title, children }[0]
export type DndPageQueryResult = {
_id: string
title: string | null
children: Array<{
title?: string
childrenStrings?: Array<string>
children?: Array<{
title?: string
children?: Array<{
title?: string
_type: 'dndTestItemChildL2'
_key: string
}>
_type: 'dndTestItemChildL1'
_key: string
}>
_type: 'dndTestItem'
_key: string
}> | null
} | null

// Source: ./src/app/projects/page.tsx
// Variable: projectsPageQuery
// Query: *[_type == "project" && defined(slug.current)]
Expand Down Expand Up @@ -919,24 +919,6 @@ export type PageSlugsResult = Array<{
slug: string | null
}>

// Source: ./src/app/project/[slug]/page.tsx
// Variable: projectSlugsQuery
// Query: *[_type == "project" && defined(slug.current)]{"slug": slug.current}
export type ProjectSlugsQueryResult = Array<{
slug: string | null
}>
// Variable: projectPageQuery
// Query: *[_type == "project" && slug.current == $slug][0]
export type ProjectPageQueryResult = {
_id: string
_type: 'project'
_createdAt: string
_updatedAt: string
_rev: string
title?: string
slug?: Slug
} | null

// Source: ./src/app/product/[slug]/page.tsx
// Variable: productSlugsQuery
// Query: *[_type == "product" && defined(slug.current)]{"slug": slug.current}
Expand Down Expand Up @@ -1035,18 +1017,36 @@ export type ProductPageQueryResult = {
}>
} | null

// Source: ./src/app/project/[slug]/page.tsx
// Variable: projectSlugsQuery
// Query: *[_type == "project" && defined(slug.current)]{"slug": slug.current}
export type ProjectSlugsQueryResult = Array<{
slug: string | null
}>
// Variable: projectPageQuery
// Query: *[_type == "project" && slug.current == $slug][0]
export type ProjectPageQueryResult = {
_id: string
_type: 'project'
_createdAt: string
_updatedAt: string
_rev: string
title?: string
slug?: Slug
} | null

declare module '@sanity/client' {
interface SanityQueries {
'\n *[_id == "siteSettings"][0]{\n title,\n description,\n copyrightText\n}': LayoutQueryResult
"\n *[_id == \"siteSettings\"][0]{\n frontPage->{\n _type,\n _id,\n title,\n sections[]{\n ...,\n symbol->{_type},\n 'headline': coalesce(headline, symbol->headline),\n 'tagline': coalesce(tagline, symbol->tagline),\n 'subline': coalesce(subline, symbol->subline),\n 'image': coalesce(image, symbol->image),\n product->{\n _type,\n _id,\n title,\n slug,\n \"media\": media[0]\n },\n products[]{\n _key,\n ...(@->{\n _type,\n _id,\n title,\n slug,\n \"media\": media[0]\n })\n }\n },\n style\n }\n }.frontPage\n": FrontPageQueryResult
'\n *[_type == "dndTestPage"]{\n _id,\n title,\n children\n }[0]\n': DndPageQueryResult
'\n *[_type == "product" && defined(slug.current)]{\n _id,\n title,\n description,\n slug,\n "media": media[0]\n }\n': ProductsPageQueryResult
'\n *[_type == "dndTestPage"]{\n _id,\n title,\n children\n }[0]\n': DndPageQueryResult
'*[_type == "project" && defined(slug.current)]': ProjectsPageQueryResult
"\n *[_type == \"page\" && slug.current == $slug][0]{\n _type,\n _id,\n title,\n sections[]{\n ...,\n symbol->{_type},\n 'headline': coalesce(headline, symbol->headline),\n 'tagline': coalesce(tagline, symbol->tagline),\n 'subline': coalesce(subline, symbol->subline),\n 'image': coalesce(image, symbol->image),\n product->{\n _type,\n _id,\n title,\n slug,\n \"media\": media[0]\n },\n products[]{\n _key,\n ...(@->{\n _type,\n _id,\n title,\n slug,\n \"media\": media[0]\n })\n }\n },\n style\n }\n": PageQueryResult
'*[_type == "page" && defined(slug.current)]{"slug": slug.current}': PageSlugsResult
'*[_type == "project" && defined(slug.current)]{"slug": slug.current}': ProjectSlugsQueryResult
'*[_type == "project" && slug.current == $slug][0]': ProjectPageQueryResult
'*[_type == "product" && defined(slug.current)]{"slug": slug.current}': ProductSlugsQueryResult
'*[_type == "product" && slug.current == $slug][0]': ProductPageQueryResult
'*[_type == "project" && defined(slug.current)]{"slug": slug.current}': ProjectSlugsQueryResult
'*[_type == "project" && slug.current == $slug][0]': ProjectPageQueryResult
}
}

This file was deleted.

2 changes: 1 addition & 1 deletion packages/presentation/src/PresentationTool.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ export default function PresentationTool(props: {
* By this, we are making the key aware of the excluded perspectives, so it will invalidate the cache.
* Should be ideally fixed in the cache key directly, not here.
*/
([globalPerspective, ...excludedPerspectives].join(',') as `bundle.${string}`)
([globalPerspective, 'exc-', ...excludedPerspectives].join(',') as `bundle.${string}`)
: globalPerspective

const viewport = useMemo(() => (params.viewport ? 'mobile' : 'desktop'), [params.viewport])
Expand Down

0 comments on commit e2e5574

Please sign in to comment.