wenum 1.92.0 → 1.93.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/dist/index.d.mts CHANGED
@@ -68,15 +68,16 @@ declare const ZeroGameMeta: GameMetaProps;
68
68
 
69
69
  type LeaderboardType = "score" | "duel" | "time" | "distance" | "weight";
70
70
 
71
- type AddingEntityType = "gameToLeaderboard" | "playerToDuelGame" | "playerToNonDuelGame" | "memberToCircle";
72
- type EntityType = "game" | "team" | "collection" | "uoi";
73
-
74
71
  type PlayerType = 'uoi' | 'team' | 'collection';
75
72
 
76
73
  type PostPrivacy = "public" | "private" | "parent" | "internal";
77
74
 
78
75
  type LocationType = "none" | "point" | "street" | "city";
79
76
 
77
+ type AddingEntityType = "gameToLeaderboard" | "playerToDuelGame" | "playerToNonDuelGame" | "memberToCircle";
78
+ type EntityType = "leaderboard" | "team" | "collection" | "uoi";
79
+ declare function getPIDPrefixByEntityType(entityType: EntityType): string;
80
+
80
81
  type PIDPrefixType = 'usr' | 'uoi' | 'tms' | 'arn' | 'evt' | 'col' | 'lbd' | 'gme' | 'mkt' | 'org' | 'lcp' | 'lcs' | 'lcc' | 'lip' | 'lis' | 'lic' | 'txt' | 'img' | 'pol' | 'vid' | '';
81
82
  declare const PID_LENGTH = 9;
82
83
  declare const PID_PREFIX_LENGTH = 3;
@@ -272,4 +273,4 @@ type AvatarR2Folder = 'collection' | 'game' | 'user' | 'team' | 'leaderboard' |
272
273
  declare function getAvatarR2FolderByProfileType(profileType: ProfileType): AvatarR2Folder;
273
274
  declare function getAvatarR2CdnUrl(folder: AvatarR2Folder, pageID: string, imageID: string, size: ImageSize): string;
274
275
 
