@graphcommerce/next-ui 4.23.0 → 4.23.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  import { SxProps, ButtonBase, Box, Theme, alpha } from '@mui/material'
2
- import React, { FormEvent } from 'react'
2
+ import React from 'react'
3
3
  import { extendableComponent } from '../Styles'
4
4
  import { breakpointVal } from '../Styles/breakpointVal'
5
5
 
@@ -104,23 +104,22 @@ export const ActionCardList = React.forwardRef<HTMLDivElement, ActionCardListPro
104
104
  <Box
105
105
  ref={ref}
106
106
  sx={[
107
- error &&
108
- ((theme) => ({
109
- '& .ActionCard-root': {
110
- borderLeft: 2,
111
- borderRight: 2,
112
- borderLeftColor: 'error.main',
113
- borderRightColor: 'error.main',
114
- },
115
- '& > div:first-of-type.ActionCard-root': {
116
- borderTop: 2,
117
- borderTopColor: 'error.main',
118
- },
119
- '& > div:last-of-type.ActionCard-root': {
120
- borderBottom: 2,
121
- borderBottomColor: 'error.main',
122
- },
123
- })),
107
+ error && {
108
+ '& .ActionCard-root': {
109
+ borderLeft: 2,
110
+ borderRight: 2,
111
+ borderLeftColor: 'error.main',
112
+ borderRightColor: 'error.main',
113
+ },
114
+ '& > div:first-of-type.ActionCard-root': {
115
+ borderTop: 2,
116
+ borderTopColor: 'error.main',
117
+ },
118
+ '& > div:last-of-type.ActionCard-root': {
119
+ borderBottom: 2,
120
+ borderBottomColor: 'error.main',
121
+ },
122
+ },
124
123
  ]}
125
124
  >
