profile-pane 3.2.1 → 3.2.2-test.0

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 (241) hide show
  1. package/README.md +50 -0
  2. package/lib/303.profile-pane.js +1362 -0
  3. package/lib/303.profile-pane.js.map +1 -0
  4. package/lib/303.profile-pane.min.js +2 -0
  5. package/lib/303.profile-pane.min.js.map +1 -0
  6. package/lib/ProfileView.css +1090 -0
  7. package/lib/ProfileView.d.ts +2 -1
  8. package/lib/ProfileView.d.ts.map +1 -1
  9. package/lib/ProfileView.js +64 -36
  10. package/lib/buttonsHelper.d.ts +1 -1
  11. package/lib/buttonsHelper.d.ts.map +1 -1
  12. package/lib/buttonsHelper.js +2 -1
  13. package/lib/editProfilePane/EditCVCard.js +1 -1
  14. package/lib/editProfilePane/EditCommunitiesCard.js +1 -1
  15. package/lib/editProfilePane/EditFriendsCard.js +1 -1
  16. package/lib/editProfilePane/EditProfileView.d.ts +1 -1
  17. package/lib/editProfilePane/EditProfileView.d.ts.map +1 -1
  18. package/lib/editProfilePane/EditProfileView.js +4 -5
  19. package/lib/editProfilePane/editProfilePresenter.d.ts.map +1 -1
  20. package/lib/editProfilePane/editProfilePresenter.js +5 -4
  21. package/lib/icons-svg/profileIcons.d.ts +1 -1
  22. package/lib/icons-svg/profileIcons.d.ts.map +1 -1
  23. package/lib/icons-svg/profileIcons.js +9 -17
  24. package/lib/index.d.ts +1 -8
  25. package/lib/index.d.ts.map +1 -1
  26. package/lib/index.js +74 -40
  27. package/lib/ontology/otherPreferencesForm.ttl +32 -0
  28. package/lib/ontology/resumeForm.ttl +349 -0
  29. package/lib/ontology/socialMedia.ttl +433 -0
  30. package/lib/profile-pane.js +32266 -13247
  31. package/lib/profile-pane.js.map +1 -1
  32. package/lib/profile-pane.min.js +2315 -935
  33. package/lib/profile-pane.min.js.map +1 -1
  34. package/lib/rdfFormsHelper.d.ts +13 -1
  35. package/lib/rdfFormsHelper.d.ts.map +1 -1
  36. package/lib/rdfFormsHelper.js +13 -1
  37. package/lib/sections/bio/BioEditDialog.d.ts.map +1 -1
  38. package/lib/sections/bio/BioEditDialog.js +7 -7
  39. package/lib/sections/bio/BioSection.css +300 -0
  40. package/lib/sections/bio/BioSection.d.ts +3 -2
  41. package/lib/sections/bio/BioSection.d.ts.map +1 -1
  42. package/lib/sections/bio/BioSection.js +26 -19
  43. package/lib/sections/bio/mutations.d.ts.map +1 -1
  44. package/lib/sections/bio/mutations.js +14 -3
  45. package/lib/sections/contactInfo/ContactInfoEditDialog.css +354 -0
  46. package/lib/sections/contactInfo/ContactInfoEditDialog.d.ts +3 -1
  47. package/lib/sections/contactInfo/ContactInfoEditDialog.d.ts.map +1 -1
  48. package/lib/sections/contactInfo/ContactInfoEditDialog.js +183 -98
  49. package/lib/sections/contactInfo/ContactInfoSection.css +125 -0
  50. package/lib/sections/contactInfo/ContactInfoSection.d.ts +2 -0
  51. package/lib/sections/contactInfo/ContactInfoSection.d.ts.map +1 -1
  52. package/lib/sections/contactInfo/ContactInfoSection.js +64 -41
  53. package/lib/sections/contactInfo/mutations.d.ts.map +1 -1
  54. package/lib/sections/contactInfo/mutations.js +51 -16
  55. package/lib/sections/education/EducationEditDialog.d.ts +3 -1
  56. package/lib/sections/education/EducationEditDialog.d.ts.map +1 -1
  57. package/lib/sections/education/EducationEditDialog.js +170 -92
  58. package/lib/sections/education/EducationSection.css +133 -0
  59. package/lib/sections/education/EducationSection.d.ts +3 -2
  60. package/lib/sections/education/EducationSection.d.ts.map +1 -1
  61. package/lib/sections/education/EducationSection.js +32 -25
  62. package/lib/sections/education/mutations.d.ts.map +1 -1
  63. package/lib/sections/education/mutations.js +14 -3
  64. package/lib/sections/heading/HeadingEditDialog.d.ts +4 -1
  65. package/lib/sections/heading/HeadingEditDialog.d.ts.map +1 -1
  66. package/lib/sections/heading/HeadingEditDialog.js +287 -162
  67. package/lib/sections/heading/HeadingSection.css +862 -0
  68. package/lib/sections/heading/HeadingSection.d.ts +3 -2
  69. package/lib/sections/heading/HeadingSection.d.ts.map +1 -1
  70. package/lib/sections/heading/HeadingSection.js +63 -32
  71. package/lib/sections/heading/imageHelpers.d.ts +1 -0
  72. package/lib/sections/heading/imageHelpers.d.ts.map +1 -1
  73. package/lib/sections/heading/imageHelpers.js +40 -1
  74. package/lib/sections/heading/mutations.d.ts.map +1 -1
  75. package/lib/sections/heading/mutations.js +86 -23
  76. package/lib/sections/heading/selectors.d.ts.map +1 -1
  77. package/lib/sections/heading/selectors.js +14 -3
  78. package/lib/sections/heading/types.d.ts +1 -2
  79. package/lib/sections/heading/types.d.ts.map +1 -1
  80. package/lib/sections/languages/LanguageEditDialog.d.ts +3 -1
  81. package/lib/sections/languages/LanguageEditDialog.d.ts.map +1 -1
  82. package/lib/sections/languages/LanguageEditDialog.js +202 -119
  83. package/lib/sections/languages/LanguageSection.css +53 -0
  84. package/lib/sections/languages/LanguageSection.d.ts +2 -0
  85. package/lib/sections/languages/LanguageSection.d.ts.map +1 -1
  86. package/lib/sections/languages/LanguageSection.js +42 -31
  87. package/lib/sections/languages/mutations.d.ts.map +1 -1
  88. package/lib/sections/languages/mutations.js +60 -161
  89. package/lib/sections/languages/selectors.d.ts.map +1 -1
  90. package/lib/sections/languages/selectors.js +1 -2
  91. package/lib/sections/projects/ProjectEditDialog.d.ts +2 -1
  92. package/lib/sections/projects/ProjectEditDialog.d.ts.map +1 -1
  93. package/lib/sections/projects/ProjectEditDialog.js +13 -24
  94. package/lib/sections/projects/ProjectSection.css +368 -0
  95. package/lib/sections/projects/ProjectSection.d.ts +2 -1
  96. package/lib/sections/projects/ProjectSection.d.ts.map +1 -1
  97. package/lib/sections/projects/ProjectSection.js +116 -34
  98. package/lib/sections/projects/mutations.d.ts.map +1 -1
  99. package/lib/sections/projects/mutations.js +109 -132
  100. package/lib/sections/projects/selectors.d.ts.map +1 -1
  101. package/lib/sections/projects/selectors.js +4 -45
  102. package/lib/{QRCodeCard.d.ts → sections/qrcode/QRCodeCard.d.ts} +2 -1
  103. package/lib/sections/qrcode/QRCodeCard.d.ts.map +1 -0
  104. package/lib/{QRCodeCard.js → sections/qrcode/QRCodeCard.js} +59 -11
  105. package/lib/sections/qrcode/QRCodeSection.css +108 -0
  106. package/lib/sections/qrcode/QRCodeSection.d.ts +4 -0
  107. package/lib/sections/qrcode/QRCodeSection.d.ts.map +1 -0
  108. package/lib/sections/qrcode/QRCodeSection.js +17 -0
  109. package/lib/sections/resume/ResumeEditDialog.d.ts +10 -1
  110. package/lib/sections/resume/ResumeEditDialog.d.ts.map +1 -1
  111. package/lib/sections/resume/ResumeEditDialog.js +531 -149
  112. package/lib/sections/resume/ResumeSection.css +350 -0
  113. package/lib/sections/resume/ResumeSection.d.ts +3 -2
  114. package/lib/sections/resume/ResumeSection.d.ts.map +1 -1
  115. package/lib/sections/resume/ResumeSection.js +78 -49
  116. package/lib/sections/resume/mutations.d.ts.map +1 -1
  117. package/lib/sections/resume/mutations.js +17 -3
  118. package/lib/sections/resume/selectors.d.ts.map +1 -1
  119. package/lib/sections/resume/selectors.js +1 -0
  120. package/lib/sections/resume/types.d.ts +1 -0
  121. package/lib/sections/resume/types.d.ts.map +1 -1
  122. package/lib/sections/shared/collapsibleSection.d.ts.map +1 -1
  123. package/lib/sections/shared/collapsibleSection.js +1 -0
  124. package/lib/sections/shared/phoneCountries.d.ts +1 -1
  125. package/lib/sections/shared/phoneCountries.d.ts.map +1 -1
  126. package/lib/sections/shared/phoneCountries.js +2 -2
  127. package/lib/sections/shared/projectCommunityNodes.d.ts +6 -0
  128. package/lib/sections/shared/projectCommunityNodes.d.ts.map +1 -0
  129. package/lib/sections/shared/projectCommunityNodes.js +56 -0
  130. package/lib/sections/shared/rdfMutationHelpers.d.ts +35 -2
  131. package/lib/sections/shared/rdfMutationHelpers.d.ts.map +1 -1
  132. package/lib/sections/shared/rdfMutationHelpers.js +290 -14
  133. package/lib/sections/shared/sectionCardHelpers.d.ts.map +1 -1
  134. package/lib/sections/shared/sectionCardHelpers.js +80 -11
  135. package/lib/sections/shared/types.d.ts +24 -0
  136. package/lib/sections/shared/types.d.ts.map +1 -1
  137. package/lib/sections/skills/SkillsEditDialog.d.ts +3 -1
  138. package/lib/sections/skills/SkillsEditDialog.d.ts.map +1 -1
  139. package/lib/sections/skills/SkillsEditDialog.js +136 -115
  140. package/lib/sections/skills/SkillsSection.css +173 -0
  141. package/lib/sections/skills/SkillsSection.d.ts +2 -0
  142. package/lib/sections/skills/SkillsSection.d.ts.map +1 -1
  143. package/lib/sections/skills/SkillsSection.js +107 -47
  144. package/lib/sections/skills/mutations.d.ts.map +1 -1
  145. package/lib/sections/skills/mutations.js +25 -21
  146. package/lib/sections/skills/selectors.d.ts.map +1 -1
  147. package/lib/sections/skills/selectors.js +5 -3
  148. package/lib/sections/social/SocialEditDialog.d.ts +3 -1
  149. package/lib/sections/social/SocialEditDialog.d.ts.map +1 -1
  150. package/lib/sections/social/SocialEditDialog.js +170 -62
  151. package/lib/sections/social/SocialSection.css +194 -0
  152. package/lib/sections/social/SocialSection.d.ts +4 -3
  153. package/lib/sections/social/SocialSection.d.ts.map +1 -1
  154. package/lib/sections/social/SocialSection.js +59 -43
  155. package/lib/sections/social/mutations.d.ts.map +1 -1
  156. package/lib/sections/social/mutations.js +23 -132
  157. package/lib/specialButtons/AddMeToYourFriends.css +54 -0
  158. package/lib/specialButtons/addContact/AddMeToYourContacts.css +1118 -0
  159. package/lib/specialButtons/addContact/ContactCreationDialog.d.ts +10 -0
  160. package/lib/specialButtons/addContact/ContactCreationDialog.d.ts.map +1 -0
  161. package/lib/specialButtons/addContact/ContactCreationDialog.js +1123 -0
  162. package/lib/specialButtons/addContact/addMeToYourContacts.d.ts +16 -0
  163. package/lib/specialButtons/addContact/addMeToYourContacts.d.ts.map +1 -0
  164. package/lib/specialButtons/addContact/addMeToYourContacts.js +136 -0
  165. package/lib/specialButtons/addContact/contactsErrors.d.ts +8 -0
  166. package/lib/specialButtons/addContact/contactsErrors.d.ts.map +1 -0
  167. package/lib/specialButtons/addContact/contactsErrors.js +106 -0
  168. package/lib/specialButtons/addContact/contactsTypes.d.ts +43 -0
  169. package/lib/specialButtons/addContact/contactsTypes.d.ts.map +1 -0
  170. package/lib/specialButtons/addContact/contactsTypes.js +5 -0
  171. package/lib/specialButtons/addContact/helpers.d.ts +7 -0
  172. package/lib/specialButtons/addContact/helpers.d.ts.map +1 -0
  173. package/lib/specialButtons/addContact/helpers.js +103 -0
  174. package/lib/specialButtons/addContact/mutations.d.ts +16 -0
  175. package/lib/specialButtons/addContact/mutations.d.ts.map +1 -0
  176. package/lib/specialButtons/addContact/mutations.js +300 -0
  177. package/lib/specialButtons/addContact/selectors.d.ts +10 -0
  178. package/lib/specialButtons/addContact/selectors.d.ts.map +1 -0
  179. package/lib/specialButtons/addContact/selectors.js +163 -0
  180. package/lib/{addMeToYourFriends.d.ts → specialButtons/addMeToYourFriends.d.ts} +6 -4
  181. package/lib/specialButtons/addMeToYourFriends.d.ts.map +1 -0
  182. package/lib/{addMeToYourFriends.js → specialButtons/addMeToYourFriends.js} +46 -11
  183. package/lib/styles/CollapsibleSection.css +519 -0
  184. package/lib/styles/EditDialogs.css +506 -686
  185. package/lib/styles/EditDialogs.responsive.css +989 -0
  186. package/lib/texts/buttonTexts.d.ts +9 -0
  187. package/lib/texts/buttonTexts.d.ts.map +1 -0
  188. package/lib/texts/buttonTexts.js +14 -0
  189. package/lib/texts/dialogTexts.d.ts +14 -0
  190. package/lib/texts/dialogTexts.d.ts.map +1 -0
  191. package/lib/texts/dialogTexts.js +19 -0
  192. package/lib/texts/messageTexts.d.ts +42 -0
  193. package/lib/texts/messageTexts.d.ts.map +1 -0
  194. package/lib/texts/messageTexts.js +47 -0
  195. package/lib/texts/profileTexts.d.ts +14 -0
  196. package/lib/texts/profileTexts.d.ts.map +1 -0
  197. package/lib/texts/profileTexts.js +19 -0
  198. package/lib/texts/qrCodeTexts.d.ts +2 -0
  199. package/lib/texts/qrCodeTexts.d.ts.map +1 -0
  200. package/lib/texts/qrCodeTexts.js +7 -0
  201. package/lib/texts.d.ts +5 -60
  202. package/lib/texts.d.ts.map +1 -1
  203. package/lib/texts.js +55 -70
  204. package/lib/ui/dialog.css +233 -0
  205. package/lib/ui/dialog.d.ts +15 -1
  206. package/lib/ui/dialog.d.ts.map +1 -1
  207. package/lib/ui/dialog.js +245 -45
  208. package/lib/ui/dialog.responsive.css +195 -0
  209. package/lib/ui/errors.d.ts.map +1 -1
  210. package/lib/ui/errors.js +2 -1
  211. package/lib/ui/spinner.d.ts +3 -0
  212. package/lib/ui/spinner.d.ts.map +1 -0
  213. package/lib/ui/spinner.js +13 -0
  214. package/lib/utils/debug.d.ts +5 -0
  215. package/lib/utils/debug.d.ts.map +1 -0
  216. package/lib/utils/debug.js +23 -0
  217. package/lib/utils/errorDisplay.d.ts +2 -0
  218. package/lib/utils/errorDisplay.d.ts.map +1 -0
  219. package/lib/utils/errorDisplay.js +19 -0
  220. package/package.json +32 -25
  221. package/lib/ChatWithMe.d.ts +0 -7
  222. package/lib/ChatWithMe.d.ts.map +0 -1
  223. package/lib/ChatWithMe.js +0 -90
  224. package/lib/QRCodeCard.d.ts.map +0 -1
  225. package/lib/addMeToYourFriends.d.ts.map +0 -1
  226. package/lib/sections/heading/camera.d.ts +0 -19
  227. package/lib/sections/heading/camera.d.ts.map +0 -1
  228. package/lib/sections/heading/camera.js +0 -199
  229. package/lib/styles/BioSection.css +0 -77
  230. package/lib/styles/CVCard.css +0 -142
  231. package/lib/styles/ChatWithMe.css +0 -6
  232. package/lib/styles/ContactInfoEditDialog.css +0 -153
  233. package/lib/styles/EducationCard.css +0 -103
  234. package/lib/styles/HeadingSection.css +0 -309
  235. package/lib/styles/ProfileCard.css +0 -66
  236. package/lib/styles/ProfileView.css +0 -65
  237. package/lib/styles/ProjectsCard.css +0 -206
  238. package/lib/styles/QRCodeCard.css +0 -43
  239. package/lib/styles/SocialCard.css +0 -89
  240. package/lib/styles/dialog.css +0 -209
  241. package/lib/styles/utilities.css +0 -740