275
- export { ALL_CARDGAMES_INTERESTS, ALL_INTEREST_CATEGORIES, ALL_LEISURE_INTERESTS, ALL_MUSIC_INTERESTS, ALL_PETS_INTERESTS, ALL_SPORTS_INTERESTS, ALL_TRAVEL_INTERESTS, type AccountStatus, type AddingEntityType, AdminAccountStatus, AttachmentType, AttendanceStatus, type AvatarR2Folder, BasketballPosition, type BroadcastType, type BuddyingStatus, COLLECTION_ATTRIBUTE_LABEL, COLLECTION_PETS_ATTRIBUTE_LABEL, COMMON_ATTRIBUTE_LABEL, type CardGamesInterestType, type CategoryType, ChallengeStatus, type CollectionAttributeType, type CollectionMetaProps, type CollectionMetaStatus, type CollectionOwnerStatus, type CollectionPetsAttributeType, type CollectionPrivacy, type CollectionStatus, type CollectionType, type CommonAttributeType, type CommonMarketType, type DuelGameResultType, type EntityType, type EventsNearbyProps, FollowingStatus, type GameMetaProps, type GameType, type GamesByTypeNearbyProps, type GamesNearbyProps, type Gender, type Handedness, INTERESTS_BY_CATEGORY, type ImageSize, type InterestNearbyProps, type InterestType, type LeaderboardType, type LeaderboardsByGameTypeNearbyProps, type LeisureInterestType, type LengthUnit, type LocationType, type MarketMetaProps, type MarketMetaStatus, type MarketType, type MarketsByTypeNearbyProps, type MemberingStatus, type MusicInterestType, type NearbyProps, type NotificationType, type PIDPrefixType, PID_LENGTH, PID_PREFIX_LENGTH, type PageR2Folder, type PageType, type PetsInterestType, type PlayerType, type PostPrivacy, type ProfilePermission, type ProfilePrivacy, type ProfileStatus, type ProfileType, ReactionType, type SocialMediaType, type SportsInterestType, type SubjectR2Folder, type SubjectType, type TennisBackhand, type TennisLevel, type TravelInterestType, UOI_ATTRIBUTE_LABEL, UOI_SPORTS_ATTRIBUTE_LABEL, UOI_SPORTS_BASKETBALL_ATTRIBUTE_LABEL, UOI_SPORTS_TENNIS_ATTRIBUTE_LABEL, type UoiAttributeType, type UoiSportsAttributeType, type UoiSportsBasketballAttributeType, type UoiSportsTennisAttributeType, type UserPronoun, type WeightUnit, ZeroCollectionMeta, ZeroGameMeta, ZeroMarketOption, getAvatarR2CdnUrl, getAvatarR2FolderByProfileType, getCollectionAttributeLabel, getCommonAttributeLabel, getEntityTypeByPID, getNearbyIndex, getPIDPrefixByProfileType, getPageR2CdnUrl, getProfileTypeByPID, getSubjectR2CdnUrl, getUoiAttributeLabel, isGamePID, isLeaderboardPID, isTeamPID, isUoiPID };
276
+ export { ALL_CARDGAMES_INTERESTS, ALL_INTEREST_CATEGORIES, ALL_LEISURE_INTERESTS, ALL_MUSIC_INTERESTS, ALL_PETS_INTERESTS, ALL_SPORTS_INTERESTS, ALL_TRAVEL_INTERESTS, type AccountStatus, type AddingEntityType, AdminAccountStatus, AttachmentType, AttendanceStatus, type AvatarR2Folder, BasketballPosition, type BroadcastType, type BuddyingStatus, COLLECTION_ATTRIBUTE_LABEL, COLLECTION_PETS_ATTRIBUTE_LABEL, COMMON_ATTRIBUTE_LABEL, type CardGamesInterestType, type CategoryType, ChallengeStatus, type CollectionAttributeType, type CollectionMetaProps, type CollectionMetaStatus, type CollectionOwnerStatus, type CollectionPetsAttributeType, type CollectionPrivacy, type CollectionStatus, type CollectionType, type CommonAttributeType, type CommonMarketType, type DuelGameResultType, type EntityType, type EventsNearbyProps, FollowingStatus, type GameMetaProps, type GameType, type GamesByTypeNearbyProps, type GamesNearbyProps, type Gender, type Handedness, INTERESTS_BY_CATEGORY, type ImageSize, type InterestNearbyProps, type InterestType, type LeaderboardType, type LeaderboardsByGameTypeNearbyProps, type LeisureInterestType, type LengthUnit, type LocationType, type MarketMetaProps, type MarketMetaStatus, type MarketType, type MarketsByTypeNearbyProps, type MemberingStatus, type MusicInterestType, type NearbyProps, type NotificationType, type PIDPrefixType, PID_LENGTH, PID_PREFIX_LENGTH, type PageR2Folder, type PageType, type PetsInterestType, type PlayerType, type PostPrivacy, type ProfilePermission, type ProfilePrivacy, type ProfileStatus, type ProfileType, ReactionType, type SocialMediaType, type SportsInterestType, type SubjectR2Folder, type SubjectType, type TennisBackhand, type TennisLevel, type TravelInterestType, UOI_ATTRIBUTE_LABEL, UOI_SPORTS_ATTRIBUTE_LABEL, UOI_SPORTS_BASKETBALL_ATTRIBUTE_LABEL, UOI_SPORTS_TENNIS_ATTRIBUTE_LABEL, type UoiAttributeType, type UoiSportsAttributeType, type UoiSportsBasketballAttributeType, type UoiSportsTennisAttributeType, type UserPronoun, type WeightUnit, ZeroCollectionMeta, ZeroGameMeta, ZeroMarketOption, getAvatarR2CdnUrl, getAvatarR2FolderByProfileType, getCollectionAttributeLabel, getCommonAttributeLabel, getEntityTypeByPID, getNearbyIndex, getPIDPrefixByEntityType, getPIDPrefixByProfileType, getPageR2CdnUrl, getProfileTypeByPID, getSubjectR2CdnUrl, getUoiAttributeLabel, isGamePID, isLeaderboardPID, isTeamPID, isUoiPID };
package/dist/index.d.ts CHANGED
@@ -68,15 +68,16 @@ declare const ZeroGameMeta: GameMetaProps;
68
68
 
