fix wallpaper defaults

This commit is contained in:
or-else
2026-01-16 11:51:42 +03:00
parent 8c3d273c34
commit 16489432cf
22 changed files with 237 additions and 129 deletions
+9
View File
@@ -816,6 +816,15 @@ div.trusted-badge {
text-decoration: none;
}
.flat-button.disabled,
.flat-button.disabled:hover,
.flat-button.disabled:focus {
color: var(--clr-primary-accent);
cursor: default;
opacity: 0.75;
filter: grayscale(75%);
}
.flat-button.faux {
display: inline-block;
height: 1.4em;
+1 -1
View File
File diff suppressed because one or more lines are too long
+20
View File
@@ -254,3 +254,23 @@ export function defaultWallpaper() {
const wp = wallpaperIndex[WALLPAPER_DEFAULTS.type][WALLPAPER_DEFAULTS.index];
return {name: `../${WALLPAPER_DEFAULTS.path}${wp.name}`, size: wp.size};
}
export function wallpaperNameFromUrl(wallpaperUrl) {
// Get filename from URL.
const parts = wallpaperUrl.split('/');
return parts[parts.length - 1];
}
export function wallpaperTypeFromUrl(wallpaperUrl) {
// Get filename from URL.
const fname = wallpaperNameFromUrl(wallpaperUrl);
const wallpaperIndex = require('../../img/bkg/index.json');
for (const type in wallpaperIndex) {
for (let i = 0; i < wallpaperIndex[type].length; i++) {
if (wallpaperIndex[type][i].name == fname) {
return type;
}
}
}
return null;
}
+3
View File
@@ -254,6 +254,9 @@ class SidepanelView extends React.PureComponent {
<Suspense fallback={<div className="panel-form-row"><FormattedMessage id="loading_note"
defaultMessage="Loading..." description="Message shown when component is loading"/></div>}>
<WallpapersView
wallpaper={this.props.wallpaper}
wallpaperSize={this.props.wallpaperSize}
wallpaperBlur={this.props.wallpaperBlur}
colorSchema={this.props.colorSchema !== 'auto' ? this.props.colorSchema : this.props.systemColorSchema}
onWallpaperSelected={this.props.onWallpaperSelected}
/>
+3
View File
@@ -2179,6 +2179,9 @@ class TinodeWeb extends React.Component {
reqCredMethod={this.state.reqCredMethod}
textSize={this.state.textSize}
colorSchema={this.state.colorSchema}
wallpaper={this.state.wallpaper}
wallpaperSize={this.state.wallpaperSize}
wallpaperBlur={this.state.wallpaperBlur}
systemColorSchema={this.state.systemColorSchema}
sendOnEnter={this.state.sendOnEnter}
+21 -6
View File
@@ -3,17 +3,20 @@ import React from 'react';
import { FormattedMessage } from 'react-intl';
import HashNavigation from '../lib/navigation.js';
import { WALLPAPER_DEFAULTS } from '../config.js';
import { wallpaperNameFromUrl, wallpaperTypeFromUrl } from '../lib/utils.js';
import imageIndex from '../../img/bkg/index.json';
export default class WallpapersView extends React.PureComponent {
constructor(props) {
super(props);
const type = wallpaperTypeFromUrl(this.props.wallpaper);
const name = wallpaperNameFromUrl(this.props.wallpaper);
this.state = {
tab: WALLPAPER_DEFAULTS.type, // currently selected tab: 'patt' | 'img'
selectedType: WALLPAPER_DEFAULTS.type, // type of the selected wallpaper.
wallpaper: imageIndex[WALLPAPER_DEFAULTS.type][WALLPAPER_DEFAULTS.index].name,
blur: 0,
tab: type || WALLPAPER_DEFAULTS.type, // currently selected tab: 'patt' | 'img'
selectedType: type || WALLPAPER_DEFAULTS.type, // type of the selected wallpaper.
wallpaper: name || imageIndex[WALLPAPER_DEFAULTS.type][WALLPAPER_DEFAULTS.index].name,
blur: this.props.wallpaperBlur | 0,
};
this.blurValues = [0, 1, 2, 4, 8, 16];
@@ -21,6 +24,7 @@ export default class WallpapersView extends React.PureComponent {
this.handleTabClick = this.handleTabClick.bind(this);
this.handleWallpaperSelected = this.handleWallpaperSelected.bind(this);
this.handleBlurChanged = this.handleBlurChanged.bind(this);
this.hasChanged = this.hasChanged.bind(this);
}
handleTabClick(e) {
@@ -32,6 +36,10 @@ export default class WallpapersView extends React.PureComponent {
handleWallpaperSelected(e) {
let index, type, blur
if (!e) {
if (!this.hasChanged()) {
return;
}
// Restore default.
type = WALLPAPER_DEFAULTS.type;
index = WALLPAPER_DEFAULTS.index;
@@ -58,11 +66,18 @@ export default class WallpapersView extends React.PureComponent {
}
}
hasChanged() {
return this.state.selectedType != WALLPAPER_DEFAULTS.type ||
this.state.wallpaper != imageIndex[WALLPAPER_DEFAULTS.type][WALLPAPER_DEFAULTS.index].name ||
this.state.blur != 0;
}
render() {
return (
<div className="flex-column">
<div className="panel-form-row clean-clickable">
<a className="flat-button" onClick={() => this.handleWallpaperSelected(null)}>
<div className={`panel-form-row${this.hasChanged() ? ' clean-clickable' : ''}`}>
<a className={`flat-button${this.hasChanged() ? '' : ' disabled'}`}
onClick={() => this.handleWallpaperSelected(null)}>
<i className="material-icons">undo</i>&nbsp;
<FormattedMessage id="button_restore" defaultMessage="Restore default" description="Reset setting to default"/>
</a>
+1 -1
View File
@@ -1,2 +1,2 @@
"use strict";(self.webpackChunktinode_webapp=self.webpackChunktinode_webapp||[]).push([[827],{3827:function(e,t,a){a.r(t),a.d(t,{default:function(){return d}});var l=a(1594),s=a.n(l),r=a(8181),n=a(7151),i=a(9027),c=a(1781);class d extends s().PureComponent{constructor(e){super(e),this.state={tab:i.S.type,selectedType:i.S.type,wallpaper:c[i.S.type][i.S.index].name,blur:0},this.blurValues=[0,1,2,4,8,16],this.handleTabClick=this.handleTabClick.bind(this),this.handleWallpaperSelected=this.handleWallpaperSelected.bind(this),this.handleBlurChanged=this.handleBlurChanged.bind(this)}handleTabClick(e){e.preventDefault(),n.A.navigateTo(n.A.addUrlParam(window.location.hash,"tab",e.currentTarget.dataset.id)),this.setState({tab:e.currentTarget.dataset.id})}handleWallpaperSelected(e){let t,a,l;e?(e.preventDefault(),a=this.state.tab,t=e.currentTarget.dataset.id,l="patt"==a?0:this.state.blur):(a=i.S.type,t=i.S.index,l=0);const s=c[a][t].name,r="patt"==a?c[a][t].size:0;this.setState({tab:a,wallpaper:s,selectedType:a,blur:l}),this.props.onWallpaperSelected(`../${i.S.path}${s}`,r,this.blurValues[l])}handleBlurChanged(e){e.preventDefault();const t=e.currentTarget.value;this.setState({blur:t}),"img"==this.state.selectedType&&this.props.onWallpaperSelected(`../${i.S.path}${this.state.wallpaper}`,0,this.blurValues[t])}render(){return s().createElement("div",{className:"flex-column"},s().createElement("div",{className:"panel-form-row clean-clickable"},s().createElement("a",{className:"flat-button",onClick:()=>this.handleWallpaperSelected(null)},s().createElement("i",{className:"material-icons"},"undo")," ",s().createElement(r.FormattedMessage,{id:"button_restore",defaultMessage:[{type:0,value:"Restore default"}]}))),s().createElement("ul",{className:"tabbar"},s().createElement("li",{className:"patt"===this.state.tab?"active":null},s().createElement("a",{href:"#","data-id":"patt",onClick:this.handleTabClick},s().createElement(r.FormattedMessage,{id:"tabtitle_pattern",defaultMessage:[{type:0,value:"pattern"}]}))),s().createElement("li",{className:"img"===this.state.tab?"active":null},s().createElement("a",{href:"#","data-id":"img",onClick:this.handleTabClick},s().createElement(r.FormattedMessage,{id:"tabtitle_image",defaultMessage:[{type:0,value:"image"}]})))),s().createElement("div",{id:"settings-form",className:"scrollable-panel"},"patt"===this.state.tab?s().createElement("div",{className:"image-grid"},c.patt.map((e,t)=>{const a=this.state.wallpaper===e.name?" selected":"",l="dark"==this.props.colorSchema?"inverted":null;return s().createElement("div",{key:t,"data-id":t,className:`image-grid-cell${a}`,onClick:this.handleWallpaperSelected},s().createElement("img",{src:i.S.path+e.name,alt:e.name,className:l,style:{width:`${e.size}px`,height:`${e.size}px`}}))})):s().createElement(s().Fragment,null,s().createElement("div",{className:"panel-form-column"},s().createElement("div",{className:"panel-form-row"},s().createElement("label",{className:"small"},s().createElement(r.FormattedMessage,{id:"label_blur_wallpaper",defaultMessage:[{type:0,value:"Blur:"}]}))),s().createElement("div",{className:"panel-form-row"},s().createElement("input",{type:"range",id:"blur",name:"blur",min:"0",max:"5",step:"1",value:this.state.blur,onChange:this.handleBlurChanged}))),s().createElement("div",{className:"image-grid"},c.img.map((e,t)=>{const a=this.state.wallpaper===e.name?" selected":"";return s().createElement("div",{key:t,"data-id":t,className:`image-grid-cell${a}`,onClick:this.handleWallpaperSelected},s().createElement("img",{src:i.S.path+e.pr,alt:e.name,style:{width:"100%",height:"100%"}}))})))))}}}}]);
"use strict";(self.webpackChunktinode_webapp=self.webpackChunktinode_webapp||[]).push([[827],{3827:function(e,t,a){a.r(t),a.d(t,{default:function(){return p}});var l=a(1594),s=a.n(l),r=a(8181),n=a(7151),i=a(9027),d=a(3540),c=a(1781);class p extends s().PureComponent{constructor(e){super(e);const t=(0,d.MC)(this.props.wallpaper),a=(0,d.t7)(this.props.wallpaper);this.state={tab:t||i.S.type,selectedType:t||i.S.type,wallpaper:a||c[i.S.type][i.S.index].name,blur:0|this.props.wallpaperBlur},this.blurValues=[0,1,2,4,8,16],this.handleTabClick=this.handleTabClick.bind(this),this.handleWallpaperSelected=this.handleWallpaperSelected.bind(this),this.handleBlurChanged=this.handleBlurChanged.bind(this),this.hasChanged=this.hasChanged.bind(this)}handleTabClick(e){e.preventDefault(),n.A.navigateTo(n.A.addUrlParam(window.location.hash,"tab",e.currentTarget.dataset.id)),this.setState({tab:e.currentTarget.dataset.id})}handleWallpaperSelected(e){let t,a,l;if(e)e.preventDefault(),a=this.state.tab,t=e.currentTarget.dataset.id,l="patt"==a?0:this.state.blur;else{if(!this.hasChanged())return;a=i.S.type,t=i.S.index,l=0}const s=c[a][t].name,r="patt"==a?c[a][t].size:0;this.setState({tab:a,wallpaper:s,selectedType:a,blur:l}),this.props.onWallpaperSelected(`../${i.S.path}${s}`,r,this.blurValues[l])}handleBlurChanged(e){e.preventDefault();const t=e.currentTarget.value;this.setState({blur:t}),"img"==this.state.selectedType&&this.props.onWallpaperSelected(`../${i.S.path}${this.state.wallpaper}`,0,this.blurValues[t])}hasChanged(){return this.state.selectedType!=i.S.type||this.state.wallpaper!=c[i.S.type][i.S.index].name||0!=this.state.blur}render(){return s().createElement("div",{className:"flex-column"},s().createElement("div",{className:"panel-form-row"+(this.hasChanged()?" clean-clickable":"")},s().createElement("a",{className:"flat-button"+(this.hasChanged()?"":" disabled"),onClick:()=>this.handleWallpaperSelected(null)},s().createElement("i",{className:"material-icons"},"undo")," ",s().createElement(r.FormattedMessage,{id:"button_restore",defaultMessage:[{type:0,value:"Restore default"}]}))),s().createElement("ul",{className:"tabbar"},s().createElement("li",{className:"patt"===this.state.tab?"active":null},s().createElement("a",{href:"#","data-id":"patt",onClick:this.handleTabClick},s().createElement(r.FormattedMessage,{id:"tabtitle_pattern",defaultMessage:[{type:0,value:"pattern"}]}))),s().createElement("li",{className:"img"===this.state.tab?"active":null},s().createElement("a",{href:"#","data-id":"img",onClick:this.handleTabClick},s().createElement(r.FormattedMessage,{id:"tabtitle_image",defaultMessage:[{type:0,value:"image"}]})))),s().createElement("div",{id:"settings-form",className:"scrollable-panel"},"patt"===this.state.tab?s().createElement("div",{className:"image-grid"},c.patt.map((e,t)=>{const a=this.state.wallpaper===e.name?" selected":"",l="dark"==this.props.colorSchema?"inverted":null;return s().createElement("div",{key:t,"data-id":t,className:`image-grid-cell${a}`,onClick:this.handleWallpaperSelected},s().createElement("img",{src:i.S.path+e.name,alt:e.name,className:l,style:{width:`${e.size}px`,height:`${e.size}px`}}))})):s().createElement(s().Fragment,null,s().createElement("div",{className:"panel-form-column"},s().createElement("div",{className:"panel-form-row"},s().createElement("label",{className:"small"},s().createElement(r.FormattedMessage,{id:"label_blur_wallpaper",defaultMessage:[{type:0,value:"Blur:"}]}))),s().createElement("div",{className:"panel-form-row"},s().createElement("input",{type:"range",id:"blur",name:"blur",min:"0",max:"5",step:"1",value:this.state.blur,onChange:this.handleBlurChanged}))),s().createElement("div",{className:"image-grid"},c.img.map((e,t)=>{const a=this.state.wallpaper===e.name?" selected":"";return s().createElement("div",{key:t,"data-id":t,className:`image-grid-cell${a}`,onClick:this.handleWallpaperSelected},s().createElement("img",{src:i.S.path+e.pr,alt:e.name,style:{width:"100%",height:"100%"}}))})))))}}}}]);
//# sourceMappingURL=827.prod.js.map
+1 -1
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
File diff suppressed because one or more lines are too long
+31 -1
View File
@@ -8486,7 +8486,9 @@ __webpack_require__.r(__webpack_exports__);
/* harmony export */ sanitizeUrlForMime: function() { return /* binding */ sanitizeUrlForMime; },
/* harmony export */ theCard: function() { return /* binding */ theCard; },
/* harmony export */ updateFavicon: function() { return /* binding */ updateFavicon; },
/* harmony export */ urlAsAttachment: function() { return /* binding */ urlAsAttachment; }
/* harmony export */ urlAsAttachment: function() { return /* binding */ urlAsAttachment; },
/* harmony export */ wallpaperNameFromUrl: function() { return /* binding */ wallpaperNameFromUrl; },
/* harmony export */ wallpaperTypeFromUrl: function() { return /* binding */ wallpaperTypeFromUrl; }
/* harmony export */ });
/* harmony import */ var tinode_sdk__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tinode-sdk */ "tinode-sdk");
/* harmony import */ var tinode_sdk__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(tinode_sdk__WEBPACK_IMPORTED_MODULE_0__);
@@ -8682,6 +8684,22 @@ function defaultWallpaper() {
size: wp.size
};
}
function wallpaperNameFromUrl(wallpaperUrl) {
const parts = wallpaperUrl.split('/');
return parts[parts.length - 1];
}
function wallpaperTypeFromUrl(wallpaperUrl) {
const fname = wallpaperNameFromUrl(wallpaperUrl);
const wallpaperIndex = __webpack_require__(/*! ../../img/bkg/index.json */ "./img/bkg/index.json");
for (const type in wallpaperIndex) {
for (let i = 0; i < wallpaperIndex[type].length; i++) {
if (wallpaperIndex[type][i].name == fname) {
return type;
}
}
}
return null;
}
/***/ }),
@@ -11967,6 +11985,9 @@ class SidepanelView extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureCo
}]
}))
}, react__WEBPACK_IMPORTED_MODULE_0___default().createElement(WallpapersView, {
wallpaper: this.props.wallpaper,
wallpaperSize: this.props.wallpaperSize,
wallpaperBlur: this.props.wallpaperBlur,
colorSchema: this.props.colorSchema !== 'auto' ? this.props.colorSchema : this.props.systemColorSchema,
onWallpaperSelected: this.props.onWallpaperSelected
})) : view === 'contacts' || view == 'archive' || view == 'blocked' ? react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_contacts_view_jsx__WEBPACK_IMPORTED_MODULE_6__["default"], {
@@ -14000,6 +14021,9 @@ class TinodeWeb extends (react__WEBPACK_IMPORTED_MODULE_0___default().Component)
reqCredMethod: this.state.reqCredMethod,
textSize: this.state.textSize,
colorSchema: this.state.colorSchema,
wallpaper: this.state.wallpaper,
wallpaperSize: this.state.wallpaperSize,
wallpaperBlur: this.state.wallpaperBlur,
systemColorSchema: this.state.systemColorSchema,
sendOnEnter: this.state.sendOnEnter,
onGlobalSettings: this.handleGlobalSettings,
@@ -21239,6 +21263,12 @@ module.exports = tinode;
/******/ if (cachedModule !== undefined) {
/******/ return cachedModule.exports;
/******/ }
/******/ // Check if module exists (development only)
/******/ if (__webpack_modules__[moduleId] === undefined) {
/******/ var e = new Error("Cannot find module '" + moduleId + "'");
/******/ e.code = 'MODULE_NOT_FOUND';
/******/ throw e;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = __webpack_module_cache__[moduleId] = {
/******/ // no module.id needed
+1 -1
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+22 -11
View File
@@ -17,7 +17,9 @@ __webpack_require__.r(__webpack_exports__);
/* harmony import */ var react_intl__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react_intl__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _lib_navigation_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../lib/navigation.js */ "./src/lib/navigation.js");
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../config.js */ "./src/config.js");
/* harmony import */ var _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../img/bkg/index.json */ "./img/bkg/index.json");
/* harmony import */ var _lib_utils_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../lib/utils.js */ "./src/lib/utils.js");
/* harmony import */ var _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../img/bkg/index.json */ "./img/bkg/index.json");
@@ -26,16 +28,19 @@ __webpack_require__.r(__webpack_exports__);
class WallpapersView extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureComponent) {
constructor(props) {
super(props);
const type = (0,_lib_utils_js__WEBPACK_IMPORTED_MODULE_4__.wallpaperTypeFromUrl)(this.props.wallpaper);
const name = (0,_lib_utils_js__WEBPACK_IMPORTED_MODULE_4__.wallpaperNameFromUrl)(this.props.wallpaper);
this.state = {
tab: _config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type,
selectedType: _config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type,
wallpaper: _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_4__[_config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type][_config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.index].name,
blur: 0
tab: type || _config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type,
selectedType: type || _config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type,
wallpaper: name || _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_5__[_config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type][_config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.index].name,
blur: this.props.wallpaperBlur | 0
};
this.blurValues = [0, 1, 2, 4, 8, 16];
this.handleTabClick = this.handleTabClick.bind(this);
this.handleWallpaperSelected = this.handleWallpaperSelected.bind(this);
this.handleBlurChanged = this.handleBlurChanged.bind(this);
this.hasChanged = this.hasChanged.bind(this);
}
handleTabClick(e) {
e.preventDefault();
@@ -47,6 +52,9 @@ class WallpapersView extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureC
handleWallpaperSelected(e) {
let index, type, blur;
if (!e) {
if (!this.hasChanged()) {
return;
}
type = _config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type;
index = _config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.index;
blur = 0;
@@ -56,8 +64,8 @@ class WallpapersView extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureC
index = e.currentTarget.dataset.id;
blur = type == 'patt' ? 0 : this.state.blur;
}
const fname = _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_4__[type][index].name;
const size = type == 'patt' ? _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_4__[type][index].size : 0;
const fname = _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_5__[type][index].name;
const size = type == 'patt' ? _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_5__[type][index].size : 0;
this.setState({
tab: type,
wallpaper: fname,
@@ -76,13 +84,16 @@ class WallpapersView extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureC
this.props.onWallpaperSelected(`../${_config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.path}${this.state.wallpaper}`, 0, this.blurValues[blur]);
}
}
hasChanged() {
return this.state.selectedType != _config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type || this.state.wallpaper != _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_5__[_config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.type][_config_js__WEBPACK_IMPORTED_MODULE_3__.WALLPAPER_DEFAULTS.index].name || this.state.blur != 0;
}
render() {
return react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
className: "flex-column"
}, react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
className: "panel-form-row clean-clickable"
className: `panel-form-row${this.hasChanged() ? ' clean-clickable' : ''}`
}, react__WEBPACK_IMPORTED_MODULE_0___default().createElement("a", {
className: "flat-button",
className: `flat-button${this.hasChanged() ? '' : ' disabled'}`,
onClick: () => this.handleWallpaperSelected(null)
}, react__WEBPACK_IMPORTED_MODULE_0___default().createElement("i", {
className: "material-icons"
@@ -123,7 +134,7 @@ class WallpapersView extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureC
className: "scrollable-panel"
}, this.state.tab === 'patt' ? react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
className: "image-grid"
}, _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_4__.patt.map((img, idx) => {
}, _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_5__.patt.map((img, idx) => {
const selected = this.state.wallpaper === img.name ? ' selected' : '';
const dark = this.props.colorSchema == 'dark' ? 'inverted' : null;
return react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
@@ -165,7 +176,7 @@ class WallpapersView extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureC
onChange: this.handleBlurChanged
}))), react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
className: "image-grid"
}, _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_4__.img.map((img, idx) => {
}, _img_bkg_index_json__WEBPACK_IMPORTED_MODULE_5__.img.map((img, idx) => {
const selected = this.state.wallpaper === img.name ? ' selected' : '';
return react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
key: idx,
File diff suppressed because one or more lines are too long
+114 -97
View File
@@ -7,8 +7,8 @@
exports["tinode"] = factory();
else
root["tinode"] = factory();
})(this, () => {
return /******/ (() => { // webpackBootstrap
})(this, function() {
return /******/ (function() { // webpackBootstrap
/******/ "use strict";
/******/ var __webpack_modules__ = ({
@@ -16,11 +16,11 @@ return /******/ (() => { // webpackBootstrap
/*!****************************!*\
!*** ./src/access-mode.js ***!
\****************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ AccessMode)
/* harmony export */ "default": function() { return /* binding */ AccessMode; }
/* harmony export */ });
class AccessMode {
@@ -227,11 +227,11 @@ AccessMode._INVALID = 0x100000;
/*!************************!*\
!*** ./src/cbuffer.js ***!
\************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ CBuffer)
/* harmony export */ "default": function() { return /* binding */ CBuffer; }
/* harmony export */ });
class CBuffer {
@@ -351,11 +351,11 @@ class CBuffer {
/*!***************************!*\
!*** ./src/comm-error.js ***!
\***************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ CommError)
/* harmony export */ "default": function() { return /* binding */ CommError; }
/* harmony export */ });
@@ -373,45 +373,45 @@ class CommError extends Error {
/*!***********************!*\
!*** ./src/config.js ***!
\***********************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ BACKOFF_BASE: () => (/* binding */ BACKOFF_BASE),
/* harmony export */ BACKOFF_JITTER: () => (/* binding */ BACKOFF_JITTER),
/* harmony export */ BACKOFF_MAX_ITER: () => (/* binding */ BACKOFF_MAX_ITER),
/* harmony export */ DEFAULT_MESSAGES_PAGE: () => (/* binding */ DEFAULT_MESSAGES_PAGE),
/* harmony export */ DEL_CHAR: () => (/* binding */ DEL_CHAR),
/* harmony export */ EXPIRE_PROMISES_PERIOD: () => (/* binding */ EXPIRE_PROMISES_PERIOD),
/* harmony export */ EXPIRE_PROMISES_TIMEOUT: () => (/* binding */ EXPIRE_PROMISES_TIMEOUT),
/* harmony export */ LIBRARY: () => (/* binding */ LIBRARY),
/* harmony export */ LOCAL_SEQID: () => (/* binding */ LOCAL_SEQID),
/* harmony export */ MAX_PINNED_COUNT: () => (/* binding */ MAX_PINNED_COUNT),
/* harmony export */ MESSAGE_STATUS_FAILED: () => (/* binding */ MESSAGE_STATUS_FAILED),
/* harmony export */ MESSAGE_STATUS_FATAL: () => (/* binding */ MESSAGE_STATUS_FATAL),
/* harmony export */ MESSAGE_STATUS_NONE: () => (/* binding */ MESSAGE_STATUS_NONE),
/* harmony export */ MESSAGE_STATUS_QUEUED: () => (/* binding */ MESSAGE_STATUS_QUEUED),
/* harmony export */ MESSAGE_STATUS_READ: () => (/* binding */ MESSAGE_STATUS_READ),
/* harmony export */ MESSAGE_STATUS_RECEIVED: () => (/* binding */ MESSAGE_STATUS_RECEIVED),
/* harmony export */ MESSAGE_STATUS_SENDING: () => (/* binding */ MESSAGE_STATUS_SENDING),
/* harmony export */ MESSAGE_STATUS_SENT: () => (/* binding */ MESSAGE_STATUS_SENT),
/* harmony export */ MESSAGE_STATUS_TO_ME: () => (/* binding */ MESSAGE_STATUS_TO_ME),
/* harmony export */ PROTOCOL_VERSION: () => (/* binding */ PROTOCOL_VERSION),
/* harmony export */ RECV_TIMEOUT: () => (/* binding */ RECV_TIMEOUT),
/* harmony export */ TAG_ALIAS: () => (/* binding */ TAG_ALIAS),
/* harmony export */ TAG_EMAIL: () => (/* binding */ TAG_EMAIL),
/* harmony export */ TAG_PHONE: () => (/* binding */ TAG_PHONE),
/* harmony export */ TOPIC_CHAN: () => (/* binding */ TOPIC_CHAN),
/* harmony export */ TOPIC_FND: () => (/* binding */ TOPIC_FND),
/* harmony export */ TOPIC_GRP: () => (/* binding */ TOPIC_GRP),
/* harmony export */ TOPIC_ME: () => (/* binding */ TOPIC_ME),
/* harmony export */ TOPIC_NEW: () => (/* binding */ TOPIC_NEW),
/* harmony export */ TOPIC_NEW_CHAN: () => (/* binding */ TOPIC_NEW_CHAN),
/* harmony export */ TOPIC_P2P: () => (/* binding */ TOPIC_P2P),
/* harmony export */ TOPIC_SLF: () => (/* binding */ TOPIC_SLF),
/* harmony export */ TOPIC_SYS: () => (/* binding */ TOPIC_SYS),
/* harmony export */ USER_NEW: () => (/* binding */ USER_NEW),
/* harmony export */ VERSION: () => (/* binding */ VERSION)
/* harmony export */ BACKOFF_BASE: function() { return /* binding */ BACKOFF_BASE; },
/* harmony export */ BACKOFF_JITTER: function() { return /* binding */ BACKOFF_JITTER; },
/* harmony export */ BACKOFF_MAX_ITER: function() { return /* binding */ BACKOFF_MAX_ITER; },
/* harmony export */ DEFAULT_MESSAGES_PAGE: function() { return /* binding */ DEFAULT_MESSAGES_PAGE; },
/* harmony export */ DEL_CHAR: function() { return /* binding */ DEL_CHAR; },
/* harmony export */ EXPIRE_PROMISES_PERIOD: function() { return /* binding */ EXPIRE_PROMISES_PERIOD; },
/* harmony export */ EXPIRE_PROMISES_TIMEOUT: function() { return /* binding */ EXPIRE_PROMISES_TIMEOUT; },
/* harmony export */ LIBRARY: function() { return /* binding */ LIBRARY; },
/* harmony export */ LOCAL_SEQID: function() { return /* binding */ LOCAL_SEQID; },
/* harmony export */ MAX_PINNED_COUNT: function() { return /* binding */ MAX_PINNED_COUNT; },
/* harmony export */ MESSAGE_STATUS_FAILED: function() { return /* binding */ MESSAGE_STATUS_FAILED; },
/* harmony export */ MESSAGE_STATUS_FATAL: function() { return /* binding */ MESSAGE_STATUS_FATAL; },
/* harmony export */ MESSAGE_STATUS_NONE: function() { return /* binding */ MESSAGE_STATUS_NONE; },
/* harmony export */ MESSAGE_STATUS_QUEUED: function() { return /* binding */ MESSAGE_STATUS_QUEUED; },
/* harmony export */ MESSAGE_STATUS_READ: function() { return /* binding */ MESSAGE_STATUS_READ; },
/* harmony export */ MESSAGE_STATUS_RECEIVED: function() { return /* binding */ MESSAGE_STATUS_RECEIVED; },
/* harmony export */ MESSAGE_STATUS_SENDING: function() { return /* binding */ MESSAGE_STATUS_SENDING; },
/* harmony export */ MESSAGE_STATUS_SENT: function() { return /* binding */ MESSAGE_STATUS_SENT; },
/* harmony export */ MESSAGE_STATUS_TO_ME: function() { return /* binding */ MESSAGE_STATUS_TO_ME; },
/* harmony export */ PROTOCOL_VERSION: function() { return /* binding */ PROTOCOL_VERSION; },
/* harmony export */ RECV_TIMEOUT: function() { return /* binding */ RECV_TIMEOUT; },
/* harmony export */ TAG_ALIAS: function() { return /* binding */ TAG_ALIAS; },
/* harmony export */ TAG_EMAIL: function() { return /* binding */ TAG_EMAIL; },
/* harmony export */ TAG_PHONE: function() { return /* binding */ TAG_PHONE; },
/* harmony export */ TOPIC_CHAN: function() { return /* binding */ TOPIC_CHAN; },
/* harmony export */ TOPIC_FND: function() { return /* binding */ TOPIC_FND; },
/* harmony export */ TOPIC_GRP: function() { return /* binding */ TOPIC_GRP; },
/* harmony export */ TOPIC_ME: function() { return /* binding */ TOPIC_ME; },
/* harmony export */ TOPIC_NEW: function() { return /* binding */ TOPIC_NEW; },
/* harmony export */ TOPIC_NEW_CHAN: function() { return /* binding */ TOPIC_NEW_CHAN; },
/* harmony export */ TOPIC_P2P: function() { return /* binding */ TOPIC_P2P; },
/* harmony export */ TOPIC_SLF: function() { return /* binding */ TOPIC_SLF; },
/* harmony export */ TOPIC_SYS: function() { return /* binding */ TOPIC_SYS; },
/* harmony export */ USER_NEW: function() { return /* binding */ USER_NEW; },
/* harmony export */ VERSION: function() { return /* binding */ VERSION; }
/* harmony export */ });
/* harmony import */ var _version_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../version.js */ "./version.js");
@@ -459,11 +459,11 @@ const BACKOFF_JITTER = 0.3;
/*!***************************!*\
!*** ./src/connection.js ***!
\***************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ Connection)
/* harmony export */ "default": function() { return /* binding */ Connection; }
/* harmony export */ });
/* harmony import */ var _comm_error_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./comm-error.js */ "./src/comm-error.js");
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./config.js */ "./src/config.js");
@@ -789,11 +789,11 @@ Connection.NETWORK_USER_TEXT = NETWORK_USER_TEXT;
/*!*******************!*\
!*** ./src/db.js ***!
\*******************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ DB)
/* harmony export */ "default": function() { return /* binding */ DB; }
/* harmony export */ });
const DB_VERSION = 3;
@@ -1397,7 +1397,7 @@ class DB {
/*!***********************!*\
!*** ./src/drafty.js ***!
\***********************/
/***/ ((module) => {
/***/ (function(module) {
/**
* @copyright 2015-2024 Tinode LLC.
@@ -3159,11 +3159,11 @@ if (true) {
/*!**************************!*\
!*** ./src/fnd-topic.js ***!
\**************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ TopicFnd)
/* harmony export */ "default": function() { return /* binding */ TopicFnd; }
/* harmony export */ });
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./config.js */ "./src/config.js");
/* harmony import */ var _topic_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./topic.js */ "./src/topic.js");
@@ -3240,11 +3240,11 @@ class TopicFnd extends _topic_js__WEBPACK_IMPORTED_MODULE_1__["default"] {
/*!***************************!*\
!*** ./src/large-file.js ***!
\***************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ LargeFileHelper)
/* harmony export */ "default": function() { return /* binding */ LargeFileHelper; }
/* harmony export */ });
/* harmony import */ var _comm_error_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./comm-error.js */ "./src/comm-error.js");
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./utils.js */ "./src/utils.js");
@@ -3476,11 +3476,11 @@ class LargeFileHelper {
/*!*************************!*\
!*** ./src/me-topic.js ***!
\*************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ TopicMe)
/* harmony export */ "default": function() { return /* binding */ TopicMe; }
/* harmony export */ });
/* harmony import */ var _access_mode_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./access-mode.js */ "./src/access-mode.js");
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./config.js */ "./src/config.js");
@@ -3798,11 +3798,11 @@ class TopicMe extends _topic_js__WEBPACK_IMPORTED_MODULE_2__["default"] {
/*!*****************************!*\
!*** ./src/meta-builder.js ***!
\*****************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ MetaGetBuilder)
/* harmony export */ "default": function() { return /* binding */ MetaGetBuilder; }
/* harmony export */ });
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./utils */ "./src/utils.js");
@@ -3934,11 +3934,11 @@ class MetaGetBuilder {
/*!**********************!*\
!*** ./src/topic.js ***!
\**********************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": () => (/* binding */ Topic)
/* harmony export */ "default": function() { return /* binding */ Topic; }
/* harmony export */ });
/* harmony import */ var _access_mode_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./access-mode.js */ "./src/access-mode.js");
/* harmony import */ var _cbuffer_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./cbuffer.js */ "./src/cbuffer.js");
@@ -5201,21 +5201,21 @@ class Topic {
/*!**********************!*\
!*** ./src/utils.js ***!
\**********************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ clipInRange: () => (/* binding */ clipInRange),
/* harmony export */ clipOutRange: () => (/* binding */ clipOutRange),
/* harmony export */ isUrlRelative: () => (/* binding */ isUrlRelative),
/* harmony export */ jsonParseHelper: () => (/* binding */ jsonParseHelper),
/* harmony export */ listToRanges: () => (/* binding */ listToRanges),
/* harmony export */ mergeObj: () => (/* binding */ mergeObj),
/* harmony export */ mergeToCache: () => (/* binding */ mergeToCache),
/* harmony export */ normalizeArray: () => (/* binding */ normalizeArray),
/* harmony export */ normalizeRanges: () => (/* binding */ normalizeRanges),
/* harmony export */ rfc3339DateString: () => (/* binding */ rfc3339DateString),
/* harmony export */ simplify: () => (/* binding */ simplify)
/* harmony export */ clipInRange: function() { return /* binding */ clipInRange; },
/* harmony export */ clipOutRange: function() { return /* binding */ clipOutRange; },
/* harmony export */ isUrlRelative: function() { return /* binding */ isUrlRelative; },
/* harmony export */ jsonParseHelper: function() { return /* binding */ jsonParseHelper; },
/* harmony export */ listToRanges: function() { return /* binding */ listToRanges; },
/* harmony export */ mergeObj: function() { return /* binding */ mergeObj; },
/* harmony export */ mergeToCache: function() { return /* binding */ mergeToCache; },
/* harmony export */ normalizeArray: function() { return /* binding */ normalizeArray; },
/* harmony export */ normalizeRanges: function() { return /* binding */ normalizeRanges; },
/* harmony export */ rfc3339DateString: function() { return /* binding */ rfc3339DateString; },
/* harmony export */ simplify: function() { return /* binding */ simplify; }
/* harmony export */ });
/* harmony import */ var _access_mode_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./access-mode.js */ "./src/access-mode.js");
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./config.js */ "./src/config.js");
@@ -5443,13 +5443,13 @@ function clipInRange(src, clip) {
/*!********************!*\
!*** ./version.js ***!
\********************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ PACKAGE_VERSION: () => (/* binding */ PACKAGE_VERSION)
/* harmony export */ PACKAGE_VERSION: function() { return /* binding */ PACKAGE_VERSION; }
/* harmony export */ });
const PACKAGE_VERSION = "0.25.0";
const PACKAGE_VERSION = "0.25.1";
/***/ })
@@ -5465,6 +5465,12 @@ const PACKAGE_VERSION = "0.25.0";
/******/ if (cachedModule !== undefined) {
/******/ return cachedModule.exports;
/******/ }
/******/ // Check if module exists (development only)
/******/ if (__webpack_modules__[moduleId] === undefined) {
/******/ var e = new Error("Cannot find module '" + moduleId + "'");
/******/ e.code = 'MODULE_NOT_FOUND';
/******/ throw e;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = __webpack_module_cache__[moduleId] = {
/******/ // no module.id needed
@@ -5481,57 +5487,69 @@ const PACKAGE_VERSION = "0.25.0";
/******/
/************************************************************************/
/******/ /* webpack/runtime/compat get default export */
/******/ (() => {
/******/ !function() {
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __webpack_require__.n = (module) => {
/******/ __webpack_require__.n = function(module) {
/******/ var getter = module && module.__esModule ?
/******/ () => (module['default']) :
/******/ () => (module);
/******/ function() { return module['default']; } :
/******/ function() { return module; };
/******/ __webpack_require__.d(getter, { a: getter });
/******/ return getter;
/******/ };
/******/ })();
/******/ }();
/******/
/******/ /* webpack/runtime/define property getters */
/******/ (() => {
/******/ !function() {
/******/ // define getter functions for harmony exports
/******/ __webpack_require__.d = (exports, definition) => {
/******/ __webpack_require__.d = function(exports, definition) {
/******/ for(var key in definition) {
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
/******/ }
/******/ }
/******/ };
/******/ })();
/******/ }();
/******/
/******/ /* webpack/runtime/global */
/******/ !function() {
/******/ __webpack_require__.g = (function() {
/******/ if (typeof globalThis === 'object') return globalThis;
/******/ try {
/******/ return this || new Function('return this')();
/******/ } catch (e) {
/******/ if (typeof window === 'object') return window;
/******/ }
/******/ })();
/******/ }();
/******/
/******/ /* webpack/runtime/hasOwnProperty shorthand */
/******/ (() => {
/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
/******/ })();
/******/ !function() {
/******/ __webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }
/******/ }();
/******/
/******/ /* webpack/runtime/make namespace object */
/******/ (() => {
/******/ !function() {
/******/ // define __esModule on exports
/******/ __webpack_require__.r = (exports) => {
/******/ __webpack_require__.r = function(exports) {
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ }
/******/ Object.defineProperty(exports, '__esModule', { value: true });
/******/ };
/******/ })();
/******/ }();
/******/
/************************************************************************/
var __webpack_exports__ = {};
// This entry needs to be wrapped in an IIFE because it needs to be isolated against other modules in the chunk.
(() => {
!function() {
/*!***********************!*\
!*** ./src/tinode.js ***!
\***********************/
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ AccessMode: () => (/* reexport safe */ _access_mode_js__WEBPACK_IMPORTED_MODULE_0__["default"]),
/* harmony export */ Drafty: () => (/* reexport default from dynamic */ _drafty_js__WEBPACK_IMPORTED_MODULE_5___default.a),
/* harmony export */ Tinode: () => (/* binding */ Tinode)
/* harmony export */ AccessMode: function() { return /* reexport safe */ _access_mode_js__WEBPACK_IMPORTED_MODULE_0__["default"]; },
/* harmony export */ Drafty: function() { return /* reexport default from dynamic */ _drafty_js__WEBPACK_IMPORTED_MODULE_5___default.a; },
/* harmony export */ Tinode: function() { return /* binding */ Tinode; }
/* harmony export */ });
/* harmony import */ var _access_mode_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./access-mode.js */ "./src/access-mode.js");
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./config.js */ "./src/config.js");
@@ -5621,7 +5639,7 @@ initForNonBrowserApp();
function initForNonBrowserApp() {
const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';
if (typeof btoa == 'undefined') {
globalThis.btoa = function (input = '') {
__webpack_require__.g.btoa = function (input = '') {
let str = input;
let output = '';
for (let block = 0, charCode, i = 0, map = chars; str.charAt(i | 0) || (map = '=', i % 1); output += map.charAt(63 & block >> 8 - i % 1 * 8)) {
@@ -5635,7 +5653,7 @@ function initForNonBrowserApp() {
};
}
if (typeof atob == 'undefined') {
globalThis.atob = function (input = '') {
__webpack_require__.g.atob = function (input = '') {
let str = input.replace(/=+$/, '');
let output = '';
if (str.length % 4 == 1) {
@@ -5648,7 +5666,7 @@ function initForNonBrowserApp() {
};
}
if (typeof window == 'undefined') {
globalThis.window = {
__webpack_require__.g.window = {
WebSocket: WebSocketProvider,
XMLHttpRequest: XHRProvider,
indexedDB: IndexedDBProvider,
@@ -6830,8 +6848,7 @@ Tinode.URI_TOPIC_ID_PREFIX = 'tinode:topic/';
Tinode.TAG_ALIAS = _config_js__WEBPACK_IMPORTED_MODULE_1__.TAG_ALIAS;
Tinode.TAG_EMAIL = _config_js__WEBPACK_IMPORTED_MODULE_1__.TAG_EMAIL;
Tinode.TAG_PHONE = _config_js__WEBPACK_IMPORTED_MODULE_1__.TAG_PHONE;
})();
}();
/******/ return __webpack_exports__;
/******/ })()
;
File diff suppressed because one or more lines are too long
+1 -1
View File
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long