Socket
Socket
Sign inDemoInstall

@contentful/f36-typography

Package Overview
Dependencies
Maintainers
100
Versions
400
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@contentful/f36-typography - npm Package Compare versions

Comparing version 4.0.1-next-v4-4466.1998 to 4.0.1-next-v4-4479.1999

2

dist/module.js

@@ -1,2 +0,2 @@

import e from"@babel/runtime/helpers/esm/extends";import{css as t,cx as i}from"emotion";import a,{useContext as n,createContext as r}from"react";import o from"@contentful/f36-tokens";import{Box as s}from"@contentful/f36-core";function l(e,t,i,a){Object.defineProperty(e,t,{get:i,set:a,enumerable:!0,configurable:!0})}var c={};l(c,"Heading",(()=>h)),l(c,"Subheading",(()=>u)),l(c,"Typography",(()=>m)),l(c,"DisplayText",(()=>H)),l(c,"SectionHeading",(()=>y)),l(c,"Paragraph",(()=>b));const g={displayText:"spacingL",displayTextLarge:"spacingXl",heading:"spacingM",paragraph:"spacingM",sectionHeading:"spacingL",subheading:"spacingM"},f=r({});function m(t){return a.createElement(f.Provider,{value:g},a.createElement(s,e({testId:"cf-ui-text-container"},t)))}const d=({children:r,className:l,...c},g)=>{const m=n(f);return a.createElement(s,e({as:"h1",display:"block",margin:"none",marginBottom:m.heading,testId:"cf-ui-heading",className:i(t({fontFamily:o.fontStackPrimary,fontWeight:o.fontWeightDemiBold,color:o.colorTextDark,fontSize:o.fontSizeXl,lineHeight:o.lineHeightXl,textRendering:"optimizeLegibility"},""),l)},c,{ref:g}),r)},h=a.forwardRef(d),p=({children:r,className:s,...l},c)=>{const g=n(f);return a.createElement(h,e({as:"h2",testId:"cf-ui-subheading",marginBottom:g.subheading,className:i(t({fontSize:o.fontSizeL,lineHeight:o.lineHeightL},""),s)},l,{ref:c}),r)},u=a.forwardRef(p),S=({children:r,className:s,size:l="default",...c},g)=>{const m=n(f);let d="";return d=t("huge"===l?{fontSize:o.fontSize4Xl,lineHeight:o.lineHeight4Xl}:"large"===l?{fontSize:o.fontSize3Xl,lineHeight:o.lineHeight3Xl}:{fontSize:o.fontSize2Xl,lineHeight:o.lineHeight2Xl},""),a.createElement(h,e({as:"h1",testId:"cf-ui-display-text",marginBottom:"default"===l?m.displayText:m.displayTextLarge,className:i(d,s)},c,{ref:g}),r)},H=a.forwardRef(S),x=({children:r,className:s,...l},c)=>{const g=n(f);return a.createElement(h,e({as:"h3",testId:"cf-ui-section-heading",marginBottom:g.sectionHeading,className:i(t({fontSize:o.fontSizeS,lineHeight:o.lineHeightS,letterSpacing:o.letterSpacingWide,textTransform:"uppercase"},""),s)},l,{ref:c}),r)},y=a.forwardRef(x),z=({children:r,className:s,...l},c)=>{const g=n(f);return a.createElement(h,e({as:"p",testId:"cf-ui-paragraph",marginBottom:g.paragraph,className:i(t({fontWeight:o.fontWeightNormal,color:o.colorTextMid,fontSize:o.fontSizeM,lineHeight:o.lineHeightM},""),s)},l,{ref:c}),r)},b=a.forwardRef(z);export{h as Heading,u as Subheading,m as Typography,H as DisplayText,y as SectionHeading,b as Paragraph};
import e from"@babel/runtime/helpers/esm/extends";import{cx as t,css as i}from"emotion";import a,{useContext as n,createContext as r}from"react";import o from"@contentful/f36-tokens";import{Box as s}from"@contentful/f36-core";function l(e,t,i,a){Object.defineProperty(e,t,{get:i,set:a,enumerable:!0,configurable:!0})}var c={};l(c,"Heading",(()=>h)),l(c,"Subheading",(()=>u)),l(c,"Typography",(()=>m)),l(c,"DisplayText",(()=>H)),l(c,"SectionHeading",(()=>y)),l(c,"Paragraph",(()=>b));const g={displayText:"spacingL",displayTextLarge:"spacingXl",heading:"spacingM",paragraph:"spacingM",sectionHeading:"spacingL",subheading:"spacingM"},f=r({});function m(t){return a.createElement(f.Provider,{value:g},a.createElement(s,e({testId:"cf-ui-text-container"},t)))}const d=({children:r,className:l,...c},g)=>{const m=n(f);return a.createElement(s,e({as:"h1",display:"block",margin:"none",marginBottom:m.heading,testId:"cf-ui-heading",className:t(i({fontFamily:o.fontStackPrimary,fontWeight:o.fontWeightDemiBold,color:o.colorTextDark,fontSize:o.fontSizeXl,lineHeight:o.lineHeightXl,textRendering:"optimizeLegibility"},""),l)},c,{ref:g}),r)},h=a.forwardRef(d),p=({children:r,className:s,...l},c)=>{const g=n(f);return a.createElement(h,e({as:"h2",testId:"cf-ui-subheading",marginBottom:g.subheading,className:t(i({fontSize:o.fontSizeL,lineHeight:o.lineHeightL},""),s)},l,{ref:c}),r)},u=a.forwardRef(p),S=({children:r,className:s,size:l="default",...c},g)=>{const m=n(f);let d="";return d=i("huge"===l?{fontSize:o.fontSize4Xl,lineHeight:o.lineHeight4Xl}:"large"===l?{fontSize:o.fontSize3Xl,lineHeight:o.lineHeight3Xl}:{fontSize:o.fontSize2Xl,lineHeight:o.lineHeight2Xl},""),a.createElement(h,e({as:"h1",testId:"cf-ui-display-text",marginBottom:"default"===l?m.displayText:m.displayTextLarge,className:t(d,s)},c,{ref:g}),r)},H=a.forwardRef(S),x=({children:r,className:s,...l},c)=>{const g=n(f);return a.createElement(h,e({as:"h3",testId:"cf-ui-section-heading",marginBottom:g.sectionHeading,className:t(i({fontSize:o.fontSizeS,lineHeight:o.lineHeightS,letterSpacing:o.letterSpacingWide,textTransform:"uppercase"},""),s)},l,{ref:c}),r)},y=a.forwardRef(x),z=({children:r,className:s,...l},c)=>{const g=n(f);return a.createElement(h,e({as:"p",testId:"cf-ui-paragraph",marginBottom:g.paragraph,className:t(i({fontWeight:o.fontWeightNormal,color:o.colorTextMid,fontSize:o.fontSizeM,lineHeight:o.lineHeightM},""),s)},l,{ref:c}),r)},b=a.forwardRef(z);export{h as Heading,u as Subheading,m as Typography,H as DisplayText,y as SectionHeading,b as Paragraph};
//# sourceMappingURL=module.js.map
{
"name": "@contentful/f36-typography",
"version": "4.0.1-next-v4-4466.1998+0fc11f2b",
"version": "4.0.1-next-v4-4479.1999+0a9aea34",
"description": "Forma 36: typography React Component",

@@ -25,4 +25,4 @@ "license": "MIT",

"@babel/runtime": "^7.6.2",
"@contentful/f36-core": "4.0.1-next-v4-4466.1998+0fc11f2b",
"@contentful/f36-tokens": "4.0.1-next-v4-4466.1998+0fc11f2b",
"@contentful/f36-core": "4.0.1-next-v4-4479.1999+0a9aea34",
"@contentful/f36-tokens": "4.0.1-next-v4-4479.1999+0a9aea34",
"emotion": "^10.0.17"

@@ -36,3 +36,3 @@ },

},
"gitHead": "0fc11f2b5c01d0af1d2a88c79b3c2871e0560a1e"
"gitHead": "0a9aea349399cb5b56af6b99c711f189a22583d7"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc