@saasquatch/mint-components 1.6.2-5 → 1.6.2-6
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.
|
@@ -114,7 +114,7 @@ DOMTokenList
|
|
|
114
114
|
|
|
115
115
|
var resourcesUrl = scriptElm ? scriptElm.getAttribute('data-resources-url') || scriptElm.src : '';
|
|
116
116
|
var start = function() {
|
|
117
|
-
var url = new URL('./p-ab7ae098.system.js', new URL(resourcesUrl
|
|
117
|
+
var url = new URL('./p-ab7ae098.system.js', new URL(resourcesUrl));
|
|
118
118
|
System.import(url.href);
|
|
119
119
|
};
|
|
120
120
|
|
package/docs/docs.docx
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@saasquatch/mint-components",
|
|
3
3
|
"title": "Mint Components",
|
|
4
|
-
"version": "1.6.2-
|
|
4
|
+
"version": "1.6.2-6",
|
|
5
5
|
"description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.",
|
|
6
6
|
"icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg",
|
|
7
7
|
"raisins": "docs/raisins.json",
|
package/docs/grapesjs.js
DELETED
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
System.register([], function (exports_1, context_1) {
|
|
2
|
-
"use strict";
|
|
3
|
-
var components;
|
|
4
|
-
var __moduleName = context_1 && context_1.id;
|
|
5
|
-
return {
|
|
6
|
-
setters: [],
|
|
7
|
-
execute: function () {
|
|
8
|
-
components = [{ "tag": "select-test", "name": "Big Stat", "uiSchema": {}, "traits": [] }, { "tag": "sqm-big-stat", "name": "Big Stat", "uiSchema": { "stat-type": { "ui:widget": "StatTypeSelectWidget", "ui:name": "Stat Type", "ui:help": "Select what type of stat to display. Manual paths are also supported." } }, "traits": [{ "name": "stat-type", "type": "string", "title": "Stat Type" }] }, { "tag": "sqm-edit-profile", "name": "Edit Profile", "uiSchema": { "canceltext": { "ui:name": "Cancel button text", "ui:help": "" }, "currentregiontext": { "ui:name": "Region field label", "ui:help": "" }, "editprofileheader": { "ui:name": "Heading", "ui:help": "" }, "editprofiletext": { "ui:name": "Enable editing button text", "ui:help": "" }, "firstnametext": { "ui:name": "First name field label", "ui:help": "" }, "lastnametext": { "ui:name": "Last name field label", "ui:help": "" }, "updatetext": { "ui:name": "Update info button text", "ui:help": "" } }, "traits": [{ "name": "canceltext", "type": "string", "title": "Cancel button text" }, { "name": "currentregiontext", "type": "string", "title": "Region field label" }, { "name": "editprofileheader", "type": "string", "title": "Heading" }, { "name": "editprofiletext", "type": "string", "title": "Enable editing button text" }, { "name": "firstnametext", "type": "string", "title": "First name field label" }, { "name": "lastnametext", "type": "string", "title": "Last name field label" }, { "name": "updatetext", "type": "string", "title": "Update info button text" }] }, { "tag": "sqm-form-message", "name": "Form Message", "uiSchema": { "icon": { "ui:name": "Icon to use in alert", "ui:help": "" }, "type": { "ui:name": "Type of alert", "ui:help": "" } }, "traits": [{ "name": "icon", "type": "string", "title": "Icon to use in alert" }, { "name": "type", "type": "string", "title": "Type of alert" }] }, { "tag": "sqm-hook-story-container", "name": "sqm-hook-story-container", "uiSchema": { "hookStory": { "ui:help": "" } }, "traits": [{ "name": "hookStory", "type": "FunctionalComponent<{}>", "title": "hookStory" }] }, { "tag": "sqm-leaderboard", "name": "Leaderboard", "uiSchema": { "leaderboard-type": { "ui:name": "Leaderboard type", "ui:help": "" }, "rank-type": { "ui:help": "" }, "statsheading": { "ui:name": "Stats Column Heading", "ui:help": "" }, "usersheading": { "ui:name": "User Column Heading", "ui:help": "" } }, "traits": [{ "name": "leaderboard-type", "type": "\"topConvertedReferrers\" | \"topStartedReferrers\"", "title": "Leaderboard type" }, { "name": "rank-type", "type": "\"denseRank\" | \"rank\" | \"rowNumber\"", "title": "rank-type" }, { "name": "statsheading", "type": "string", "title": "Stats Column Heading" }, { "name": "usersheading", "type": "string", "title": "User Column Heading" }] }, { "tag": "sqm-leaderboard-rank", "name": "Leaderboard Rank", "uiSchema": { "leaderboard-type": { "ui:name": "Leaderboard type", "ui:help": "" }, "rank-text": { "ui:help": "" }, "rank-type": { "ui:name": "Default rank", "ui:help": "" }, "unranked-text": { "ui:help": "" } }, "traits": [{ "name": "leaderboard-type", "type": "\"topConvertedReferrers\" | \"topStartedReferrers\"", "title": "Leaderboard type" }, { "name": "rank-text", "type": "string", "title": "rank-text" }, { "name": "rank-type", "type": "\"denseRank\" | \"rank\" | \"rowNumber\"", "title": "Default rank" }, { "name": "unranked-text", "type": "string", "title": "unranked-text" }] }, { "tag": "sqm-navigation-menu", "name": "Portal Frame", "uiSchema": { "include-dropdown": { "ui:name": "Include dropdown menu", "ui:help": "" }, "menu-label": { "ui:name": "Label on the header menu", "ui:help": "" } }, "traits": [{ "name": "include-dropdown", "type": "boolean", "title": "Include dropdown menu" }, { "name": "menu-label", "type": "string", "title": "Label on the header menu" }] }, { "tag": "sqm-popup-container", "name": "Popup container for widgets", "uiSchema": { "close-button": { "ui:name": "Display a close button on the popup", "ui:help": "" }, "close-button-text": { "ui:name": "Text to be used as the close button", "ui:help": "" }, "embed-padding": { "ui:name": "Specify padding on the popup contents when in embedded mode", "ui:help": "" }, "popup-padding": { "ui:name": "Specify padding on the popup contents when in popup mode", "ui:help": "" }, "powered-by": { "ui:name": "Show SaaSquatch Powered By messaging", "ui:help": "" } }, "traits": [{ "name": "close-button", "type": "boolean", "title": "Display a close button on the popup" }, { "name": "close-button-text", "type": "string", "title": "Text to be used as the close button" }, { "name": "embed-padding", "type": "\"large\" | \"medium\" | \"none\" | \"small\"", "title": "Specify padding on the popup contents when in embedded mode" }, { "name": "popup-padding", "type": "\"large\" | \"medium\" | \"none\" | \"small\"", "title": "Specify padding on the popup contents when in popup mode" }, { "name": "powered-by", "type": "boolean", "title": "Show SaaSquatch Powered By messaging" }] }, { "tag": "sqm-portal-email-verification", "name": "Portal Email Verification", "uiSchema": { "next-page-url-parameter": { "ui:help": "" } }, "traits": [{ "name": "next-page-url-parameter", "type": "string", "title": "next-page-url-parameter" }] }, { "tag": "sqm-portal-forgot-password", "name": "Portal Forgot Password", "uiSchema": { "email-label": { "ui:help": "" }, "next-page-url-parameter": { "ui:help": "" }, "submit-label": { "ui:help": "" } }, "traits": [{ "name": "email-label", "type": "string", "title": "email-label" }, { "name": "next-page-url-parameter", "type": "string", "title": "next-page-url-parameter" }, { "name": "submit-label", "type": "string", "title": "submit-label" }] }, { "tag": "sqm-portal-frame", "name": "Portal Frame", "uiSchema": {}, "traits": [] }, { "tag": "sqm-portal-login", "name": "Portal Login", "uiSchema": { "email-label": { "ui:help": "" }, "next-page": { "ui:help": "" }, "next-page-url-parameter": { "ui:help": "" }, "password-label": { "ui:help": "" }, "submit-label": { "ui:help": "" } }, "traits": [{ "name": "email-label", "type": "string", "title": "email-label" }, { "name": "next-page", "type": "string", "title": "next-page" }, { "name": "next-page-url-parameter", "type": "string", "title": "next-page-url-parameter" }, { "name": "password-label", "type": "string", "title": "password-label" }, { "name": "submit-label", "type": "string", "title": "submit-label" }] }, { "tag": "sqm-portal-logout", "name": "Portal Logout", "uiSchema": { "logout-on-render": { "ui:help": "" }, "next-page": { "ui:help": "" } }, "traits": [{ "name": "logout-on-render", "type": "boolean", "title": "logout-on-render" }, { "name": "next-page", "type": "string", "title": "next-page" }] }, { "tag": "sqm-portal-protected-route", "name": "Portal Protected Route", "uiSchema": { "authenticated": { "ui:help": "" }, "redirect-to": { "ui:help": "" }, "redirect-to-unverified": { "ui:help": "" }, "verified": { "ui:help": "" } }, "traits": [{ "name": "authenticated", "type": "any", "title": "authenticated" }, { "name": "redirect-to", "type": "any", "title": "redirect-to" }, { "name": "redirect-to-unverified", "type": "any", "title": "redirect-to-unverified" }, { "name": "verified", "type": "any", "title": "verified" }] }, { "tag": "sqm-portal-register", "name": "Portal Register", "uiSchema": { "email-label": { "ui:help": "" }, "next-page": { "ui:help": "" }, "next-page-url-parameter": { "ui:help": "" }, "password-label": { "ui:help": "" }, "submit-label": { "ui:help": "" } }, "traits": [{ "name": "email-label", "type": "string", "title": "email-label" }, { "name": "next-page", "type": "string", "title": "next-page" }, { "name": "next-page-url-parameter", "type": "string", "title": "next-page-url-parameter" }, { "name": "password-label", "type": "string", "title": "password-label" }, { "name": "submit-label", "type": "string", "title": "submit-label" }] }, { "tag": "sqm-portal-reset-password", "name": "Portal Reset Password", "uiSchema": { "next-page": { "ui:help": "" }, "next-page-url-parameter": { "ui:help": "" } }, "traits": [{ "name": "next-page", "type": "string", "title": "next-page" }, { "name": "next-page-url-parameter", "type": "string", "title": "next-page-url-parameter" }] }, { "tag": "sqm-portal-verify-email", "name": "Portal Verify Email", "uiSchema": { "next-page": { "ui:help": "" }, "next-page-url-parameter": { "ui:help": "" } }, "traits": [{ "name": "next-page", "type": "string", "title": "next-page" }, { "name": "next-page-url-parameter", "type": "string", "title": "next-page-url-parameter" }] }, { "tag": "sqm-route", "name": "Route (for pages)", "uiSchema": { "path": { "ui:name": "Navigation path name", "ui:help": "" } }, "traits": [{ "name": "path", "type": "string", "title": "Navigation path name" }] }, { "tag": "sqm-router", "name": "Router (for pages)", "uiSchema": {}, "traits": [] }, { "tag": "sqm-share-button", "name": "Share Button", "uiSchema": { "ui:order": ["medium", "program-id", "*", "pill", "disabled", "hideicon"], "disabled": { "ui:name": "Disabled", "ui:help": "" }, "hideicon": { "ui:name": "Hide the icon", "ui:help": "" }, "icon": { "ui:name": "Icon used in button. Will try to select an icon based on the share medium if left empty.", "ui:help": "" }, "iconslot": { "ui:name": "Icon Location", "ui:help": "" }, "medium": { "ui:name": "Share Medium", "ui:help": "The social medium to share on. Share messages and links\nwill be pulled from your program config and tagged for analytics." }, "pill": { "ui:name": "Display as pill", "ui:help": "" }, "program-id": { "ui:name": "Program ID", "ui:help": "Optional programId, or uses the programId context where this button is rendered." }, "sharetext": { "ui:name": "Text used for native sharing (mobile only)", "ui:help": "" }, "sharetitle": { "ui:name": "Title used for native sharing (mobile only)", "ui:help": "" }, "size": { "ui:name": "Button Size", "ui:help": "" }, "type": { "ui:name": "Button Style", "ui:help": "" } }, "traits": [{ "name": "disabled", "type": "boolean", "title": "Disabled" }, { "name": "hideicon", "type": "boolean", "title": "Hide the icon" }, { "name": "icon", "type": "string", "title": "Icon used in button. Will try to select an icon based on the share medium if left empty." }, { "name": "iconslot", "type": "string", "title": "Icon Location", "enum": ["prefix", "suffix"], "enumNames": ["Prefix", "Suffix"] }, { "name": "medium", "type": "string", "title": "Share Medium", "enum": ["facebook", "twitter", "email", "direct", "linkedin", "sms", "fbmessenger", "whatsapp", "linemessenger", "pinterest", "reminder", "unknown"], "enumNames": ["Facebook", "Twitter", "Email", "Web Share Sheet", "Linkedin", "SMS", "Facebook Messenger", "Whatsapp", "Line Messenger", "Pinterest", "Reminder", "Unknown"] }, { "name": "pill", "type": "boolean", "title": "Display as pill" }, { "name": "program-id", "type": "string", "title": "Program ID" }, { "name": "sharetext", "type": "string", "title": "Text used for native sharing (mobile only)" }, { "name": "sharetitle", "type": "string", "title": "Title used for native sharing (mobile only)" }, { "name": "size", "type": "string", "title": "Button Size", "enum": ["small", "medium", "large"], "enumNames": ["Small", "Medium", "Large"] }, { "name": "type", "type": "string", "title": "Button Style", "enum": ["primary", "success", "info", "warning", "danger", "default", "text"] }] }, { "tag": "sqm-share-link", "name": "Share Link", "uiSchema": { "program-id": { "ui:name": "Program ID", "ui:help": "The ID of the program that should generate the link. Defaults to the program ID in context where this widget is loaded." }, "tooltip-lifespan": { "ui:name": "Tooltip lifespan", "ui:help": "The number of milliseconds that the tooltip will appear for" }, "tooltip-text": { "ui:name": "Tooltip text", "ui:help": "This is shown after someone has successfully copied the link to the clipboard." } }, "traits": [{ "name": "program-id", "type": "string", "title": "Program ID" }, { "name": "tooltip-lifespan", "type": "number", "title": "Tooltip lifespan" }, { "name": "tooltip-text", "type": "string", "title": "Tooltip text" }] }, { "tag": "sqm-stencilbook", "name": "sqm-stencilbook", "uiSchema": {}, "traits": [] }, { "tag": "sl-details", "name": "Details", "traits": [{ "type": "string", "name": "summary", "title": "Label" }] }, { "tag": "sl-tab", "name": "Tab", "traits": [{ "type": "string", "name": "panel", "title": "Panel ID" }] }, { "tag": "sl-tab-panel", "name": "Tab Panel", "traits": [{ "type": "string", "name": "name", "title": "Panel ID" }] }, { "tag": "sl-tab-group", "name": "Tab Group", "traits": [{ "type": "string", "name": "placement", "title": "Placement of Tabs", "enum": ["top", "right", "bottom", "left"] }] }];
|
|
9
|
-
exports_1("default", (function (editor, config) {
|
|
10
|
-
if (config === void 0) { config = {}; }
|
|
11
|
-
// Get DomComponents module
|
|
12
|
-
var comps = editor.DomComponents;
|
|
13
|
-
// Get the model and the view from the default Component type
|
|
14
|
-
var defaultType = comps.getType("default");
|
|
15
|
-
var defaultModel = defaultType.model;
|
|
16
|
-
var defaultView = defaultType.view;
|
|
17
|
-
function registerComponent(_a) {
|
|
18
|
-
var tag = _a.tag, name = _a.name, traits = _a.traits, uiSchema = _a.uiSchema;
|
|
19
|
-
comps.addType(tag.toLowerCase(), {
|
|
20
|
-
model: defaultModel.extend({
|
|
21
|
-
defaults: Object.assign({}, defaultModel.prototype.defaults, {
|
|
22
|
-
name: name,
|
|
23
|
-
// can be dropped only inside
|
|
24
|
-
draggable: false,
|
|
25
|
-
// these components can be dropped in here
|
|
26
|
-
droppable: false,
|
|
27
|
-
selectable: true,
|
|
28
|
-
toolbar: [],
|
|
29
|
-
traits: traits,
|
|
30
|
-
uiSchema: uiSchema,
|
|
31
|
-
}),
|
|
32
|
-
}, {
|
|
33
|
-
isComponent: function (el) {
|
|
34
|
-
if (el.tagName === tag.toUpperCase()) {
|
|
35
|
-
return { type: tag.toLowerCase() };
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
|
-
}),
|
|
39
|
-
view: defaultView.extend({
|
|
40
|
-
render: function () {
|
|
41
|
-
defaultView.prototype.render.apply(this, arguments);
|
|
42
|
-
return this;
|
|
43
|
-
},
|
|
44
|
-
}),
|
|
45
|
-
});
|
|
46
|
-
}
|
|
47
|
-
if (!components) {
|
|
48
|
-
throw new Error("Error registering components. This is likely due to a build problem in the source library. See GrapesJS generator.ts");
|
|
49
|
-
}
|
|
50
|
-
components.forEach(registerComponent);
|
|
51
|
-
}));
|
|
52
|
-
}
|
|
53
|
-
};
|
|
54
|
-
});
|