Skip to content

Commit

Permalink
yFiles for HTML 2.5.0.2 demos
Browse files Browse the repository at this point in the history
  • Loading branch information
michabaur committed Oct 13, 2022
1 parent d183034 commit 7415ceb
Show file tree
Hide file tree
Showing 881 changed files with 22,588 additions and 4,551 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@ import { ExteriorLabelModel, GraphComponent, License } from 'yfiles'

import { fetchLicense } from '../../resources/fetch-license.js'

import { enableWorkarounds } from '../../utils/Workarounds.js'

/**
* @returns {!Promise}
*/
Expand All @@ -47,6 +45,5 @@ async function run() {
graphComponent.fitGraphBounds()
}

enableWorkarounds()
// noinspection JSIgnoredPromiseFromCall
run()
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@ import { ExteriorLabelModel, GraphComponent, License } from 'yfiles'

import { fetchLicense } from '../../resources/fetch-license'

import { enableWorkarounds } from '../../utils/Workarounds'

async function run(): Promise<void> {
License.value = await fetchLicense()

Expand All @@ -44,6 +42,5 @@ async function run(): Promise<void> {
graphComponent.fitGraphBounds()
}

enableWorkarounds()
// noinspection JSIgnoredPromiseFromCall
run()
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ import {
ToolTipQueryEventArgs
} from 'yfiles'

import ContextMenu from '../../utils/ContextMenu.js'
import { ContextMenu } from '../../utils/ContextMenu.js'
import { bindCommand, showApp } from '../../resources/demo-app.js'
import { fetchLicense } from '../../resources/fetch-license.js'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ import {
ToolTipQueryEventArgs
} from 'yfiles'

import ContextMenu from '../../utils/ContextMenu'
import { ContextMenu } from '../../utils/ContextMenu'
import { bindCommand, showApp } from '../../resources/demo-app'
import { fetchLicense } from '../../resources/fetch-license'

Expand Down
12 changes: 3 additions & 9 deletions demos/01-tutorial-getting-started/10-layout/SampleApplication.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ import {
ToolTipQueryEventArgs
} from 'yfiles'

import ContextMenu from '../../utils/ContextMenu.js'
import { bindAction, bindCommand, showApp } from '../../resources/demo-app.js'
import { ContextMenu } from '../../utils/ContextMenu.js'
import { bindAction, bindCommand, reportDemoError, showApp } from '../../resources/demo-app.js'
import GraphBuilderData from './resources/graph.js'
import { fetchLicense } from '../../resources/fetch-license.js'

Expand Down Expand Up @@ -140,13 +140,7 @@ async function runLayout() {
easedAnimation: true
})
} catch (error) {
// this is just for the purpose of the demo - usually you would employ your own
// logging or error handling logic, here
if (typeof window.reportError === 'function') {
window.reportError(error)
} else {
throw error
}
reportDemoError(error)
} finally {
layoutButton.disabled = false
}
Expand Down
13 changes: 3 additions & 10 deletions demos/01-tutorial-getting-started/10-layout/SampleApplication.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ import {
ToolTipQueryEventArgs
} from 'yfiles'

import ContextMenu from '../../utils/ContextMenu'
import { bindAction, bindCommand, showApp } from '../../resources/demo-app'
import { ContextMenu } from '../../utils/ContextMenu'
import { bindAction, bindCommand, reportDemoError, showApp } from '../../resources/demo-app'
import GraphBuilderData from './resources/graph'
import { fetchLicense } from '../../resources/fetch-license'

Expand Down Expand Up @@ -137,14 +137,7 @@ async function runLayout(): Promise<void> {
easedAnimation: true
})
} catch (error) {
// this is just for the purpose of the demo - usually you would employ your own
// logging or error handling logic, here
if (typeof (window as any).reportError === 'function') {
// eslint-disable-next-line @typescript-eslint/no-unsafe-call
;(window as any).reportError(error)
} else {
throw error
}
reportDemoError(error)
} finally {
layoutButton.disabled = false
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ import {
Size
} from 'yfiles'

import { bindAction, bindCommand, showApp } from '../../resources/demo-app.js'
import { bindAction, bindCommand, reportDemoError, showApp } from '../../resources/demo-app.js'
import GraphBuilderData from './resources/graph.js'
import { fetchLicense } from '../../resources/fetch-license.js'

Expand Down Expand Up @@ -137,13 +137,7 @@ async function runLayout() {
easedAnimation: true
})
} catch (error) {
// this is just for the purpose of the demo - usually you would employ your own
// logging or error handling logic, here
if (typeof window.reportError === 'function') {
window.reportError(error)
} else {
throw error
}
reportDemoError(error)
} finally {
layoutButton.disabled = false
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ import {
Size
} from 'yfiles'

import { bindAction, bindCommand, showApp } from '../../resources/demo-app'
import { bindAction, bindCommand, reportDemoError, showApp } from '../../resources/demo-app'
import GraphBuilderData from './resources/graph'
import { fetchLicense } from '../../resources/fetch-license'

Expand Down Expand Up @@ -134,14 +134,7 @@ async function runLayout(): Promise<void> {
easedAnimation: true
})
} catch (error) {
// this is just for the purpose of the demo - usually you would employ your own
// logging or error handling logic, here
if (typeof (window as any).reportError === 'function') {
// eslint-disable-next-line @typescript-eslint/no-unsafe-call
;(window as any).reportError(error)
} else {
throw error
}
reportDemoError(error)
} finally {
layoutButton.disabled = false
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ import {
ToolTipQueryEventArgs
} from 'yfiles'

import ContextMenu from '../../utils/ContextMenu.js'
import { ContextMenu } from '../../utils/ContextMenu.js'
import { bindAction, bindCommand, showApp } from '../../resources/demo-app.js'
import GraphBuilderData from './resources/graph.js'
import { fetchLicense } from '../../resources/fetch-license.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ import {
ToolTipQueryEventArgs
} from 'yfiles'

