solid-panes 3.5.19 → 3.5.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/dev/loader.ts +11 -11
  2. package/lib/argument/argumentPane.js +15 -7
  3. package/lib/argument/argumentPane.js.map +1 -1
  4. package/lib/dashboard/basicPreferences.d.ts.map +1 -1
  5. package/lib/dashboard/basicPreferences.js +6 -6
  6. package/lib/dashboard/basicPreferences.js.map +1 -1
  7. package/lib/dashboard/dashboardPane.d.ts.map +1 -1
  8. package/lib/dashboard/dashboardPane.js +6 -4
  9. package/lib/dashboard/dashboardPane.js.map +1 -1
  10. package/lib/dataContentPane.js +1 -1
  11. package/lib/dataContentPane.js.map +1 -1
  12. package/lib/form/pane.js +15 -6
  13. package/lib/form/pane.js.map +1 -1
  14. package/lib/home/homePane.d.ts.map +1 -1
  15. package/lib/home/homePane.js +7 -5
  16. package/lib/home/homePane.js.map +1 -1
  17. package/lib/index.d.ts +7 -3
  18. package/lib/index.d.ts.map +1 -1
  19. package/lib/index.js +15 -4
  20. package/lib/index.js.map +1 -1
  21. package/lib/mainPage/header.d.ts.map +1 -1
  22. package/lib/mainPage/header.js +4 -2
  23. package/lib/mainPage/header.js.map +1 -1
  24. package/lib/microblogPane/microblogPane.js +16 -14
  25. package/lib/microblogPane/microblogPane.js.map +1 -1
  26. package/lib/outline/dragDrop.js +16 -6
  27. package/lib/outline/dragDrop.js.map +1 -1
  28. package/lib/outline/licenseOptions.js +12 -5
  29. package/lib/outline/licenseOptions.js.map +1 -1
  30. package/lib/outline/manager.js +29 -21
  31. package/lib/outline/manager.js.map +1 -1
  32. package/lib/outline/queryByExample.js +14 -6
  33. package/lib/outline/queryByExample.js.map +1 -1
  34. package/lib/outline/userInput.js +90 -80
  35. package/lib/outline/userInput.js.map +1 -1
  36. package/lib/pad/padPane.d.ts.map +1 -1
  37. package/lib/pad/padPane.js +6 -4
  38. package/lib/pad/padPane.js.map +1 -1
  39. package/lib/profile/editProfile.view.d.ts.map +1 -1
  40. package/lib/profile/editProfile.view.js +3 -3
  41. package/lib/profile/editProfile.view.js.map +1 -1
  42. package/lib/schedule/schedulePane.js +26 -14
  43. package/lib/schedule/schedulePane.js.map +1 -1
  44. package/lib/socialPane.js +16 -6
  45. package/lib/socialPane.js.map +1 -1
  46. package/lib/transaction/pane.js +1 -1
  47. package/lib/transaction/pane.js.map +1 -1
  48. package/lib/transaction/period.js +1 -1
  49. package/lib/transaction/period.js.map +1 -1
  50. package/lib/trip/tripPane.js +1 -1
  51. package/lib/trip/tripPane.js.map +1 -1
  52. package/lib/trustedApplications/trustedApplications.dom.d.ts.map +1 -1
  53. package/lib/trustedApplications/trustedApplications.dom.js +11 -9
  54. package/lib/trustedApplications/trustedApplications.dom.js.map +1 -1
  55. package/lib/trustedApplications/trustedApplications.view.d.ts.map +1 -1
  56. package/lib/trustedApplications/trustedApplications.view.js +5 -3
  57. package/lib/trustedApplications/trustedApplications.view.js.map +1 -1
  58. package/lib/versionInfo.js +3 -3
  59. package/lib/versionInfo.js.map +1 -1
  60. package/package.json +14 -14
  61. package/src/argument/argumentPane.js +5 -5
  62. package/src/dashboard/basicPreferences.ts +4 -5
  63. package/src/dashboard/dashboardPane.ts +4 -3
  64. package/src/dataContentPane.js +1 -1
  65. package/src/form/pane.js +5 -4
  66. package/src/home/homePane.ts +7 -6
  67. package/src/index.ts +24 -18
  68. package/src/mainPage/header.ts +3 -2
  69. package/src/microblogPane/microblogPane.js +9 -8
  70. package/src/outline/dragDrop.js +5 -4
  71. package/src/outline/licenseOptions.js +4 -5
  72. package/src/outline/manager.js +22 -21
  73. package/src/outline/queryByExample.js +4 -4
  74. package/src/outline/userInput.js +72 -72
  75. package/src/pad/padPane.ts +3 -3
  76. package/src/profile/editProfile.view.ts +5 -8
  77. package/src/schedule/schedulePane.js +14 -13
  78. package/src/socialPane.js +5 -4
  79. package/src/transaction/pane.js +1 -1
  80. package/src/transaction/period.js +1 -1
  81. package/src/trip/tripPane.js +1 -1
  82. package/src/trustedApplications/trustedApplications.dom.ts +2 -1
  83. package/src/trustedApplications/trustedApplications.view.ts +4 -4
  84. package/src/versionInfo.ts +3 -3
