feat: minor ui tweaks

This commit is contained in:
liyasthomas
2021-06-14 09:55:27 +05:30
parent ced2f1b911
commit 111a947413
28 changed files with 48 additions and 95 deletions

View File

@@ -26,7 +26,7 @@ export default Vue.extend({
}, },
noLegend: { noLegend: {
type: Boolean, type: Boolean,
default: false, default: true,
}, },
}, },
computed: { computed: {

View File

@@ -232,6 +232,7 @@ export default {
this.hideModal() this.hideModal()
}, },
hideModal() { hideModal() {
this.picked = null
this.$emit("hide-modal") this.$emit("hide-modal")
}, },
}, },

View File

@@ -36,7 +36,7 @@
> >
<i class="material-icons">topic</i> <i class="material-icons">topic</i>
</button> </button>
<v-popover v-if="!savingMode"> <v-popover>
<button v-tooltip.left="$t('more')" class="tooltip-target icon"> <button v-tooltip.left="$t('more')" class="tooltip-target icon">
<i class="material-icons">more_vert</i> <i class="material-icons">more_vert</i>
</button> </button>

View File

@@ -28,7 +28,7 @@
<span>{{ folder.name }}</span> <span>{{ folder.name }}</span>
</button> </button>
</div> </div>
<v-popover v-if="!savingMode"> <v-popover>
<button v-tooltip.left="$t('more')" class="tooltip-target icon"> <button v-tooltip.left="$t('more')" class="tooltip-target icon">
<i class="material-icons">more_vert</i> <i class="material-icons">more_vert</i>
</button> </button>

View File

@@ -25,7 +25,7 @@
<span>{{ request.name }}</span> <span>{{ request.name }}</span>
</button> </button>
</div> </div>
<v-popover v-if="!savingMode"> <v-popover>
<button v-tooltip="$t('more')" class="tooltip-target icon"> <button v-tooltip="$t('more')" class="tooltip-target icon">
<i class="material-icons">more_vert</i> <i class="material-icons">more_vert</i>
</button> </button>

View File

@@ -1,12 +1,8 @@
<template> <template>
<AppSection <AppSection ref="collections" :label="$t('collections')">
ref="collections"
class="yellow"
:label="$t('collections')"
no-legend
>
<div class="show-on-large-screen"> <div class="show-on-large-screen">
<input <input
v-if="showCollActions"
v-model="filterText" v-model="filterText"
aria-label="Search" aria-label="Search"
type="search" type="search"
@@ -50,11 +46,7 @@
@hide-modal="displayModalImportExport(false)" @hide-modal="displayModalImportExport(false)"
/> />
<div class="border-b row-wrapper border-divider"> <div class="border-b row-wrapper border-divider">
<button <button class="icon" @click="displayModalAdd(true)">
v-if="showCollActions"
class="icon"
@click="displayModalAdd(true)"
>
<i class="material-icons">add</i> <i class="material-icons">add</i>
<span>{{ $t("new") }}</span> <span>{{ $t("new") }}</span>
</button> </button>

View File

@@ -1,5 +1,5 @@
<template> <template>
<AppSection ref="collections" :label="$t('collections')" no-legend> <AppSection ref="collections" :label="$t('collections')">
<div class="show-on-large-screen"> <div class="show-on-large-screen">
<input <input
v-if="!saveRequest" v-if="!saveRequest"
@@ -57,8 +57,7 @@
v-if=" v-if="
collectionsType.type == 'team-collections' && collectionsType.type == 'team-collections' &&
(collectionsType.selectedTeam == undefined || (collectionsType.selectedTeam == undefined ||
collectionsType.selectedTeam.myRole == 'VIEWER') && collectionsType.selectedTeam.myRole == 'VIEWER')
!saveRequest
" "
class="icon" class="icon"
disabled disabled
@@ -69,11 +68,7 @@
<span>{{ $t("new") }}</span> <span>{{ $t("new") }}</span>
</div> </div>
</button> </button>
<button <button v-else class="icon" @click="displayModalAdd(true)">
v-else-if="!saveRequest"
class="icon"
@click="displayModalAdd(true)"
>
<i class="material-icons">add</i> <i class="material-icons">add</i>
<span>{{ $t("new") }}</span> <span>{{ $t("new") }}</span>
</button> </button>

