Skip to content

Commit

Permalink
MDL-78453 tiny_aiplacement: Increase the image alt text max length
Browse files Browse the repository at this point in the history
  • Loading branch information
meirzamoodle committed Nov 4, 2024
1 parent 5e259cc commit 536d9ff
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion lib/editor/tiny/plugins/aiplacement/amd/src/mediaimage.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import {getString} from 'core/str';
import MediaImage from 'tiny_media/image';
import Notification from 'core/notification';
import {prefetchStrings} from 'core/prefetch';
import {MAX_LENGTH_ALT} from 'tiny_media/imagehelpers';

prefetchStrings('core_ai', [
'contentwatermark',
Expand Down Expand Up @@ -57,7 +58,7 @@ export default class AiMediaImage extends MediaImage {
* @return {string} The truncated alt text
*/
truncateAltText(altText) {
const maximumAltTextLength = 125;
const maximumAltTextLength = MAX_LENGTH_ALT;
const watermark = ' - ' + this.watermark;
const ellipsis = '...';

Expand Down

0 comments on commit 536d9ff

Please sign in to comment.