@linear/sdk 14.0.0 → 15.0.1

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.
package/dist/index-umd.js CHANGED
@@ -9,7 +9,7 @@
9
9
  var crypto__default = /*#__PURE__*/_interopDefaultLegacy(crypto);
10
10
 
11
11
  (function() {
12
- const env = {"npm_package_name":"@linear/sdk","npm_package_version":"14.0.0"};
12
+ const env = {"npm_package_name":"@linear/sdk","npm_package_version":"15.0.1"};
13
13
  try {
14
14
  if (process) {
15
15
  process.env = Object.assign({}, process.env);
@@ -1478,12 +1478,24 @@
1478
1478
  OrganizationInviteStatus["Expired"] = "expired";
1479
1479
  OrganizationInviteStatus["Pending"] = "pending";
1480
1480
  })(OrganizationInviteStatus || (OrganizationInviteStatus = {}));
1481
+ /** How to treat NULL values, whether they should appear first or last */
1482
+ var PaginationNulls;
1483
+ (function (PaginationNulls) {
1484
+ PaginationNulls["First"] = "first";
1485
+ PaginationNulls["Last"] = "last";
1486
+ })(PaginationNulls || (PaginationNulls = {}));
1481
1487
  /** By which field should the pagination order by */
1482
1488
  var PaginationOrderBy;
1483
1489
  (function (PaginationOrderBy) {
1484
1490
  PaginationOrderBy["CreatedAt"] = "createdAt";
1485
1491
  PaginationOrderBy["UpdatedAt"] = "updatedAt";
1486
1492
  })(PaginationOrderBy || (PaginationOrderBy = {}));
1493
+ /** Whether to sort in ascending or descending order */
1494
+ var PaginationSortOrder;
1495
+ (function (PaginationSortOrder) {
1496
+ PaginationSortOrder["Ascending"] = "Ascending";
1497
+ PaginationSortOrder["Descending"] = "Descending";
1498
+ })(PaginationSortOrder || (PaginationSortOrder = {}));
1487
1499
  /** A type of project status. */
1488
1500
  var ProjectStatusType;
1489
1501
  (function (ProjectStatusType) {
@@ -3084,6 +3096,7 @@
3084
3096
  kind: "SelectionSet",
3085
3097
  selections: [
3086
3098
  { kind: "Field", name: { kind: "Name", value: "__typename" } },
3099
+ { kind: "Field", name: { kind: "Name", value: "expiresAt" } },
3087
3100
  { kind: "Field", name: { kind: "Name", value: "id" } },
3088
3101
  ],
3089
3102
  },
@@ -9410,6 +9423,14 @@
9410
9423
  selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
9411
9424
  },
9412
9425
  },
9426
+ {
9427
+ kind: "Field",
9428
+ name: { kind: "Name", value: "triageResponsibility" },
9429
+ selectionSet: {
9430
+ kind: "SelectionSet",
9431
+ selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
9432
+ },
9433
+ },
9413
9434
  { kind: "Field", name: { kind: "Name", value: "autoCloseStateId" } },
9414
9435
  { kind: "Field", name: { kind: "Name", value: "cycleCooldownTime" } },
9415
9436
  { kind: "Field", name: { kind: "Name", value: "cycleStartDay" } },
@@ -9849,7 +9870,6 @@
9849
9870
  { kind: "Field", name: { kind: "Name", value: "archivedAt" } },
9850
9871
  { kind: "Field", name: { kind: "Name", value: "createdAt" } },
9851
9872
  { kind: "Field", name: { kind: "Name", value: "id" } },
9852
- { kind: "Field", name: { kind: "Name", value: "error" } },
9853
9873
  ],
9854
9874
  },
9855
9875
  },
@@ -9913,6 +9933,23 @@
9913
9933
  },
9914
9934
  ],
9915
9935
  };
