diff --git a/angular/demo/src/app/samples/rating/readonly.route.ts b/angular/demo/src/app/samples/rating/readonly.route.ts
index eb4dae9b4b..5fe15ec3d5 100644
--- a/angular/demo/src/app/samples/rating/readonly.route.ts
+++ b/angular/demo/src/app/samples/rating/readonly.route.ts
@@ -1,14 +1,22 @@
import {AgnosUIAngularModule} from '@agnos-ui/angular';
-import {Component} from '@angular/core';
+import {Component, inject} from '@angular/core';
+import heartFill from '!raw-loader!bootstrap-icons/icons/heart-fill.svg';
+import {DomSanitizer} from '@angular/platform-browser';
@Component({
standalone: true,
imports: [AgnosUIAngularModule],
template: `
- ♥♥
+
+
+
+
`,
})
-export default class ReadonlyRatingComponent {}
+export default class ReadonlyRatingComponent {
+ readonly sanitizer = inject(DomSanitizer);
+ readonly heartFill = heartFill;
+}
diff --git a/angular/demo/src/app/samples/alert/raw-loader.d.ts b/angular/demo/src/app/types/raw-loader.d.ts
similarity index 100%
rename from angular/demo/src/app/samples/alert/raw-loader.d.ts
rename to angular/demo/src/app/types/raw-loader.d.ts
diff --git a/common/demo.scss b/common/demo.scss
index af05270f5b..2d601892d7 100644
--- a/common/demo.scss
+++ b/common/demo.scss
@@ -36,8 +36,13 @@ main {
.star {
position: relative;
display: inline-block;
- font-size: 300%;
+ font-size: 2.5rem;
color: #d3d3d3;
+ svg {
+ width: 1em;
+ height: 1em;
+ padding-right: 0.1rem;
+ }
}
.full {
diff --git a/e2e/rating/rating.e2e-spec.ts b/e2e/rating/rating.e2e-spec.ts
index 99608365f1..1469b32456 100644
--- a/e2e/rating/rating.e2e-spec.ts
+++ b/e2e/rating/rating.e2e-spec.ts
@@ -122,7 +122,7 @@ test.describe.parallel(`Rating tests`, () => {
text: '3.64 out of 5',
disabled: null,
readonly: 'true',
- stars: ['♥♥', '♥♥', '♥♥', '♥♥', '♥♥'],
+ stars: ['', '', '', '', ''],
classes: expectedClasses,
};
expect(await ratingPO.state()).toEqual(expectedState);
diff --git a/e2e/samplesMarkup.e2e-spec.ts-snapshots/rating-readonly.html b/e2e/samplesMarkup.e2e-spec.ts-snapshots/rating-readonly.html
index c6ecf91077..c3ba015e39 100644
--- a/e2e/samplesMarkup.e2e-spec.ts-snapshots/rating-readonly.html
+++ b/e2e/samplesMarkup.e2e-spec.ts-snapshots/rating-readonly.html
@@ -32,9 +32,35 @@
class="half"
style="width: 100%;"
>
- "♥"
+
+
+
+
- "♥"
- "♥"
+
+
+
+
- "♥"
- "♥"
+
+
+
+
- "♥"
- "♥"
+
+
+
+
- "♥"
- "♥"
+
+
+
+
- "♥"
diff --git a/react/demo/app/samples/rating/Readonly.route.tsx b/react/demo/app/samples/rating/Readonly.route.tsx
index 803e18a2f9..99e02e716d 100644
--- a/react/demo/app/samples/rating/Readonly.route.tsx
+++ b/react/demo/app/samples/rating/Readonly.route.tsx
@@ -1,5 +1,6 @@
import type {StarContext} from '@agnos-ui/core';
import {Rating} from '@agnos-ui/react';
+import heartFill from 'bootstrap-icons/icons/heart-fill.svg?raw';
const RatingDemo = () => {
return (
@@ -19,10 +20,8 @@ const RatingDemo = () => {
};
return (
-
- ♥
-
- ♥
+
+
);
}}
diff --git a/svelte/demo/samples/rating/Readonly.route.svelte b/svelte/demo/samples/rating/Readonly.route.svelte
index e91273990d..6488c94442 100644
--- a/svelte/demo/samples/rating/Readonly.route.svelte
+++ b/svelte/demo/samples/rating/Readonly.route.svelte
@@ -1,9 +1,13 @@
- ♥♥
+
+ {@html heartFill}
+
+ {@html heartFill}