<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://www.logicwiki.co.uk/index.php?action=history&amp;feed=atom&amp;title=Material_UI_Basics</id>
		<title>Material UI Basics - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://www.logicwiki.co.uk/index.php?action=history&amp;feed=atom&amp;title=Material_UI_Basics"/>
		<link rel="alternate" type="text/html" href="https://www.logicwiki.co.uk/index.php?title=Material_UI_Basics&amp;action=history"/>
		<updated>2026-05-15T16:45:51Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.26.2</generator>

	<entry>
		<id>https://www.logicwiki.co.uk/index.php?title=Material_UI_Basics&amp;diff=2439&amp;oldid=prev</id>
		<title>AliIybar: Created page with &quot;Category:Material  == Spacing == === Notation === The space utility converts shorthand margin and padding props to margin and padding CSS declarations. The props are named...&quot;</title>
		<link rel="alternate" type="text/html" href="https://www.logicwiki.co.uk/index.php?title=Material_UI_Basics&amp;diff=2439&amp;oldid=prev"/>
				<updated>2024-12-24T12:42:08Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;&lt;a href=&quot;/index.php?title=Category:Material&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;Category:Material (page does not exist)&quot;&gt;Category:Material&lt;/a&gt;  == Spacing == === Notation === The space utility converts shorthand margin and padding props to margin and padding CSS declarations. The props are named...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;[[Category:Material]]&lt;br /&gt;
&lt;br /&gt;
== Spacing ==&lt;br /&gt;
=== Notation ===&lt;br /&gt;
The space utility converts shorthand margin and padding props to margin and padding CSS declarations. The props are named using the format '''{property}{sides}'''.&lt;br /&gt;
&lt;br /&gt;
Where property is one of:&lt;br /&gt;
* m - for classes that set margin&lt;br /&gt;
* p - for classes that set padding&lt;br /&gt;
Where sides is one of:&lt;br /&gt;
* t - for classes that set margin-top or padding-top&lt;br /&gt;
* b - for classes that set margin-bottom or padding-bottom&lt;br /&gt;
* l - for classes that set margin-left or padding-left&lt;br /&gt;
* r - for classes that set margin-right or padding-right&lt;br /&gt;
* x - for classes that set both *-left and *-right&lt;br /&gt;
* y - for classes that set both *-top and *-bottom&lt;br /&gt;
* blank - for classes that set a margin or padding on all 4 sides of the element&lt;br /&gt;
&lt;br /&gt;
=== Transformation ===&lt;br /&gt;
&lt;br /&gt;
Depending on the input and the theme configuration, the following transformation is applied:&lt;br /&gt;
&lt;br /&gt;
input: number &amp;amp; theme: number: the prop value is multiplied by the theme value.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
const theme = {&lt;br /&gt;
  spacing: 8,&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;Box sx={{ m: -2 }} /&amp;gt; // margin: -16px;&lt;br /&gt;
&amp;lt;Box sx={{ m: 0 }} /&amp;gt; // margin: 0px;&lt;br /&gt;
&amp;lt;Box sx={{ m: 0.5 }} /&amp;gt; // margin: 4px;&lt;br /&gt;
&amp;lt;Box sx={{ m: 2 }} /&amp;gt; // margin: 16px;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
input: number &amp;amp; theme: array: the prop value is used as the array index.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
const theme = {&lt;br /&gt;
  spacing: [0, 2, 3, 5, 8],&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;Box sx={{ m: -2 }} /&amp;gt; // margin: -3px;&lt;br /&gt;
&amp;lt;Box sx={{ m: 0 }} /&amp;gt; // margin: 0px;&lt;br /&gt;
&amp;lt;Box sx={{ m: 2 }} /&amp;gt; // margin: 3px;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
input: number &amp;amp; theme: function: the function is called with the prop value.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
const theme = {&lt;br /&gt;
  spacing: value =&amp;gt; value * 2,&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;Box sx={{ m: 0 }} /&amp;gt; // margin: 0px;&lt;br /&gt;
&amp;lt;Box sx={{ m: 2 }} /&amp;gt; // margin: 4px;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
input: string: the prop value is passed as raw CSS value.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;Box sx={{ m: '2rem' }} /&amp;gt; // margin: 2rem;&lt;br /&gt;
&amp;lt;Box sx={{ mx: 'auto' }} /&amp;gt; // margin-left: auto; margin-right: auto;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>AliIybar</name></author>	</entry>

	</feed>