carbon-react 158.49.0 → 158.49.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 +1 @@
|
|
|
1
|
-
import o,{css as t}from"styled-components";import{margin as i}from"styled-system";import e from"../../style/themes/apply-base-theme.js";import{StyledLinkPreview as n}from"../link-preview/link-preview.style.js";import{VARIANT_TYPES as r}from"../typography/typography.component.js";const a=o.div.withConfig({displayName:"note.style__StyledNoteContent",componentId:"sc-
|
|
1
|
+
import o,{css as t}from"styled-components";import{margin as i}from"styled-system";import e from"../../style/themes/apply-base-theme.js";import{StyledLinkPreview as n}from"../link-preview/link-preview.style.js";import{VARIANT_TYPES as r}from"../typography/typography.component.js";const a=o.div.withConfig({displayName:"note.style__StyledNoteContent",componentId:"sc-39f03fe6-0"})(["position:relative;width:100%;",' &:last-of-type:not(:first-of-type){border-top:solid 1px var(--colorsUtilityMajor050);}a:not([data-component="link-preview"]){color:var(--colorsActionMajor500);&:hover{cursor:pointer;color:var(--colorsActionMajor600);}&:focus{outline:none;text-decoration:none;color:var(--colorsActionMajorYin090);background-color:var(--colorsSemanticFocus250);border-radius:var(--borderRadius025);box-shadow:0 var(--spacing050) 0 0 var(--colorsUtilityYin090);}}'],(({hasPreview:o})=>o&&t(["margin-top:var(--spacing200);"]))),l=o.div.withConfig({displayName:"note.style__StyledNoteMain",componentId:"sc-39f03fe6-1"})(["display:flex;justify-content:space-between;padding-bottom:var(--spacing300);"]),s=o.div.withConfig({displayName:"note.style__StyledInlineControl",componentId:"sc-39f03fe6-2"})(["display:inline-block;min-width:fit-content;"]),p=o.div.withConfig({displayName:"note.style__StyledTitleWrapper",componentId:"sc-39f03fe6-3"})(["",""],r.map((o=>`\n ${o}{\n font-weight: 700;\n font-size: 16px;\n line-height: 21px;\n padding-bottom: 16px;\n }\n `))),c=o.div.withConfig({displayName:"note.style__StyledFooterContent",componentId:"sc-39f03fe6-4"})(["line-height:21px;align-items:baseline;font-weight:500;",""],(({hasName:o})=>t(["margin-top:var(--spacing200);"," ",""],o&&t(["&:first-of-type{font-size:14px;}&:nth-of-type(2){font-size:12px;color:var(--colorsUtilityYin065);margin-left:var(--spacing200);}&:last-of-type:not(:nth-of-type(2)){font-size:12px;color:var(--colorsUtilityYin065);cursor:pointer;margin-left:var(--spacing300);}"]),!o&&t(["&:first-of-type{font-size:12px;color:var(--colorsUtilityYin065);}&:last-of-type:not(:first-of-type){font-size:12px;color:var(--colorsUtilityYin065);cursor:pointer;margin-left:var(--spacing300);}"])))),d=o.div.withConfig({displayName:"note.style__StyledFooter",componentId:"sc-39f03fe6-5"})(["display:flex;margin-bottom:calc(-1 * var(--spacing100));flex-wrap:wrap;"]),f=o.div.attrs(e).withConfig({displayName:"note.style__StyledNote",componentId:"sc-39f03fe6-6"})([""," ","{margin:0px;:not(:first-of-type){margin-top:8px;}}.textBold{font-weight:bold !important;}.textItalic{font-style:italic;}.textUnderline{text-decoration:underline;}",""],(({width:o})=>t(["background-color:var(--colorsUtilityYang100);border:1px solid var(--colorsUtilityMajor100);border-radius:var(--borderRadius100);display:flex;flex-direction:column;padding:24px;position:relative;width:","%;box-sizing:border-box;","{box-sizing:border-box;width:auto;}"],o,a)),n,i);export{d as StyledFooter,c as StyledFooterContent,s as StyledInlineControl,f as StyledNote,a as StyledNoteContent,l as StyledNoteMain,p as StyledTitleWrapper};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{TextNode as t}from"lexical";function
|
|
1
|
+
import{TextNode as t,IS_BOLD as e,IS_ITALIC as i,IS_UNDERLINE as n}from"lexical";function r(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}const o={title:{weight:"700",lineHeight:"30px",size:"24px"},subtitle:{weight:"500",lineHeight:"26.25px",size:"21px"},sectionHeader:{weight:"500",lineHeight:"22.5px",size:"18px"},sectionSubheader:{weight:"500",lineHeight:"20px",size:"16px"},paragraph:{weight:"400",lineHeight:"21px",size:"14px"}};class s extends t{static getType(){return"styled-span"}static clone(t){return new s(t.__text,t.__fontWeight,t.__fontSize,t.__lineHeight,t.__key)}getFontWeight(){return this.__fontWeight}getFontSize(){return this.__fontSize}getLineHeight(){return this.__lineHeight}setFontWeight(t){this.getWritable().__fontWeight=t}setFontSize(t){this.getWritable().__fontSize=t}setLineHeight(t){this.getWritable().__lineHeight=t}getTypographyKey(){for(const t of Object.keys(o)){const{weight:e,size:i,lineHeight:n}=o[t];if(this.__fontWeight===e&&this.__fontSize===i&&this.__lineHeight===n)return t}return"paragraph"}exportDOM(){let t=document.createElement("span");t.style.fontWeight=this.__fontWeight,t.style.fontSize=this.__fontSize,t.style.lineHeight=this.__lineHeight,t.textContent=this.getTextContent();const r=this.getFormat();if(r&e){const e=document.createElement("strong");e.appendChild(t),t=e}if(r&i){const e=document.createElement("em");e.appendChild(t),t=e}if(r&n){const e=document.createElement("u");e.appendChild(t),t=e}return{element:t}}static importDOM(){return{span:t=>({conversion:()=>{const e=t.style.fontWeight||"400",i=t.style.fontSize||"14px",n=t.style.lineHeight||"21px";return{node:new s(t.textContent||"",e,i,n)}},priority:1})}}exportJSON(){return t=function(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{},n=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(i).filter((function(t){return Object.getOwnPropertyDescriptor(i,t).enumerable})))),n.forEach((function(e){r(t,e,i[e])}))}return t}({},super.exportJSON()),e=null!=(e={type:"styled-span",version:1,fontWeight:this.__fontWeight,fontSize:this.__fontSize,lineHeight:this.__lineHeight})?e:{},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):function(t){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e.push.apply(e,i)}return e}(Object(e)).forEach((function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})),t;var t,e}static importJSON(t){return new s(t.text,t.fontWeight,t.fontSize,t.lineHeight).updateFromJSON(t)}createDOM(t){const e=super.createDOM(t);return e.style.fontWeight=this.__fontWeight,e.style.fontSize=this.__fontSize,e.style.lineHeight=this.__lineHeight,e}updateDOM(t,e,i){let n=super.updateDOM(t,e,i);return this.__fontWeight!==t.__fontWeight&&(e.style.fontWeight=this.__fontWeight,n=!0),this.__fontSize!==t.__fontSize&&(e.style.fontSize=this.__fontSize,n=!0),this.__lineHeight!==t.__lineHeight&&(e.style.lineHeight=this.__lineHeight,n=!0),n}static createFromOption(t,e=""){const{weight:i,size:n,lineHeight:r}=o[t];return new s(e,i,n,r)}constructor(t,e,i,n,o){super(t,o),r(this,"__fontWeight",void 0),r(this,"__fontSize",void 0),r(this,"__lineHeight",void 0),this.__fontWeight=e,this.__fontSize=i,this.__lineHeight=n}}function h(t,e,i,n){return new s(t,e,i,n)}function g(t){return t instanceof s}export{h as $createStyledSpanNode,g as $isStyledSpanNode,s as StyledSpanNode};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var t=require("styled-components"),o=require("styled-system"),e=require("../../style/themes/apply-base-theme.js"),i=require("../link-preview/link-preview.style.js"),n=require("../typography/typography.component.js");function r(t){return t&&t.__esModule?t:{default:t}}var a=r(t);const
|
|
1
|
+
"use strict";var t=require("styled-components"),o=require("styled-system"),e=require("../../style/themes/apply-base-theme.js"),i=require("../link-preview/link-preview.style.js"),n=require("../typography/typography.component.js");function r(t){return t&&t.__esModule?t:{default:t}}var a=r(t);const l=a.default.div.withConfig({displayName:"note.style__StyledNoteContent",componentId:"sc-39f03fe6-0"})(["position:relative;width:100%;",' &:last-of-type:not(:first-of-type){border-top:solid 1px var(--colorsUtilityMajor050);}a:not([data-component="link-preview"]){color:var(--colorsActionMajor500);&:hover{cursor:pointer;color:var(--colorsActionMajor600);}&:focus{outline:none;text-decoration:none;color:var(--colorsActionMajorYin090);background-color:var(--colorsSemanticFocus250);border-radius:var(--borderRadius025);box-shadow:0 var(--spacing050) 0 0 var(--colorsUtilityYin090);}}'],(({hasPreview:o})=>o&&t.css(["margin-top:var(--spacing200);"]))),s=a.default.div.withConfig({displayName:"note.style__StyledNoteMain",componentId:"sc-39f03fe6-1"})(["display:flex;justify-content:space-between;padding-bottom:var(--spacing300);"]),p=a.default.div.withConfig({displayName:"note.style__StyledInlineControl",componentId:"sc-39f03fe6-2"})(["display:inline-block;min-width:fit-content;"]),d=a.default.div.withConfig({displayName:"note.style__StyledTitleWrapper",componentId:"sc-39f03fe6-3"})(["",""],n.VARIANT_TYPES.map((t=>`\n ${t}{\n font-weight: 700;\n font-size: 16px;\n line-height: 21px;\n padding-bottom: 16px;\n }\n `))),c=a.default.div.withConfig({displayName:"note.style__StyledFooterContent",componentId:"sc-39f03fe6-4"})(["line-height:21px;align-items:baseline;font-weight:500;",""],(({hasName:o})=>t.css(["margin-top:var(--spacing200);"," ",""],o&&t.css(["&:first-of-type{font-size:14px;}&:nth-of-type(2){font-size:12px;color:var(--colorsUtilityYin065);margin-left:var(--spacing200);}&:last-of-type:not(:nth-of-type(2)){font-size:12px;color:var(--colorsUtilityYin065);cursor:pointer;margin-left:var(--spacing300);}"]),!o&&t.css(["&:first-of-type{font-size:12px;color:var(--colorsUtilityYin065);}&:last-of-type:not(:first-of-type){font-size:12px;color:var(--colorsUtilityYin065);cursor:pointer;margin-left:var(--spacing300);}"])))),f=a.default.div.withConfig({displayName:"note.style__StyledFooter",componentId:"sc-39f03fe6-5"})(["display:flex;margin-bottom:calc(-1 * var(--spacing100));flex-wrap:wrap;"]),y=a.default.div.attrs(e.default).withConfig({displayName:"note.style__StyledNote",componentId:"sc-39f03fe6-6"})([""," ","{margin:0px;:not(:first-of-type){margin-top:8px;}}.textBold{font-weight:bold !important;}.textItalic{font-style:italic;}.textUnderline{text-decoration:underline;}",""],(({width:o})=>t.css(["background-color:var(--colorsUtilityYang100);border:1px solid var(--colorsUtilityMajor100);border-radius:var(--borderRadius100);display:flex;flex-direction:column;padding:24px;position:relative;width:","%;box-sizing:border-box;","{box-sizing:border-box;width:auto;}"],o,l)),i.StyledLinkPreview,o.margin);exports.StyledFooter=f,exports.StyledFooterContent=c,exports.StyledInlineControl=p,exports.StyledNote=y,exports.StyledNoteContent=l,exports.StyledNoteMain=s,exports.StyledTitleWrapper=d;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var t=require("lexical");function e(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}const i={title:{weight:"700",lineHeight:"30px",size:"24px"},subtitle:{weight:"500",lineHeight:"26.25px",size:"21px"},sectionHeader:{weight:"500",lineHeight:"22.5px",size:"18px"},sectionSubheader:{weight:"500",lineHeight:"20px",size:"16px"},paragraph:{weight:"400",lineHeight:"21px",size:"14px"}};class n extends t.TextNode{static getType(){return"styled-span"}static clone(t){return new n(t.__text,t.__fontWeight,t.__fontSize,t.__lineHeight,t.__key)}getFontWeight(){return this.__fontWeight}getFontSize(){return this.__fontSize}getLineHeight(){return this.__lineHeight}setFontWeight(t){this.getWritable().__fontWeight=t}setFontSize(t){this.getWritable().__fontSize=t}setLineHeight(t){this.getWritable().__lineHeight=t}getTypographyKey(){for(const t of Object.keys(i)){const{weight:e,size:n,lineHeight:r}=i[t];if(this.__fontWeight===e&&this.__fontSize===n&&this.__lineHeight===r)return t}return"paragraph"}exportDOM(){
|
|
1
|
+
"use strict";var t=require("lexical");function e(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}const i={title:{weight:"700",lineHeight:"30px",size:"24px"},subtitle:{weight:"500",lineHeight:"26.25px",size:"21px"},sectionHeader:{weight:"500",lineHeight:"22.5px",size:"18px"},sectionSubheader:{weight:"500",lineHeight:"20px",size:"16px"},paragraph:{weight:"400",lineHeight:"21px",size:"14px"}};class n extends t.TextNode{static getType(){return"styled-span"}static clone(t){return new n(t.__text,t.__fontWeight,t.__fontSize,t.__lineHeight,t.__key)}getFontWeight(){return this.__fontWeight}getFontSize(){return this.__fontSize}getLineHeight(){return this.__lineHeight}setFontWeight(t){this.getWritable().__fontWeight=t}setFontSize(t){this.getWritable().__fontSize=t}setLineHeight(t){this.getWritable().__lineHeight=t}getTypographyKey(){for(const t of Object.keys(i)){const{weight:e,size:n,lineHeight:r}=i[t];if(this.__fontWeight===e&&this.__fontSize===n&&this.__lineHeight===r)return t}return"paragraph"}exportDOM(){let e=document.createElement("span");e.style.fontWeight=this.__fontWeight,e.style.fontSize=this.__fontSize,e.style.lineHeight=this.__lineHeight,e.textContent=this.getTextContent();const i=this.getFormat();if(i&t.IS_BOLD){const t=document.createElement("strong");t.appendChild(e),e=t}if(i&t.IS_ITALIC){const t=document.createElement("em");t.appendChild(e),e=t}if(i&t.IS_UNDERLINE){const t=document.createElement("u");t.appendChild(e),e=t}return{element:e}}static importDOM(){return{span:t=>({conversion:()=>{const e=t.style.fontWeight||"400",i=t.style.fontSize||"14px",r=t.style.lineHeight||"21px";return{node:new n(t.textContent||"",e,i,r)}},priority:1})}}exportJSON(){return t=function(t){for(var i=1;i<arguments.length;i++){var n=null!=arguments[i]?arguments[i]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable})))),r.forEach((function(i){e(t,i,n[i])}))}return t}({},super.exportJSON()),i=null!=(i={type:"styled-span",version:1,fontWeight:this.__fontWeight,fontSize:this.__fontSize,lineHeight:this.__lineHeight})?i:{},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):function(t){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e.push.apply(e,i)}return e}(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))})),t;var t,i}static importJSON(t){return new n(t.text,t.fontWeight,t.fontSize,t.lineHeight).updateFromJSON(t)}createDOM(t){const e=super.createDOM(t);return e.style.fontWeight=this.__fontWeight,e.style.fontSize=this.__fontSize,e.style.lineHeight=this.__lineHeight,e}updateDOM(t,e,i){let n=super.updateDOM(t,e,i);return this.__fontWeight!==t.__fontWeight&&(e.style.fontWeight=this.__fontWeight,n=!0),this.__fontSize!==t.__fontSize&&(e.style.fontSize=this.__fontSize,n=!0),this.__lineHeight!==t.__lineHeight&&(e.style.lineHeight=this.__lineHeight,n=!0),n}static createFromOption(t,e=""){const{weight:r,size:o,lineHeight:s}=i[t];return new n(e,r,o,s)}constructor(t,i,n,r,o){super(t,o),e(this,"__fontWeight",void 0),e(this,"__fontSize",void 0),e(this,"__lineHeight",void 0),this.__fontWeight=i,this.__fontSize=n,this.__lineHeight=r}}exports.$createStyledSpanNode=function(t,e,i,r){return new n(t,e,i,r)},exports.$isStyledSpanNode=function(t){return t instanceof n},exports.StyledSpanNode=n;
|