Skip to content

Commit bead11d

Browse files
committed
style: export success modal + generally
1 parent d44357b commit bead11d

14 files changed

+93
-57
lines changed

.eslintrc.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ module.exports = {
1313
'no-plusplus': 'off',
1414
'prefer-destructuring': 'off',
1515
'vue/no-textarea-mustache': 'off',
16+
'max-len': ['error', 110],
1617
},
1718
parserOptions: {
1819
parser: 'babel-eslint',

src/assets/css/custom/custom-action-button.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,5 @@
2222

2323
.ActionButton button[disabled],
2424
.ActionButton button:disabled {
25-
--button-invert-color: theme(colors.gray.dark);
25+
--button-invert-color: theme(colors.gray.mid);
2626
}

src/assets/icons/arrow-back.svg

Lines changed: 1 addition & 1 deletion
Loading

src/assets/icons/check-circle.svg

Lines changed: 1 addition & 0 deletions
Loading

src/components/ButtonExport.vue

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
<template v-slot:trigger>
66
<button
77
class="Button font-title"
8+
tabindex="1000"
89
>
910
Export
1011
</button>
@@ -36,6 +37,7 @@ import Popover from '@/components/Popover.vue';
3637
const GmailFormatter = {
3738
// Uses text/html
3839
blockquote(text) {
40+
// eslint-disable-next-line
3941
return `<blockquote style="margin-left: 0; padding: 15px; background: rgb(238, 238, 238); border-radius: 5px; color: rgb(51, 51, 51); font-family: sans-serif; font-size: 14.4px;">${text}</blockquote>`;
4042
},
4143
};

src/components/Editor.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<div class="relative">
33
<div
44
v-if="!$store.state.timestamp"
5-
class="Placeholder Text-lg"
5+
class="Placeholder Text-lg font-medium"
66
>
77
Paste here &amp; click to select…
88
</div>
@@ -162,7 +162,7 @@ export default {
162162
.Placeholder {
163163
@apply font-title text-brand-primary pl-6 mt-1;
164164
@apply absolute;
165-
margin-left: 3px;
165+
margin-left: 2px;
166166
}
167167
/*
168168

src/components/Modal.vue

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -59,35 +59,35 @@ export default {
5959
</script>
6060

6161
<style lang="postcss" scoped>
62-
.Modal-backdrop {
63-
@apply fixed inset-0 overflow-auto;
64-
background-color: rgba(255, 255, 255, 0.96);
65-
z-index: 99; /* below vue-headroom */
66-
}
62+
.Modal-backdrop {
63+
@apply fixed inset-0 overflow-auto;
64+
background-color: rgba(255, 255, 255, 1);
65+
z-index: 99; /* below vue-headroom */
66+
}
6767
68-
.Modal {
69-
/* @apply h-full; */
70-
/* @apply bg-white; */
71-
}
68+
.Modal {
69+
/* @apply h-full; */
70+
/* @apply bg-white; */
71+
}
7272
73-
.Modal-close {
74-
@apply absolute inset-0 p-4 z-10 cursor-pointer;
75-
}
73+
.Modal-close {
74+
@apply absolute inset-0 p-4 z-10 cursor-pointer;
75+
}
7676
77-
.Modal-close:focus,
78-
.Modal-close:active {
79-
@apply outline-none;
80-
}
77+
.Modal-close:focus,
78+
.Modal-close:active {
79+
@apply outline-none;
80+
}
8181
82-
/* Transition */
83-
.Modal-enter-active,
84-
.Modal-leave-active {
85-
transition: opacity 500ms cubic-bezier(0.19, 1, 0.22, 1);
86-
}
82+
/* Transition */
83+
.Modal-enter-active,
84+
.Modal-leave-active {
85+
transition: opacity 500ms cubic-bezier(0.19, 1, 0.22, 1);
86+
}
8787
88-
.Modal-enter,
89-
.Modal-leave-to {
90-
@apply opacity-0;
91-
/* transform: scale(1.05); */
92-
}
88+
.Modal-enter,
89+
.Modal-leave-to {
90+
@apply opacity-0;
91+
/* transform: scale(1.05); */
92+
}
9393
</style>

src/components/NavBar.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
class="Text-xl font-title font-bold text-brand-primary"
77
>
88
<icon v-if="$route.name !== 'home'" name="arrow-back" class="mr-1" />
9-
{{ homeLabel }}
9+
<span>{{ homeLabel }}</span>
1010
</router-link>
1111
<NavBarInfo class="mt-px"></NavBarInfo>
1212
</nav>
@@ -22,7 +22,7 @@ export default {
2222
},
2323
computed: {
2424
homeLabel() {
25-
return this.$route.name === 'home' ? 'Corvid Writing' : 'Corral mode';
25+
return this.$route.name === 'home' ? 'Corvid Writing' : 'Revise selection';
2626
},
2727
},
2828
};

