From 2d0ec2b162e3e2851fef7f280aab21c9f00cd171 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=B6rnquist?= Date: Sun, 31 Oct 2021 20:48:23 +0100 Subject: Everything but lib. --- static/clock.ts | 1 + static/dragable.ts | 2 ++ static/globals.ts | 22 ++++++++++++++++++++++ static/jcal.ts | 3 +++ static/lib.ts | 1 + static/popup.ts | 2 ++ static/script.ts | 4 ++++ static/server_connect.ts | 2 ++ static/types.ts | 6 ++++++ static/vevent.ts | 3 +++ 10 files changed, 46 insertions(+) (limited to 'static') diff --git a/static/clock.ts b/static/clock.ts index c4feda8f..27c3e4e1 100644 --- a/static/clock.ts +++ b/static/clock.ts @@ -1,3 +1,4 @@ +export { SmallcalCellHighlight, Timebar } class Clock { update(now: Date) { diff --git a/static/dragable.ts b/static/dragable.ts index 20acdd3a..6110a510 100644 --- a/static/dragable.ts +++ b/static/dragable.ts @@ -1,3 +1,5 @@ +export { bind_popup_control } + /* Apply to a given component to make it draggable. Drag area (usually a title bar) should be be the only argument. diff --git a/static/globals.ts b/static/globals.ts index dabd6d8c..0ca2e3de 100644 --- a/static/globals.ts +++ b/static/globals.ts @@ -1,3 +1,25 @@ +export { + vcal_objects, + hasValue, + ComponentVEvent, + ComponentDescription, + popuplateTab, + ComponentEdit, + find_popup, + find_block, + ComponentBlock, + DateTimeInput, + verifySlot, + TabElement, + buildDescriptionList, + PopupElement, + wholeday_checkbox, +} + +import { close_popup, toggle_popup } from './popup' +import { VEvent, xml_to_vcal } from './vevent' +import { bind_popup_control } from './dragable' + "use strict"; const vcal_objects: Map = new Map() diff --git a/static/jcal.ts b/static/jcal.ts index db833a3c..51a1130b 100644 --- a/static/jcal.ts +++ b/static/jcal.ts @@ -1,3 +1,6 @@ +export { jcal_to_xcal } +import { ical_type, JCalProperty, JCal } from './types' + function jcal_type_to_xcal(doc: Document, type: ical_type, value: any): Element { let el = doc.createElementNS(xcal, type); switch (type) { diff --git a/static/lib.ts b/static/lib.ts index 26735bd1..e3d99007 100644 --- a/static/lib.ts +++ b/static/lib.ts @@ -1,3 +1,4 @@ + 'use strict'; /* General procedures which in theory could be used anywhere. diff --git a/static/popup.ts b/static/popup.ts index 8d9420c6..3fb4ae54 100644 --- a/static/popup.ts +++ b/static/popup.ts @@ -1,3 +1,5 @@ +import { find_block, find_popup, PopupElement } from './globals' +export { event_from_popup, popup_from_event, close_popup, close_all_popups, VIEW, open_popup, toggle_popup, activePopup } /* event component => coresponding popup component */ diff --git a/static/script.ts b/static/script.ts index 8984c19a..7d98a28a 100644 --- a/static/script.ts +++ b/static/script.ts @@ -1,5 +1,9 @@ 'use strict'; +import { close_all_popups } from './popup' +import { VEvent } from './vevent' +import { SmallcalCellHighlight, Timebar } from './clock' + /* calp specific stuff */ diff --git a/static/server_connect.ts b/static/server_connect.ts index a6599500..96f6e872 100644 --- a/static/server_connect.ts +++ b/static/server_connect.ts @@ -1,3 +1,5 @@ +import { jcal_to_xcal } from './jcal' +import { VEvent } from './vevent' /* async function remove_event(element: Element): void { diff --git a/static/types.ts b/static/types.ts index 7e10e90e..63d55e35 100644 --- a/static/types.ts +++ b/static/types.ts @@ -1,3 +1,9 @@ +export { + all_types, ical_type, property_names, + valid_fields, known_ical_types, + valid_input_types, tagname, + JCalProperty, JCal +} let all_types = [ 'text', diff --git a/static/vevent.ts b/static/vevent.ts index 20b668ee..f25c5341 100644 --- a/static/vevent.ts +++ b/static/vevent.ts @@ -1,3 +1,6 @@ +import { ical_type, valid_input_types, JCal } from './types' +export { VEvent, xml_to_vcal } + "use strict"; interface Redrawable extends HTMLElement { -- cgit v1.2.3