View File

@@ -44,7 +44,7 @@
> >
<i class="material-icons">check_box</i> <i class="material-icons">check_box</i>
</button> </button>
<v-popover v-if="!saveRequest"> <v-popover>
<button v-tooltip.left="$t('more')" class="tooltip-target icon"> <button v-tooltip.left="$t('more')" class="tooltip-target icon">
<i class="material-icons">more_vert</i> <i class="material-icons">more_vert</i>
</button> </button>

View File

@@ -27,7 +27,7 @@
<span>{{ folder.name ? folder.name : folder.title }}</span> <span>{{ folder.name ? folder.name : folder.title }}</span>
</button> </button>
</div> </div>
<v-popover v-if="!saveRequest"> <v-popover>
<button v-tooltip.left="$t('more')" class="tooltip-target icon"> <button v-tooltip.left="$t('more')" class="tooltip-target icon">
<i class="material-icons">more_vert</i> <i class="material-icons">more_vert</i>
</button> </button>

View File

@@ -27,7 +27,7 @@
<span>{{ request.name }}</span> <span>{{ request.name }}</span>
</button> </button>
</div> </div>
<v-popover v-if="!saveRequest"> <v-popover>
<button v-tooltip="$t('more')" class="tooltip-target icon"> <button v-tooltip="$t('more')" class="tooltip-target icon">
<i class="material-icons">more_vert</i> <i class="material-icons">more_vert</i>
</button> </button>

View File

@@ -33,7 +33,7 @@
> >
<i class="material-icons">check_box</i> <i class="material-icons">check_box</i>
</button> </button>
<v-popover v-if="!saveRequest"> <v-popover>
<button <button
v-if="collectionsType.selectedTeam.myRole !== 'VIEWER'" v-if="collectionsType.selectedTeam.myRole !== 'VIEWER'"
v-tooltip.left="$t('more')" v-tooltip.left="$t('more')"

View File

@@ -18,7 +18,7 @@
<span>{{ folder.name ? folder.name : folder.title }}</span> <span>{{ folder.name ? folder.name : folder.title }}</span>
</button> </button>
</div> </div>
<v-popover v-if="!saveRequest"> <v-popover>
<button <button
v-if="collectionsType.selectedTeam.myRole !== 'VIEWER'" v-if="collectionsType.selectedTeam.myRole !== 'VIEWER'"
v-tooltip.left="$t('more')" v-tooltip.left="$t('more')"

View File

@@ -17,7 +17,7 @@
<span>{{ request.name }}</span> <span>{{ request.name }}</span>
</button> </button>
</div> </div>
<v-popover v-if="!saveRequest"> <v-popover>
<button <button
v-if="collectionsType.selectedTeam.myRole !== 'VIEWER'" v-if="collectionsType.selectedTeam.myRole !== 'VIEWER'"
v-tooltip="$t('more')" v-tooltip="$t('more')"

View File

@@ -1,10 +1,5 @@
<template> <template>
<AppSection <AppSection ref="environments" :label="$t('environments')">
ref="environments"
icon="history"
:label="$t('environments')"
no-legend
>
<div class="show-on-large-screen"> <div class="show-on-large-screen">
<span class="select-wrapper"> <span class="select-wrapper">
<select <select

View File

@@ -1,5 +1,5 @@
<template> <template>
<AppSection ref="history" icon="history" :label="$t('history')" no-legend> <AppSection ref="history" :label="$t('history')">
<div class="show-on-large-screen"> <div class="show-on-large-screen">
<input <input
v-model="filterText" v-model="filterText"

View File

@@ -1,5 +1,5 @@
<template> <template>
<AppSection ref="headers" label="Headers" no-legend> <AppSection ref="headers" label="Headers">
<ul v-if="headers.length !== 0"> <ul v-if="headers.length !== 0">
<li> <li>
<div class="row-wrapper"> <div class="row-wrapper">