src/components/NavBarInfo.vue

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@
88
<span v-else class="Timestamp Text-xs">{{ $store.state.timestamp }}</span>
99
</template>
1010
<!-- info toggle -->
11-
<span
11+
<button
1212
class="Info Text-xs text-brand-primary"
1313
ref="infoIcon"
1414
@click.prevent="toggleMobileNav()"
1515
>
1616
<icon v-if="mobileNavOpen" name="close" height="1.75em" width="1.75em"></icon>
1717
<icon v-else name="info" height="1.25em" width="1.25em"></icon>
18-
</span>
18+
</button>
1919
<portal to="modals">
2020
<Modal :show="mobileNavOpen" @close="mobileNavOpen = false">
2121
<Info></Info>
@@ -64,8 +64,7 @@ export default {
6464
.Info:hover {
6565
@apply text-brand-primary;
6666
}
67-
.Info svg {
68-
/* height: 1.25em !important; */
69-
/* width: 1.25em !important; */
67+
.Info:focus {
68+
@apply outline-none;
7069
}
7170
</style>

src/components/icons/arrow-back.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
var icon = require('vue-svgicon')
33
icon.register({
44
'arrow-back': {
5-
width: 16,
6-
height: 16,
5+
width: 24,
6+
height: 24,
77
viewBox: '0 0 24 24',
8-
data: '<path pid="0" d="M5 12l11 7V5z"/><path pid="1" d="M24 24H0V0h24z" fill="none"/>'
8+
data: '<path pid="0" d="M0 0h24v24H0z" fill="none"/><path pid="1" d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z"/>'
99
}
1010
})

src/components/icons/check-circle.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
/* eslint-disable */
2+
var icon = require('vue-svgicon')
3+
icon.register({
4+
'check-circle': {
5+
width: 24,
6+
height: 24,
7+
viewBox: '0 0 24 24',
8+
data: '<path pid="0" d="M0 0h24v24H0z" fill="none"/><path pid="1" d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/>'
9+
}
10+
})

src/components/icons/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/* eslint-disable */
22
require('./arrow-back')
3+
require('./check-circle')
34
require('./close')
45
require('./delete')
56
require('./edit')

src/views/Reply.vue

Lines changed: 38 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -65,20 +65,30 @@
6565
class="reply-input reply-input--contextual Input"
6666
placeholder="Add a summary…"
6767
rows="3"
68-
tabindex="32767"
68+
tabindex="999"
6969
@input="handleOutroInput"
7070
>{{ $store.state.repliesOutro }}</textarea>
71-
72-
<ButtonExport @onExport="handleExport" :groupedSelections="groupedSelections" />
7371
</div>
72+
<ButtonExport @onExport="handleExport" :groupedSelections="groupedSelections" />
73+
<!-- success modal -->
7474
<portal to="modals">
75-
<Modal :show="isResetModalOpen" @close="isResetModalOpen = false" ref="resetModal">
76-
<div class="max-w-xl">
77-
<p class="s-p">Successfully copied to your clipboard!</p>
78-
<div class="flex">
79-
<button class="mr-2 w-1/2 Button" @click="resetState">Start again</button>
80-
<button class="ml-2 w-1/2 Button Button--outline" @click="dismiss">Keep Editing</button>
81-
</div>
75+
<Modal
76+
:show="isResetModalOpen"
77+
@close="isResetModalOpen = false"
78+
ref="resetModal"
79+
>
80+
<p class="s-h font-title font-medium text-form-goo Text-base">
81+
<icon name="check-circle" class="text-form-good mr-2px" height="1.25em" width="1.25em"></icon>
82+
Copied to your clipboard
83+
</p>
84+
<hr class="s-h" />
85+
<div class="flex pt-1">
86+
<button class="mr-2 w-1/2 font-title font-semibold Button" @click="resetState">
87+
Start again
88+
</button>
89+
<button class="ml-2 w-1/2 font-title font-semibold Button Button--outline" @click="dismiss">
90+
Keep editing
91+
</button>
8292
</div>
8393
</Modal>
8494
</portal>
@@ -183,7 +193,7 @@ export default {
183193
}
184194
.selection:not(:last-of-type) {
185195
/* less than Block-sm-b */
186-
margin-bottom: calc(theme(spacing.10) * var(--block-size-ratio));
196+
margin-bottom: calc(theme(spacing.8) * var(--block-size-ratio));
187197
}
188198
.selection-content {
189199
flex-grow: 1;
@@ -195,7 +205,7 @@ export default {
195205
.selection__options {
196206
@apply absolute inset-0 right-auto text-right;
197207
top: var(--inset);
198-
left: -3.5rem;
208+
left: -3rem;
199209
}
200210
.selection .option-button {
201211
@apply opacity-0;
@@ -267,18 +277,30 @@ export default {
267277
} */
268278
269279
/*
270-
Modal
280+
Modal
281+
1. Move it above everything incl the nav
271282
*/
272283
.Modal-backdrop {
284+
@apply flex justify-center items-start;
273285
background: rgba(255, 255, 255, 0.7);
286+
background: rgba(250, 248, 245, 0.7);
287+
background: rgba(244, 242, 240, 0.7);
288+
z-index: 101; /* 1 */
274289
}
275-
276290
>>> .Modal {
277-
box-shadow: 0 0 6px 4px #eaeaea;
291+
/* @apply max-w-sm; */
292+
@apply shadow-xl;
293+
@apply rounded-lg bg-white;
294+
/* @apply border border-form-good; */
295+
@apply p-8;
296+
padding: calc(theme(spacing.8) * var(--block-size-ratio));
297+
margin-top: calc(theme(spacing.48) * var(--block-size-ratio));
298+
margin-top: 25vh;
299+
box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2), 0 10px 10px -5px rgba(0, 0, 0, 0.05);
278300
}
279-
280301
>>> .Modal .Button {
281302
white-space: nowrap;
303+
}
282304
283305
/*
284306
Draggable

tailwind.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ module.exports = {
2222
blue: '#1b495a',
2323
blueneutral: '#f1f2f3',
2424
bluelight: blueLight,
25-
neutral: '#FAF8F5',
25+
neutral: '#f4f2f0',
2626
},
2727
group: {
2828
2: 'hsl(110, 63%, 43%)',

0 commit comments

Comments
 (0)