All Projects → erikvullings → mithril-materialized

erikvullings / mithril-materialized

Licence: MIT license
A Materialize-css library for the Mithril framework.

Programming Languages

typescript
32286 projects
CSS
56736 projects
javascript
184084 projects - #8 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to mithril-materialized

mithril-datepicker
Pick a date! But only if you're using Mithril. (component for Mithril.js ^v1.0)
Stars: ✭ 23 (+4.55%)
Mutual labels:  mithril, mithril-components
easy-materialize-rtl
Simple way to set RTL for materializecss.com.
Stars: ✭ 20 (-9.09%)
Mutual labels:  materializecss, materialize
materialize-social
Social Login Buttons for MaterializeCSS
Stars: ✭ 50 (+127.27%)
Mutual labels:  materializecss
mithril-hooks
Use hooks in Mithril
Stars: ✭ 37 (+68.18%)
Mutual labels:  mithril
materializecss starter
A Starter Boilerplate for Materializecss, ionicons, font-awesome and Animatecss
Stars: ✭ 58 (+163.64%)
Mutual labels:  materializecss
angular-model-pattern-example
Model pattern for Angular (2, 4, ...), manage and share your state with simple services using RxJS Subjects and Observables
Stars: ✭ 37 (+68.18%)
Mutual labels:  materializecss
mopt
Babel plugin to optimize Mithril m() calls into simple JS objects for speed
Stars: ✭ 45 (+104.55%)
Mutual labels:  mithril
fimfic2epub
📚 Chrome/Firefox extension & npm package for improved EPUB export on fimfiction.net
Stars: ✭ 17 (-22.73%)
Mutual labels:  mithril
crispy-forms-materialize
Django application to add materializecss support to django-crispy-forms
Stars: ✭ 20 (-9.09%)
Mutual labels:  materializecss
componentity
Thousands of components ready to be copy-pasted!
Stars: ✭ 15 (-31.82%)
Mutual labels:  materializecss
zhihu-daily
知乎日报(Vuejs)
Stars: ✭ 45 (+104.55%)
Mutual labels:  materialize
polythene-mithril-setup
Minimal setup example how to create a Polythene app.
Stars: ✭ 16 (-27.27%)
Mutual labels:  mithril
brush
An amazing scaffolding for developing database-driven websites, applications and APIs. Built on Laravel Lumen Framework, MySQL and Angular.
Stars: ✭ 23 (+4.55%)
Mutual labels:  materializecss
djadmin
Djadmin is a django admin theme
Stars: ✭ 42 (+90.91%)
Mutual labels:  materializecss
defe
devfeed is a Tech feed Aggregator for Developers & Tech Enthusiasts
Stars: ✭ 28 (+27.27%)
Mutual labels:  materializecss
News-Manager
🗞news scraping and recommendation system
Stars: ✭ 14 (-36.36%)
Mutual labels:  materialize-css
Bank-Account-Simulation
A Bank Account Simulation with JavaFX and SQLite back-end. Material UX|UI.
Stars: ✭ 19 (-13.64%)
Mutual labels:  materialize-css
Smartshop
An e-commerce php/mysql website built from scratch (Deprecated)
Stars: ✭ 46 (+109.09%)
Mutual labels:  materializecss
chrome-snowplow-inspector
Web Extension for debugging Snowplow pixels.
Stars: ✭ 26 (+18.18%)
Mutual labels:  mithril
Think-Incognito
You Think You Are Incognito? People can't TRACK you? This Will PROVE You Wrong. Open website: http://tinyurl.com/think-incognito Now
Stars: ✭ 35 (+59.09%)
Mutual labels:  materialize-css

mithril-materialized

A materialize-css library, available on npm, for the Mithril framework (tested with v2.0.0-rc7 and higher, but presumably, it should work with v1.1.6 too), making it easier to use a Materialize theme in your application. This library provides you with Mithril components, wrapping around the materialize-css functionality.

Supported components:

  • Buttons
    • Button
    • FlatButton
    • RoundButton
    • SubmitButton
  • Inputs
    • TextInput
    • TextArea
    • AutoComplete
    • UrlInput
    • EmailInput
    • NumberInput
    • ColorInput
    • RangeInput
    • Chips
  • Pickers
    • DatePicker
    • TimePicker
  • Selections
    • Select
    • Options
    • RadioButtons
    • Switch
    • Dropdown
  • Collections
    • Basic, Link and Avatar Collections
    • Collapsible or accordion
  • Others
    • ModalPanel
    • MaterialBox
    • Carousel
    • Pagination
    • Parallax
  • Additional
    • Label
    • HelperText
  • Not from Materialize-CSS

Usage instructions

See the documentation for examples on how to use this library in your own application. Please note that the library does not include mithril, nor the materialize-css JavaScript or CSS, so you have to include them yourself, as documented.

Build instructions

This repository consists of two packages, combined using lerna: the lib package that is published to npm, as well as an example project which uses this library to display the Mithril components that it contains.

To install the dependencies, you can use npm i, or, alternatively, use pnpm m i (assuming you have installed pnpm as alternative package manager using npm i -g pnpm) to perform a multi-repository install. Next, build everything using npm start and visit the documentation page on http://localhost:1234 in case port 1234 is not occupied already.

CSS

Although I've tried to limit the CSS adaptations to a minimum, I needed to tweak certain parts to make it look better. You can either copy them manually, or import them, e.g.

import 'mithril-materialized/dist/index.css';

Here are the styles I've added.

/* For the switch */
.clear,
.clear-10,
.clear-15 {
  clear: both;
  /* overflow: hidden; Précaution pour IE 7 */
}
.clear-10 {
  margin-bottom: 10px;
}
.clear-15 {
  margin-bottom: 15px;
}

span.mandatory {
  margin-left: 5px;
  color: red;
}

label+.switch {
  margin-top: 1rem;
}

/* For the color input */
input[type='color']:not(.browser-default) {
  margin: 0px 0 8px 0;
  /** Copied from input[type=number] */
  background-color: transparent;
  border: none;
  border-bottom: 1px solid #9e9e9e;
  border-radius: 0;
  outline: none;
  height: 3rem;
  width: 100%;
  font-size: 16px;
  padding: 0;
  -webkit-box-shadow: none;
  box-shadow: none;
  -webkit-box-sizing: content-box;
  box-sizing: content-box;
  -webkit-transition: border 0.3s, -webkit-box-shadow 0.3s;
  transition: border 0.3s, -webkit-box-shadow 0.3s;
  transition: box-shadow 0.3s, border 0.3s;
  transition: box-shadow 0.3s, border 0.3s, -webkit-box-shadow 0.3s;
}

/* For the options' label */
.input-field.options > label {
  top: -2.5rem;
}

/* For the code block */
.codeblock {
  margin: 1.5rem 0 2.5rem 0;
}
.codeblock > div {
  margin-bottom: 1rem;
}
.codeblock > label {
  display: inline-block;
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].