View File

@@ -1,5 +1,5 @@
<template> <template>
<AppSection ref="sync" :label="$t('notes')" no-legend> <AppSection ref="sync" :label="$t('notes')">
<div v-if="fb.currentUser"> <div v-if="fb.currentUser">
<FirebaseInputform /> <FirebaseInputform />
<FirebaseFeeds /> <FirebaseFeeds />

View File

@@ -1,5 +1,5 @@
<template> <template>
<AppSection ref="parameters" label="Parameters" no-legend> <AppSection ref="parameters" label="Parameters">
<ul v-if="params.length !== 0"> <ul v-if="params.length !== 0">
<li> <li>
<div class="row-wrapper"> <div class="row-wrapper">

View File

@@ -1,5 +1,5 @@
<template> <template>
<AppSection id="response" ref="response" :label="$t('response')" no-legend> <AppSection id="response" ref="response" :label="$t('response')">
<HttpResponseMeta :response="response" :active="active" /> <HttpResponseMeta :response="response" :active="active" />
<div v-if="response.body && response.body !== $t('loading')"> <div v-if="response.body && response.body !== $t('loading')">
<LensesResponseBodyRenderer :response="response" /> <LensesResponseBodyRenderer :response="response" />

View File

@@ -1,6 +1,6 @@
<template> <template>
<div> <div>
<AppSection :label="$t('request')" no-legend> <AppSection :label="$t('request')">
<ul> <ul>
<li> <li>
<label for="mqtt-url">{{ $t("url") }}</label> <label for="mqtt-url">{{ $t("url") }}</label>
@@ -34,7 +34,7 @@
</ul> </ul>
</AppSection> </AppSection>
<AppSection :label="$t('communication')" no-legend> <AppSection :label="$t('communication')">
<ul> <ul>
<li> <li>
<RealtimeLog :title="$t('log')" :log="log" /> <RealtimeLog :title="$t('log')" :log="log" />

View File

@@ -1,6 +1,6 @@
<template> <template>
<div> <div>
<AppSection ref="request" :label="$t('request')" no-legend> <AppSection ref="request" :label="$t('request')">
<ul> <ul>
<li> <li>
<label for="socketio-url">{{ $t("url") }}</label> <label for="socketio-url">{{ $t("url") }}</label>
@@ -43,12 +43,7 @@
</ul> </ul>
</AppSection> </AppSection>
<AppSection <AppSection id="response" ref="response" :label="$t('communication')">
id="response"
ref="response"
:label="$t('communication')"
no-legend
>
<ul> <ul>
<li> <li>
<RealtimeLog :title="$t('log')" :log="communication.log" /> <RealtimeLog :title="$t('log')" :log="communication.log" />

View File

@@ -1,6 +1,6 @@
<template> <template>
<div> <div>
<AppSection ref="request" :label="$t('request')" no-legend> <AppSection ref="request" :label="$t('request')">
<ul> <ul>
<li> <li>
<label for="server">{{ $t("server") }}</label> <label for="server">{{ $t("server") }}</label>
@@ -36,12 +36,7 @@
</ul> </ul>
</AppSection> </AppSection>
<AppSection <AppSection id="response" ref="response" :label="$t('communication')">
id="response"
ref="response"
:label="$t('communication')"
no-legend
>
<ul> <ul>
<li> <li>
<RealtimeLog :title="$t('events')" :log="events.log" /> <RealtimeLog :title="$t('events')" :log="events.log" />

View File

@@ -1,6 +1,6 @@
<template> <template>
<div> <div>
<AppSection ref="request" :label="$t('request')" no-legend> <AppSection ref="request" :label="$t('request')">
<ul> <ul>
<li> <li>
<label for="websocket-url">{{ $t("url") }}</label> <label for="websocket-url">{{ $t("url") }}</label>
@@ -37,12 +37,7 @@
</ul> </ul>
</AppSection> </AppSection>
<AppSection <AppSection id="response" ref="response" :label="$t('communication')">
id="response"
ref="response"
:label="$t('communication')"
no-legend
>
<ul> <ul>
<li> <li>
<RealtimeLog :title="$t('log')" :log="communication.log" /> <RealtimeLog :title="$t('log')" :log="communication.log" />

