UNPKG

@atlaskit/adf-schema

Version:

Shared package that contains the ADF-schema (json) and ProseMirror node/mark specs

45 lines (43 loc) 1.04 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.link = void 0; var _adfSchemaGenerator = require("@atlaskit/adf-schema-generator"); var link = exports.link = (0, _adfSchemaGenerator.adfMark)('link'); // import { linkMarketGroup } from '../groups/linkMarkGroup' would cause circular deps issue var linkMarkGroup = (0, _adfSchemaGenerator.adfMarkGroup)('link', [link]); link.define({ // it seems unnessary to have it here? excludes: [linkMarkGroup], inclusive: false, attrs: { href: { type: 'string', validatorFn: 'safeUrl' }, title: { type: 'string', optional: true }, id: { type: 'string', optional: true }, collection: { type: 'string', optional: true }, occurrenceKey: { type: 'string', optional: true }, // TODO: expand object // packages/adf-schema/src/schema/marks/link.ts __confluenceMetadata: { type: 'object', optional: true, default: null } } });