import ContextMenu from '../../utils/ContextMenu'
import { ContextMenu } from '../../utils/ContextMenu'
import { bindAction, bindCommand, showApp } from '../../resources/demo-app'
import GraphBuilderData from './resources/graph'
import { fetchLicense } from '../../resources/fetch-license'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
constructor() {
super()
this.$nodeColor = 'rgba(0,130,180,1)'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
private static $fillCounter: number

private $nodeColor: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle.js'
import { MySimpleNodeStyle } from './MySimpleNodeStyle.js'
import { bindCommand, showApp } from '../../resources/demo-app.js'

import { applyDemoTheme } from '../../resources/demo-styles.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle'
import { MySimpleNodeStyle } from './MySimpleNodeStyle'
import { bindCommand, showApp } from '../../resources/demo-app'

import { applyDemoTheme } from '../../resources/demo-styles'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
constructor() {
super()
this.$nodeColor = 'rgba(0,130,180,1)'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
private static $fillCounter: number

private $nodeColor: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle.js'
import { MySimpleNodeStyle } from './MySimpleNodeStyle.js'
import { bindCommand, showApp } from '../../resources/demo-app.js'

import { applyDemoTheme } from '../../resources/demo-styles.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle'
import { MySimpleNodeStyle } from './MySimpleNodeStyle'
import { bindCommand, showApp } from '../../resources/demo-app'

import { applyDemoTheme } from '../../resources/demo-styles'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
constructor() {
super()
this.$nodeColor = 'rgba(0,130,180,1)'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
private static $fillCounter: number

private $nodeColor: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle.js'
import { MySimpleNodeStyle } from './MySimpleNodeStyle.js'
import { bindAction, bindCommand, showApp } from '../../resources/demo-app.js'

import { applyDemoTheme } from '../../resources/demo-styles.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle'
import { MySimpleNodeStyle } from './MySimpleNodeStyle'
import { bindAction, bindCommand, showApp } from '../../resources/demo-app'

import { applyDemoTheme } from '../../resources/demo-styles'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
constructor() {
super()
this.$nodeColor = 'rgba(0,130,180,1)'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
private static $fillCounter: number

private $nodeColor: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle.js'
import { MySimpleNodeStyle } from './MySimpleNodeStyle.js'
import { bindCommand, showApp } from '../../resources/demo-app.js'

import { applyDemoTheme } from '../../resources/demo-styles.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle'
import { MySimpleNodeStyle } from './MySimpleNodeStyle'
import { bindCommand, showApp } from '../../resources/demo-app'

import { applyDemoTheme } from '../../resources/demo-styles'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
constructor() {
super()
this.$nodeColor = 'rgba(0,130,180,1)'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
private static $fillCounter: number

private $nodeColor: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle.js'
import { MySimpleNodeStyle } from './MySimpleNodeStyle.js'
import { bindCommand, showApp } from '../../resources/demo-app.js'

import { applyDemoTheme } from '../../resources/demo-styles.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle'
import { MySimpleNodeStyle } from './MySimpleNodeStyle'
import { bindCommand, showApp } from '../../resources/demo-app'

import { applyDemoTheme } from '../../resources/demo-styles'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
constructor() {
super()
this.$nodeColor = 'rgba(0,130,180,1)'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
private static $fillCounter: number

private $nodeColor: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle.js'
import { MySimpleNodeStyle } from './MySimpleNodeStyle.js'
import { bindCommand, showApp } from '../../resources/demo-app.js'

import { applyDemoTheme } from '../../resources/demo-styles.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import {
Size
} from 'yfiles'

import MySimpleNodeStyle from './MySimpleNodeStyle'
import { MySimpleNodeStyle } from './MySimpleNodeStyle'
import { bindCommand, showApp } from '../../resources/demo-app'

import { applyDemoTheme } from '../../resources/demo-styles'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ import {
* that uses the convenience class {@link NodeStyleBase}
* as the base class.
*/
export default class MySimpleNodeStyle extends NodeStyleBase {
export class MySimpleNodeStyle extends NodeStyleBase {
constructor() {
super()
this.$nodeColor = 'rgba(0,130,180,1)'
Expand Down
Loading

0 comments on commit 7415ceb

Please sign in to comment.