Comments (3)
@omartoutounji Thanks for this info. I think you could achieve this with CSS.
Let's say you have this default layout:
[
'c a z y x w v u',
'd t',
'e s'
(etc..)
]
Then in CSS you'd target all the rows that are not the first nor the last one.
Perhaps like this
.simple-keyboard .hg-row:not(:first-child):not(:last-child) {
justify-content: space-between;
}
.simple-keyboard .hg-row:not(:first-child):not(:last-child) .hg-button {
flex-grow: unset;
min-width: 50px;
}
Here's a sandbox:
https://codesandbox.io/s/2zx3my9qj0
Screenshot:
Regards,
Francisco Hodge
from simple-keyboard.
Hello @hodgef,
Thank you for your prompt reply.
We are trying to create iType, a website that allows you to type using your eye gaze which is tracked by your webcam. Fingers? Who needs them!
We tried 'eye-gazing' (as in typing by staring at a letter one-by-one for some time) on a QWERTY and it wasn't a pleasant experience as the letters are so close to each other. So to achieve a better user experience, we completely re-designed the QWERTY look to make it easier to type with your eyes.
We are now trying to implement that design using simple-keyboard, however empty spaces are replaced with empty buttons which we don't want.
Allow me to elaborate by attaching screenshots.
Below is the design we are trying to implement.
Below is our implementation so far with simple-keyboard
As you can see, those empty buttons look bad and the empty rows are clickable which we don't want!
from simple-keyboard.
Hello @omartoutounji,
Any character between spaces (even a space between spaces), is considered a button by design.
You could create an empty button like this {//}
(built-in) or just create a custom empty button (like {empty}
), then give it a desired style in CSS (though buttonTheme).
I'm not completely visualizing the use-case here though, a screenshot of what you're trying to achieve would really help. If padding between rows or buttons is needed, I generally would recommend using CSS.
Hope that helps. If it doesn't please provide a screenshot of what you're trying to achieve and we'll go from there.
Regards,
Francisco Hodge
from simple-keyboard.
Related Issues (20)
- Add icons or images to buttons HOT 1
- your web is not opened HOT 1
- Prevent showing system keyboard on tablets HOT 3
- Support for mouse element HOT 2
- Japanese Flick Input (Mobile) HOT 3
- excludeFromLayout doesnt work HOT 2
- can i use in vue3? HOT 1
- Keyboard button not showing with tailwind HOT 2
- Not responsive on mobile HOT 1
- CSS partialy Apply HOT 1
- BackSpace Issue HOT 1
- need more layers (right alt) HOT 2
- Button Hold : Allow additional keys via options HOT 6
- `layoutCandidates` is not case sensitive HOT 1
- When simple-keyboard is used with accessibility voice over turned on, hitting q enters 1 in input HOT 1
- Simple-keyboard Not Rendering HOT 2
- When set layoutCandidatesPageSize = 15, There is an issue with the background color of the candidate box
- Not displaying keyboard outside app.component HOT 1
- Virtual Keyboard, keys are coming all white HOT 1
- Can this component be dragged by the mouse motor? 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 simple-keyboard.