Skip to content
This repository has been archived by the owner on Dec 31, 2021. It is now read-only.

Commit

Permalink
Add win-7 theme to documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
benjaminsattler committed May 31, 2020
1 parent 23f2efd commit 76d1ba5
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 1 deletion.
23 changes: 22 additions & 1 deletion README.md
Expand Up @@ -96,10 +96,31 @@ Similarly, here are two examples creating windows with light and dark win-xp the
</os-window>
```

Finally, here are two examples creating windows with light and dark win-7 theme:

```html
<os-window
window-title="Random Cat Pic"
os-theme="win-7"
>
<img src="http://www.randomkittengenerator.com/cats/rotator.php">
</os-window>

<os-window
window-title="Random Cat Pic"
os-theme="win-7"
theme="dark"
>
<img src="http://www.randomkittengenerator.com/cats/rotator.php">
</os-window>
```

![mac light theme](./doc/img/macos-light.png)
![mac dark theme](./doc/img/macos-dark.png)
![win-xp light theme](./doc/img/win-xp-light.png)
![win-xp dark theme](./doc/img/win-xp-dark.png)
![win-7 light theme](./doc/img/win-7-light.png)
![win-7 dark theme](./doc/img/win-7-dark.png)

## Requirements

Expand All @@ -114,7 +135,7 @@ Similarly, here are two examples creating windows with light and dark win-xp the
## Features

- switch operating system designs
- currently supported themes: `macos` and `win-xp`
- currently supported themes: `macos`, `win-xp`, and `win-7`
- switch between light &amp; dark themes
- create non-interactive or interactive window frames
- use any HTML as window contents
Expand Down
13 changes: 13 additions & 0 deletions doc/api.md
Expand Up @@ -203,6 +203,7 @@ An example of all available operating system theme settings is show in the image

![mac operating system theme (default)](./img/theme-mac.png)
![win-xp operating system theme (default)](./img/theme-win-xp.png)
![win-7 operating system theme (default)](./img/theme-win-7.png)

```html
<!-- default operating system theme -->
Expand All @@ -222,6 +223,11 @@ An example of all available operating system theme settings is show in the image
<os-window
os-theme="win-xp"
></os-window>

<!-- win-7 operating system theme -->
<os-window
os-theme="win-7"
></os-window>
```

You can change the operating system theme through JavaScript:
Expand All @@ -233,6 +239,8 @@ var win = document.createElement('os-window');
win.osTheme = 'mac';
// To change operating system theme to win-xp
win.osTheme = 'win-xp';
// To change operating system theme to win-7
win.osTheme = 'win-7';

// To read the operating system theme
var osTheme = win.osTheme;
Expand Down Expand Up @@ -266,6 +274,11 @@ An example of all available combinations of light and dark mode with operating s

![light win-xp operating system theme (default)](./img/win-xp-light.png)
![dark win-xp operating system theme](./img/win-xp-dark.png)

(**left:** light win-7 window theme (default), **right:** dark win-7 window theme)

![light win-7 operating system theme (default)](./img/win-7-light.png)
![dark win-7 operating system theme](./img/win-7-dark.png)
```html
<!-- default theme -->
<os-window></os-window>
Expand Down
Binary file added doc/img/theme-win-7.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/win-7-dark.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/img/win-7-light.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 76d1ba5

Please sign in to comment.