gd-sprest 9.7.3 → 9.7.4

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 (98) hide show
  1. package/build/helper/executor.js +10 -20
  2. package/build/helper/fieldSchemaXML.js +85 -89
  3. package/build/helper/index.js +12 -28
  4. package/build/helper/jslink.js +124 -128
  5. package/build/helper/listForm.js +109 -118
  6. package/build/helper/listFormField.js +62 -65
  7. package/build/helper/methods/addContentEditorWebPart.js +9 -17
  8. package/build/helper/methods/addPermissionLevel.js +12 -16
  9. package/build/helper/methods/addScriptEditorWebPart.js +9 -17
  10. package/build/helper/methods/copyPermissionLevel.js +22 -26
  11. package/build/helper/methods/createContentType.js +96 -19
  12. package/build/helper/methods/createDocSet.js +10 -14
  13. package/build/helper/methods/getCurrentTheme.js +26 -31
  14. package/build/helper/methods/hasPermissions.js +8 -13
  15. package/build/helper/methods/index.js +16 -32
  16. package/build/helper/methods/loadSPCore.js +13 -17
  17. package/build/helper/methods/parse.js +5 -9
  18. package/build/helper/methods/request.js +4 -8
  19. package/build/helper/methods/setContentTypeFields.js +71 -79
  20. package/build/helper/methods/setGroupOwner.js +6 -10
  21. package/build/helper/methods/setWebProperty.js +26 -30
  22. package/build/helper/methods/stringify.js +3 -7
  23. package/build/helper/methods/webWorker.js +40 -20
  24. package/build/helper/ribbonLink.js +10 -14
  25. package/build/helper/sbLink.js +11 -15
  26. package/build/helper/sp/calloutManager.js +22 -25
  27. package/build/helper/sp/index.js +13 -16
  28. package/build/helper/sp/modalDialog.js +32 -35
  29. package/build/helper/sp/notify.js +9 -12
  30. package/build/helper/sp/ribbon.js +1 -4
  31. package/build/helper/sp/sod.js +9 -18
  32. package/build/helper/sp/status.js +18 -21
  33. package/build/helper/spCfg.js +232 -259
  34. package/build/helper/spCfgTypes.js +2 -5
  35. package/build/helper/taxonomy.js +144 -182
  36. package/build/helper/webpart.js +110 -94
  37. package/build/index.js +6 -23
  38. package/build/lib/apps.js +4 -7
  39. package/build/lib/contextInfo.js +217 -781
  40. package/build/lib/directorySession.js +4 -7
  41. package/build/lib/graph.js +16 -19
  42. package/build/lib/groupService.js +4 -7
  43. package/build/lib/groupSiteManager.js +4 -7
  44. package/build/lib/hubSites.js +11 -25
  45. package/build/lib/hubSitesUtility.js +4 -7
  46. package/build/lib/index.js +27 -43
  47. package/build/lib/list.js +49 -53
  48. package/build/lib/navigation.js +4 -7
  49. package/build/lib/peopleManager.js +4 -7
  50. package/build/lib/peoplePicker.js +4 -7
  51. package/build/lib/profileLoader.js +4 -7
  52. package/build/lib/search.js +30 -33
  53. package/build/lib/sensitivityLabels.js +6 -9
  54. package/build/lib/site.js +20 -35
  55. package/build/lib/siteIconManager.js +4 -7
  56. package/build/lib/siteManager.js +4 -7
  57. package/build/lib/sitePages.js +37 -51
  58. package/build/lib/socialFeed.js +13 -16
  59. package/build/lib/themeManager.js +4 -7
  60. package/build/lib/userProfile.js +4 -7
  61. package/build/lib/utility.js +12 -17
  62. package/build/lib/web.js +34 -49
  63. package/build/lib/webTemplateExtensions.js +4 -7
  64. package/build/lib/wfInstanceService.js +4 -7
  65. package/build/lib/wfSubscriptionService.js +4 -7
  66. package/build/mapper/custom/audit.js +3 -6
  67. package/build/mapper/custom/graph.js +13 -16
  68. package/build/mapper/custom/index.js +8 -24
  69. package/build/mapper/custom/odata.js +3 -6
  70. package/build/mapper/custom/old.js +42 -45
  71. package/build/mapper/custom/peoplePicker.js +4 -7
  72. package/build/mapper/custom/propertyValues.js +3 -6
  73. package/build/mapper/custom/utility.js +17 -20
  74. package/build/mapper/custom/webTemplateExtensions.js +19 -22
  75. package/build/mapper/def.js +1032 -989
  76. package/build/mapper/index.js +4 -9
  77. package/build/mapper/v2.js +2629 -2632
  78. package/build/rest.js +16 -19
  79. package/build/sptypes/graphtypes.js +694 -710
  80. package/build/sptypes/index.js +3 -7
  81. package/build/sptypes/sptypes.js +49 -52
  82. package/build/utils/base.js +20 -37
  83. package/build/utils/batch.js +53 -63
  84. package/build/utils/helper.js +79 -83
  85. package/build/utils/index.js +9 -25
  86. package/build/utils/methodInfo.js +88 -141
  87. package/build/utils/oData.js +62 -112
  88. package/build/utils/request.js +137 -155
  89. package/build/utils/requestType.js +1 -4
  90. package/build/utils/targetInfo.js +39 -52
  91. package/build/utils/xhrRequest.js +59 -107
  92. package/build/v2/drive.js +9 -13
  93. package/build/v2/drives.js +8 -12
  94. package/build/v2/index.js +3 -19
  95. package/build/v2/sites.js +61 -65
  96. package/dist/gd-sprest.js +1 -1
  97. package/dist/gd-sprest.min.js +1 -1
  98. package/package.json +1 -1
