Open-Source API Development Ecosystem • https://hoppscotch.io • Offline, On-Prem & Cloud • Web, Desktop & CLI • Open-Source Alternative to Postman, Insomnia
TypeScript apiapi-clientapi-restapi-testingdeveloper-toolsgraphqlhttphttp-clientpwarestrest-apispatestingtesting-toolstoolsvuevuejswebsocket
:sparkles: Toast for extensions
Liyas Thomas93acb03297e6
diff --git a/README.md b/README.mdindex c27261def..2ffff8300 100644--- a/README.md+++ b/README.md@@ -218,8 +218,11 @@ _**All `i18n` contributions are welcome to `i18n` [branch](https://github.com/li📦 **Add-ons**: Official add-ons for Postwoman.- - **[Postwoman Proxy β](https://github.com/postwoman-io/postwoman-proxy)** - A simple proxy server created for Postwoman- - **[Postwoman CLI β](https://github.com/postwoman-io/postwoman-cli)** - A CLI solution for Postwoman+ - **[Proxy β](https://github.com/postwoman-io/postwoman-proxy)** - A simple proxy server created for Postwoman+ - **[CLI β](https://github.com/postwoman-io/postwoman-cli)** - A CLI solution for Postwoman+ - **[Browser Extensions](https://github.com/postwoman-io/postwoman-cli)** - Browser extensions that simplifies access to Postwoman++ [ **Firefox**]() |  **Chrome (coming soon)**_Add-ons are developed and maintained under **[Official Postwoman Organization](https://github.com/postwoman-io)**_diff --git a/lang/en-US.js b/lang/en-US.jsindex 0fd4d880d..baa78e0fb 100644--- a/lang/en-US.js+++ b/lang/en-US.js@@ -154,7 +154,8 @@ export default {disconnected_from: "Disconnected from {name}",something_went_wrong: "Something went wrong!",error_occurred: "An error has occurred.",- browser_support_sse: "This browser doesn't seems to have Server Sent Events support.",+ browser_support_sse:+ "This browser doesn't seems to have Server Sent Events support.",log: "Log",no_url: "No URL",run_query: "Run Query",@@ -207,7 +208,8 @@ export default {value_count: "value {count}",send_request_first: "Send a request first",generate_docs: "Generate Documentation",- generate_docs_message: "Import any Postwoman Collection to Generate Documentation on-the-go.",+ generate_docs_message:+ "Import any Postwoman Collection to Generate Documentation on-the-go.",generate_docs_first: "Generate documentation first",docs_generated: "Documentation generated",import_collections: "Import collections",@@ -231,8 +233,10 @@ export default {enable_proxy: "Try enabling Proxy",complete_config_urls: "Please complete configuration urls.",token_request_saved: "Token request saved",- donate_info1: "If you have enjoyed the productivity of using Postwoman, consider donating as a sign of appreciation.",- donate_info2: "You can support Postwoman development via the following methods:",+ donate_info1:+ "If you have enjoyed the productivity of using Postwoman, consider donating as a sign of appreciation.",+ donate_info2:+ "You can support Postwoman development via the following methods:",one_time_recurring: "One-time or recurring",one_time: "One-time",recurring: "Recurring",@@ -241,5 +245,8 @@ export default {go_home: "Go Home",reload: "Reload",enter_curl: "Enter cURL",- empty: "Empty"+ empty: "Empty",+ extensions: "Extensions",+ extensions_info1: "Browser extension that simplifies access to Postwoman",+ extensions_info2: "Get Postwoman browser extension!"};diff --git a/layouts/default.vue b/layouts/default.vueindex 6ed7a7c0c..bdba8e0d0 100644--- a/layouts/default.vue+++ b/layouts/default.vue@@ -293,6 +293,16 @@<i class="material-icons">more_vert</i></button><template slot="popover">+ <div>+ <button+ class="icon"+ @click="showExtensions = true"+ v-close-popover+ >+ <i class="material-icons">extension</i>+ <span>{{ $t("extensions") }}</span>+ </button>+ </div><div><buttonclass="icon"@@ -402,6 +412,66 @@<aside class="nav-second"></aside></div></div>+ <modal v-if="showExtensions" @close="showExtensions = false">+ <div slot="header">+ <ul>+ <li>+ <div class="flex-wrap">+ <h3 class="title">{{ $t("extensions") }}</h3>+ <div>+ <button class="icon" @click="showExtensions = false">+ <i class="material-icons">close</i>+ </button>+ </div>+ </div>+ </li>+ </ul>+ </div>+ <div slot="body">+ <p class="info">+ {{ $t("extensions_info1") }}+ </p>+ <div>+ <a+ href="https://addons.mozilla.org/en-US/firefox/addon/postwoman"+ target="_blank"+ rel="noopener"+ >+ <button class="icon">+ <svg+ class="material-icons"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ >+ <path+ d="M12 0c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm8.003 8.657c-1.276-3.321-4.46-4.605-5.534-4.537 3.529 1.376 4.373 6.059 4.06 7.441-.307-1.621-1.286-3.017-1.872-3.385 3.417 8.005-4.835 10.465-7.353 7.687.649.168 1.931.085 2.891-.557.898-.602.983-.638 1.56-.683.686-.053-.041-1.406-1.539-1.177-.616.094-1.632.819-2.88.341-1.508-.576-1.46-2.634.096-2.015.337-.437.088-1.263.088-1.263.452-.414 1.022-.706 1.37-.911.228-.135.829-.507.795-1.23-.123-.096-.32-.219-.766-.193-1.736.11-1.852-.518-1.967-.808.078-.668.524-1.534 1.361-1.931-1.257-.193-2.28.397-2.789 1.154-.809-.174-1.305-.183-2.118-.031-.316-.24-.666-.67-.878-1.181 1.832-2.066 4.499-3.378 7.472-3.378 5.912 0 8.263 4.283 8.003 6.657z"+ />+ </svg>+ <span>Firefox</span>+ </button>+ </a>+ </div>+ <div>+ <button class="icon" disabled>+ <svg+ class="material-icons"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ >+ <path+ d="M2.897 4.181c2.43-2.828 5.763-4.181 9.072-4.181 4.288 0 8.535 2.273 10.717 6.554-2.722.001-6.984 0-9.293 0-1.674.001-2.755-.037-3.926.579-1.376.724-2.415 2.067-2.777 3.644l-3.793-6.596zm5.11 7.819c0 2.2 1.789 3.99 3.988 3.99s3.988-1.79 3.988-3.99-1.789-3.991-3.988-3.991-3.988 1.791-3.988 3.991zm5.536 5.223c-2.238.666-4.858-.073-6.293-2.549-1.095-1.891-3.989-6.933-5.305-9.225-1.33 2.04-1.945 4.294-1.945 6.507 0 5.448 3.726 10.65 9.673 11.818l3.87-6.551zm2.158-9.214c1.864 1.734 2.271 4.542 1.007 6.719-.951 1.641-3.988 6.766-5.46 9.248 7.189.443 12.752-5.36 12.752-11.972 0-1.313-.22-2.66-.69-3.995h-7.609z"+ />+ </svg>+ <span>Chrome (coming soon)</span>+ </button>+ </div>+ </div>+ <div slot="footer"></div>+ </modal><modal v-if="showShortcuts" @close="showShortcuts = false"><div slot="header"><ul>@@ -532,6 +602,7 @@ export default {// prompt.showInstallPrompt: null,version: {},+ showExtensions: false,showShortcuts: false,showSupport: false};@@ -591,6 +662,33 @@ export default {]});}+ let showExtensionsToast =+ localStorage.getItem("showExtensionsToast") === "yes";+ if (!showExtensionsToast) {+ setTimeout(() => {+ this.$toast.show(this.$t("extensions_info2"), {+ icon: "extension",+ duration: 5000,+ theme: "toasted-primary",+ action: [+ {+ text: this.$t("yes"),+ onClick: (e, toastObject) => {+ this.showExtensions = true;+ localStorage.setItem("showExtensionsToast", "yes");+ toastObject.goAway(0);+ }+ },+ {+ text: this.$t("no"),+ onClick: (e, toastObject) => {+ toastObject.goAway(0);+ }+ }+ ]+ });+ }, 10000);+ }})();window.addEventListener("scroll", event => {