Giter Club home page Giter Club logo

Comments (8)

hexadecy avatar hexadecy commented on August 11, 2024

Ok I will add a show-clear option.

from angular-material-datetimepicker.

hexadecy avatar hexadecy commented on August 11, 2024

Option show-clear added in: 307a514 v1.19.1
The label should be normally above the input.
dtp-input can be override with a css like: .dtp .dtp-input

Can you provide me a full example? (code) or better jsFiddle.

from angular-material-datetimepicker.

oliversalzburg avatar oliversalzburg commented on August 11, 2024

https://codepen.io/oliversalzburg/pen/NWKyJrd should showcase the issue with the label intersecting with the picker icon.

Also notice that, when you remove the .dtp-input, it has no effect on how the input is rendererd, which lead me to believe the class is actually redundant.

Thanks for the show-clear! I'll test it out ASAP

from angular-material-datetimepicker.

hexadecy avatar hexadecy commented on August 11, 2024

It's because this picker needs the placeholder attribute.

doctype html
html(
	ng-csp
	ng-app="foo"
	)
	md-input-container.md-block
		label Start
		input.dtp-no-msclear.dtp-input.md-input(
			type="text"
			mdc-datetime-picker
			date="false"
			time="true"
			minutes="true"
			ng-model-options="{timezone: meeting.fair.timezone}"
			format="LT"
			edit-input="true"
			show-icon="true"
			ng-model="vm.meeting.start"
			placeholder="Enter time"
			)

from angular-material-datetimepicker.

oliversalzburg avatar oliversalzburg commented on August 11, 2024

It's because this picker needs the placeholder attribute.

Oh yeah, that's much better 😀 Thanks for that. What about the dtp-input class though? It seems like it's not doing anything. And if you were to remove the show-icon, it even looks weird for being indented under the label.

image

from angular-material-datetimepicker.

oliversalzburg avatar oliversalzburg commented on August 11, 2024

show-clear is working perfectly btw. Thanks again

from angular-material-datetimepicker.

hexadecy avatar hexadecy commented on August 11, 2024

Class like .dtp-no-msclear or .dtp-input are added by the datetime-picker component only when show-icon is "true". Most of the code in this fork is for a special use case.

html(
	ng-csp
	ng-app="foo"
	)
	md-input-container.md-block
		label Start
		input(
			type="text"
			mdc-datetime-picker
			date="false"
			time="true"
			minutes="true"
			ng-model-options="{timezone: meeting.fair.timezone}"
			format="LT"
			edit-input="true"
			show-icon="false"
			ng-model="vm.meeting.start"
			)

Please check examples at: https://github.com/beenote/angular-material-datetimepicker/blob/gh-pages/index.html

from angular-material-datetimepicker.

oliversalzburg avatar oliversalzburg commented on August 11, 2024

Oh, I see. I just copied directly from https://beenote.github.io/angular-material-datetimepicker/ and didn't think the class would be added by the directive. Thanks

from angular-material-datetimepicker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.