Rohan Maity
01/16/2022, 9:30 AM@material/textfield
in my project
https://www.npmjs.com/package/@material/textfield
I have added the following dependency as
implementation(npm("@material/textfield", "13.0.0")
But after that, I am not able to understand, how to create the an adapter file for this
Its not a simple function
Does anyone here have similar problem or used npm dependency in kotlin web ?turansky
01/16/2022, 10:12 AMRohan Maity
01/16/2022, 10:14 AMRohan Maity
01/16/2022, 10:14 AMBig Chungus
01/16/2022, 10:27 AMturansky
01/16/2022, 11:01 AMIt says these are auto generated, is there a tool for this ?Generators are here
Rohan Maity
01/16/2022, 11:05 AMBig Chungus
01/16/2022, 11:06 AMRohan Maity
01/16/2022, 11:06 AMRohan Maity
01/16/2022, 11:16 AMRohan Maity
01/16/2022, 11:16 AMBig Chungus
01/16/2022, 11:18 AMRohan Maity
01/16/2022, 11:43 AMtypes/kotlin
repo, seems to be auto genrated againBig Chungus
01/16/2022, 11:45 AMBig Chungus
01/16/2022, 11:45 AMBig Chungus
01/16/2022, 11:46 AMRohan Maity
01/16/2022, 11:53 AMturansky
01/16/2022, 11:56 AMI am still not able to see any library/tool which generates declarationsCustom generator located in
buildSrc
It’s not a ducat 🙂Big Chungus
01/16/2022, 11:59 AMRohan Maity
01/16/2022, 12:01 PMturansky
01/16/2022, 12:04 PMRohan Maity
01/16/2022, 12:05 PMturansky
01/16/2022, 12:06 PMturansky
01/16/2022, 12:07 PMRohan Maity
01/16/2022, 12:08 PMBig Chungus
01/16/2022, 12:23 PMRohan Maity
01/16/2022, 12:35 PMMDCTextField
But is not getting evenly spread
But with core TextInput
got evenly spread
Div(
attrs = {
style {
display(DisplayStyle.Flex)
width(100.percent)
justifyContent(JustifyContent.SpaceBetween)
flexFlow(FlexDirection.Row, FlexWrap.Nowrap)
}
}
) {
val annualCtcState = remember { mutableStateOf("") }
MDCTextField(
annualCtcState.value,
{
type = MDCTextFieldCommonOpts.Type.Outlined
label = "Annual CTC"
},
{
style {
margin(8.px)
width(33.percent)
title("Annual CTC")
}
onInput {
annualCtcState.value = it.value
}
}
)
@Big Chungus 😕Big Chungus
01/16/2022, 12:39 PMGabriel Duncan
01/16/2022, 1:22 PMBig Chungus
01/16/2022, 1:27 PMBig Chungus
01/16/2022, 1:28 PMBig Chungus
01/16/2022, 1:29 PMGabriel Duncan
01/16/2022, 1:32 PMBig Chungus
01/16/2022, 2:04 PMBig Chungus
01/16/2022, 2:04 PMBig Chungus
01/16/2022, 2:04 PMRohan Maity
01/16/2022, 2:20 PMBig Chungus
01/16/2022, 3:26 PMBig Chungus
01/16/2022, 3:26 PMRohan Maity
01/16/2022, 4:29 PMRohan Maity
01/16/2022, 4:33 PMmdc-text-field
but I was not able to
So you created a style which would need to be applied to the parent which in turn apply a the style to all the child of the parent for a particular classname mentioned in the styleBig Chungus
01/16/2022, 4:34 PMBig Chungus
01/16/2022, 4:35 PMRohan Maity
01/16/2022, 4:35 PMBig Chungus
01/16/2022, 4:38 PMBig Chungus
01/16/2022, 4:39 PMRohan Maity
01/16/2022, 5:13 PM@mateiral/textField
issue or something happened due to kmdc onlyBig Chungus
01/16/2022, 5:54 PMRohan Maity
01/17/2022, 5:05 AMRohan Maity
01/17/2022, 5:05 AMRohan Maity
01/17/2022, 5:50 AMRohan Maity
01/17/2022, 7:59 AMmdc-text-field-focusd
class gets removed from the HTML whenever I input something. I was not able to see code which handles the input. AFAIU its using simple TextInput
from basic compose web. Now IMO, this simple TextInput
is not able to maintain the state of being focused (mdc-text-field-focused
) on input
• Floating label gets cut when I tap outside of text field after typing some input. After typing some input and clicking outside. (Not sure which event is triggered on clicking outside) MDCNotch Span
width gets changed to random specific value. But it should have been fit-content.
I have highlighted the span in the attached image