package/build/rest.js CHANGED
@@ -1,16 +1,13 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.$REST = void 0;
4
- var Helper = require("./helper");
5
- var Lib = require("./lib");
6
- var LibV2 = require("./v2");
7
- var sptypes_1 = require("./sptypes");
1
+ import * as Helper from "./helper";
2
+ import * as Lib from "./lib";
3
+ import * as LibV2 from "./v2";
4
+ import { GraphTypes, SPTypes } from "./sptypes";
8
5
  /**
9
6
  * SharePoint REST Library
10
7
  */
11
- exports.$REST = {
12
- __ver: 9.73,
13
- AppContext: function (siteUrl) { return Lib.Site.getAppContext(siteUrl); },
8
+ export const $REST = {
9
+ __ver: 9.74,
10
+ AppContext: (siteUrl) => { return Lib.Site.getAppContext(siteUrl); },
14
11
  Apps: Lib.Apps,
15
12
  ContextInfo: Lib.ContextInfo,
16
13
  DefaultRequestToHostFl: false,
@@ -19,10 +16,10 @@ exports.$REST = {
19
16
  drives: LibV2.drives,
20
17
  GetWebUrlFromPageUrl: Lib.Web.getWebUrlFromPageUrl,
21
18
  Graph: Lib.Graph,
22
- GraphTypes: sptypes_1.GraphTypes,
19
+ GraphTypes,
23
20
  GroupService: Lib.GroupService,
24
21
  GroupSiteManager: Lib.GroupSiteManager,
25
- Helper: Helper,
22
+ Helper,
26
23
  HubSites: Lib.HubSites,
27
24
  HubSitesUtility: Lib.HubSitesUtility,
28
25
  List: Lib.List,
@@ -32,17 +29,17 @@ exports.$REST = {
32
29
  PeopleManager: Lib.PeopleManager,
33
30
  PeoplePicker: Lib.PeoplePicker,
34
31
  ProfileLoader: Lib.ProfileLoader,
35
- RemoteWeb: function (requestUrl) { return Lib.Web.getRemoteWeb(requestUrl); },
32
+ RemoteWeb: (requestUrl) => { return Lib.Web.getRemoteWeb(requestUrl); },
36
33
  Search: Lib.Search,
37
34
  SensitivityLabels: Lib.SensitivityLabels,
38
35
  Site: Lib.Site,
39
36
  SiteIconManager: Lib.SiteIconManager,
40
37
  SiteManager: Lib.SiteManager,
41
38
  SitePages: Lib.SitePages,
42
- SiteExists: function (url) { return Lib.Site.exists(url); },
39
+ SiteExists: (url) => { return Lib.Site.exists(url); },
43
40
  sites: LibV2.sites,
44
- SiteUrl: function (id) { return Lib.Site.getUrlById(id); },
45
- SPTypes: sptypes_1.SPTypes,
41
+ SiteUrl: (id) => { return Lib.Site.getUrlById(id); },
42
+ SPTypes: SPTypes,
46
43
  SocialFeed: Lib.SocialFeed,
47
44
  ThemeManager: Lib.ThemeManager,
48
45
  UserProfile: Lib.UserProfile,
@@ -53,10 +50,10 @@ exports.$REST = {
53
50
  WorkflowSubscriptionService: Lib.WorkflowSubscriptionService
54
51
  };
55
52
  // See if the library doesn't exist, or is an older version
56
- var global = Lib.ContextInfo.window.$REST;
57
- if (global == null || global.__ver == null || global.__ver < exports.$REST.__ver) {
53
+ let global = Lib.ContextInfo.window.$REST;
54
+ if (global == null || global.__ver == null || global.__ver < $REST.__ver) {
58
55
  // Set the global variable
59
- Lib.ContextInfo.window.$REST = exports.$REST;
56
+ Lib.ContextInfo.window.$REST = $REST;
60
57
  // Enable the refresh token
61
58
  Lib.ContextInfo.enableRefreshToken();
62
59
  // Ensure the SP lib exists