403Webshell
Server IP : 209.209.40.120  /  Your IP : 216.73.217.112
Web Server : Microsoft-IIS/10.0
System : Windows NT NEWWWW 10.0 build 17763 (Windows Server 2019) i586
User : NEWWWW$ ( 0)
PHP Version : 8.3.30
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  C:/framework7/node_modules/framework7/components/gauge/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : C:/framework7/node_modules/framework7/components/gauge/gauge.js
import $ from '../../shared/dom7.js';
import Gauge from './gauge-class.js';
import ConstructorMethods from '../../shared/constructor-methods.js';
import { extend } from '../../shared/utils.js';
export default {
  name: 'gauge',
  static: {
    Gauge
  },
  create() {
    const app = this;
    app.gauge = ConstructorMethods({
      defaultSelector: '.gauge',
      constructor: Gauge,
      app,
      domProp: 'f7Gauge'
    });
    app.gauge.update = function update(el, newParams) {
      const $el = $(el);
      if ($el.length === 0) return undefined;
      const gauge = app.gauge.get(el);
      if (!gauge) return undefined;
      gauge.update(newParams);
      return gauge;
    };
  },
  params: {
    gauge: {
      el: null,
      type: 'circle',
      value: 0,
      size: 200,
      bgColor: 'transparent',
      borderBgColor: '#eeeeee',
      borderColor: '#000000',
      borderWidth: 10,
      valueText: null,
      valueTextColor: '#000000',
      valueFontSize: 31,
      valueFontWeight: 500,
      labelText: null,
      labelTextColor: '#888888',
      labelFontSize: 14,
      labelFontWeight: 400
    }
  },
  on: {
    tabMounted(tabEl) {
      const app = this;
      $(tabEl).find('.gauge-init').each(el => {
        app.gauge.create(extend({
          el
        }, $(el).dataset() || {}));
      });
    },
    tabBeforeRemove(tabEl) {
      $(tabEl).find('.gauge-init').each(el => {
        if (el.f7Gauge) el.f7Gauge.destroy();
      });
    },
    pageInit(page) {
      const app = this;
      page.$el.find('.gauge-init').each(el => {
        app.gauge.create(extend({
          el
        }, $(el).dataset() || {}));
      });
    },
    pageBeforeRemove(page) {
      page.$el.find('.gauge-init').each(el => {
        if (el.f7Gauge) el.f7Gauge.destroy();
      });
    }
  },
  vnode: {
    'gauge-init': {
      insert(vnode) {
        const app = this;
        const el = vnode.elm;
        app.gauge.create(extend({
          el
        }, $(el).dataset() || {}));
      },
      destroy(vnode) {
        const el = vnode.elm;
        if (el.f7Gauge) el.f7Gauge.destroy();
      }
    }
  }
};

Youez - 2016 - github.com/yon3zu
LinuXploit