View File

@@ -1,11 +1,5 @@
<template> <template>
<AppSection <AppSection ref="teams" :label="$t('teams')">
ref="teams"
class="green"
icon="history"
:label="$t('teams')"
no-legend
>
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("teams") }}</label> <label>{{ $t("teams") }}</label>
<div v-if="fb.currentUser"></div> <div v-if="fb.currentUser"></div>

View File

@@ -2,7 +2,7 @@
<div class="page"> <div class="page">
<div class="content"> <div class="content">
<div class="page-columns inner-left"> <div class="page-columns inner-left">
<AppSection ref="import" :label="$t('import')" no-legend> <AppSection ref="import" :label="$t('import')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("collection") }}</label> <label>{{ $t("collection") }}</label>
<p class="info"> <p class="info">
@@ -55,7 +55,7 @@
</div> </div>
</AppSection> </AppSection>
<AppSection ref="documentation" :label="$t('documentation')" no-legend> <AppSection ref="documentation" :label="$t('documentation')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("documentation") }}</label> <label>{{ $t("documentation") }}</label>
<p v-if="items.length === 0" class="info"> <p v-if="items.length === 0" class="info">

View File

@@ -2,7 +2,7 @@
<div class="page"> <div class="page">
<div class="content"> <div class="content">
<div class="page-columns inner-left"> <div class="page-columns inner-left">
<AppSection ref="endpoint" :label="$t('endpoint')" no-legend> <AppSection ref="endpoint" :label="$t('endpoint')">
<ul> <ul>
<li> <li>
<label for="url">{{ $t("url") }}</label> <label for="url">{{ $t("url") }}</label>
@@ -37,7 +37,7 @@
</ul> </ul>
</AppSection> </AppSection>
<AppSection ref="headers" :label="$t('headers')" no-legend> <AppSection ref="headers" :label="$t('headers')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("headers") }}</label> <label>{{ $t("headers") }}</label>
<ul v-if="headers.length !== 0"> <ul v-if="headers.length !== 0">
@@ -150,7 +150,7 @@
</div> </div>
</AppSection> </AppSection>
<AppSection ref="schema" :label="$t('schema')" no-legend> <AppSection ref="schema" :label="$t('schema')">
<div class="row-wrapper"> <div class="row-wrapper">
<label>{{ $t("schema") }}</label> <label>{{ $t("schema") }}</label>
<div v-if="schema"> <div v-if="schema">
@@ -212,7 +212,7 @@
/> />
</AppSection> </AppSection>
<AppSection ref="query" :label="$t('query')" no-legend> <AppSection ref="query" :label="$t('query')">
<div class="row-wrapper gqlRunQuery"> <div class="row-wrapper gqlRunQuery">
<label for="gqlQuery">{{ $t("query") }}</label> <label for="gqlQuery">{{ $t("query") }}</label>
<div> <div>
@@ -266,7 +266,7 @@
/> />
</AppSection> </AppSection>
<AppSection ref="variables" :label="$t('variables')" no-legend> <AppSection ref="variables" :label="$t('variables')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("variables") }}</label> <label>{{ $t("variables") }}</label>
<SmartAceEditor <SmartAceEditor
@@ -285,7 +285,7 @@
</div> </div>
</AppSection> </AppSection>
<AppSection ref="response" :label="$t('response')" no-legend> <AppSection ref="response" :label="$t('response')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("response") }}</label> <label>{{ $t("response") }}</label>
<div class="row-wrapper"> <div class="row-wrapper">
@@ -347,7 +347,7 @@
> >
<SmartTabs> <SmartTabs>
<SmartTab :id="'docs'" :label="`Docs`" :selected="true"> <SmartTab :id="'docs'" :label="`Docs`" :selected="true">
<AppSection ref="docs" :label="$t('docs')" no-legend> <AppSection ref="docs" :label="$t('docs')">
<section class="flex-col"> <section class="flex-col">
<input <input
v-model="graphqlFieldsFilterText" v-model="graphqlFieldsFilterText"

