namirasoft-site-react 1.4.407 → 1.4.408

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.
@@ -11,6 +11,7 @@ export interface NSLayoutProps extends IBaseComponentProps, NSRouterMakerProps {
11
11
  scope: string;
12
12
  logo: string;
13
13
  header: {
14
+ enabled?: boolean;
14
15
  right: IHeaderRightProps;
15
16
  left?: {
16
17
  title?: string;
@@ -25,18 +25,19 @@ export function NSLayout(props) {
25
25
  var _a;
26
26
  if (e.key === "Enter")
27
27
  (_a = props.onEnterPressed) === null || _a === void 0 ? void 0 : _a.call(props);
28
- }, children: [_jsxs(NSHeader, { left: {
29
- scope: props.scope,
30
- name: "Header",
31
- logo: props.logo,
32
- title: (_k = props.header.left) === null || _k === void 0 ? void 0 : _k.title
33
- }, right: props.header.right, isLoggedIn: props.isLoggedIn, notifier: props.notifier, children: [props.notifications.length !== 0 &&
34
- _jsx(_Fragment, { children: props.notifications.map((notification, index) => _jsx(Fragment, { children: _jsx(NSBarNotification, Object.assign({}, notification, { onClose: () => {
35
- props.notifier.delNotification(notification.id);
36
- }, onChangeState: () => {
37
- props.notifier.onChangeState();
38
- } })) }, `NSLayout_fragment_key_${index}`)) }), _jsxs("div", { className: 'd-none d-lg-block', children: [alerts.length !== 0 && alerts.map((alert, index) => _jsx(NSBarAlert, Object.assign({}, alert), `NSLayout_NSBarAlert_key_${index}`)), isValidAction(props.action) &&
39
- _jsx(NSBarAction, Object.assign({}, props.action))] })] }), _jsxs("div", { className: 'd-block d-lg-none', children: [alerts.length !== 0 && alerts.map((alert, index) => _jsx(NSBarAlert, Object.assign({}, alert), `NSLayout_NSBarAlert_key_${index}`)), isValidAction(props.action) && _jsx(NSBarAction, Object.assign({}, props.action))] }), props.title &&
28
+ }, children: [props.header.enabled !== false &&
29
+ _jsxs(NSHeader, { left: {
30
+ scope: props.scope,
31
+ name: "Header",
32
+ logo: props.logo,
33
+ title: (_k = props.header.left) === null || _k === void 0 ? void 0 : _k.title
34
+ }, right: props.header.right, isLoggedIn: props.isLoggedIn, notifier: props.notifier, children: [props.notifications.length !== 0 &&
35
+ _jsx(_Fragment, { children: props.notifications.map((notification, index) => _jsx(Fragment, { children: _jsx(NSBarNotification, Object.assign({}, notification, { onClose: () => {
36
+ props.notifier.delNotification(notification.id);
37
+ }, onChangeState: () => {
38
+ props.notifier.onChangeState();
39
+ } })) }, `NSLayout_fragment_key_${index}`)) }), _jsxs("div", { className: 'd-none d-lg-block', children: [alerts.length !== 0 && alerts.map((alert, index) => _jsx(NSBarAlert, Object.assign({}, alert), `NSLayout_NSBarAlert_key_${index}`)), isValidAction(props.action) &&
40
+ _jsx(NSBarAction, Object.assign({}, props.action))] })] }), _jsxs("div", { className: 'd-block d-lg-none', children: [alerts.length !== 0 && alerts.map((alert, index) => _jsx(NSBarAlert, Object.assign({}, alert), `NSLayout_NSBarAlert_key_${index}`)), isValidAction(props.action) && _jsx(NSBarAction, Object.assign({}, props.action))] }), props.title &&
40
41
  _jsxs(_Fragment, { children: [_jsx(NSSpace, { size: NSSpaceSizeType.MINI }), _jsx(NSBarTitle, Object.assign({}, props.title))] }), _jsx("main", { className: `d-flex flex-column text-white ${Styles.ns_layout_main}`, children: props.children }), _jsx(NSFooter, { scope: props.scope, name: "Footer", logo: props.logo, isLoggedIn: props.isLoggedIn })] }));
41
42
  }
42
43
  //# sourceMappingURL=NSLayout.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NSLayout.js","sourceRoot":"","sources":["../../src/components/NSLayout.tsx"],"names":[],"mappings":";AAAA,OAAO,MAAM,MAAM,uBAAuB,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAa,MAAM,OAAO,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,OAAO,EAAE,iBAAiB,EAA0B,MAAM,qBAAqB,CAAC;AAEhF,OAAO,EAAo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J,eAAM,SAAS,EAAE,iCAAiC,MAAM,CAAC,cAAc,EAAE,YACvE,KAAK,CAAC,QAAQ,GACT,EACP,KAAC,QAAQ,IACR,KAAK,EAAE,KAAK,CAAC,KAAK,EAClB,IAAI,EAAC,QAAQ,EACb,IAAI,EAAE,KAAK,CAAC,IAAI,EAChB,UAAU,EAAE,KAAK,CAAC,UAAU,GAC3B,IACI,CACP,CAAC;AACH,CAAC"}
