Open henrikvoetmand opened 1 year ago
A few thoughts regarding this issue.
The current functionality allows for everything to be inserted. It just needs a kirby-affix
directive which is valid on any element. Elements are centered vertically with flex
So any instances where an element seems to not be vertically aligned is the fault of the inserted element itself. Which can be fixed with individual styling on the inserted element. (In your application) Personally I don't think it would be a good idea to start implementing styling logic that is conditional on the affix element type.
In regards to horizontal spacing it is derived from default kirby-input
horizontal padding from affix to the relevant edge (suffix = padding-right / prefix = padding-left) while the "inside" padding (between text and affix) is half of default kirby-input
padding.
These padding values are easy to change and if we can solve most issues that way, I think it would be the best solution.
When it comes to limiting affix element to icons
, icon buttons
and text
I am strongly apposed to this.
Some reasons why I don't like it:
I hope this makes sense :)
TLDR:
I believe @henrikvoetmand and I came to this conclusion.
So 16/12px fixed padding.
If this is acceptable. It should be easy to move forward.
Describe the enhancement
Adjustment to input with affix. We want to align Icon and icon-btn affix.
Describe the solution you'd like
Adjust spacing and placement of icon and icon btn. Consider limiting the affix elements to only icons, icon buttons and text.
Have you considered any alternatives?
Are there any additional context?
https://zpl.io/Z08z7Kd
Checklist:
The following tasks should be carried out in sequence in order to follow the process of contributing correctly.
Refinement
Implementation
The contributor who wants to implement this issue should:
Review
Once the issue has been implemented and is ready for review: