mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-05-06 22:46:06 +02:00
chore: Add code folding regions to app.js for better organization
I thought it would be nice for app.js to roleplay as an organized code file. So I made a regex to prepend all existing manually commented code areas such as "App: FriendLog" with #region so that VSCode can fold them. There were a couple uncommented regions that are now commented with summaries I can only describe as 'I tried'
This commit is contained in:
+166
-88
@@ -4,6 +4,7 @@
|
|||||||
// This work is licensed under the terms of the MIT license.
|
// This work is licensed under the terms of the MIT license.
|
||||||
// For a copy, see <https://opensource.org/licenses/MIT>.
|
// For a copy, see <https://opensource.org/licenses/MIT>.
|
||||||
|
|
||||||
|
// #region | Imports
|
||||||
import '@fontsource/noto-sans-kr';
|
import '@fontsource/noto-sans-kr';
|
||||||
import '@fontsource/noto-sans-jp';
|
import '@fontsource/noto-sans-jp';
|
||||||
import Noty from 'noty';
|
import Noty from 'noty';
|
||||||
@@ -24,11 +25,15 @@ import security from './security.js';
|
|||||||
import database from './repository/database.js';
|
import database from './repository/database.js';
|
||||||
import * as localizedStrings from './localization/localizedStrings.js';
|
import * as localizedStrings from './localization/localizedStrings.js';
|
||||||
|
|
||||||
|
// #endregion
|
||||||
|
|
||||||
speechSynthesis.getVoices();
|
speechSynthesis.getVoices();
|
||||||
|
|
||||||
|
// #region | Hey look it's most of VRCX!
|
||||||
(async function () {
|
(async function () {
|
||||||
var $app = null;
|
var $app = null;
|
||||||
|
|
||||||
|
// #region | Init
|
||||||
await CefSharp.BindObjectAsync(
|
await CefSharp.BindObjectAsync(
|
||||||
'AppApi',
|
'AppApi',
|
||||||
'WebApi',
|
'WebApi',
|
||||||
@@ -42,6 +47,7 @@ speechSynthesis.getVoices();
|
|||||||
|
|
||||||
await configRepository.init();
|
await configRepository.init();
|
||||||
|
|
||||||
|
// #region | Init: Migrate old legacy database data to new format
|
||||||
if (configRepository.getBool('migrate_config_20201101') === null) {
|
if (configRepository.getBool('migrate_config_20201101') === null) {
|
||||||
var legacyConfigKeys = [
|
var legacyConfigKeys = [
|
||||||
'orderFriendGroup0',
|
'orderFriendGroup0',
|
||||||
@@ -72,6 +78,8 @@ speechSynthesis.getVoices();
|
|||||||
configRepository.setBool('migrate_config_20201101', true);
|
configRepository.setBool('migrate_config_20201101', true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// #endregion
|
||||||
|
// #region | Init: drop/keyup event listeners
|
||||||
// Make sure file drops outside of the screenshot manager don't navigate to the file path dropped.
|
// Make sure file drops outside of the screenshot manager don't navigate to the file path dropped.
|
||||||
// This issue persists on prompts created with prompt(), unfortunately. Not sure how to fix that.
|
// This issue persists on prompts created with prompt(), unfortunately. Not sure how to fix that.
|
||||||
document.body.addEventListener('drop', function (e) {
|
document.body.addEventListener('drop', function (e) {
|
||||||
@@ -97,6 +105,8 @@ speechSynthesis.getVoices();
|
|||||||
$app.screenshotMetadataCarouselChange(carouselNavigation);
|
$app.screenshotMetadataCarouselChange(carouselNavigation);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
// #endregion
|
||||||
|
// #region | Init: Define VRCX database helper functions, flush timer
|
||||||
|
|
||||||
VRCXStorage.GetArray = async function (key) {
|
VRCXStorage.GetArray = async function (key) {
|
||||||
try {
|
try {
|
||||||
@@ -133,6 +143,8 @@ speechSynthesis.getVoices();
|
|||||||
workerTimers.setInterval(function () {
|
workerTimers.setInterval(function () {
|
||||||
VRCXStorage.Flush();
|
VRCXStorage.Flush();
|
||||||
}, 5 * 60 * 1000);
|
}, 5 * 60 * 1000);
|
||||||
|
// #endregion
|
||||||
|
// #region | Init: Noty, Vue, Vue-Markdown, ElementUI, VueI18n, VueLazyLoad, Vue filters, dark stylesheet
|
||||||
|
|
||||||
Noty.overrideDefaults({
|
Noty.overrideDefaults({
|
||||||
animation: {
|
animation: {
|
||||||
@@ -241,10 +253,8 @@ speechSynthesis.getVoices();
|
|||||||
$appDarkStyle.rel = 'stylesheet';
|
$appDarkStyle.rel = 'stylesheet';
|
||||||
$appDarkStyle.href = `app.dark.css?_=${Date.now()}`;
|
$appDarkStyle.href = `app.dark.css?_=${Date.now()}`;
|
||||||
document.head.appendChild($appDarkStyle);
|
document.head.appendChild($appDarkStyle);
|
||||||
|
// #endregion
|
||||||
//
|
// #region | Init: Languages
|
||||||
// Languages
|
|
||||||
//
|
|
||||||
|
|
||||||
var subsetOfLanguages = {
|
var subsetOfLanguages = {
|
||||||
eng: 'English',
|
eng: 'English',
|
||||||
@@ -310,11 +320,11 @@ speechSynthesis.getVoices();
|
|||||||
fsl: 'fr',
|
fsl: 'fr',
|
||||||
kvk: 'kr'
|
kvk: 'kr'
|
||||||
};
|
};
|
||||||
|
// #endregion
|
||||||
|
// #endregion
|
||||||
|
// #region | API: This is NOT all the api functions, not even close :(
|
||||||
|
|
||||||
//
|
// #region | API: Base
|
||||||
// API
|
|
||||||
//
|
|
||||||
|
|
||||||
var API = {};
|
var API = {};
|
||||||
|
|
||||||
API.eventHandlers = new Map();
|
API.eventHandlers = new Map();
|
||||||
@@ -670,7 +680,8 @@ speechSynthesis.getVoices();
|
|||||||
.then((args) => this.$bulk(options, args));
|
.then((args) => this.$bulk(options, args));
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: Config
|
// #endregion
|
||||||
|
// #region | API: Config
|
||||||
|
|
||||||
API.cachedConfig = {};
|
API.cachedConfig = {};
|
||||||
|
|
||||||
@@ -699,7 +710,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: Location
|
// #endregion
|
||||||
|
// #region | API: Location
|
||||||
|
|
||||||
API.parseLocation = function (tag) {
|
API.parseLocation = function (tag) {
|
||||||
var _tag = String(tag || '');
|
var _tag = String(tag || '');
|
||||||
@@ -1184,7 +1196,8 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// API: User
|
// #endregion
|
||||||
|
// #region | API: User
|
||||||
|
|
||||||
// changeUserName: PUT users/${userId} {displayName: string, currentPassword: string}
|
// changeUserName: PUT users/${userId} {displayName: string, currentPassword: string}
|
||||||
// changeUserEmail: PUT users/${userId} {email: string, currentPassword: string}
|
// changeUserEmail: PUT users/${userId} {email: string, currentPassword: string}
|
||||||
@@ -1960,7 +1973,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: World
|
// #endregion
|
||||||
|
// #region | API: World
|
||||||
|
|
||||||
API.cachedWorlds = new Map();
|
API.cachedWorlds = new Map();
|
||||||
|
|
||||||
@@ -2360,7 +2374,8 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// API: Friend
|
// #endregion
|
||||||
|
// #region | API: Friend
|
||||||
|
|
||||||
API.$on('FRIEND:LIST', function (args) {
|
API.$on('FRIEND:LIST', function (args) {
|
||||||
for (var json of args.json) {
|
for (var json of args.json) {
|
||||||
@@ -2544,7 +2559,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: Avatar
|
// #endregion
|
||||||
|
// #region | API: Avatar
|
||||||
|
|
||||||
API.cachedAvatars = new Map();
|
API.cachedAvatars = new Map();
|
||||||
|
|
||||||
@@ -2754,7 +2770,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: Notification
|
// #endregion
|
||||||
|
// #region | API: Notification
|
||||||
|
|
||||||
API.isNotificationsLoading = false;
|
API.isNotificationsLoading = false;
|
||||||
|
|
||||||
@@ -3271,7 +3288,8 @@ speechSynthesis.getVoices();
|
|||||||
return '';
|
return '';
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: PlayerModeration
|
// #endregion
|
||||||
|
// #region | API: PlayerModeration
|
||||||
|
|
||||||
API.cachedPlayerModerations = new Map();
|
API.cachedPlayerModerations = new Map();
|
||||||
API.isPlayerModerationsLoading = false;
|
API.isPlayerModerationsLoading = false;
|
||||||
@@ -3444,7 +3462,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: AvatarModeration
|
// #endregion
|
||||||
|
// #region | API: AvatarModeration
|
||||||
|
|
||||||
API.cachedAvatarModerations = new Map();
|
API.cachedAvatarModerations = new Map();
|
||||||
|
|
||||||
@@ -3564,7 +3583,8 @@ speechSynthesis.getVoices();
|
|||||||
return ref;
|
return ref;
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: Favorite
|
// #endregion
|
||||||
|
// #region | API: Favorite
|
||||||
|
|
||||||
API.cachedFavorites = new Map();
|
API.cachedFavorites = new Map();
|
||||||
API.cachedFavoritesByObjectId = new Map();
|
API.cachedFavoritesByObjectId = new Map();
|
||||||
@@ -4275,7 +4295,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: WebSocket
|
// #endregion
|
||||||
|
// #region | API: WebSocket
|
||||||
|
|
||||||
API.webSocket = null;
|
API.webSocket = null;
|
||||||
|
|
||||||
@@ -4659,7 +4680,8 @@ speechSynthesis.getVoices();
|
|||||||
} catch (err) { }
|
} catch (err) { }
|
||||||
};
|
};
|
||||||
|
|
||||||
// API: Visit
|
// #endregion
|
||||||
|
// #region | API: Visit
|
||||||
|
|
||||||
API.getVisits = function () {
|
API.getVisits = function () {
|
||||||
return this.call('visits', {
|
return this.call('visits', {
|
||||||
@@ -4673,8 +4695,14 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// #endregion
|
||||||
// API
|
// API
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// #endregion
|
||||||
|
// #region | Misc
|
||||||
|
|
||||||
var extractFileId = (s) => {
|
var extractFileId = (s) => {
|
||||||
var match = String(s).match(/file_[0-9A-Za-z-]+/);
|
var match = String(s).match(/file_[0-9A-Za-z-]+/);
|
||||||
return match ? match[0] : '';
|
return match ? match[0] : '';
|
||||||
@@ -4747,8 +4775,6 @@ speechSynthesis.getVoices();
|
|||||||
return node;
|
return node;
|
||||||
};
|
};
|
||||||
|
|
||||||
// Misc
|
|
||||||
|
|
||||||
var $timers = [];
|
var $timers = [];
|
||||||
|
|
||||||
Vue.component('timer', {
|
Vue.component('timer', {
|
||||||
@@ -4849,7 +4875,8 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
}, 5000);
|
}, 5000);
|
||||||
|
|
||||||
// initialise
|
// #endregion
|
||||||
|
// #region | initialise ... stuff. Don't look at me, I don't work here
|
||||||
|
|
||||||
var $app = {
|
var $app = {
|
||||||
data: {
|
data: {
|
||||||
@@ -5940,8 +5967,7 @@ speechSynthesis.getVoices();
|
|||||||
break;
|
break;
|
||||||
case 'invite':
|
case 'invite':
|
||||||
this.speak(
|
this.speak(
|
||||||
`${
|
`${noty.senderUsername
|
||||||
noty.senderUsername
|
|
||||||
} has invited you to ${this.displayLocation(
|
} has invited you to ${this.displayLocation(
|
||||||
noty.details.worldId,
|
noty.details.worldId,
|
||||||
noty.details.worldName
|
noty.details.worldName
|
||||||
@@ -5999,8 +6025,7 @@ speechSynthesis.getVoices();
|
|||||||
case 'PortalSpawn':
|
case 'PortalSpawn':
|
||||||
if (noty.displayName) {
|
if (noty.displayName) {
|
||||||
this.speak(
|
this.speak(
|
||||||
`${
|
`${noty.displayName
|
||||||
noty.displayName
|
|
||||||
} has spawned a portal to ${this.displayLocation(
|
} has spawned a portal to ${this.displayLocation(
|
||||||
noty.instanceId,
|
noty.instanceId,
|
||||||
noty.worldName
|
noty.worldName
|
||||||
@@ -6123,8 +6148,7 @@ speechSynthesis.getVoices();
|
|||||||
case 'invite':
|
case 'invite':
|
||||||
AppApi.XSNotification(
|
AppApi.XSNotification(
|
||||||
'VRCX',
|
'VRCX',
|
||||||
`${
|
`${noty.senderUsername
|
||||||
noty.senderUsername
|
|
||||||
} has invited you to ${this.displayLocation(
|
} has invited you to ${this.displayLocation(
|
||||||
noty.details.worldId,
|
noty.details.worldId,
|
||||||
noty.details.worldName
|
noty.details.worldName
|
||||||
@@ -6213,8 +6237,7 @@ speechSynthesis.getVoices();
|
|||||||
if (noty.displayName) {
|
if (noty.displayName) {
|
||||||
AppApi.XSNotification(
|
AppApi.XSNotification(
|
||||||
'VRCX',
|
'VRCX',
|
||||||
`${
|
`${noty.displayName
|
||||||
noty.displayName
|
|
||||||
} has spawned a portal to ${this.displayLocation(
|
} has spawned a portal to ${this.displayLocation(
|
||||||
noty.instanceId,
|
noty.instanceId,
|
||||||
noty.worldName
|
noty.worldName
|
||||||
@@ -7371,7 +7394,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Friends
|
// #endregion
|
||||||
|
// #region | App: Friends
|
||||||
|
|
||||||
$app.data.friends = new Map();
|
$app.data.friends = new Map();
|
||||||
$app.data.pendingActiveFriends = new Set();
|
$app.data.pendingActiveFriends = new Set();
|
||||||
@@ -8354,7 +8378,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Quick Search
|
// #endregion
|
||||||
|
// #region | App: Quick Search
|
||||||
|
|
||||||
$app.data.quickSearch = '';
|
$app.data.quickSearch = '';
|
||||||
$app.data.quickSearchItems = [];
|
$app.data.quickSearchItems = [];
|
||||||
@@ -8442,7 +8467,8 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Quick Search User History
|
// #endregion
|
||||||
|
// #region | App: Quick Search User History
|
||||||
|
|
||||||
$app.data.showUserDialogHistory = new Set();
|
$app.data.showUserDialogHistory = new Set();
|
||||||
|
|
||||||
@@ -8464,7 +8490,8 @@ speechSynthesis.getVoices();
|
|||||||
this.quickSearchItems = results;
|
this.quickSearchItems = results;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Feed
|
// #endregion
|
||||||
|
// #region | App: Feed
|
||||||
|
|
||||||
$app.methods.feedSearch = function (row) {
|
$app.methods.feedSearch = function (row) {
|
||||||
var value = this.feedTable.search.toUpperCase();
|
var value = this.feedTable.search.toUpperCase();
|
||||||
@@ -8979,7 +9006,8 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: gameLog
|
// #endregion
|
||||||
|
// #region | App: gameLog
|
||||||
|
|
||||||
$app.data.lastLocation = {
|
$app.data.lastLocation = {
|
||||||
date: 0,
|
date: 0,
|
||||||
@@ -10522,8 +10550,7 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
if (this.debugPhotonLogging) {
|
if (this.debugPhotonLogging) {
|
||||||
var displayName = this.getDisplayNameFromPhotonId(senderId);
|
var displayName = this.getDisplayNameFromPhotonId(senderId);
|
||||||
var feed = `RPC ${displayName} ${
|
var feed = `RPC ${displayName} ${this.photonEventType[eventData.EventType]
|
||||||
this.photonEventType[eventData.EventType]
|
|
||||||
}${eventName}`;
|
}${eventName}`;
|
||||||
console.log('VrcRpc:', feed);
|
console.log('VrcRpc:', feed);
|
||||||
}
|
}
|
||||||
@@ -11838,7 +11865,8 @@ speechSynthesis.getVoices();
|
|||||||
this.$refs.menu.activeIndex = 'search';
|
this.$refs.menu.activeIndex = 'search';
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Search
|
// #endregion
|
||||||
|
// #region | App: Search
|
||||||
|
|
||||||
$app.data.searchText = '';
|
$app.data.searchText = '';
|
||||||
$app.data.searchUserResults = [];
|
$app.data.searchUserResults = [];
|
||||||
@@ -12144,7 +12172,8 @@ speechSynthesis.getVoices();
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Favorite
|
// #endregion
|
||||||
|
// #region | App: Favorite
|
||||||
|
|
||||||
$app.data.favoriteObjects = new Map();
|
$app.data.favoriteObjects = new Map();
|
||||||
$app.data.favoriteFriends_ = [];
|
$app.data.favoriteFriends_ = [];
|
||||||
@@ -12430,7 +12459,8 @@ speechSynthesis.getVoices();
|
|||||||
return this.favoriteAvatarsSorted;
|
return this.favoriteAvatarsSorted;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: friendLog
|
// #endregion
|
||||||
|
// #region | App: friendLog
|
||||||
|
|
||||||
$app.data.friendLog = new Map();
|
$app.data.friendLog = new Map();
|
||||||
$app.data.friendLogTable = {
|
$app.data.friendLogTable = {
|
||||||
@@ -12765,7 +12795,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Moderation
|
// #endregion
|
||||||
|
// #region | App: Moderation
|
||||||
|
|
||||||
$app.data.playerModerationTable = {
|
$app.data.playerModerationTable = {
|
||||||
data: [],
|
data: [],
|
||||||
@@ -12850,7 +12881,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Notification
|
// #endregion
|
||||||
|
// #region | App: Notification
|
||||||
|
|
||||||
$app.data.notificationTable = {
|
$app.data.notificationTable = {
|
||||||
data: [],
|
data: [],
|
||||||
@@ -13077,7 +13109,8 @@ speechSynthesis.getVoices();
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
// App: Profile + Settings
|
// #endregion
|
||||||
|
// #region | App: Profile + Settings
|
||||||
|
|
||||||
$app.data.configTreeData = [];
|
$app.data.configTreeData = [];
|
||||||
$app.data.currentUserTreeData = [];
|
$app.data.currentUserTreeData = [];
|
||||||
@@ -14730,7 +14763,8 @@ speechSynthesis.getVoices();
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Dialog
|
// #endregion
|
||||||
|
// #region | App: Dialog
|
||||||
|
|
||||||
var adjustDialogZ = (el) => {
|
var adjustDialogZ = (el) => {
|
||||||
var z = 0;
|
var z = 0;
|
||||||
@@ -14747,7 +14781,8 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: User Dialog
|
// #endregion
|
||||||
|
// #region | App: User Dialog
|
||||||
|
|
||||||
$app.data.userDialog = {
|
$app.data.userDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -15370,7 +15405,8 @@ speechSynthesis.getVoices();
|
|||||||
this.updateTimers();
|
this.updateTimers();
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: player list
|
// #endregion
|
||||||
|
// #region | App: player list
|
||||||
|
|
||||||
API.$on('LOGIN', function () {
|
API.$on('LOGIN', function () {
|
||||||
$app.currentInstanceUserList.data = [];
|
$app.currentInstanceUserList.data = [];
|
||||||
@@ -15728,8 +15764,7 @@ speechSynthesis.getVoices();
|
|||||||
if (type === 'search') {
|
if (type === 'search') {
|
||||||
try {
|
try {
|
||||||
var response = await webApiService.execute({
|
var response = await webApiService.execute({
|
||||||
url: `${
|
url: `${this.avatarRemoteDatabaseProvider
|
||||||
this.avatarRemoteDatabaseProvider
|
|
||||||
}?${type}=${encodeURIComponent(search)}&n=5000`,
|
}?${type}=${encodeURIComponent(search)}&n=5000`,
|
||||||
method: 'GET',
|
method: 'GET',
|
||||||
headers: {
|
headers: {
|
||||||
@@ -16188,7 +16223,8 @@ speechSynthesis.getVoices();
|
|||||||
return avatars;
|
return avatars;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: World Dialog
|
// #endregion
|
||||||
|
// #region | App: World Dialog
|
||||||
|
|
||||||
$app.data.worldDialog = {
|
$app.data.worldDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -16832,7 +16868,8 @@ speechSynthesis.getVoices();
|
|||||||
return platforms.join(', ');
|
return platforms.join(', ');
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Avatar Dialog
|
// #endregion
|
||||||
|
// #region | App: Avatar Dialog
|
||||||
|
|
||||||
$app.data.avatarDialog = {
|
$app.data.avatarDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17182,7 +17219,8 @@ speechSynthesis.getVoices();
|
|||||||
return platforms.join(', ');
|
return platforms.join(', ');
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Favorite Dialog
|
// #endregion
|
||||||
|
// #region | App: Favorite Dialog
|
||||||
|
|
||||||
$app.data.favoriteDialog = {
|
$app.data.favoriteDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17291,7 +17329,8 @@ speechSynthesis.getVoices();
|
|||||||
$app.updateFavoriteDialog(args.params.objectId);
|
$app.updateFavoriteDialog(args.params.objectId);
|
||||||
});
|
});
|
||||||
|
|
||||||
// App: Invite Dialog
|
// #endregion
|
||||||
|
// #region | App: Invite Dialog
|
||||||
|
|
||||||
$app.data.inviteDialog = {
|
$app.data.inviteDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17378,7 +17417,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Social Status Dialog
|
// #endregion
|
||||||
|
// #region | App: Social Status Dialog
|
||||||
|
|
||||||
$app.data.socialStatusDialog = {
|
$app.data.socialStatusDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17440,7 +17480,8 @@ speechSynthesis.getVoices();
|
|||||||
D.statusDescription = val.status;
|
D.statusDescription = val.status;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Language Dialog
|
// #endregion
|
||||||
|
// #region | App: Language Dialog
|
||||||
|
|
||||||
$app.data.languageDialog = {
|
$app.data.languageDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17496,7 +17537,8 @@ speechSynthesis.getVoices();
|
|||||||
D.visible = true;
|
D.visible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Bio Dialog
|
// #endregion
|
||||||
|
// #region | App: Bio Dialog
|
||||||
|
|
||||||
$app.data.bioDialog = {
|
$app.data.bioDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17540,7 +17582,8 @@ speechSynthesis.getVoices();
|
|||||||
D.visible = true;
|
D.visible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: New Instance Dialog
|
// #endregion
|
||||||
|
// #region | App: New Instance Dialog
|
||||||
|
|
||||||
$app.data.newInstanceDialog = {
|
$app.data.newInstanceDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17758,7 +17801,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Launch Options Dialog
|
// #endregion
|
||||||
|
// #region | App: Launch Options Dialog
|
||||||
|
|
||||||
$app.data.launchOptionsDialog = {
|
$app.data.launchOptionsDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17809,7 +17853,8 @@ speechSynthesis.getVoices();
|
|||||||
D.visible = true;
|
D.visible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Set World Tags Dialog
|
// #endregion
|
||||||
|
// #region | App: Set World Tags Dialog
|
||||||
|
|
||||||
$app.data.setWorldTagsDialog = {
|
$app.data.setWorldTagsDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -17859,7 +17904,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Notification position
|
// #endregion
|
||||||
|
// #region | App: Notification position
|
||||||
|
|
||||||
$app.data.notificationPositionDialog = {
|
$app.data.notificationPositionDialog = {
|
||||||
visible: false
|
visible: false
|
||||||
@@ -17872,7 +17918,8 @@ speechSynthesis.getVoices();
|
|||||||
this.notificationPositionDialog.visible = true;
|
this.notificationPositionDialog.visible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Noty feed filters
|
// #endregion
|
||||||
|
// #region | App: Noty feed filters
|
||||||
|
|
||||||
$app.data.notyFeedFiltersDialog = {
|
$app.data.notyFeedFiltersDialog = {
|
||||||
visible: false
|
visible: false
|
||||||
@@ -17885,7 +17932,8 @@ speechSynthesis.getVoices();
|
|||||||
this.notyFeedFiltersDialog.visible = true;
|
this.notyFeedFiltersDialog.visible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Wrist feed filters
|
// #endregion
|
||||||
|
// #region | App: Wrist feed filters
|
||||||
|
|
||||||
$app.data.wristFeedFiltersDialog = {
|
$app.data.wristFeedFiltersDialog = {
|
||||||
visible: false
|
visible: false
|
||||||
@@ -17898,7 +17946,8 @@ speechSynthesis.getVoices();
|
|||||||
this.wristFeedFiltersDialog.visible = true;
|
this.wristFeedFiltersDialog.visible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Launch Dialog
|
// #endregion
|
||||||
|
// #region | App: Launch Dialog
|
||||||
|
|
||||||
$app.data.launchDialog = {
|
$app.data.launchDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -18075,7 +18124,8 @@ speechSynthesis.getVoices();
|
|||||||
D.visible = false;
|
D.visible = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Copy To Clipboard
|
// #endregion
|
||||||
|
// #region | App: Copy To Clipboard
|
||||||
|
|
||||||
$app.methods.copyToClipboard = function (text) {
|
$app.methods.copyToClipboard = function (text) {
|
||||||
var textArea = document.createElement('textarea');
|
var textArea = document.createElement('textarea');
|
||||||
@@ -18185,7 +18235,8 @@ speechSynthesis.getVoices();
|
|||||||
this.copyToClipboard(text);
|
this.copyToClipboard(text);
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: VRCPlus Icons
|
// #endregion
|
||||||
|
// #region | App: VRCPlus Icons
|
||||||
|
|
||||||
API.$on('LOGIN', function () {
|
API.$on('LOGIN', function () {
|
||||||
$app.VRCPlusIconsTable = [];
|
$app.VRCPlusIconsTable = [];
|
||||||
@@ -18418,7 +18469,8 @@ speechSynthesis.getVoices();
|
|||||||
return 0;
|
return 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Invite Messages
|
// #endregion
|
||||||
|
// #region | App: Invite Messages
|
||||||
|
|
||||||
API.$on('LOGIN', function () {
|
API.$on('LOGIN', function () {
|
||||||
$app.inviteMessageTable.data = [];
|
$app.inviteMessageTable.data = [];
|
||||||
@@ -18482,7 +18534,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Edit Invite Message Dialog
|
// #endregion
|
||||||
|
// #region | App: Edit Invite Message Dialog
|
||||||
|
|
||||||
$app.data.editInviteMessageDialog = {
|
$app.data.editInviteMessageDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -18541,7 +18594,8 @@ speechSynthesis.getVoices();
|
|||||||
this.editInviteMessageDialog.visible = false;
|
this.editInviteMessageDialog.visible = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Edit and Send Invite Response Message Dialog
|
// #endregion
|
||||||
|
// #region | App: Edit and Send Invite Response Message Dialog
|
||||||
|
|
||||||
$app.data.editAndSendInviteResponseDialog = {
|
$app.data.editAndSendInviteResponseDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -18734,7 +18788,8 @@ speechSynthesis.getVoices();
|
|||||||
this.sendInviteResponseConfirmDialog.visible = false;
|
this.sendInviteResponseConfirmDialog.visible = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Invite Request Response Message Dialog
|
// #endregion
|
||||||
|
// #region | App: Invite Request Response Message Dialog
|
||||||
|
|
||||||
$app.data.sendInviteRequestResponseDialogVisible = false;
|
$app.data.sendInviteRequestResponseDialogVisible = false;
|
||||||
|
|
||||||
@@ -18759,7 +18814,8 @@ speechSynthesis.getVoices();
|
|||||||
this.sendInviteRequestResponseDialogVisible = true;
|
this.sendInviteRequestResponseDialogVisible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Invite Message Dialog
|
// #endregion
|
||||||
|
// #region | App: Invite Message Dialog
|
||||||
|
|
||||||
$app.data.editAndSendInviteDialog = {
|
$app.data.editAndSendInviteDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -19099,7 +19155,8 @@ speechSynthesis.getVoices();
|
|||||||
this.sendInviteConfirmDialog.visible = false;
|
this.sendInviteConfirmDialog.visible = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Invite Request Message Dialog
|
// #endregion
|
||||||
|
// #region | App: Invite Request Message Dialog
|
||||||
|
|
||||||
$app.data.sendInviteRequestDialogVisible = false;
|
$app.data.sendInviteRequestDialogVisible = false;
|
||||||
|
|
||||||
@@ -19126,7 +19183,8 @@ speechSynthesis.getVoices();
|
|||||||
this.sendInviteRequestDialogVisible = true;
|
this.sendInviteRequestDialogVisible = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Friends List
|
// #endregion
|
||||||
|
// #region | App: Friends List
|
||||||
|
|
||||||
API.$on('LOGIN', function () {
|
API.$on('LOGIN', function () {
|
||||||
$app.friendsListTable.data = [];
|
$app.friendsListTable.data = [];
|
||||||
@@ -22231,7 +22289,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Previous Instances User Dialog
|
// #endregion
|
||||||
|
// #region | App: Previous Instances User Dialog
|
||||||
|
|
||||||
$app.data.previousInstancesUserDialogTable = {
|
$app.data.previousInstancesUserDialogTable = {
|
||||||
data: [],
|
data: [],
|
||||||
@@ -22330,7 +22389,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Previous Instances World Dialog
|
// #endregion
|
||||||
|
// #region | App: Previous Instances World Dialog
|
||||||
|
|
||||||
$app.data.previousInstancesWorldDialogTable = {
|
$app.data.previousInstancesWorldDialogTable = {
|
||||||
data: [],
|
data: [],
|
||||||
@@ -22413,7 +22473,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Previous Instance Info Dialog
|
// #endregion
|
||||||
|
// #region | App: Previous Instance Info Dialog
|
||||||
|
|
||||||
$app.data.previousInstanceInfoDialogTable = {
|
$app.data.previousInstanceInfoDialogTable = {
|
||||||
data: [],
|
data: [],
|
||||||
@@ -22865,7 +22926,8 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: world favorite import
|
// #endregion
|
||||||
|
// #region | App: world favorite import
|
||||||
|
|
||||||
$app.data.worldImportDialog = {
|
$app.data.worldImportDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -23026,7 +23088,8 @@ speechSynthesis.getVoices();
|
|||||||
$app.worldExportLocalFavoriteGroup = null;
|
$app.worldExportLocalFavoriteGroup = null;
|
||||||
});
|
});
|
||||||
|
|
||||||
// App: world favorite export
|
// #endregion
|
||||||
|
// #region | App: world favorite export
|
||||||
|
|
||||||
$app.data.worldExportDialogRef = {};
|
$app.data.worldExportDialogRef = {};
|
||||||
$app.data.worldExportDialogVisible = false;
|
$app.data.worldExportDialogVisible = false;
|
||||||
@@ -23100,7 +23163,8 @@ speechSynthesis.getVoices();
|
|||||||
this.updateWorldExportDialog();
|
this.updateWorldExportDialog();
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: avatar favorite import
|
// #endregion
|
||||||
|
// #region | App: avatar favorite import
|
||||||
|
|
||||||
$app.data.avatarImportDialog = {
|
$app.data.avatarImportDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -23241,7 +23305,8 @@ speechSynthesis.getVoices();
|
|||||||
$app.avatarExportFavoriteGroup = null;
|
$app.avatarExportFavoriteGroup = null;
|
||||||
});
|
});
|
||||||
|
|
||||||
// App: avatar favorite export
|
// #endregion
|
||||||
|
// #region | App: avatar favorite export
|
||||||
|
|
||||||
$app.data.avatarExportDialogRef = {};
|
$app.data.avatarExportDialogRef = {};
|
||||||
$app.data.avatarExportDialogVisible = false;
|
$app.data.avatarExportDialogVisible = false;
|
||||||
@@ -23285,7 +23350,8 @@ speechSynthesis.getVoices();
|
|||||||
this.updateAvatarExportDialog();
|
this.updateAvatarExportDialog();
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: friend favorite import
|
// #endregion
|
||||||
|
// #region | App: friend favorite import
|
||||||
|
|
||||||
$app.data.friendImportDialog = {
|
$app.data.friendImportDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -23424,7 +23490,8 @@ speechSynthesis.getVoices();
|
|||||||
$app.friendExportFavoriteGroup = null;
|
$app.friendExportFavoriteGroup = null;
|
||||||
});
|
});
|
||||||
|
|
||||||
// App: friend favorite export
|
// #endregion
|
||||||
|
// #region | App: friend favorite export
|
||||||
|
|
||||||
$app.data.friendExportDialogRef = {};
|
$app.data.friendExportDialogRef = {};
|
||||||
$app.data.friendExportDialogVisible = false;
|
$app.data.friendExportDialogVisible = false;
|
||||||
@@ -23468,7 +23535,8 @@ speechSynthesis.getVoices();
|
|||||||
this.updateFriendExportDialog();
|
this.updateFriendExportDialog();
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: user dialog notes
|
// #endregion
|
||||||
|
// #region | App: user dialog notes
|
||||||
|
|
||||||
API.saveNote = function (params) {
|
API.saveNote = function (params) {
|
||||||
return this.call('userNotes', {
|
return this.call('userNotes', {
|
||||||
@@ -23539,7 +23607,8 @@ speechSynthesis.getVoices();
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: note export
|
// #endregion
|
||||||
|
// #region | App: note export
|
||||||
|
|
||||||
$app.data.noteExportDialog = {
|
$app.data.noteExportDialog = {
|
||||||
visible: false,
|
visible: false,
|
||||||
@@ -23692,7 +23761,8 @@ speechSynthesis.getVoices();
|
|||||||
this.avatarRemoteDatabaseProvider = provider;
|
this.avatarRemoteDatabaseProvider = provider;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: local world favorites
|
// #endregion
|
||||||
|
// #region | App: local world favorites
|
||||||
|
|
||||||
$app.data.localWorldFavoriteGroups = [];
|
$app.data.localWorldFavoriteGroups = [];
|
||||||
$app.data.localWorldFavoritesList = [];
|
$app.data.localWorldFavoritesList = [];
|
||||||
@@ -24031,7 +24101,8 @@ speechSynthesis.getVoices();
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: ChatBox Blacklist
|
// #endregion
|
||||||
|
// #region | App: ChatBox Blacklist
|
||||||
$app.data.chatboxBlacklist = [
|
$app.data.chatboxBlacklist = [
|
||||||
'NP: ',
|
'NP: ',
|
||||||
'Now Playing',
|
'Now Playing',
|
||||||
@@ -24080,7 +24151,8 @@ speechSynthesis.getVoices();
|
|||||||
return false;
|
return false;
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: ChatBox User Blacklist
|
// #endregion
|
||||||
|
// #region | App: ChatBox User Blacklist
|
||||||
$app.data.chatboxUserBlacklist = new Map();
|
$app.data.chatboxUserBlacklist = new Map();
|
||||||
if (configRepository.getString('VRCX_chatboxUserBlacklist')) {
|
if (configRepository.getString('VRCX_chatboxUserBlacklist')) {
|
||||||
$app.data.chatboxUserBlacklist = new Map(
|
$app.data.chatboxUserBlacklist = new Map(
|
||||||
@@ -24114,7 +24186,8 @@ speechSynthesis.getVoices();
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Groups
|
// #endregion
|
||||||
|
// #region | App: Groups
|
||||||
|
|
||||||
API.cachedGroups = new Map();
|
API.cachedGroups = new Map();
|
||||||
|
|
||||||
@@ -25510,7 +25583,8 @@ speechSynthesis.getVoices();
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
// App: Language
|
// #endregion
|
||||||
|
// #region | App: Language
|
||||||
|
|
||||||
$app.data.appLanguage = 'en';
|
$app.data.appLanguage = 'en';
|
||||||
if (configRepository.getString('VRCX_appLanguage')) {
|
if (configRepository.getString('VRCX_appLanguage')) {
|
||||||
@@ -25541,6 +25615,8 @@ speechSynthesis.getVoices();
|
|||||||
this.updateVRConfigVars();
|
this.updateVRConfigVars();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// #endregion
|
||||||
|
// #region | App: Random unsorted app methods, data structs, API functions, and an API feedback/file analysis event
|
||||||
API.$on('USER:FEEDBACK', function (args) {
|
API.$on('USER:FEEDBACK', function (args) {
|
||||||
if (args.params.userId === this.currentUser.id) {
|
if (args.params.userId === this.currentUser.id) {
|
||||||
$app.currentUserFeedbackData = buildTreeData(args.json);
|
$app.currentUserFeedbackData = buildTreeData(args.json);
|
||||||
@@ -25694,7 +25770,9 @@ speechSynthesis.getVoices();
|
|||||||
}
|
}
|
||||||
API.getFileAnalysis({ fileId, version });
|
API.getFileAnalysis({ fileId, version });
|
||||||
};
|
};
|
||||||
|
// #endregion
|
||||||
|
|
||||||
$app = new Vue($app);
|
$app = new Vue($app);
|
||||||
window.$app = $app;
|
window.$app = $app;
|
||||||
})();
|
})();
|
||||||
|
// #endregion
|
||||||
Reference in New Issue
Block a user