montana/Russian/Site/messenger/dist/748.48eece6321d4e8e0ac31.js

2 lines
15 KiB
JavaScript
Raw Normal View History

2026-05-18 18:05:32 +03:00
"use strict";(self.webpackChunkmontana_messenger=self.webpackChunkmontana_messenger||[]).push([[748,8925],{8925(e,i,n){n.r(i),n.d(i,{TauriEvent:()=>t,emit:()=>o,emitTo:()=>u,listen:()=>s,once:()=>r});var t,l=n(55962);async function a(e,i){window.__TAURI_EVENT_PLUGIN_INTERNALS__.unregisterListener(e,i),await(0,l.invoke)("plugin:event|unlisten",{event:e,eventId:i})}async function s(e,i,n){var t;const s="string"==typeof(null==n?void 0:n.target)?{kind:"AnyLabel",label:n.target}:null!==(t=null==n?void 0:n.target)&&void 0!==t?t:{kind:"Any"};return(0,l.invoke)("plugin:event|listen",{event:e,target:s,handler:(0,l.transformCallback)(i)}).then(i=>async()=>a(e,i))}async function r(e,i,n){return s(e,n=>{a(e,n.id),i(n)},n)}async function o(e,i){await(0,l.invoke)("plugin:event|emit",{event:e,payload:i})}async function u(e,i,n){const t="string"==typeof e?{kind:"AnyLabel",label:e}:e;await(0,l.invoke)("plugin:event|emit_to",{target:t,event:i,payload:n})}!function(e){e.WINDOW_RESIZED="tauri://resize",e.WINDOW_MOVED="tauri://move",e.WINDOW_CLOSE_REQUESTED="tauri://close-requested",e.WINDOW_DESTROYED="tauri://destroyed",e.WINDOW_FOCUS="tauri://focus",e.WINDOW_BLUR="tauri://blur",e.WINDOW_SCALE_FACTOR_CHANGED="tauri://scale-change",e.WINDOW_THEME_CHANGED="tauri://theme-changed",e.WINDOW_CREATED="tauri://window-created",e.WEBVIEW_CREATED="tauri://webview-created",e.DRAG_ENTER="tauri://drag-enter",e.DRAG_OVER="tauri://drag-over",e.DRAG_DROP="tauri://drag-drop",e.DRAG_LEAVE="tauri://drag-leave"}(t||(t={}))},60748(e,i,n){n.d(i,{getCurrentWindow:()=>v});var t=n(55962);class l{constructor(...e){this.type="Logical",1===e.length?"Logical"in e[0]?(this.width=e[0].Logical.width,this.height=e[0].Logical.height):(this.width=e[0].width,this.height=e[0].height):(this.width=e[0],this.height=e[1])}toPhysical(e){return new a(this.width*e,this.height*e)}[t.SERIALIZE_TO_IPC_FN](){return{width:this.width,height:this.height}}toJSON(){return this[t.SERIALIZE_TO_IPC_FN]()}}class a{constructor(...e){this.type="Physical",1===e.length?"Physical"in e[0]?(this.width=e[0].Physical.width,this.height=e[0].Physical.height):(this.width=e[0].width,this.height=e[0].height):(this.width=e[0],this.height=e[1])}toLogical(e){return new l(this.width/e,this.height/e)}[t.SERIALIZE_TO_IPC_FN](){return{width:this.width,height:this.height}}toJSON(){return this[t.SERIALIZE_TO_IPC_FN]()}}class s{constructor(e){this.size=e}toLogical(e){return this.size instanceof l?this.size:this.size.toLogical(e)}toPhysical(e){return this.size instanceof a?this.size:this.size.toPhysical(e)}[t.SERIALIZE_TO_IPC_FN](){return{[`${this.size.type}`]:{width:this.size.width,height:this.size.height}}}toJSON(){return this[t.SERIALIZE_TO_IPC_FN]()}}class r{constructor(...e){this.type="Logical",1===e.length?"Logical"in e[0]?(this.x=e[0].Logical.x,this.y=e[0].Logical.y):(this.x=e[0].x,this.y=e[0].y):(this.x=e[0],this.y=e[1])}toPhysical(e){return new o(this.x*e,this.y*e)}[t.SERIALIZE_TO_IPC_FN](){return{x:this.x,y:this.y}}toJSON(){return this[t.SERIALIZE_TO_IPC_FN]()}}class o{constructor(...e){this.type="Physical",1===e.length?"Physical"in e[0]?(this.x=e[0].Physical.x,this.y=e[0].Physical.y):(this.x=e[0].x,this.y=e[0].y):(this.x=e[0],this.y=e[1])}toLogical(e){return new r(this.x/e,this.y/e)}[t.SERIALIZE_TO_IPC_FN](){return{x:this.x,y:this.y}}toJSON(){return this[t.SERIALIZE_TO_IPC_FN]()}}class u{constructor(e){this.position=e}toLogical(e){return this.position instanceof r?this.position:this.position.toLogical(e)}toPhysical(e){return this.position instanceof o?this.position:this.position.toPhysical(e)}[t.SERIALIZE_TO_IPC_FN](){return{[`${this.position.type}`]:{x:this.position.x,y:this.position.y}}}toJSON(){return this[t.SERIALIZE_TO_IPC_FN]()}}var c,h,d=n(8925);class w extends t.Resource{constructor(e){super(e)}static async new(e,i,n){return(0,t.invoke)("plugin:image|new",{rgba:b(e),width:i,height:n}).then(e=>new w(e))}static async fromBytes(e){return(0,t.invoke)("plugin:image|from_bytes",{bytes:b(e)}).then(e=>new w(e))}static async fromPath(e){return(0,t.invoke)("plugin:image|from_path",{path:e}).then(e=>new w(e))}asy
//# sourceMappingURL=748.48eece6321d4e8e0ac31.js.map