package/package.json CHANGED
@@ -8,7 +8,7 @@
8
8
  "framework": "npm",
9
9
  "application": "package",
10
10
  "private": false,
11
- "version": "1.4.407",
11
+ "version": "1.4.408",
12
12
  "author": "Amir Abolhasani",
13
13
  "license": "MIT",
14
14
  "main": "./dist/main.js",
@@ -52,7 +52,7 @@
52
52
  "react-phone-number-input": "^3.4.12",
53
53
  "react-router-dom": "^7.6.2",
54
54
  "react-scripts": "^5.0.1",
55
- "styled-components": "^6.1.18",
55
+ "styled-components": "^6.1.19",
56
56
  "xlsx": "^0.18.5"
57
57
  },
58
58
  "eslintConfig": {
@@ -17,6 +17,7 @@ export interface NSLayoutProps extends IBaseComponentProps, NSRouterMakerProps
17
17
  scope: string;
18
18
  logo: string;
19
19
  header: {
20
+ enabled?: boolean;
20
21
  right: IHeaderRightProps;
21
22
  left?: {
22
23
  title?: string;
@@ -56,53 +57,56 @@ export function NSLayout(props: NSLayoutProps)
56
57
  props.onEnterPressed?.();
57
58
  }}
58
59
  >
59
- <NSHeader
60
- left={{
61
- scope: props.scope,
62
- name: "Header",
63
- logo: props.logo,
64
- title: props.header.left?.title
65
- }}
66
- right={props.header.right}
67
- isLoggedIn={props.isLoggedIn}
68
- notifier={props.notifier}
69
- >
70
- {
71
- props.notifications.length !== 0 &&
72
- <>
73
- {
74
- props.notifications.map((notification, index) =>
75
- <Fragment key={`NSLayout_fragment_key_${index}`}>
76
- <NSBarNotification
77
- {...notification}
78
- onClose={() =>
79
- {
80
- props.notifier.delNotification(notification.id);
81
- }}
82
- onChangeState={() =>
83
- {
84
- props.notifier.onChangeState();
85
- }}
86
- />
87
- </Fragment>
88
- )
89
- }
90
- </>
91
- }
92
- {/* Desktop */}
93
- <div className='d-none d-lg-block'>
94
- {
95
- alerts.length !== 0 && alerts.map((alert, index) => <NSBarAlert key={`NSLayout_NSBarAlert_key_${index}`} {...alert} />)
96
- }
60
+ {
61
+ props.header.enabled !== false &&
62
+ <NSHeader
63
+ left={{
64
+ scope: props.scope,
65
+ name: "Header",
66
+ logo: props.logo,
67
+ title: props.header.left?.title
68
+ }}
69
+ right={props.header.right}
70
+ isLoggedIn={props.isLoggedIn}
71
+ notifier={props.notifier}
72
+ >
97
73
  {
98
- isValidAction(props.action) &&
99
- <NSBarAction
100
- {...props.action}
101
- />
74
+ props.notifications.length !== 0 &&
75
+ <>
76
+ {
77
+ props.notifications.map((notification, index) =>
78
+ <Fragment key={`NSLayout_fragment_key_${index}`}>
79
+ <NSBarNotification
80
+ {...notification}
81
+ onClose={() =>
82
+ {
83
+ props.notifier.delNotification(notification.id);
84
+ }}
85
+ onChangeState={() =>
86
+ {
87
+ props.notifier.onChangeState();
88
+ }}
89
+ />
90
+ </Fragment>
91
+ )
92
+ }
93
+ </>
102
94
  }
103
- </div>
104
- {/* Desktop */}
105
- </NSHeader>
95
+ {/* Desktop */}
96
+ <div className='d-none d-lg-block'>
97
+ {
98
+ alerts.length !== 0 && alerts.map((alert, index) => <NSBarAlert key={`NSLayout_NSBarAlert_key_${index}`} {...alert} />)
99
+ }
100
+ {
101
+ isValidAction(props.action) &&
102
+ <NSBarAction
103
+ {...props.action}
104
+ />
105
+ }
106
+ </div>
107
+ {/* Desktop */}
108
+ </NSHeader>
109
+ }
106
110
  <div className='d-block d-lg-none'>
107
111
  {/* Mobile */}
108
112
  {