material-design

Background image dimension for Navigation Drawer header

独自空忆成欢 提交于 2020-01-12 00:39:33
问题 Basically I liked the background used by Mr. Jonathan Lee for Navigation Drawer header back ground in google official link http://www.google.com/design/spec/patterns/navigation-drawer.html#navigation-drawer-content So I wanted to reproduce something similar inspired by that. I believe that I need to make a similar design in photoshop and set it as the background image. But the question is, what should be the dimensions and pixels so that it matches different kind of devices? The above link

Angular Material Design - Change flex value with screen size

不打扰是莪最后的温柔 提交于 2020-01-11 17:15:28
问题 I'm new to AngularJS so please bear with me. I'm using Angular Material Design and I have difficulties in identifying a way to efficiently do responsive grids. Please see my comments in the code below: <div layout="row"> <div layout="row" flex="75" layout-sm="column" class="ptn-info-grid" layout-margin> <!-- USING ROW FOR DESKTOP AND COLUMN FOR MOBILE DEVICES --> <div layout="column" flex="66"> <!-- I want this div occupy 2/3 of screen in Desktop but change to 100 in mobile devices (but stays

Using a Material-based Dialog Theme with AppCompat

会有一股神秘感。 提交于 2020-01-11 15:37:07
问题 I have an activity in my Manifest I used to style with a Dialog Theme. I can not find how to replace this in AppCompat library. <activity android:name=".LoginActivity" android:theme="@android:styles/Theme.Holo.Dialog" android:configChanges="orientation|screenSize|keyboardHidden" android:label="Login" > Is there a Material-based equivalent? 回答1: There is no material based theme for a dialog in AppCompat yet, see here Will appcompat automatically theme dialogs to look like the Lollipop version?

How to let the Spinner items appear below itself when being clicked and with full width, like on G+ app

雨燕双飞 提交于 2020-01-11 04:58:05
问题 background Google plus has a spinner-like view that shows a lot of items, but all of them appear below itself: I need to mimic this in my own spinner (that's what I was told), but as of recently, Material-Design guidelines say (here) the Spinner should put its items on top of itself, and that's what the support library does for it. The problem I can't find a way to revert this behavior. I've tried changing the style of the Spinner, and also searched about this on the Internet (and here). The

Material Button - Styles not being applied correctly, ugly as hell

谁说胖子不能爱 提交于 2020-01-06 18:35:53
问题 The ugly result: My layout: <?xml version="1.0" encoding="utf-8"?> <android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent"> <com.google.android.material.button.MaterialButton android:id="@+id/material_text_button" style="@style/Widget.MaterialComponents.Button.TextButton"

In material-ui how do i get a text input in an AppBar to the center?

我怕爱的太早我们不能终老 提交于 2020-01-06 15:28:09
问题 Iv defined an app bar using material-ui (app-bar-docs), and it includes a children attribute which can be used to add content to it (the docs mention things like tabs can be added to the appbar). However, i want to have a text input inside the Appbar, but it ends up to the right, after an iconelementright , how do i get it back to the center? here is the code: class AppBarExampleIconButton extends React.Component { render() { return ( <AppBar title={<span style={styles.title}>Title</span>}

Configure Webpack to resolve relative paths

两盒软妹~` 提交于 2020-01-05 08:52:42
问题 I am trying to implement Material Web Components into my Web App as per Material Component Web's Getting Started Guide. I was able to successfully set up Webpack (V3) to load the SASS for a web component. This was after running into a problem with the include path. I was able to resolve this by adding this line to my webpack.config.js . { loader: 'sass-loader', options: { includePaths: ['./node_modules'] } } However, I wasn't as successful compiling the JS. The component in question is

Persistent Bottom Sheet with rounded corners in Android crashes when used in a card view

∥☆過路亽.° 提交于 2020-01-05 04:57:22
问题 I have created a persistent bottom sheet in android with the intent of displaying a ListView containing additional information about locations. I want the sheet to have rounded corners. I got a ton of results for modal dialog but none for persistent. Is it possible or should I use the modal version? As suggested in an answer here, I tried wrapping it in a card view but the app crashes when I try to open the fragment. <?xml version="1.0" encoding="utf-8"?> <androidx.coordinatorlayout.widget

Implementing an RecycleView or CardView items with the same design for eachother

萝らか妹 提交于 2020-01-05 02:55:36
问题 I need to know, when the user clicking on one item(or for example, whatsApp contacts) WhatsApp showing to the user one design with this picture example: here is the recycle view items: and i'm using : http://code.tutsplus.com/tutorials/getting-started-with-recyclerview-and-cardview-on-android--cms-23465 Main-activity: public class MainActivity extends AppCompatActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout

Remove blur effect from child element with relative position

爷,独闯天下 提交于 2020-01-05 02:47:27
问题 I am using material card and want to make background blur but don't want blur effect on a div. <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons"> <link rel="stylesheet" href="https://code.getmdl.io/1.3.0/material.indigo-pink.min.css"> <script defer src="https://code.getmdl.io/1.3.0/material.min.js"></script> <div style="background:url(https://www.allaboutbirds.org/guide/assets/og/75335251-1200px.jpg) center / cover;filter: blur(5px);z-index: 0;" class="remo