Socket
Book a DemoInstallSign in
Socket

schedui

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

schedui

Sched UI - lite event schedule visualization UI library

latest
Source
npmnpm
Version
1.0.0-beta4
Version published
Weekly downloads
4
Maintainers
1
Weekly downloads
 
Created
Source

SchedUI

SchedUI is a lite event schedule visualization UI library

Install

npm install schedui --save

Prerequisites

  • Moment
  • jQuery
  • jQuery UI

Usage

TypeScript

import { SchedUI, IOptions } from 'schedui';

$(() => {

  let today = moment().startOf('day');

  const options: IOptions = {
    periods: [{
      name: '1 week',
      label: '1 week',
      timeframePeriod: 60 * 24,
      timeframeOverall: 60 * 24 * 7,
      timeframeHeaders: ['MMM', 'Do'],
      classes: 'period-1week'
    }, {
      name: '1 month',
      label: '1 month',
      timeframePeriod: 60 * 24 * 1,
      timeframeOverall: 60 * 24 * 28,
      timeframeHeaders: ['MMM', 'Do'],
      classes: 'period-1month'
    }],
    items: [{
      id: 20,
      name: '<div>Item 1</div><div>Sub Info</div>',
      sectionId: 1,
      start: moment(today).add('days', -1),
      end: moment(today).add('days', 3),
      classes: 'item-status-three',
      events: [{
        label: 'one',
        at: moment(today).add('hours', 6),
        classes: 'item-event-one'
      }]
    }, {
      id: 21,
      name: '<div>Item 3</div>',
      start: moment(today).add('hours', 12),
      end: moment(today).add('days', 3).add('hours', 4),
      sectionId: 2,
      classes: 'item-status-none'
    }],
    sections: [
      { id: 1, name: 'Section 1' },
      { id: 2, name: 'Section 2' }
    ],
    selectedPeriod: '1 week',
    element: $('.calendar')
  };

  (new SchedUI(options)).init(true);

});

This project is TypeScriptified fork of TimeScheduler.

FAQs

Package last updated on 18 Nov 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts