@graphcommerce/graphcms-ui 3.0.6 → 3.0.7

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  # Change Log
2
2
 
3
+ ## 3.0.7
4
+
5
+ ### Patch Changes
6
+
7
+ - [#1353](https://github.com/graphcommerce-org/graphcommerce/pull/1353) [`0e5ee7ba8`](https://github.com/graphcommerce-org/graphcommerce/commit/0e5ee7ba89698e5e711001e846ed182528060cba) Thanks [@paales](https://github.com/paales)! - Eslint: enable rules that were previously disabled and make fixes
8
+
9
+ - Updated dependencies [[`49a2d6617`](https://github.com/graphcommerce-org/graphcommerce/commit/49a2d661712e1787fba46c6195f7b559189e23d9), [`f67da3cfb`](https://github.com/graphcommerce-org/graphcommerce/commit/f67da3cfbe2dcf5ea23519d088c5aa0074029182), [`218766869`](https://github.com/graphcommerce-org/graphcommerce/commit/218766869f7468c067a590857c942f3819f8add4), [`0e5ee7ba8`](https://github.com/graphcommerce-org/graphcommerce/commit/0e5ee7ba89698e5e711001e846ed182528060cba), [`829b8690b`](https://github.com/graphcommerce-org/graphcommerce/commit/829b8690bc5d0a46e596299e4120e9837a9f179c)]:
10
+ - @graphcommerce/next-ui@4.4.0
11
+
3
12
  ## 3.0.6
4
13
 
5
14
  ### Patch Changes
@@ -121,7 +121,7 @@ function RenderElement(element: ElementNode & AdditionalProps) {
121
121
 
122
122
  if (process.env.NODE_ENV !== 'production') {
123
123
  console.error(element)
124
- throw Error(`RichText: Unknown Element: ${element.type}`)
124
+ throw Error(`RichText: Unknown Element: ${type}`)
125
125
  }
126
126
  return <RenderChildren childNodes={children} sxRenderer={sxRenderer} renderers={renderers} />
127
127
  }
@@ -27,9 +27,9 @@ export const defaultRenderers: Renderers = {
27
27
  video: ({ src, width, height, title, mimeType }) => (
28
28
  <Asset asset={{ url: src, alt: title, width, height, mimeType }} />
29
29
  ),
30
- link: ({ href, ...props }) => (
30
+ link: ({ href, openInNewTab, ...props }) => (
31
31
  <PageLink href={href} passHref>
32
- <Link underline='hover' {...props} />
32
+ <Link underline='hover' {...props} target={openInNewTab ? '_blank' : undefined} />
33
33
  </PageLink>
34
34
  ),
35
35
  table: (props) => <Box component='table' {...props} />,
@@ -43,6 +43,7 @@ type LinkElement = {
43
43
  type: 'link'
44
44
  children: ElementOrTextNode[]
45
45
  href: string
46
+ openInNewTab?: boolean
46
47
  }
47
48
 
48
49
  type ImageElement = {
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/graphcms-ui",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "3.0.6",
5
+ "version": "3.0.7",
6
6
  "sideEffects": false,
7
7
  "prettier": "@graphcommerce/prettier-config-pwa",
8
8
  "eslintConfig": {
@@ -12,7 +12,7 @@
12
12
  }
13
13
  },
14
14
  "devDependencies": {
15
- "@graphcommerce/eslint-config-pwa": "^4.0.5",
15
+ "@graphcommerce/eslint-config-pwa": "^4.1.2",
16
16
  "@graphcommerce/prettier-config-pwa": "^4.0.3",
17
17
  "@graphcommerce/typescript-config-pwa": "^4.0.2",
18
18
  "@playwright/test": "^1.19.2"
@@ -20,7 +20,7 @@
20
20
  "dependencies": {
21
21
  "@graphcommerce/graphql": "^3.0.4",
22
22
  "@graphcommerce/image": "^3.1.1",
23
- "@graphcommerce/next-ui": "^4.3.0",
23
+ "@graphcommerce/next-ui": "^4.4.0",
24
24
  "type-fest": "^2.12.0"
25
25
  },
26
26
  "peerDependencies": {