69
69
  type LeaderboardType = "score" | "duel" | "time" | "distance" | "weight";
70
70
 
71
- type AddingEntityType = "gameToLeaderboard" | "playerToDuelGame" | "playerToNonDuelGame" | "memberToCircle";
72
- type EntityType = "game" | "team" | "collection" | "uoi";
73
-
74
71
  type PlayerType = 'uoi' | 'team' | 'collection';
75
72
 
76
73
  type PostPrivacy = "public" | "private" | "parent" | "internal";
77
74
 
78
75
  type LocationType = "none" | "point" | "street" | "city";
79
76
 
77
+ type AddingEntityType = "gameToLeaderboard" | "playerToDuelGame" | "playerToNonDuelGame" | "memberToCircle";
78
+ type EntityType = "leaderboard" | "team" | "collection" | "uoi";
79
+ declare function getPIDPrefixByEntityType(entityType: EntityType): string;
80
+
80
81
  type PIDPrefixType = 'usr' | 'uoi' | 'tms' | 'arn' | 'evt' | 'col' | 'lbd' | 'gme' | 'mkt' | 'org' | 'lcp' | 'lcs' | 'lcc' | 'lip' | 'lis' | 'lic' | 'txt' | 'img' | 'pol' | 'vid' | '';
81
82
  declare const PID_LENGTH = 9;
82
83
  declare const PID_PREFIX_LENGTH = 3;
@@ -272,4 +273,4 @@ type AvatarR2Folder = 'collection' | 'game' | 'user' | 'team' | 'leaderboard' |
272
273
  declare function getAvatarR2FolderByProfileType(profileType: ProfileType): AvatarR2Folder;
273
274
  declare function getAvatarR2CdnUrl(folder: AvatarR2Folder, pageID: string, imageID: string, size: ImageSize): string;
274
275
 
