material-design

Add icon (e.g. material design or Prime Icons) to a p:inputText

旧街凉风 提交于 2020-03-16 07:01:48
问题 I want to add an icon for an input text element, in a JavaEE project: <h:panelGroup styleClass="md-inputfield"> <p:inputText id="name" value="#{createCustomerView.customer.name}" required="true" label="Nome" requiredMessage="inserisci il nome"> <f:validateLength minimum="2" /> </p:inputText> <p:outputLabel for="name" value="Nome" /> <p:message for="name" display="icon" /> </h:panelGroup> How Can add an icon, like a person icon? 回答1: You can make use of Primefaces input group. refer https:/

Remove space between bounds and button border

南笙酒味 提交于 2020-03-16 06:42:28
问题 How do I remove those space between Button border and view bounds tried setting padding to 0dp but with no results. These is material button with default style. 回答1: The MaterialButton has a default style with these insets: <style name="Widget.MaterialComponents.Button"..> <item name="android:insetLeft">0dp</item> <item name="android:insetRight">0dp</item> <item name="android:insetTop">@dimen/mtrl_btn_inset</item> <item name="android:insetBottom">@dimen/mtrl_btn_inset</item> ... </style> The

Remove space between bounds and button border

别等时光非礼了梦想. 提交于 2020-03-16 06:42:22
问题 How do I remove those space between Button border and view bounds tried setting padding to 0dp but with no results. These is material button with default style. 回答1: The MaterialButton has a default style with these insets: <style name="Widget.MaterialComponents.Button"..> <item name="android:insetLeft">0dp</item> <item name="android:insetRight">0dp</item> <item name="android:insetTop">@dimen/mtrl_btn_inset</item> <item name="android:insetBottom">@dimen/mtrl_btn_inset</item> ... </style> The

dynamically insert mat-checkbox

家住魔仙堡 提交于 2020-03-04 11:29:15
问题 I want to dynamically insert a <mat-checkbox> element into a component. and I inserted two <mat-checkbox> elements. one inserted statically (i.e into the template file directly). and the other one inserted dynamically, and contains a <mat-checkbox> and another normal checkbox <input type="checkbox" /> the first one (the statically inserted one) rendered without any problem. also the normal input inserted dynamically without any problem. but the <mat-checkbox> that dynamically inserted didn't

Bottom app bar problem with placing icons

寵の児 提交于 2020-03-01 04:09:02
问题 I have a problem with bottom app bar, because I want the icons to be displayed to me in the first picture Instead I got this: 回答1: You can place a custom layout inside your BottomAppBar . The only thing is that you will need to align items in your custom layout manually. <com.google.android.material.bottomappbar.BottomAppBar xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" style="@style/Widget.MaterialComponents.BottomAppBar"

Bottom app bar problem with placing icons

安稳与你 提交于 2020-03-01 04:06:59
问题 I have a problem with bottom app bar, because I want the icons to be displayed to me in the first picture Instead I got this: 回答1: You can place a custom layout inside your BottomAppBar . The only thing is that you will need to align items in your custom layout manually. <com.google.android.material.bottomappbar.BottomAppBar xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" style="@style/Widget.MaterialComponents.BottomAppBar"

How to enlarge the SVG icon in material-ui iconButtons?

吃可爱长大的小学妹 提交于 2020-02-26 11:32:04
问题 Has anyone build webpages using react.js and the Material UI library? How should I resize the icon size? It is a svg icon. I just built an "create new" component, which is a piece of material paper with a content add button on the top. Here is the code. import React from 'react'; import Paper from 'material-ui/lib/paper'; import ContentAdd from 'material-ui/lib/svg-icons/content/add'; import IconButton from 'material-ui/lib/icon-button'; const styleForPaper = { width: '96vw', height: '20vh',

Material Design autocomplete make an item unselectable

醉酒当歌 提交于 2020-02-25 13:40:27
问题 I'm using Material Design and AngularJS and I want to display some unselectable element in my autocomplete. My autocomplete display entity that could be linked with the entity that the user is working on. Some of these entities are already linked to another entity. I want to display them but make them unselectable. Here my autocomplete in a tpl.html file : <md-autocomplete md-no-cache="noCache" md-selected-item="selectedItem" md-search-text="searchText" md-selected-item-change= "controller

Material Design autocomplete make an item unselectable

╄→尐↘猪︶ㄣ 提交于 2020-02-25 13:40:27
问题 I'm using Material Design and AngularJS and I want to display some unselectable element in my autocomplete. My autocomplete display entity that could be linked with the entity that the user is working on. Some of these entities are already linked to another entity. I want to display them but make them unselectable. Here my autocomplete in a tpl.html file : <md-autocomplete md-no-cache="noCache" md-selected-item="selectedItem" md-search-text="searchText" md-selected-item-change= "controller

CardView with different corner radius

混江龙づ霸主 提交于 2020-02-20 08:07:03
问题 I have the following CardView and I want to set different radius for each corner in the card. Is it possible to change them by XML or programmaticaly? Thanks in advance. <android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginRight="16dp" android:layout_marginLeft="16dp" android:layout_marginTop="5dp" android