@neatico/visual-core 0.14.66 → 0.14.68
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/dist/cjs/compositionNumbers.js +3 -1
- package/dist/cjs/compositionUseCases.js +2 -0
- package/dist/cjs/layoutContracts.js +1 -0
- package/dist/cjs/nativeSocialParameters.js +17 -1
- package/dist/cjs/socialLayouts.js +2 -0
- package/dist/compositionNumbers.js +3 -1
- package/dist/compositionUseCases.js +2 -0
- package/dist/layoutContracts.js +1 -0
- package/dist/nativeSocialParameters.js +17 -1
- package/dist/socialLayouts.d.ts +8 -0
- package/dist/socialLayouts.js +2 -0
- package/package.json +1 -1
|
@@ -3,6 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.compositionUseCase = compositionUseCase;
|
|
4
4
|
/** Authored communication tasks, independent of field count and successful parameter filling. */
|
|
5
5
|
const useCases = {
|
|
6
|
+
'dark-promo': 'Promote a supplied product or offer with a bold headline, a concise product scope, an action, a website label and offer terms. Preserve exact discounts and eligibility; clearly label illustrative prices and never fabricate a real promotion.',
|
|
7
|
+
'price-increase': 'Announce an event ticket price increase or early-bird deadline, with the supplied current price, future price, effective date and event details. Preserve amounts and dates exactly; never invent urgency or ticket availability.',
|
|
6
8
|
'note-question': 'Ask one audience-facing question or open a discussion. A plain factual list is a weaker fit than a real question-led task.',
|
|
7
9
|
'note-marker': 'Emphasize one short assertion, takeaway, or opinion with highlighted typography. This is not a detailed list or quantitative explanation.',
|
|
8
10
|
'note-editorial': 'Present a short reflective editorial passage with a clear headline and supporting prose.',
|
|
@@ -8,6 +8,8 @@ const parameterDefaults_js_1 = require("./parameterDefaults.js");
|
|
|
8
8
|
const textPresentation_js_1 = require("./textPresentation.js");
|
|
9
9
|
const socialLayouts_js_1 = require("./socialLayouts.js");
|
|
10
10
|
const slots = {
|
|
11
|
+
'price-increase': { items: 2, value: true, image: true },
|
|
12
|
+
'dark-promo': { value: true, attribution: true },
|
|
11
13
|
'note-question': {}, 'note-marker': {}, 'note-editorial': {}, 'note-checklist': { items: 3 }, 'note-photo': { image: true }, 'note-news': { value: true },
|
|
12
14
|
'chat-messenger': { items: 3 }, 'chat-imessage': { items: 3 }, 'chat-telegram': { items: 3 }, 'chat-workplace': { items: 3 },
|
|
13
15
|
'time-notice': { value: true }, 'news-focus': {}, manifesto: {}, launch: { image: true }, bento: { items: 3 }, spotlight: { items: 3, value: true, image: true },
|
|
@@ -38,14 +40,24 @@ function nativeSocialParameterContract(id) {
|
|
|
38
40
|
properties.eyebrow = { ...copy(20, 'Optional concise section label. Use an empty string when no label improves the message.', 0), default: '' };
|
|
39
41
|
if (!id.startsWith('chat-') && !['note-photo', 'note-checklist'].includes(id))
|
|
40
42
|
properties.cta = { ...copy(24, 'Optional short call to action appropriate to the input. Use an empty string when this is purely informational.', 0), default: '' };
|
|
41
|
-
if (['note-marker', 'note-editorial', 'note-question'].includes(id))
|
|
43
|
+
if (['note-marker', 'note-editorial', 'note-question', 'dark-promo'].includes(id))
|
|
42
44
|
properties.titleLines = { type: 'array', minItems: 0, maxItems: 4, default: [], items: copy(40, 'One complete phrase from the title, preserving its original language.'), description: 'Preferred title lines: one item for a single line, two to four for a multiline heading, or empty for automatic fitting. Concatenating the phrases must preserve the complete title and word boundaries. The renderer may reflow only when the requested lines cannot fit legibly.' };
|
|
43
45
|
if (id === 'note-marker')
|
|
44
46
|
properties.emphasis = { type: 'array', minItems: 0, maxItems: 2, default: [], items: copy(40, 'An exact contiguous phrase from title to highlight.'), description: 'Choose one or two important exact title phrases. Empty means the renderer highlights the final title line.' };
|
|
47
|
+
if (id === 'price-increase') {
|
|
48
|
+
properties.title = copy(28, 'Short price-change headline; keep the event name in eyebrow.');
|
|
49
|
+
properties.body = copy(64, 'Short event descriptor. Use only supplied event facts or explicitly labelled sample text.');
|
|
50
|
+
}
|
|
45
51
|
if (spec.value)
|
|
46
52
|
properties.value = copy(24, 'The focal quantity, price, time, or short value statement. Label fictional quantities as simulated.');
|
|
47
53
|
if (spec.attribution)
|
|
48
54
|
properties.attribution = copy(48, 'Exact supplied attribution, or an empty string. Never invent an endorsement.', 0);
|
|
55
|
+
if (id === 'dark-promo') {
|
|
56
|
+
properties.title = copy(28, 'A concise supplied offer headline; do not invent a discount.');
|
|
57
|
+
properties.body = copy(64, 'A concise product or service scope.');
|
|
58
|
+
properties.value = copy(40, 'A supplied website or short destination label. Never invent a URL.', 0);
|
|
59
|
+
properties.attribution = copy(80, 'Offer eligibility and terms, or an explicit sample disclaimer. Never fabricate a real promotion.', 0);
|
|
60
|
+
}
|
|
49
61
|
if (spec.image)
|
|
50
62
|
properties.imageAssetId = asset();
|
|
51
63
|
if (spec.items) {
|
|
@@ -65,6 +77,10 @@ function nativeSocialParameterContract(id) {
|
|
|
65
77
|
}
|
|
66
78
|
properties.items = { type: 'array', minItems: spec.items, maxItems: spec.items, items: object(item), ...(spec.quantities === 'share' ? { description: 'Exactly three nonnegative percentage shares totaling at most one hundred.' } : {}) };
|
|
67
79
|
}
|
|
80
|
+
if (id === 'price-increase') {
|
|
81
|
+
properties.value = copy(24, 'Current ticket price and currency, optionally followed by Now. Preserve supplied amounts exactly.');
|
|
82
|
+
properties.items.description = 'Exactly two detail pairs in this order: item 0 title is event date and description is location; item 1 title is future ticket price and description is its effective date. Never invent missing dates or prices. Label illustrative content explicitly.';
|
|
83
|
+
}
|
|
68
84
|
if (spec.quantities === 'comparison' || spec.quantities === 'benchmark')
|
|
69
85
|
properties.comparisonLabels = { type: 'array', minItems: 2, maxItems: 2, items: copy(20, 'A supplied or explicitly illustrative series label.') };
|
|
70
86
|
if (['note-question', 'note-marker', 'note-editorial'].includes(id))
|
|
@@ -208,4 +208,6 @@ exports.SOCIAL_LAYOUT_CATALOG = [
|
|
|
208
208
|
scene: "product-showcase",
|
|
209
209
|
name: "Product showcase",
|
|
210
210
|
},
|
|
211
|
+
{ id: "price-increase", scene: "pricing", name: "Event price increase" },
|
|
212
|
+
{ id: "dark-promo", scene: "pricing", name: "Dark gradient promotion" },
|
|
211
213
|
];
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
/** Authored communication tasks, independent of field count and successful parameter filling. */
|
|
2
2
|
const useCases = {
|
|
3
|
+
'dark-promo': 'Promote a supplied product or offer with a bold headline, a concise product scope, an action, a website label and offer terms. Preserve exact discounts and eligibility; clearly label illustrative prices and never fabricate a real promotion.',
|
|
4
|
+
'price-increase': 'Announce an event ticket price increase or early-bird deadline, with the supplied current price, future price, effective date and event details. Preserve amounts and dates exactly; never invent urgency or ticket availability.',
|
|
3
5
|
'note-question': 'Ask one audience-facing question or open a discussion. A plain factual list is a weaker fit than a real question-led task.',
|
|
4
6
|
'note-marker': 'Emphasize one short assertion, takeaway, or opinion with highlighted typography. This is not a detailed list or quantitative explanation.',
|
|
5
7
|
'note-editorial': 'Present a short reflective editorial passage with a clear headline and supporting prose.',
|
package/dist/layoutContracts.js
CHANGED
|
@@ -2,6 +2,8 @@ import { compositionParameterDefaults } from './parameterDefaults.js';
|
|
|
2
2
|
import { textPresentationSchema, validateTextPresentations } from './textPresentation.js';
|
|
3
3
|
import { SOCIAL_LAYOUT_CATALOG } from './socialLayouts.js';
|
|
4
4
|
const slots = {
|
|
5
|
+
'price-increase': { items: 2, value: true, image: true },
|
|
6
|
+
'dark-promo': { value: true, attribution: true },
|
|
5
7
|
'note-question': {}, 'note-marker': {}, 'note-editorial': {}, 'note-checklist': { items: 3 }, 'note-photo': { image: true }, 'note-news': { value: true },
|
|
6
8
|
'chat-messenger': { items: 3 }, 'chat-imessage': { items: 3 }, 'chat-telegram': { items: 3 }, 'chat-workplace': { items: 3 },
|
|
7
9
|
'time-notice': { value: true }, 'news-focus': {}, manifesto: {}, launch: { image: true }, bento: { items: 3 }, spotlight: { items: 3, value: true, image: true },
|
|
@@ -32,14 +34,24 @@ export function nativeSocialParameterContract(id) {
|
|
|
32
34
|
properties.eyebrow = { ...copy(20, 'Optional concise section label. Use an empty string when no label improves the message.', 0), default: '' };
|
|
33
35
|
if (!id.startsWith('chat-') && !['note-photo', 'note-checklist'].includes(id))
|
|
34
36
|
properties.cta = { ...copy(24, 'Optional short call to action appropriate to the input. Use an empty string when this is purely informational.', 0), default: '' };
|
|
35
|
-
if (['note-marker', 'note-editorial', 'note-question'].includes(id))
|
|
37
|
+
if (['note-marker', 'note-editorial', 'note-question', 'dark-promo'].includes(id))
|
|
36
38
|
properties.titleLines = { type: 'array', minItems: 0, maxItems: 4, default: [], items: copy(40, 'One complete phrase from the title, preserving its original language.'), description: 'Preferred title lines: one item for a single line, two to four for a multiline heading, or empty for automatic fitting. Concatenating the phrases must preserve the complete title and word boundaries. The renderer may reflow only when the requested lines cannot fit legibly.' };
|
|
37
39
|
if (id === 'note-marker')
|
|
38
40
|
properties.emphasis = { type: 'array', minItems: 0, maxItems: 2, default: [], items: copy(40, 'An exact contiguous phrase from title to highlight.'), description: 'Choose one or two important exact title phrases. Empty means the renderer highlights the final title line.' };
|
|
41
|
+
if (id === 'price-increase') {
|
|
42
|
+
properties.title = copy(28, 'Short price-change headline; keep the event name in eyebrow.');
|
|
43
|
+
properties.body = copy(64, 'Short event descriptor. Use only supplied event facts or explicitly labelled sample text.');
|
|
44
|
+
}
|
|
39
45
|
if (spec.value)
|
|
40
46
|
properties.value = copy(24, 'The focal quantity, price, time, or short value statement. Label fictional quantities as simulated.');
|
|
41
47
|
if (spec.attribution)
|
|
42
48
|
properties.attribution = copy(48, 'Exact supplied attribution, or an empty string. Never invent an endorsement.', 0);
|
|
49
|
+
if (id === 'dark-promo') {
|
|
50
|
+
properties.title = copy(28, 'A concise supplied offer headline; do not invent a discount.');
|
|
51
|
+
properties.body = copy(64, 'A concise product or service scope.');
|
|
52
|
+
properties.value = copy(40, 'A supplied website or short destination label. Never invent a URL.', 0);
|
|
53
|
+
properties.attribution = copy(80, 'Offer eligibility and terms, or an explicit sample disclaimer. Never fabricate a real promotion.', 0);
|
|
54
|
+
}
|
|
43
55
|
if (spec.image)
|
|
44
56
|
properties.imageAssetId = asset();
|
|
45
57
|
if (spec.items) {
|
|
@@ -59,6 +71,10 @@ export function nativeSocialParameterContract(id) {
|
|
|
59
71
|
}
|
|
60
72
|
properties.items = { type: 'array', minItems: spec.items, maxItems: spec.items, items: object(item), ...(spec.quantities === 'share' ? { description: 'Exactly three nonnegative percentage shares totaling at most one hundred.' } : {}) };
|
|
61
73
|
}
|
|
74
|
+
if (id === 'price-increase') {
|
|
75
|
+
properties.value = copy(24, 'Current ticket price and currency, optionally followed by Now. Preserve supplied amounts exactly.');
|
|
76
|
+
properties.items.description = 'Exactly two detail pairs in this order: item 0 title is event date and description is location; item 1 title is future ticket price and description is its effective date. Never invent missing dates or prices. Label illustrative content explicitly.';
|
|
77
|
+
}
|
|
62
78
|
if (spec.quantities === 'comparison' || spec.quantities === 'benchmark')
|
|
63
79
|
properties.comparisonLabels = { type: 'array', minItems: 2, maxItems: 2, items: copy(20, 'A supplied or explicitly illustrative series label.') };
|
|
64
80
|
if (['note-question', 'note-marker', 'note-editorial'].includes(id))
|
package/dist/socialLayouts.d.ts
CHANGED
|
@@ -195,4 +195,12 @@ export declare const SOCIAL_LAYOUT_CATALOG: readonly [{
|
|
|
195
195
|
readonly id: "product-showcase";
|
|
196
196
|
readonly scene: "product-showcase";
|
|
197
197
|
readonly name: "Product showcase";
|
|
198
|
+
}, {
|
|
199
|
+
readonly id: "price-increase";
|
|
200
|
+
readonly scene: "pricing";
|
|
201
|
+
readonly name: "Event price increase";
|
|
202
|
+
}, {
|
|
203
|
+
readonly id: "dark-promo";
|
|
204
|
+
readonly scene: "pricing";
|
|
205
|
+
readonly name: "Dark gradient promotion";
|
|
198
206
|
}];
|
package/dist/socialLayouts.js
CHANGED
|
@@ -205,4 +205,6 @@ export const SOCIAL_LAYOUT_CATALOG = [
|
|
|
205
205
|
scene: "product-showcase",
|
|
206
206
|
name: "Product showcase",
|
|
207
207
|
},
|
|
208
|
+
{ id: "price-increase", scene: "pricing", name: "Event price increase" },
|
|
209
|
+
{ id: "dark-promo", scene: "pricing", name: "Dark gradient promotion" },
|
|
208
210
|
];
|
package/package.json
CHANGED