View File

@@ -3,7 +3,7 @@
<div class="page"> <div class="page">
<div class="content"> <div class="content">
<div class="page-columns inner-left"> <div class="page-columns inner-left">
<AppSection :label="$t('request')" ref="request" no-legend> <AppSection :label="$t('request')" ref="request">
<ul> <ul>
<li class="shrink"> <li class="shrink">
<label for="method">{{ $t("method") }}</label> <label for="method">{{ $t("method") }}</label>
@@ -253,11 +253,7 @@
</SmartTab> </SmartTab>
<SmartTab :id="'authentication'" :label="$t('authentication')"> <SmartTab :id="'authentication'" :label="$t('authentication')">
<AppSection <AppSection :label="$t('authentication')" ref="authentication">
:label="$t('authentication')"
ref="authentication"
no-legend
>
<ul> <ul>
<li> <li>
<div class="row-wrapper"> <div class="row-wrapper">
@@ -358,7 +354,6 @@
<AppSection <AppSection
v-if="showTokenRequest" v-if="showTokenRequest"
class="red"
label="Access Token Request" label="Access Token Request"
ref="accessTokenRequest" ref="accessTokenRequest"
> >
@@ -485,10 +480,8 @@
> >
<AppSection <AppSection
v-if="showPreRequestScript" v-if="showPreRequestScript"
class="orange"
:label="$t('pre_request_script')" :label="$t('pre_request_script')"
ref="preRequest" ref="preRequest"
no-legend
> >
<ul> <ul>
<li> <li>
@@ -527,10 +520,8 @@
<SmartTab :id="'tests'" :label="$t('tests')"> <SmartTab :id="'tests'" :label="$t('tests')">
<AppSection <AppSection
v-if="testsEnabled" v-if="testsEnabled"
class="orange"
:label="$t('tests')" :label="$t('tests')"
ref="postRequestTests" ref="postRequestTests"
no-legend
> >
<ul> <ul>
<li> <li>

View File

@@ -4,7 +4,7 @@
<Teams /> <Teams />
</div> </div>
<AppSection ref="account" :label="$t('account')" no-legend> <AppSection ref="account" :label="$t('account')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("account") }}</label> <label>{{ $t("account") }}</label>
<div v-if="fb.currentUser"> <div v-if="fb.currentUser">
@@ -74,7 +74,7 @@
</div> </div>
</AppSection> </AppSection>
<AppSection ref="theme" :label="$t('theme')" no-legend> <AppSection ref="theme" :label="$t('theme')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("theme") }}</label> <label>{{ $t("theme") }}</label>
<SmartColorModePicker /> <SmartColorModePicker />
@@ -91,7 +91,7 @@
</div> </div>
</AppSection> </AppSection>
<AppSection ref="extensions" :label="$t('extensions')" no-legend> <AppSection ref="extensions" :label="$t('extensions')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("extensions") }}</label> <label>{{ $t("extensions") }}</label>
<div class="row-wrapper"> <div class="row-wrapper">
@@ -113,7 +113,7 @@
</div> </div>
</AppSection> </AppSection>
<AppSection ref="proxy" :label="$t('proxy')" no-legend> <AppSection ref="proxy" :label="$t('proxy')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("proxy") }}</label> <label>{{ $t("proxy") }}</label>
<div class="row-wrapper"> <div class="row-wrapper">
@@ -184,7 +184,7 @@
--> -->
</AppSection> </AppSection>
<AppSection ref="experiments" :label="$t('experiments')" no-legend> <AppSection ref="experiments" :label="$t('experiments')">
<div class="flex flex-col"> <div class="flex flex-col">
<label>{{ $t("experiments") }}</label> <label>{{ $t("experiments") }}</label>
<p class="info"> <p class="info">