Skip to content

Commit

Permalink
GH-1136 Fix close icon (Fix #1136)
Browse files Browse the repository at this point in the history
  • Loading branch information
dzikoysk committed Feb 26, 2022
1 parent 61fb9ea commit 186300e
Show file tree
Hide file tree
Showing 9 changed files with 66 additions and 24 deletions.

Large diffs are not rendered by default.

This file was deleted.

Large diffs are not rendered by default.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@
<meta property="og:site_name" content="{{REPOSILITE.TITLE}}">
<meta property="og:type" content="website">
<meta property="og:description" content="{{REPOSILITE.DESCRIPTION}}">
<script type="module" crossorigin src="/{{REPOSILITE.VITE_BASE_PATH}}/assets/index.c6b49bfb.js"></script>
<script type="module" crossorigin src="/{{REPOSILITE.VITE_BASE_PATH}}/assets/index.a13e2ff3.js"></script>
<link rel="modulepreload" href="/{{REPOSILITE.VITE_BASE_PATH}}/assets/vendor.ed721fb1.js">
<link rel="stylesheet" href="/{{REPOSILITE.VITE_BASE_PATH}}/assets/index.6d966543.css">
<link rel="stylesheet" href="/{{REPOSILITE.VITE_BASE_PATH}}/assets/index.1f820778.css">
</head>
<body>
<div id="app"></div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import { VueFinalModal } from 'vue-final-modal'
import Toggle from '@vueform/toggle'
import '@vueform/toggle/themes/default.css'
import { useAdjustments } from '../../store/adjustments'
import CloseIcon from '../icons/CloseIcon.vue'

const { reversedFileOrder, displayHashFiles } = useAdjustments()
const showAdjustments = ref(false)
Expand Down Expand Up @@ -60,7 +61,9 @@ export default {
/>
</div>
</div>
<button class="absolute top-0 right-0 mt-5 mr-9" @click="showAdjustments = false">🗙</button>
<button class="absolute top-0 right-0 mt-5 mr-9" @click="showAdjustments = false">
<CloseIcon />
</button>
</div>
</vue-final-modal>
<div @click="showAdjustments = true">
Expand Down
7 changes: 5 additions & 2 deletions reposilite-frontend/src/components/browser/BrowserUpload.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { createSuccessToast, createErrorToast } from '../../helpers/toast'
import { useSession } from '../../store/session'
import useQualifier from '../../helpers/qualifier'
import FileUpload from 'vue-upload-component'
import CloseIcon from '../icons/CloseIcon.vue'
const { client } = useSession()
const { qualifier, refreshQualifier } = useQualifier()
Expand Down Expand Up @@ -55,8 +56,10 @@ const uploadFiles = () => {
</div>
</FileUpload>
<div class="-mt-2 pb-2">
<div v-for="file in files" :key="file.name" class="pb-1 px-6">
<span class="text-xs text-purple-400" @click="removeFile(file)">🗙</span>
<div v-for="file in files" :key="file.name" class="pb-1 px-6 flex">
<span @click="removeFile(file)" class="pt-0.85">
<CloseIcon class="h-5 text-purple-400" />
</span>
<span class="px-2">{{file.name}}</span>
</div>
</div>
Expand Down
5 changes: 4 additions & 1 deletion reposilite-frontend/src/components/header/LoginModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import { ref } from 'vue'
import { VueFinalModal } from 'vue-final-modal'
import { createToast } from 'mosha-vue-toastify'
import { useSession } from '../../store/session'
import CloseIcon from '../icons/CloseIcon.vue'

const { login } = useSession()
const showLogin = ref(false)
Expand Down Expand Up @@ -58,7 +59,9 @@ export default {
</div>
<button class="bg-gray-100 dark:bg-gray-800 py-2 my-3 rounded-md cursor-pointer">Sign in</button>
</form>
<button class="absolute top-0 right-0 mt-5 mr-5" @click="close()">🗙</button>
<button class="absolute top-0 right-0 mt-5 mr-5" @click="close()">
<CloseIcon />
</button>
</div>
</vue-final-modal>
<div @click="showLogin = true">
Expand Down
33 changes: 33 additions & 0 deletions reposilite-frontend/src/components/icons/CloseIcon.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
<!--
- Copyright (c) 2022 dzikoysk
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-->

<template>
<!-- Source: https://heroicons.dev/ -->
<svg
class="w-6 h-6"
fill="none"
stroke="currentColor"
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
stroke-width="2"
d="M6 18L18 6M6 6l12 12"
/>
</svg>
</template>

0 comments on commit 186300e

Please sign in to comment.