Skip to content
This repository has been archived by the owner on Nov 4, 2024. It is now read-only.

Commit

Permalink
Added discord 128 char enforcement to Image Text
Browse files Browse the repository at this point in the history
  • Loading branch information
hypherionmc committed Apr 12, 2022
1 parent 31fc5bc commit 63d8b8b
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 18 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "simple-rpc-vue",
"version": "2.0.4",
"version": "2.0.5",
"private": true,
"scripts": {
"info" : "tauri info",
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "simple-rpc-editor"
version = "2.0.4"
version = "2.0.5"
description = "Simple RPC Config Editor App"
authors = [ "HypherionSA" ]
license = "MIT"
Expand Down
21 changes: 5 additions & 16 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@
</v-select>

<div class="input-group mb-3" v-if="(key === 'largeImageKey' || key === 'smallImageKey') && appVars.manualEdit">
<input type="text" class="form-control" v-model="configData.new[key]" v-on:change="" style="border-radius: 5px 0px 0px 5px;">
<input type="text" class="form-control" v-model="configData.new[key]" v-on:change="" style="border-radius: 5px 0px 0px 5px;" maxlength="128">
<div class="input-group-append">
<button class="btn btn-success" type="button" v-on:click="appVars.manualEdit = !appVars.manualEdit">
<font-awesome-icon :icon="['fas', 'edit']" />
Expand Down Expand Up @@ -229,7 +229,7 @@
<label class="col-sm-2 col-form-label">{{datakey | camelToNormal}}</label>
<div class="col-sm-10">

<input type="text" class="form-control" :class="darkMode ? 'dark' : 'light'" v-if="datakey === 'largeImageText' || datakey === 'smallImageText' || datakey === 'name' || datakey === 'description' || datakey === 'state'" v-model="configData.new.dimension_overrides.dimensions[key][datakey]">
<input type="text" class="form-control" :class="darkMode ? 'dark' : 'light'" v-if="datakey === 'largeImageText' || datakey === 'smallImageText' || datakey === 'name' || datakey === 'description' || datakey === 'state'" v-model="configData.new.dimension_overrides.dimensions[key][datakey]" maxlength="128">

<v-select :options="configData.appAssets" class="image-chooser" :class="darkMode ? 'dark' : 'light'"
label="name" v-if="(datakey === 'largeImageKey' || datakey === 'smallImageKey')"
Expand Down Expand Up @@ -267,7 +267,7 @@
<div class="mb-3 row" v-for="(worldData, datakey) in dimension">
<label class="col-sm-2 col-form-label">{{datakey | camelToNormal}}</label>
<div class="col-sm-10">
<input type="text" class="form-control" :class="darkMode ? 'dark' : 'light'" v-if="datakey === 'largeImageText' || datakey === 'smallImageText' || datakey === 'ip' || datakey === 'description' || datakey === 'state' || datakey === 'largeImageKey' || datakey === 'smallImageKey'" v-model="configData.new.entry[key][datakey]">
<input type="text" class="form-control" :class="darkMode ? 'dark' : 'light'" v-if="datakey === 'largeImageText' || datakey === 'smallImageText' || datakey === 'ip' || datakey === 'description' || datakey === 'state' || datakey === 'largeImageKey' || datakey === 'smallImageKey'" v-model="configData.new.entry[key][datakey]" maxlength="128">
</div>
</div>
</div>
Expand Down Expand Up @@ -344,8 +344,8 @@ export default {
appSettings: {
showPreview: false,
showChangelog: false,
internalVer: 8,
lastInternalVer: 7
internalVer: 9,
lastInternalVer: 8
},
codeEditor: {
editorRef: Object,
Expand Down Expand Up @@ -395,17 +395,6 @@ export default {
AppFunctions.saveSettings(appRef);
}, 1000);
/*await invoke("discord_rpc", {
clientId: "885690338025545809",
state: "Idling",
details: "",
largeImageKey: "logo",
largeImageText: "Simple RPC Editor" + appRef.aboutInfo.appver,
smallImageKey: "",
smallImageText: "",
startTime: Math.round(Date.now() / 1000)
});*/
setInterval(async function () {
if (appRef.configData.isConfigLoaded) {
if (appRef.configData.configType === 'NORMAL' && !_.isEqual(appRef.configData.new, appRef.configData.lastConfigData) || appRef.appVars.activeSection.last !== appRef.appVars.activeSection.current) {
Expand Down
3 changes: 3 additions & 0 deletions src/components/ChangelogSplash.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
<div class="code-editor" style='vertical-align: top !important; justify-items: normal !important; align-items: normal !important; display: block;' :class="darkMode ? 'dark' : 'light'">
<h4 id="changelog_head" class="text-center" style='width: 100%;' :class="darkMode ? 'dark' : 'light'">What's New</h4>
<pre id="changelog" style="width: 100%; height: 95%; background: transparent !important; border: 0px;" readonly="readonly" class="w-100 form-control" :class="darkMode ? 'dark' : 'light'">
Version 2.0.5:
* Enforce discord limit of 128 chars on imageText

Version 2.0.4:
* Fix "cannot recurse directory issue"
* Upgrade Tauri to 1.0-rc
Expand Down

0 comments on commit 63d8b8b

Please sign in to comment.