UNPKG

@seidhr/sanity-plugin-muna-schemas

Version:

Muna or ᛗᚢᚾᚨ means remember in norse. Muna is a schema for the Sanity Studio that enables detailed descriptions of cultural heritage objects and knowledge about their contexts as well as pages about them (or anything else really.)

118 lines (112 loc) 2.5 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _react = _interopRequireDefault(require("react")); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } var highlightIcon = () => /*#__PURE__*/_react.default.createElement("span", { style: { fontWeight: 'bold' } }, "H"); var highlightRender = props => /*#__PURE__*/_react.default.createElement("span", { style: { backgroundColor: 'yellow' } }, props.children); var _default = { name: 'simpleBlockContent', type: 'array', title: 'Excerpt', of: [{ title: 'Block', type: 'block', styles: [{ title: 'Normal', value: 'normal' }, { title: 'H1', value: 'h1' }, { title: 'H2', value: 'h2' }, { title: 'H3', value: 'h3' }, { title: 'Quote', value: 'blockquote' }], lists: [{ title: 'Numbered', value: 'number' }, { title: 'Bulleted', value: 'bullet' }], marks: { decorators: [{ title: 'Strong', value: 'strong' }, { title: 'Emphasis', value: 'em' }, { title: 'Highlight', value: 'highlight', blockEditor: { icon: highlightIcon, render: highlightRender } }, { title: 'Code', value: 'code' }], annotations: [{ name: 'link', type: 'object', title: 'External link', fields: [{ name: 'href', type: 'url', title: 'URL' }, { title: 'Open in new tab', name: 'blank', description: 'Read https://css-tricks.com/use-target_blank/', type: 'boolean', initialValue: true }] }, { name: 'internalLink', type: 'object', title: 'Internal link', fields: [{ name: 'reference', type: 'reference', title: 'Reference', to: [{ type: 'Actor' }, { type: 'HumanMadeObject' }, { type: 'Collection' }, { type: 'Event' }, { type: 'Material' } // other types you may want to link to ] }] }] } }], options: { semanticSanity: { exclude: true } } }; exports.default = _default; //# sourceMappingURL=simpleBlockContent.js.map