Skip to content

Commit

Permalink
Merge branch 'main' into fix-avoid-double-gif-upload
Browse files Browse the repository at this point in the history
  • Loading branch information
melMass authored Oct 27, 2023
2 parents bc778fd + 89af49d commit 49f9087
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/components/preview/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const Field = ({ title, value }) => {
value && (
<div className={styles.field}>
<strong>{title}:</strong>
{value}
<p>{value}</p>
</div>
)
)
Expand Down
8 changes: 5 additions & 3 deletions src/pages/config/Subjkt.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -266,11 +266,13 @@ export const Subjkt = () => {
value={subjkt}
onChange={setSubjkt}
onBlur={(e) => {
setSubjkt(e.target.value.replace(/[^a-z0-9-._]/g, ''))
if(/[^A-Za-z0-9-._]/.test(e.target.value)) {
show('Subjkt contains invalid characters. This field can only contain: letters (a-z A-Z), numbers (0-9), . (dot), - (dash), _ (underscore)')
}
}}
placeholder="can contain letters (a-z), numbers (0-9), . (dot), - (dash), _ (underscore)"
placeholder="can contain letters (a-z A-Z), numbers (0-9), . (dot), - (dash), _ (underscore)"
label="Username"
pattern="^[a-z0-9-._]*$"
pattern="^[A-Za-z0-9-._]*$"
/>
<Input
name="description"
Expand Down

0 comments on commit 49f9087

Please sign in to comment.