@@ -4,7 +4,8 @@
4
4
  */
5
5
  /* global alert */
6
6
 
7
- const UI = require('solid-ui')
7
+ import * as UI from 'solid-ui'
8
+ import { authn } from 'solid-logic'
8
9
  const $rdf = UI.rdf
9
10
  const ns = UI.ns
10
11
 
@@ -141,7 +142,7 @@ module.exports = {
141
142
  const fetcher = kb.fetcher
142
143
  const updater = kb.updater
143
144
 
144
- let me = options.me || UI.authn.currentUser()
145
+ let me = options.me || authn.currentUser()
145
146
  if (!me) {
146
147
  console.log('MUST BE LOGGED IN')
147
148
  alert('NOT LOGGED IN')
@@ -203,7 +204,7 @@ module.exports = {
203
204
  newBase + item.local,
204
205
  item.contentType
205
206
  )
206
- .then(() => UI.authn.checkUser())
207
+ .then(() => authn.checkUser())
207
208
  .then(webId => {
208
209
  me = webId
209
210
 
@@ -376,7 +377,7 @@ module.exports = {
376
377
 
377
378
  let me
378
379
 
379
- UI.authn.checkUser().then(webId => {
380
+ authn.checkUser().then(webId => {
380
381
  me = webId
381
382
 
382
383
  if (logInOutButton) {
@@ -395,7 +396,7 @@ module.exports = {
395
396
  //
396
397
 
397
398
  const newInstanceButton = function () {
398
- const b = UI.authn.newAppInstance(
399
+ const b = UI.login.newAppInstance(
399
400
  dom,
400
401
  { noun: 'scheduler' },
401
402
  initializeNewInstanceInWorkspace
@@ -474,7 +475,7 @@ module.exports = {
474
475
  const showAppropriateDisplay = function showAppropriateDisplay () {
475
476
  console.log('showAppropriateDisplay()')
476
477
 
477
- UI.authn.checkUser().then(webId => {
478
+ authn.checkUser().then(webId => {
478
479
  if (!webId) {
479
480
  return showSignon()
480
481
  }
@@ -505,7 +506,7 @@ module.exports = {
505
506
  const showSignon = function showSignon () {
506
507
  clearElement(naviMain)
507
508
  const signonContext = { div: div, dom: dom }
508
- UI.authn.logIn(signonContext).then(context => {
509
+ UI.login.loggedInContext(signonContext).then(context => {
509
510
  me = context.me
510
511
  waitingForLogin = false // untested
511
512
  showAppropriateDisplay()
@@ -515,7 +516,7 @@ module.exports = {
515
516
  const showBootstrap = function showBootstrap () {
516
517
  const div = clearElement(naviMain)
517
518
  div.appendChild(
518
- UI.authn.newAppInstance(
519
+ UI.login.newAppInstance(
519
520
  dom,
520
521
  { noun: 'poll' },
521
522
  initializeNewInstanceInWorkspace
@@ -799,7 +800,7 @@ module.exports = {
799
800
  refreshButton.textContent = 'refresh'
800
801
  refreshButton.addEventListener('click', function (e) {
801
802
  refreshButton.disabled = true
802
- UI.store.fetcher.nowOrWhenFetched(subject.doc(), undefined, function (ok, body) {
803
+ store.fetcher.nowOrWhenFetched(subject.doc(), undefined, function (ok, body) {
803
804
  if (!ok) {
804
805
  console.log('Cant refresh matrix' + body)
805
806
  } else {
@@ -864,7 +865,7 @@ module.exports = {
864
865
  dataPointForNT[possibleTimes[j].toNT()] = dataPoint
865
866
  }
866
867
  if (insertables.length) {
867
- UI.store.updater.update([], insertables, function (uri, success, errorBody) {
868
+ store.updater.update([], insertables, function (uri, success, errorBody) {
868
869
  if (!success) {
869
870
  complainIfBad(success, errorBody)
870
871
  } else {
@@ -1024,12 +1025,12 @@ module.exports = {
1024
1025
  // @@ Give other combos too-- see schedule ontology
1025
1026
  // const possibleAvailabilities = [ SCHED('No'), SCHED('Maybe'), SCHED('Yes') ]
1026
1027
 
1027
- // const me = UI.authn.currentUser()
1028
+ // const me = authn.currentUser()
1028
1029
 
1029
1030
  const dataPointForNT = []
1030
1031
 
1031
1032
  const loginContext = { div: naviCenter, dom: dom }
1032
- UI.authn.logIn(loginContext).then(context => {
1033
+ UI.login.loggedInContext(loginContext).then(context => {
1033
1034
  const me = context.me
1034
1035
  const doc = resultsDoc
1035
1036
  options.set_y = options.set_y.filter(function (z) {
@@ -1166,7 +1167,7 @@ module.exports = {
1166
1167
 
1167
1168
  const logInOutButton = null
1168
1169
  /*
1169
- const logInOutButton = UI.authn.loginStatusBox(dom, setUser)
1170
+ const logInOutButton = UI.login.loginStatusBox(dom, setUser)
1170
1171
  // floating divs lead to a mess
1171
1172
  // logInOutButton.setAttribute('style', 'float: right') // float the beginning of the end
1172
1173
  naviLoginout3.appendChild(logInOutButton)
package/src/socialPane.js CHANGED
@@ -8,8 +8,9 @@
8
8
  ** -- todo: use common code to get username and load profile and set 'me'
9
9
  */
10
10
 
11
- const UI = require('solid-ui')
12
- const $rdf = require('rdflib')
11
+ import * as UI from 'solid-ui'
12
+ import { authn } from 'solid-logic'
13
+ import * as $rdf from 'rdflib'
13
14
 
14
15
  module.exports = {
15
16
  icon: UI.icons.originalIconBase + 'foaf/foafTiny.gif',
@@ -198,11 +199,11 @@ module.exports = {
198
199
  let h3 = dom.createElement('H3')
199
200
  h3.appendChild(dom.createTextNode(name))
200
201
 
201
- let me = UI.authn.currentUser()
202
+ let me = authn.currentUser()
202
203
  const meUri = me ? me.uri : null
203
204
 
204
205
  // @@ Add: event handler to redraw the stuff below when me changes.
205
- const loginOutButton = UI.authn.loginStatusBox(dom, webIdUri => {
206
+ const loginOutButton = UI.login.loginStatusBox(dom, webIdUri => {
206
207
  me = kb.sym(webIdUri)
207
208
  // @@ To be written: redraw as a function the new me
208
209
  // @@ refresh the sidebars
@@ -67,7 +67,7 @@ module.exports = {
67
67
 
68
68
  const t = kb.findTypeURIs(subject)
69
69
 
70
- // var me = UI.authn.currentUser()
70
+ // var me = authn.currentUser()
71
71
  const predicateURIsDone = {}
72
72
  const donePredicate = function (pred) {
73
73
  predicateURIsDone[pred.uri] = true
@@ -351,7 +351,7 @@ module.exports = {
351
351
 
352
352
  // //////////////////////////////////////////////////////////////////////////////
353
353
 
354
- // var me = UI.authn.currentUser()
354
+ // var me = authn.currentUser()
355
355
 
356
356
  // Render a single Period
357
357
 
@@ -60,7 +60,7 @@ module.exports = {
60
60
 
61
61
  const t = kb.findTypeURIs(subject)
62
62
 
63
- // var me = UI.authn.currentUser()
63
+ // var me = authn.currentUser()
64
64
 
65
65
  // Function: Render a single trip
66
66
 
@@ -1,5 +1,6 @@
1
1
  import { NamedNode, Statement, sym } from 'rdflib'
2
- import { ns, store } from 'solid-ui'
2
+ import { ns } from 'solid-ui'
3
+ import { store } from 'solid-logic'
3
4
  import { generateRandomString, getStatementsToAdd, getStatementsToDelete } from './trustedApplications.utils'
4
5
 
5
6
  interface FormElements {
@@ -1,7 +1,7 @@
1
- import { authn, icons, store, widgets } from 'solid-ui'
2
- import { NamedNode } from 'rdflib'
3
-
4
1
  import { PaneDefinition } from 'pane-registry'
2
+ import { NamedNode } from 'rdflib'
3
+ import { icons, login, widgets } from 'solid-ui'
4
+ import { store } from 'solid-logic'
5
5
  import { createApplicationTable, createContainer, createText } from './trustedApplications.dom'
6
6
 
7
7
  const thisColor = '#418d99'
@@ -32,7 +32,7 @@ const trustedApplicationView: PaneDefinition = {
32
32
  }
33
33
 
34
34
  async function render (dom, main, statusArea): Promise<void> {
35
- const authContext = await authn.logInLoadProfile({ dom: dom, div: main, statusArea: statusArea, me: null })
35
+ const authContext = await login.ensureLoadedProfile({ dom: dom, div: main, statusArea: statusArea, me: null })
36
36
  const subject = authContext.me as NamedNode
37
37
 
38
38
  const profile = subject.doc()
@@ -1,9 +1,9 @@
1
1
  export default {
2
- buildTime: '2022-02-23T14:28:35Z',
3
- commit: '86ea668bacfb94213d209dd9962722bf0189ddbe',
2
+ buildTime: '2022-03-01T20:30:41Z',
3
+ commit: 'b3dce45b53a5e1ff12ca803196b206eaaf3fcb16',
4
4
  npmInfo:
5
5
  {
6
- 'solid-panes': '3.5.19',
6
+ 'solid-panes': '3.5.20',
7
7
  npm: '6.14.13',
8
8
  ares: '1.17.1',
9
9
  brotli: '1.0.9',