@@ -1,6 +1,7 @@
1
1
  import { TemplateResult } from 'lit-html';
2
2
  import { DataBrowserContext } from 'pane-registry';
3
3
  import { NamedNode } from 'rdflib';
4
- import './styles/ProfileView.css';
4
+ import './ProfileView.css';
5
+ import './styles/CollapsibleSection.css';
5
6
  export declare function ProfileView(subject: NamedNode, context: DataBrowserContext, onSaved?: () => Promise<void> | void): Promise<TemplateResult>;
6
7
  //# sourceMappingURL=ProfileView.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ProfileView.d.ts","sourceRoot":"","sources":["../src/ProfileView.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,cAAc,EAAE,MAAM,UAAU,CAAA;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AAClD,OAAO,EAAE,SAAS,EAAa,MAAM,QAAQ,CAAA;AAE7C,OAAO,0BAA0B,CAAA;AAgEjC,wBAAsB,WAAW,CAC/B,OAAO,EAAE,SAAS,EAClB,OAAO,EAAE,kBAAkB,EAC3B,OAAO,CAAC,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,GACnC,OAAO,CAAE,cAAc,CAAC,CAsC1B"}
1
+ {"version":3,"file":"ProfileView.d.ts","sourceRoot":"","sources":["../src/ProfileView.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,cAAc,EAAE,MAAM,UAAU,CAAA;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AAClD,OAAO,EAAE,SAAS,EAAa,MAAM,QAAQ,CAAA;AAE7C,OAAO,mBAAmB,CAAA;AAC1B,OAAO,iCAAiC,CAAA;AAiDxC,wBAAsB,WAAW,CAC/B,OAAO,EAAE,SAAS,EAClB,OAAO,EAAE,kBAAkB,EAC3B,OAAO,CAAC,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,GACnC,OAAO,CAAE,cAAc,CAAC,CA8E1B"}
@@ -6,8 +6,8 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.ProfileView = ProfileView;
7
7
  var _litHtml = require("lit-html");
8
8
  var _solidLogic = require("solid-logic");
9
- require("./styles/ProfileView.css");
10
- var _QRCodeCard = require("./QRCodeCard");
9
+ require("./ProfileView.css");
10
+ require("./styles/CollapsibleSection.css");
11
11
  var _ProfileViewModelPresenter = require("./ProfileViewModelPresenter");
12
12
  var _ContactInfoSection = require("./sections/contactInfo/ContactInfoSection");
13
13
  var _LanguageSection = require("./sections/languages/LanguageSection");
@@ -17,6 +17,7 @@ var _ProjectSection = require("./sections/projects/ProjectSection");
17
17
  var _HeadingSection = require("./sections/heading/HeadingSection");
18
18
  var _BioSection = require("./sections/bio/BioSection");
19
19
  var _SocialSection = require("./sections/social/SocialSection");
20
+ var _QRCodeSection = require("./sections/qrcode/QRCodeSection");
20
21
  function getViewerMode(subject) {
21
22
  let mode = 'anonymous';
22
23
  if (_solidLogic.authn.currentUser() && _solidLogic.authn.currentUser().sameTerm(subject)) mode = 'owner';
@@ -25,34 +26,26 @@ function getViewerMode(subject) {
25
26
  }
26
27
  function renderSidebar(store, subject, accounts, skills, languages, contactInfo, viewerMode, onSaved) {
27
28
  return (0, _litHtml.html)`
28
- <aside
29
- aria-labelledby="sidebar-heading"
30
- class="profile__sidebar p-sm"
29
+ <div
30
+ class="profile__sidebar"
31
31
  >
32
- <h2 id="sidebar-heading" class="sr-only">Sidebar</h2>
33
- <div aria-label="Sidebar Content" class="flex-column gap-md">
34
- ${(0, _SocialSection.renderSocialAccounts)(store, subject, accounts, viewerMode, onSaved)}
32
+ <aside class="profile__sidebar-content" aria-labelledby="profile-sidebar-heading">
33
+ <h2 id="profile-sidebar-heading" class="sr-only">Profile sidebar</h2>
34
+ ${(0, _SocialSection.renderSocialSection)(store, subject, accounts, viewerMode, onSaved)}
35
35
  ${(0, _SkillsSection.renderSkillsSection)(store, subject, skills, viewerMode, onSaved)}
36
36
  ${(0, _LanguageSection.renderLanguageSection)(store, subject, languages, viewerMode, onSaved)}
37
37
  ${(0, _ContactInfoSection.renderContactInfoSection)(store, subject, contactInfo, viewerMode, onSaved)}
38
- ${renderQRCode(subject, store)}
39
- </div>
40
- </aside>
41
- `;
42
- }
43
- function renderQRCode(subject, store) {
44
- return (0, _litHtml.html)`
45
- <section class="profile__section border-lighter profile__qr-code" aria-labelledby="qr-heading" tabindex="-1">
46
- <h2 id="qr-heading" class="sr-only">QR code</h2>
47
- <div class="qrcode-card__frame flex-center">
48
- ${(0, _QRCodeCard.QRCodeCard)(subject, store)}
49
- </div>
50
- </section>
38
+ ${(0, _QRCodeSection.renderQRCodeSection)(subject, store)}
39
+ </aside>
40
+ </div>
51
41
  `;
52
42
  }
53
43
  async function ProfileView(subject, context, onSaved) {
54
44
  const store = context.session.store;
55
45
  const viewerMode = getViewerMode(subject);
46
+ const layout = context.environment?.layout ?? 'desktop';
47
+ const theme = context.environment?.theme ?? 'light';
48
+ const inputMode = context.environment?.inputMode ?? 'pointer';
56
49
  const viewModel = await (0, _ProfileViewModelPresenter.presentProfileViewModel)(subject, store);
57
50
  const profileDetails = viewModel.profileDetails;
58
51
  const rolesByType = viewModel.cvDetails;
@@ -62,28 +55,63 @@ async function ProfileView(subject, context, onSaved) {
62
55
  const bioDetails = viewModel.bioDetails;
63
56
  const accounts = viewModel.social;
64
57
  const contactInfo = viewModel.contactInfo;
65
- return (0, _litHtml.html)`
66
- <div class="profile-pane-root">
67
- <main
58
+ const headingSection = await (0, _HeadingSection.renderHeadingSection)(context, subject, profileDetails, viewerMode, onSaved);
59
+ const bioSection = (0, _BioSection.renderBioSection)(store, subject, bioDetails, viewerMode, onSaved);
60
+ const skillsSection = (0, _SkillsSection.renderSkillsSection)(store, subject, skills, viewerMode, onSaved);
61
+ const languageSection = (0, _LanguageSection.renderLanguageSection)(store, subject, languages, viewerMode, onSaved);
62
+ const cvSection = (0, _ResumeSection.renderCVSection)(store, subject, rolesByType, viewerMode, onSaved);
63
+ const projectSection = (0, _ProjectSection.renderProjectSection)(store, subject, projects, viewerMode, onSaved);
64
+ const socialSection = (0, _SocialSection.renderSocialSection)(store, subject, accounts, viewerMode, onSaved);
65
+ const contactInfoSection = (0, _ContactInfoSection.renderContactInfoSection)(store, subject, contactInfo, viewerMode, onSaved);
66
+ const qrCodeSection = (0, _QRCodeSection.renderQRCodeSection)(subject, store);
67
+ if (layout === 'mobile') {
68
+ return (0, _litHtml.html)`
69
+ <div
70
+ class="profile-pane-root"
71
+ data-layout=${layout}
72
+ data-theme=${theme}
73
+ data-input-mode=${inputMode}
74
+ >
75
+ <main
76
+ id="main-content"
77
+ class="profile-grid"
78
+ tabindex="-1"
79
+ >
80
+ ${headingSection}
81
+ ${bioSection}
82
+ ${skillsSection}
83
+ ${languageSection}
84
+ ${cvSection}
85
+ ${projectSection}
86
+ ${socialSection}
87
+ ${contactInfoSection}
88
+ ${qrCodeSection}
89
+ </main>
90
+ </div>
91
+ `;
92
+ }
93
+ return (0, _litHtml.html)`
94
+ <div
95
+ class="profile-pane-root"
96
+ data-layout=${layout}
97
+ data-theme=${theme}
98
+ data-input-mode=${inputMode}
99
+ >
100
+ <div
68
101
  id="main-content"
69
102
  class="profile-grid"
70
103
  tabindex="-1"
71
- >
72
- <h1 id="profile-content-heading" class="sr-only">Profile for ${profileDetails.name}</h1>
104
+ >
73
105
 
74
- <section
75
- class="profile__main flex-column gap-md p-sm"
76
- >
77
- <h2 id="profile-main-heading" class="sr-only">Main Profile Content</h2>
106
+ <section class="profile__main">
107
+ ${headingSection}
108
+ ${bioSection}
109
+ ${cvSection}
110
+ ${projectSection}
78
111
 
79
- ${(0, _HeadingSection.renderHeadingSection)(context, subject, profileDetails, viewerMode, onSaved)}
80
- ${(0, _BioSection.renderBioSection)(store, subject, bioDetails, viewerMode, onSaved)}
81
- ${(0, _ResumeSection.renderCVSection)(store, subject, rolesByType, viewerMode, onSaved)}
82
- ${(0, _ProjectSection.renderProjectSection)(store, subject, projects, viewerMode, onSaved)}
83
-
84
112
  </section>
85
113
  ${renderSidebar(store, subject, accounts, skills, languages, contactInfo, viewerMode, onSaved)}
86
- </main>
114
+ </div>
87
115
  </div>
88
116
  `;
89
117
  }
@@ -1,6 +1,6 @@
1
1
  import { DataBrowserContext } from 'pane-registry';
2
2
  import { NamedNode } from 'rdflib';
3
- declare function complain(buttonContainer: HTMLDivElement, context: DataBrowserContext, error: string): void;
3
+ declare function complain(buttonContainer: HTMLDivElement, context: DataBrowserContext, error: unknown): void;
4
4
  declare function mention(buttonContainer: HTMLDivElement, message: string): void;
5
5
  declare function clearPreviousMessage(buttonContainer: HTMLDivElement): void;
6
6
  declare function checkIfAnyUserLoggedIn(me: NamedNode): boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"buttonsHelper.d.ts","sourceRoot":"","sources":["../src/buttonsHelper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AAElD,OAAO,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAA;AAElC,iBAAS,QAAQ,CACf,eAAe,EAAE,cAAc,EAC/B,OAAO,EAAE,kBAAkB,EAC3B,KAAK,EAAE,MAAM,GACZ,IAAI,CAYN;AAED,iBAAS,OAAO,CAAC,eAAe,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI,CAcvE;AAED,iBAAS,oBAAoB,CAAC,eAAe,EAAE,cAAc,GAAG,IAAI,CAInE;AAED,iBAAS,sBAAsB,CAAC,EAAE,EAAE,SAAS,GAAG,OAAO,CAGtD;AAED,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,CAAA"}
1
+ {"version":3,"file":"buttonsHelper.d.ts","sourceRoot":"","sources":["../src/buttonsHelper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AAElD,OAAO,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAA;AAGlC,iBAAS,QAAQ,CACf,eAAe,EAAE,cAAc,EAC/B,OAAO,EAAE,kBAAkB,EAC3B,KAAK,EAAE,OAAO,GACb,IAAI,CAYN;AAED,iBAAS,OAAO,CAAC,eAAe,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI,CAcvE;AAED,iBAAS,oBAAoB,CAAC,eAAe,EAAE,cAAc,GAAG,IAAI,CAInE;AAED,iBAAS,sBAAsB,CAAC,EAAE,EAAE,SAAS,GAAG,OAAO,CAGtD;AAED,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,CAAA"}
@@ -8,8 +8,9 @@ exports.clearPreviousMessage = clearPreviousMessage;
8
8
  exports.complain = complain;
9
9
  exports.mention = mention;
10
10
  var _solidUi = require("solid-ui");
11
+ var _errorDisplay = require("./utils/errorDisplay");
11
12
  function complain(buttonContainer, context, error) {
12
- const errorBlock = _solidUi.widgets.errorMessageBlock(context.dom, error);
13
+ const errorBlock = _solidUi.widgets.errorMessageBlock(context.dom, (0, _errorDisplay.formatDisplayError)(error));
13
14
  errorBlock.setAttribute('role', 'alert');
14
15
  errorBlock.setAttribute('aria-live', 'assertive');
15
16
  errorBlock.setAttribute('tabindex', '0');
@@ -9,7 +9,7 @@ var _texts = require("../texts");
9
9
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
10
  /* babel-plugin-inline-import '../ontology/resumeForm.ttl' */
11
11
  /** Project-local: currently unused component. Keep temporarily; do not add new usage. */
12
- const resumeForm = "@prefix os: <http://www.w3.org/2000/10/swap/os#> .\n@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.\n@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.\n@prefix foaf: <http://xmlns.com/foaf/0.1/>.\n@prefix owl: <http://www.w3.org/2002/07/owl#>.\n@prefix solid: <http://www.w3.org/ns/solid/terms#>.\n@prefix ui: <http://www.w3.org/ns/ui#>.\n@prefix schema: <http://schema.org/>.\n@prefix vcard: <http://www.w3.org/2006/vcard/ns#>.\n@prefix org: <http://www.w3.org/ns/org#>.\n@prefix esco: <http://data.europa.eu/esco/model#>.\n@prefix wd: <http://www.wikidata.org/entity/>.\n@prefix wdt: <http://www.wikidata.org/prop/direct/>.\n@prefix l: <https://www.w3.org/ns/iana/language-code/>.\n\n@prefix : <#>.\n\n:this\n <http://purl.org/dc/elements/1.1/title> \"Resume form\" ;\n a ui:Form ;\n ui:parts (\n :CVGroup\n :SkillsHeading :SkillsForm\n :LanguagesHeading :LanguagesForm\n ).\n\n# Curriculum Vitae: membership of organizations\n\n:CVGroup a ui:Group; \n ui:weight 1; \n ui:parts ( \n :ResumeHeading \n :involvementWithOrganizationsForm \n ).\n\n:ResumeHeading a ui:Heading; \n ui:contents \"Add your work experience\" .\n\n:involvementWithOrganizationsForm a ui:Multiple;\n ui:label \"work experience\";\n ui:property org:member; \n ui:reverse true; # link back from role to member\n ui:ordered false; # Allow user to order CV secions rather than force date order? No.\n ui:part :RoleMembershipForm.\n\norg:member owl:inverse [ ui:label \"Work experience\" ]. # timelimited involvement\n\n# This is a big important form for one of a series of roles in the list.\n\n:RoleMembershipForm a ui:Group; \n ui:weight 3; \n ui:parts ( \n :MembershipFormHeading\n :RoleClassifier \n :roleNameField\n :escoOccupationField \n :orgField \n :RoleDatesForm \n :RoleDescriptionForm).\n\n:MembershipFormHeading a ui:Heading; \n ui:contents \"Details of the role\"@en, \"D\xE9tailes de ce r\xF4le\"@fr .\n\n:roleNameField a ui:SingleLineTextField;\n ui:label \"Job title\";\n ui:property vcard:role .\n\n:escoOccupationField a ui:AutocompleteField;\n ui:label \"Find in occupation catalog\";\n ui:property org:role;\n ui:dataSource :ESCO_Occupation_DataSource;\n ui:targetClass schema:Occupation .\n\n :ESCO_Occupation_DataSource a ui:DataSource;\n schema:name \"ESCO\";\n ui:targetClass schema:Occupation ;\n schema:logo <https://ec.europa.eu/esco/portal/static_resource2/images/logo/logo_en.gif>;\n ui:searchByNameURI \"https://ec.europa.eu/esco/api/search?language=$(language)&type=occupation&text=$(name)\".\n\n:orgField a ui:Choice; \n ui:label \"For organization\"@en, \"Pour l'organisation\"@fr;\n ui:canMintNew true; \n ui:use :OrganizationCreationForm ;\n ui:property org:organization;\n ui:from vcard:Organization .\n\nvcard:Organization ui:creationForm :OrganizationCreationForm .\n\n###### eposodes in one's career - Roles\n\n:RoleClassifier a ui:Classifier; \n ui:label \"Job type\"@en;\n ui:category solid:Role .\n\n:RoleDatesForm a ui:Options; \n ui:dependingOn rdf:type; \n ui:case\n [ ui:for solid:PastRole; ui:use :TwoDateForm ],\n [ ui:for solid:CurrentRole; ui:use :StartDateForm ],\n [ ui:for solid:FutureRole; ui:use :StartDateForm ].\n\n :TwoDateForm a ui:Group; \n ui:weight 0; \n ui:parts ( :StartDateForm :EndDateForm ) .\n :StartDateForm a ui:DateField; \n ui:label \"Start\"@en,\"D\xE9but\"@fr;\n ui:property schema:startDate .\n :EndDateForm a ui:DateField; \n ui:label \"End\"@en,\"Fin\"@fr;\n ui:property schema:endDate .\n\nsolid:Role a rdfs:Class;\n owl:disjointUnionOf ( solid:PastRole solid:CurrentRole solid:FutureRole ) ;\n owl:oneOf ( solid:CurrentRole solid:PastRole solid:FutureRole ). # Future Role too?\n\nsolid:PastRole a rdfs:Class; rdfs:label \"Former role\"@en, \"Ancien r\xF4le\"@fr, \"Vergangene Rolle\"@de, \"Rol anterior\"@es .\nsolid:CurrentRole a rdfs:Class; rdfs:label \"Current role\"@en, \"R\xF4le actuel\"@fr, \"Momentane Rolle\"@de , \"Rol actual\"@es .\nsolid:FutureRole a rdfs:Class; rdfs:label \"Future role\"@en, \"R\xF4le \xE0 venir\"@fr, \"Zuk\xFCnftige Rolle\"@de, \"Rol futuro\"@es .\n\n:RoleDescriptionForm a ui:MultiLineTextField; \n ui:property schema:description;\n ui:label \"Describe your role\" .\n\n###### Organizations\n\n:OrganizationCreationForm a ui:Form; \n schema:name \"Form for editing an organization using public data\" ;\n ui:parts ( \n :OrgClassifier \n :OrganizationNameField\n :OrgSwitch\n :homePageURIField ) .\n\n:OrgClassifier a ui:Classifier; \n ui:label \"Type\"@en;\n ui:category solid:InterestingOrganization .\n\n:OrgSwitch a ui:Options; \n ui:dependingOn rdf:type;\n ui:case\n [ ui:for schema:Corporation; ui:use :CorporationForm ],\n [ ui:for schema:GovernmentOrganization; ui:use :GovernmentOrganizationForm ],\n [ ui:for schema:PerformingGroup; ui:use :PerformingGroupForm ],\n [ ui:for schema:Project; ui:use :ProjectForm ],\n [ ui:for schema:NGO; ui:use :NGOForm ],\n [ ui:for schema:EducationalOrganization; ui:use :EducationalOrganizationForm ],\n [ ui:for schema:ResearchOrganization; ui:use :ResearchOrganizationForm ],\n [ ui:for schema:SportsOrganization; ui:use :SportsOrganizationForm ].\n\n:OrganizationNameField a ui:SingleLineTextField ;\n ui:label \"Name\";\n ui:maxLength \"200\" ;\n ui:property schema:name .\n\n:homePageURIField a ui:NamedNodeURIField;\n ui:label \"Homepage\"@en;\n ui:property schema:uri .\n\n# Ontology data to drive the :OrgClassifier classifier\nsolid:InterestingOrganization owl:disjointUnionOf (\n # Airline - a Corporation\n # Consortium - a Corporation or a NGO\n schema:Corporation\n schema:EducationalOrganization\n schema:ResearchOrganization # Proposed. https://github.com/schemaorg/schemaorg/issues/2877\n # FundingScheme - eh?\n schema:GovernmentOrganization\n # LibrarySystem\n # LocalBusiness - Corporation\n # MedicalOrganization - a Corporation or a NGO\n schema:NGO\n # NewsMediaOrganization - a Corporation or a NGO\n schema:PerformingGroup # a band\n schema:Project # like Solid\n schema:SportsOrganization) .\n\n# This until the schema.org ontology adopts it\nschema:ResearchOrganization a rdfs:Class; \n rdfs:label \"Research Organization\"@en, \"Organization de Recherche\"@fr ,\"organizaci\xF3n de investigaci\xF3n\"@es, \n \"\u0645\u0646\u0638\u0645\u0629 \u0627\u0644\u0628\u062D\u062B\"@ar, \"\u0905\u0928\u0941\u0938\u0902\u0927\u093E\u0928 \u0938\u0902\u0917\u0920\u0928\"@hi, \"Forschungsorganisation\"@de, \"shirika la utafiti\"@sw .\n\n##### Depending on the type of org, chose a different form\n\n#### Corporation\n:CorporationForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :CorporationAutocomplete ) .\n\n :CorporationAutocomplete a ui:AutocompleteField; \n ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q6881511>; # Enterprise\n ui:property solid:publicId; \n ui:dataSource :WikidataInstancesByName.\n\n :WikidataInstancesByName a ui:DataSource ;\n schema:name \"Wikidata instances by name\";\n ui:endpoint \"https://query.wikidata.org/sparql\" ;\n ui:searchByNameQuery \"\"\"SELECT ?subject ?name\n WHERE {\n ?klass wdt:P279* $(targetClass) .\n ?subject wdt:P31 ?klass .\n ?subject rdfs:label ?name.\n FILTER regex(?name, \"$(name)\", \"i\")\n } LIMIT $(limit) \"\"\" ;\n\n # Note this form of the query is very experimental\n ui:searchByName [ ui:construct { ?subject schema:name ?name } ;\n ui:where { ?klass wdt:P279 ?targetClass .\n ?subject wdt:P31 ?klass; rdfs:label ?name .\n };\n ].\n\n#### Gouvernment\n:GovernmentOrganizationForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :GovernmentOrganizationAutocomplete ) .\n\n :GovernmentOrganizationAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q327333>; # GovernmentOrganization\n ui:property solid:publicId; \n ui:dataSource :WikidataInstancesByName.\n\n#### Educational\n:EducationalOrganizationForm a ui:Group; \n ui:weight 1; \n ui:parts ( \n :EducationalOrganizationAutocomplete ) .\n\n :EducationalOrganizationAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q2385804>; # EducationalOrganization\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### Research Group\n:ResearchOrganizationForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :ResearchOrganizationAutocomplete ) .\n\n :ResearchOrganizationAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q31855>; # research institute\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### NGO\n:NGOForm a ui:Group; ui:weight 0; \n ui:parts ( \n :NGOAutocomplete ) .\n\n :NGOAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q163740>; # Non-profit org\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### Performing group\n:PerformingGroupForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :PerformingGroupAutocomplete ) .\n\n :PerformingGroupAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q32178211>; # Music Org\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### Project\n:ProjectForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :ProjectAutocomplete ) . # :ProjectAutocomplete - no: supress, as not in WD\n\n :ProjectAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q170584>; # Project\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### Sports Organization\n :SportsOrganizationForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :SportsOrganizationAutocomplete ) .\n\n :SportsOrganizationAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q4438121>; # SportsOrganization\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#################### Skills\n\n:SkillsHeading a ui:Heading; \n ui:contents \"Add your skills\" .\n\n:SkillsForm a ui:Multiple;\n ui:label \"skill\";\n ui:property schema:skills;\n ui:ordered false; # Allow reader to order skills\n ui:part :SkillForm.\n\n:SkillForm a ui:Group; ui:weight 1; ui:parts ( :escoSkillField ).\n\n :escoSkillField a ui:AutocompleteField;\n ui:label \"Find in skills catalog\";\n ui:property solid:publicId;\n ui:dataSource :ESCO_Skill_DataSource;\n ui:targetClass schema:Skill .\n\n :ESCO_Skill_DataSource a ui:DataSource;\n schema:name \"ESCO skill\";\n ui:targetClass esco:Skill ;\n schema:logo <https://ec.europa.eu/esco/portal/static_resource2/images/logo/logo_en.gif>;\n ui:searchByNameURI \"https://ec.europa.eu/esco/api/search?language=$(language)&limit=$(limit)&type=skill&text=$(name)\".\n\n#################### Languages\n\n:LanguagesHeading a ui:Heading; ui:contents \"Add your languages\" .\n\n:LanguagesForm a ui:Multiple;\n ui:label \"language\";\n ui:property schema:knowsLanguage; \n ui:ordered true; # Allow user to order languages most important first.\n ui:part :LanguageForm.\n\n:LanguageForm a ui:Group; ui:weight 1; ui:parts ( :WikidataLanguageField ).\n\n :WikidataLanguageField a ui:AutocompleteField;\n ui:label \"Language\";\n ui:property solid:publicId; \n ui:dataSource :WikidataLanguageDataSource;\n ui:targetClass schema:Language .\n\n :WikidataLanguageDataSource\n schema:name \"Find in wikidata\";\n ui:endpoint \"https://query.wikidata.org/sparql\" ;\n ui:objectURIBase <https://www.w3.org/ns/iana/language-code/>;\n # Add this to any literal string returned as ?subject\n ui:searchByNameQuery \"\"\"SELECT ?item ?subject ?name\n WHERE\n { ?item wdt:P305 ?subject .\n OPTIONAL {?item rdfs:label ?name}\n OPTIONAL {?item wdt:P1705 ?name}\n FILTER regex(?name, \"$(name)\", \"i\")\n FILTER regex(?subject, \"^..$\", \"i\")\n }\"\"\" .\n # Note we restrict code to two-letter codes with the second regex, so as to limit the deluge of languages\n # Hope there are not any important ones which have three-letter codes.\n # Omitted: SERVICE wikibase:label { bd:serviceParam wikibase:language \"$(languages)\". }";
12
+ const resumeForm = "@prefix os: <http://www.w3.org/2000/10/swap/os#> .\n@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.\n@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.\n@prefix foaf: <http://xmlns.com/foaf/0.1/>.\n@prefix owl: <http://www.w3.org/2002/07/owl#>.\n@prefix solid: <http://www.w3.org/ns/solid/terms#>.\n@prefix ui: <http://www.w3.org/ns/ui#>.\n@prefix schema: <http://schema.org/>.\n@prefix vcard: <http://www.w3.org/2006/vcard/ns#>.\n@prefix org: <http://www.w3.org/ns/org#>.\n@prefix esco: <http://data.europa.eu/esco/model#>.\n@prefix wd: <http://www.wikidata.org/entity/>.\n@prefix wdt: <http://www.wikidata.org/prop/direct/>.\n@prefix l: <https://www.w3.org/ns/iana/language-code/>.\n\n@prefix : <#>.\n\n:this\n <http://purl.org/dc/elements/1.1/title> \"Resume form\" ;\n a ui:Form ;\n ui:parts (\n :CVGroup\n :SkillsHeading :SkillsForm\n :LanguagesHeading :LanguagesForm\n ).\n\n# Curriculum Vitae: membership of organizations\n\n:CVGroup a ui:Group; \n ui:weight 1; \n ui:parts ( \n :ResumeHeading \n :involvementWithOrganizationsForm \n ).\n\n:ResumeHeading a ui:Heading; \n ui:contents \"Add your work experience\" .\n\n:involvementWithOrganizationsForm a ui:Multiple;\n ui:label \"work experience\";\n ui:property org:member; \n ui:reverse true; # link back from role to member\n ui:ordered false; # Allow user to order CV secions rather than force date order? No.\n ui:part :RoleMembershipForm.\n\norg:member owl:inverse [ ui:label \"Work experience\" ]. # timelimited involvement\n\n# This is a big important form for one of a series of roles in the list.\n\n:RoleMembershipForm a ui:Group; \n ui:weight 3; \n ui:parts ( \n :MembershipFormHeading\n :RoleClassifier \n :roleNameField\n :escoOccupationField \n :orgField \n :RoleDatesForm \n :RoleDescriptionForm).\n\n:MembershipFormHeading a ui:Heading; \n ui:contents \"Details of the role\"@en, \"D\xE9tailes de ce r\xF4le\"@fr .\n\n:roleNameField a ui:SingleLineTextField;\n ui:label \"Job title\";\n ui:property vcard:role .\n\n:escoOccupationField a ui:AutocompleteField;\n ui:label \"Find in occupation catalog\";\n ui:property org:role;\n ui:dataSource :ESCO_Occupation_DataSource;\n ui:targetClass schema:Occupation .\n\n :ESCO_Occupation_DataSource a ui:DataSource;\n schema:name \"ESCO\";\n ui:targetClass schema:Occupation ;\n schema:logo <https://ec.europa.eu/esco/portal/static_resource2/images/logo/logo_en.gif>;\n ui:searchByNameURI \"https://ec.europa.eu/esco/api/search?language=$(language)&type=occupation&text=$(name)&selectedVersion=v1.2.0\".\n\n:orgField a ui:Choice; \n ui:label \"For organization\"@en, \"Pour l'organisation\"@fr;\n ui:canMintNew true; \n ui:use :OrganizationCreationForm ;\n ui:property org:organization;\n ui:from vcard:Organization .\n\nvcard:Organization ui:creationForm :OrganizationCreationForm .\n\n###### eposodes in one's career - Roles\n\n:RoleClassifier a ui:Classifier; \n ui:label \"Job type\"@en;\n ui:category solid:Role .\n\n:RoleDatesForm a ui:Options; \n ui:dependingOn rdf:type; \n ui:case\n [ ui:for solid:PastRole; ui:use :TwoDateForm ],\n [ ui:for solid:CurrentRole; ui:use :StartDateForm ],\n [ ui:for solid:FutureRole; ui:use :StartDateForm ].\n\n :TwoDateForm a ui:Group; \n ui:weight 0; \n ui:parts ( :StartDateForm :EndDateForm ) .\n :StartDateForm a ui:DateField; \n ui:label \"Start\"@en,\"D\xE9but\"@fr;\n ui:property schema:startDate .\n :EndDateForm a ui:DateField; \n ui:label \"End\"@en,\"Fin\"@fr;\n ui:property schema:endDate .\n\nsolid:Role a rdfs:Class;\n owl:disjointUnionOf ( solid:PastRole solid:CurrentRole solid:FutureRole ) ;\n owl:oneOf ( solid:CurrentRole solid:PastRole solid:FutureRole ). # Future Role too?\n\nsolid:PastRole a rdfs:Class; rdfs:label \"Former role\"@en, \"Ancien r\xF4le\"@fr, \"Vergangene Rolle\"@de, \"Rol anterior\"@es .\nsolid:CurrentRole a rdfs:Class; rdfs:label \"Current role\"@en, \"R\xF4le actuel\"@fr, \"Momentane Rolle\"@de , \"Rol actual\"@es .\nsolid:FutureRole a rdfs:Class; rdfs:label \"Future role\"@en, \"R\xF4le \xE0 venir\"@fr, \"Zuk\xFCnftige Rolle\"@de, \"Rol futuro\"@es .\n\n:RoleDescriptionForm a ui:MultiLineTextField; \n ui:property schema:description;\n ui:label \"Describe your role\" .\n\n###### Organizations\n\n:OrganizationCreationForm a ui:Form; \n schema:name \"Form for editing an organization using public data\" ;\n ui:parts ( \n :OrgClassifier \n :OrganizationNameField\n :OrgSwitch\n :homePageURIField ) .\n\n:OrgClassifier a ui:Classifier; \n ui:label \"Type\"@en;\n ui:category solid:InterestingOrganization .\n\n:OrgSwitch a ui:Options; \n ui:dependingOn rdf:type;\n ui:case\n [ ui:for schema:Corporation; ui:use :CorporationForm ],\n [ ui:for schema:GovernmentOrganization; ui:use :GovernmentOrganizationForm ],\n [ ui:for schema:PerformingGroup; ui:use :PerformingGroupForm ],\n [ ui:for schema:Project; ui:use :ProjectForm ],\n [ ui:for schema:NGO; ui:use :NGOForm ],\n [ ui:for schema:EducationalOrganization; ui:use :EducationalOrganizationForm ],\n [ ui:for schema:ResearchOrganization; ui:use :ResearchOrganizationForm ],\n [ ui:for schema:SportsOrganization; ui:use :SportsOrganizationForm ].\n\n:OrganizationNameField a ui:SingleLineTextField ;\n ui:label \"Name\";\n ui:maxLength \"200\" ;\n ui:property schema:name .\n\n:homePageURIField a ui:NamedNodeURIField;\n ui:label \"Homepage\"@en;\n ui:property schema:uri .\n\n# Ontology data to drive the :OrgClassifier classifier\nsolid:InterestingOrganization owl:disjointUnionOf (\n # Airline - a Corporation\n # Consortium - a Corporation or a NGO\n schema:Corporation\n schema:EducationalOrganization\n schema:ResearchOrganization # Proposed. https://github.com/schemaorg/schemaorg/issues/2877\n # FundingScheme - eh?\n schema:GovernmentOrganization\n # LibrarySystem\n # LocalBusiness - Corporation\n # MedicalOrganization - a Corporation or a NGO\n schema:NGO\n # NewsMediaOrganization - a Corporation or a NGO\n schema:PerformingGroup # a band\n schema:Project # like Solid\n schema:SportsOrganization) .\n\n# This until the schema.org ontology adopts it\nschema:ResearchOrganization a rdfs:Class; \n rdfs:label \"Research Organization\"@en, \"Organization de Recherche\"@fr ,\"organizaci\xF3n de investigaci\xF3n\"@es, \n \"\u0645\u0646\u0638\u0645\u0629 \u0627\u0644\u0628\u062D\u062B\"@ar, \"\u0905\u0928\u0941\u0938\u0902\u0927\u093E\u0928 \u0938\u0902\u0917\u0920\u0928\"@hi, \"Forschungsorganisation\"@de, \"shirika la utafiti\"@sw .\n\n##### Depending on the type of org, chose a different form\n\n#### Corporation\n:CorporationForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :CorporationAutocomplete ) .\n\n :CorporationAutocomplete a ui:AutocompleteField; \n ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q6881511>; # Enterprise\n ui:property solid:publicId; \n ui:dataSource :WikidataInstancesByName.\n\n :WikidataInstancesByName a ui:DataSource ;\n schema:name \"Wikidata instances by name\";\n ui:endpoint \"https://query.wikidata.org/sparql\" ;\n ui:searchByNameQuery \"\"\"SELECT ?subject ?name\n WHERE {\n ?klass wdt:P279* $(targetClass) .\n ?subject wdt:P31 ?klass .\n ?subject rdfs:label ?name.\n FILTER regex(?name, \"$(name)\", \"i\")\n } LIMIT $(limit) \"\"\" ;\n\n # Note this form of the query is very experimental\n ui:searchByName [ ui:construct { ?subject schema:name ?name } ;\n ui:where { ?klass wdt:P279 ?targetClass .\n ?subject wdt:P31 ?klass; rdfs:label ?name .\n };\n ].\n\n#### Gouvernment\n:GovernmentOrganizationForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :GovernmentOrganizationAutocomplete ) .\n\n :GovernmentOrganizationAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q327333>; # GovernmentOrganization\n ui:property solid:publicId; \n ui:dataSource :WikidataInstancesByName.\n\n#### Educational\n:EducationalOrganizationForm a ui:Group; \n ui:weight 1; \n ui:parts ( \n :EducationalOrganizationAutocomplete ) .\n\n :EducationalOrganizationAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q2385804>; # EducationalOrganization\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### Research Group\n:ResearchOrganizationForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :ResearchOrganizationAutocomplete ) .\n\n :ResearchOrganizationAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q31855>; # research institute\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### NGO\n:NGOForm a ui:Group; ui:weight 0; \n ui:parts ( \n :NGOAutocomplete ) .\n\n :NGOAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q163740>; # Non-profit org\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### Performing group\n:PerformingGroupForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :PerformingGroupAutocomplete ) .\n\n :PerformingGroupAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q32178211>; # Music Org\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### Project\n:ProjectForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :ProjectAutocomplete ) . # :ProjectAutocomplete - no: supress, as not in WD\n\n :ProjectAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q170584>; # Project\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#### Sports Organization\n :SportsOrganizationForm a ui:Group; \n ui:weight 0; \n ui:parts ( \n :SportsOrganizationAutocomplete ) .\n\n :SportsOrganizationAutocomplete\n a ui:AutocompleteField; ui:label \"Find in wikidata\";\n ui:targetClass <http://www.wikidata.org/entity/Q4438121>; # SportsOrganization\n ui:property solid:publicId; ui:dataSource :WikidataInstancesByName.\n\n#################### Skills\n\n:SkillsHeading a ui:Heading; \n ui:contents \"Add your skills\" .\n\n:SkillsForm a ui:Multiple;\n ui:label \"skill\";\n ui:property schema:skills;\n ui:ordered false; # Allow reader to order skills\n ui:part :SkillForm.\n\n:SkillForm a ui:Group; ui:weight 1; ui:parts ( :escoSkillField ).\n\n :escoSkillField a ui:AutocompleteField;\n ui:label \"Find in skills catalog\";\n ui:property solid:publicId;\n ui:dataSource :ESCO_Skill_DataSource;\n ui:targetClass schema:Skill .\n\n :ESCO_Skill_DataSource a ui:DataSource;\n schema:name \"ESCO skill\";\n ui:targetClass esco:Skill ;\n schema:logo <https://ec.europa.eu/esco/portal/static_resource2/images/logo/logo_en.gif>;\n ui:searchByNameURI \"https://ec.europa.eu/esco/api/search?language=$(language)&limit=$(limit)&type=skill&text=$(name)&selectedVersion=v1.2.0\".\n\n#################### Languages\n\n:LanguagesHeading a ui:Heading; ui:contents \"Add your languages\" .\n\n:LanguagesForm a ui:Multiple;\n ui:label \"language\";\n ui:property schema:knowsLanguage; \n ui:ordered true; # Allow user to order languages most important first.\n ui:part :LanguageForm.\n\n:LanguageForm a ui:Group; ui:weight 1; ui:parts ( :WikidataLanguageField ).\n\n :WikidataLanguageField a ui:AutocompleteField;\n ui:label \"Language\";\n ui:property solid:publicId; \n ui:dataSource :WikidataLanguageDataSource;\n ui:targetClass schema:Language .\n\n :WikidataLanguageDataSource\n schema:name \"Find in wikidata\";\n ui:endpoint \"https://query.wikidata.org/sparql\" ;\n ui:objectURIBase <https://www.w3.org/ns/iana/language-code/>;\n # Add this to any literal string returned as ?subject\n ui:searchByNameQuery \"\"\"SELECT ?item ?subject ?name\n WHERE\n { ?item wdt:P305 ?subject .\n OPTIONAL {?item rdfs:label ?name}\n OPTIONAL {?item wdt:P1705 ?name}\n FILTER regex(?name, \"$(name)\", \"i\")\n FILTER regex(?subject, \"^..$\", \"i\")\n }\"\"\" .\n # Note we restrict code to two-letter codes with the second regex, so as to limit the deluge of languages\n # Hope there are not any important ones which have three-letter codes.\n # Omitted: SERVICE wikibase:label { bd:serviceParam wikibase:language \"$(languages)\". }";
13
13
  const resumeFormName = 'resumeForm.ttl'; // The name of the form file
14
14
 
15
15
  function EditCVSection(context, me, editableProfile, store) {
@@ -9,7 +9,7 @@ var _texts = require("../texts");
9
9
  var _solidLogic = require("solid-logic");
10
10
  require("../styles/editProfile.css");
11
11
  var _buttonsHelper = require("../buttonsHelper");
12
- var _addMeToYourFriends = require("../addMeToYourFriends");
12
+ var _addMeToYourFriends = require("../specialButtons/addMeToYourFriends");
13
13
  var _editProfilePresenter = require("./editProfilePresenter");
14
14
  /** Project-local: currently unused component. Keep temporarily; do not add new usage. */
15
15
 
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.EditFriendsSection = EditFriendsSection;
7
7
  var _solidUi = require("solid-ui");
8
8
  var _texts = require("../texts");
9
- var _addMeToYourFriends = require("../addMeToYourFriends");
9
+ var _addMeToYourFriends = require("../specialButtons/addMeToYourFriends");
10
10
  require("../styles/editProfile.css");
11
11
  var _solidLogic = require("solid-logic");
12
12
  var _buttonsHelper = require("../buttonsHelper");
@@ -9,7 +9,7 @@
9
9
  * or standalone script adding onto existing mashlib.
10
10
  */
11
11
  import { PaneDefinition } from 'pane-registry';
12
- import '../styles/utilities.css';
12
+ import '../ProfileView.css';
13
13
  declare const editProfileView: PaneDefinition;
14
14
  export default editProfileView;
15
15
  //# sourceMappingURL=EditProfileView.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"EditProfileView.d.ts","sourceRoot":"","sources":["../../src/editProfilePane/EditProfileView.ts"],"names":[],"mappings":"AAAA,yFAAyF;AACzF;;;;;;;;GAQG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAA;AAO9C,OAAO,yBAAyB,CAAA;AAKhC,QAAA,MAAM,eAAe,EAAE,cAuGtB,CAAA;AAED,eAAe,eAAe,CAAA"}
1
+ {"version":3,"file":"EditProfileView.d.ts","sourceRoot":"","sources":["../../src/editProfilePane/EditProfileView.ts"],"names":[],"mappings":"AAAA,yFAAyF;AACzF;;;;;;;;GAQG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAA;AAO9C,OAAO,oBAAoB,CAAA;AAK3B,QAAA,MAAM,eAAe,EAAE,cAsGtB,CAAA;AAED,eAAe,eAAe,CAAA"}
@@ -9,7 +9,7 @@ var _EditContactsCard = require("./EditContactsCard");
9
9
  var _EditFriendsCard = require("./EditFriendsCard");
10
10
  var _EditSocialCard = require("./EditSocialCard");
11
11
  var _EditCommunitiesCard = require("./EditCommunitiesCard");
12
- require("../styles/utilities.css");
12
+ require("../ProfileView.css");
13
13
  var _EditCVCard = require("./EditCVCard");
14
14
  var _EditOtherPreferences = require("./EditOtherPreferences");
15
15
  var _rdfFormsHelper = require("../rdfFormsHelper");
@@ -31,8 +31,7 @@ const editProfileView = {
31
31
  label: () => null,
32
32
  // don't use this in the normal solid-panes dispatching
33
33
 
34
- render: function (subject, context) {
35
- //console.log('@@@ render edit profile pane: subject, context', subject, context)
34
+ render: function (_subject, context) {
36
35
  const dom = context.dom;
37
36
  const store = context.session.store;
38
37
 
@@ -43,8 +42,8 @@ const editProfileView = {
43
42
  div.setAttribute('aria-label', 'Edit your profile');
44
43
  let editableProfile;
45
44
 
46
- // Use <main> for the main content area, styled as a grid like ProfileView
47
- const main = dom.createElement('main');
45
+ // Pane root content. The page-level <main> landmark is on the shell's #MainContent.
46
+ const main = dom.createElement('div');
48
47
  main.setAttribute('id', 'profile-edit-main-content');
49
48
  main.setAttribute('aria-busy', 'true');
50
49
  main.setAttribute('tabindex', '-1');
@@ -1 +1 @@
1
- {"version":3,"file":"editProfilePresenter.d.ts","sourceRoot":"","sources":["../../src/editProfilePane/editProfilePresenter.ts"],"names":[],"mappings":"AAAA,yFAAyF;AACzF,OAAO,EAAE,SAAS,EAAO,MAAM,QAAQ,CAAA;AAMvC,wBAAgB,OAAO,CAAC,GAAG,EAAE,QAAQ,EAAE,eAAe,EAAE,gBAAgB,EAAE,EAAE,EAAE,SAAS,EAAE,eAAe,EAAE,SAAS,GAAG,IAAI,EAAE,SAAS,EAAE,SAAS,QAmB/I;AAiFD,wBAAgB,QAAQ,CAAC,OAAO,EAAE,SAAS,GAAG,OAAO,CAMpD"}
1
+ {"version":3,"file":"editProfilePresenter.d.ts","sourceRoot":"","sources":["../../src/editProfilePane/editProfilePresenter.ts"],"names":[],"mappings":"AAAA,yFAAyF;AACzF,OAAO,EAAE,SAAS,EAAO,MAAM,QAAQ,CAAA;AAOvC,wBAAgB,OAAO,CAAC,GAAG,EAAE,QAAQ,EAAE,eAAe,EAAE,gBAAgB,EAAE,EAAE,EAAE,SAAS,EAAE,eAAe,EAAE,SAAS,GAAG,IAAI,EAAE,SAAS,EAAE,SAAS,QAmB/I;AAiFD,wBAAgB,QAAQ,CAAC,OAAO,EAAE,SAAS,GAAG,OAAO,CAMpD"}
@@ -8,6 +8,7 @@ exports.refresh = refresh;
8
8
  var _rdflib = require("rdflib");
9
9
  var _solidLogic = require("solid-logic");
10
10
  var _solidUi = require("solid-ui");
11
+ var _debug = require("../utils/debug");
11
12
  /** Project-local: currently unused component. Keep temporarily; do not add new usage. */
12
13
 
13
14
  const DEFAULT_ICON_URI = _solidUi.icons.iconBase + 'noun_10636_grey.svg'; // grey disc
@@ -64,7 +65,7 @@ async function deleteAttachment(dom, attachmentTable, me, editableProfile, targe
64
65
  // Delete the exact statements in the store so we don't rely on doc() matching
65
66
  const statementsToDelete = _solidLogic.store.statementsMatching(me, predicate, target, null);
66
67
  if (!statementsToDelete.length) {
67
- console.warn('No matching statement found to delete for', target.value);
68
+ (0, _debug.warn)('No matching statement found to delete for', target.value);
68
69
  refresh(dom, attachmentTable, me, editableProfile, predicate);
69
70
  return;
70
71
  }
@@ -77,7 +78,7 @@ async function deleteAttachment(dom, attachmentTable, me, editableProfile, targe
77
78
  if (stillThere) {
78
79
  try {
79
80
  _solidLogic.store.removeStatements(statementsToDelete);
80
- } catch (e) {
81
+ } catch (_error) {
81
82
  // Ignore if already gone
82
83
  }
83
84
  }
@@ -87,13 +88,13 @@ async function deleteAttachment(dom, attachmentTable, me, editableProfile, targe
87
88
  if (_solidLogic.store.fetcher) await _solidLogic.store.fetcher.load(me.doc());
88
89
  refresh(dom, attachmentTable, me, editableProfile, predicate);
89
90
  } catch (error) {
90
- console.error('Error deleting:', error);
91
+ (0, _debug.error)('Error deleting:', error);
91
92
 
92
93
  // If update failed, try to keep UI in sync anyway
93
94
  if (typeof _solidLogic.store.removeStatements === 'function') {
94
95
  try {
95
96
  _solidLogic.store.removeStatements(statementsToDelete);
96
- } catch (e) {
97
+ } catch (_error) {
97
98
  /* ignore */
98
99
  }
99
100
  }
@@ -3,11 +3,11 @@ export declare const locationIcon: import("lit-html").TemplateResult<1>;
3
3
  export declare const checkMarkIcon: import("lit-html").TemplateResult<1>;
4
4
  export declare const plusDarkIcon: import("lit-html").TemplateResult<1>;
5
5
  export declare const plusIcon: import("lit-html").TemplateResult<1>;
6
- export declare const searchIcon: import("lit-html").TemplateResult<1>;
7
6
  export declare const trashIcon: import("lit-html").TemplateResult<1>;
8
7
  export declare const bentoIcon: import("lit-html").TemplateResult<1>;
9
8
  export declare const starIcon: import("lit-html").TemplateResult<1>;
10
9
  export declare const addIcon: import("lit-html").TemplateResult<1>;
10
+ export declare const chevronDownIcon: import("lit-html").TemplateResult<1>;
11
11
  export declare const personInCircleIcon: import("lit-html").TemplateResult<1>;
12
12
  export declare const globeIcon: import("lit-html").TemplateResult<1>;
13
13
  export declare const lighteningIcon: import("lit-html").TemplateResult<1>;
@@ -1 +1 @@
1
- {"version":3,"file":"profileIcons.d.ts","sourceRoot":"","sources":["../../src/icons-svg/profileIcons.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,YAAY,sCAoBxB,CAAA;AACD,eAAO,MAAM,YAAY,sCAYxB,CAAA;AACD,eAAO,MAAM,aAAa,sCAWzB,CAAA;AACD,eAAO,MAAM,YAAY,sCAYxB,CAAA;AAED,eAAO,MAAM,QAAQ,sCAkBpB,CAAA;AACD,eAAO,MAAM,UAAU,sCAYtB,CAAA;AACD,eAAO,MAAM,SAAS,sCAerB,CAAA;AACD,eAAO,MAAM,SAAS,sCAgBrB,CAAA;AACD,eAAO,MAAM,QAAQ,sCAYpB,CAAA;AACD,eAAO,MAAM,OAAO,sCAkBnB,CAAA;AACD,eAAO,MAAM,kBAAkB,sCAa9B,CAAA;AACD,eAAO,MAAM,SAAS,sCAarB,CAAA;AACD,eAAO,MAAM,cAAc,sCAiB1B,CAAA;AACD,eAAO,MAAM,WAAW,sCAWvB,CAAA;AACD,eAAO,MAAM,YAAY,sCAYxB,CAAA;AACD,eAAO,MAAM,SAAS,sCAWrB,CAAA;AAED,eAAO,MAAM,SAAS,sCAWrB,CAAA;AAED,eAAO,MAAM,QAAQ,sCAWpB,CAAA;AACD,eAAO,MAAM,UAAU,sCAYtB,CAAA;AACD,eAAO,MAAM,UAAU,sCAYtB,CAAA;AAED,eAAO,MAAM,iBAAiB,sCAY7B,CAAA"}
1
+ {"version":3,"file":"profileIcons.d.ts","sourceRoot":"","sources":["../../src/icons-svg/profileIcons.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,YAAY,sCAoBxB,CAAA;AACD,eAAO,MAAM,YAAY,sCAYxB,CAAA;AACD,eAAO,MAAM,aAAa,sCAWzB,CAAA;AACD,eAAO,MAAM,YAAY,sCAYxB,CAAA;AAED,eAAO,MAAM,QAAQ,sCAkBpB,CAAA;AACD,eAAO,MAAM,SAAS,sCAerB,CAAA;AACD,eAAO,MAAM,SAAS,sCAgBrB,CAAA;AACD,eAAO,MAAM,QAAQ,sCAYpB,CAAA;AACD,eAAO,MAAM,OAAO,sCAkBnB,CAAA;AAED,eAAO,MAAM,eAAe,sCAI3B,CAAA;AACD,eAAO,MAAM,kBAAkB,sCAa9B,CAAA;AACD,eAAO,MAAM,SAAS,sCAarB,CAAA;AACD,eAAO,MAAM,cAAc,sCAiB1B,CAAA;AACD,eAAO,MAAM,WAAW,sCAWvB,CAAA;AACD,eAAO,MAAM,YAAY,sCAYxB,CAAA;AACD,eAAO,MAAM,SAAS,sCAWrB,CAAA;AAED,eAAO,MAAM,SAAS,sCAWrB,CAAA;AAED,eAAO,MAAM,QAAQ,sCAWpB,CAAA;AACD,eAAO,MAAM,UAAU,sCAYtB,CAAA;AACD,eAAO,MAAM,UAAU,sCAYtB,CAAA;AAED,eAAO,MAAM,iBAAiB,sCAY7B,CAAA"}
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.twoDownArrowsIcon = exports.trashIcon = exports.starIcon = exports.searchIcon = exports.plusIcon = exports.plusDarkIcon = exports.personInCircleIcon = exports.pasteIcon = exports.locationIcon = exports.lighteningIcon = exports.globeIcon = exports.envelopeIcon = exports.editIcon = exports.deleteIcon = exports.commentIcon = exports.closeIcon = exports.checkMarkIcon = exports.cameraIcon = exports.birthdayIcon = exports.bentoIcon = exports.addIcon = void 0;
6
+ exports.twoDownArrowsIcon = exports.trashIcon = exports.starIcon = exports.plusIcon = exports.plusDarkIcon = exports.personInCircleIcon = exports.pasteIcon = exports.locationIcon = exports.lighteningIcon = exports.globeIcon = exports.envelopeIcon = exports.editIcon = exports.deleteIcon = exports.commentIcon = exports.closeIcon = exports.chevronDownIcon = exports.checkMarkIcon = exports.cameraIcon = exports.birthdayIcon = exports.bentoIcon = exports.addIcon = void 0;
7
7
  var _litHtml = require("lit-html");
8
8
  const birthdayIcon = exports.birthdayIcon = (0, _litHtml.html)`
9
9
  <svg
@@ -83,19 +83,6 @@ const plusIcon = exports.plusIcon = (0, _litHtml.html)`
83
83
  </defs>
84
84
  </svg>
85
85
  `;
86
- const searchIcon = exports.searchIcon = (0, _litHtml.html)`
87
- <svg xmlns="http://www.w3.org/2000/svg"
88
- width="13"
89
- height="13"
90
- viewBox="0 0 13 13"
91
- fill="none"
92
- aria-hidden="true"
93
- focusable="false"
94
- >
95
- <circle cx="5.5" cy="5.5" r="4.5" stroke="#99A1AF" stroke-width="1.2" fill="none"/>
96
- <path d="M9.1 9.1L12 12" stroke="#99A1AF" stroke-width="1.2" stroke-linecap="round"/>
97
- </svg>
98
- `;
99
86
  const trashIcon = exports.trashIcon = (0, _litHtml.html)`
100
87
  <svg xmlns="http://www.w3.org/2000/svg"
101
88
  width="20"
@@ -161,6 +148,11 @@ const addIcon = exports.addIcon = (0, _litHtml.html)`
161
148
  </defs>
162
149
  </svg>
163
150
  `;
151
+ const chevronDownIcon = exports.chevronDownIcon = (0, _litHtml.html)`
152
+ <svg xmlns="http://www.w3.org/2000/svg" width="12" height="7" viewBox="0 0 12 7" fill="none" aria-hidden="true" focusable="false">
153
+ <path d="M10.1831 0.183058C10.4271 -0.061018 10.8228 -0.061015 11.0668 0.183058C11.3109 0.427136 11.3109 0.82277 11.0668 1.06685L6.06685 6.06685C5.82277 6.31093 5.42714 6.31093 5.18306 6.06685L0.183058 1.06685C-0.0610194 0.82277 -0.0610194 0.427136 0.183058 0.183058C0.427136 -0.0610194 0.82277 -0.0610194 1.06685 0.183058L5.62495 4.74116L10.1831 0.183058Z" fill="#6A7282"/>
154
+ </svg>
155
+ `;
164
156
  const personInCircleIcon = exports.personInCircleIcon = (0, _litHtml.html)`
165
157
  <svg xmlns="http://www.w3.org/2000/svg"
166
158
  width="64"
@@ -258,9 +250,9 @@ const closeIcon = exports.closeIcon = (0, _litHtml.html)`
258
250
  `;
259
251
  const editIcon = exports.editIcon = (0, _litHtml.html)`
260
252
  <svg xmlns="http://www.w3.org/2000/svg"
261
- width="20"
262
- height="20"
263
- viewBox="0 0 20 20"
253
+ width="14"
254
+ height="14"
255
+ viewBox="3 3 14 14"
264
256
  fill="none"
265
257
  aria-hidden="true"
266
258
  focusable="false"
package/lib/index.d.ts CHANGED
@@ -1,13 +1,6 @@
1
1
  import { DataBrowserContext } from 'pane-registry';
2
- import './styles/CVCard.css';
3
- import './styles/ChatWithMe.css';
4
- import './styles/ProfileCard.css';
5
- import './styles/ProfileView.css';
6
- import './styles/QRCodeCard.css';
7
- import './styles/SocialCard.css';
8
- import './styles/utilities.css';
9
2
  import { NamedNode } from 'rdflib';
10
- export { addMeToYourFriendsDiv, createAddMeToYourFriendsButton, saveNewThing, checkIfThingExists } from './addMeToYourFriends';
3
+ export { addMeToYourFriendsDiv, createAddMeToYourFriendsButton, saveNewThing, checkIfThingExists } from './specialButtons/addMeToYourFriends';
11
4
  declare const Pane: {
12
5
  global: boolean;
13
6
  icon: string;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AAClD,OAAO,qBAAqB,CAAA;AAC5B,OAAO,yBAAyB,CAAA;AAChC,OAAO,0BAA0B,CAAA;AACjC,OAAO,0BAA0B,CAAA;AACjC,OAAO,yBAAyB,CAAA;AAChC,OAAO,yBAAyB,CAAA;AAChC,OAAO,wBAAwB,CAAA;AAC/B,OAAO,EAAE,SAAS,EAAa,MAAM,QAAQ,CAAA;AAK7C,OAAO,EACL,qBAAqB,EACrB,8BAA8B,EAC9B,YAAY,EACZ,kBAAkB,EACnB,MAAM,sBAAsB,CAAA;AAe7B,QAAA,MAAM,IAAI;;;;qBAKG,SAAS,WACT,kBAAkB,KAC1B,MAAM,GAAG,IAAI;sBAWE,SAAS,WAAW,kBAAkB,KAAG,WAAW;CA4CvE,CAAA;AAED,eAAe,IAAI,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AAClD,OAAO,EAAE,SAAS,EAAa,MAAM,QAAQ,CAAA;AAK7C,OAAO,EACL,qBAAqB,EACrB,8BAA8B,EAC9B,YAAY,EACZ,kBAAkB,EACnB,MAAM,qCAAqC,CAAA;AAsG5C,QAAA,MAAM,IAAI;;;;qBAKG,SAAS,WACT,kBAAkB,KAC1B,MAAM,GAAG,IAAI;sBAWE,SAAS,WAAW,kBAAkB,KAAG,WAAW;CAqBvE,CAAA;AAED,eAAe,IAAI,CAAA"}
package/lib/index.js CHANGED
@@ -28,25 +28,81 @@ Object.defineProperty(exports, "saveNewThing", {
28
28
  return _addMeToYourFriends.saveNewThing;
29
29
  }
30
30
  });
31
- require("./styles/CVCard.css");
32
- require("./styles/ChatWithMe.css");
33
- require("./styles/ProfileCard.css");
34
- require("./styles/ProfileView.css");
35
- require("./styles/QRCodeCard.css");
36
- require("./styles/SocialCard.css");
37
- require("./styles/utilities.css");
38
31
  var _litHtml = require("lit-html");
39
- var _ProfileView2 = require("./ProfileView");
32
+ var _ProfileView = require("./ProfileView");
40
33
  var _solidUi = require("solid-ui");
41
- var qrcode = _interopRequireWildcard(require("qrcode"));
42
- var _addMeToYourFriends = require("./addMeToYourFriends");
43
- function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
34
+ var _QRCodeCard = require("./sections/qrcode/QRCodeCard");
35
+ var _addMeToYourFriends = require("./specialButtons/addMeToYourFriends");
44
36
  async function loadExtendedProfile(store, subject) {
45
37
  const otherProfiles = store.each(subject, _solidUi.ns.rdfs('seeAlso'), null, subject.doc());
46
38
  if (otherProfiles.length > 0) {
47
39
  await store.fetcher.load(otherProfiles);
48
40
  }
49
41
  }
42
+ const HEADING_SECTION_SELECTOR = '[data-profile-section="heading"]';
43
+ const SOCIAL_SECTION_SELECTOR = '[data-profile-section="social"]';
44
+ function syncSocialSectionHeight(root) {
45
+ let animationFrameId = 0;
46
+ const updateHeight = () => {
47
+ animationFrameId = 0;
48
+ const grid = root.querySelector('.profile-grid');
49
+ const headingSection = root.querySelector(HEADING_SECTION_SELECTOR);
50
+ const socialSection = root.querySelector(SOCIAL_SECTION_SELECTOR);
51
+ if (!grid || !headingSection || !socialSection) {
52
+ return;
53
+ }
54
+ const isDesktopGrid = root.dataset.layout !== 'mobile' && getComputedStyle(grid).display === 'grid';
55
+ if (!isDesktopGrid) {
56
+ socialSection.style.removeProperty('min-height');
57
+ return;
58
+ }
59
+ const nextMinHeight = `${Math.ceil(headingSection.getBoundingClientRect().height)}px`;
60
+ if (socialSection.style.minHeight !== nextMinHeight) {
61
+ socialSection.style.minHeight = nextMinHeight;
62
+ }
63
+ };
64
+ const scheduleUpdate = () => {
65
+ if (animationFrameId !== 0) {
66
+ return;
67
+ }
68
+ animationFrameId = window.requestAnimationFrame(updateHeight);
69
+ };
70
+ updateHeight();
71
+ if (typeof ResizeObserver === 'undefined') {
72
+ window.addEventListener('resize', scheduleUpdate);
73
+ return () => {
74
+ if (animationFrameId !== 0) {
75
+ window.cancelAnimationFrame(animationFrameId);
76
+ }
77
+ window.removeEventListener('resize', scheduleUpdate);
78
+ };
79
+ }
80
+ const resizeObserver = new ResizeObserver(scheduleUpdate);
81
+ resizeObserver.observe(root);
82
+ const headingSection = root.querySelector(HEADING_SECTION_SELECTOR);
83
+ const socialSection = root.querySelector(SOCIAL_SECTION_SELECTOR);
84
+ if (headingSection) {
85
+ resizeObserver.observe(headingSection);
86
+ }
87
+ if (socialSection) {
88
+ resizeObserver.observe(socialSection);
89
+ }
90
+ return () => {
91
+ if (animationFrameId !== 0) {
92
+ window.cancelAnimationFrame(animationFrameId);
93
+ }
94
+ resizeObserver.disconnect();
95
+ };
96
+ }
97
+ function applyEnvironmentAttributes(element, context) {
98
+ const layout = context.environment?.layout ?? 'desktop';
99
+ const theme = context.environment?.theme ?? 'light';
100
+ const inputMode = context.environment?.inputMode ?? 'pointer';
101
+ element.classList.add('profile-pane-host');
102
+ element.dataset.layout = layout;
103
+ element.dataset.theme = theme;
104
+ element.dataset.inputMode = inputMode;
105
+ }
50
106
  const Pane = {
51
107
  global: false,
52
108
  icon: _solidUi.icons.iconBase + 'noun_15059.svg',
@@ -61,36 +117,14 @@ const Pane = {
61
117
  render: (subject, context) => {
62
118
  const target = context.dom.createElement('div');
63
119
  const store = context.session.store;
120
+ let cleanupSocialSectionHeightSync = null;
121
+ applyEnvironmentAttributes(target, context);
64
122
  const renderWithData = async () => {
65
- (0, _litHtml.render)(await (0, _ProfileView2.ProfileView)(subject, context, renderWithData), target);
66
- const QRCodeEles = Array.from(target.getElementsByClassName('qrcode-card'));
67
- if (!QRCodeEles.length) return console.error('QRCode Ele missing');
68
- for (const QRCodeElement of QRCodeEles) {
69
- const value = QRCodeElement.getAttribute('data-value');
70
- if (!value) return console.error('QRCode data-value missing');
71
- const options = {
72
- type: 'svg',
73
- color: {
74
- dark: '#000000',
75
- light: '#ffffff'
76
- }
77
- };
78
- qrcode.toString(value, options, function (error, svg) {
79
- if (error) {
80
- console.error('QRcode error!', error);
81
- } else {
82
- const imageContainer = QRCodeElement.querySelector('div[role="img"]');
83
- if (!imageContainer) {
84
- console.error('QRCode image container missing');
85
- return;
86
- }
87
- imageContainer.innerHTML = svg;
88
- imageContainer.style.width = '100%';
89
- imageContainer.style.height = '100%';
90
- imageContainer.style.margin = '0';
91
- }
92
- });
93
- }
123
+ applyEnvironmentAttributes(target, context);
124
+ (0, _litHtml.render)(await (0, _ProfileView.ProfileView)(subject, context, renderWithData), target);
125
+ cleanupSocialSectionHeightSync?.();
126
+ cleanupSocialSectionHeightSync = syncSocialSectionHeight(target);
127
+ await (0, _QRCodeCard.hydrateQRCodes)(target);
94
128
  };
95
129
  loadExtendedProfile(store, subject).then(async () => {
96
130
  await renderWithData();