mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-15 22:28:10 +08:00
* Upgrade TypeScript, ESLint, and other dependencies This also cleans up various other files where newer ESLint rules complained * Set CI and CD to use Node.js version 16 * Small tweak * Fix CD version printing * Add nvm version for Cloudflare Pages
45 lines
782 B
Vue
45 lines
782 B
Vue
<template>
|
|
<div class="shelf-item-input" :class="{ active: active }">
|
|
<IconButton :action="action" :icon="icon" :size="32" />
|
|
</div>
|
|
</template>
|
|
|
|
<style lang="scss">
|
|
.shelf-item-input {
|
|
flex: 0 0 auto;
|
|
border-radius: 2px;
|
|
|
|
&:hover {
|
|
background: var(--color-6-lowergray);
|
|
}
|
|
|
|
&.active {
|
|
background: var(--color-accent);
|
|
}
|
|
|
|
.icon-button {
|
|
background: unset;
|
|
}
|
|
|
|
svg {
|
|
width: 24px;
|
|
height: 24px;
|
|
}
|
|
}
|
|
</style>
|
|
|
|
<script lang="ts">
|
|
import { defineComponent } from "vue";
|
|
|
|
import IconButton from "@/components/widgets/buttons/IconButton.vue";
|
|
|
|
export default defineComponent({
|
|
components: { IconButton },
|
|
props: {
|
|
icon: { type: String, required: true },
|
|
action: { type: Function, required: true },
|
|
active: { type: Boolean, default: false },
|
|
},
|
|
});
|
|
</script>
|