Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TimePicker : [showSpinners]="false" not working #1672

Closed
industrylinq opened this issue Feb 21, 2017 · 6 comments · Fixed by #2058
Closed

TimePicker : [showSpinners]="false" not working #1672

industrylinq opened this issue Feb 21, 2017 · 6 comments · Fixed by #2058

Comments

@industrylinq
Copy link

"ng2-bootstrap": "1.3.3",

angular 2.4.8.

showMeridian is working as expected, however if I try to hide the chevrons by setting showSpinners to false the chevrons are still their.

Although it seems that hidden is actualy added to the chevrons class.

<tr class="text-center hidden" ng-reflect-klass="text-center" ng-reflect-ng-class="[object Object]">
          <td><a class="btn btn-link" ng-reflect-klass="btn btn-link" ng-reflect-ng-class="[object Object]"><span class="glyphicon glyphicon-chevron-up"></span></a></td>
          <td>&nbsp;</td>
          <td><a class="btn btn-link" ng-reflect-klass="btn btn-link" ng-reflect-ng-class="[object Object]"><span class="glyphicon glyphicon-chevron-up"></span></a></td>
          <!--template bindings={
  "ng-reflect-ng-if": "true"
}--><td ng-reflect-ng-class="[object Object]"></td>
        </tr>

@industrylinq
Copy link
Author

industrylinq commented Feb 21, 2017

I've placed showSpinner within a [hidden] tag instead of within the class and this seems to work perfectly.

template: "\n <table>\n <tbody>\n <tr [hidden]=\"!showSpinners\" class=\"text-center\" [ngClass]=\"{hidden: !showSpinners || readonlyInput}\">\n

@Uness77
Copy link

Uness77 commented Mar 9, 2017

any hack to fix this problem ? I was thinking about creating a TimePickerComponent but I was wondering if someone got an easier hack

@carlfarmer
Copy link

I got round this by simply adding the hidden class;

.hidden { display: none; }

@artemvfrolov artemvfrolov mentioned this issue Jun 15, 2017
valorkin added a commit that referenced this issue Jul 19, 2017
fixes #2036
fixes #1981 ( + min max demo )
fixes #1973
close #1957 ( + seconds demo )
fixes #1935
fixes #1672
feat #1007 added keyboard and mousewheel support
fixes #962
fixes #793
fixes #173
fixes #1271 added custom validation demo
fixes #1539 bs4
fixes #1253 if input is invalid

* feat(timepicker): new timepicker implementation

* feat(timepicker): new timepicker implementation testing

* chore(timepicker): removed old timepicker implementation

* chore(mini-ngrx): added ngrx licence

* fix(timepicker): fix seconds

* fix(timepicker): fix custom validation demo

* fix(tests): fix tests & aot errors

* fix(timepicker): min max restrictions

* fix(timepicker): min max checks

* feat(timepicker): add inputs validation (#2187)

* feat(timepicker): add inputs validation

* fix(timepicker): add isPM support

* feat(timepicker): add isValid output

* feat(timepicker): added test plan (#2127)

* fix(timepicker): fix ngModelChange demo

* fix(test): fix unit tests

* docs(timepicker): fix docs conflict, add isValid description
@kmaci3k
Copy link

kmaci3k commented Oct 26, 2017

Was the fix released in 1.9.3 version ? If so, it looks like [showSpinners]="false" still does not work.

@evilstiefel
Copy link

This still does not seem to work with Bootstrap 4.0.0 - [showSpinners]="false" has no effect on the display of arrows.

@nagos
Copy link
Contributor

nagos commented Apr 5, 2018

It does not work in bootstrap 4.
bootstrap migration guide

The .hidden and .show classes have been removed because they conflicted with jQuery’s $(...).hide() and $(...).show() methods. Instead, try toggling the [hidden] attribute or use inline styles like style="display: none;" and style="display: block;".

Now you can use workaroudn
.hidden { display: none; }

P.S. I made pull request for this. #4197

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants