@mattermost/types 7.8.0 → 7.10.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.
package/lib/admin.d.ts CHANGED
@@ -9,8 +9,33 @@ import { SamlCertificateStatus, SamlMetadataResponse } from './saml';
9
9
  import { Team } from './teams';
10
10
  import { UserAccessToken, UserProfile } from './users';
11
11
  import { RelationOneToOne } from './utilities';
12
+ export declare enum LogLevelEnum {
13
+ SILLY = "silly",
14
+ DEBUG = "debug",
15
+ INFO = "info",
16
+ WARN = "warn",
17
+ ERROR = "error"
18
+ }
19
+ export declare type LogServerNames = string[];
20
+ export declare type LogLevels = LogLevelEnum[];
21
+ export declare type LogDateFrom = string;
22
+ export declare type LogDateTo = string;
23
+ export declare type LogObject = {
24
+ caller: string;
25
+ job_id: string;
26
+ level: LogLevelEnum;
27
+ msg: string;
28
+ timestamp: string;
29
+ worker: string;
30
+ };
31
+ export declare type LogFilter = {
32
+ serverNames: LogServerNames;
33
+ logLevels: LogLevels;
34
+ dateFrom: LogDateFrom;
35
+ dateTo: LogDateTo;
36
+ };
12
37
  export declare type AdminState = {
13
- logs: string[];
38
+ logs: LogObject[];
14
39
  audits: Record<string, Audit>;
15
40
  config: Partial<AdminConfig>;
16
41
  environmentConfig: Partial<EnvironmentConfig>;
package/lib/admin.js CHANGED
@@ -2,3 +2,12 @@
2
2
  // Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
3
3
  // See LICENSE.txt for license information.
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.LogLevelEnum = void 0;
6
+ var LogLevelEnum;
7
+ (function (LogLevelEnum) {
8
+ LogLevelEnum["SILLY"] = "silly";
9
+ LogLevelEnum["DEBUG"] = "debug";
10
+ LogLevelEnum["INFO"] = "info";
11
+ LogLevelEnum["WARN"] = "warn";
12
+ LogLevelEnum["ERROR"] = "error";
13
+ })(LogLevelEnum = exports.LogLevelEnum || (exports.LogLevelEnum = {}));
package/lib/apps.d.ts CHANGED
@@ -102,7 +102,7 @@ export declare type AppContext = {
102
102
  export declare type AppContextProps = {
103
103
  [name: string]: string;
104
104
  };
105
- export declare type AppExpandLevel = string;
105
+ export declare type AppExpandLevel = '' | 'none' | 'summary' | '+summary' | 'all' | '+all';
106
106
  export declare type AppExpand = {
107
107
  app?: AppExpandLevel;
108
108
  acting_user?: AppExpandLevel;
@@ -114,6 +114,7 @@ export declare type AppExpand = {
114
114
  root_post?: AppExpandLevel;
115
115
  team?: AppExpandLevel;
116
116
  user?: AppExpandLevel;
117
+ locale?: AppExpandLevel;
117
118
  };
118
119
  export declare type AppForm = {
119
120
  title?: string;
package/lib/apps.js CHANGED
@@ -3,9 +3,6 @@
3
3
  // See LICENSE.txt for license information.
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
5
  exports.Locations = exports.Permission = void 0;
6
- // This file's contents belong to the Apps Framework feature.
7
- // Apps Framework feature is experimental, and the contents of this file are
8
- // susceptible to breaking changes without pushing the major version of this package.
9
6
  var Permission;
10
7
  (function (Permission) {
11
8
  Permission["UserJoinedChannelNotification"] = "user_joined_channel_notification";
package/lib/boards.d.ts CHANGED
@@ -1,9 +1,3 @@
1
- export declare type BoardsUsageResponse = {
2
- cards: number;
3
- views: number;
4
- used_cards: number;
5
- card_limit_timestamp: number;
6
- };
7
1
  declare const boardTypes: string[];
8
2
  declare type BoardTypes = typeof boardTypes[number];
9
3
  declare type PropertyTypeEnum = 'text' | 'number' | 'select' | 'multiSelect' | 'date' | 'person' | 'file' | 'checkbox' | 'url' | 'email' | 'phone' | 'createdTime' | 'createdBy' | 'updatedTime' | 'updatedBy' | 'unknown';
@@ -38,20 +32,6 @@ export declare type Board = {
38
32
  updateAt: number;
39
33
  deleteAt: number;
40
34
  };
41
- export declare type BoardTemplate = Board;
42
- export declare type BoardPatch = {
43
- channelId?: string;
44
- type?: BoardTypes;
45
- minimumRole?: string;
46
- title?: string;
47
- description?: string;
48
- icon?: string;
49
- showDescription?: boolean;
50
- updatedProperties?: Record<string, any>;
51
- deletedProperties?: string[];
52
- updatedCardProperties?: IPropertyTemplate[];
53
- deletedCardProperties?: string[];
54
- };
55
35
  export declare type CreateBoardResponse = {
56
36
  boards: Board[];
57
37
  };
package/lib/cloud.d.ts CHANGED
@@ -4,7 +4,7 @@ export declare type CloudState = {
4
4
  products?: Record<string, Product>;
5
5
  customer?: CloudCustomer;
6
6
  invoices?: Record<string, Invoice>;
7
- subscriptionStats?: LicenseExpandReducer;
7
+ subscriptionStats?: LicenseSelfServeStatusReducer;
8
8
  limits: {
9
9
  limitsLoaded: boolean;
10
10
  limits: Limits;
@@ -15,6 +15,7 @@ export declare type CloudState = {
15
15
  customer?: true;
16
16
  invoices?: true;
17
17
  limits?: true;
18
+ trueUpReview?: true;
18
19
  };
19
20
  selfHostedSignup: {
20
21
  progress: ValueOf<typeof SelfHostedSignupProgress>;
@@ -34,6 +35,7 @@ export declare type Subscription = {
34
35
  trial_end_at: number;
35
36
  is_free_trial: string;
36
37
  delinquent_since?: number;
38
+ compliance_blocked?: string;
37
39
  };
38
40
  export declare type Product = {
39
41
  id: string;
@@ -83,11 +85,12 @@ export declare type CloudCustomer = {
83
85
  company_address: Address;
84
86
  payment_method: PaymentMethod;
85
87
  } & CustomerMetadataGatherWireTransfer;
86
- export declare type LicenseExpandStatus = {
87
- is_expandable: boolean;
88
+ export declare type LicenseSelfServeStatus = {
89
+ is_expandable?: boolean;
90
+ is_renewable?: boolean;
88
91
  };
89
92
  declare type RequestState = 'IDLE' | 'LOADING' | 'ERROR' | 'OK';
90
- export interface LicenseExpandReducer extends LicenseExpandStatus {
93
+ export interface LicenseSelfServeStatusReducer extends LicenseSelfServeStatus {
91
94
  getRequestState: RequestState;
92
95
  }
93
96
  export declare type CloudCustomerPatch = {
@@ -157,10 +160,6 @@ export declare type Limits = {
157
160
  teams?: {
158
161
  active?: number;
159
162
  };
160
- boards?: {
161
- cards?: number;
162
- views?: number;
163
- };
164
163
  };
165
164
  export interface CloudUsage {
166
165
  files: {
@@ -171,10 +170,6 @@ export interface CloudUsage {
171
170
  history: number;
172
171
  historyLoaded: boolean;
173
172
  };
174
- boards: {
175
- cards: number;
176
- cardsLoaded: boolean;
177
- };
178
173
  teams: TeamsUsage;
179
174
  }
180
175
  export declare type TeamsUsage = {
@@ -191,4 +186,13 @@ export interface CreateSubscriptionRequest {
191
186
  seats: number;
192
187
  internal_purchase_order?: string;
193
188
  }
189
+ export declare const areShippingDetailsValid: (address: Address | null | undefined) => boolean;
190
+ export declare type Feedback = {
191
+ reason: string;
192
+ comments: string;
193
+ };
194
+ export declare type WorkspaceDeletionRequest = {
195
+ subscription_id: string;
196
+ delete_feedback: Feedback;
197
+ };
194
198
  export {};
package/lib/cloud.js CHANGED
@@ -2,7 +2,7 @@
2
2
  // Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
3
3
  // See LICENSE.txt for license information.
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.InvoiceLineItemType = exports.SelfHostedSignupProgress = exports.TypePurchases = void 0;
5
+ exports.areShippingDetailsValid = exports.InvoiceLineItemType = exports.SelfHostedSignupProgress = exports.TypePurchases = void 0;
6
6
  exports.TypePurchases = {
7
7
  firstSelfHostLicensePurchase: 'first_purchase',
8
8
  renewalSelfHost: 'renewal_self',
@@ -25,3 +25,10 @@ exports.InvoiceLineItemType = {
25
25
  OnPremise: 'onpremise',
26
26
  Metered: 'metered',
27
27
  };
28
+ const areShippingDetailsValid = (address) => {
29
+ if (!address) {
30
+ return false;
31
+ }
32
+ return Boolean(address.city && address.country && address.line1 && address.postal_code && address.state);
33
+ };
34
+ exports.areShippingDetailsValid = areShippingDetailsValid;
package/lib/config.d.ts CHANGED
@@ -13,10 +13,13 @@ export declare type ClientConfig = {
13
13
  BannerColor: string;
14
14
  BannerText: string;
15
15
  BannerTextColor: string;
16
+ BuildBoards: string;
16
17
  BuildDate: string;
17
18
  BuildEnterpriseReady: string;
18
19
  BuildHash: string;
20
+ BuildHashBoards: string;
19
21
  BuildHashEnterprise: string;
22
+ BuildHashPlaybooks: string;
20
23
  BuildNumber: string;
21
24
  CollapsedThreads: CollapsedThreads;
22
25
  CustomBrandText: string;
@@ -110,9 +113,10 @@ export declare type ClientConfig = {
110
113
  ExperimentalTimezone: string;
111
114
  ExperimentalViewArchivedChannels: string;
112
115
  FileLevel: string;
116
+ FeatureFlagAppsEnabled: string;
113
117
  FeatureFlagBoardsProduct: string;
118
+ FeatureFlagCallsEnabled: string;
114
119
  FeatureFlagGraphQL: string;
115
- FeatureFlagAnnualSubscription: string;
116
120
  GfycatAPIKey: string;
117
121
  GfycatAPISecret: string;
118
122
  GoogleDeveloperKey: string;
@@ -173,6 +177,7 @@ export declare type ClientConfig = {
173
177
  SiteURL: string;
174
178
  SQLDriverName: string;
175
179
  SupportEmail: string;
180
+ TelemetryId: string;
176
181
  TeammateNameDisplay: string;
177
182
  TermsOfServiceLink: string;
178
183
  TimeBetweenUserTypingUpdatesMilliseconds: string;
@@ -347,6 +352,7 @@ export declare type ServiceSettings = {
347
352
  EnableCustomGroups: boolean;
348
353
  SelfHostedPurchase: boolean;
349
354
  AllowSyncedDrafts: boolean;
355
+ SelfHostedExpansion: boolean;
350
356
  };
351
357
  export declare type TeamSettings = {
352
358
  SiteName: string;
@@ -405,6 +411,7 @@ export declare type LogSettings = {
405
411
  FileLocation: string;
406
412
  EnableWebhookDebugging: boolean;
407
413
  EnableDiagnostics: boolean;
414
+ VerboseDiagnostics: boolean;
408
415
  EnableSentry: boolean;
409
416
  AdvancedLoggingConfig: string;
410
417
  };
@@ -707,6 +714,9 @@ export declare type ElasticsearchSettings = {
707
714
  BatchSize: number;
708
715
  RequestTimeoutSeconds: number;
709
716
  SkipTLSVerification: boolean;
717
+ CA: string;
718
+ ClientCert: string;
719
+ ClientKey: string;
710
720
  Trace: string;
711
721
  };
712
722
  export declare type BleveSettings = {
@@ -41,6 +41,24 @@ export declare type HostedCustomerState = {
41
41
  errors: {
42
42
  products?: true;
43
43
  invoices?: true;
44
+ trueUpReview?: true;
44
45
  };
45
46
  signupProgress: ValueOf<typeof SelfHostedSignupProgress>;
47
+ trueUpReviewStatus: TrueUpReviewStatusReducer;
48
+ trueUpReviewProfile: TrueUpReviewProfileReducer;
46
49
  };
50
+ export declare type TrueUpReviewProfile = {
51
+ content: string;
52
+ };
53
+ export declare type TrueUpReviewStatus = {
54
+ due_date: number;
55
+ complete: boolean;
56
+ };
57
+ declare type RequestState = 'IDLE' | 'LOADING' | 'OK';
58
+ export interface TrueUpReviewProfileReducer extends TrueUpReviewProfile {
59
+ getRequestState: RequestState;
60
+ }
61
+ export interface TrueUpReviewStatusReducer extends TrueUpReviewStatus {
62
+ getRequestState: RequestState;
63
+ }
64
+ export {};
package/lib/posts.d.ts CHANGED
@@ -4,7 +4,7 @@ import { FileInfo } from './files';
4
4
  import { Reaction } from './reactions';
5
5
  import { UserProfile } from './users';
6
6
  import { RelationOneToOne, RelationOneToMany, IDMappedObjects } from './utilities';
7
- export declare type PostType = 'system_add_remove' | 'system_add_to_channel' | 'system_add_to_team' | 'system_channel_deleted' | 'system_channel_restored' | 'system_displayname_change' | 'system_convert_channel' | 'system_ephemeral' | 'system_header_change' | 'system_join_channel' | 'system_join_leave' | 'system_leave_channel' | 'system_purpose_change' | 'system_remove_from_channel' | 'system_combined_user_activity' | 'system_fake_parent_deleted' | 'system_generic' | '';
7
+ export declare type PostType = 'system_add_remove' | 'system_add_to_channel' | 'system_add_to_team' | 'system_channel_deleted' | 'system_channel_restored' | 'system_displayname_change' | 'system_convert_channel' | 'system_ephemeral' | 'system_header_change' | 'system_join_channel' | 'system_join_leave' | 'system_leave_channel' | 'system_purpose_change' | 'system_remove_from_channel' | 'system_combined_user_activity' | 'system_fake_parent_deleted' | 'system_generic' | 'reminder' | '';
8
8
  export declare type PostEmbedType = 'image' | 'link' | 'message_attachment' | 'opengraph' | 'permalink';
9
9
  export declare type PostEmbed = {
10
10
  type: PostEmbedType;
@@ -106,6 +106,7 @@ export declare type PostsState = {
106
106
  openGraph: RelationOneToOne<Post, Record<string, OpenGraphMetadata>>;
107
107
  pendingPostIds: string[];
108
108
  selectedPostId: string;
109
+ postEditHistory: Post[];
109
110
  currentFocusedPostId: string;
110
111
  messagesHistory: MessageHistory;
111
112
  expandedURLs: Record<string, string>;
package/lib/requests.d.ts CHANGED
@@ -9,7 +9,6 @@ export declare type ChannelsRequestsStatuses = {
9
9
  myChannels: RequestStatusType;
10
10
  createChannel: RequestStatusType;
11
11
  updateChannel: RequestStatusType;
12
- getChannelsAndChannelMembers: RequestStatusType;
13
12
  };
14
13
  export declare type GeneralRequestsStatuses = {
15
14
  websocket: RequestStatusType;
@@ -2,8 +2,24 @@ import { RequireOnlyOne } from './utilities';
2
2
  export declare type WorkTemplatesState = {
3
3
  categories: Category[];
4
4
  templatesInCategory: Record<string, WorkTemplate[]>;
5
- playbookTemplates: [];
5
+ playbookTemplates: PlaybookTemplateType[];
6
+ linkedProducts: Record<string, number>;
6
7
  };
8
+ export interface PlaybookTemplateType {
9
+ title: string;
10
+ template: any;
11
+ }
12
+ export interface ExecuteWorkTemplateRequest {
13
+ team_id: string;
14
+ name: string;
15
+ visibility: Visibility;
16
+ work_template: WorkTemplate;
17
+ playbook_templates?: PlaybookTemplateType[];
18
+ }
19
+ export interface ExecuteWorkTemplateResponse {
20
+ channel_with_playbook_ids: string[];
21
+ channel_ids: string[];
22
+ }
7
23
  export interface WorkTemplate {
8
24
  id: string;
9
25
  category: string;
@@ -22,16 +38,19 @@ export interface Channel {
22
38
  id: string;
23
39
  name: string;
24
40
  illustration: string;
41
+ playbook?: string;
25
42
  }
26
43
  export interface Board {
27
44
  id: string;
28
45
  name: string;
29
46
  illustration: string;
47
+ channel?: string;
30
48
  }
31
49
  export interface Playbook {
32
50
  id: string;
33
51
  name: string;
34
52
  illustration: string;
53
+ template: string;
35
54
  }
36
55
  export interface Integration {
37
56
  id: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mattermost/types",
3
- "version": "7.8.0",
3
+ "version": "7.10.0",
4
4
  "description": "Shared type definitions used by the Mattermost web app",
5
5
  "keywords": [
6
6
  "mattermost"
@@ -14,7 +14,7 @@
14
14
  "./*": "./lib/*.js"
15
15
  },
16
16
  "types": "./lib/*.d.ts",
17
- "respository": {
17
+ "repository": {
18
18
  "type": "git",
19
19
  "url": "github:mattermost/mattermost-webapp",
20
20
  "directory": "packages/types"