Comments (5)
an example script where this is hapenning:
// Name: Password Generator
// Description: Generate a random password
// Author: Bruno Paz
// Github: @brpaz
import "@johnlindquist/kit"
const generatePassword : typeof import("generate-password") = await npm("generate-password");
const length = await arg({
placeholder: "How many characters?",
validate: (input) => {
if (isNaN(Number(input))) {
return "Please enter a number"
}
return true
}
})
const includeSymbols = await arg({
placeholder: "Include symbols?",
choices: ["Yes", "No"],
defaultValue: "Yes",
})
const passwords = generatePassword.generateMultiple(5, {
length: Number(length),
numbers: true,
excludeSimilarCharacters: true,
symbols: includeSymbols === "Yes",
strict: true,
})
await arg({
placeholder: "Select a password to copy",
choices: passwords,
onSubmit: async (input, state) => {
await copy(state?.focused?.value)
notify("Copied to clipboard")
},
actions: [
{
name: "Copy to clipboard",
shortcut: "c",
visible: true,
onAction: async (input, state) => {
await copy(state?.focused?.value)
notify("Copied to clipboard")
}
}
]
})
from kit.
@brpaz Thanks for the report. The internal window size detection measurements apparently have a different behavior on Linux than they do on Windows and Mac. I'm investigating a fix. I'll try to either have a fix or a workaround in the next few days.
from kit.
cool. thank you. Great work on the V2 btw. I love the new features like Actions and Snippets.
from kit.
@brpaz Here's a build which prevents resizing:
https://github.com/johnlindquist/kitapp/releases/tag/v2.0.43
I'm still investigating if I can possible re-enable resizing before I push the build to public channel
from kit.
@johnlindquist thanks. just tested it and seems fine. I will close this.
from kit.
Related Issues (20)
- [Feature] support for XDG environment variables
- Linux (Wayland) - Cannot open ScriptKit window after install HOT 2
- Error when using names/values for arg function returned for env
- ScriptKit unresponsive after Mac OS sleep HOT 3
- [Preview Build] Esbuild error when using ScriptKit HOT 2
- Kit AppImage won't start on Ubuntu 22.04 HOT 3
- inspect doesn't let you pass in number on 1.94.7 HOT 1
- Preview is not rendered when searching for choices in choices
- `clipboard.writeText` doesn't write to clipboard if it's not `string` HOT 1
- MacOS Sonoma: setActiveAppBounds targets the Kit.app prompt HOT 2
- Should we make ~/.kit directory with permission 700?
- Shortcode on Windows gets executed without pressing Space HOT 3
- Error creating new snippet in release candidate for 2.0 HOT 2
- doesn't work on ubuntu 22.04LTS HOT 3
- Crashing after update to 2.0.15 HOT 2
- Opening Script Kit Prompt Flashes HOT 3
- Keyboard Shortcut Still Registered After Deletion
- PLEASE put the docs in a documentation site. The API and Guide docs are way too long! HOT 5
- Extra space breaks clipboard expected behaviour of the Clipboard #v2 HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kit.