@next-bricks/nav 0.10.4 → 0.10.5
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/bricks.json +2 -2
- package/dist/chunks/{3981.8f71ff52.js → 3981.8ca3a2ac.js} +3 -3
- package/dist/chunks/{3981.8f71ff52.js.map → 3981.8ca3a2ac.js.map} +1 -1
- package/dist/chunks/easyops-navbar-alerts.ed925132.js +2 -0
- package/dist/chunks/{easyops-navbar-alerts.9ea93872.js.map → easyops-navbar-alerts.ed925132.js.map} +1 -1
- package/dist/chunks/{main.1e913769.js → main.b78098c0.js} +2 -2
- package/dist/chunks/{main.1e913769.js.map → main.b78098c0.js.map} +1 -1
- package/dist/examples.json +3 -3
- package/dist/{index.a633ef43.js → index.2f5c8bce.js} +2 -2
- package/dist/{index.a633ef43.js.map → index.2f5c8bce.js.map} +1 -1
- package/dist/manifest.json +27 -27
- package/dist/types.json +53 -53
- package/package.json +2 -2
- package/dist/chunks/easyops-navbar-alerts.9ea93872.js +0 -2
- /package/dist/chunks/{3981.8f71ff52.js.LICENSE.txt → 3981.8ca3a2ac.js.LICENSE.txt} +0 -0
package/dist/types.json
CHANGED
|
@@ -4,59 +4,6 @@
|
|
|
4
4
|
"events": [],
|
|
5
5
|
"methods": []
|
|
6
6
|
},
|
|
7
|
-
"eo-app-bar-wrapper": {
|
|
8
|
-
"properties": [
|
|
9
|
-
{
|
|
10
|
-
"name": "isFixed",
|
|
11
|
-
"annotation": {
|
|
12
|
-
"type": "keyword",
|
|
13
|
-
"value": "boolean"
|
|
14
|
-
}
|
|
15
|
-
},
|
|
16
|
-
{
|
|
17
|
-
"name": "position",
|
|
18
|
-
"annotation": {
|
|
19
|
-
"type": "union",
|
|
20
|
-
"types": [
|
|
21
|
-
{
|
|
22
|
-
"type": "jsLiteral",
|
|
23
|
-
"value": "static"
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
"type": "jsLiteral",
|
|
27
|
-
"value": "fixed"
|
|
28
|
-
}
|
|
29
|
-
]
|
|
30
|
-
}
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
"name": "displayCenter",
|
|
34
|
-
"annotation": {
|
|
35
|
-
"type": "keyword",
|
|
36
|
-
"value": "boolean"
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
"name": "extraAppBarContentStyle",
|
|
41
|
-
"annotation": {
|
|
42
|
-
"type": "reference",
|
|
43
|
-
"typeName": {
|
|
44
|
-
"type": "qualifiedName",
|
|
45
|
-
"left": {
|
|
46
|
-
"type": "identifier",
|
|
47
|
-
"name": "React"
|
|
48
|
-
},
|
|
49
|
-
"right": {
|
|
50
|
-
"type": "identifier",
|
|
51
|
-
"name": "CSSProperties"
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
],
|
|
57
|
-
"events": [],
|
|
58
|
-
"methods": []
|
|
59
|
-
},
|
|
60
7
|
"eo-frame-breadcrumb": {
|
|
61
8
|
"properties": [
|
|
62
9
|
{
|
|
@@ -145,6 +92,59 @@
|
|
|
145
92
|
}
|
|
146
93
|
]
|
|
147
94
|
},
|
|
95
|
+
"eo-app-bar-wrapper": {
|
|
96
|
+
"properties": [
|
|
97
|
+
{
|
|
98
|
+
"name": "isFixed",
|
|
99
|
+
"annotation": {
|
|
100
|
+
"type": "keyword",
|
|
101
|
+
"value": "boolean"
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
"name": "position",
|
|
106
|
+
"annotation": {
|
|
107
|
+
"type": "union",
|
|
108
|
+
"types": [
|
|
109
|
+
{
|
|
110
|
+
"type": "jsLiteral",
|
|
111
|
+
"value": "static"
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
"type": "jsLiteral",
|
|
115
|
+
"value": "fixed"
|
|
116
|
+
}
|
|
117
|
+
]
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
"name": "displayCenter",
|
|
122
|
+
"annotation": {
|
|
123
|
+
"type": "keyword",
|
|
124
|
+
"value": "boolean"
|
|
125
|
+
}
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
"name": "extraAppBarContentStyle",
|
|
129
|
+
"annotation": {
|
|
130
|
+
"type": "reference",
|
|
131
|
+
"typeName": {
|
|
132
|
+
"type": "qualifiedName",
|
|
133
|
+
"left": {
|
|
134
|
+
"type": "identifier",
|
|
135
|
+
"name": "React"
|
|
136
|
+
},
|
|
137
|
+
"right": {
|
|
138
|
+
"type": "identifier",
|
|
139
|
+
"name": "CSSProperties"
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
],
|
|
145
|
+
"events": [],
|
|
146
|
+
"methods": []
|
|
147
|
+
},
|
|
148
148
|
"eo-sidebar-menu-item": {
|
|
149
149
|
"properties": [
|
|
150
150
|
{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@next-bricks/nav",
|
|
3
|
-
"version": "0.10.
|
|
3
|
+
"version": "0.10.5",
|
|
4
4
|
"homepage": "https://github.com/easyops-cn/next-bricks/tree/master/bricks/nav",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -43,5 +43,5 @@
|
|
|
43
43
|
"@next-bricks/form": "*",
|
|
44
44
|
"@next-bricks/icons": "*"
|
|
45
45
|
},
|
|
46
|
-
"gitHead": "
|
|
46
|
+
"gitHead": "c12ad9433dd5dfc6c3d1106149a445142becb32a"
|
|
47
47
|
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunk_next_bricks_nav=self.webpackChunk_next_bricks_nav||[]).push([[6681,5850,5628],{5074:(e,t,r)=>{r.r(t),r.d(t,{EasyopsNavbarAlerts:()=>i,EasyopsNavbarAlertsComponent:()=>k,WrappedIcon:()=>y,WrappedLink:()=>w});var n,o,a,i,c=r(5066),l=r(8657),s=r.n(l),u=r(7844),f=r(8835),d=r(6594),p=r(1150),v=r(738),m=(r(2006),r(2890)),g=r(5239),h=r.n(g),b=r(7128),y=(0,f.wrapBrick)("eo-icon"),w=(0,f.wrapBrick)("eo-link"),{defineElement:x}=(0,u.createDecorators)();o=x("nav.easyops-navbar-alerts",{styleTexts:[b.Z]});class E extends f.ReactNextElement{render(){return s().createElement(k,null)}}a=E,[i,n]=(0,c.Z)(a,[],[o],0,void 0,f.ReactNextElement).c,n();var S=new m.o(localStorage);function k(){var[e,t]=(0,l.useState)(null),[r,n]=(0,l.useState)(null),o=(0,p.useCurrentApp)(),a=(0,l.useMemo)((()=>{var e=v.auth.getAuth();return"license:".concat(e.org)}),[]);(0,l.useEffect)((()=>{var e,r,n=v.auth.getAuth(),o=null===(e=n.license)||void 0===e?void 0:e.validDaysLeft;o&&o<=15&&n.isAdmin&&(!(r=S.getItem(a))||h()().unix()>r)&&t(o)}),[a]),(0,l.useEffect)((()=>{var e=e=>{var t=e.detail.renderTime,{loadTime:r,loadInfoPage:a}=(0,d.getRuntime)().getMiscSettings();null!=o&&o.isBuildPush&&r>0&&t>r&&n({renderTime:j(t),suggestTime:j(r),suggestUrl:a})};return window.addEventListener("route.render",e),()=>{window.removeEventListener("route.render",e)}}),[o]);var i=(0,l.useCallback)((()=>{S.setItem(a,h()().unix()+86400),t(null)}),[a]);return s().createElement(s().Fragment,null,r&&s().createElement(Z,{text:"您的页面存在性能问题, 当前页面渲染时间 ".concat(r.renderTime," 秒, 规定阈值为: ").concat(r.suggestTime," 秒, 您已超过。请您针对该页面进行性能优化!"),type:"warning",link:r.suggestUrl?{label:"建议解决思路",url:r.suggestUrl}:void 0}),null!==e&&s().createElement(Z,{text:"离 License 过期还有 ".concat(e," 天"),type:"info",closable:!0,onClose:i}))}function Z(e){var{text:t,type:r,closable:n,link:o,onClose:a}=e;return s().createElement("div",{className:"alert ".concat(r)},s().createElement("span",{className:"text"},t),o&&s().createElement(w,{className:"link",href:o.url,target:"_blank"},o.label),n&&s().createElement(y,{lib:"antd",icon:"close",className:"icon",role:"button",onClick:a}))}function j(e){return Math.floor(100*e)/1e5}},7128:(e,t,r)=>{r.d(t,{Z:()=>c});var n=r(9601),o=r.n(n),a=r(2609),i=r.n(a)()(o());i.push([e.id,":host{display:block}:host([hidden]){display:none}.alert{height:32px;padding:0 20px;display:flex;justify-content:center;align-items:center}.text{color:var(--antd-text-color);min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.icon{margin-left:20px;cursor:pointer;color:#8c8c8c}.info{background-color:var(--color-info-bg)}.warning{background-color:var(--color-warning-bg)}",""]);const c=i.toString()},2609:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r="",n=void 0!==t[5];return t[4]&&(r+="@supports (".concat(t[4],") {")),t[2]&&(r+="@media ".concat(t[2]," {")),n&&(r+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),r+=e(t),n&&(r+="}"),t[2]&&(r+="}"),t[4]&&(r+="}"),r})).join("")},t.i=function(e,r,n,o,a){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(n)for(var c=0;c<this.length;c++){var l=this[c][0];null!=l&&(i[l]=!0)}for(var s=0;s<e.length;s++){var u=[].concat(e[s]);n&&i[u[0]]||(void 0!==a&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=a),r&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=r):u[2]=r),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),t.push(u))}},t}},9601:e=>{e.exports=function(e){return e[1]}},5066:(e,t,r)=>{r.d(t,{Z:()=>c});var n=r(6522),o=r(1815);function a(e,t,r){"symbol"==(0,n.Z)(t)&&(t=(t=t.description)?"["+t+"]":"");try{Object.defineProperty(e,"name",{configurable:!0,value:r?r+" "+t:t})}catch(e){}return e}var i=r(5850);function c(e,t,r,c,l,s){function u(e,t,r){return function(n,o){return r&&r(n),e[t].call(n,o)}}function f(e,t){for(var r=0;r<e.length;r++)e[r].call(t);return t}function d(e,t,r,n){if("function"!=typeof e&&(n||void 0!==e))throw new TypeError(t+" must "+(r||"be")+" a function"+(n?"":" or undefined"));return e}function p(e,t,r,o,i,c,l,s,f,p,v,m,g){function h(e){if(!g(e))throw new TypeError("Attempted to access private element on non-instance")}var b,y,w=t[0],x=t[3],E=!s;if(!E){r||Array.isArray(w)||(w=[w]);var S={},k=[],Z=3===i?"get":4===i||m?"set":"value";p?(v||m?S={get:a((function(){return x(this)}),o,"get"),set:function(e){t[4](this,e)}}:S[Z]=x,v||a(S[Z],o,2===i?"":Z)):v||(S=Object.getOwnPropertyDescriptor(e,o))}for(var j=w.length-1;j>=0;j-=r?2:1){var A=w[j],T=r?w[j-1]:void 0,I={},N={kind:["field","accessor","method","getter","setter","field","class"][i],name:o,metadata:c,addInitializer:function(e,t){if(e.v)throw new Error("attempted to call addInitializer after decoration was finished");d(t,"An initializer","be",!0),l.push(t)}.bind(null,I)};try{if(E)y=A.call(T,e,N);else{var O,P;N.static=f,N.private=p,p||!v&&2!==i?2===i?O=function(e){return h(e),S.value}:((i<2||3===i)&&(O=u(S,"get",p&&h)),(i<2||4===i)&&(P=u(S,"set",p&&h))):(O=function(e){return e[o]},v&&(P=function(e,t){e[o]=t}));var C=N.access={has:p?g.bind():function(e){return o in e}};if(O&&(C.get=O),P&&(C.set=P),y=A.call(T,m?{get:S.get,set:S.set}:S[Z],N),m){if("object"==(0,n.Z)(y)&&y)(b=d(y.get,"accessor.get"))&&(S.get=b),(b=d(y.set,"accessor.set"))&&(S.set=b),(b=d(y.init,"accessor.init"))&&k.push(b);else if(void 0!==y)throw new TypeError("accessor decorators must return an object with get, set, or init properties or void 0")}else d(y,(v?"field":"method")+" decorators","return")&&(v?k.push(y):S[Z]=y)}}finally{I.v=!0}}return(v||m)&&s.push((function(e,t){for(var r=k.length-1;r>=0;r--)t=k[r].call(e,t);return t})),v||E||(p?m?s.push(u(S,"get"),u(S,"set")):s.push(2===i?S[Z]:u.call.bind(S[Z])):Object.defineProperty(e,o,S)),y}function v(e,t){return Object.defineProperty(e,Symbol.metadata||Symbol.for("Symbol.metadata"),{configurable:!0,enumerable:!0,value:t})}if(arguments.length>=6)var m=s[Symbol.metadata||Symbol.for("Symbol.metadata")];var g=Object.create(null==m?null:m),h=function(e,t,r,n){var a,c,l=[],s=function(t){return(0,o.Z)(t)===e},u=new Map;function d(e){e&&l.push(f.bind(null,e))}for(var v=0;v<t.length;v++){var m=t[v];if(Array.isArray(m)){var g=m[1],h=m[2],b=m.length>3,y=16&g,w=!!(8&g),x=0==(g&=7),E=h+"/"+w;if(!x&&!b){var S=u.get(E);if(!0===S||3===S&&4!==g||4===S&&3!==g)throw new Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: "+h);u.set(E,!(g>2)||g)}p(w?e:e.prototype,m,y,b?"#"+h:(0,i.Z)(h),g,n,w?c=c||[]:a=a||[],l,w,b,x,1===g,w&&b?s:r)}}return d(a),d(c),l}(e,t,l,g);return r.length||v(e,g),{e:h,get c(){var t=[];return r.length&&[v(d(p(e,[r],c,e.name,5,g,t),"class decorators","return")||e,g),f.bind(null,t,e)]}}}},1815:(e,t,r)=>{r.d(t,{Z:()=>o});var n=r(6522);function o(e){if(Object(e)!==e)throw TypeError("right-hand side of 'in' should be an object, got "+(null!==e?(0,n.Z)(e):"null"));return e}},5850:(e,t,r)=>{r.d(t,{Z:()=>o});var n=r(6522);function o(e){var t=function(e,t){if("object"!=(0,n.Z)(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,"string");if("object"!=(0,n.Z)(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==(0,n.Z)(t)?t:String(t)}},6522:(e,t,r)=>{function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}r.d(t,{Z:()=>n})},2890:(e,t,r)=>{r.d(t,{o:()=>n});class n{constructor(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"brick-next-";this.storage=e,this.prefix=t}setItem(e,t){this.storage.setItem(this.prefix+e,JSON.stringify(t))}getItem(e){return JSON.parse(this.storage.getItem(this.prefix+e))}removeItem(e){return this.storage.removeItem(this.prefix+e)}clear(){return this.storage.clear()}}}}]);
|
|
2
|
-
//# sourceMappingURL=easyops-navbar-alerts.9ea93872.js.map
|
|
File without changes
|