@contentful/field-editor-single-line 1.1.9 → 1.1.11

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
@@ -3,6 +3,16 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [1.1.11](https://github.com/contentful/field-editors/compare/@contentful/field-editor-single-line@1.1.10...@contentful/field-editor-single-line@1.1.11) (2023-03-14)
7
+
8
+ **Note:** Version bump only for package @contentful/field-editor-single-line
9
+
10
+ ## [1.1.10](https://github.com/contentful/field-editors/compare/@contentful/field-editor-single-line@1.1.9...@contentful/field-editor-single-line@1.1.10) (2023-03-10)
11
+
12
+ ### Bug Fixes
13
+
14
+ - support disabling single line editor ([#1367](https://github.com/contentful/field-editors/issues/1367)) ([f8314ff](https://github.com/contentful/field-editors/commit/f8314fff446a3dcb482835424c7fca66c4f87f20))
15
+
6
16
  ## [1.1.9](https://github.com/contentful/field-editors/compare/@contentful/field-editor-single-line@1.1.8...@contentful/field-editor-single-line@1.1.9) (2023-02-21)
7
17
 
8
18
  **Note:** Version bump only for package @contentful/field-editor-single-line
@@ -5,6 +5,10 @@ export interface SingleLineEditorProps {
5
5
  * is the field disabled initially
6
6
  */
7
7
  isInitiallyDisabled: boolean;
8
+ /**
9
+ * is the field manually disabled
10
+ */
11
+ isDisabled?: boolean;
8
12
  /**
9
13
  * whether char validation should be shown or not
10
14
  */
@@ -38,7 +38,8 @@ function SingleLineEditor(props) {
38
38
  var direction = locales.direction[field.locale] || 'ltr';
39
39
  return React.createElement(fieldEditorShared.FieldConnector, {
40
40
  field: field,
41
- isInitiallyDisabled: props.isInitiallyDisabled
41
+ isInitiallyDisabled: props.isInitiallyDisabled,
42
+ isDisabled: props.isDisabled
42
43
  }, function (_ref) {
43
44
  var value = _ref.value,
44
45
  errors = _ref.errors,
@@ -1 +1 @@
1
- {"version":3,"file":"field-editor-single-line.cjs.development.js","sources":["../src/styles.ts","../src/SingleLineEditor.tsx"],"sourcesContent":["import { css } from 'emotion';\nimport tokens from '@contentful/f36-tokens';\n\nexport const validationRow = css({\n display: 'flex',\n justifyContent: 'space-between',\n fontSize: tokens.fontSizeM,\n marginTop: tokens.spacingXs,\n color: tokens.gray700,\n});\n\nexport const rightToLeft = css({\n direction: 'rtl',\n});\n","import * as React from 'react';\nimport {\n FieldAPI,\n FieldConnector,\n ConstraintsUtils,\n CharCounter,\n CharValidation,\n LocalesAPI,\n} from '@contentful/field-editor-shared';\nimport * as styles from './styles';\n\nimport { TextInput } from '@contentful/f36-components';\n\nexport interface SingleLineEditorProps {\n /**\n * is the field disabled initially\n */\n isInitiallyDisabled: boolean;\n\n /**\n * whether char validation should be shown or not\n */\n withCharValidation: boolean;\n /**\n * sdk.field\n */\n field: FieldAPI;\n\n /**\n * sdk.locales\n */\n locales: LocalesAPI;\n}\n\nfunction isSupportedFieldTypes(val: string): val is 'Symbol' | 'Text' {\n return val === 'Symbol' || val === 'Text';\n}\n\nexport function SingleLineEditor(props: SingleLineEditorProps) {\n const { field, locales } = props;\n\n if (!isSupportedFieldTypes(field.type)) {\n throw new Error(`\"${field.type}\" field type is not supported by SingleLineEditor`);\n }\n\n const constraints = ConstraintsUtils.fromFieldValidations(field.validations, field.type);\n const checkConstraint = ConstraintsUtils.makeChecker(constraints);\n const direction = locales.direction[field.locale] || 'ltr';\n\n return (\n <FieldConnector<string> field={field} isInitiallyDisabled={props.isInitiallyDisabled}>\n {({ value, errors, disabled, setValue }) => {\n return (\n <div data-test-id=\"single-line-editor\">\n <TextInput\n className={direction === 'rtl' ? styles.rightToLeft : ''}\n isRequired={field.required}\n isInvalid={errors.length > 0}\n isDisabled={disabled}\n value={value || ''}\n onChange={(e: React.ChangeEvent<HTMLInputElement>) => {\n setValue(e.target.value);\n }}\n />\n {props.withCharValidation && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={checkConstraint} />\n <CharValidation constraints={constraints} />\n </div>\n )}\n {props.withCharValidation === false && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={() => true} />\n </div>\n )}\n </div>\n );\n }}\n </FieldConnector>\n );\n}\n\nSingleLineEditor.defaultProps = {\n isInitiallyDisabled: true,\n withCharValidation: true,\n};\n"],"names":["validationRow","css","display","justifyContent","fontSize","tokens","fontSizeM","marginTop","spacingXs","color","gray700","rightToLeft","direction","isSupportedFieldTypes","val","SingleLineEditor","props","field","locales","type","Error","constraints","ConstraintsUtils","fromFieldValidations","validations","checkConstraint","makeChecker","locale","React","FieldConnector","isInitiallyDisabled","value","errors","disabled","setValue","TextInput","className","styles","isRequired","required","isInvalid","length","isDisabled","onChange","e","target","withCharValidation","CharCounter","CharValidation","defaultProps"],"mappings":";;;;;;;;;;;;AAGO,IAAMA,aAAa,gBAAGC,WAAG,CAAC;AAC/BC,EAAAA,OAAO,EAAE,MADsB;AAE/BC,EAAAA,cAAc,EAAE,eAFe;AAG/BC,EAAAA,QAAQ,EAAEC,MAAM,CAACC,SAHc;AAI/BC,EAAAA,SAAS,EAAEF,MAAM,CAACG,SAJa;AAK/BC,EAAAA,KAAK,EAAEJ,MAAM,CAACK;AALiB,CAAD,CAAzB;AAQA,IAAMC,WAAW,gBAAGV,WAAG,CAAC;AAC7BW,EAAAA,SAAS,EAAE;AADkB,CAAD,CAAvB;;ACuBP,SAASC,qBAAT,CAA+BC,GAA/B;AACE,SAAOA,GAAG,KAAK,QAAR,IAAoBA,GAAG,KAAK,MAAnC;AACD;;AAED,SAAgBC,iBAAiBC;AAC/B,MAAQC,KAAR,GAA2BD,KAA3B,CAAQC,KAAR;AAAA,MAAeC,OAAf,GAA2BF,KAA3B,CAAeE,OAAf;;AAEA,MAAI,CAACL,qBAAqB,CAACI,KAAK,CAACE,IAAP,CAA1B,EAAwC;AACtC,UAAM,IAAIC,KAAJ,QAAcH,KAAK,CAACE,IAApB,wDAAN;AACD;;AAED,MAAME,WAAW,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AAahB,MAAAA,KAAK,EAAEA,KAAK,IAAI;AAAIN,MAAAA,eAAe,EAAE;AAAA,eAAM,IAAN;AAAA;KAAlD,CADF,CAlBJ,CADF;AAyBD,GA3BH,CADF;AA+BD;AAEDV,gBAAgB,CAACkC,YAAjB,GAAgC;AAC9BnB,EAAAA,mBAAmB,EAAE,IADS;AAE9BgB,EAAAA,kBAAkB,EAAE;AAFU,CAAhC;;;;"}
1
+ {"version":3,"file":"field-editor-single-line.cjs.development.js","sources":["../src/styles.ts","../src/SingleLineEditor.tsx"],"sourcesContent":["import { css } from 'emotion';\nimport tokens from '@contentful/f36-tokens';\n\nexport const validationRow = css({\n display: 'flex',\n justifyContent: 'space-between',\n fontSize: tokens.fontSizeM,\n marginTop: tokens.spacingXs,\n color: tokens.gray700,\n});\n\nexport const rightToLeft = css({\n direction: 'rtl',\n});\n","import * as React from 'react';\nimport {\n FieldAPI,\n FieldConnector,\n ConstraintsUtils,\n CharCounter,\n CharValidation,\n LocalesAPI,\n} from '@contentful/field-editor-shared';\nimport * as styles from './styles';\n\nimport { TextInput } from '@contentful/f36-components';\n\nexport interface SingleLineEditorProps {\n /**\n * is the field disabled initially\n */\n isInitiallyDisabled: boolean;\n\n /**\n * is the field manually disabled\n */\n isDisabled?: boolean;\n\n /**\n * whether char validation should be shown or not\n */\n withCharValidation: boolean;\n /**\n * sdk.field\n */\n field: FieldAPI;\n\n /**\n * sdk.locales\n */\n locales: LocalesAPI;\n}\n\nfunction isSupportedFieldTypes(val: string): val is 'Symbol' | 'Text' {\n return val === 'Symbol' || val === 'Text';\n}\n\nexport function SingleLineEditor(props: SingleLineEditorProps) {\n const { field, locales } = props;\n\n if (!isSupportedFieldTypes(field.type)) {\n throw new Error(`\"${field.type}\" field type is not supported by SingleLineEditor`);\n }\n\n const constraints = ConstraintsUtils.fromFieldValidations(field.validations, field.type);\n const checkConstraint = ConstraintsUtils.makeChecker(constraints);\n const direction = locales.direction[field.locale] || 'ltr';\n\n return (\n <FieldConnector<string>\n field={field}\n isInitiallyDisabled={props.isInitiallyDisabled}\n isDisabled={props.isDisabled}>\n {({ value, errors, disabled, setValue }) => {\n return (\n <div data-test-id=\"single-line-editor\">\n <TextInput\n className={direction === 'rtl' ? styles.rightToLeft : ''}\n isRequired={field.required}\n isInvalid={errors.length > 0}\n isDisabled={disabled}\n value={value || ''}\n onChange={(e: React.ChangeEvent<HTMLInputElement>) => {\n setValue(e.target.value);\n }}\n />\n {props.withCharValidation && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={checkConstraint} />\n <CharValidation constraints={constraints} />\n </div>\n )}\n {props.withCharValidation === false && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={() => true} />\n </div>\n )}\n </div>\n );\n }}\n </FieldConnector>\n );\n}\n\nSingleLineEditor.defaultProps = {\n isInitiallyDisabled: true,\n withCharValidation: true,\n};\n"],"names":["validationRow","css","display","justifyContent","fontSize","tokens","fontSizeM","marginTop","spacingXs","color","gray700","rightToLeft","direction","isSupportedFieldTypes","val","SingleLineEditor","props","field","locales","type","Error","constraints","ConstraintsUtils","fromFieldValidations","validations","checkConstraint","makeChecker","locale","React","FieldConnector","isInitiallyDisabled","isDisabled","value","errors","disabled","setValue","TextInput","className","styles","isRequired","required","isInvalid","length","onChange","e","target","withCharValidation","CharCounter","CharValidation","defaultProps"],"mappings":";;;;;;;;;;;;AAGO,IAAMA,aAAa,gBAAGC,WAAG,CAAC;AAC/BC,EAAAA,OAAO,EAAE,MADsB;AAE/BC,EAAAA,cAAc,EAAE,eAFe;AAG/BC,EAAAA,QAAQ,EAAEC,MAAM,CAACC,SAHc;AAI/BC,EAAAA,SAAS,EAAEF,MAAM,CAACG,SAJa;AAK/BC,EAAAA,KAAK,EAAEJ,MAAM,CAACK;AALiB,CAAD,CAAzB;AAQA,IAAMC,WAAW,gBAAGV,WAAG,CAAC;AAC7BW,EAAAA,SAAS,EAAE;AADkB,CAAD,CAAvB;;AC4BP,SAASC,qBAAT,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hB,KAAK,CAAC8B,kBAAN,IACClB,mBAAA,MAAA;AAAKS,MAAAA,SAAS,EAAEC;KAAhB,EACEV,mBAAA,CAACmB,6BAAD;AAAaf,MAAAA,KAAK,EAAEA,KAAK,IAAI;AAAIP,MAAAA,eAAe,EAAEA;KAAlD,CADF,EAEEG,mBAAA,CAACoB,gCAAD;AAAgB3B,MAAAA,WAAW,EAAEA;KAA7B,CAFF,CAZJ,EAiBGL,KAAK,CAAC8B,kBAAN,KAA6B,KAA7B,IACClB,mBAAA,MAAA;AAAKS,MAAAA,SAAS,EAAEC;KAAhB,EACEV,mBAAA,CAACmB,6BAAD;AAAaf,MAAAA,KAAK,EAAEA,KAAK,IAAI;AAAIP,MAAAA,eAAe,EAAE;AAAA,eAAM,IAAN;AAAA;KAAlD,CADF,CAlBJ,CADF;AAyBD,GA9BH,CADF;AAkCD;AAEDV,gBAAgB,CAACkC,YAAjB,GAAgC;AAC9BnB,EAAAA,mBAAmB,EAAE,IADS;AAE9BgB,EAAAA,kBAAkB,EAAE;AAFU,CAAhC;;;;"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("react"),i=require("@contentful/field-editor-shared"),n=require("emotion"),r=(e=require("@contentful/f36-tokens"))&&"object"==typeof e&&"default"in e?e.default:e,a=require("@contentful/f36-components"),l=n.css({display:"flex",justifyContent:"space-between",fontSize:r.fontSizeM,marginTop:r.spacingXs,color:r.gray700}),o=n.css({direction:"rtl"});function s(e){var n,r=e.field,s=e.locales;if("Symbol"!==(n=r.type)&&"Text"!==n)throw new Error('"'+r.type+'" field type is not supported by SingleLineEditor');var d=i.ConstraintsUtils.fromFieldValidations(r.validations,r.type),c=i.ConstraintsUtils.makeChecker(d),u=s.direction[r.locale]||"ltr";return t.createElement(i.FieldConnector,{field:r,isInitiallyDisabled:e.isInitiallyDisabled},(function(n){var s=n.value,f=n.setValue;return t.createElement("div",{"data-test-id":"single-line-editor"},t.createElement(a.TextInput,{className:"rtl"===u?o:"",isRequired:r.required,isInvalid:n.errors.length>0,isDisabled:n.disabled,value:s||"",onChange:function(e){f(e.target.value)}}),e.withCharValidation&&t.createElement("div",{className:l},t.createElement(i.CharCounter,{value:s||"",checkConstraint:c}),t.createElement(i.CharValidation,{constraints:d})),!1===e.withCharValidation&&t.createElement("div",{className:l},t.createElement(i.CharCounter,{value:s||"",checkConstraint:function(){return!0}})))}))}s.defaultProps={isInitiallyDisabled:!0,withCharValidation:!0},exports.SingleLineEditor=s;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("react"),i=require("@contentful/field-editor-shared"),a=require("emotion"),n=(e=require("@contentful/f36-tokens"))&&"object"==typeof e&&"default"in e?e.default:e,r=require("@contentful/f36-components"),l=a.css({display:"flex",justifyContent:"space-between",fontSize:n.fontSizeM,marginTop:n.spacingXs,color:n.gray700}),s=a.css({direction:"rtl"});function o(e){var a,n=e.field,o=e.locales;if("Symbol"!==(a=n.type)&&"Text"!==a)throw new Error('"'+n.type+'" field type is not supported by SingleLineEditor');var d=i.ConstraintsUtils.fromFieldValidations(n.validations,n.type),c=i.ConstraintsUtils.makeChecker(d),u=o.direction[n.locale]||"ltr";return t.createElement(i.FieldConnector,{field:n,isInitiallyDisabled:e.isInitiallyDisabled,isDisabled:e.isDisabled},(function(a){var o=a.value,f=a.setValue;return t.createElement("div",{"data-test-id":"single-line-editor"},t.createElement(r.TextInput,{className:"rtl"===u?s:"",isRequired:n.required,isInvalid:a.errors.length>0,isDisabled:a.disabled,value:o||"",onChange:function(e){f(e.target.value)}}),e.withCharValidation&&t.createElement("div",{className:l},t.createElement(i.CharCounter,{value:o||"",checkConstraint:c}),t.createElement(i.CharValidation,{constraints:d})),!1===e.withCharValidation&&t.createElement("div",{className:l},t.createElement(i.CharCounter,{value:o||"",checkConstraint:function(){return!0}})))}))}o.defaultProps={isInitiallyDisabled:!0,withCharValidation:!0},exports.SingleLineEditor=o;
2
2
  //# sourceMappingURL=field-editor-single-line.cjs.production.min.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"field-editor-single-line.cjs.production.min.js","sources":["../src/styles.ts","../src/SingleLineEditor.tsx"],"sourcesContent":["import { css } from 'emotion';\nimport tokens from '@contentful/f36-tokens';\n\nexport const validationRow = css({\n display: 'flex',\n justifyContent: 'space-between',\n fontSize: tokens.fontSizeM,\n marginTop: tokens.spacingXs,\n color: tokens.gray700,\n});\n\nexport const rightToLeft = css({\n direction: 'rtl',\n});\n","import * as React from 'react';\nimport {\n FieldAPI,\n FieldConnector,\n ConstraintsUtils,\n CharCounter,\n CharValidation,\n LocalesAPI,\n} from '@contentful/field-editor-shared';\nimport * as styles from './styles';\n\nimport { TextInput } from '@contentful/f36-components';\n\nexport interface SingleLineEditorProps {\n /**\n * is the field disabled initially\n */\n isInitiallyDisabled: boolean;\n\n /**\n * whether char validation should be shown or not\n */\n withCharValidation: boolean;\n /**\n * sdk.field\n */\n field: FieldAPI;\n\n /**\n * sdk.locales\n */\n locales: LocalesAPI;\n}\n\nfunction isSupportedFieldTypes(val: string): val is 'Symbol' | 'Text' {\n return val === 'Symbol' || val === 'Text';\n}\n\nexport function SingleLineEditor(props: SingleLineEditorProps) {\n const { field, locales } = props;\n\n if (!isSupportedFieldTypes(field.type)) {\n throw new Error(`\"${field.type}\" field type is not supported by SingleLineEditor`);\n }\n\n const constraints = ConstraintsUtils.fromFieldValidations(field.validations, field.type);\n const checkConstraint = ConstraintsUtils.makeChecker(constraints);\n const direction = locales.direction[field.locale] || 'ltr';\n\n return (\n <FieldConnector<string> field={field} isInitiallyDisabled={props.isInitiallyDisabled}>\n {({ value, errors, disabled, setValue }) => {\n return (\n <div data-test-id=\"single-line-editor\">\n <TextInput\n className={direction === 'rtl' ? styles.rightToLeft : ''}\n isRequired={field.required}\n isInvalid={errors.length > 0}\n isDisabled={disabled}\n value={value || ''}\n onChange={(e: React.ChangeEvent<HTMLInputElement>) => {\n setValue(e.target.value);\n }}\n />\n {props.withCharValidation && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={checkConstraint} />\n <CharValidation constraints={constraints} />\n </div>\n )}\n {props.withCharValidation === false && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={() => true} />\n </div>\n )}\n </div>\n );\n }}\n </FieldConnector>\n );\n}\n\nSingleLineEditor.defaultProps = {\n isInitiallyDisabled: true,\n withCharValidation: true,\n};\n"],"names":["validationRow","css","display","justifyContent","fontSize","tokens","fontSizeM","marginTop","spacingXs","color","gray700","rightToLeft","direction","SingleLineEditor","props","val","field","locales","type","Error","constraints","ConstraintsUtils","fromFieldValidations","validations","checkConstraint","makeChecker","locale","React","FieldConnector","isInitiallyDisabled","value","setValue","TextInput","className","styles","isRequired","required","isInvalid","errors","length","isDisabled","disabled","onChange","e","target","withCharValidation","CharCounter","CharValidation","defaultProps"],"mappings":"8RAGaA,EAAgBC,MAAI,CAC/BC,QAAS,OACTC,eAAgB,gBAChBC,SAAUC,EAAOC,UACjBC,UAAWF,EAAOG,UAClBC,MAAOJ,EAAOK,UAGHC,EAAcV,MAAI,CAC7BW,UAAW,iBC0BGC,EAAiBC,OAJFC,EAKrBC,EAAmBF,EAAnBE,MAAOC,EAAYH,EAAZG,WAJA,YADcF,EAOFC,EAAME,OANE,SAARH,QAOnB,IAAII,UAAUH,EAAME,8DAGtBE,EAAcC,mBAAiBC,qBAAqBN,EAAMO,YAAaP,EAAME,MAC7EM,EAAkBH,mBAAiBI,YAAYL,GAC/CR,EAAYK,EAAQL,UAAUI,EAAMU,SAAW,aAGnDC,gBAACC,kBAAuBZ,MAAOA,EAAOa,oBAAqBf,EAAMe,sBAC9D,gBAAGC,IAAAA,MAAyBC,IAAAA,gBAEzBJ,sCAAkB,sBAChBA,gBAACK,aACCC,UAAyB,QAAdrB,EAAsBsB,EAAqB,GACtDC,WAAYnB,EAAMoB,SAClBC,YANGC,OAMeC,OAAS,EAC3BC,aAPWC,SAQXX,MAAOA,GAAS,GAChBY,SAAU,SAACC,GACTZ,EAASY,EAAEC,OAAOd,UAGrBhB,EAAM+B,oBACLlB,uBAAKM,UAAWC,GACdP,gBAACmB,eAAYhB,MAAOA,GAAS,GAAIN,gBAAiBA,IAClDG,gBAACoB,kBAAe3B,YAAaA,MAGH,IAA7BN,EAAM+B,oBACLlB,uBAAKM,UAAWC,GACdP,gBAACmB,eAAYhB,MAAOA,GAAS,GAAIN,gBAAiB,kBAAM,UAUxEX,EAAiBmC,aAAe,CAC9BnB,qBAAqB,EACrBgB,oBAAoB"}
1
+ {"version":3,"file":"field-editor-single-line.cjs.production.min.js","sources":["../src/styles.ts","../src/SingleLineEditor.tsx"],"sourcesContent":["import { css } from 'emotion';\nimport tokens from '@contentful/f36-tokens';\n\nexport const validationRow = css({\n display: 'flex',\n justifyContent: 'space-between',\n fontSize: tokens.fontSizeM,\n marginTop: tokens.spacingXs,\n color: tokens.gray700,\n});\n\nexport const rightToLeft = css({\n direction: 'rtl',\n});\n","import * as React from 'react';\nimport {\n FieldAPI,\n FieldConnector,\n ConstraintsUtils,\n CharCounter,\n CharValidation,\n LocalesAPI,\n} from '@contentful/field-editor-shared';\nimport * as styles from './styles';\n\nimport { TextInput } from '@contentful/f36-components';\n\nexport interface SingleLineEditorProps {\n /**\n * is the field disabled initially\n */\n isInitiallyDisabled: boolean;\n\n /**\n * is the field manually disabled\n */\n isDisabled?: boolean;\n\n /**\n * whether char validation should be shown or not\n */\n withCharValidation: boolean;\n /**\n * sdk.field\n */\n field: FieldAPI;\n\n /**\n * sdk.locales\n */\n locales: LocalesAPI;\n}\n\nfunction isSupportedFieldTypes(val: string): val is 'Symbol' | 'Text' {\n return val === 'Symbol' || val === 'Text';\n}\n\nexport function SingleLineEditor(props: SingleLineEditorProps) {\n const { field, locales } = props;\n\n if (!isSupportedFieldTypes(field.type)) {\n throw new Error(`\"${field.type}\" field type is not supported by SingleLineEditor`);\n }\n\n const constraints = ConstraintsUtils.fromFieldValidations(field.validations, field.type);\n const checkConstraint = ConstraintsUtils.makeChecker(constraints);\n const direction = locales.direction[field.locale] || 'ltr';\n\n return (\n <FieldConnector<string>\n field={field}\n isInitiallyDisabled={props.isInitiallyDisabled}\n isDisabled={props.isDisabled}>\n {({ value, errors, disabled, setValue }) => {\n return (\n <div data-test-id=\"single-line-editor\">\n <TextInput\n className={direction === 'rtl' ? styles.rightToLeft : ''}\n isRequired={field.required}\n isInvalid={errors.length > 0}\n isDisabled={disabled}\n value={value || ''}\n onChange={(e: React.ChangeEvent<HTMLInputElement>) => {\n setValue(e.target.value);\n }}\n />\n {props.withCharValidation && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={checkConstraint} />\n <CharValidation constraints={constraints} />\n </div>\n )}\n {props.withCharValidation === false && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={() => true} />\n </div>\n )}\n </div>\n );\n }}\n </FieldConnector>\n );\n}\n\nSingleLineEditor.defaultProps = {\n isInitiallyDisabled: true,\n withCharValidation: true,\n};\n"],"names":["validationRow","css","display","justifyContent","fontSize","tokens","fontSizeM","marginTop","spacingXs","color","gray700","rightToLeft","direction","SingleLineEditor","props","val","field","locales","type","Error","constraints","ConstraintsUtils","fromFieldValidations","validations","checkConstraint","makeChecker","locale","React","FieldConnector","isInitiallyDisabled","isDisabled","value","setValue","TextInput","className","styles","isRequired","required","isInvalid","errors","length","disabled","onChange","e","target","withCharValidation","CharCounter","CharValidation","defaultProps"],"mappings":"8RAGaA,EAAgBC,MAAI,CAC/BC,QAAS,OACTC,eAAgB,gBAChBC,SAAUC,EAAOC,UACjBC,UAAWF,EAAOG,UAClBC,MAAOJ,EAAOK,UAGHC,EAAcV,MAAI,CAC7BW,UAAW,iBC+BGC,EAAiBC,OAJFC,EAKrBC,EAAmBF,EAAnBE,MAAOC,EAAYH,EAAZG,WAJA,YADcF,EAOFC,EAAME,OANE,SAARH,QAOnB,IAAII,UAAUH,EAAME,8DAGtBE,EAAcC,mBAAiBC,qBAAqBN,EAAMO,YAAaP,EAAME,MAC7EM,EAAkBH,mBAAiBI,YAAYL,GAC/CR,EAAYK,EAAQL,UAAUI,EAAMU,SAAW,aAGnDC,gBAACC,kBACCZ,MAAOA,EACPa,oBAAqBf,EAAMe,oBAC3BC,WAAYhB,EAAMgB,aACjB,gBAAGC,IAAAA,MAAyBC,IAAAA,gBAEzBL,sCAAkB,sBAChBA,gBAACM,aACCC,UAAyB,QAAdtB,EAAsBuB,EAAqB,GACtDC,WAAYpB,EAAMqB,SAClBC,YANGC,OAMeC,OAAS,EAC3BV,aAPWW,SAQXV,MAAOA,GAAS,GAChBW,SAAU,SAACC,GACTX,EAASW,EAAEC,OAAOb,UAGrBjB,EAAM+B,oBACLlB,uBAAKO,UAAWC,GACdR,gBAACmB,eAAYf,MAAOA,GAAS,GAAIP,gBAAiBA,IAClDG,gBAACoB,kBAAe3B,YAAaA,MAGH,IAA7BN,EAAM+B,oBACLlB,uBAAKO,UAAWC,GACdR,gBAACmB,eAAYf,MAAOA,GAAS,GAAIP,gBAAiB,kBAAM,UAUxEX,EAAiBmC,aAAe,CAC9BnB,qBAAqB,EACrBgB,oBAAoB"}
@@ -32,7 +32,8 @@ function SingleLineEditor(props) {
32
32
  var direction = locales.direction[field.locale] || 'ltr';
33
33
  return createElement(FieldConnector, {
34
34
  field: field,
35
- isInitiallyDisabled: props.isInitiallyDisabled
35
+ isInitiallyDisabled: props.isInitiallyDisabled,
36
+ isDisabled: props.isDisabled
36
37
  }, function (_ref) {
37
38
  var value = _ref.value,
38
39
  errors = _ref.errors,
@@ -1 +1 @@
1
- {"version":3,"file":"field-editor-single-line.esm.js","sources":["../src/styles.ts","../src/SingleLineEditor.tsx"],"sourcesContent":["import { css } from 'emotion';\nimport tokens from '@contentful/f36-tokens';\n\nexport const validationRow = css({\n display: 'flex',\n justifyContent: 'space-between',\n fontSize: tokens.fontSizeM,\n marginTop: tokens.spacingXs,\n color: tokens.gray700,\n});\n\nexport const rightToLeft = css({\n direction: 'rtl',\n});\n","import * as React from 'react';\nimport {\n FieldAPI,\n FieldConnector,\n ConstraintsUtils,\n CharCounter,\n CharValidation,\n LocalesAPI,\n} from '@contentful/field-editor-shared';\nimport * as styles from './styles';\n\nimport { TextInput } from '@contentful/f36-components';\n\nexport interface SingleLineEditorProps {\n /**\n * is the field disabled initially\n */\n isInitiallyDisabled: boolean;\n\n /**\n * whether char validation should be shown or not\n */\n withCharValidation: boolean;\n /**\n * sdk.field\n */\n field: FieldAPI;\n\n /**\n * sdk.locales\n */\n locales: LocalesAPI;\n}\n\nfunction isSupportedFieldTypes(val: string): val is 'Symbol' | 'Text' {\n return val === 'Symbol' || val === 'Text';\n}\n\nexport function SingleLineEditor(props: SingleLineEditorProps) {\n const { field, locales } = props;\n\n if (!isSupportedFieldTypes(field.type)) {\n throw new Error(`\"${field.type}\" field type is not supported by SingleLineEditor`);\n }\n\n const constraints = ConstraintsUtils.fromFieldValidations(field.validations, field.type);\n const checkConstraint = ConstraintsUtils.makeChecker(constraints);\n const direction = locales.direction[field.locale] || 'ltr';\n\n return (\n <FieldConnector<string> field={field} isInitiallyDisabled={props.isInitiallyDisabled}>\n {({ value, errors, disabled, setValue }) => {\n return (\n <div data-test-id=\"single-line-editor\">\n <TextInput\n className={direction === 'rtl' ? styles.rightToLeft : ''}\n isRequired={field.required}\n isInvalid={errors.length > 0}\n isDisabled={disabled}\n value={value || ''}\n onChange={(e: React.ChangeEvent<HTMLInputElement>) => {\n setValue(e.target.value);\n }}\n />\n {props.withCharValidation && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={checkConstraint} />\n <CharValidation constraints={constraints} />\n </div>\n )}\n {props.withCharValidation === false && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={() => true} />\n </div>\n )}\n </div>\n );\n }}\n </FieldConnector>\n );\n}\n\nSingleLineEditor.defaultProps = {\n isInitiallyDisabled: true,\n withCharValidation: true,\n};\n"],"names":["validationRow","css","display","justifyContent","fontSize","tokens","fontSizeM","marginTop","spacingXs","color","gray700","rightToLeft","direction","isSupportedFieldTypes","val","SingleLineEditor","props","field","locales","type","Error","constraints","ConstraintsUtils","fromFieldValidations","validations","checkConstraint","makeChecker","locale","React","FieldConnector","isInitiallyDisabled","value","errors","disabled","setValue","TextInput","className","styles","isRequired","required","isInvalid","length","isDisabled","onChange","e","target","withCharValidation","CharCounter","CharValidation","defaultProps"],"mappings":";;;;;;AAGO,IAAMA,aAAa,gBAAGC,GAAG,CAAC;AAC/BC,EAAAA,OAAO,EAAE,MADsB;AAE/BC,EAAAA,cAAc,EAAE,eAFe;AAG/BC,EAAAA,QAAQ,EAAEC,MAAM,CAACC,SAHc;AAI/BC,EAAAA,SAAS,EAAEF,MAAM,CAACG,SAJa;AAK/BC,EAAAA,KAAK,EAAEJ,MAAM,CAACK;AALiB,CAAD,CAAzB;AAQA,IAAMC,WAAW,gBAAGV,GAAG,CAAC;AAC7BW,EAAAA,SAAS,EAAE;AADkB,CAAD,CAAvB;;ACuBP,SAASC,qBAAT,CAA+BC,GAA/B;AACE,SAAOA,GAAG,KAAK,QAAR,IAAoBA,GAAG,KAAK,MAAnC;AACD;;AAED,SAAgBC,iBAAiBC;AAC/B,MAAQC,KAAR,GAA2BD,KAA3B,CAAQC,KAAR;AAAA,MAAeC,OAAf,GAA2BF,KAA3B,CAAeE,OAAf;;AAEA,MAAI,CAACL,qBAAqB,CAACI,KAAK,CAACE,IAAP,CAA1B,EAAwC;AACtC,UAAM,IAAIC,KAAJ,QAAcH,KAAK,CAACE,IAApB,wDAAN;AACD;;AAED,MAAME,WAAW,GAAGC,gBAAgB,CAACC,oBAAjB,CAAsCN,KAAK,CAACO,WAA5C,EAAyDP,KAAK,CAACE,IAA/D,CAApB;AACA,MAAMM,eAAe,GAAGH,gBAAgB,CAACI,WAAjB,CAA6BL,WAA7B,CAAxB;AACA,MAAMT,SAAS,GAAGM,OAAO,CAACN,SAAR,CAAkBK,KAAK,CAACU,MAAxB,KAAmC,KAArD;AAEA,SACEC,aAAA,CAACC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-editor-single-line.esm.js","sources":["../src/styles.ts","../src/SingleLineEditor.tsx"],"sourcesContent":["import { css } from 'emotion';\nimport tokens from '@contentful/f36-tokens';\n\nexport const validationRow = css({\n display: 'flex',\n justifyContent: 'space-between',\n fontSize: tokens.fontSizeM,\n marginTop: tokens.spacingXs,\n color: tokens.gray700,\n});\n\nexport const rightToLeft = css({\n direction: 'rtl',\n});\n","import * as React from 'react';\nimport {\n FieldAPI,\n FieldConnector,\n ConstraintsUtils,\n CharCounter,\n CharValidation,\n LocalesAPI,\n} from '@contentful/field-editor-shared';\nimport * as styles from './styles';\n\nimport { TextInput } from '@contentful/f36-components';\n\nexport interface SingleLineEditorProps {\n /**\n * is the field disabled initially\n */\n isInitiallyDisabled: boolean;\n\n /**\n * is the field manually disabled\n */\n isDisabled?: boolean;\n\n /**\n * whether char validation should be shown or not\n */\n withCharValidation: boolean;\n /**\n * sdk.field\n */\n field: FieldAPI;\n\n /**\n * sdk.locales\n */\n locales: LocalesAPI;\n}\n\nfunction isSupportedFieldTypes(val: string): val is 'Symbol' | 'Text' {\n return val === 'Symbol' || val === 'Text';\n}\n\nexport function SingleLineEditor(props: SingleLineEditorProps) {\n const { field, locales } = props;\n\n if (!isSupportedFieldTypes(field.type)) {\n throw new Error(`\"${field.type}\" field type is not supported by SingleLineEditor`);\n }\n\n const constraints = ConstraintsUtils.fromFieldValidations(field.validations, field.type);\n const checkConstraint = ConstraintsUtils.makeChecker(constraints);\n const direction = locales.direction[field.locale] || 'ltr';\n\n return (\n <FieldConnector<string>\n field={field}\n isInitiallyDisabled={props.isInitiallyDisabled}\n isDisabled={props.isDisabled}>\n {({ value, errors, disabled, setValue }) => {\n return (\n <div data-test-id=\"single-line-editor\">\n <TextInput\n className={direction === 'rtl' ? styles.rightToLeft : ''}\n isRequired={field.required}\n isInvalid={errors.length > 0}\n isDisabled={disabled}\n value={value || ''}\n onChange={(e: React.ChangeEvent<HTMLInputElement>) => {\n setValue(e.target.value);\n }}\n />\n {props.withCharValidation && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={checkConstraint} />\n <CharValidation constraints={constraints} />\n </div>\n )}\n {props.withCharValidation === false && (\n <div className={styles.validationRow}>\n <CharCounter value={value || ''} checkConstraint={() => true} />\n </div>\n )}\n </div>\n );\n }}\n </FieldConnector>\n );\n}\n\nSingleLineEditor.defaultProps = {\n isInitiallyDisabled: true,\n withCharValidation: true,\n};\n"],"names":["validationRow","css","display","justifyContent","fontSize","tokens","fontSizeM","marginTop","spacingXs","color","gray700","rightToLeft","direction","isSupportedFieldTypes","val","SingleLineEditor","props","field","locales","type","Error","constraints","ConstraintsUtils","fromFieldValidations","validations","checkConstraint","makeChecker","locale","React","FieldConnector","isInitiallyDisabled","isDisabled","value","errors","disabled","setValue","TextInput","className","styles","isRequired","required","isInvalid","length","onChange","e","target","withCharValidation","CharCounter","CharValidation","defaultProps"],"mappings":";;;;;;AAGO,IAAMA,aAAa,gBAAGC,GAAG,CAAC;AAC/BC,EAAAA,OAAO,EAAE,MADsB;AAE/BC,EAAAA,cAAc,EAAE,eAFe;AAG/BC,EAAAA,QAAQ,EAAEC,MAAM,CAACC,SAHc;AAI/BC,EAAAA,SAAS,EAAEF,MAAM,CAACG,SAJa;AAK/BC,EAAAA,KAAK,EAAEJ,MAAM,CAACK;AALiB,CAAD,CAAzB;AAQA,IAAMC,WAAW,gBAAGV,GAAG,CAAC;AAC7BW,EAAAA,SAAS,EAAE;AADkB,CAAD,CAAvB;;AC4BP,SAASC,qBAAT,CAA+BC,GAA/B;AACE,SAAOA,GAAG,KAAK,QAAR,IAAoBA,GAAG,KAAK,MAAnC;AACD;;AAED,SAAgBC,iBAAiBC;AAC/B,MAAQC,KAAR,GAA2BD,KAA3B,CAAQC,KAAR;AAAA,MAAeC,OAAf,GAA2BF,KAA3B,CAAeE,OAAf;;AAEA,MAAI,CAACL,qBAAqB,CAACI,KAAK,CAACE,IAAP,CAA1B,EAAwC;AACtC,UAAM,IAAIC,KAAJ,QA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7B,IACClB,aAAA,MAAA;AAAKS,MAAAA,SAAS,EAAEC;KAAhB,EACEV,aAAA,CAACmB,WAAD;AAAaf,MAAAA,KAAK,EAAEA,KAAK,IAAI;AAAIP,MAAAA,eAAe,EAAE;AAAA,eAAM,IAAN;AAAA;KAAlD,CADF,CAlBJ,CADF;AAyBD,GA9BH,CADF;AAkCD;AAEDV,gBAAgB,CAACkC,YAAjB,GAAgC;AAC9BnB,EAAAA,mBAAmB,EAAE,IADS;AAE9BgB,EAAAA,kBAAkB,EAAE;AAFU,CAAhC;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contentful/field-editor-single-line",
3
- "version": "1.1.9",
3
+ "version": "1.1.11",
4
4
  "main": "dist/index.js",
5
5
  "module": "dist/field-editor-single-line.esm.js",
6
6
  "typings": "dist/index.d.ts",
@@ -23,26 +23,16 @@
23
23
  "dependencies": {
24
24
  "@contentful/f36-components": "^4.0.27",
25
25
  "@contentful/f36-tokens": "^4.0.0",
26
- "@contentful/field-editor-shared": "^1.1.6",
26
+ "@contentful/field-editor-shared": "^1.1.8",
27
27
  "emotion": "^10.0.17",
28
28
  "lodash": "^4.17.15",
29
29
  "lodash-es": "^4.17.15"
30
30
  },
31
31
  "devDependencies": {
32
- "@contentful/field-editor-test-utils": "^1.2.5"
32
+ "@contentful/field-editor-test-utils": "^1.2.7"
33
33
  },
34
34
  "peerDependencies": {
35
35
  "react": ">=16.8.0"
36
36
  },
37
- "jest": {
38
- "testMatch": [
39
- "**/?(*.)+(spec|test).[jt]s?(x)"
40
- ],
41
- "globals": {
42
- "ts-jest": {
43
- "diagnostics": false
44
- }
45
- }
46
- },
47
- "gitHead": "320c8066c77ca41cde74d4c17dc9708188432088"
37
+ "gitHead": "4fff7b9534374dcc44cb477240d369fc34f46415"
48
38
  }