126
125
  {childReactNodes.map((child) =>
@@ -2,7 +2,6 @@ import { Box, SxProps, Theme } from '@mui/material'
2
2
  import React from 'react'
3
3
  import { extendableComponent } from '../../Styles'
4
4
  import { breakpointVal } from '../../Styles/breakpointVal'
5
- import { responsiveVal } from '../../Styles/responsiveVal'
6
5
 
7
6
  export type BlogHeaderProps = {
8
7
  sx?: SxProps<Theme>
package/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  # Change Log
2
2
 
3
+ ## 4.23.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [#1624](https://github.com/graphcommerce-org/graphcommerce/pull/1624) [`9b84a68a1`](https://github.com/graphcommerce-org/graphcommerce/commit/9b84a68a1e7311a79eb687c7dcee905d3000facf) Thanks [@paales](https://github.com/paales)! - Create a GetServerSideProps
8
+
9
+ - Updated dependencies []:
10
+ - @graphcommerce/framer-scroller@2.1.35
11
+
3
12
  ## 4.23.0
4
13
 
5
14
  ### Minor Changes
package/Form/Form.tsx CHANGED
@@ -1,6 +1,5 @@
1
1
  import { darken, lighten, styled, Theme } from '@mui/material'
2
2
  import { breakpointVal } from '../Styles/breakpointVal'
3
- import { responsiveVal } from '../Styles/responsiveVal'
4
3
  import { sx } from '../Theme/themeDefaults'
5
4
 
6
5
  type FormStyleProps = {
@@ -1,4 +1,4 @@
1
- import { useIsomorphicLayoutEffect, useMotionValueValue } from '@graphcommerce/framer-utils'
1
+ import { useMotionValueValue } from '@graphcommerce/framer-utils'
2
2
  import {
3
3
  Divider,
4
4
  Fab,
@@ -13,7 +13,7 @@ import {
13
13
  } from '@mui/material'
14
14
  import { m } from 'framer-motion'
15
15
  import { useRouter } from 'next/router'
16
- import React, { useEffect, useCallback, useRef } from 'react'
16
+ import React, { useEffect } from 'react'
17
17
  import { IconSvg } from '../IconSvg'
18
18
  import { useScrollY } from '../Layout/hooks/useScrollY'
19
19
  import { extendableComponent } from '../Styles/extendableComponent'
@@ -70,7 +70,7 @@ export const NavigationItem = React.memo<NavigationItemProps>((props) => {
70
70
  const column = hidingRoot ? itemPath.length - 1 : itemPath.length
71
71
  const classes = withState({ first, last, column: itemPath.length })
72
72
 
73
- const onCloseHandler: React.MouseEventHandler<HTMLAnchorElement> = useEventCallback((e) => {
73
+ const onCloseHandler: React.MouseEventHandler<HTMLAnchorElement> = useEventCallback(() => {
74
74
  if (!isNavigationHref(props)) return
75
75
  closing.set(true)
76
76
  })
@@ -3,8 +3,8 @@ import { useMotionValueValue, useMotionSelector } from '@graphcommerce/framer-ut
3
3
  import { i18n } from '@lingui/core'
4
4
  import { Trans } from '@lingui/react'
5
5
  import { Box, Fab, SxProps, Theme, useEventCallback, useMediaQuery } from '@mui/material'
6
- import { m, useMotionValue } from 'framer-motion'
7
- import React, { startTransition, useEffect, useRef, useState } from 'react'
6
+ import { m } from 'framer-motion'
7
+ import React, { useEffect } from 'react'
8
8
  import type { LiteralUnion } from 'type-fest'
9
9
  import { IconSvg, useIconSvgSize } from '../../IconSvg'
10
10
  import { LayoutHeaderContent } from '../../Layout/components/LayoutHeaderContent'
@@ -1,5 +1,5 @@
1
1
  import { MotionConfig, useMotionValue } from 'framer-motion'
2
- import React, { useMemo, useRef } from 'react'
2
+ import React, { useMemo } from 'react'
3
3
  import { isElement } from 'react-is'
4
4
  import {
5
5
  NavigationNode,
package/Page/types.ts CHANGED
@@ -3,7 +3,10 @@ import { UpPage } from '@graphcommerce/framer-next-pages/types'
3
3
  // todo: remove references to GraphQL
4
4
  // eslint-disable-next-line import/no-extraneous-dependencies
5
5
  import { NormalizedCacheObject } from '@graphcommerce/graphql'
6
- import { GetStaticProps as GetStaticPropsNext } from 'next'
6
+ import {
7
+ GetStaticProps as GetStaticPropsNext,
8
+ GetServerSideProps as GetServerSidePropsNext,
9
+ } from 'next'
7
10
 
8
11
  type AnyObj = Record<string, unknown>
9
12
 
@@ -14,3 +17,9 @@ export type GetStaticProps<
14
17
  P extends AnyObj = AnyObj,
15
18
  Q extends ParsedUrlQuery = ParsedUrlQuery,
16
19
  > = GetStaticPropsNext<P & Omit<PL, 'children'> & ApolloStateProps, Q>
20
+
21
+ export type GetServerSideProps<
22
+ PL extends AnyObj,
23
+ P extends AnyObj = AnyObj,
24
+ Q extends ParsedUrlQuery = ParsedUrlQuery,
25
+ > = GetServerSidePropsNext<P & Omit<PL, 'children'> & ApolloStateProps, Q>
@@ -1,6 +1,5 @@
1
1
  import { Box, SxProps, Theme } from '@mui/material'
2
2
  import { extendableComponent } from '../Styles'
3
- import { responsiveVal } from '../Styles/responsiveVal'
4
3
 
5
4
  export type StepperProps = {
6
5
  steps: number
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/next-ui",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "4.23.0",
5
+ "version": "4.23.1",
6
6
  "author": "",
7
7
  "license": "MIT",
8
8
  "sideEffects": false,
@@ -20,7 +20,7 @@
20
20
  "@emotion/server": "^11.4.0",
21
21
  "@emotion/styled": "^11.9.3",
22
22
  "@graphcommerce/framer-next-pages": "3.3.0",
23
- "@graphcommerce/framer-scroller": "2.1.34",
23
+ "@graphcommerce/framer-scroller": "2.1.35",
24
24
  "@graphcommerce/framer-utils": "3.2.0",
25
25
  "@graphcommerce/image": "3.1.9",
26
26
  "cookie": "^0.5.0",