No description
Find a file
Pat Hartl f094309d2d Add classes to all controls and window elements
This adds classes to the elements of the custom window where they're either outright missing or could be a bit more specific. This allows for easier targeting of individual elements for stylesheets.
2024-06-05 10:09:38 -05:00
Photino.Blazor.CustomWindow Add classes to all controls and window elements 2024-06-05 10:09:38 -05:00
Photino.Blazor.CustomWindow.Sample Add support for latest version of Photino.Blazor 2024-06-05 14:32:01 +03:00
.gitattributes Photino.Blazor.CustomWindow 2024-01-21 16:50:56 +03:00
.gitignore Photino.Blazor.CustomWindow 2024-01-21 16:50:56 +03:00
customwindow.png Photino.Blazor.CustomWindow 2024-01-21 16:50:56 +03:00
LICENSE.txt Photino.Blazor.CustomWindow 2024-01-21 16:50:56 +03:00
Photino.Blazor.CustomWindow.sln Photino.Blazor.CustomWindow 2024-01-21 16:50:56 +03:00
preview.png Add new media for readme and remove old 2024-01-21 17:59:52 +03:00
README.md Update README.md - Shields 2024-03-11 19:11:44 +03:00

 Photino.Blazor.CustomWindow

NuGet Version NuGet Downloads

About

Customizable cross-platform window view and behaviour implementation for Photino.Blazor applications with Chromeless mode.
The project provides Blazor component named CustomWindow that takes up the entire space of the cromeless window and renders custom window header and borders. It includes the possibility of customizing the window header up to the icon, title and control buttons, moving the window on header dragging, window resizing on borders dragging, and some other features such as stretching (expanding) the window by half the screen when moving it to the boundaries of the monitor's work area. Default control buttons allow to minimize, maximize and close the window. At the same time, the component also provides appropriate methods.

How to use

  1. Include Photino.Blazor.CustomWindow as PackageReference to your project.
  2. Include css and js files from _content/Photino.Blazor.CustomWindow to your index.html as shown in the example. Or you can add their contents manually as your own files.
  3. Add CustomWindow to your Photino.Blazor application service collection with AddCustomWindow() extension.
  4. Use CustomWindow component as root in your markup and place your content to its WindowContent RenderFragment (see example).
  5. Don't forget to set the PhotinoWindow.Chromeless property to true.
  6. Override --pb-custom-window-[. . .] css variables for styling (default values here).

Problems

  • When Blazor catch an unhandled error, entire window freezes including any interaction with CustomWindow. This can only be solved by creating a solution based on JavaScript and not Blazor.