Files
weiyu/deploy/server/notebase/assets/components/adaptable-action-card/0.1.7/index.js
2025-02-14 23:56:02 +08:00

1 line
17 KiB
JavaScript

!function (t, n) { "object" == typeof exports && "object" == typeof module ? module.exports = n(require("React"), require("ChatUI")) : "function" == typeof define && define.amd ? define(["React", "ChatUI"], n) : "object" == typeof exports ? exports.AlimeComponentAdaptableActionCard = n(require("React"), require("ChatUI")) : t.AlimeComponentAdaptableActionCard = n(t.React, t.ChatUI) }(window, (function (t, n) { return function (t) { var n = {}; function e(r) { if (n[r]) return n[r].exports; var o = n[r] = { i: r, l: !1, exports: {} }; return t[r].call(o.exports, o, o.exports, e), o.l = !0, o.exports } return e.m = t, e.c = n, e.d = function (t, n, r) { e.o(t, n) || Object.defineProperty(t, n, { enumerable: !0, get: r }) }, e.r = function (t) { "undefined" != typeof Symbol && Symbol.toStringTag && Object.defineProperty(t, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(t, "__esModule", { value: !0 }) }, e.t = function (t, n) { if (1 & n && (t = e(t)), 8 & n) return t; if (4 & n && "object" == typeof t && t && t.__esModule) return t; var r = Object.create(null); if (e.r(r), Object.defineProperty(r, "default", { enumerable: !0, value: t }), 2 & n && "string" != typeof t) for (var o in t) e.d(r, o, function (n) { return t[n] }.bind(null, o)); return r }, e.n = function (t) { var n = t && t.__esModule ? function () { return t.default } : function () { return t }; return e.d(n, "a", n), n }, e.o = function (t, n) { return Object.prototype.hasOwnProperty.call(t, n) }, e.p = "//dev.g.alicdn.com/alime-components/adaptable-action-card/0.1.7/", e(e.s = 19) }([function (n, e) { n.exports = t }, function (t, n, e) { (function (n) { var e = function (t) { return t && t.Math == Math && t }; t.exports = e("object" == typeof globalThis && globalThis) || e("object" == typeof window && window) || e("object" == typeof self && self) || e("object" == typeof n && n) || Function("return this")() }).call(this, e(25)) }, function (t, n) { t.exports = function (t) { try { return !!t() } catch (t) { return !0 } } }, function (t, e) { t.exports = n }, function (t, n, e) { var r = e(2); t.exports = !r((function () { return 7 != Object.defineProperty({}, 1, { get: function () { return 7 } })[1] })) }, function (t, n) { t.exports = function (t) { return "object" == typeof t ? null !== t : "function" == typeof t } }, function (t, n) { var e = {}.hasOwnProperty; t.exports = function (t, n) { return e.call(t, n) } }, function (t, n) { t.exports = {} }, function (t, n) { t.exports = function (t, n) { return { enumerable: !(1 & t), configurable: !(2 & t), writable: !(4 & t), value: n } } }, function (t, n, e) { var r = e(2), o = e(10), i = "".split; t.exports = r((function () { return !Object("z").propertyIsEnumerable(0) })) ? function (t) { return "String" == o(t) ? i.call(t, "") : Object(t) } : Object }, function (t, n) { var e = {}.toString; t.exports = function (t) { return e.call(t).slice(8, -1) } }, function (t, n) { t.exports = function (t) { if (null == t) throw TypeError("Can't call method on " + t); return t } }, function (t, n, e) { var r = e(5); t.exports = function (t, n) { if (!r(t)) return t; var e, o; if (n && "function" == typeof (e = t.toString) && !r(o = e.call(t))) return o; if ("function" == typeof (e = t.valueOf) && !r(o = e.call(t))) return o; if (!n && "function" == typeof (e = t.toString) && !r(o = e.call(t))) return o; throw TypeError("Can't convert object to primitive value") } }, function (t, n, e) { var r = e(4), o = e(2), i = e(29); t.exports = !r && !o((function () { return 7 != Object.defineProperty(i("div"), "a", { get: function () { return 7 } }).a })) }, function (t, n, e) { var r = e(31); t.exports = function (t, n, e) { if (r(t), void 0 === n) return t; switch (e) { case 0: return function () { return t.call(n) }; case 1: return function (e) { return t.call(n, e) }; case 2: return function (e, r) { return t.call(n, e, r) }; case 3: return function (e, r, o) { return t.call(n, e, r, o) } }return function () { return t.apply(n, arguments) } } }, function (t, n, e) { var r = e(4), o = e(32), i = e(8); t.exports = r ? function (t, n, e) { return o.f(t, n, i(1, e)) } : function (t, n, e) { return t[n] = e, t } }, function (t, n, e) { var r = e(1), o = e(40), i = e(6), c = e(44), a = e(17), u = e(45), f = o("wks"), s = r.Symbol, l = u ? s : s && s.withoutSetter || c; t.exports = function (t) { return i(f, t) || (a && i(s, t) ? f[t] = s[t] : f[t] = l("Symbol." + t)), f[t] } }, function (t, n, e) { var r = e(2); t.exports = !!Object.getOwnPropertySymbols && !r((function () { return !String(Symbol()) })) }, function (t, n, e) { t.exports = e(20) }, function (t, n, e) { "use strict"; e.r(n), e.d(n, "default", (function () { return u })); var r = e(18), o = e.n(r), i = e(0), c = e.n(i), a = e(3); e(52); function u(t) { var n = t.data, e = t.ctx, r = t.meta; function u(t, n) { var o, i = t.action, c = t.param; "openWindow" === i ? e.util.openWindow(c.url) : "sendText" === i ? e.postMessage({ type: "text", content: { text: c.text }, context: r.context }) : "telephone" === i ? e.util.openWindow("tel:".concat(c.tel)) : "wangwang" === i && e.JSBridge.openWangxin({ nick: c.nick }), o = { c: "adaptable-action-card", d: "btn", text: t.param.text, position: n }, e.log.click(o, r.logParams) } Object(i.useEffect)((function () { r.history || e.ui.scrollToEnd() }), []); var f = n.picUrl, s = n.title, l = n.content, p = n.actionList, d = n.actionOrientation; return c.a.createElement(a.Card, { className: "AdaptableActionCard", size: "xl", fluid: !0 }, f && c.a.createElement("img", { className: "AdaptableActionCard-img", src: f, onLoad: function () { r.history || e.ui.scrollToEnd() }, alt: "" }), s && c.a.createElement(a.CardTitle, null, s), l && c.a.createElement(a.CardText, null, c.a.createElement(a.RichText, { content: l })), p && "[]" !== p && c.a.createElement(a.CardActions, { direction: "0" === d ? "column" : null }, o()(p).call(p, (function (t, n) { return c.a.createElement(a.Button, { color: "primary" === t.style ? "primary" : null, onClick: function () { return u(t, n) }, key: n }, t.text) })))) } }, function (t, n, e) { var r = e(21); t.exports = r }, function (t, n, e) { var r = e(22), o = Array.prototype; t.exports = function (t) { var n = t.map; return t === o || t instanceof Array && n === o.map ? r : n } }, function (t, n, e) { e(23); var r = e(51); t.exports = r("Array").map }, function (t, n, e) { "use strict"; var r = e(24), o = e(34).map, i = e(46), c = e(50), a = i("map"), u = c("map"); r({ target: "Array", proto: !0, forced: !a || !u }, { map: function (t) { return o(this, t, arguments.length > 1 ? arguments[1] : void 0) } }) }, function (t, n, e) { "use strict"; var r = e(1), o = e(26).f, i = e(30), c = e(7), a = e(14), u = e(15), f = e(6), s = function (t) { var n = function (n, e, r) { if (this instanceof t) { switch (arguments.length) { case 0: return new t; case 1: return new t(n); case 2: return new t(n, e) }return new t(n, e, r) } return t.apply(this, arguments) }; return n.prototype = t.prototype, n }; t.exports = function (t, n) { var e, l, p, d, v, y, m, h, b = t.target, x = t.global, g = t.stat, w = t.proto, A = x ? r : g ? r[b] : (r[b] || {}).prototype, j = x ? c : c[b] || (c[b] = {}), C = j.prototype; for (p in n) e = !i(x ? p : b + (g ? "." : "#") + p, t.forced) && A && f(A, p), v = j[p], e && (y = t.noTargetGet ? (h = o(A, p)) && h.value : A[p]), d = e && y ? y : n[p], e && typeof v == typeof d || (m = t.bind && e ? a(d, r) : t.wrap && e ? s(d) : w && "function" == typeof d ? a(Function.call, d) : d, (t.sham || d && d.sham || v && v.sham) && u(m, "sham", !0), j[p] = m, w && (f(c, l = b + "Prototype") || u(c, l, {}), c[l][p] = d, t.real && C && !C[p] && u(C, p, d))) } }, function (t, n) { var e; e = function () { return this }(); try { e = e || new Function("return this")() } catch (t) { "object" == typeof window && (e = window) } t.exports = e }, function (t, n, e) { var r = e(4), o = e(27), i = e(8), c = e(28), a = e(12), u = e(6), f = e(13), s = Object.getOwnPropertyDescriptor; n.f = r ? s : function (t, n) { if (t = c(t), n = a(n, !0), f) try { return s(t, n) } catch (t) { } if (u(t, n)) return i(!o.f.call(t, n), t[n]) } }, function (t, n, e) { "use strict"; var r = {}.propertyIsEnumerable, o = Object.getOwnPropertyDescriptor, i = o && !r.call({ 1: 2 }, 1); n.f = i ? function (t) { var n = o(this, t); return !!n && n.enumerable } : r }, function (t, n, e) { var r = e(9), o = e(11); t.exports = function (t) { return r(o(t)) } }, function (t, n, e) { var r = e(1), o = e(5), i = r.document, c = o(i) && o(i.createElement); t.exports = function (t) { return c ? i.createElement(t) : {} } }, function (t, n, e) { var r = e(2), o = /#|\.prototype\./, i = function (t, n) { var e = a[c(t)]; return e == f || e != u && ("function" == typeof n ? r(n) : !!n) }, c = i.normalize = function (t) { return String(t).replace(o, ".").toLowerCase() }, a = i.data = {}, u = i.NATIVE = "N", f = i.POLYFILL = "P"; t.exports = i }, function (t, n) { t.exports = function (t) { if ("function" != typeof t) throw TypeError(String(t) + " is not a function"); return t } }, function (t, n, e) { var r = e(4), o = e(13), i = e(33), c = e(12), a = Object.defineProperty; n.f = r ? a : function (t, n, e) { if (i(t), n = c(n, !0), i(e), o) try { return a(t, n, e) } catch (t) { } if ("get" in e || "set" in e) throw TypeError("Accessors not supported"); return "value" in e && (t[n] = e.value), t } }, function (t, n, e) { var r = e(5); t.exports = function (t) { if (!r(t)) throw TypeError(String(t) + " is not an object"); return t } }, function (t, n, e) { var r = e(14), o = e(9), i = e(35), c = e(36), a = e(38), u = [].push, f = function (t) { var n = 1 == t, e = 2 == t, f = 3 == t, s = 4 == t, l = 6 == t, p = 5 == t || l; return function (d, v, y, m) { for (var h, b, x = i(d), g = o(x), w = r(v, y, 3), A = c(g.length), j = 0, C = m || a, S = n ? C(d, A) : e ? C(d, 0) : void 0; A > j; j++)if ((p || j in g) && (b = w(h = g[j], j, x), t)) if (n) S[j] = b; else if (b) switch (t) { case 3: return !0; case 5: return h; case 6: return j; case 2: u.call(S, h) } else if (s) return !1; return l ? -1 : f || s ? s : S } }; t.exports = { forEach: f(0), map: f(1), filter: f(2), some: f(3), every: f(4), find: f(5), findIndex: f(6) } }, function (t, n, e) { var r = e(11); t.exports = function (t) { return Object(r(t)) } }, function (t, n, e) { var r = e(37), o = Math.min; t.exports = function (t) { return t > 0 ? o(r(t), 9007199254740991) : 0 } }, function (t, n) { var e = Math.ceil, r = Math.floor; t.exports = function (t) { return isNaN(t = +t) ? 0 : (t > 0 ? r : e)(t) } }, function (t, n, e) { var r = e(5), o = e(39), i = e(16)("species"); t.exports = function (t, n) { var e; return o(t) && ("function" != typeof (e = t.constructor) || e !== Array && !o(e.prototype) ? r(e) && null === (e = e[i]) && (e = void 0) : e = void 0), new (void 0 === e ? Array : e)(0 === n ? 0 : n) } }, function (t, n, e) { var r = e(10); t.exports = Array.isArray || function (t) { return "Array" == r(t) } }, function (t, n, e) { var r = e(41), o = e(42); (t.exports = function (t, n) { return o[t] || (o[t] = void 0 !== n ? n : {}) })("versions", []).push({ version: "3.6.3", mode: r ? "pure" : "global", copyright: "© 2020 Denis Pushkarev (zloirock.ru)" }) }, function (t, n) { t.exports = !0 }, function (t, n, e) { var r = e(1), o = e(43), i = r["__core-js_shared__"] || o("__core-js_shared__", {}); t.exports = i }, function (t, n, e) { var r = e(1), o = e(15); t.exports = function (t, n) { try { o(r, t, n) } catch (e) { r[t] = n } return n } }, function (t, n) { var e = 0, r = Math.random(); t.exports = function (t) { return "Symbol(" + String(void 0 === t ? "" : t) + ")_" + (++e + r).toString(36) } }, function (t, n, e) { var r = e(17); t.exports = r && !Symbol.sham && "symbol" == typeof Symbol.iterator }, function (t, n, e) { var r = e(2), o = e(16), i = e(47), c = o("species"); t.exports = function (t) { return i >= 51 || !r((function () { var n = []; return (n.constructor = {})[c] = function () { return { foo: 1 } }, 1 !== n[t](Boolean).foo })) } }, function (t, n, e) { var r, o, i = e(1), c = e(48), a = i.process, u = a && a.versions, f = u && u.v8; f ? o = (r = f.split("."))[0] + r[1] : c && (!(r = c.match(/Edge\/(\d+)/)) || r[1] >= 74) && (r = c.match(/Chrome\/(\d+)/)) && (o = r[1]), t.exports = o && +o }, function (t, n, e) { var r = e(49); t.exports = r("navigator", "userAgent") || "" }, function (t, n, e) { var r = e(7), o = e(1), i = function (t) { return "function" == typeof t ? t : void 0 }; t.exports = function (t, n) { return arguments.length < 2 ? i(r[t]) || i(o[t]) : r[t] && r[t][n] || o[t] && o[t][n] } }, function (t, n, e) { var r = e(4), o = e(2), i = e(6), c = Object.defineProperty, a = function (t) { throw t }; t.exports = function (t, n) { n || (n = {}); var e = [][t], u = !!i(n, "ACCESSORS") && n.ACCESSORS, f = i(n, 0) ? n[0] : a, s = i(n, 1) ? n[1] : void 0; return !!e && !o((function () { if (u && !r) return !0; var t = { length: -1 }, n = function (n) { u ? c(t, n, { enumerable: !0, get: a }) : t[n] = 1 }; n(1), n(2147483646), n(4294967294), e.call(t, f, s) })) } }, function (t, n, e) { var r = e(7); t.exports = function (t) { return r[t + "Prototype"] } }, function (t, n, e) { var r = e(53), o = e(54); "string" == typeof (o = o.__esModule ? o.default : o) && (o = [[t.i, o, ""]]); var i = { insert: "head", singleton: !1 }, c = (r(t.i, o, i), o.locals ? o.locals : {}); t.exports = c }, function (t, n, e) { "use strict"; var r, o = function () { return void 0 === r && (r = Boolean(window && document && document.all && !window.atob)), r }, i = function () { var t = {}; return function (n) { if (void 0 === t[n]) { var e = document.querySelector(n); if (window.HTMLIFrameElement && e instanceof window.HTMLIFrameElement) try { e = e.contentDocument.head } catch (t) { e = null } t[n] = e } return t[n] } }(), c = {}; function a(t, n, e) { for (var r = 0; r < n.length; r++) { var o = { css: n[r][1], media: n[r][2], sourceMap: n[r][3] }; c[t][r] ? c[t][r](o) : c[t].push(y(o, e)) } } function u(t) { var n = document.createElement("style"), r = t.attributes || {}; if (void 0 === r.nonce) { var o = e.nc; o && (r.nonce = o) } if (Object.keys(r).forEach((function (t) { n.setAttribute(t, r[t]) })), "function" == typeof t.insert) t.insert(n); else { var c = i(t.insert || "head"); if (!c) throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid."); c.appendChild(n) } return n } var f, s = (f = [], function (t, n) { return f[t] = n, f.filter(Boolean).join("\n") }); function l(t, n, e, r) { var o = e ? "" : r.css; if (t.styleSheet) t.styleSheet.cssText = s(n, o); else { var i = document.createTextNode(o), c = t.childNodes; c[n] && t.removeChild(c[n]), c.length ? t.insertBefore(i, c[n]) : t.appendChild(i) } } function p(t, n, e) { var r = e.css, o = e.media, i = e.sourceMap; if (o ? t.setAttribute("media", o) : t.removeAttribute("media"), i && btoa && (r += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i)))), " */")), t.styleSheet) t.styleSheet.cssText = r; else { for (; t.firstChild;)t.removeChild(t.firstChild); t.appendChild(document.createTextNode(r)) } } var d = null, v = 0; function y(t, n) { var e, r, o; if (n.singleton) { var i = v++; e = d || (d = u(n)), r = l.bind(null, e, i, !1), o = l.bind(null, e, i, !0) } else e = u(n), r = p.bind(null, e, n), o = function () { !function (t) { if (null === t.parentNode) return !1; t.parentNode.removeChild(t) }(e) }; return r(t), function (n) { if (n) { if (n.css === t.css && n.media === t.media && n.sourceMap === t.sourceMap) return; r(t = n) } else o() } } t.exports = function (t, n, e) { return (e = e || {}).singleton || "boolean" == typeof e.singleton || (e.singleton = o()), t = e.base ? t + e.base : t, n = n || [], c[t] || (c[t] = []), a(t, n, e), function (n) { if (n = n || [], "[object Array]" === Object.prototype.toString.call(n)) { c[t] || (c[t] = []), a(t, n, e); for (var r = n.length; r < c[t].length; r++)c[t][r](); c[t].length = n.length, 0 === c[t].length && delete c[t] } } } }, function (t, n, e) { (n = e(55)(!0)).push([t.i, ".AdaptableActionCard-img{display:block;width:100%}", "", { version: 3, sources: ["style.css"], names: [], mappings: "AAAA,yBACE,aAAc,CACd,UACF", file: "style.css", sourcesContent: [".AdaptableActionCard-img {\n display: block;\n width: 100%;\n}\n"] }]), t.exports = n }, function (t, n, e) { "use strict"; t.exports = function (t) { var n = []; return n.toString = function () { return this.map((function (n) { var e = function (t, n) { var e = t[1] || "", r = t[3]; if (!r) return e; if (n && "function" == typeof btoa) { var o = (c = r, a = btoa(unescape(encodeURIComponent(JSON.stringify(c)))), u = "sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a), "/*# ".concat(u, " */")), i = r.sources.map((function (t) { return "/*# sourceURL=".concat(r.sourceRoot || "").concat(t, " */") })); return [e].concat(i).concat([o]).join("\n") } var c, a, u; return [e].join("\n") }(n, t); return n[2] ? "@media ".concat(n[2], " {").concat(e, "}") : e })).join("") }, n.i = function (t, e) { "string" == typeof t && (t = [[null, t, ""]]); for (var r = 0; r < t.length; r++) { var o = [].concat(t[r]); e && (o[2] ? o[2] = "".concat(e, " and ").concat(o[2]) : o[2] = e), n.push(o) } }, n } }]) }));