I hereby claim:
- I am sominemo on github.
- I am sominemo (https://keybase.io/sominemo) on keybase.
- I have a public key ASDVhrl53oijcLlNBZ9U4GUduo0BD4Z2HsT_gXOpdLt5HQo
To claim this, I am signing this object:
onword = { | |
reg: {}, | |
debug: false, | |
set: (a, c, s) => { | |
if (!s) a = a.toLowerCase(); | |
document.addEventListener("keypress", (b) => { | |
onword.listen(a, b, c, s); | |
}); |
onword={reg:{},set:(d,e,f)=>{f||(d=d.toLowerCase()),document.addEventListener("keypress",g=>{onword.listen(d,g,e,f)}),onword.reg[d]=0},listen:(d,e,f,g)=>{if(!g)var h=e.key.toLowerCase();else var h=e.key;if(d[onword.reg[d]]&&h===d[onword.reg[d]])onword.reg[d]++;else{onword.reg[d];onword.reg[d]=0}onword.reg[d]>=d.length&&(f(),onword.reg[d]=0)}}; | |
// onword.set(): Add new KeyPress-listener | |
// @param d* {string} - String we're listening for | |
// @param e* {function} - Callback | |
// @param f {bool} - Case-sensitive | |
onword.set("Hello World", ()=>{alert("Welcome to JavaScript!");}) |
/** | |
* @typedef {Object} OnWordListenerInfo | |
* @property {function[]} callback Callbacks for the listener | |
* @property {boolean} case Case senisvity | |
* @property {boolean} debug Debug mode for the listener | |
* @property {number} stage Symbol number which will be checked on the next keypress | |
* @property {string} string String the item is listening for | |
*/ | |
class OnWordListener { |
class OnWordListener{constructor(e,s){this.parent=s,this.id=e}get info(){return this.parent.getById(this.id)}unset(){this.parent.unset(this.id)}}class OnWord{constructor(e=!1,s,t=!1,i=!1){this.register=[],this.disabled=!1,this.listener=this.handler.bind(this),document.addEventListener("keypress",this.listener),t&&this.listen(e,s,t,i)}listen(e,s,t=!1,i=!1){let r=this.register.findIndex(s=>s.string===e&&t===s.case&&i===s.debug);return-1===r?this.register.push({string:t?e:e.toLowerCase(),stage:0,callback:[s],case:t,debug:i}):this.register[r].callback.push(s),r=-1===r?this.register.length-1:r,new OnWordListener(r,this)}getById(e){return this.register[e]}handler(e){if(this.disabled)return;const{key:s}=e,t=s.toLowerCase();this.register.forEach(e=>{const i=e.case?s:t;e.string[e.stage]===i?(e.stage++,e.debug&&console.log(`${i} = ${e.string[e.stage-1]}`)):(e.debug&&console.log(`${i} != ${e.string[e.stage]}`),e.stage=0),e.stage>=e.string.length&&(e.stage=0,e.callback.forEach(e=>e()))})}unset(e){this.register.splice(e,1 |
I hereby claim:
To claim this, I am signing this object:
This document describes the protocol of Mono Corp API Proxy (MCAP). This protocol is created for Mono PWA project.
application/json
Content-Type and 200 OK
response code;function detectDevTools() { | |
let h = window.outerWidth - window.innerWidth > 160; | |
let v = window.outerHeight - window.innerHeight > 160; | |
if ( | |
(h && v) || | |
!((window.Firebug && window.Firebug.chrome && window.Firebug.chrome.isInitialized) || h || v) | |
) { | |
return { isOpen: false, orientation: null }; | |
} |
Also available: English version
Content-Type: application/json
и кодом ответа 200 OK
;POST /personal/auth/request Monobank Request
. См. Отправка запросов в Monobank;import 'package:flutter/material.dart'; | |
void main() { | |
runApp(const MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
const MyApp({super.key}); | |
@override |