material-design

How to expand a card on tap in flutter?

落花浮王杯 提交于 2019-12-22 06:35:23
问题 I would like to achieve the material design card behavior on tap. When I tap it, it should expand fullscreen and reveal additional content/new page. How do I achieve it? https://material.io/design/components/cards.html#behavior I tried with Navigator.of(context).push() to reveal new page and play with Hero animations to move the card background to new Scaffold, however it seems it is not the way to go since new page is not revealing from the card itself, or I cannot make it to. I am trying to

Change ListView's ScrollBar/FastScroll color?

♀尐吖头ヾ 提交于 2019-12-22 05:32:04
问题 My app has an orange theme all over but the ScrollBar/FastScroll is appearing green. I've tried to search a lot but can't find any way to change this. It just stays the way it is. I found a "android:fastScrollTextColor" property but that changes the color of the B inside the bubble. And I can't find any property to change the color of this bubble or the ScrollBar next to it. In case it makes a difference I'm using the custom PinnedHeaderListView that I got from here to mimic the sticky

Angularjs with material design Failed to instantiate module ngMaterial

自闭症网瘾萝莉.ら 提交于 2019-12-22 04:58:16
问题 I have installed angularjs and materialjs using bower. bower install angular-material And injected 'ngMaterial' into my app but getting this error. Uncaught Error: [$injector:modulerr] Failed to instantiate module demoApp due to: Error: [$injector:modulerr] Failed to instantiate module ngMaterial due to: Error: [$injector:modulerr] Failed to instantiate module material.core due to: Error: [$injector:unpr] Unknown provider: $mdUtilProvider Any Help. 回答1: I had the same problem until I changed

Primary color (sometimes) goes transparent

偶尔善良 提交于 2019-12-22 04:38:05
问题 I am developing with the latest SDK version (API 21) and Support Library 21.0.2 and I've been having trouble when trying to implement the new Material Design guidelines. Material Design says that I need to have my primary color and my accent color and apply them over my app. But sometimes when I open the app the primary color becomes transparent in some widgets, it goes back to normal until I close the app (with the Back Button) and launch it again. Here is an example of the primary color

How to use paper-dialog polymer element?

与世无争的帅哥 提交于 2019-12-22 04:09:42
问题 I am using the element by adding opening and closing tags <paper-dialog><p>This is it</p></paper-dialog> but it is not getting shown up. Do I need to add some script on top of it so that it should be triggered on some event? Or is there some another way to make it visible ? 回答1: The dialog itself is autohidden. You usually toggle it with a button. For example, give the dialog an id="dialog" and make the button on-tap="toggleDialog" , which would be toggleDialog: () => { this.$.dialog.toggle()

Change layout_scrollFlags programmatically in CollapsingToolbarLayout

这一生的挚爱 提交于 2019-12-22 03:17:30
问题 I have the following CollapsingToolbarLayout tag in my xml: <android.support.design.widget.CollapsingToolbarLayout android:id="@+id/collapsingToolbarLayout" android:layout_width="match_parent" android:layout_height="match_parent" app:contentScrim="?attr/colorPrimary" app:expandedTitleMarginStart="@dimen/expanded_toolbar_title_margin_start" app:layout_scrollFlags="exitUntilCollapsed"> I would like to change the scrollFlags value programmatically (run time) - specifically, toggle the scrollable

Change layout_scrollFlags programmatically in CollapsingToolbarLayout

旧街凉风 提交于 2019-12-22 03:17:12
问题 I have the following CollapsingToolbarLayout tag in my xml: <android.support.design.widget.CollapsingToolbarLayout android:id="@+id/collapsingToolbarLayout" android:layout_width="match_parent" android:layout_height="match_parent" app:contentScrim="?attr/colorPrimary" app:expandedTitleMarginStart="@dimen/expanded_toolbar_title_margin_start" app:layout_scrollFlags="exitUntilCollapsed"> I would like to change the scrollFlags value programmatically (run time) - specifically, toggle the scrollable

Material Design 2 Tabs aligned at bottom

北城余情 提交于 2019-12-22 01:32:08
问题 I want to have tabs aligned at the bottom of the md-tab-group , like shown below: It is possible in Material 1 using md-tabs-align="bottom" . Is there anything available in Material 2 for this purpose? Here is my code: <md-tab-group> <md-tab label="Tab One"> Tab One Contents </md-tab> <md-tab label="Tab Two"> Tab Two Contents </md-tab> </md-tab-group> 回答1: For whomever may stumble across this question. The Tabs section of the component demo site references the following in the API Reference

Elevation not working

给你一囗甜甜゛ 提交于 2019-12-22 00:20:32
问题 I'm trying to get a 4dp elevation on a button in a sample app and I can't seem to get any shadow to show up. This is my code: <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" tools:context=".MainActivity" android:clipChildren="false" android:orientation="vertical"> <Button android:layout_width="wrap_content" android:layout_height="wrap_content"

How to set vertical alignment for mdRadioButton directive of Angular Material related to text?

断了今生、忘了曾经 提交于 2019-12-21 22:21:48
问题 How to set vertical alignment for mdRadioButton directive of Angular Material related to text? I have tried both layout-align and vertical-align style but, the radio button is always align middle related to the text. here is the plunker <md-content> <md-radio-group ng-model="data" style="vertical-align:top;"> <md-radio-button value="a" aria-label="Label 1" style="vertical-align:text-top;">long text 1</md-radio-button> <md-radio-button value="b"> long text 2 </md-radio-button> </md-radio-group