Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
var setUser = function (webid) {
if (webid) {
tabulator.preferences.set('me', webid)
console.log('(SetUser: Logged in as ' + webid + ')')
me = kb.sym(webid)
UI.outline.GotoSubject(me, true, pane, true, undefined)
// @@ Here enable all kinds of stuff
} else {
tabulator.preferences.set('me', '')
console.log('(SetUser: Logged out)')
me = null
}
}
// @@ Here enable all kinds of stuff
} else {
tabulator.preferences.set('me', '')
console.log('(SetUser: Logged out)')
me = null
}
}
var me_uri = tabulator.preferences.get('me')
var me = me_uri ? kb.sym(me_uri) : null
var userTest = $rdf.sym('https://databox.me/')
UI.widgets.checkUser(userTest, setUser)
var pane = UI.panes.home
var target = me // @@ for now, in fact not relevant
// subject, expand, pane, solo, referrer, table
})
// @@ Here enable all kinds of stuff
} else {
tabulator.preferences.set('me', '')
console.log('(SetUser: Logged out)')
me = null
}
}
var me_uri = tabulator.preferences.get('me')
var me = me_uri ? kb.sym(me_uri) : null
var userTest = $rdf.sym('https://databox.me/')
UI.widgets.checkUser(userTest, setUser)
var pane = UI.panes.home
var target = me // @@ for now, in fact not relevant
// subject, expand, pane, solo, referrer, table
UI.outline.GotoSubject(target, true, pane, true, undefined)
// ////////////////////////////// Reproduction: spawn a new instance
//
// Viral growth path: user of app decides to make another instance
//
var newInstanceButtonDiv = function () {
return UI.widgets.newAppInstance(dom,
{ noun: 'meeting',
appPathSegment: appPathSegment},
initializeNewInstanceInWorkspace)
} // newInstanceButtonDiv
UI.outline.GotoSubject(me, true, pane, true, undefined)
// @@ Here enable all kinds of stuff
} else {
tabulator.preferences.set('me', '')
console.log('(SetUser: Logged out)')
me = null
}
}
var me_uri = tabulator.preferences.get('me')
var me = me_uri ? kb.sym(me_uri) : null
var userTest = $rdf.sym('https://databox.me/')
UI.widgets.checkUser(userTest, setUser)
var pane = UI.panes.home
var target = me // @@ for now, in fact not relevant
// subject, expand, pane, solo, referrer, table
})
console.log('(SetUser: Logged in as ' + webid + ')')
me = kb.sym(webid)
// @@ Here enable all kinds of stuff
} else {
tabulator.preferences.set('me', '')
console.log('(SetUser: Logged out)')
me = null
}
}
var me_uri = tabulator.preferences.get('me')
var me = me_uri ? kb.sym(me_uri) : null
var userTest = $rdf.sym('https://databox.me/')
UI.widgets.checkUser(userTest, setUser)
var pane = UI.panes.home
var target = me // @@ for now, in fact not relevant
// subject, expand, pane, solo, referrer, table
UI.outline.GotoSubject(target, true, pane, true, undefined)
// ////////////////////////////// Reproduction: spawn a new instance
//
// Viral growth path: user of app decides to make another instance
//
var newInstanceButtonDiv = function () {
return UI.widgets.newAppInstance(dom,
{ noun: 'meeting',
appPathSegment: appPathSegment},
initializeNewInstanceInWorkspace)
document.addEventListener('DOMContentLoaded', function () {
var UI = require('mashlib')
var inputStyle = 'background-color: #eef; padding: 0.5em; border: .5em solid white; font-size: 150%; text-align: center;' // ;
var kb = UI.store
var ns = UI.ns
var dom = document
var updater = kb.updater
var waitingForLogin = false
var uri = window.location.href
var base = uri.slice(0, uri.lastIndexOf('/') + 1)
// //////////////////////////////////// Getting logged in with a WebId
var setUser = function (webid) {
if (webid) {
tabulator.preferences.set('me', webid)
console.log('(SetUser: Logged in as ' + webid + ')')
me = null
}
}
var me_uri = tabulator.preferences.get('me')
var me = me_uri ? kb.sym(me_uri) : null
var userTest = $rdf.sym('https://databox.me/')
UI.widgets.checkUser(userTest, setUser)
var pane = UI.panes.home
var target = me // @@ for now, in fact not relevant
// subject, expand, pane, solo, referrer, table
UI.outline.GotoSubject(target, true, pane, true, undefined)
// ////////////////////////////// Reproduction: spawn a new instance
//
// Viral growth path: user of app decides to make another instance
//
var newInstanceButtonDiv = function () {
return UI.widgets.newAppInstance(dom,
{ noun: 'meeting',
appPathSegment: appPathSegment},
initializeNewInstanceInWorkspace)
} // newInstanceButtonDiv
// /////////////////////// Create new document files for new instance of app
var initializeNewInstanceInWorkspace = function (ws, newBase) {
var newInstanceButtonDiv = function () {
return UI.widgets.newAppInstance(dom,
{ noun: 'meeting',
appPathSegment: appPathSegment},
initializeNewInstanceInWorkspace)
} // newInstanceButtonDiv
var newInstanceButtonDiv = function () {
return UI.authn.newAppInstance(dom,
{ noun: 'meeting',
appPathSegment: appPathSegment},
initializeNewInstanceInWorkspace)
} // newInstanceButtonDiv
document.addEventListener('DOMContentLoaded', function () {
var UI = require('mashlib')
var appPathSegment = 'meetulator.timbl.com'
var inputStyle = 'background-color: #eef; padding: 0.5em; border: .5em solid white; font-size: 150%; text-align: center;' // ;
var dom = document
var div = document.getElementById('FormTarget')
UI.authn.checkUser() // kick off async operation
// ////////////////////////////// Reproduction: spawn a new instance
//
// Viral growth path: user of app decides to make another instance
//
var newInstanceButtonDiv = function () {
return UI.authn.newAppInstance(dom,
{ noun: 'meeting',
appPathSegment: appPathSegment},
initializeNewInstanceInWorkspace)
} // newInstanceButtonDiv
// /////////////////////// Create new document files for new instance of app
var initializeNewInstanceInWorkspace = function (ws, newBase) {