Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
124 changes: 62 additions & 62 deletions .github/DISCUSSION_TEMPLATE/q-a.yml
Original file line number Diff line number Diff line change
@@ -1,62 +1,62 @@
name: Q&A
description: Ask the community for help
body:
- type: textarea
id: question
attributes:
label: Describe your issue
description: |
- Explain your problem in the most specific way. Provide any relevant error logs, full stack traces of exceptions, browser logs, etc...
- If you have a build error, [make sure to attach a binlog](https://aka.platform.uno/msbuild-troubleshoot)
- type: textarea
id: repro-steps
attributes:
label: Provide repro steps and sample
description: |
- Attach a [**minimal repro project**](https://aka.platform.uno/uno-repro-sample) and provide detailed **steps to reproduce**.
- Make sure to attach the zip file to this discussion (you can use drag and drop of the zip file).
- type: textarea
id: nuget-versions
attributes:
label: NuGet package version(s)
- type: checkboxes
id: renderer
attributes:
label: Renderer
multiple: true
options:
- Skia
- Native
- type: dropdown
id: platforms
attributes:
label: Affected platforms
multiple: true
options:
- WebAssembly
- Android
- iOS
- Desktop (Windows)
- Desktop (macOS)
- Desktop (X11)
- Desktop (Linux Framebuffer)
- Windows App SDK
- Build tasks
- type: dropdown
id: ide
attributes:
label: IDE
multiple: true
options:
- Visual Studio 2022
- Visual Studio Code
- Rider Windows
- Rider macOS
- Rider Linux
name: Q&A
description: Ask the community for help
body:

- type: textarea
id: question
attributes:
label: Describe your issue
description: |
- Explain your problem in the most specific way. Provide any relevant error logs, full stack traces of exceptions, browser logs, etc...
- If you have a build error, [make sure to attach a binlog](https://aka.platform.uno/msbuild-troubleshoot)

- type: textarea
id: repro-steps
attributes:
label: Provide repro steps and sample
description: |
- Attach a [**minimal repro project**](https://aka.platform.uno/uno-repro-sample) and provide detailed **steps to reproduce**.
- Make sure to attach the zip file to this discussion (you can use drag and drop of the zip file).

- type: textarea
id: nuget-versions
attributes:
label: NuGet package version(s)

- type: checkboxes
id: renderer
attributes:
label: Renderer
multiple: true
options:

- Skia
- Native

- type: dropdown
id: platforms
attributes:
label: Affected platforms
multiple: true
options:
- WebAssembly
- Android
- iOS
- Desktop (Windows)
- Desktop (macOS)
- Desktop (X11)
- Desktop (Linux Framebuffer)
- Windows App SDK
- Build tasks

- type: dropdown
id: ide
attributes:
label: IDE
multiple: true
options:
- Visual Studio 2022
- Visual Studio Code
- Rider Windows
- Rider macOS
- Rider Linux
46 changes: 23 additions & 23 deletions .github/workflows/no-response.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
name: No Response
# Both `issue_comment` and `scheduled` event types are required for this Action
# to work properly.
on:
issue_comment:
types: [created]
schedule:
# Schedule for 5 minutes past the hour, every 6 hours
- cron: '5 */6 * * *'
jobs:
noResponse:
if: github.repository == 'unoplatform/uno'
runs-on: ubuntu-latest
steps:
- uses: lee-dohm/no-response@9bb0a4b5e6a45046f00353d5de7d90fb8bd773bb # 0.5.0
with:
token: ${{ github.token }}
daysUntilClose: 20
responseRequiredLabel: triage/needs-information
closeComment: >
This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. We don't monitor discussions on closed issues thus please open a new GitHub issue if you need the team to revisit this matter.
name: No Response

# Both `issue_comment` and `scheduled` event types are required for this Action
# to work properly.
on:
issue_comment:
types: [created]
schedule:
# Schedule for 5 minutes past the hour, every 6 hours
- cron: '5 */6 * * *'

jobs:
noResponse:
if: github.repository == 'unoplatform/uno'
runs-on: ubuntu-latest
steps:
- uses: lee-dohm/no-response@9bb0a4b5e6a45046f00353d5de7d90fb8bd773bb # 0.5.0
with:
token: ${{ github.token }}
daysUntilClose: 20
responseRequiredLabel: triage/needs-information
closeComment: >
This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. We don't monitor discussions on closed issues thus please open a new GitHub issue if you need the team to revisit this matter.
70 changes: 35 additions & 35 deletions .github/workflows/stale-prs.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
name: 'Close stale PRs'
on:
schedule:
- cron: '30 1 * * *'
workflow_dispatch:
permissions:
contents: write # only for delete-branch option
issues: write
pull-requests: write
jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v9
with:
# docs: https://github.com/actions/stale?tab=readme-ov-file
stale-pr-message: 'This PR is stale because it has been open 60 days with no activity. Remove stale label or comment or it will be closed in 10 days.'
close-pr-message: 'This PR was closed because it has been stalled for 10 days with no activity.'
days-before-pr-stale: 60
days-before-pr-close: 10
# disable issue closing
days-before-issue-stale: -1
days-before-issue-close: -1
operations-per-run: 100
# Flag older PRs first
ascending: true
name: 'Close stale PRs'
on:
schedule:
- cron: '30 1 * * *'

workflow_dispatch:

permissions:
contents: write # only for delete-branch option
issues: write
pull-requests: write

jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v9
with:
# docs: https://github.com/actions/stale?tab=readme-ov-file

stale-pr-message: 'This PR is stale because it has been open 60 days with no activity. Remove stale label or comment or it will be closed in 10 days.'
close-pr-message: 'This PR was closed because it has been stalled for 10 days with no activity.'

days-before-pr-stale: 60
days-before-pr-close: 10

# disable issue closing
days-before-issue-stale: -1
days-before-issue-close: -1

operations-per-run: 100

# Flag older PRs first
ascending: true

debug-only: false
49 changes: 48 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ο»Ώ<h1 align=center>
<h1 align=center>
<img alt="Uno Platform Banner" align=center width="95%" src="https://github.com/user-attachments/assets/ac1b6c72-a6ed-4c3f-9e0d-a8eca96bdc4e" />
</h1>

Expand Down Expand Up @@ -136,6 +136,53 @@
* **[Hot Reload](https://aka.platform.uno/hot-reload)**
* **[Design-to-Code](https://aka.platform.uno/Design-to-Code)**
* **[Uno Playground](https://playground.platform.uno/)**: Experiment with code snippets and see live previews.

## Testing File Picker Functionality

We've added comprehensive testing for the `FileOpenPicker` functionality, which is now available for WebAssembly (WASM) targets. This implementation demonstrates how to use the Uno Platform's file picker to select files in a cross-platform application.

Check notice on line 142 in README.md

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

README.md#L142

Expected: 80; Actual: 252

### Key Features

- **Cross-Platform Support**: Seamlessly works across all Uno Platform targets with a consistent API

Check notice on line 146 in README.md

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

README.md#L146

Expected: 80; Actual: 100

Check notice on line 146 in README.md

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

README.md#L146

Expected: asterisk; Actual: dash
- **File Type Filtering**: Easily specify which file types users can select

Check notice on line 147 in README.md

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

README.md#L147

Expected: asterisk; Actual: dash
- **Asynchronous Operation**: Non-blocking file selection with proper async/await pattern

Check notice on line 148 in README.md

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

README.md#L148

Expected: 80; Actual: 89

Check notice on line 148 in README.md

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

README.md#L148

Expected: asterisk; Actual: dash
- **Error Handling**: Comprehensive error handling for all file operations

Check notice on line 149 in README.md

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

README.md#L149

Expected: asterisk; Actual: dash

### Example Usage

```csharp
var picker = new FileOpenPicker
{
ViewMode = PickerViewMode.Thumbnail,
SuggestedStartLocation = PickerLocationId.DocumentsLibrary
};

// Add file type filters
picker.FileTypeFilter.Add(".txt");
picker.FileTypeFilter.Add(".jpg");
picker.FileTypeFilter.Add(".png");
picker.FileTypeFilter.Add("*");

// Open the file picker
var file = await picker.PickSingleFileAsync();

if (file != null)
{
// File was selected
// Access file properties or read content
}
```

### Running Tests

To run the FileOpenPicker tests:

1. Build the solution
2. Use the test explorer in your IDE
3. Look for `FileOpenPicker_Tests` in the test list

The tests verify both successful file selection and cancellation scenarios, ensuring robust file handling in your application.

Check notice on line 184 in README.md

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

README.md#L184

Expected: 80; Actual: 126

* **[Uno Gallery](https://gallery.platform.uno/)**: Explore various UI themes and components in action.
* **[Workshops & Code Samples](https://aka.platform.uno/samples-tutorials)**: Access practical tutorials and sample projects to accelerate learning.
* **[Case Studies](https://platform.uno/case-studies/)**: Learn from real-world applications built using the Uno Platform.
Expand Down
44 changes: 22 additions & 22 deletions build/ci/templates/host-cleanup-linux.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
steps:
- bash: |
# This list is based on what the base image contains and
# may need to be adjusted as new software gets installed.
# Use the `du` command below to determine what can be
# uninstalled.
rm -fR ~/.cargo
rm -fR ~/.rustup
rm -fR ~/.dotnet
sudo rm -fR /usr/share/swift
sudo rm -fR /opt/microsoft/msedge
sudo rm -fR /usr/local/.ghcup
sudo rm -fR /usr/lib/mono
sudo snap remove lxd
sudo snap remove core20
sudo apt remove snapd
df -h
# du -h -d 3 /
displayName: 'Cleanup unused image dependencies (Linux)'
steps:
- bash: |
# This list is based on what the base image contains and
# may need to be adjusted as new software gets installed.
# Use the `du` command below to determine what can be
# uninstalled.

rm -fR ~/.cargo
rm -fR ~/.rustup
rm -fR ~/.dotnet
sudo rm -fR /usr/share/swift
sudo rm -fR /opt/microsoft/msedge
sudo rm -fR /usr/local/.ghcup
sudo rm -fR /usr/lib/mono
sudo snap remove lxd
sudo snap remove core20
sudo apt remove snapd

df -h
# du -h -d 3 /

displayName: 'Cleanup unused image dependencies (Linux)'
condition: eq(variables['Agent.OS'], 'Linux')
Loading
Loading