Design rudimentary UI for printing text

This commit is contained in:
Joscha 2025-03-02 21:57:07 +01:00
parent c81f331c04
commit 8eaf465101
3 changed files with 67 additions and 20 deletions

View file

@ -1,18 +1,10 @@
<script setup lang="ts">
import CSegment from "./components/CSegment.vue";
</script>
<template> <template>
<div class="glow"> <div class="strip">
<div class="strip"> <CSegment />
<h2>Thing</h2>
Hello World
<br />
World Hello
<br />
<input type="file" />
<input />
<br />
<button>Foo</button>
<button>Foo</button>
<button>Foo</button>
</div>
</div> </div>
</template> </template>
@ -23,12 +15,6 @@
padding: 32px; padding: 32px;
background-color: white; background-color: white;
mask: conic-gradient(from 100deg at top, #000 160deg, #0000 160deg)
center/64px;
}
.glow {
filter: drop-shadow(0 0 50px rgb(255, 238, 214));
} }
</style> </style>
@ -53,6 +39,7 @@
padding: 0; padding: 0;
} }
h1,
h2 { h2 {
font-size: 32px; font-size: 32px;
} }

View file

@ -0,0 +1,33 @@
<script setup lang="ts">
import { ref } from "vue";
import CSegmentText from "./CSegmentText.vue";
const mode = ref<"text">();
</script>
<template>
<CSegmentText v-if="mode === 'text'" />
<section v-else class="choose">
<p>What do you want to print?</p>
<div class="list">
<button @click="mode = 'text'">Calendar</button>
<button @click="mode = 'text'">Cellular Automaton</button>
<button @click="mode = 'text'">Chat Message</button>
<button @click="mode = 'text'">Easter Egg</button>
<button @click="mode = 'text'">Text</button>
<button @click="mode = 'text'">Tic Tac Toe</button>
</div>
</section>
</template>
<style scoped>
p {
margin-bottom: 1ch;
}
.list {
display: flex;
flex-wrap: wrap;
gap: 1ch;
}
</style>

View file

@ -0,0 +1,27 @@
<script setup lang="ts"></script>
<template>
<section>
<h2>Text</h2>
<textarea rows="10"></textarea>
<fieldset>
<label><input type="checkbox" /> Force-Wrap</label>
<label><input type="checkbox" checked /> Feed</label>
</fieldset>
<button>Print</button>
</section>
</template>
<style scoped>
section {
display: flex;
flex-direction: column;
gap: 16px;
}
fieldset {
display: flex;
flex-direction: column;
border: none;
}
</style>