275
- export { ALL_CARDGAMES_INTERESTS, ALL_INTEREST_CATEGORIES, ALL_LEISURE_INTERESTS, ALL_MUSIC_INTERESTS, ALL_PETS_INTERESTS, ALL_SPORTS_INTERESTS, ALL_TRAVEL_INTERESTS, type AccountStatus, type AddingEntityType, AdminAccountStatus, AttachmentType, AttendanceStatus, type AvatarR2Folder, BasketballPosition, type BroadcastType, type BuddyingStatus, COLLECTION_ATTRIBUTE_LABEL, COLLECTION_PETS_ATTRIBUTE_LABEL, COMMON_ATTRIBUTE_LABEL, type CardGamesInterestType, type CategoryType, ChallengeStatus, type CollectionAttributeType, type CollectionMetaProps, type CollectionMetaStatus, type CollectionOwnerStatus, type CollectionPetsAttributeType, type CollectionPrivacy, type CollectionStatus, type CollectionType, type CommonAttributeType, type CommonMarketType, type DuelGameResultType, type EntityType, type EventsNearbyProps, FollowingStatus, type GameMetaProps, type GameType, type GamesByTypeNearbyProps, type GamesNearbyProps, type Gender, type Handedness, INTERESTS_BY_CATEGORY, type ImageSize, type InterestNearbyProps, type InterestType, type LeaderboardType, type LeaderboardsByGameTypeNearbyProps, type LeisureInterestType, type LengthUnit, type LocationType, type MarketMetaProps, type MarketMetaStatus, type MarketType, type MarketsByTypeNearbyProps, type MemberingStatus, type MusicInterestType, type NearbyProps, type NotificationType, type PIDPrefixType, PID_LENGTH, PID_PREFIX_LENGTH, type PageR2Folder, type PageType, type PetsInterestType, type PlayerType, type PostPrivacy, type ProfilePermission, type ProfilePrivacy, type ProfileStatus, type ProfileType, ReactionType, type SocialMediaType, type SportsInterestType, type SubjectR2Folder, type SubjectType, type TennisBackhand, type TennisLevel, type TravelInterestType, UOI_ATTRIBUTE_LABEL, UOI_SPORTS_ATTRIBUTE_LABEL, UOI_SPORTS_BASKETBALL_ATTRIBUTE_LABEL, UOI_SPORTS_TENNIS_ATTRIBUTE_LABEL, type UoiAttributeType, type UoiSportsAttributeType, type UoiSportsBasketballAttributeType, type UoiSportsTennisAttributeType, type UserPronoun, type WeightUnit, ZeroCollectionMeta, ZeroGameMeta, ZeroMarketOption, getAvatarR2CdnUrl, getAvatarR2FolderByProfileType, getCollectionAttributeLabel, getCommonAttributeLabel, getEntityTypeByPID, getNearbyIndex, getPIDPrefixByProfileType, getPageR2CdnUrl, getProfileTypeByPID, getSubjectR2CdnUrl, getUoiAttributeLabel, isGamePID, isLeaderboardPID, isTeamPID, isUoiPID };
276
+ export { ALL_CARDGAMES_INTERESTS, ALL_INTEREST_CATEGORIES, ALL_LEISURE_INTERESTS, ALL_MUSIC_INTERESTS, ALL_PETS_INTERESTS, ALL_SPORTS_INTERESTS, ALL_TRAVEL_INTERESTS, type AccountStatus, type AddingEntityType, AdminAccountStatus, AttachmentType, AttendanceStatus, type AvatarR2Folder, BasketballPosition, type BroadcastType, type BuddyingStatus, COLLECTION_ATTRIBUTE_LABEL, COLLECTION_PETS_ATTRIBUTE_LABEL, COMMON_ATTRIBUTE_LABEL, type CardGamesInterestType, type CategoryType, ChallengeStatus, type CollectionAttributeType, type CollectionMetaProps, type CollectionMetaStatus, type CollectionOwnerStatus, type CollectionPetsAttributeType, type CollectionPrivacy, type CollectionStatus, type CollectionType, type CommonAttributeType, type CommonMarketType, type DuelGameResultType, type EntityType, type EventsNearbyProps, FollowingStatus, type GameMetaProps, type GameType, type GamesByTypeNearbyProps, type GamesNearbyProps, type Gender, type Handedness, INTERESTS_BY_CATEGORY, type ImageSize, type InterestNearbyProps, type InterestType, type LeaderboardType, type LeaderboardsByGameTypeNearbyProps, type LeisureInterestType, type LengthUnit, type LocationType, type MarketMetaProps, type MarketMetaStatus, type MarketType, type MarketsByTypeNearbyProps, type MemberingStatus, type MusicInterestType, type NearbyProps, type NotificationType, type PIDPrefixType, PID_LENGTH, PID_PREFIX_LENGTH, type PageR2Folder, type PageType, type PetsInterestType, type PlayerType, type PostPrivacy, type ProfilePermission, type ProfilePrivacy, type ProfileStatus, type ProfileType, ReactionType, type SocialMediaType, type SportsInterestType, type SubjectR2Folder, type SubjectType, type TennisBackhand, type TennisLevel, type TravelInterestType, UOI_ATTRIBUTE_LABEL, UOI_SPORTS_ATTRIBUTE_LABEL, UOI_SPORTS_BASKETBALL_ATTRIBUTE_LABEL, UOI_SPORTS_TENNIS_ATTRIBUTE_LABEL, type UoiAttributeType, type UoiSportsAttributeType, type UoiSportsBasketballAttributeType, type UoiSportsTennisAttributeType, type UserPronoun, type WeightUnit, ZeroCollectionMeta, ZeroGameMeta, ZeroMarketOption, getAvatarR2CdnUrl, getAvatarR2FolderByProfileType, getCollectionAttributeLabel, getCommonAttributeLabel, getEntityTypeByPID, getNearbyIndex, getPIDPrefixByEntityType, getPIDPrefixByProfileType, getPageR2CdnUrl, getProfileTypeByPID, getSubjectR2CdnUrl, getUoiAttributeLabel, isGamePID, isLeaderboardPID, isTeamPID, isUoiPID };
package/dist/index.js CHANGED
@@ -53,6 +53,7 @@ __export(index_exports, {
53
53
  getCommonAttributeLabel: () => getCommonAttributeLabel,
54
54
  getEntityTypeByPID: () => getEntityTypeByPID,
55
55
  getNearbyIndex: () => getNearbyIndex,
56
+ getPIDPrefixByEntityType: () => getPIDPrefixByEntityType,
56
57
  getPIDPrefixByProfileType: () => getPIDPrefixByProfileType,
57
58
  getPageR2CdnUrl: () => getPageR2CdnUrl,
58
59
  getProfileTypeByPID: () => getProfileTypeByPID,
@@ -140,8 +141,8 @@ function getProfileTypeByPID(pid) {
140
141
  function getEntityTypeByPID(pid) {
141
142
  const prefix = getPIDPrefix(pid);
142
143
  switch (prefix) {
143
- case "gme":
144
- return "game";
144
+ case "lbd":
145
+ return "leaderboard";
145
146
  case "tms":
146
147
  return "team";
147
148
  case "col":
@@ -205,6 +206,22 @@ var AttachmentType = /* @__PURE__ */ ((AttachmentType2) => {
205
206
  return AttachmentType2;
206
207
  })(AttachmentType || {});
207
208
 
209
+ // src/page/entity.ts
210
+ function getPIDPrefixByEntityType(entityType) {
211
+ switch (entityType) {
212
+ case "uoi":
213
+ return "uoi";
214
+ case "team":
215
+ return "tms";
216
+ case "leaderboard":
217
+ return "lbd";
218
+ case "collection":
219
+ return "col";
220
+ default:
221
+ return "";
222
+ }
223
+ }
224
+
208
225
  // src/auth.ts
209
226
  var AdminAccountStatus = /* @__PURE__ */ ((AdminAccountStatus2) => {
210
227
  AdminAccountStatus2[AdminAccountStatus2["None"] = 0] = "None";
@@ -506,6 +523,7 @@ function getAvatarR2CdnUrl(folder, pageID, imageID, size) {
506
523
  getCommonAttributeLabel,
507
524
  getEntityTypeByPID,
508
525
  getNearbyIndex,
526
+ getPIDPrefixByEntityType,
509
527
  getPIDPrefixByProfileType,
510
528
  getPageR2CdnUrl,
511
529
  getProfileTypeByPID,
package/dist/index.mjs CHANGED
@@ -73,8 +73,8 @@ function getProfileTypeByPID(pid) {
73
73
  function getEntityTypeByPID(pid) {
74
74
  const prefix = getPIDPrefix(pid);
75
75
  switch (prefix) {
76
- case "gme":
77
- return "game";
76
+ case "lbd":
77
+ return "leaderboard";
78
78
  case "tms":
79
79
  return "team";
80
80
  case "col":
@@ -138,6 +138,22 @@ var AttachmentType = /* @__PURE__ */ ((AttachmentType2) => {
138
138
  return AttachmentType2;
139
139
  })(AttachmentType || {});
140
140
 
141
+ // src/page/entity.ts
142
+ function getPIDPrefixByEntityType(entityType) {
143
+ switch (entityType) {
144
+ case "uoi":
145
+ return "uoi";
146
+ case "team":
147
+ return "tms";
148
+ case "leaderboard":
149
+ return "lbd";
150
+ case "collection":
151
+ return "col";
152
+ default:
153
+ return "";
154
+ }
155
+ }
156
+
141
157
  // src/auth.ts
142
158
  var AdminAccountStatus = /* @__PURE__ */ ((AdminAccountStatus2) => {
143
159
  AdminAccountStatus2[AdminAccountStatus2["None"] = 0] = "None";
@@ -438,6 +454,7 @@ export {
438
454
  getCommonAttributeLabel,
439
455
  getEntityTypeByPID,
440
456
  getNearbyIndex,
457
+ getPIDPrefixByEntityType,
441
458
  getPIDPrefixByProfileType,
442
459
  getPageR2CdnUrl,
443
460
  getProfileTypeByPID,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wenum",
3
- "version": "1.92.0",
3
+ "version": "1.93.0",
4
4
  "main": "dist/index.js",
5
5
  "module": "dist/index.mjs",
6
6
  "types": "dist/index.d.ts",
@@ -0,0 +1,22 @@
1
+ export type AddingEntityType =
2
+ "gameToLeaderboard" |
3
+ "playerToDuelGame" |
4
+ "playerToNonDuelGame" |
5
+ "memberToCircle";
6
+
7
+ export type EntityType = "leaderboard" | "team" | "collection" | "uoi";
8
+
9
+ export function getPIDPrefixByEntityType(entityType: EntityType): string {
10
+ switch (entityType) {
11
+ case 'uoi':
12
+ return 'uoi';
13
+ case 'team':
14
+ return 'tms';
15
+ case 'leaderboard':
16
+ return 'lbd';
17
+ case 'collection':
18
+ return 'col';
19
+ default:
20
+ return '';
21
+ }
22
+ }
package/src/page/index.ts CHANGED
@@ -7,3 +7,4 @@ export * from './broadcast';
7
7
  export * from './collection';
8
8
  export * from './nearby';
9
9
  export * from './attachment';
10
+ export * from './entity';
package/src/page/pid.ts CHANGED
@@ -1,4 +1,5 @@
1
- import { ProfileType, EntityType } from './profile';
1
+ import { EntityType } from './entity';
2
+ import { ProfileType } from './profile';
2
3
 
3
4
  export type PIDPrefixType =
4
5
  'usr' | 'uoi' | 'tms' | 'arn' | 'evt' | 'col' | 'lbd' | 'gme' | 'mkt' | 'org'
@@ -54,8 +55,8 @@ export function getProfileTypeByPID(pid: string): ProfileType {
54
55
  export function getEntityTypeByPID(pid: string): EntityType | undefined {
55
56
  const prefix = getPIDPrefix(pid);
56
57
  switch (prefix) {
57
- case 'gme':
58
- return 'game';
58
+ case 'lbd':
59
+ return 'leaderboard';
59
60
  case 'tms':
60
61
  return 'team';
61
62
  case 'col':
@@ -4,5 +4,4 @@ export * from './user';
4
4
  export * from './event';
5
5
  export * from './game';
6
6
  export * from './leaderboard';
7
- export * from './addingEntity';
8
7
  export * from './player';
@@ -1,18 +1,16 @@
1
1
  export type ProfileType =
2
2
  "none" |
3
3
  "user" |
4
- "uoi" |
5
- "market"|
6
- "arena"|
7
- "organization"|
4
+ "uoi" |
5
+ "market"|
6
+ "arena"|
7
+ "organization"|
8
8
  "event"|
9
9
  "team"|
10
10
  "leaderboard" |
11
11
  "game"
12
12
 
13
13
 
14
-
15
-
16
14
  export type ProfilePrivacy =
17
15
  "public" |
18
16
  "private" |
@@ -1,7 +0,0 @@
1
- export type AddingEntityType =
2
- "gameToLeaderboard" |
3
- "playerToDuelGame" |
4
- "playerToNonDuelGame" |
5
- "memberToCircle";
6
-
7
- export type EntityType = "game" | "team" | "collection" | "uoi";