superdesk-ui-framework 3.0.1-beta.1 → 3.0.1-beta.2
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/app/fonts/sd_big-icons.eot +0 -0
- package/app/fonts/sd_big-icons.svg +55 -53
- package/app/fonts/sd_big-icons.ttf +0 -0
- package/app/fonts/sd_big-icons.woff +0 -0
- package/app/fonts/sd_icons.eot +0 -0
- package/app/fonts/sd_icons.svg +1 -0
- package/app/fonts/sd_icons.ttf +0 -0
- package/app/fonts/sd_icons.woff +0 -0
- package/app/img/dots.svg +3 -0
- package/app/styles/_accessibility.scss +3 -3
- package/app/styles/_big-icon-font.scss +60 -23
- package/app/styles/_boxed-list.scss +26 -3
- package/app/styles/_buttons.scss +4 -0
- package/app/styles/_helpers.scss +4 -3
- package/app/styles/_icon-font.scss +341 -307
- package/app/styles/_icon-labels.scss +66 -10
- package/app/styles/_table-list.scss +244 -0
- package/app/styles/app.scss +1 -0
- package/app/styles/components/_list-item.scss +24 -20
- package/app/styles/components/_sd-dropzone.scss +52 -16
- package/app/styles/components/_subnav.scss +87 -80
- package/app/styles/design-tokens/_design-tokens-general.scss +7 -0
- package/app/styles/design-tokens/_new-colors.scss +4 -2
- package/app/styles/form-elements/_inputs.scss +4 -0
- package/app/styles/grids/_grid-layout.scss +21 -7
- package/app/styles/layout/_container.scss +3 -0
- package/app/styles/layout/_editor.scss +108 -16
- package/app/styles/menus/_sd-sidebar-menu.scss +6 -0
- package/app/styles/primereact/_pr-dialog.scss +39 -7
- package/app-typescript/components/CreateButton.tsx +38 -0
- package/app-typescript/components/DropZone.tsx +4 -4
- package/app-typescript/components/Icon.tsx +3 -1
- package/app-typescript/components/IconLabel.tsx +8 -1
- package/app-typescript/components/Input.tsx +2 -0
- package/app-typescript/components/Layouts/AuthoringContainer.tsx +27 -0
- package/app-typescript/components/Layouts/AuthoringInnerHeader.tsx +2 -0
- package/app-typescript/components/Layouts/AuthoringMain.tsx +11 -7
- package/app-typescript/components/Layouts/AuthoringMainToolBar.tsx +7 -1
- package/app-typescript/components/Layouts/Container.tsx +1 -1
- package/app-typescript/components/Layouts/ContentSplitter.tsx +23 -0
- package/app-typescript/components/Layouts/Layout.tsx +33 -0
- package/app-typescript/components/Layouts/LayoutContainer.tsx +1 -4
- package/app-typescript/components/Layouts/MainPanel.tsx +10 -5
- package/app-typescript/components/Layouts/OverlayPanel.tsx +19 -0
- package/app-typescript/components/Layouts/Panel.tsx +1 -0
- package/app-typescript/components/Layouts/index.tsx +8 -2
- package/app-typescript/components/Lists/BoxedList.tsx +6 -2
- package/app-typescript/components/Lists/ContentList.tsx +100 -0
- package/app-typescript/components/Lists/TableList.tsx +208 -0
- package/app-typescript/components/Modal.tsx +27 -17
- package/app-typescript/components/Navigation/SideBarTabs.tsx +10 -0
- package/app-typescript/components/SearchBar.tsx +79 -0
- package/app-typescript/components/Select.tsx +2 -0
- package/app-typescript/components/SidebarMenu.tsx +68 -0
- package/app-typescript/components/Spinner.tsx +1 -1
- package/app-typescript/components/SwitchGroup.tsx +2 -1
- package/app-typescript/index.ts +3 -0
- package/dist/dots.svg +3 -0
- package/dist/examples.bundle.css +7871 -379
- package/dist/examples.bundle.js +29461 -15740
- package/dist/playgrounds/react-playgrounds/EditorTest.tsx +9 -4
- package/dist/playgrounds/react-playgrounds/Index.tsx +3 -1
- package/dist/playgrounds/react-playgrounds/PersonalProfile.tsx +13 -0
- package/dist/playgrounds/react-playgrounds/RundownEditor.tsx +466 -0
- package/dist/playgrounds/react-playgrounds/Rundowns.tsx +1002 -0
- package/dist/playgrounds/react-playgrounds/TestGround.tsx +190 -182
- package/dist/playgrounds/react-playgrounds/UiPlayground.tsx +4 -0
- package/dist/playgrounds/react-playgrounds/components/AuthoringContainer.tsx +26 -0
- package/dist/playgrounds/react-playgrounds/components/ContentSplitter.tsx +22 -0
- package/dist/playgrounds/react-playgrounds/components/Index.tsx +6 -1
- package/dist/playgrounds/react-playgrounds/components/MainPanel.tsx +11 -1
- package/dist/playgrounds/react-playgrounds/components/SearchBar.tsx +51 -9
- package/dist/react/Container.tsx +1 -1
- package/dist/react/ContentList.tsx +280 -0
- package/dist/react/CreateButton.tsx +71 -0
- package/dist/react/DropZone.tsx +14 -6
- package/dist/react/IconButtons.tsx +6 -6
- package/dist/react/IconLabels.tsx +24 -2
- package/dist/react/Index.tsx +15 -0
- package/dist/react/Inputs.tsx +32 -3
- package/dist/react/Modal.tsx +1 -0
- package/dist/react/TableList.tsx +268 -0
- package/dist/sd_big-icons.eot +0 -0
- package/dist/sd_big-icons.svg +55 -53
- package/dist/sd_big-icons.ttf +0 -0
- package/dist/sd_big-icons.woff +0 -0
- package/dist/sd_icons.eot +0 -0
- package/dist/sd_icons.svg +1 -0
- package/dist/sd_icons.ttf +0 -0
- package/dist/sd_icons.woff +0 -0
- package/dist/superdesk-ui.bundle.css +44994 -24931
- package/dist/superdesk-ui.bundle.js +2437 -1949
- package/dist/vendor.bundle.js +27 -27
- package/examples/css/docs-page.css +2 -3
- package/examples/index.js +8 -0
- package/examples/pages/playgrounds/react-playgrounds/EditorTest.tsx +9 -4
- package/examples/pages/playgrounds/react-playgrounds/Index.tsx +3 -1
- package/examples/pages/playgrounds/react-playgrounds/PersonalProfile.tsx +13 -0
- package/examples/pages/playgrounds/react-playgrounds/RundownEditor.tsx +466 -0
- package/examples/pages/playgrounds/react-playgrounds/Rundowns.tsx +1002 -0
- package/examples/pages/playgrounds/react-playgrounds/TestGround.tsx +190 -182
- package/examples/pages/playgrounds/react-playgrounds/UiPlayground.tsx +4 -0
- package/examples/pages/playgrounds/react-playgrounds/components/AuthoringContainer.tsx +26 -0
- package/examples/pages/playgrounds/react-playgrounds/components/ContentSplitter.tsx +22 -0
- package/examples/pages/playgrounds/react-playgrounds/components/Index.tsx +6 -1
- package/examples/pages/playgrounds/react-playgrounds/components/MainPanel.tsx +11 -1
- package/examples/pages/playgrounds/react-playgrounds/components/SearchBar.tsx +51 -9
- package/examples/pages/react/Container.tsx +1 -1
- package/examples/pages/react/ContentList.tsx +280 -0
- package/examples/pages/react/CreateButton.tsx +71 -0
- package/examples/pages/react/DropZone.tsx +14 -6
- package/examples/pages/react/IconButtons.tsx +6 -6
- package/examples/pages/react/IconLabels.tsx +24 -2
- package/examples/pages/react/Index.tsx +15 -0
- package/examples/pages/react/Inputs.tsx +32 -3
- package/examples/pages/react/Modal.tsx +1 -0
- package/examples/pages/react/TableList.tsx +268 -0
- package/package.json +2 -1
- package/react/components/CreateButton.d.ts +17 -0
- package/react/components/CreateButton.js +66 -0
- package/react/components/DropZone.d.ts +2 -2
- package/react/components/DropZone.js +2 -2
- package/react/components/Icon.d.ts +1 -0
- package/react/components/Icon.js +2 -1
- package/react/components/IconLabel.d.ts +2 -0
- package/react/components/IconLabel.js +6 -3
- package/react/components/Input.d.ts +1 -0
- package/react/components/Input.js +1 -0
- package/react/components/Layouts/AuthoringContainer.d.ts +11 -0
- package/react/components/Layouts/AuthoringContainer.js +58 -0
- package/react/components/Layouts/AuthoringInnerHeader.d.ts +1 -0
- package/react/components/Layouts/AuthoringInnerHeader.js +6 -3
- package/react/components/Layouts/AuthoringMain.d.ts +3 -1
- package/react/components/Layouts/AuthoringMain.js +2 -2
- package/react/components/Layouts/AuthoringMainToolBar.d.ts +1 -0
- package/react/components/Layouts/AuthoringMainToolBar.js +8 -1
- package/react/components/Layouts/Container.d.ts +1 -1
- package/react/components/Layouts/ContentSplitter.d.ts +10 -0
- package/react/components/Layouts/ContentSplitter.js +56 -0
- package/react/components/Layouts/Layout.d.ts +8 -0
- package/react/components/Layouts/Layout.js +35 -0
- package/react/components/Layouts/LayoutContainer.js +1 -1
- package/react/components/Layouts/MainPanel.d.ts +1 -0
- package/react/components/Layouts/MainPanel.js +11 -4
- package/react/components/Layouts/OverlayPanel.d.ts +8 -0
- package/react/components/Layouts/OverlayPanel.js +49 -0
- package/react/components/Layouts/Panel.d.ts +1 -0
- package/react/components/Layouts/index.d.ts +6 -2
- package/react/components/Layouts/index.js +12 -4
- package/react/components/Lists/BoxedList.d.ts +2 -0
- package/react/components/Lists/BoxedList.js +6 -4
- package/react/components/Modal.d.ts +2 -0
- package/react/components/Modal.js +11 -3
- package/react/components/Navigation/SideBarTabs.d.ts +1 -0
- package/react/components/Navigation/SideBarTabs.js +4 -0
- package/react/components/SearchBar.d.ts +23 -0
- package/react/components/SearchBar.js +87 -0
- package/react/components/Select.d.ts +1 -0
- package/react/components/Select.js +1 -0
- package/react/components/Spinner.js +1 -1
- package/react/components/SwitchGroup.d.ts +1 -0
- package/react/components/SwitchGroup.js +1 -1
- package/react/index.d.ts +2 -0
- package/react/index.js +5 -0
- package/sd_icons.eot +0 -0
- package/sd_icons.svg +189 -0
- package/sd_icons.ttf +0 -0
- package/sd_icons.woff +0 -0
@@ -0,0 +1,10 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
interface IProps {
|
3
|
+
children?: React.ReactNode;
|
4
|
+
background?: 'transparent' | 'light' | 'grey' | 'dark';
|
5
|
+
visible?: boolean;
|
6
|
+
}
|
7
|
+
export declare class ContentSplitter extends React.PureComponent<IProps> {
|
8
|
+
render(): JSX.Element;
|
9
|
+
}
|
10
|
+
export {};
|
@@ -0,0 +1,56 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
3
|
+
var extendStatics = function (d, b) {
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
6
|
+
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
7
|
+
return extendStatics(d, b);
|
8
|
+
};
|
9
|
+
return function (d, b) {
|
10
|
+
extendStatics(d, b);
|
11
|
+
function __() { this.constructor = d; }
|
12
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
13
|
+
};
|
14
|
+
})();
|
15
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
16
|
+
if (k2 === undefined) k2 = k;
|
17
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
18
|
+
}) : (function(o, m, k, k2) {
|
19
|
+
if (k2 === undefined) k2 = k;
|
20
|
+
o[k2] = m[k];
|
21
|
+
}));
|
22
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
23
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
24
|
+
}) : function(o, v) {
|
25
|
+
o["default"] = v;
|
26
|
+
});
|
27
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
28
|
+
if (mod && mod.__esModule) return mod;
|
29
|
+
var result = {};
|
30
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
31
|
+
__setModuleDefault(result, mod);
|
32
|
+
return result;
|
33
|
+
};
|
34
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
35
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
36
|
+
};
|
37
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
38
|
+
exports.ContentSplitter = void 0;
|
39
|
+
var React = __importStar(require("react"));
|
40
|
+
var classnames_1 = __importDefault(require("classnames"));
|
41
|
+
var ContentSplitter = /** @class */ (function (_super) {
|
42
|
+
__extends(ContentSplitter, _super);
|
43
|
+
function ContentSplitter() {
|
44
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
45
|
+
}
|
46
|
+
ContentSplitter.prototype.render = function () {
|
47
|
+
var _a;
|
48
|
+
var classes = classnames_1.default('sd-content-wrapper__content-splitter', (_a = {},
|
49
|
+
_a["sd-content-wrapper__content-splitter--" + this.props.background] = this.props.background !== 'light' && this.props.background !== undefined,
|
50
|
+
_a['content-splitter--visible'] = this.props.visible,
|
51
|
+
_a));
|
52
|
+
return (React.createElement("div", { className: classes }, this.props.children));
|
53
|
+
};
|
54
|
+
return ContentSplitter;
|
55
|
+
}(React.PureComponent));
|
56
|
+
exports.ContentSplitter = ContentSplitter;
|
@@ -0,0 +1,35 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
+
if (k2 === undefined) k2 = k;
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
5
|
+
}) : (function(o, m, k, k2) {
|
6
|
+
if (k2 === undefined) k2 = k;
|
7
|
+
o[k2] = m[k];
|
8
|
+
}));
|
9
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
10
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
11
|
+
}) : function(o, v) {
|
12
|
+
o["default"] = v;
|
13
|
+
});
|
14
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
15
|
+
if (mod && mod.__esModule) return mod;
|
16
|
+
var result = {};
|
17
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
18
|
+
__setModuleDefault(result, mod);
|
19
|
+
return result;
|
20
|
+
};
|
21
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
22
|
+
exports.Layout = void 0;
|
23
|
+
var React = __importStar(require("react"));
|
24
|
+
exports.Layout = function (_a) {
|
25
|
+
var header = _a.header, children = _a.children, theme = _a.theme;
|
26
|
+
return (React.createElement("div", { className: 'sd-page-grid--test docs-page__full-width-helper', "data-theme": theme },
|
27
|
+
React.createElement("div", { className: 'sd-main-menu' },
|
28
|
+
React.createElement("div", { className: 'sd-main-menu__inner' })),
|
29
|
+
React.createElement("header", { className: 'sd-top-menu' },
|
30
|
+
React.createElement("a", { className: 'sd-top-menu__collapse-nav' },
|
31
|
+
React.createElement("i", { className: 'icon-collapse icon--white' })),
|
32
|
+
React.createElement("p", { className: 'sd-top-menu__header' }, header)),
|
33
|
+
React.createElement("section", { id: '1', className: 'sd-content sd-content-wrapper' }, children),
|
34
|
+
React.createElement("footer", { className: 'bottom-bar' }, "This is the footer.")));
|
35
|
+
};
|
@@ -40,7 +40,7 @@ var LayoutContainer = /** @class */ (function (_super) {
|
|
40
40
|
return _super !== null && _super.apply(this, arguments) || this;
|
41
41
|
}
|
42
42
|
LayoutContainer.prototype.render = function () {
|
43
|
-
return (React.createElement("div", {
|
43
|
+
return (React.createElement("div", { className: 'sd-content-wrapper__main-content-area sd-main-content-grid comfort' }, this.props.children));
|
44
44
|
};
|
45
45
|
return LayoutContainer;
|
46
46
|
}(React.PureComponent));
|
@@ -31,19 +31,26 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
31
31
|
__setModuleDefault(result, mod);
|
32
32
|
return result;
|
33
33
|
};
|
34
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
35
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
36
|
+
};
|
34
37
|
Object.defineProperty(exports, "__esModule", { value: true });
|
35
38
|
exports.MainPanel = void 0;
|
36
39
|
var React = __importStar(require("react"));
|
40
|
+
var classnames_1 = __importDefault(require("classnames"));
|
37
41
|
var MainPanel = /** @class */ (function (_super) {
|
38
42
|
__extends(MainPanel, _super);
|
39
43
|
function MainPanel() {
|
40
44
|
return _super !== null && _super.apply(this, arguments) || this;
|
41
45
|
}
|
42
46
|
MainPanel.prototype.render = function () {
|
43
|
-
var
|
44
|
-
'sd-
|
45
|
-
|
46
|
-
|
47
|
+
var classes = classnames_1.default('sd-main-content-grid__content', {
|
48
|
+
'sd-padding--2': !this.props.padding || this.props.padding === 'small',
|
49
|
+
'sd-padding--3': this.props.padding === 'medium',
|
50
|
+
'sd-padding--4': this.props.padding === 'large',
|
51
|
+
'sd-padding--0': this.props.padding === 'none',
|
52
|
+
}, this.props.className);
|
53
|
+
return (React.createElement("div", { className: classes }, this.props.children));
|
47
54
|
};
|
48
55
|
return MainPanel;
|
49
56
|
}(React.PureComponent));
|
@@ -0,0 +1,49 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
3
|
+
var extendStatics = function (d, b) {
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
6
|
+
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
7
|
+
return extendStatics(d, b);
|
8
|
+
};
|
9
|
+
return function (d, b) {
|
10
|
+
extendStatics(d, b);
|
11
|
+
function __() { this.constructor = d; }
|
12
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
13
|
+
};
|
14
|
+
})();
|
15
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
16
|
+
if (k2 === undefined) k2 = k;
|
17
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
18
|
+
}) : (function(o, m, k, k2) {
|
19
|
+
if (k2 === undefined) k2 = k;
|
20
|
+
o[k2] = m[k];
|
21
|
+
}));
|
22
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
23
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
24
|
+
}) : function(o, v) {
|
25
|
+
o["default"] = v;
|
26
|
+
});
|
27
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
28
|
+
if (mod && mod.__esModule) return mod;
|
29
|
+
var result = {};
|
30
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
31
|
+
__setModuleDefault(result, mod);
|
32
|
+
return result;
|
33
|
+
};
|
34
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
35
|
+
exports.OverlayPanel = void 0;
|
36
|
+
var React = __importStar(require("react"));
|
37
|
+
var OverlayPanel = /** @class */ (function (_super) {
|
38
|
+
__extends(OverlayPanel, _super);
|
39
|
+
function OverlayPanel() {
|
40
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
41
|
+
}
|
42
|
+
OverlayPanel.prototype.render = function () {
|
43
|
+
return (React.createElement("div", { className: 'sd-main-content-grid__overlay' },
|
44
|
+
React.createElement("div", { className: 'sd-overlay-panel sd-overlay-panel--dark-ui' },
|
45
|
+
React.createElement("div", { className: 'side-panel side-panel--shadow-right side-panel--dark-ui' }, this.props.children))));
|
46
|
+
};
|
47
|
+
return OverlayPanel;
|
48
|
+
}(React.PureComponent));
|
49
|
+
exports.OverlayPanel = OverlayPanel;
|
@@ -1,9 +1,13 @@
|
|
1
1
|
export { Panel, PanelHeader, PanelContent, PanelContentBlock, PanelFooter, PanelHeaderSlidingToolbar } from './Panel';
|
2
|
+
export { Layout } from './Layout';
|
3
|
+
export { LayoutContainer } from './LayoutContainer';
|
2
4
|
export { HeaderPanel } from './HeaderPanel';
|
5
|
+
export { MainPanel, IMainPanelProps } from './MainPanel';
|
3
6
|
export { LeftPanel } from './LeftPanel';
|
4
7
|
export { RightPanel } from './RightPanel';
|
5
|
-
export {
|
6
|
-
export {
|
8
|
+
export { OverlayPanel } from './OverlayPanel';
|
9
|
+
export { AuthoringContainer } from './AuthoringContainer';
|
10
|
+
export { ContentSplitter } from './ContentSplitter';
|
7
11
|
export { PageLayout } from './PageLayout';
|
8
12
|
export { Container } from './Container';
|
9
13
|
export { AuthoringFrameContainer } from './AuthoringFrameContainer';
|
@@ -7,16 +7,24 @@ Object.defineProperty(exports, "PanelContent", { enumerable: true, get: function
|
|
7
7
|
Object.defineProperty(exports, "PanelContentBlock", { enumerable: true, get: function () { return Panel_1.PanelContentBlock; } });
|
8
8
|
Object.defineProperty(exports, "PanelFooter", { enumerable: true, get: function () { return Panel_1.PanelFooter; } });
|
9
9
|
Object.defineProperty(exports, "PanelHeaderSlidingToolbar", { enumerable: true, get: function () { return Panel_1.PanelHeaderSlidingToolbar; } });
|
10
|
+
var Layout_1 = require("./Layout");
|
11
|
+
Object.defineProperty(exports, "Layout", { enumerable: true, get: function () { return Layout_1.Layout; } });
|
12
|
+
var LayoutContainer_1 = require("./LayoutContainer");
|
13
|
+
Object.defineProperty(exports, "LayoutContainer", { enumerable: true, get: function () { return LayoutContainer_1.LayoutContainer; } });
|
10
14
|
var HeaderPanel_1 = require("./HeaderPanel");
|
11
15
|
Object.defineProperty(exports, "HeaderPanel", { enumerable: true, get: function () { return HeaderPanel_1.HeaderPanel; } });
|
16
|
+
var MainPanel_1 = require("./MainPanel");
|
17
|
+
Object.defineProperty(exports, "MainPanel", { enumerable: true, get: function () { return MainPanel_1.MainPanel; } });
|
12
18
|
var LeftPanel_1 = require("./LeftPanel");
|
13
19
|
Object.defineProperty(exports, "LeftPanel", { enumerable: true, get: function () { return LeftPanel_1.LeftPanel; } });
|
14
20
|
var RightPanel_1 = require("./RightPanel");
|
15
21
|
Object.defineProperty(exports, "RightPanel", { enumerable: true, get: function () { return RightPanel_1.RightPanel; } });
|
16
|
-
var
|
17
|
-
Object.defineProperty(exports, "
|
18
|
-
var
|
19
|
-
Object.defineProperty(exports, "
|
22
|
+
var OverlayPanel_1 = require("./OverlayPanel");
|
23
|
+
Object.defineProperty(exports, "OverlayPanel", { enumerable: true, get: function () { return OverlayPanel_1.OverlayPanel; } });
|
24
|
+
var AuthoringContainer_1 = require("./AuthoringContainer");
|
25
|
+
Object.defineProperty(exports, "AuthoringContainer", { enumerable: true, get: function () { return AuthoringContainer_1.AuthoringContainer; } });
|
26
|
+
var ContentSplitter_1 = require("./ContentSplitter");
|
27
|
+
Object.defineProperty(exports, "ContentSplitter", { enumerable: true, get: function () { return ContentSplitter_1.ContentSplitter; } });
|
20
28
|
var PageLayout_1 = require("./PageLayout");
|
21
29
|
Object.defineProperty(exports, "PageLayout", { enumerable: true, get: function () { return PageLayout_1.PageLayout; } });
|
22
30
|
var Container_1 = require("./Container");
|
@@ -17,8 +17,10 @@ interface IPropsItem {
|
|
17
17
|
footer?: React.ReactNode;
|
18
18
|
actions?: React.ReactNode;
|
19
19
|
children?: React.ReactNode;
|
20
|
+
density?: 'compact' | 'comfortable' | 'loose';
|
20
21
|
type?: 'default' | 'primary' | 'success' | 'warning' | 'alert' | 'highlight';
|
21
22
|
clickable?: boolean;
|
23
|
+
alignVertical?: 'start' | 'center';
|
22
24
|
slideInActions?: boolean;
|
23
25
|
selected?: boolean;
|
24
26
|
onClick?(): void;
|
@@ -103,13 +103,15 @@ var BoxedListItem = /** @class */ (function (_super) {
|
|
103
103
|
BoxedListItem.prototype.render = function () {
|
104
104
|
var _a;
|
105
105
|
var classes = classnames_1.default('boxed-list__item', (_a = {
|
106
|
-
'
|
107
|
-
'boxed-list__item--clickable': this.props.clickable === true,
|
108
|
-
'boxed-list__item--selected': this.props.selected
|
106
|
+
'boxed-list__item--comfortable': this.props.density === undefined
|
109
107
|
},
|
108
|
+
_a["boxed-list__item--" + this.props.density] = this.props.density || this.props.density !== undefined,
|
109
|
+
_a['boxed-list__item--clickable'] = this.props.clickable === true,
|
110
|
+
_a['boxed-list__item--selected'] = this.props.selected,
|
110
111
|
_a["boxed-list__item--" + this.props.type] = this.props.type || this.props.type !== undefined,
|
112
|
+
_a["boxed-list__item--align-" + this.props.alignVertical] = this.props.alignVertical,
|
111
113
|
_a));
|
112
|
-
return (React.createElement("li", { className: classes },
|
114
|
+
return (React.createElement("li", { className: classes, onClick: this.props.onClick },
|
113
115
|
this.props.media && (React.createElement(BoxedListMedia, null, this.props.media)),
|
114
116
|
React.createElement(BoxedListContent, null, this.props.children),
|
115
117
|
this.props.footer && (React.createElement(BoxedListFooter, null, this.props.footer)),
|
@@ -4,6 +4,8 @@ interface IProps {
|
|
4
4
|
className?: string;
|
5
5
|
theme?: string;
|
6
6
|
visible?: boolean;
|
7
|
+
contentBg?: 'default' | 'medium' | 'dark';
|
8
|
+
contentPadding?: 'none' | 'small' | 'medium' | 'large';
|
7
9
|
size?: 'small' | 'medium' | 'large' | 'x-large';
|
8
10
|
maximized?: boolean;
|
9
11
|
headerTemplate?: JSX.Element | string;
|
@@ -19,15 +19,23 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
19
|
exports.Modal = void 0;
|
20
20
|
var react_1 = __importDefault(require("react"));
|
21
21
|
var dialog_1 = require("@superdesk/primereact/dialog");
|
22
|
+
var classnames_1 = __importDefault(require("classnames"));
|
22
23
|
var Modal = /** @class */ (function (_super) {
|
23
24
|
__extends(Modal, _super);
|
24
25
|
function Modal() {
|
25
26
|
return _super !== null && _super.apply(this, arguments) || this;
|
26
27
|
}
|
27
28
|
Modal.prototype.render = function () {
|
28
|
-
|
29
|
-
|
30
|
-
|
29
|
+
var _a;
|
30
|
+
var classes = classnames_1.default((_a = {},
|
31
|
+
_a["p-dialog-content--" + this.props.size] = this.props.size,
|
32
|
+
_a['p-dialog-content--default'] = this.props.contentBg === undefined,
|
33
|
+
_a["p-dialog-content--" + this.props.contentBg] = this.props.contentBg,
|
34
|
+
_a['p-dialog-content--s-padding'] = this.props.contentPadding === undefined,
|
35
|
+
_a["p-dialog-content--" + this.props.contentPadding] = this.props.contentPadding,
|
36
|
+
_a), this.props.className);
|
37
|
+
return (react_1.default.createElement("div", { style: { display: 'content' }, "data-theme": this.props.theme !== 'dark' ? null : 'dark-ui' },
|
38
|
+
react_1.default.createElement(dialog_1.Dialog, { id: this.props.id, visible: this.props.visible, header: this.props.headerTemplate, footer: this.props.footerTemplate, closeOnEscape: this.props.closeOnEscape, maximized: this.props.maximized, contentClassName: classes, onShow: this.props.onShow, onHide: this.props.onHide }, this.props.children)));
|
31
39
|
};
|
32
40
|
return Modal;
|
33
41
|
}(react_1.default.Component));
|
@@ -35,6 +35,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
35
35
|
exports.SideBarTabs = void 0;
|
36
36
|
var React = __importStar(require("react"));
|
37
37
|
var Icon_1 = require("../Icon");
|
38
|
+
var Badge_1 = require("../Badge");
|
38
39
|
var SideBarTabs = /** @class */ (function (_super) {
|
39
40
|
__extends(SideBarTabs, _super);
|
40
41
|
function SideBarTabs(props) {
|
@@ -71,6 +72,9 @@ var SideBarTabs = /** @class */ (function (_super) {
|
|
71
72
|
React.createElement("a", { role: 'button', "aria-label": item['tooltip'], className: 'sd-sidetab-menu__btn' + (item['active'] ?
|
72
73
|
' sd-sidetab-menu__btn--active' :
|
73
74
|
(index === _this.state.index ? ' sd-sidetab-menu__btn--active' : '')), onClick: function () { return _this.handleClick(item, index, event); } },
|
75
|
+
item['badgeValue'] != null
|
76
|
+
? (React.createElement(Badge_1.Badge, { text: item['badgeValue'], type: 'primary' }))
|
77
|
+
: null,
|
74
78
|
React.createElement("span", { className: 'sd-sidetab-menu__main-icon ' },
|
75
79
|
React.createElement(Icon_1.Icon, { size: item['size'], name: item['icon'] })),
|
76
80
|
React.createElement("i", { className: 'sd-sidetab-menu__helper-icon icon-close-small' }))));
|
@@ -0,0 +1,23 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
interface IProps {
|
3
|
+
value?: string | number;
|
4
|
+
type?: 'expanded' | 'collapsed' | 'boxed';
|
5
|
+
placeholder: string;
|
6
|
+
focused?: boolean;
|
7
|
+
boxed?: boolean;
|
8
|
+
onSubmit?(): void;
|
9
|
+
}
|
10
|
+
interface IState {
|
11
|
+
inputValue: any;
|
12
|
+
type: string;
|
13
|
+
focused: boolean;
|
14
|
+
boxed?: boolean;
|
15
|
+
}
|
16
|
+
export declare class SearchBar extends React.PureComponent<IProps, IState> {
|
17
|
+
private inputRef;
|
18
|
+
constructor(props: IProps);
|
19
|
+
componentDidUpdate(prevProps: any): void;
|
20
|
+
componentDidMount: () => void;
|
21
|
+
render(): JSX.Element;
|
22
|
+
}
|
23
|
+
export {};
|
@@ -0,0 +1,87 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
3
|
+
var extendStatics = function (d, b) {
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
6
|
+
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
7
|
+
return extendStatics(d, b);
|
8
|
+
};
|
9
|
+
return function (d, b) {
|
10
|
+
extendStatics(d, b);
|
11
|
+
function __() { this.constructor = d; }
|
12
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
13
|
+
};
|
14
|
+
})();
|
15
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
16
|
+
if (k2 === undefined) k2 = k;
|
17
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
18
|
+
}) : (function(o, m, k, k2) {
|
19
|
+
if (k2 === undefined) k2 = k;
|
20
|
+
o[k2] = m[k];
|
21
|
+
}));
|
22
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
23
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
24
|
+
}) : function(o, v) {
|
25
|
+
o["default"] = v;
|
26
|
+
});
|
27
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
28
|
+
if (mod && mod.__esModule) return mod;
|
29
|
+
var result = {};
|
30
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
31
|
+
__setModuleDefault(result, mod);
|
32
|
+
return result;
|
33
|
+
};
|
34
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
35
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
36
|
+
};
|
37
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
38
|
+
exports.SearchBar = void 0;
|
39
|
+
var React = __importStar(require("react"));
|
40
|
+
var classnames_1 = __importDefault(require("classnames"));
|
41
|
+
var Icon_1 = require("./Icon");
|
42
|
+
var SearchBar = /** @class */ (function (_super) {
|
43
|
+
__extends(SearchBar, _super);
|
44
|
+
function SearchBar(props) {
|
45
|
+
var _this = _super.call(this, props) || this;
|
46
|
+
_this.componentDidMount = function () {
|
47
|
+
document.addEventListener("mousedown", function (event) {
|
48
|
+
if (_this.inputRef.current && !_this.inputRef.current.contains(event.target)) {
|
49
|
+
_this.setState({ focused: false });
|
50
|
+
}
|
51
|
+
});
|
52
|
+
};
|
53
|
+
_this.state = {
|
54
|
+
inputValue: _this.props.value ? _this.props.value : '',
|
55
|
+
focused: _this.props.focused ? _this.props.focused : false,
|
56
|
+
type: _this.props.type ? _this.props.type : 'expanded',
|
57
|
+
boxed: _this.props.boxed ? _this.props.boxed : false,
|
58
|
+
};
|
59
|
+
_this.inputRef = React.createRef();
|
60
|
+
return _this;
|
61
|
+
}
|
62
|
+
SearchBar.prototype.componentDidUpdate = function (prevProps) {
|
63
|
+
if (prevProps.value !== this.props.value) {
|
64
|
+
this.setState({ inputValue: this.props.value });
|
65
|
+
}
|
66
|
+
};
|
67
|
+
SearchBar.prototype.render = function () {
|
68
|
+
var _a;
|
69
|
+
var _this = this;
|
70
|
+
var classes = classnames_1.default('sd-searchbar', (_a = {},
|
71
|
+
_a["sd-searchbar--" + this.state.type] = this.props.type,
|
72
|
+
_a['sd-searchbar--expanded'] = this.state.type === 'expanded' || this.props.type === undefined,
|
73
|
+
_a['sd-searchbar--focused'] = this.state.focused,
|
74
|
+
_a['sd-searchbar--boxed'] = this.state.boxed,
|
75
|
+
_a));
|
76
|
+
return (React.createElement("div", { className: classes, ref: this.inputRef },
|
77
|
+
React.createElement("label", { className: "sd-searchbar__icon" }),
|
78
|
+
React.createElement("input", { id: "search-input", ref: function (input) { return (input && _this.props.focused) && input.focus(); }, className: "sd-searchbar__input", type: "text", placeholder: this.props.placeholder, value: this.state.inputValue, onChange: function (e) { return _this.setState({ inputValue: e.target.value }); }, onFocus: function () { return _this.setState({ focused: true }); } }),
|
79
|
+
this.state.inputValue &&
|
80
|
+
React.createElement("button", { className: "sd-searchbar__cancel", onClick: function () { return _this.setState({ inputValue: '' }); } },
|
81
|
+
React.createElement(Icon_1.Icon, { name: 'remove-sign' })),
|
82
|
+
React.createElement("button", { id: "sd-searchbar__search-btn", className: "sd-searchbar__search-btn", onSubmit: function () { return _this.props.onSubmit; } },
|
83
|
+
React.createElement(Icon_1.Icon, { name: 'chevron-right-thin' }))));
|
84
|
+
};
|
85
|
+
return SearchBar;
|
86
|
+
}(React.PureComponent));
|
87
|
+
exports.SearchBar = SearchBar;
|
@@ -61,6 +61,7 @@ var Select = /** @class */ (function (_super) {
|
|
61
61
|
'sd-input--inline-label': this.props.inlineLabel,
|
62
62
|
'sd-input--required': this.props.required,
|
63
63
|
'sd-input--disabled': this.props.disabled,
|
64
|
+
'sd-input--full-width': this.props.fullWidth,
|
64
65
|
'sd-input--invalid': this.props.invalid || this.state.invalid,
|
65
66
|
});
|
66
67
|
var labelClasses = classnames_1.default('sd-input__label', {
|
@@ -62,7 +62,7 @@ var Spinner = /** @class */ (function (_super) {
|
|
62
62
|
_a["sd-spinner--" + this.props.size] = this.props.size || this.props.size !== undefined,
|
63
63
|
_a));
|
64
64
|
return (React.createElement("svg", { role: "progressbar", className: classes, viewBox: "0 0 50 50" },
|
65
|
-
React.createElement("circle", { className: "sd-spinner__path", cx: "25", cy: "25", r: "20", fill: "none",
|
65
|
+
React.createElement("circle", { className: "sd-spinner__path", cx: "25", cy: "25", r: "20", fill: "none", strokeWidth: "5" })));
|
66
66
|
};
|
67
67
|
return Spinner;
|
68
68
|
}(React.PureComponent));
|
@@ -49,7 +49,7 @@ var SwitchGroup = /** @class */ (function (_super) {
|
|
49
49
|
_a["sd-switch__group--vertical"] = this.props.orientation !== 'horizontal',
|
50
50
|
_a["sd-switch__group--horizontal"] = this.props.orientation === 'horizontal',
|
51
51
|
_a["sd-switch__group--right"] = this.props.align === 'right',
|
52
|
-
_a));
|
52
|
+
_a), this.props.className);
|
53
53
|
return (React.createElement("div", { className: classes }, this.props.children));
|
54
54
|
};
|
55
55
|
return SwitchGroup;
|
package/react/index.d.ts
CHANGED
@@ -63,6 +63,8 @@ export { SelectGrid } from './components/SelectGrid';
|
|
63
63
|
export { IconPicker } from './components/IconPicker';
|
64
64
|
export { ThemeSelector } from './components/ThemeSelector';
|
65
65
|
export { DropZone } from './components/DropZone';
|
66
|
+
export { CreateButton } from './components/CreateButton';
|
67
|
+
export { SearchBar } from './components/SearchBar';
|
66
68
|
export * from './components/Layouts';
|
67
69
|
export * from './components/Form';
|
68
70
|
export * from './components/Navigation';
|
package/react/index.js
CHANGED
@@ -159,6 +159,11 @@ var ThemeSelector_1 = require("./components/ThemeSelector");
|
|
159
159
|
Object.defineProperty(exports, "ThemeSelector", { enumerable: true, get: function () { return ThemeSelector_1.ThemeSelector; } });
|
160
160
|
var DropZone_1 = require("./components/DropZone");
|
161
161
|
Object.defineProperty(exports, "DropZone", { enumerable: true, get: function () { return DropZone_1.DropZone; } });
|
162
|
+
var CreateButton_1 = require("./components/CreateButton");
|
163
|
+
Object.defineProperty(exports, "CreateButton", { enumerable: true, get: function () { return CreateButton_1.CreateButton; } });
|
164
|
+
// export { TreeSelect } from './components/TreeSelect';
|
165
|
+
var SearchBar_1 = require("./components/SearchBar");
|
166
|
+
Object.defineProperty(exports, "SearchBar", { enumerable: true, get: function () { return SearchBar_1.SearchBar; } });
|
162
167
|
__exportStar(require("./components/Layouts"), exports);
|
163
168
|
__exportStar(require("./components/Form"), exports);
|
164
169
|
__exportStar(require("./components/Navigation"), exports);
|
package/sd_icons.eot
ADDED
Binary file
|