You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 19, 2024. It is now read-only.
Copy file name to clipboardExpand all lines: guides/v2.0/frontend-dev-guide/themes/admin_theme_create.md
+13-6Lines changed: 13 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@ This topic describes how to create your custom theme for Magento Admin, referenc
20
20
21
21
[Set]({{page.baseurl}}config-guide/cli/config-cli-subcommands-mode.html) your Magento application to the developer [mode]({{page.baseurl}}config-guide/bootstrap/magento-modes.html). The application mode influences the way static files are cached by Magento.
22
22
23
-
## Create an Admin theme
23
+
## Overview
24
24
25
25
To create a custom Admin theme, take the following steps:
26
26
@@ -32,10 +32,10 @@ To create a custom Admin theme, take the following steps:
32
32
33
33
Each step is described further.
34
34
35
-
###Create a theme directory {#create_dir}
35
+
## Create a theme directory {#create_dir}
36
36
In the `app/design/adminhtml` directory create a new `<Vendor>/<admin_theme>` directory.
37
37
38
-
###Add a declaration `theme.xml` {#declare_theme}
38
+
## Add a declaration `theme.xml` {#declare_theme}
39
39
40
40
In the theme directory, add `theme.xml` containing at least the theme name and the parent theme name (if the theme [inherits]({{page.baseurl}}frontend-dev-guide/themes/theme-inherit.html) from one). We recommend you to inherit from the default Magento Admin theme: `Magento/backend`.
41
41
@@ -49,9 +49,11 @@ Configure it using the following example (replace placeholders with your theme i
49
49
<parent>%vendor_dir%/%parent_theme_dir%</parent> <!-- the parent theme. Example: Magento/backend -->
50
50
</theme>
51
51
52
+
If you change the theme title or parent theme information in `theme.xml` after a theme was already [registered](#register_theme), you need to open or reload any Magento Admin page for your changes to be saved in the database.
53
+
52
54
{%endhighlight%}
53
55
54
-
###Add `registration.php` {#add_registry}
56
+
## Add `registration.php` {#add_registry}
55
57
In your theme directory, create a `registration.php` file.
56
58
In this file, add the following code, having replaced placeholders with your theme information:
57
59
@@ -68,16 +70,21 @@ In this file, add the following code, having replaced placeholders with your the
See the [Make your theme a Composer package (optional)]({{page.baseurl}}frontend-dev-guide/themes/theme-create.html#fedg_create_theme_composer)
73
75
74
76
75
-
### Admin theme logo (optional) {#logo}
77
+
## Admin theme logo (optional) {#logo}
76
78
77
79
In the default `Magento/backend` theme `lib/web/images/magento-logo.svg` is used as theme logo.
78
80
To override it, in your theme directory, create a `web/images` sub-directory, and add your custom file named `magento-logo.svg`.
79
81
If you want to use the file with other name and/or format, you need to additionally declare it as described in [Declaring theme logo]({{page.baseurl}}frontend-dev-guide/themes/theme-create.html#logo_declare).
80
82
83
+
84
+
## Theme registration {#register_theme}
85
+
86
+
Once you open the Magento Admin (or reload any Magento Admin page) having added the theme files to the files system, your theme gets registered and added to the database.
87
+
81
88
## Apply the Admin theme
82
89
83
90
See the [Apply a custom Admin theme topic]({{page.baseurl}}frontend-dev-guide/themes/admin_theme.html).
Copy file name to clipboardExpand all lines: guides/v2.0/frontend-dev-guide/themes/theme-create.md
+11-1Lines changed: 11 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -65,6 +65,11 @@ After you create a directory for your theme, you must create `theme.xml` contain
65
65
</theme>
66
66
{% endhighlight %}
67
67
68
+
<divclass="bs-callout bs-callout-info"id="info">
69
+
<p>If you update theme.xml later</p>
70
+
</div>
71
+
72
+
If you change the theme title or parent theme information in `theme.xml` after a theme was already [registered](#register_theme), you need to open or reload any Magento Admin page for your changes to be saved in the database.
68
73
69
74
## Make your theme a Composer package (optional) {#fedg_create_theme_composer}
70
75
@@ -247,7 +252,12 @@ To learn more about theme layouts, refer to the <a href="{{page.baseurl}}fronten
247
252
248
253
249
254
## What's next {#next}
250
-
See the [Apply and configure a theme in Admin]({{page.baseurl}}frontend-dev-guide/themes/theme-apply.html) topic.
255
+
256
+
### Theme registration {#register_theme}
257
+
Once you open the Magento Admin (or reload any Magento Admin page) having added the theme files to the files system, your theme gets registered and added to the database.
258
+
259
+
### Applying a theme
260
+
For information on how to apply the theme for the storefront, see the [Apply and configure a theme in Admin]({{page.baseurl}}frontend-dev-guide/themes/theme-apply.html) topic.
0 commit comments