9936
+ const TriageResponsibilityManualSelectionFragmentDoc = {
9937
+ kind: "Document",
9938
+ definitions: [
9939
+ {
9940
+ kind: "FragmentDefinition",
9941
+ name: { kind: "Name", value: "TriageResponsibilityManualSelection" },
9942
+ typeCondition: { kind: "NamedType", name: { kind: "Name", value: "TriageResponsibilityManualSelection" } },
9943
+ selectionSet: {
9944
+ kind: "SelectionSet",
9945
+ selections: [
9946
+ { kind: "Field", name: { kind: "Name", value: "__typename" } },
9947
+ { kind: "Field", name: { kind: "Name", value: "userIds" } },
9948
+ ],
9949
+ },
9950
+ },
9951
+ ],
9952
+ };
9916
9953
  const TriageResponsibilityFragmentDoc = {
9917
9954
  kind: "Document",
9918
9955
  definitions: [
@@ -9924,14 +9961,14 @@
9924
9961
  kind: "SelectionSet",
9925
9962
  selections: [
9926
9963
  { kind: "Field", name: { kind: "Name", value: "__typename" } },
9927
- { kind: "Field", name: { kind: "Name", value: "schedule" } },
9928
- { kind: "Field", name: { kind: "Name", value: "manualSelection" } },
9929
9964
  {
9930
9965
  kind: "Field",
9931
- name: { kind: "Name", value: "integration" },
9966
+ name: { kind: "Name", value: "manualSelection" },
9932
9967
  selectionSet: {
9933
9968
  kind: "SelectionSet",
9934
- selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
9969
+ selections: [
9970
+ { kind: "FragmentSpread", name: { kind: "Name", value: "TriageResponsibilityManualSelection" } },
9971
+ ],
9935
9972
  },
9936
9973
  },
9937
9974
  { kind: "Field", name: { kind: "Name", value: "updatedAt" } },
@@ -9954,6 +9991,14 @@
9954
9991
  },
9955
9992
  },
9956
9993
  { kind: "Field", name: { kind: "Name", value: "id" } },
9994
+ {
9995
+ kind: "Field",
9996
+ name: { kind: "Name", value: "currentUser" },
9997
+ selectionSet: {
9998
+ kind: "SelectionSet",
9999
+ selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
10000
+ },
10001
+ },
9957
10002
  ],
9958
10003
  },
9959
10004
  },
@@ -9991,6 +10036,32 @@
9991
10036
  },
9992
10037
  ],
9993
10038
  };
10039
+ const TriageResponsibilityPayloadFragmentDoc = {
10040
+ kind: "Document",
10041
+ definitions: [
10042
+ {
10043
+ kind: "FragmentDefinition",
10044
+ name: { kind: "Name", value: "TriageResponsibilityPayload" },
10045
+ typeCondition: { kind: "NamedType", name: { kind: "Name", value: "TriageResponsibilityPayload" } },
10046
+ selectionSet: {
10047
+ kind: "SelectionSet",
10048
+ selections: [
10049
+ { kind: "Field", name: { kind: "Name", value: "__typename" } },
10050
+ { kind: "Field", name: { kind: "Name", value: "lastSyncId" } },
10051
+ { kind: "Field", name: { kind: "Name", value: "success" } },
10052
+ {
10053
+ kind: "Field",
10054
+ name: { kind: "Name", value: "triageResponsibility" },
10055
+ selectionSet: {
10056
+ kind: "SelectionSet",
10057
+ selections: [{ kind: "Field", name: { kind: "Name", value: "id" } }],
10058
+ },
10059
+ },
10060
+ ],
10061
+ },
10062
+ },
10063
+ ],
10064
+ };
9994
10065
  const UploadFileHeaderFragmentDoc = {
9995
10066
  kind: "Document",
9996
10067
  definitions: [
@@ -17545,6 +17616,14 @@
17545
17616
  variable: { kind: "Variable", name: { kind: "Name", value: "orderBy" } },
17546
17617
  type: { kind: "NamedType", name: { kind: "Name", value: "PaginationOrderBy" } },
17547
17618
  },
17619
+ {
17620
+ kind: "VariableDefinition",
17621
+ variable: { kind: "Variable", name: { kind: "Name", value: "sort" } },
17622
+ type: {
17623
+ kind: "ListType",
17624
+ type: { kind: "NonNullType", type: { kind: "NamedType", name: { kind: "Name", value: "IssueSortInput" } } },
17625
+ },
17626
+ },
17548
17627
  ],
17549
17628
  selectionSet: {
17550
17629
  kind: "SelectionSet",
@@ -17588,6 +17667,11 @@
17588
17667
  name: { kind: "Name", value: "orderBy" },
17589
17668
  value: { kind: "Variable", name: { kind: "Name", value: "orderBy" } },
17590
17669
  },
17670
+ {
17671
+ kind: "Argument",
17672
+ name: { kind: "Name", value: "sort" },
17673
+ value: { kind: "Variable", name: { kind: "Name", value: "sort" } },
17674
+ },
17591
17675
  ],
17592
17676
  selectionSet: {
17593
17677
  kind: "SelectionSet",
@@ -34515,7 +34599,9 @@
34515
34599
  get OAuthClientApprovalStatus () { return OAuthClientApprovalStatus; },
34516
34600
  get OrganizationDomainAuthType () { return OrganizationDomainAuthType; },
34517
34601
  get OrganizationInviteStatus () { return OrganizationInviteStatus; },
34602
+ get PaginationNulls () { return PaginationNulls; },
34518
34603
  get PaginationOrderBy () { return PaginationOrderBy; },
34604
+ get PaginationSortOrder () { return PaginationSortOrder; },
34519
34605
  get ProjectStatusType () { return ProjectStatusType; },
34520
34606
  get ProjectTab () { return ProjectTab; },
34521
34607
  get ProjectUpdateHealthType () { return ProjectUpdateHealthType; },
@@ -34773,8 +34859,10 @@
34773
34859
  TimeScheduleFragmentDoc: TimeScheduleFragmentDoc,
34774
34860
  TimeScheduleConnectionFragmentDoc: TimeScheduleConnectionFragmentDoc,
34775
34861
  TimeSchedulePayloadFragmentDoc: TimeSchedulePayloadFragmentDoc,
34862
+ TriageResponsibilityManualSelectionFragmentDoc: TriageResponsibilityManualSelectionFragmentDoc,
34776
34863
  TriageResponsibilityFragmentDoc: TriageResponsibilityFragmentDoc,
34777
34864
  TriageResponsibilityConnectionFragmentDoc: TriageResponsibilityConnectionFragmentDoc,
34865
+ TriageResponsibilityPayloadFragmentDoc: TriageResponsibilityPayloadFragmentDoc,
34778
34866
  UploadFileHeaderFragmentDoc: UploadFileHeaderFragmentDoc,
34779
34867
  UploadFileFragmentDoc: UploadFileFragmentDoc,
34780
34868
  UploadPayloadFragmentDoc: UploadPayloadFragmentDoc,
@@ -35771,7 +35859,9 @@
35771
35859
  */
35772
35860
  class AuthOrganizationInvite extends Request {
35773
35861
  constructor(request, data) {
35862
+ var _a;
35774
35863
  super(request);
35864
+ this.expiresAt = (_a = parseDate(data.expiresAt)) !== null && _a !== void 0 ? _a : undefined;
35775
35865
  this.id = data.id;
35776
35866
  }
35777
35867
  }
@@ -41083,18 +41173,17 @@
41083
41173
  */
41084
41174
  class TimeSchedule extends Request {
41085
41175
  constructor(request, data) {
41086
- var _a, _b, _c, _d, _e, _f, _g;
41176
+ var _a, _b, _c, _d, _e, _f;
41087
41177
  super(request);
41088
41178
  this.archivedAt = (_a = parseDate(data.archivedAt)) !== null && _a !== void 0 ? _a : undefined;
41089
41179
  this.createdAt = (_b = parseDate(data.createdAt)) !== null && _b !== void 0 ? _b : new Date();
41090
- this.error = (_c = data.error) !== null && _c !== void 0 ? _c : undefined;
41091
- this.externalId = (_d = data.externalId) !== null && _d !== void 0 ? _d : undefined;
41092
- this.externalUrl = (_e = data.externalUrl) !== null && _e !== void 0 ? _e : undefined;
41180
+ this.externalId = (_c = data.externalId) !== null && _c !== void 0 ? _c : undefined;
41181
+ this.externalUrl = (_d = data.externalUrl) !== null && _d !== void 0 ? _d : undefined;
41093
41182
  this.id = data.id;
41094
41183
  this.name = data.name;
41095
- this.updatedAt = (_f = parseDate(data.updatedAt)) !== null && _f !== void 0 ? _f : new Date();
41184
+ this.updatedAt = (_e = parseDate(data.updatedAt)) !== null && _e !== void 0 ? _e : new Date();
41096
41185
  this.entries = data.entries.map(node => new TimeScheduleEntry(request, node));
41097
- this._integration = (_g = data.integration) !== null && _g !== void 0 ? _g : undefined;
41186
+ this._integration = (_f = data.integration) !== null && _f !== void 0 ? _f : undefined;
41098
41187
  }
41099
41188
  /** The identifier of the Linear integration populating the schedule. */
41100
41189
  get integration() {
@@ -41155,20 +41244,22 @@
41155
41244
  */
41156
41245
  class TriageResponsibility extends Request {
41157
41246
  constructor(request, data) {
41158
- var _a, _b, _c, _d, _e;
41247
+ var _a, _b, _c, _d;
41159
41248
  super(request);
41160
41249
  this.archivedAt = (_a = parseDate(data.archivedAt)) !== null && _a !== void 0 ? _a : undefined;
41161
41250
  this.createdAt = (_b = parseDate(data.createdAt)) !== null && _b !== void 0 ? _b : new Date();
41162
41251
  this.id = data.id;
41163
- this.manualSelection = (_c = data.manualSelection) !== null && _c !== void 0 ? _c : undefined;
41164
- this.schedule = (_d = data.schedule) !== null && _d !== void 0 ? _d : undefined;
41165
- this.updatedAt = (_e = parseDate(data.updatedAt)) !== null && _e !== void 0 ? _e : new Date();
41166
- this._integration = data.integration;
41252
+ this.updatedAt = (_c = parseDate(data.updatedAt)) !== null && _c !== void 0 ? _c : new Date();
41253
+ this.manualSelection = data.manualSelection
41254
+ ? new TriageResponsibilityManualSelection(request, data.manualSelection)
41255
+ : undefined;
41256
+ this._currentUser = (_d = data.currentUser) !== null && _d !== void 0 ? _d : undefined;
41167
41257
  this._team = data.team;
41168
41258
  }
41169
- /** The integration used for scheduling. */
41170
- get integration() {
41171
- return new IntegrationQuery(this._request).fetch(this._integration.id);
41259
+ /** The user currently responsible for triage. */
41260
+ get currentUser() {
41261
+ var _a, _b;
41262
+ return ((_a = this._currentUser) === null || _a === void 0 ? void 0 : _a.id) ? new UserQuery(this._request).fetch((_b = this._currentUser) === null || _b === void 0 ? void 0 : _b.id) : undefined;
41172
41263
  }
41173
41264
  /** The team to which the triage responsibility belongs to. */
41174
41265
  get team() {
@@ -41187,6 +41278,31 @@
41187
41278
  super(request, fetch, data.nodes.map(node => new TriageResponsibility(request, node)), new PageInfo(request, data.pageInfo));
41188
41279
  }
41189
41280
  }
41281
+ /**
41282
+ * TriageResponsibilityManualSelection model
41283
+ *
41284
+ * @param request - function to call the graphql client
41285
+ * @param data - L.TriageResponsibilityManualSelectionFragment response data
41286
+ */
41287
+ class TriageResponsibilityManualSelection extends Request {
41288
+ constructor(request, data) {
41289
+ super(request);
41290
+ this.userIds = data.userIds;
41291
+ }
41292
+ }
41293
+ /**
41294
+ * TriageResponsibilityPayload model
41295
+ *
41296
+ * @param request - function to call the graphql client
41297
+ * @param data - L.TriageResponsibilityPayloadFragment response data
41298
+ */
41299
+ class TriageResponsibilityPayload extends Request {
41300
+ constructor(request, data) {
41301
+ super(request);
41302
+ this.lastSyncId = data.lastSyncId;
41303
+ this.success = data.success;
41304
+ }
41305
+ }
41190
41306
  /**
41191
41307
  * Object representing Google Cloud upload policy, plus additional data.
41192
41308
  *
@@ -54780,6 +54896,8 @@
54780
54896
  exports.TimeSchedulePayload = TimeSchedulePayload;
54781
54897
  exports.TriageResponsibility = TriageResponsibility;
54782
54898
  exports.TriageResponsibilityConnection = TriageResponsibilityConnection;
54899
+ exports.TriageResponsibilityManualSelection = TriageResponsibilityManualSelection;
54900
+ exports.TriageResponsibilityPayload = TriageResponsibilityPayload;
54783
54901
  exports.UnarchiveIssueMutation = UnarchiveIssueMutation;
54784
54902
  exports.UnarchiveNotificationMutation = UnarchiveNotificationMutation;
54785
54903
  exports.UnarchiveProjectMutation = UnarchiveProjectMutation;