diff --git a/.gitignore b/.gitignore index 09047e5d..e3a95437 100644 --- a/.gitignore +++ b/.gitignore @@ -36,5 +36,3 @@ pandora/gunicorn_config.py .DS_Store .env overlay/ -pandora/encoding.conf -pandora/tasks.conf diff --git a/Dockerfile b/Dockerfile index 24e6d63c..a1b287ee 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM code.0x2620.org/0x2620/pandora-base:latest +FROM 0x2620/pandora-base:latest LABEL maintainer="0x2620@0x2620.org" diff --git a/README.md b/README.md index 40cf23f0..044a3cb8 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ We recommend to run pan.do/ra inside of LXD or LXC or dedicated VM or server. You will need at least 2GB of free disk space - pan.do/ra is known to work with Debian/12 (bookworm) and Ubuntu 22.04, + pan.do/ra is known to work with Ubuntu 18.04, 20.04 and Debian/10 (buster), other distributions might also work, let us know if it works for you. Use the following commands as root to install pan.do/ra and all dependencies: @@ -16,7 +16,7 @@ cd /root curl -sL https://pan.do/ra-install > pandora_install.sh chmod +x pandora_install.sh -export BRANCH=master # change to 'stable' to get the latest release (sometimes outdated) +export BRANCH=stable # change to 'master' to get current developement version ./pandora_install.sh 2>&1 | tee pandora_install.log ``` @@ -50,9 +50,4 @@ export BRANCH=master # change to 'stable' to get the latest release (sometimes o More info at https://code.0x2620.org/0x2620/pandora/wiki/Customization -## Update - - To update your existing instlalation run - - pandoractl update diff --git a/ctl b/ctl index 6e16fb87..b78183ba 100755 --- a/ctl +++ b/ctl @@ -27,30 +27,25 @@ if [ "$action" = "init" ]; then $SUDO bin/python3 -m pip install -U --ignore-installed "pip<9" fi if [ ! -d static/oxjs ]; then - $SUDO git clone -b $branch https://code.0x2620.org/0x2620/oxjs.git static/oxjs + $SUDO git clone --depth 1 -b $branch https://git.0x2620.org/oxjs.git static/oxjs fi $SUDO mkdir -p src + if [ ! -d src/oxtimelines ]; then + $SUDO git clone --depth 1 -b $branch https://git.0x2620.org/oxtimelines.git src/oxtimelines + fi for package in oxtimelines python-ox; do cd ${BASE} if [ ! -d src/${package} ]; then - $SUDO git clone -b $branch https://code.0x2620.org/0x2620/${package}.git src/${package} + $SUDO git clone --depth 1 -b $branch https://git.0x2620.org/${package}.git src/${package} fi cd ${BASE}/src/${package} - - $SUDO ${BASE}/bin/pip install -e . - + $SUDO ${BASE}/bin/python setup.py develop done cd ${BASE} $SUDO ./bin/pip install -r requirements.txt - for template in gunicorn_config.py encoding.conf tasks.conf; do - if [ ! -e pandora/$template ]; then - $SUDO cp pandora/${template}.in pandora/$template - fi - done - exit 0 -fi -if [ "$action" = "version" ]; then - git rev-list HEAD --count + if [ ! -e pandora/gunicorn_config.py ]; then + $SUDO cp pandora/gunicorn_config.py.in pandora/gunicorn_config.py + fi exit 0 fi @@ -78,15 +73,10 @@ if [ `whoami` != 'root' ]; then exit 1 fi if [ "$action" = "install" ]; then - cd "`dirname "$self"`" + cd "`dirname "$0"`" BASE=`pwd` if [ -x /bin/systemctl ]; then if [ -d /etc/systemd/system/ ]; then - for template in gunicorn_config.py encoding.conf tasks.conf; do - if [ ! -e pandora/$template ]; then - $SUDO cp pandora/${template}.in pandora/$template - fi - done for service in $SERVICES; do if [ -e /lib/systemd/system/${service}.service ]; then rm -f /lib/systemd/system/${service}.service \ diff --git a/docker-compose.yml b/docker-compose.yml index 532a1fda..1360247c 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -15,6 +15,7 @@ services: - "127.0.0.1:2620:80" networks: - backend + - default links: - pandora - websocketd @@ -27,7 +28,7 @@ services: restart: unless-stopped db: - image: postgres:15 + image: postgres:latest networks: - backend env_file: .env diff --git a/docker/base/Dockerfile b/docker/base/Dockerfile index 199af642..727891e8 100644 --- a/docker/base/Dockerfile +++ b/docker/base/Dockerfile @@ -1,4 +1,4 @@ -FROM debian:12 +FROM debian:buster LABEL maintainer="0x2620@0x2620.org" diff --git a/docker/base/install.sh b/docker/base/install.sh index c344d74c..2d016eba 100755 --- a/docker/base/install.sh +++ b/docker/base/install.sh @@ -1,17 +1,9 @@ #!/bin/bash +UBUNTU_CODENAME=bionic if [ -e /etc/os-release ]; then . /etc/os-release fi -if [ -z "$UBUNTU_CODENAME" ]; then - UBUNTU_CODENAME=bionic -fi -if [ "$VERSION_CODENAME" = "bullseye" ]; then - UBUNTU_CODENAME=focal -fi -if [ "$VERSION_CODENAME" = "bookworm" ]; then - UBUNTU_CODENAME=lunar -fi export DEBIAN_FRONTEND=noninteractive echo 'Acquire::Languages "none";' > /etc/apt/apt.conf.d/99languages @@ -52,6 +44,7 @@ apt-get install -y \ python3-numpy \ python3-psycopg2 \ python3-pyinotify \ + python3-simplejson \ python3-lxml \ python3-cssselect \ python3-html5lib \ @@ -60,6 +53,7 @@ apt-get install -y \ oxframe \ ffmpeg \ mkvtoolnix \ + gpac \ imagemagick \ poppler-utils \ ipython3 \ diff --git a/docker/build.sh b/docker/build.sh index fc33b7c8..dd661ba1 100755 --- a/docker/build.sh +++ b/docker/build.sh @@ -11,7 +11,7 @@ else proxy= fi -docker build $proxy -t code.0x2620.org/0x2620/pandora-base base -docker build -t code.0x2620.org/0x2620/pandora-nginx nginx +docker build $proxy -t 0x2620/pandora-base base +docker build -t 0x2620/pandora-nginx nginx cd .. -docker build -t code.0x2620.org/0x2620/pandora . +docker build -t 0x2620/pandora . diff --git a/docker/entrypoint.sh b/docker/entrypoint.sh index 4813b00a..123883f8 100755 --- a/docker/entrypoint.sh +++ b/docker/entrypoint.sh @@ -6,7 +6,7 @@ user=pandora export LANG=en_US.UTF-8 mkdir -p /run/pandora -chown -R ${user}:${user} /run/pandora +chown -R ${user}.${user} /run/pandora update="/usr/bin/sudo -u $user -E -H /srv/pandora/update.py" @@ -32,7 +32,7 @@ if [ "$action" = "pandora" ]; then /srv/pandora/pandora/manage.py init_db $update db echo "Generating static files..." - chown -R ${user}:${user} /srv/pandora/ + chown -R ${user}.${user} /srv/pandora/ $update static touch /srv/pandora/initialized fi @@ -52,7 +52,7 @@ if [ "$action" = "encoding" ]; then -A app worker \ -Q encoding -n ${name} \ --pidfile /run/pandora/encoding.pid \ - --max-tasks-per-child 500 \ + --maxtasksperchild 500 \ -c 1 \ -l INFO fi @@ -66,7 +66,7 @@ if [ "$action" = "tasks" ]; then -A app worker \ -Q default,celery -n ${name} \ --pidfile /run/pandora/tasks.pid \ - --max-tasks-per-child 1000 \ + --maxtasksperchild 1000 \ -l INFO fi if [ "$action" = "cron" ]; then @@ -103,9 +103,9 @@ fi # pan.do/ra setup hooks if [ "$action" = "docker-compose.yml" ]; then cat /srv/pandora_base/docker-compose.yml | \ - sed "s#build: \.#image: code.0x2620.org/0x2620/pandora:latest#g" | \ + sed "s#build: \.#image: 0x2620/pandora:latest#g" | \ sed "s#\./overlay:#.:#g" | \ - sed "s#build: docker/nginx#image: code.0x2620.org/0x2620/pandora-nginx:latest#g" + sed "s#build: docker/nginx#image: 0x2620/pandora-nginx:latest#g" exit fi if [ "$action" = ".env" ]; then @@ -131,5 +131,5 @@ echo " docker run 0x2620/pandora setup | sh" echo echo adjust created files to match your needs and run: echo -echo " docker compose up" +echo " docker-compose up" echo diff --git a/docker/publish.sh b/docker/publish.sh index 2766a474..f4ef0193 100644 --- a/docker/publish.sh +++ b/docker/publish.sh @@ -1,5 +1,5 @@ #!/bin/bash -# push new version of pan.do/ra to code.0x2620.org +# push new version of pan.do/ra to docker hub set -e cd /tmp @@ -7,6 +7,6 @@ git clone https://code.0x2620.org/0x2620/pandora cd pandora ./docker/build.sh -docker push code.0x2620.org/0x2620/pandora-base:latest -docker push code.0x2620.org/0x2620/pandora-nginx:latest -docker push code.0x2620.org/0x2620/pandora:latest +docker push 0x2620/pandora-base:latest +docker push 0x2620/pandora-nginx:latest +docker push 0x2620/pandora:latest diff --git a/docker/setup-docker-compose.sh b/docker/setup-docker-compose.sh index fc25efde..2f48179f 100755 --- a/docker/setup-docker-compose.sh +++ b/docker/setup-docker-compose.sh @@ -1,18 +1,18 @@ #!/bin/sh -docker run --rm code.0x2620.org/0x2620/pandora docker-compose.yml > docker-compose.yml +docker run 0x2620/pandora docker-compose.yml > docker-compose.yml if [ ! -e .env ]; then - docker run --rm code.0x2620.org/0x2620/pandora .env > .env + docker run 0x2620/pandora .env > .env echo .env >> .gitignore fi if [ ! -e config.jsonc ]; then - docker run --rm code.0x2620.org/0x2620/pandora config.jsonc > config.jsonc + docker run 0x2620/pandora config.jsonc > config.jsonc fi cat > README.md << EOF pan.do/ra docker instance this folder was created with - docker run --rm code.0x2620.org/0x2620/pandora setup | sh + docker run 0x2620/pandora setup | sh To start pan.do/ra adjust the files in this folder: @@ -22,14 +22,11 @@ To start pan.do/ra adjust the files in this folder: and to get started run this: - docker compose up -d + docker-compose up -d To update pan.do/ra run: - docker compose run --rm pandora ctl update + docker-compose run pandora ctl update -To run pan.do/ra manage shell: - - docker compose run --rm pandora ctl manage shell EOF touch __init__.py diff --git a/etc/nginx/pandora b/etc/nginx/pandora index db3838a3..419120aa 100644 --- a/etc/nginx/pandora +++ b/etc/nginx/pandora @@ -17,16 +17,10 @@ server { #server_name pandora.YOURDOMAIN.COM; listen 80 default; - listen [::]:80 default; access_log /var/log/nginx/pandora.access.log; error_log /var/log/nginx/pandora.error.log; - location /.well-known/acme-challenge/ { - root /var/www/html/; - autoindex off; - } - location /favicon.ico { root /srv/pandora/static; } diff --git a/etc/sudoers.d/pandora b/etc/sudoers.d/pandora deleted file mode 100644 index d05bab77..00000000 --- a/etc/sudoers.d/pandora +++ /dev/null @@ -1 +0,0 @@ -pandora ALL=(ALL:ALL) NOPASSWD:/usr/local/bin/pandoractl diff --git a/etc/systemd/system/pandora-cron.service b/etc/systemd/system/pandora-cron.service index 7c6b0028..9f1ef157 100644 --- a/etc/systemd/system/pandora-cron.service +++ b/etc/systemd/system/pandora-cron.service @@ -11,7 +11,7 @@ PIDFile=/run/pandora/cron.pid WorkingDirectory=/srv/pandora/pandora ExecStart=/srv/pandora/bin/celery \ -A app beat \ - --scheduler django_celery_beat.schedulers:DatabaseScheduler \ + -s /run/pandora/celerybeat-schedule \ --pidfile /run/pandora/cron.pid \ -l INFO ExecReload=/bin/kill -HUP $MAINPID diff --git a/etc/systemd/system/pandora-encoding.service b/etc/systemd/system/pandora-encoding.service index ee8725ce..b2a48626 100644 --- a/etc/systemd/system/pandora-encoding.service +++ b/etc/systemd/system/pandora-encoding.service @@ -7,16 +7,14 @@ Type=simple Restart=always User=pandora Group=pandora -EnvironmentFile=/srv/pandora/pandora/encoding.conf PIDFile=/run/pandora/encoding.pid WorkingDirectory=/srv/pandora/pandora ExecStart=/srv/pandora/bin/celery \ -A app worker \ -Q encoding -n pandora-encoding \ --pidfile /run/pandora/encoding.pid \ - -c $CONCURRENCY \ - --max-tasks-per-child $MAX_TASKS_PER_CHILD \ - -l $LOGLEVEL + --maxtasksperchild 500 \ + -l INFO ExecReload=/bin/kill -TERM $MAINPID [Install] diff --git a/etc/systemd/system/pandora-tasks.service b/etc/systemd/system/pandora-tasks.service index d1d49420..19cf04af 100644 --- a/etc/systemd/system/pandora-tasks.service +++ b/etc/systemd/system/pandora-tasks.service @@ -7,16 +7,14 @@ Type=simple Restart=always User=pandora Group=pandora -EnvironmentFile=/srv/pandora/pandora/tasks.conf PIDFile=/run/pandora/tasks.pid WorkingDirectory=/srv/pandora/pandora ExecStart=/srv/pandora/bin/celery \ -A app worker \ -Q default,celery -n pandora-default \ --pidfile /run/pandora/tasks.pid \ - -c $CONCURRENCY \ - --max-tasks-per-child $MAX_TASKS_PER_CHILD \ - -l $LOGLEVEL + --maxtasksperchild 1000 \ + -l INFO ExecReload=/bin/kill -TERM $MAINPID [Install] diff --git a/pandora/annotation/apps.py b/pandora/annotation/apps.py deleted file mode 100644 index 8b0d41a8..00000000 --- a/pandora/annotation/apps.py +++ /dev/null @@ -1,6 +0,0 @@ -from django.apps import AppConfig - - -class AnnotationConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'annotation' diff --git a/pandora/annotation/management/commands/import_srt.py b/pandora/annotation/management/commands/import_srt.py index ef309f81..881aa186 100644 --- a/pandora/annotation/management/commands/import_srt.py +++ b/pandora/annotation/management/commands/import_srt.py @@ -27,7 +27,6 @@ class Command(BaseCommand): parser.add_argument('username', help='username') parser.add_argument('item', help='item') parser.add_argument('layer', help='layer') - parser.add_argument('language', help='language', default="") parser.add_argument('filename', help='filename.srt') def handle(self, *args, **options): @@ -35,7 +34,6 @@ class Command(BaseCommand): public_id = options['item'] layer_id = options['layer'] filename = options['filename'] - language = options.get("language") user = User.objects.get(username=username) item = Item.objects.get(public_id=public_id) @@ -49,9 +47,6 @@ class Command(BaseCommand): for i in range(len(annotations)-1): if annotations[i]['out'] == annotations[i+1]['in']: annotations[i]['out'] = annotations[i]['out'] - 0.001 - if language: - for annotation in annotations: - annotation["value"] = '%s' % (language, annotation["value"]) tasks.add_annotations.delay({ 'item': item.public_id, 'layer': layer_id, diff --git a/pandora/annotation/migrations/0004_alter_annotation_findvalue_alter_annotation_id.py b/pandora/annotation/migrations/0004_alter_annotation_findvalue_alter_annotation_id.py deleted file mode 100644 index b767efee..00000000 --- a/pandora/annotation/migrations/0004_alter_annotation_findvalue_alter_annotation_id.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:24 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('annotation', '0003_auto_20160219_1537'), - ] - - operations = [ - migrations.AlterField( - model_name='annotation', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/annotation/models.py b/pandora/annotation/models.py index 452df4e0..e1e9d553 100644 --- a/pandora/annotation/models.py +++ b/pandora/annotation/models.py @@ -74,7 +74,7 @@ def get_matches(obj, model, layer_type, qs=None): name = name.lower() name = ox.decode_html(name) name = unicodedata.normalize('NFKD', name).lower() - if name in value and (exact or re.compile(r'((^|\s)%s([\.,;:!?\'"\)\]\-\/\s]|$))' % re.escape(name)).findall(value)): + if name in value and (exact or re.compile('((^|\s)%s([\.,;:!?\'"\)\]\-\/\s]|$))' % re.escape(name)).findall(value)): matches.append(a.id) break if not matches: @@ -155,7 +155,7 @@ class Annotation(models.Model): self.sortvalue = sortvalue[:900] else: self.sortvalue = None - self.languages = ','.join(re.compile(r'lang="(.*?)"').findall(self.value)) + self.languages = ','.join(re.compile('lang="(.*?)"').findall(self.value)) if not self.languages: self.languages = None else: @@ -163,25 +163,28 @@ class Annotation(models.Model): self.sortvalue = None self.languages = None - if not self.clip or self.start != self.clip.start or self.end != self.clip.end: - self.clip, created = Clip.get_or_create(self.item, self.start, self.end) - with transaction.atomic(): + if not self.clip or self.start != self.clip.start or self.end != self.clip.end: + self.clip, created = Clip.get_or_create(self.item, self.start, self.end) + if set_public_id: self.set_public_id() super(Annotation, self).save(*args, **kwargs) - if self.clip: - self.clip.update_findvalue() - setattr(self.clip, self.layer, True) - self.clip.save(update_fields=[self.layer, 'sortvalue', 'findvalue']) + if self.clip: + Clip.objects.filter(**{ + 'id': self.clip.id, + self.layer: False + }).update(**{self.layer: True}) + # update clip.findvalue + self.clip.save() - # update matches in bulk if called from load_subtitles - if not delay_matches: - self.update_matches() - self.update_documents() - self.update_translations() + # update matches in bulk if called from load_subtitles + if not delay_matches: + self.update_matches() + self.update_documents() + self.update_translations() def update_matches(self): from place.models import Place @@ -264,10 +267,7 @@ class Annotation(models.Model): from translation.models import Translation layer = self.get_layer() if layer.get('translate'): - for lang in settings.CONFIG['languages']: - if lang == settings.CONFIG['language']: - continue - Translation.objects.get_or_create(lang=lang, key=self.value, defaults={'type': Translation.CONTENT}) + Translation.objects.get_or_create(lang=lang, key=self.value, defaults={'type': Translation.CONTENT}) def delete(self, *args, **kwargs): with transaction.atomic(): diff --git a/pandora/annotation/tasks.py b/pandora/annotation/tasks.py index 298695c3..8054c6e3 100644 --- a/pandora/annotation/tasks.py +++ b/pandora/annotation/tasks.py @@ -5,12 +5,12 @@ from django.contrib.auth import get_user_model from django.db import transaction import ox -from app.celery import app +from celery.task import task from .models import Annotation -@app.task(ignore_results=False, queue='default') +@task(ignore_results=False, queue='default') def add_annotations(data): from item.models import Item from entity.models import Entity @@ -51,7 +51,7 @@ def add_annotations(data): annotation.item.update_facets() return True -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_item(id, force=False): from item.models import Item from clip.models import Clip @@ -72,7 +72,7 @@ def update_item(id, force=False): a.item.save() -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_annotations(layers, value): items = {} diff --git a/pandora/annotation/views.py b/pandora/annotation/views.py index 7db159df..8bfe7006 100644 --- a/pandora/annotation/views.py +++ b/pandora/annotation/views.py @@ -180,10 +180,10 @@ def addAnnotation(request, data): text='invalid data')) item = get_object_or_404_json(Item, public_id=data['item']) - + layer_id = data['layer'] layer = get_by_id(settings.CONFIG['layers'], layer_id) - if layer['canAddAnnotations'].get(request.user.profile.get_level()) or item.editable(request.user): + if layer['canAddAnnotations'].get(request.user.profile.get_level()): if layer['type'] == 'entity': try: value = Entity.get_by_name(ox.decode_html(data['value']), layer['entity']).get_id() @@ -241,7 +241,8 @@ def addAnnotations(request, data): layer_id = data['layer'] layer = get_by_id(settings.CONFIG['layers'], layer_id) - if item.editable(request.user): + if item.editable(request.user) \ + and layer['canAddAnnotations'].get(request.user.profile.get_level()): response = json_response() data['user'] = request.user.username t = add_annotations.delay(data) diff --git a/pandora/app/apps.py b/pandora/app/apps.py deleted file mode 100644 index 79293398..00000000 --- a/pandora/app/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class AppConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'app' - diff --git a/pandora/app/celery.py b/pandora/app/celery.py index e8cf17fe..710d0d0e 100644 --- a/pandora/app/celery.py +++ b/pandora/app/celery.py @@ -6,8 +6,16 @@ root_dir = os.path.normpath(os.path.abspath(os.path.dirname(__file__))) root_dir = os.path.dirname(root_dir) os.chdir(root_dir) +# set the default Django settings module for the 'celery' program. os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'settings') -app = Celery('pandora', broker_connection_retry_on_startup=True) +app = Celery('pandora') + +# Using a string here means the worker doesn't have to serialize +# the configuration object to child processes. +# - namespace='CELERY' means all celery-related configuration keys +# should have a `CELERY_` prefix. app.config_from_object('django.conf:settings', namespace='CELERY') + +# Load task modules from all registered Django app configs. app.autodiscover_tasks() diff --git a/pandora/app/config.py b/pandora/app/config.py index 672c4a3b..3e96ac27 100644 --- a/pandora/app/config.py +++ b/pandora/app/config.py @@ -133,13 +133,7 @@ def load_config(init=False): added = [] for key in sorted(d): if key not in c: - if key not in ( - 'hidden', - 'find', - 'findDocuments', - 'videoPoints', - ): - added.append("\"%s\": %s," % (key, json.dumps(d[key]))) + added.append("\"%s\": %s," % (key, json.dumps(d[key]))) c[key] = d[key] if added: sys.stderr.write("adding default %s:\n\t" % section) @@ -327,11 +321,7 @@ def update_static(): #locale for f in sorted(glob(os.path.join(settings.STATIC_ROOT, 'json/locale.pandora.*.json'))): with open(f) as fd: - try: - locale = json.load(fd) - except: - print("failed to parse %s" % f) - raise + locale = json.load(fd) site_locale = f.replace('locale.pandora', 'locale.' + settings.CONFIG['site']['id']) locale_file = f.replace('locale.pandora', 'locale') print('write', locale_file) @@ -375,3 +365,13 @@ def update_geoip(force=False): def init(): load_config(True) + +def shutdown(): + if settings.RELOADER_RUNNING: + RUN_RELOADER = False + settings.RELOADER_RUNNING = False + if NOTIFIER: + NOTIFIER.stop() + + + diff --git a/pandora/app/migrations/0002_alter_page_id_alter_settings_id.py b/pandora/app/migrations/0002_alter_page_id_alter_settings_id.py deleted file mode 100644 index 985d04c8..00000000 --- a/pandora/app/migrations/0002_alter_page_id_alter_settings_id.py +++ /dev/null @@ -1,23 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:24 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('app', '0001_initial'), - ] - - operations = [ - migrations.AlterField( - model_name='page', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='settings', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/app/oidc.py b/pandora/app/oidc.py deleted file mode 100644 index be397374..00000000 --- a/pandora/app/oidc.py +++ /dev/null @@ -1,36 +0,0 @@ -import unicodedata - -from django.contrib.auth import get_user_model - -import mozilla_django_oidc.auth - -from user.utils import prepare_user - -User = get_user_model() - - -class OIDCAuthenticationBackend(mozilla_django_oidc.auth.OIDCAuthenticationBackend): - def create_user(self, claims): - user = super(OIDCAuthenticationBackend, self).create_user(claims) - username = None - for key in ('preferred_username', 'name'): - if claims.get(key): - username = claims[key] - break - n = 1 - if username and username != user.username: - uname = username - while User.objects.filter(username=uname).exclude(id=user.id).exists(): - n += 1 - uname = '%s (%s)' % (username, n) - user.username = uname - user.save() - prepare_user(user) - return user - - def update_user(self, user, claims): - return user - - -def generate_username(email): - return unicodedata.normalize('NFKC', email)[:150] diff --git a/pandora/app/tasks.py b/pandora/app/tasks.py index 51a286e4..03b26778 100644 --- a/pandora/app/tasks.py +++ b/pandora/app/tasks.py @@ -2,16 +2,13 @@ import datetime -from app.celery import app +from celery.task import periodic_task from celery.schedules import crontab -@app.task(queue='encoding') + +@periodic_task(run_every=crontab(hour=6, minute=0), queue='encoding') def cron(**kwargs): from django.db import transaction from django.contrib.sessions.models import Session Session.objects.filter(expire_date__lt=datetime.datetime.now()).delete() transaction.commit() - -@app.on_after_finalize.connect -def setup_periodic_tasks(sender, **kwargs): - sender.add_periodic_task(crontab(hour=6, minute=0), cron.s()) diff --git a/pandora/app/views.py b/pandora/app/views.py index 734a5305..5c76b8ec 100644 --- a/pandora/app/views.py +++ b/pandora/app/views.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- -from datetime import datetime -import base64 + import copy +from datetime import datetime from django.shortcuts import render, redirect from django.conf import settings @@ -53,18 +53,17 @@ def embed(request, id): }) def redirect_url(request, url): - try: - url = base64.decodebytes(url.encode()).decode() - except: - pass + if request.META['QUERY_STRING']: + url += "?" + request.META['QUERY_STRING'] + if settings.CONFIG['site'].get('sendReferrer', False): return redirect(url) else: - return HttpResponse('' % json.dumps(url)) + return HttpResponse(''%json.dumps(url)) def opensearch_xml(request): osd = ET.Element('OpenSearchDescription') - osd.attrib['xmlns'] = "http://a9.com/-/spec/opensearch/1.1/" + osd.attrib['xmlns']="http://a9.com/-/spec/opensearch/1.1/" e = ET.SubElement(osd, 'ShortName') e.text = settings.SITENAME e = ET.SubElement(osd, 'Description') @@ -163,7 +162,7 @@ def init(request, data): del config['keys'] if 'HTTP_ACCEPT_LANGUAGE' in request.META: - response['data']['locale'] = request.META['HTTP_ACCEPT_LANGUAGE'].split(';')[0].split('-')[0].split(',')[0] + response['data']['locale'] = request.META['HTTP_ACCEPT_LANGUAGE'].split(';')[0].split('-')[0] if request.META.get('HTTP_X_PREFIX') == 'NO': config['site']['videoprefix'] = '' @@ -184,7 +183,6 @@ def init(request, data): except: pass - config['site']['oidc'] = bool(getattr(settings, 'OIDC_RP_CLIENT_ID', False)) response['data']['site'] = config response['data']['user'] = init_user(request.user, request) request.session['last_init'] = str(datetime.now()) @@ -247,7 +245,7 @@ def getEmbedDefaults(request, data): i = qs[0].cache response['data']['item'] = i['id'] response['data']['itemDuration'] = i['duration'] - response['data']['itemRatio'] = i.get('videoRatio', settings.CONFIG['video']['previewRatio']) + response['data']['itemRatio'] = i['videoRatio'] qs = List.objects.exclude(status='private').order_by('name') if qs.exists(): i = qs[0].json() diff --git a/pandora/archive/apps.py b/pandora/archive/apps.py deleted file mode 100644 index 1679d490..00000000 --- a/pandora/archive/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class ArchiveConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'archive' - diff --git a/pandora/archive/external.py b/pandora/archive/external.py index 7ec59815..cb0e7ef1 100644 --- a/pandora/archive/external.py +++ b/pandora/archive/external.py @@ -1,11 +1,10 @@ # -*- coding: utf-8 -*- import json -import logging -import os -import shutil import subprocess +import shutil import tempfile +import os import ox from django.conf import settings @@ -15,9 +14,6 @@ from item.tasks import load_subtitles from . import models -logger = logging.getLogger('pandora.' + __name__) - - info_keys = [ 'title', 'description', @@ -40,12 +36,8 @@ info_key_map = { 'display_id': 'id', } -YT_DLP = ['yt-dlp'] -if settings.YT_DLP_EXTRA: - YT_DLP += settings.YT_DLP_EXTRA - def get_info(url, referer=None): - cmd = YT_DLP + ['-j', '--all-subs', url] + cmd = ['youtube-dl', '-j', '--all-subs', url] if referer: cmd += ['--referer', referer] p = subprocess.Popen(cmd, @@ -96,15 +88,6 @@ def add_subtitles(item, media, tmp): sub.selected = True sub.save() -def load_formats(url): - cmd = YT_DLP + ['-q', url, '-j', '-F'] - p = subprocess.Popen(cmd, - stdout=subprocess.PIPE, - stderr=subprocess.PIPE, close_fds=True) - stdout, stderr = p.communicate() - formats = stdout.decode().strip().split('\n')[-1] - return json.loads(formats) - def download(item_id, url, referer=None): item = Item.objects.get(public_id=item_id) info = get_info(url, referer) @@ -116,19 +99,18 @@ def download(item_id, url, referer=None): if isinstance(tmp, bytes): tmp = tmp.decode('utf-8') os.chdir(tmp) - cmd = YT_DLP + ['-q', media['url']] + cmd = ['youtube-dl', '-q', media['url']] if referer: cmd += ['--referer', referer] elif 'referer' in media: cmd += ['--referer', media['referer']] - cmd += ['-o', '%(title)80s.%(ext)s'] if settings.CONFIG['video'].get('reuseUpload', False): max_resolution = max(settings.CONFIG['video']['resolutions']) format = settings.CONFIG['video']['formats'][0] if format == 'mp4': cmd += [ - '-f', 'bestvideo[height<=%s][ext=mp4]+bestaudio[ext=m4a]' % max_resolution, + '-f', 'bestvideo[ext=mp4]+bestaudio[ext=m4a]/bestvideo+bestaudio', '--merge-output-format', 'mp4' ] elif format == 'webm': @@ -138,50 +120,6 @@ def download(item_id, url, referer=None): stdout=subprocess.PIPE, stderr=subprocess.PIPE, close_fds=True) stdout, stderr = p.communicate() - if stderr and b'Requested format is not available.' in stderr: - formats = load_formats(url) - has_audio = bool([fmt for fmt in formats['formats'] if fmt['resolution'] == 'audio only']) - has_video = bool([fmt for fmt in formats['formats'] if 'x' in fmt['resolution']]) - - cmd = YT_DLP + [ - '-q', url, - '-o', '%(title)80s.%(ext)s' - ] - if referer: - cmd += ['--referer', referer] - elif 'referer' in media: - cmd += ['--referer', media['referer']] - if has_video and not has_audio: - cmd += [ - '-f', 'bestvideo[height<=%s][ext=mp4]' % max_resolution, - ] - elif not has_video and has_audio: - cmd += [ - 'bestaudio[ext=m4a]' - ] - else: - cmd = [] - if cmd: - p = subprocess.Popen(cmd, - stdout=subprocess.PIPE, - stderr=subprocess.PIPE, close_fds=True) - stdout, stderr = p.communicate() - if stderr and b'Requested format is not available.' in stderr: - cmd = YT_DLP + [ - '-q', url, - '-o', '%(title)80s.%(ext)s' - ] - if referer: - cmd += ['--referer', referer] - elif 'referer' in media: - cmd += ['--referer', media['referer']] - if cmd: - p = subprocess.Popen(cmd, - stdout=subprocess.PIPE, - stderr=subprocess.PIPE, close_fds=True) - stdout, stderr = p.communicate() - if stdout or stderr: - logger.error("import failed:\n%s\n%s\n%s", " ".join(cmd), stdout.decode(), stderr.decode()) parts = list(os.listdir(tmp)) if parts: part = 1 @@ -209,7 +147,6 @@ def download(item_id, url, referer=None): f.extract_stream() status = True else: - logger.error("failed to import %s file already exists %s", url, oshash) status = 'file exists' if len(parts) == 1: add_subtitles(f.item, media, tmp) diff --git a/pandora/archive/extract.py b/pandora/archive/extract.py index 7b9f24ea..ebfd2ae7 100644 --- a/pandora/archive/extract.py +++ b/pandora/archive/extract.py @@ -1,33 +1,26 @@ # -*- coding: utf-8 -*- -from distutils.spawn import find_executable -from glob import glob +import os from os.path import exists import fractions -import logging import math -import os import re import shutil import subprocess import tempfile import time +from distutils.spawn import find_executable +from glob import glob import numpy as np import ox import ox.image from ox.utils import json from django.conf import settings -from PIL import Image, ImageOps -import pillow_avif -from pillow_heif import register_heif_opener +from PIL import Image from .chop import Chop, make_keyframe_index - -register_heif_opener() -logger = logging.getLogger('pandora.' + __name__) - img_extension = 'jpg' MAX_DISTANCE = math.sqrt(3 * pow(255, 2)) @@ -64,15 +57,14 @@ def supported_formats(): stdout = stdout.decode('utf-8') stderr = stderr.decode('utf-8') version = stderr.split('\n')[0].split(' ')[2] - mp4 = 'libx264' in stdout and bool(re.compile('DEA.L. aac').findall(stdout)) return { 'version': version.split('.'), 'ogg': 'libtheora' in stdout and 'libvorbis' in stdout, 'webm': 'libvpx' in stdout and 'libvorbis' in stdout, 'vp8': 'libvpx' in stdout and 'libvorbis' in stdout, 'vp9': 'libvpx-vp9' in stdout and 'libopus' in stdout, - 'mp4': mp4, - 'h264': mp4, + 'mp4': 'libx264' in stdout and bool(re.compile('DEA.L. aac').findall(stdout)), + 'h264': 'libx264' in stdout and bool(re.compile('DEA.L. aac').findall(stdout)), } def stream(video, target, profile, info, audio_track=0, flags={}): @@ -163,7 +155,7 @@ def stream(video, target, profile, info, audio_track=0, flags={}): else: height = 96 - if settings.USE_VP9 and settings.FFMPEG_SUPPORTS_VP9: + if settings.FFMPEG_SUPPORTS_VP9: audio_codec = 'libopus' video_codec = 'libvpx-vp9' @@ -226,7 +218,7 @@ def stream(video, target, profile, info, audio_track=0, flags={}): bitrate = height*width*fps*bpp/1000 video_settings = trim + [ - '-b:v', '%dk' % bitrate, + '-vb', '%dk' % bitrate, '-aspect', aspect, # '-vf', 'yadif', '-max_muxing_queue_size', '512', @@ -254,8 +246,6 @@ def stream(video, target, profile, info, audio_track=0, flags={}): '-level', '4.0', '-pix_fmt', 'yuv420p', ] - if info['video'][0].get("force_framerate"): - video_settings += ['-r:v', str(fps)] video_settings += ['-map', '0:%s,0:0' % info['video'][0]['id']] audio_only = False else: @@ -295,7 +285,7 @@ def stream(video, target, profile, info, audio_track=0, flags={}): ac = min(ac, audiochannels) audio_settings += ['-ac', str(ac)] if audiobitrate: - audio_settings += ['-b:a', audiobitrate] + audio_settings += ['-ab', audiobitrate] if format == 'mp4': audio_settings += ['-c:a', 'aac', '-strict', '-2'] elif audio_codec == 'libopus': @@ -328,15 +318,14 @@ def stream(video, target, profile, info, audio_track=0, flags={}): pass1_post = post[:] pass1_post[-1] = '/dev/null' if format == 'webm': - if video_codec != 'libvpx-vp9': - pass1_post = ['-speed', '4'] + pass1_post + pass1_post = ['-speed', '4'] + pass1_post post = ['-speed', '1'] + post - cmds.append(base + ['-pass', '1', '-passlogfile', '%s.log' % target] - + video_settings + ['-an'] + pass1_post) + cmds.append(base + ['-an', '-pass', '1', '-passlogfile', '%s.log' % target] + + video_settings + pass1_post) cmds.append(base + ['-pass', '2', '-passlogfile', '%s.log' % target] - + video_settings + audio_settings + post) + + audio_settings + video_settings + post) else: - cmds.append(base + video_settings + audio_settings + post) + cmds.append(base + audio_settings + video_settings + post) if settings.FFMPEG_DEBUG: print('\n'.join([' '.join(cmd) for cmd in cmds])) @@ -444,15 +433,10 @@ def frame_direct(video, target, position): r = run_command(cmd) return r == 0 -def open_image_rgb(image_source): - source = Image.open(image_source) - source = ImageOps.exif_transpose(source) - source = source.convert('RGB') - return source def resize_image(image_source, image_output, width=None, size=None): if exists(image_source): - source = open_image_rgb(image_source) + source = Image.open(image_source).convert('RGB') source_width = source.size[0] source_height = source.size[1] if size: @@ -473,7 +457,7 @@ def resize_image(image_source, image_output, width=None, size=None): height = max(height, 1) if width < source_width: - resize_method = Image.LANCZOS + resize_method = Image.ANTIALIAS else: resize_method = Image.BICUBIC output = source.resize((width, height), resize_method) @@ -487,7 +471,7 @@ def timeline(video, prefix, modes=None, size=None): size = [64, 16] if isinstance(video, str): video = [video] - cmd = [os.path.normpath(os.path.join(settings.BASE_DIR, '../bin/oxtimelines')), + cmd = ['../bin/oxtimelines', '-s', ','.join(map(str, reversed(sorted(size)))), '-m', ','.join(modes), '-o', prefix, @@ -619,7 +603,7 @@ def timeline_strip(item, cuts, info, prefix): print(frame, 'cut', c, 'frame', s, frame, 'width', widths[s], box) # FIXME: why does this have to be frame+1? frame_image = Image.open(item.frame((frame+1)/fps)) - frame_image = frame_image.crop(box).resize((widths[s], timeline_height), Image.LANCZOS) + frame_image = frame_image.crop(box).resize((widths[s], timeline_height), Image.ANTIALIAS) for x_ in range(widths[s]): line_image.append(frame_image.crop((x_, 0, x_ + 1, timeline_height))) frame += widths[s] @@ -747,24 +731,19 @@ def remux_stream(src, dst): cmd = [ settings.FFMPEG, '-nostats', '-loglevel', 'error', - '-i', src, '-map_metadata', '-1', '-sn', + '-i', src, ] + video + [ ] + audio + [ '-movflags', '+faststart', dst ] - print(cmd) p = subprocess.Popen(cmd, stdin=subprocess.PIPE, - stdout=subprocess.PIPE, - stderr=subprocess.STDOUT, + stdout=open('/dev/null', 'w'), + stderr=open('/dev/null', 'w'), close_fds=True) - stdout, stderr = p.communicate() - if stderr: - logger.error("failed to remux %s %s", cmd, stderr) - return False, stderr - else: - return True, None + p.wait() + return True, None def ffprobe(path, *args): diff --git a/pandora/archive/migrations/0006_alter_file_extension_alter_file_id_alter_file_info_and_more.py b/pandora/archive/migrations/0006_alter_file_extension_alter_file_id_alter_file_info_and_more.py deleted file mode 100644 index a890a3b9..00000000 --- a/pandora/archive/migrations/0006_alter_file_extension_alter_file_id_alter_file_info_and_more.py +++ /dev/null @@ -1,100 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:24 - -import django.core.serializers.json -from django.db import migrations, models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('archive', '0005_auto_20180804_1554'), - ] - - operations = [ - migrations.AlterField( - model_name='file', - name='extension', - field=models.CharField(default='', max_length=255, null=True), - ), - migrations.AlterField( - model_name='file', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='file', - name='info', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='file', - name='language', - field=models.CharField(default='', max_length=255, null=True), - ), - migrations.AlterField( - model_name='file', - name='part', - field=models.CharField(default='', max_length=255, null=True), - ), - migrations.AlterField( - model_name='file', - name='part_title', - field=models.CharField(default='', max_length=255, null=True), - ), - migrations.AlterField( - model_name='file', - name='path', - field=models.CharField(default='', max_length=2048), - ), - migrations.AlterField( - model_name='file', - name='sort_path', - field=models.CharField(default='', max_length=2048), - ), - migrations.AlterField( - model_name='file', - name='type', - field=models.CharField(default='', max_length=255), - ), - migrations.AlterField( - model_name='file', - name='version', - field=models.CharField(default='', max_length=255, null=True), - ), - migrations.AlterField( - model_name='frame', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='instance', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='stream', - name='error', - field=models.TextField(blank=True, default=''), - ), - migrations.AlterField( - model_name='stream', - name='format', - field=models.CharField(default='webm', max_length=255), - ), - migrations.AlterField( - model_name='stream', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='stream', - name='info', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='volume', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/archive/migrations/0007_stream_archive_str_file_id_69a542_idx.py b/pandora/archive/migrations/0007_stream_archive_str_file_id_69a542_idx.py deleted file mode 100644 index 4a8bb7e2..00000000 --- a/pandora/archive/migrations/0007_stream_archive_str_file_id_69a542_idx.py +++ /dev/null @@ -1,17 +0,0 @@ -# Generated by Django 4.2.3 on 2023-08-18 12:54 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('archive', '0006_alter_file_extension_alter_file_id_alter_file_info_and_more'), - ] - - operations = [ - migrations.AddIndex( - model_name='stream', - index=models.Index(fields=['file', 'source', 'available'], name='archive_str_file_id_69a542_idx'), - ), - ] diff --git a/pandora/archive/migrations/0008_file_filename_file_folder.py b/pandora/archive/migrations/0008_file_filename_file_folder.py deleted file mode 100644 index 5c8b34da..00000000 --- a/pandora/archive/migrations/0008_file_filename_file_folder.py +++ /dev/null @@ -1,32 +0,0 @@ -# Generated by Django 4.2.7 on 2025-01-23 10:48 - -from django.db import migrations, models - -def update_path(apps, schema_editor): - File = apps.get_model("archive", "File") - for file in File.objects.all(): - if file.path: - parts = file.path.split('/') - file.filename = parts.pop() - file.folder = '/'.join(parts) - file.save() - -class Migration(migrations.Migration): - - dependencies = [ - ('archive', '0007_stream_archive_str_file_id_69a542_idx'), - ] - - operations = [ - migrations.AddField( - model_name='file', - name='filename', - field=models.CharField(default='', max_length=2048), - ), - migrations.AddField( - model_name='file', - name='folder', - field=models.CharField(default='', max_length=2048), - ), - migrations.RunPython(update_path), - ] diff --git a/pandora/archive/models.py b/pandora/archive/models.py index 476de4c4..56080815 100644 --- a/pandora/archive/models.py +++ b/pandora/archive/models.py @@ -53,9 +53,6 @@ class File(models.Model): path = models.CharField(max_length=2048, default="") # canoncial path/file sort_path = models.CharField(max_length=2048, default="") # sort name - folder = models.CharField(max_length=2048, default="") - filename = models.CharField(max_length=2048, default="") - type = models.CharField(default="", max_length=255) # editable @@ -154,10 +151,8 @@ class File(models.Model): self.sampleate = 0 self.channels = 0 - if self.framerate and self.duration > 0: + if self.framerate: self.pixels = int(self.width * self.height * float(utils.parse_decimal(self.framerate)) * self.duration) - else: - self.pixels = 0 def get_path_info(self): data = {} @@ -186,24 +181,10 @@ class File(models.Model): for type in ox.movie.EXTENSIONS: if data['extension'] in ox.movie.EXTENSIONS[type]: data['type'] = type - if data['extension'] == 'ogg' and self.info.get('video'): - data['type'] = 'video' - if data['type'] == 'unknown': - if self.info.get('video'): - data['type'] = 'video' - elif self.info.get('audio'): - data['type'] = 'audio' if 'part' in data and isinstance(data['part'], int): data['part'] = str(data['part']) return data - def update_path(self): - path = self.normalize_path() - parts = path.split('/') - self.filename = parts.pop() - self.folder = '/'.join(parts) - return path - def normalize_path(self): # FIXME: always use format_path if settings.CONFIG['site']['folderdepth'] == 4: @@ -267,7 +248,7 @@ class File(models.Model): update_path = False if self.info: if self.id: - self.path = self.update_path() + self.path = self.normalize_path() else: update_path = True if self.item: @@ -287,7 +268,7 @@ class File(models.Model): if self.type not in ('audio', 'video'): self.duration = None - elif self.id: + else: duration = sum([s.info.get('duration', 0) for s in self.streams.filter(source=None)]) if duration: @@ -295,12 +276,12 @@ class File(models.Model): if self.is_subtitle: self.available = self.data and True or False - elif self.id: + else: self.available = not self.uploading and \ self.streams.filter(source=None, available=True).count() super(File, self).save(*args, **kwargs) if update_path: - self.path = self.update_path() + self.path = self.normalize_path() super(File, self).save(*args, **kwargs) def get_path(self, name): @@ -384,8 +365,8 @@ class File(models.Model): self.info.update(stream.info) self.parse_info() self.save() - #if stream.info.get('video'): - # extract.make_keyframe_index(stream.media.path) + if stream.info.get('video'): + extract.make_keyframe_index(stream.media.path) return True, stream.media.size return save_chunk(stream, stream.media, chunk, offset, name, done_cb) return False, 0 @@ -414,7 +395,7 @@ class File(models.Model): config = settings.CONFIG['video'] height = self.info['video'][0]['height'] if self.info.get('video') else None max_resolution = max(config['resolutions']) - if height and height <= max_resolution and self.extension in ('mov', 'mkv', 'mp4', 'm4v'): + if height <= max_resolution and self.extension in ('mov', 'mkv', 'mp4', 'm4v'): vcodec = self.get_codec('video') acodec = self.get_codec('audio') if vcodec in self.MP4_VCODECS and acodec in self.MP4_ACODECS: @@ -425,7 +406,7 @@ class File(models.Model): config = settings.CONFIG['video'] height = self.info['video'][0]['height'] if self.info.get('video') else None max_resolution = max(config['resolutions']) - if height and height <= max_resolution and config['formats'][0] == self.extension: + if height <= max_resolution and config['formats'][0] == self.extension: vcodec = self.get_codec('video') acodec = self.get_codec('audio') if self.extension in ['mp4', 'm4v'] and vcodec in self.MP4_VCODECS and acodec in self.MP4_ACODECS: @@ -484,9 +465,6 @@ class File(models.Model): 'videoCodec': self.video_codec, 'wanted': self.wanted, } - for key in ('folder', 'filename'): - if keys and key in keys: - data[key] = getattr(self, key) if error: data['error'] = error for key in self.PATH_INFO: @@ -507,7 +485,7 @@ class File(models.Model): self.item.groups.filter(id__in=user.groups.all()).count() > 0 if 'instances' in data and 'filename' in self.info and self.data: data['instances'].append({ - 'ignore': not self.selected, + 'ignore': False, 'path': self.info['filename'], 'user': self.item.user.username if self.item and self.item.user else 'system', 'volume': 'Direct Upload' @@ -553,7 +531,7 @@ class File(models.Model): def process_stream(self): ''' - extract derivatives from stream upload + extract derivatives from webm upload ''' from . import tasks return tasks.process_stream.delay(self.id) @@ -747,9 +725,6 @@ class Stream(models.Model): class Meta: unique_together = ("file", "resolution", "format") - indexes = [ - models.Index(fields=['file', 'source', 'available']) - ] file = models.ForeignKey(File, related_name='streams', on_delete=models.CASCADE) resolution = models.IntegerField(default=96) @@ -829,15 +804,9 @@ class Stream(models.Model): shutil.move(self.file.data.path, target) self.file.data.name = '' self.file.save() - self.available = True - self.save() - done = True elif self.file.can_remux(): ok, error = extract.remux_stream(media, target) - if ok: - self.available = True - self.save() - done = True + done = True if not done: ok, error = extract.stream(media, target, self.name(), info, flags=self.flags) @@ -845,7 +814,7 @@ class Stream(models.Model): # get current version from db and update try: self.refresh_from_db() - except Stream.DoesNotExist: + except archive.models.DoesNotExist: pass else: self.update_status(ok, error) diff --git a/pandora/archive/queue.py b/pandora/archive/queue.py index 7cb768b2..8a8ff4ce 100644 --- a/pandora/archive/queue.py +++ b/pandora/archive/queue.py @@ -1,9 +1,11 @@ # -*- coding: utf-8 -*- from datetime import datetime -from time import time, monotonic +from time import time + +import celery.task.control +import kombu.five -from app.celery import app from .models import File @@ -16,7 +18,7 @@ def parse_job(job): 'file': f.oshash } if job['time_start']: - start_time = datetime.fromtimestamp(time() - (monotonic() - job['time_start'])) + start_time = datetime.fromtimestamp(time() - (kombu.five.monotonic() - job['time_start'])) r.update({ 'started': start_time, 'running': (datetime.now() - start_time).total_seconds() @@ -28,7 +30,7 @@ def parse_job(job): def status(): status = [] encoding_jobs = ('archive.tasks.extract_stream', 'archive.tasks.process_stream') - c = app.control.inspect() + c = celery.task.control.inspect() for job in c.active(safe=True).get('celery@pandora-encoding', []): if job['name'] in encoding_jobs: status.append(parse_job(job)) @@ -65,7 +67,7 @@ def fill_queue(): def get_celery_worker_status(): ERROR_KEY = "ERROR" try: - insp = app.control.inspect() + insp = celery.task.control.inspect() d = insp.stats() if not d: d = {ERROR_KEY: 'No running Celery workers were found.'} diff --git a/pandora/archive/tasks.py b/pandora/archive/tasks.py index 9e061b38..a2aa3d8e 100644 --- a/pandora/archive/tasks.py +++ b/pandora/archive/tasks.py @@ -2,14 +2,13 @@ from glob import glob +from celery.task import task from django.conf import settings -from django.db import transaction from django.db.models import Q from item.models import Item from item.tasks import update_poster, update_timeline from taskqueue.models import Task -from app.celery import app from . import models from . import extract @@ -69,7 +68,7 @@ def update_or_create_instance(volume, f): instance.file.item.update_wanted() return instance -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_files(user, volume, files): user = models.User.objects.get(username=user) volume, created = models.Volume.objects.get_or_create(user=user, name=volume) @@ -101,7 +100,7 @@ def update_files(user, volume, files): Task.start(i, user) update_timeline.delay(i.public_id) -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_info(user, info): user = models.User.objects.get(username=user) files = models.File.objects.filter(oshash__in=list(info)) @@ -115,7 +114,7 @@ def update_info(user, info): Task.start(i, user) update_timeline.delay(i.public_id) -@app.task(queue="encoding") +@task(queue="encoding") def process_stream(fileId): ''' process uploaded stream @@ -141,7 +140,7 @@ def process_stream(fileId): Task.finish(file.item) return True -@app.task(queue="encoding") +@task(queue="encoding") def extract_stream(fileId): ''' extract stream from direct upload @@ -170,7 +169,7 @@ def extract_stream(fileId): models.File.objects.filter(id=fileId).update(encoding=False) Task.finish(file.item) -@app.task(queue="encoding") +@task(queue="encoding") def extract_derivatives(fileId, rebuild=False): file = models.File.objects.get(id=fileId) streams = file.streams.filter(source=None) @@ -178,7 +177,7 @@ def extract_derivatives(fileId, rebuild=False): streams[0].extract_derivatives(rebuild) return True -@app.task(queue="encoding") +@task(queue="encoding") def update_stream(id): s = models.Stream.objects.get(pk=id) if not glob("%s*" % s.timeline_prefix): @@ -200,11 +199,11 @@ def update_stream(id): c.update_calculated_values() c.save() -@app.task(queue="encoding") +@task(queue="encoding") def download_media(item_id, url, referer=None): return external.download(item_id, url, referer) -@app.task(queue='default') +@task(queue='default') def move_media(data, user): from changelog.models import add_changelog from item.models import get_item, Item, ItemSort @@ -249,8 +248,7 @@ def move_media(data, user): if old_item and old_item.files.count() == 0 and i.files.count() == len(data['ids']): for a in old_item.annotations.all().order_by('id'): a.item = i - with transaction.atomic(): - a.set_public_id() + a.set_public_id() Annotation.objects.filter(id=a.id).update(item=i, public_id=a.public_id) old_item.clips.all().update(item=i, sort=i.sort) diff --git a/pandora/archive/views.py b/pandora/archive/views.py index 615a2db8..308e7c10 100644 --- a/pandora/archive/views.py +++ b/pandora/archive/views.py @@ -103,7 +103,7 @@ def update(request, data): file__available=False, file__wanted=True)] - if utils.get_by_key(settings.CONFIG['layers'], 'isSubtitles', True): + if list(filter(lambda l: l['id'] == 'subtitles', settings.CONFIG['layers'])): qs = files.filter( file__is_subtitle=True, file__available=False diff --git a/pandora/changelog/apps.py b/pandora/changelog/apps.py deleted file mode 100644 index 554ba51d..00000000 --- a/pandora/changelog/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class ChangelogConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'changelog' - diff --git a/pandora/changelog/migrations/0003_alter_changelog_id_alter_changelog_value_and_more.py b/pandora/changelog/migrations/0003_alter_changelog_id_alter_changelog_value_and_more.py deleted file mode 100644 index e8aacfaa..00000000 --- a/pandora/changelog/migrations/0003_alter_changelog_id_alter_changelog_value_and_more.py +++ /dev/null @@ -1,35 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:24 - -import django.core.serializers.json -from django.db import migrations, models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('changelog', '0002_jsonfield'), - ] - - operations = [ - migrations.AlterField( - model_name='changelog', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='changelog', - name='value', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='log', - name='data', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='log', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/clip/apps.py b/pandora/clip/apps.py deleted file mode 100644 index c957657f..00000000 --- a/pandora/clip/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class ClipConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'clip' - diff --git a/pandora/clip/managers.py b/pandora/clip/managers.py index 45e492b7..eb7c6ca9 100644 --- a/pandora/clip/managers.py +++ b/pandora/clip/managers.py @@ -17,7 +17,6 @@ keymap = { 'place': 'annotations__places__id', 'text': 'findvalue', 'annotations': 'findvalue', - 'layer': 'annotations__layer', 'user': 'annotations__user__username', } case_insensitive_keys = ('annotations__user__username', ) diff --git a/pandora/clip/migrations/0004_id_bigint.py b/pandora/clip/migrations/0004_id_bigint.py deleted file mode 100644 index b0415b96..00000000 --- a/pandora/clip/migrations/0004_id_bigint.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:24 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('clip', '0003_auto_20160219_1805'), - ] - - operations = [ - migrations.AlterField( - model_name='clip', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/clip/models.py b/pandora/clip/models.py index 406f13df..9736adb1 100644 --- a/pandora/clip/models.py +++ b/pandora/clip/models.py @@ -8,7 +8,6 @@ import ox from archive import extract from . import managers -from .utils import add_cuts def get_layers(item, interval=None, user=None): @@ -60,7 +59,9 @@ class MetaClip(object): self.hue = self.saturation = self.lightness = 0 self.volume = 0 - def update_findvalue(self): + def save(self, *args, **kwargs): + if self.duration != self.end - self.start: + self.update_calculated_values() if not self.aspect_ratio and self.item: streams = self.item.streams() if streams: @@ -88,11 +89,6 @@ class MetaClip(object): self.findvalue = '\n'.join(list(filter(None, [a.findvalue for a in anns]))) for l in [k['id'] for k in settings.CONFIG['layers']]: setattr(self, l, l in anns_by_layer and bool(len(anns_by_layer[l]))) - - def save(self, *args, **kwargs): - if self.duration != self.end - self.start: - self.update_calculated_values() - self.update_findvalue() models.Model.save(self, *args, **kwargs) clip_keys = ('id', 'in', 'out', 'position', 'created', 'modified', @@ -115,7 +111,8 @@ class MetaClip(object): del j[key] #needed here to make item find with clips work if 'annotations' in keys: - annotations = self.annotations.all().exclude(value='') + #annotations = self.annotations.filter(layer__in=settings.CONFIG['clipLayers']) + annotations = self.annotations.all() if qs: for q in qs: annotations = annotations.filter(q) @@ -153,12 +150,12 @@ class MetaClip(object): data['annotation'] = qs[0].public_id data['parts'] = self.item.cache['parts'] data['durations'] = self.item.cache['durations'] - for key in settings.CONFIG['itemTitleKeys'] + ['videoRatio']: + for key in ('title', 'director', 'year', 'videoRatio'): value = self.item.cache.get(key) if value: data[key] = value data['duration'] = data['out'] - data['in'] - add_cuts(data, self.item, self.start, self.end) + data['cuts'] = tuple([c for c in self.item.get('cuts', []) if c > self.start and c < self.end]) data['layers'] = self.get_layers(user) data['streams'] = [s.file.oshash for s in self.item.streams()] return data @@ -189,7 +186,6 @@ class MetaClip(object): def __str__(self): return self.public_id - class Meta: unique_together = ("item", "start", "end") diff --git a/pandora/clip/utils.py b/pandora/clip/utils.py deleted file mode 100644 index 7d6d03fe..00000000 --- a/pandora/clip/utils.py +++ /dev/null @@ -1,22 +0,0 @@ - - -def add_cuts(data, item, start, end): - cuts = [] - last = False - outer = [] - first = 0 - for cut in item.get('cuts', []): - if cut > start and cut < end: - if not cuts: - outer.append(first) - cuts.append(cut) - last = True - elif cut <= start: - first = cut - elif cut >= end: - if not len(outer): - outer.append(first) - if len(outer) == 1: - outer.append(cut) - data['cuts'] = tuple(cuts) - data['outerCuts'] = tuple(outer) diff --git a/pandora/config.0xdb.jsonc b/pandora/config.0xdb.jsonc index 0d4b1aae..8440de9a 100644 --- a/pandora/config.0xdb.jsonc +++ b/pandora/config.0xdb.jsonc @@ -56,7 +56,6 @@ "canExportAnnotations": {"friend": true, "staff": true, "admin": true}, "canImportAnnotations": {"staff": true, "admin": true}, "canImportItems": {}, - "canTranscribeAudio": {}, "canManageDocuments": {"staff": true, "admin": true}, "canManageEntities": {"staff": true, "admin": true}, "canManageHome": {}, @@ -1010,7 +1009,7 @@ { "id": "tags", "title": "Tags", - "canAddAnnotations": {"member": true, "friend": true, "staff": true, "admin": true}, + "canAddAnnotations": {"member": true, "staff": true, "admin": true}, "item": "Tag", "autocomplete": true, "overlap": true, @@ -1400,9 +1399,11 @@ corner of the screen "resolutions": List of video resolutions. Supported values are 96, 144, 240, 288, 360, 432, 480, 720 and 1080. + "torrent": If true, video downloads are offered via BitTorrent */ "video": { - "formats": ["mp4"], + "torrent": false, + "formats": ["webm", "mp4"], // fixme: this should be named "ratio" or "defaultRatio", // as it also applies to clip lists (on load) "previewRatio": 1.7777777778, diff --git a/pandora/config.indiancinema.jsonc b/pandora/config.indiancinema.jsonc index 518d5505..786a53d4 100644 --- a/pandora/config.indiancinema.jsonc +++ b/pandora/config.indiancinema.jsonc @@ -38,7 +38,7 @@ "capabilities": { "canAddItems": {"researcher": true, "staff": true, "admin": true}, "canAddDocuments": {"researcher": true, "staff": true, "admin": true}, - "canDownloadVideo": {"guest": -1, "member": 1, "researcher": 3, "staff": 3, "admin": 3}, + "canDownloadVideo": {"guest": -1, "member": -1, "researcher": 3, "staff": 3, "admin": 3}, "canDownloadSource": {"guest": -1, "member": -1, "researcher": -1, "staff": -1, "admin": -1}, "canEditAnnotations": {"staff": true, "admin": true}, "canEditDocuments": {"researcher": true, "staff": true, "admin": true}, @@ -58,7 +58,6 @@ "canImportAnnotations": {"researcher": true, "staff": true, "admin": true}, // import needs to handle itemRequiresVideo=false first "canImportItems": {}, - "canTranscribeAudio": {}, "canManageDocuments": {"member": true, "researcher": true, "staff": true, "admin": true}, "canManageEntities": {"member": true, "researcher": true, "staff": true, "admin": true}, "canManageHome": {"staff": true, "admin": true}, @@ -74,14 +73,13 @@ "canSeeAccessed": {"researcher": true, "staff": true, "admin": true}, "canSeeAllTasks": {"staff": true, "admin": true}, "canSeeDebugMenu": {"researcher": true, "staff": true, "admin": true}, - "canSeeDocument": {"guest": 1, "member": 1, "researcher": 2, "staff": 3, "admin": 3}, "canSeeExtraItemViews": {"researcher": true, "staff": true, "admin": true}, - "canSeeItem": {"guest": 2, "member": 2, "researcher": 2, "staff": 3, "admin": 3}, "canSeeMedia": {"researcher": true, "staff": true, "admin": true}, + "canSeeDocument": {"guest": 1, "member": 1, "researcher": 2, "staff": 3, "admin": 3}, + "canSeeItem": {"guest": 2, "member": 2, "researcher": 2, "staff": 3, "admin": 3}, "canSeeSize": {"researcher": true, "staff": true, "admin": true}, "canSeeSoftwareVersion": {"researcher": true, "staff": true, "admin": true}, - "canSendMail": {"staff": true, "admin": true}, - "canShare": {"staff": true, "admin": true} + "canSendMail": {"staff": true, "admin": true} }, /* "clipKeys" are the properties that clips can be sorted by (the values are @@ -314,14 +312,6 @@ "autocomplete": true, "columnWidth": 128 }, - { - "id": "fulltext", - "operator": "+", - "title": "Fulltext", - "type": "text", - "fulltext": true, - "find": true - }, { "id": "created", "operator": "-", @@ -1504,7 +1494,6 @@ "hasEvents": true, "hasPlaces": true, "item": "Keyword", - "autocomplete": true, "overlap": true, "type": "string" }, @@ -1886,9 +1875,11 @@ corner of the screen "resolutions": List of video resolutions. Supported values are 96, 144, 240, 288, 360, 432, 480, 720 and 1080. + "torrent": If true, video downloads are offered via BitTorrent */ "video": { - "formats": ["mp4"], + "torrent": false, + "formats": ["webm", "mp4"], "previewRatio": 1.375, "resolutions": [240, 480] } diff --git a/pandora/config.padma.jsonc b/pandora/config.padma.jsonc index a3e41988..c78740a9 100644 --- a/pandora/config.padma.jsonc +++ b/pandora/config.padma.jsonc @@ -56,7 +56,6 @@ "canExportAnnotations": {"member": true, "staff": true, "admin": true}, "canImportAnnotations": {"member": true, "staff": true, "admin": true}, "canImportItems": {"member": true, "staff": true, "admin": true}, - "canTranscribeAudio": {"staff": true, "admin": true}, "canManageDocuments": {"member": true, "staff": true, "admin": true}, "canManageEntities": {"member": true, "staff": true, "admin": true}, "canManageHome": {"staff": true, "admin": true}, @@ -72,14 +71,13 @@ "canSeeAccessed": {"staff": true, "admin": true}, "canSeeAllTasks": {"staff": true, "admin": true}, "canSeeDebugMenu": {"staff": true, "admin": true}, - "canSeeDocument": {"guest": 1, "member": 1, "staff": 4, "admin": 4}, "canSeeExtraItemViews": {"staff": true, "admin": true}, - "canSeeItem": {"guest": 1, "member": 1, "staff": 4, "admin": 4}, "canSeeMedia": {"staff": true, "admin": true}, + "canSeeDocument": {"guest": 1, "member": 1, "staff": 4, "admin": 4}, + "canSeeItem": {"guest": 1, "member": 1, "staff": 4, "admin": 4}, "canSeeSize": {"staff": true, "admin": true}, "canSeeSoftwareVersion": {"staff": true, "admin": true}, - "canSendMail": {"staff": true, "admin": true}, - "canShare": {"staff": true, "admin": true} + "canSendMail": {"staff": true, "admin": true} }, /* "clipKeys" are the properties that clips can be sorted by (the values are @@ -248,28 +246,6 @@ "filter": true, "find": true }, - { - "id": "source", - "title": "Source", - "type": "string", - "autocomplete": true, - "description": true, - "columnWidth": 180, - "filter": true, - "find": true, - "sort": true - }, - { - "id": "project", - "title": "Project", - "type": "string", - "autocomplete": true, - "description": true, - "columnWidth": 120, - "filter": true, - "find": true, - "sort": true - }, { "id": "id", "operator": "+", @@ -315,24 +291,6 @@ "sort": true, "columnWidth": 256 }, - { - "id": "content", - "operator": "+", - "title": "Content", - "type": "text", - "find": true, - "sort": true, - "columnWidth": 256 - }, - { - "id": "translation", - "operator": "+", - "title": "Translation", - "type": "text", - "find": true, - "sort": true, - "columnWidth": 256 - }, { "id": "matches", "operator": "-", @@ -352,20 +310,6 @@ "autocomplete": true, "columnWidth": 128 }, - { - "id": "notes", - "title": "Notes", - "type": "text", - "capability": "canEditMetadata" - }, - { - "id": "fulltext", - "operator": "+", - "title": "Fulltext", - "type": "text", - "fulltext": true, - "find": true - }, { "id": "created", "operator": "-", @@ -601,6 +545,7 @@ "title": "Director", "type": ["string"], "autocomplete": true, + "columnRequired": true, "columnWidth": 180, "sort": true, "sortType": "person" @@ -619,6 +564,7 @@ "title": "Featuring", "type": ["string"], "autocomplete": true, + "columnRequired": true, "columnWidth": 180, "filter": true, "sort": true, @@ -674,7 +620,7 @@ { "id": "annotations", "title": "Annotations", - "type": "text", // fixme: not the best type for this magic key + "type": "string", // fixme: not the best type for this magic key "find": true }, { @@ -712,7 +658,7 @@ }, { "id": "numberofannotations", - "title": "Number of Annotations", + "title": "Annotations", "type": "integer", "columnWidth": 60, "sort": true @@ -848,16 +794,12 @@ "id": "user", "title": "User", "type": "string", - "columnWidth": 90, "capability": "canSeeMedia", - "sort": true, "find": true }, { "id": "groups", "title": "Group", - "columnWidth": 90, - "sort": true, "type": ["string"] }, { @@ -1390,9 +1332,11 @@ corner of the screen "resolutions": List of video resolutions. Supported values are 96, 144, 240, 288, 360, 432, 480, 720 and 1080. + "torrent": If true, video downloads are offered via BitTorrent */ "video": { - "formats": ["mp4"], + "torrent": true, + "formats": ["webm", "mp4"], "previewRatio": 1.3333333333, //supported resolutions are //1080, 720, 480, 432, 360, 288, 240, 144, 96 diff --git a/pandora/config.pandora.jsonc b/pandora/config.pandora.jsonc index b0a64ab4..bd76faa2 100644 --- a/pandora/config.pandora.jsonc +++ b/pandora/config.pandora.jsonc @@ -29,7 +29,7 @@ examples (config.SITENAME.jsonc) that are part of this pan.do/ra distribution. "text": Text shown on mouseover */ "cantPlay": { - "icon": "NoCopyright", + "icon": "noCopyright", "link": "", "text": "" }, @@ -63,12 +63,11 @@ examples (config.SITENAME.jsonc) that are part of this pan.do/ra distribution. "canExportAnnotations": {"member": true, "staff": true, "admin": true}, "canImportAnnotations": {"member": true, "staff": true, "admin": true}, "canImportItems": {"member": true, "staff": true, "admin": true}, - "canTranscribeAudio": {}, "canManageDocuments": {"member": true, "staff": true, "admin": true}, "canManageEntities": {"member": true, "staff": true, "admin": true}, "canManageHome": {"staff": true, "admin": true}, "canManagePlacesAndEvents": {"member": true, "staff": true, "admin": true}, - "canManageTitlesAndNames": {"member": false, "staff": true, "admin": true}, + "canManageTitlesAndNames": {"member": true, "staff": true, "admin": true}, "canManageTranslations": {"admin": true}, "canManageUsers": {"staff": true, "admin": true}, "canPlayClips": {"guest": 1, "member": 1, "staff": 4, "admin": 4}, @@ -103,7 +102,8 @@ examples (config.SITENAME.jsonc) that are part of this pan.do/ra distribution. ], /* "clipLayers" is the ordered list of public layers that will appear as the - text of clips (in grid view, below the icon). + text of clips (in grid view, below the icon). Excluding a layer from this + list means it will not be included in find annotations. */ "clipLayers": ["publicnotes", "keywords", "subtitles"], /* @@ -351,11 +351,11 @@ examples (config.SITENAME.jsonc) that are part of this pan.do/ra distribution. "type": "enum", "columnWidth": 90, "format": {"type": "ColorLevel", "args": [ - ["Public", "Restricted", "Private"] + ["Public", "Out of Copyright", "Under Copyright", "Private"] ]}, "sort": true, "sortOperator": "+", - "values": ["Public", "Restricted", "Private", "Unknown"] + "values": ["Public", "Out of Copyright", "Under Copyright", "Private", "Unknown"] } ], /* @@ -753,13 +753,6 @@ examples (config.SITENAME.jsonc) that are part of this pan.do/ra distribution. "capability": "canSeeMedia", "find": true }, - { - "id": "filename", - "title": "Filename", - "type": ["string"], - "capability": "canSeeMedia", - "find": true - }, { "id": "created", "title": "Date Created", @@ -1166,11 +1159,6 @@ examples (config.SITENAME.jsonc) that are part of this pan.do/ra distribution. "findDocuments": {"conditions": [], "operator": "&"}, "followPlayer": true, "help": "", - "hidden": { - "collections": [], - "edits": [], - "lists": [] - }, "icons": "posters", "infoIconSize": 256, "item": "", @@ -1279,11 +1267,13 @@ examples (config.SITENAME.jsonc) that are part of this pan.do/ra distribution. corner of the screen "resolutions": List of video resolutions. Supported values are 96, 144, 240, 288, 360, 432, 480, 720 and 1080. + "torrent": If true, video downloads are offered via BitTorrent */ "video": { - "downloadFormat": "mp4", - "formats": ["mp4"], + "downloadFormat": "webm", + "formats": ["webm", "mp4"], "previewRatio": 1.3333333333, - "resolutions": [240, 480] + "resolutions": [240, 480], + "torrent": false } } diff --git a/pandora/document/apps.py b/pandora/document/apps.py deleted file mode 100644 index 88a5f0b4..00000000 --- a/pandora/document/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class DocumentConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'document' - diff --git a/pandora/document/cbr.py b/pandora/document/cbr.py deleted file mode 100644 index f895e934..00000000 --- a/pandora/document/cbr.py +++ /dev/null @@ -1,106 +0,0 @@ -# -*- coding: utf-8 -*- -import logging -import os -import zipfile - -import ox - -logger = logging.getLogger(__name__) -IMAGE_EXTENSIONS = ['.jpg', '.png', '.gif'] - - -def filter_images(files): - return [f for f in files if os.path.splitext(f)[-1].lower() in IMAGE_EXTENSIONS] - -def filter_folders(files): - out = [] - for path in files: - if not [f for f in files if f.startswith(path + '/')]: - out.append(path) - return out - -def detect_format(path): - with open(path, 'rb') as fd: - head = fd.read(10) - if head[:2] == b'PK': - return 'cbz' - if head[:3] == b'Rar': - return 'cbr' - logger.debug('unknown cbr/cbz file %s - %s', head, path) - return 'unknown' - -def cover(path): - format = detect_format(path) - if format == 'cbz': - cover = cover_cbz(path) - elif format == 'cbr': - cover = cover_cbr(path) - else: - cover = None - return cover - -def cover_cbr(path): - data = None - try: - from unrardll import names, extract_member - except: - logger.error('to extract covers from cbr files you have to install python3-unrardll: apt install python3-unrardll') - return data - try: - files = list(names(path)) - files = filter_folders(files) - files = filter_images(files) - if files: - cover = ox.sorted_strings(files)[0] - filename, data = extract_member(path, lambda h: h['filename'] == cover) - except: - logger.debug('invalid cbr file %s', path) - data = None - return data - -def cover_cbz(path): - data = None - logger.debug('cover %s', path) - data = None - try: - z = zipfile.ZipFile(path) - except zipfile.BadZipFile: - logger.debug('invalid cbz file %s', path) - return data - files = [f.filename for f in z.filelist] - files = filter_images(files) - if files: - cover = ox.sorted_strings(files)[0] - try: - data = z.read(cover) - except: - data = None - return data - -def get_pages(path): - files = [] - format = detect_format(path) - if format == 'cbz': - try: - z = zipfile.ZipFile(path) - except zipfile.BadZipFile: - logger.debug('invalid cbz file %s', path) - return data - files = [f.filename for f in z.filelist] - elif format == 'cbr': - try: - from unrar import rarfile - rar = rarfile.RarFile(path) - files = rar.namelist() - except: - pass - files = filter_images(files) - return len(files) - - -def info(path): - data = {} - data['title'] = os.path.splitext(os.path.basename(path))[0] - data['pages'] = get_pages(path) - return data - diff --git a/pandora/document/epub.py b/pandora/document/epub.py deleted file mode 100644 index d4656619..00000000 --- a/pandora/document/epub.py +++ /dev/null @@ -1,189 +0,0 @@ -import os -import xml.etree.ElementTree as ET -import zipfile -import re -from urllib.parse import unquote -import lxml.html -from io import BytesIO - -from PIL import Image - -from ox import strip_tags, decode_html, normalize_name - -import logging -logging.getLogger('PIL').setLevel(logging.ERROR) -logger = logging.getLogger(__name__) - - -def get_ratio(data): - try: - img = Image.open(BytesIO(data)) - return img.size[0]/img.size[1] - except: - return -1 - - -def normpath(path): - return '/'.join(os.path.normpath(path).split(os.sep)) - - -def cover(path): - logger.debug('cover %s', path) - data = None - try: - z = zipfile.ZipFile(path) - except zipfile.BadZipFile: - logger.debug('invalid epub file %s', path) - return data - - def use(filename): - logger.debug('using %s', filename) - try: - data = z.read(filename) - except: - return None - r = get_ratio(data) - if r < 0.3 or r > 2: - return None - return data - - files = [] - for f in z.filelist: - if f.filename == 'calibre-logo.png': - continue - if 'cover' in f.filename.lower() and f.filename.split('.')[-1] in ('jpg', 'jpeg', 'png'): - return use(f.filename) - files.append(f.filename) - opf = [f for f in files if f.endswith('opf')] - if opf: - #logger.debug('opf: %s', z.read(opf[0]).decode()) - info = ET.fromstring(z.read(opf[0])) - metadata = info.findall('{http://www.idpf.org/2007/opf}metadata') - if metadata: - metadata = metadata[0] - manifest = info.findall('{http://www.idpf.org/2007/opf}manifest') - if manifest: - manifest = manifest[0] - if metadata and manifest: - for e in list(metadata): - if e.tag == '{http://www.idpf.org/2007/opf}meta' and e.attrib.get('name') == 'cover': - cover_id = e.attrib['content'] - for e in list(manifest): - if e.attrib['id'] == cover_id: - filename = unquote(e.attrib['href']) - filename = normpath(os.path.join(os.path.dirname(opf[0]), filename)) - if filename in files: - return use(filename) - if manifest: - images = [e for e in list(manifest) if 'image' in e.attrib['media-type']] - if images: - image_data = [] - for e in images: - filename = unquote(e.attrib['href']) - filename = normpath(os.path.join(os.path.dirname(opf[0]), filename)) - if filename in files: - image_data.append(filename) - if image_data: - image_data.sort(key=lambda name: z.getinfo(name).file_size) - return use(image_data[-1]) - for e in list(manifest): - if 'html' in e.attrib['media-type']: - filename = unquote(e.attrib['href']) - filename = normpath(os.path.join(os.path.dirname(opf[0]), filename)) - html = z.read(filename).decode('utf-8', 'ignore') - img = re.compile('= img.size[1]: - width = size - height = int(size / aspect) - else: - width = int(size / aspect) - height = size - img = img.resize((width, height), resize_method) - img.save(output, quality=72) - return jpg - - -class FulltextPageMixin(FulltextMixin): - _ES_INDEX = "document-page-index" - - def extract_fulltext(self): - if self.document.file: - if self.document.extension == 'pdf': - return extract_text(self.document.file.path, self.page) - elif self.extension == 'epub': - # FIXME: is there a nice way to split that into pages - return epub.extract_text(self.file.path) - elif self.extension == 'txt': - data = '' - if os.path.exists(self.file.path): - with open(self.file.path) as fd: - data = fd.read() - return data - elif self.extension in IMAGE_EXTENSIONS: - return ocr_image(self.document.file.path) - elif self.extension == 'html': - # FIXME: is there a nice way to split that into pages - return self.data.get('text', '') - return '' diff --git a/pandora/document/managers/__init__.py b/pandora/document/managers.py similarity index 97% rename from pandora/document/managers/__init__.py rename to pandora/document/managers.py index edcc4789..4210cd62 100644 --- a/pandora/document/managers/__init__.py +++ b/pandora/document/managers.py @@ -1,5 +1,4 @@ # -*- coding: utf-8 -*- -from datetime import datetime import unicodedata from django.db.models import Q, Manager @@ -15,7 +14,6 @@ from documentcollection.models import Collection from item import utils from user.models import Group -from .pages import PageManager keymap = { 'item': 'items__public_id', @@ -63,7 +61,7 @@ def parseCondition(condition, user, item=None, owner=None): def buildCondition(k, op, v, user, exclude=False, owner=None): import entity.models - from .. import models + from . import models # fixme: frontend should never call with list if k == 'list': @@ -299,8 +297,5 @@ class DocumentManager(Manager): q |= Q(groups__in=user.groups.all()) rendered_q |= Q(groups__in=user.groups.all()) qs = qs.filter(q) - max_level = len(settings.CONFIG['documentRightsLevels']) - qs = qs.filter(rightslevel__lte=max_level) return qs - diff --git a/pandora/document/managers/pages.py b/pandora/document/managers/pages.py deleted file mode 100644 index 2fbfa4fe..00000000 --- a/pandora/document/managers/pages.py +++ /dev/null @@ -1,302 +0,0 @@ -# -*- coding: utf-8 -*- -from datetime import datetime -import unicodedata - -from six import string_types -from django.db.models import Q, Manager -from django.conf import settings - -import ox -from oxdjango.query import QuerySet - -import entity.managers -from oxdjango.managers import get_operator - -from documentcollection.models import Collection -from item import utils -from user.models import Group - - -keymap = { - 'item': 'items__public_id', -} -default_key = 'title' - -def get_key_type(k): - key_type = (utils.get_by_id(settings.CONFIG['documentKeys'], k) or {'type': 'string'}).get('type') - if isinstance(key_type, list): - key_type = key_type[0] - key_type = { - 'title': 'string', - 'person': 'string', - 'text': 'string', - 'year': 'string', - 'length': 'string', - 'layer': 'string', - 'list': 'list', - }.get(key_type, key_type) - return key_type - - -def parseCondition(condition, user, item=None, owner=None): - ''' - ''' - k = condition.get('key', default_key) - k = keymap.get(k, k) - if not k: - k = default_key - if item and k == 'description': - item_conditions = condition.copy() - item_conditions['key'] = 'items__itemproperties__description' - return parseCondition(condition, user) | parseCondition(item_conditions, user) - - v = condition['value'] - op = condition.get('operator') - if not op: - op = '=' - - if op.startswith('!'): - return buildCondition(k, op[1:], v, user, True, owner=owner) - else: - return buildCondition(k, op, v, user, owner=owner) - -def buildCondition(k, op, v, user, exclude=False, owner=None): - import entity.models - from .. import models - - # fixme: frontend should never call with list - if k == 'list': - print('fixme: frontend should never call with list', k, op, v) - k = 'collection' - - key_type = get_key_type(k) - - key_config = (utils.get_by_id(settings.CONFIG['documentKeys'], k) or {'type': 'string'}) - - facet_keys = models.Document.facet_keys - if k == 'document': - k = 'document__id' - if op == '&' and isinstance(v, list): - v = [ox.fromAZ(id_) for id_ in v] - k += get_operator(op) - else: - v = ox.fromAZ(v) - q = Q(**{k: v}) - if exclude: - q = ~Q(document__id__in=models.Document.objects.filter(q)) - return q - elif k == 'rightslevel': - q = Q(document__rightslevel=v) - if exclude: - q = ~Q(document__rightslevel=v) - return q - elif k == 'groups': - if op == '==' and v == '$my': - if not owner: - owner = user - groups = owner.groups.all() - else: - key = 'name' + get_operator(op) - groups = Group.objects.filter(**{key: v}) - if not groups.count(): - return Q(id=0) - q = Q(document__groups__in=groups) - if exclude: - q = ~q - return q - elif k in ('oshash', 'items__public_id'): - q = Q(**{k: v}) - if exclude: - q = ~Q(id__in=models.Document.objects.filter(q)) - return q - elif isinstance(v, bool): - key = k - elif k == 'entity': - entity_key, entity_v = entity.managers.namePredicate(op, v) - key = 'id__in' - v = entity.models.DocumentProperties.objects.filter(**{ - 'entity__' + entity_key: entity_v - }).values_list('document_id', flat=True) - elif k == 'collection': - q = Q(id=0) - l = v.split(":", 1) - if len(l) >= 2: - lqs = list(Collection.objects.filter(name=l[1], user__username=l[0])) - if len(lqs) == 1 and lqs[0].accessible(user): - l = lqs[0] - if l.query.get('static', False) is False: - data = l.query - q = parseConditions(data.get('conditions', []), - data.get('operator', '&'), - user, owner=l.user) - else: - q = Q(id__in=l.documents.all()) - else: - q = Q(id=0) - return q - elif key_config.get('fulltext'): - qs = models.Page.find_fulltext_ids(v) - q = Q(id__in=qs) - if exclude: - q = ~Q(id__in=qs) - return q - elif key_type == 'boolean': - q = Q(**{'find__key': k, 'find__value': v}) - if exclude: - q = ~Q(id__in=models.Document.objects.filter(q)) - return q - elif key_type == "string": - in_find = True - if in_find: - value_key = 'find__value' - else: - value_key = k - if isinstance(v, string_types): - v = unicodedata.normalize('NFKD', v).lower() - if k in facet_keys: - in_find = False - facet_value = 'facets__value' + get_operator(op, 'istr') - v = models.Document.objects.filter(**{'facets__key': k, facet_value: v}) - value_key = 'id__in' - else: - value_key = value_key + get_operator(op) - k = str(k) - value_key = str(value_key) - if k == '*': - q = Q(**{'find__value' + get_operator(op): v}) | \ - Q(**{'facets__value' + get_operator(op, 'istr'): v}) - elif in_find: - q = Q(**{'find__key': k, value_key: v}) - else: - q = Q(**{value_key: v}) - if exclude: - q = ~Q(id__in=models.Document.objects.filter(q)) - return q - elif key_type == 'date': - def parse_date(d): - while len(d) < 3: - d.append(1) - return datetime(*[int(i) for i in d]) - - #using sort here since find only contains strings - v = parse_date(v.split('-')) - vk = 'sort__%s%s' % (k, get_operator(op, 'int')) - vk = str(vk) - q = Q(**{vk: v}) - if exclude: - q = ~q - return q - else: # integer, float, list, time - #use sort table here - if key_type == 'time': - v = int(utils.parse_time(v)) - - vk = 'sort__%s%s' % (k, get_operator(op, 'int')) - vk = str(vk) - q = Q(**{vk: v}) - if exclude: - q = ~q - return q - key = str(key) - q = Q(**{key: v}) - if exclude: - q = ~q - return q - - -def parseConditions(conditions, operator, user, item=None, owner=None): - ''' - conditions: [ - { - value: "war" - } - { - key: "year", - value: "1970-1980, - operator: "!=" - }, - { - key: "country", - value: "f", - operator: "^" - } - ], - operator: "&" - ''' - conn = [] - for condition in conditions: - if 'conditions' in condition: - q = parseConditions(condition['conditions'], - condition.get('operator', '&'), user, item, owner=owner) - if q: - conn.append(q) - pass - else: - conn.append(parseCondition(condition, user, item, owner=owner)) - if conn: - q = conn[0] - for c in conn[1:]: - if operator == '|': - q = q | c - else: - q = q & c - return q - return None - - -class PageManager(Manager): - - def get_query_set(self): - return QuerySet(self.model) - - def find(self, data, user, item=None): - ''' - query: { - conditions: [ - { - value: "war" - } - { - key: "year", - value: "1970-1980, - operator: "!=" - }, - { - key: "country", - value: "f", - operator: "^" - } - ], - operator: "&" - } - ''' - - #join query with operator - qs = self.get_query_set() - query = data.get('query', {}) - conditions = parseConditions(query.get('conditions', []), - query.get('operator', '&'), - user, item) - if conditions: - qs = qs.filter(conditions) - qs = qs.distinct() - - #anonymous can only see public items - if not user or user.is_anonymous: - level = 'guest' - allowed_level = settings.CONFIG['capabilities']['canSeeDocument'][level] - qs = qs.filter(document__rightslevel__lte=allowed_level) - rendered_q = Q(rendered=True) - #users can see public items, there own items and items of there groups - else: - level = user.profile.get_level() - allowed_level = settings.CONFIG['capabilities']['canSeeDocument'][level] - q = Q(document__rightslevel__lte=allowed_level) | Q(document__user=user) - rendered_q = Q(rendered=True) | Q(document__user=user) - if user.groups.count(): - q |= Q(document__groups__in=user.groups.all()) - rendered_q |= Q(document__groups__in=user.groups.all()) - qs = qs.filter(q) - - return qs - diff --git a/pandora/document/migrations/0012_auto_20200513_0001.py b/pandora/document/migrations/0012_auto_20200513_0001.py deleted file mode 100644 index 2bf7b0ab..00000000 --- a/pandora/document/migrations/0012_auto_20200513_0001.py +++ /dev/null @@ -1,35 +0,0 @@ -# -*- coding: utf-8 -*- -# Generated by Django 1.11.22 on 2020-05-13 00:01 -from __future__ import unicode_literals - -import django.core.serializers.json -from django.db import migrations, models -import django.db.models.deletion -import document.fulltext -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('document', '0011_jsonfield'), - ] - - operations = [ - migrations.CreateModel( - name='Page', - fields=[ - ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), - ('created', models.DateTimeField(auto_now_add=True)), - ('modified', models.DateTimeField(auto_now=True)), - ('page', models.IntegerField(default=1)), - ('data', oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder)), - ], - bases=(models.Model, document.fulltext.FulltextPageMixin), - ), - migrations.AddField( - model_name='page', - name='document', - field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='pages_set', to='document.Document'), - ), - ] diff --git a/pandora/document/migrations/0013_id_bigint.py b/pandora/document/migrations/0013_id_bigint.py deleted file mode 100644 index 09dd44ed..00000000 --- a/pandora/document/migrations/0013_id_bigint.py +++ /dev/null @@ -1,55 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:24 - -import django.core.serializers.json -from django.db import migrations, models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('document', '0012_auto_20200513_0001'), - ] - - operations = [ - migrations.AlterField( - model_name='access', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='document', - name='data', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='document', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='facet', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='find', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='itemproperties', - name='description', - field=models.TextField(default=''), - ), - migrations.AlterField( - model_name='itemproperties', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='page', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/document/models.py b/pandora/document/models.py index ef664df6..e2501244 100644 --- a/pandora/document/models.py +++ b/pandora/document/models.py @@ -6,12 +6,11 @@ import os import re import unicodedata -from django.conf import settings -from django.contrib.auth import get_user_model from django.db import models, transaction from django.db.models import Q, Sum, Max +from django.contrib.auth import get_user_model from django.db.models.signals import pre_delete -from django.utils import datetime_safe +from django.conf import settings from oxdjango.fields import JSONField from PIL import Image @@ -22,18 +21,15 @@ from oxdjango.sortmodel import get_sort_field from person.models import get_name_sort from item.models import Item from annotation.models import Annotation -from archive.extract import resize_image, open_image_rgb +from archive.extract import resize_image from archive.chunk import save_chunk from user.models import Group from user.utils import update_groups -from . import cbr -from . import epub from . import managers -from . import tasks -from . import txt from . import utils -from .fulltext import FulltextMixin, FulltextPageMixin +from . import tasks +from .fulltext import FulltextMixin User = get_user_model() @@ -83,7 +79,7 @@ class Document(models.Model, FulltextMixin): current_values = [] for k in settings.CONFIG['documentKeys']: if k.get('sortType') == 'person': - current_values += self.get_value(k['id'], []) + current_values += self.get(k['id'], []) if not isinstance(current_values, list): if not current_values: current_values = [] @@ -177,21 +173,13 @@ class Document(models.Model, FulltextMixin): if self.extension == 'pdf': prefix = 2 value = self.pages - elif self.extension == 'epub': - prefix = 3 - value = self.pages - elif self.extension == 'txt': - prefix = 4 - value = self.pages - elif self.extension in ('cbr', 'cbz'): - prefix = 5 - value = self.pages - elif self.extension == 'html': - prefix = 1 - value = self.dimensions else: - prefix = 0 - value = self.width * self.height + if self.extension == 'html': + prefix = 1 + value = self.dimensions + else: + prefix = 0 + value = self.width * self.height if value < 0: value = 0 s.dimensions = ox.sort_string('%d' % prefix) + ox.sort_string('%d' % value) @@ -339,9 +327,6 @@ class Document(models.Model, FulltextMixin): def editable(self, user, item=None): if not user or user.is_anonymous: return False - max_level = len(settings.CONFIG['rightsLevels']) - if self.rightslevel > max_level: - return False if self.user == user or \ self.groups.filter(id__in=user.groups.all()).count() > 0 or \ user.is_staff or \ @@ -361,8 +346,6 @@ class Document(models.Model, FulltextMixin): groups = data.pop('groups') update_groups(self, groups) for key in data: - if key == "id": - continue k = list(filter(lambda i: i['id'] == key, settings.CONFIG['documentKeys'])) ktype = k and k[0].get('type') or '' if key == 'text' and self.extension == 'html': @@ -401,13 +384,7 @@ class Document(models.Model, FulltextMixin): @property def dimensions(self): - if self.extension in ( - 'cbr', - 'cbz', - 'epub', - 'pdf', - 'txt', - ): + if self.extension == 'pdf': return self.pages elif self.extension == 'html': return len(self.data.get('text', '').split(' ')) @@ -538,17 +515,14 @@ class Document(models.Model, FulltextMixin): return save_chunk(self, self.file, chunk, offset, name, done_cb) return False, 0 - def thumbnail(self, size=None, page=None, accept=None): + def thumbnail(self, size=None, page=None): if not self.file: return os.path.join(settings.STATIC_ROOT, 'png/document.png') src = self.file.path folder = os.path.dirname(src) if size: size = int(size) - ext = 'jpg' - if accept and 'image/avif' in accept and size > 512: - ext = 'avif' - path = os.path.join(folder, '%d.%s' % (size, ext)) + path = os.path.join(folder, '%d.jpg' % size) else: path = src if self.extension == 'pdf': @@ -572,59 +546,35 @@ class Document(models.Model, FulltextMixin): if len(crop) == 4: path = os.path.join(folder, '%dp%d,%s.jpg' % (1024, page, ','.join(map(str, crop)))) if not os.path.exists(path): - img = open_image_rgb(src).crop(crop) + img = Image.open(src).crop(crop) img.save(path) else: - img = open_image_rgb(path) + img = Image.open(path) src = path if size < max(img.size): path = os.path.join(folder, '%dp%d,%s.jpg' % (size, page, ','.join(map(str, crop)))) if not os.path.exists(path): resize_image(src, path, size=size) - elif self.extension in ('cbr', 'cbz'): - path = os.path.join(folder, '1024.jpg') - if os.path.exists(src) and not os.path.exists(path): - data = cbr.cover(src) - if data: - with open(path, "wb") as fd: - fd.write(data) - else: - return os.path.join(settings.STATIC_ROOT, 'png/document.png') - elif self.extension == 'epub': - path = os.path.join(folder, '1024.jpg') - if os.path.exists(src) and not os.path.exists(path): - data = epub.cover(src) - if data: - with open(path, "wb") as fd: - fd.write(data) - else: - return os.path.join(settings.STATIC_ROOT, 'png/document.png') - elif self.extension == 'txt': - path = os.path.join(folder, '1024.jpg') - if os.path.exists(src) and not os.path.exists(path): - txt.render(src, path) - if not os.path.exists(path): - return os.path.join(settings.STATIC_ROOT, 'png/document.png') - elif self.extension in ('jpg', 'png', 'gif', 'webp', 'heic', 'heif', 'cr2'): + elif self.extension in ('jpg', 'png', 'gif'): if os.path.exists(src): if size and page: crop = list(map(int, page.split(','))) if len(crop) == 4: path = os.path.join(folder, '%s.jpg' % ','.join(map(str, crop))) if not os.path.exists(path): - img = open_image_rgb(src).convert('RGB').crop(crop) + img = Image.open(src).crop(crop) img.save(path) else: - img = open_image_rgb(path) + img = Image.open(path) src = path if size < max(img.size): - path = os.path.join(folder, '%sp%s.%s' % (size, ','.join(map(str, crop)), ext)) + path = os.path.join(folder, '%sp%s.jpg' % (size, ','.join(map(str, crop)))) if not os.path.exists(path): resize_image(src, path, size=size) if os.path.exists(src) and not os.path.exists(path): image_size = max(self.width, self.height) if image_size == -1: - image_size = max(*open_image_rgb(src).size) + image_size = max(*Image.open(src).size) if size > image_size: path = src else: @@ -636,11 +586,6 @@ class Document(models.Model, FulltextMixin): image = os.path.join(os.path.dirname(pdf), '1024p%d.jpg' % page) utils.extract_pdfpage(pdf, image, page) - def create_pages(self): - for page in range(self.pages): - page += 1 - p, c = Page.objects.get_or_create(document=self, page=page) - def get_info(self): if self.extension == 'pdf': self.thumbnail(1024) @@ -648,28 +593,12 @@ class Document(models.Model, FulltextMixin): self.width = -1 self.height = -1 self.pages = utils.pdfpages(self.file.path) - elif self.extension in ('cbr', 'cbz'): - from . import cbr - thumb = self.thumbnail(1024) - if thumb: - self.width, self.height = open_image_rgb(thumb).size - self.pages = cbr.get_pages(self.file.path) - elif self.extension == 'epub': - thumb = self.thumbnail(1024) - if thumb: - self.width, self.height = open_image_rgb(thumb).size - self.pages = 1 - elif self.extension == 'txt': - thumb = self.thumbnail(1024) - if thumb: - self.width, self.height = open_image_rgb(thumb).size - self.pages = 1 elif self.width == -1: self.pages = -1 - self.width, self.height = open_image_rgb(self.file.path).size + self.width, self.height = Image.open(self.file.path).size def get_ratio(self): - if self.extension in ('pdf', 'epub', 'txt'): + if self.extension == 'pdf': image = self.thumbnail(1024) try: size = Image.open(image).size @@ -773,41 +702,6 @@ class ItemProperties(models.Model): super(ItemProperties, self).save(*args, **kwargs) -class Page(models.Model, FulltextPageMixin): - - created = models.DateTimeField(auto_now_add=True) - modified = models.DateTimeField(auto_now=True) - - document = models.ForeignKey(Document, related_name='pages_set', on_delete=models.CASCADE) - page = models.IntegerField(default=1) - data = JSONField(default=dict, editable=False) - - objects = managers.PageManager() - - def __str__(self): - return u"%s:%s" % (self.document, self.page) - - def json(self, keys=None, user=None): - data = {} - data['document'] = ox.toAZ(self.document.id) - data['page'] = self.page - data['id'] = '{document}/{page}'.format(**data) - document_keys = [] - if keys: - for key in list(data): - if key not in keys: - del data[key] - for key in keys: - if 'fulltext' in key: - data['fulltext'] = self.extract_fulltext() - elif key in ('document', 'page', 'id'): - pass - else: - document_keys.append(key) - if document_keys: - data.update(self.document.json(document_keys, user)) - return data - class Access(models.Model): class Meta: unique_together = ("document", "user") diff --git a/pandora/document/page_views.py b/pandora/document/page_views.py deleted file mode 100644 index d0ae7c0b..00000000 --- a/pandora/document/page_views.py +++ /dev/null @@ -1,135 +0,0 @@ -# -*- coding: utf-8 -*- - -import os -import re -from glob import glob -import unicodedata - -import ox -from ox.utils import json -from oxdjango.api import actions -from oxdjango.decorators import login_required_json -from oxdjango.http import HttpFileResponse -from oxdjango.shortcuts import render_to_json_response, get_object_or_404_json, json_response, HttpErrorJson -from django import forms -from django.db.models import Count, Sum -from django.conf import settings - -from item import utils -from item.models import Item -from itemlist.models import List -from entity.models import Entity -from archive.chunk import process_chunk -from changelog.models import add_changelog - -from . import models -from . import tasks - -def parse_query(data, user): - query = {} - query['range'] = [0, 100] - query['sort'] = [{'key': 'page', 'operator': '+'}, {'key': 'title', 'operator': '+'}] - for key in ('keys', 'group', 'file', 'range', 'position', 'positions', 'sort'): - if key in data: - query[key] = data[key] - query['qs'] = models.Page.objects.find(data, user) - return query - -def _order_query(qs, sort): - prefix = 'document__sort__' - order_by = [] - for e in sort: - operator = e['operator'] - if operator != '-': - operator = '' - key = { - 'index': 'document__items__itemproperties__index', - 'position': 'id', - 'name': 'title', - }.get(e['key'], e['key']) - if key == 'resolution': - order_by.append('%swidth' % operator) - order_by.append('%sheight' % operator) - else: - if '__' not in key and key not in ('created', 'modified', 'page'): - key = "%s%s" % (prefix, key) - order = '%s%s' % (operator, key) - order_by.append(order) - if order_by: - qs = qs.order_by(*order_by, nulls_last=True) - qs = qs.distinct() - return qs - -def _order_by_group(query): - prefix = 'document__sort__' - if 'sort' in query: - op = '-' if query['sort'][0]['operator'] == '-' else '' - if len(query['sort']) == 1 and query['sort'][0]['key'] == 'items': - order_by = op + prefix + 'items' - if query['group'] == "year": - secondary = op + prefix + 'sortvalue' - order_by = (order_by, secondary) - elif query['group'] != "keyword": - order_by = (order_by, prefix + 'sortvalue') - else: - order_by = (order_by, 'value') - else: - order_by = op + prefix + 'sortvalue' - order_by = (order_by, prefix + 'items') - else: - order_by = ('-' + prefix + 'sortvalue', prefix + 'items') - return order_by - -def findPages(request, data): - ''' - Finds documents pages for a given query - takes { - query: object, // query object, see `find` - sort: [object], // list of sort objects, see `find` - range: [int, int], // range of results, per current sort order - keys: [string] // list of keys to return - } - returns { - items: [{ // list of pages - id: string - page: int - }] - } - ''' - query = parse_query(data, request.user) - #order - qs = _order_query(query['qs'], query['sort']) - - response = json_response() - if 'group' in query: - response['data']['items'] = [] - items = 'items' - document_qs = query['qs'] - order_by = _order_by_group(query) - qs = models.Facet.objects.filter(key=query['group']).filter(document__id__in=document_qs) - qs = qs.values('value').annotate(items=Count('id')).order_by(*order_by) - - if 'positions' in query: - response['data']['positions'] = {} - ids = [j['value'] for j in qs] - response['data']['positions'] = utils.get_positions(ids, query['positions']) - elif 'range' in data: - qs = qs[query['range'][0]:query['range'][1]] - response['data']['items'] = [{'name': i['value'], 'items': i[items]} for i in qs] - else: - response['data']['items'] = qs.count() - elif 'keys' in data: - qs = qs[query['range'][0]:query['range'][1]] - - response['data']['items'] = [l.json(data['keys'], request.user) for l in qs] - elif 'position' in data: - #FIXME: actually implement position requests - response['data']['position'] = 0 - elif 'positions' in data: - ids = list(qs.values_list('id', flat=True)) - response['data']['positions'] = utils.get_positions(ids, query['positions'], decode_id=True) - else: - response['data']['items'] = qs.count() - return render_to_json_response(response) -actions.register(findPages) - diff --git a/pandora/document/tasks.py b/pandora/document/tasks.py index fcfb5576..7bede1a9 100644 --- a/pandora/document/tasks.py +++ b/pandora/document/tasks.py @@ -1,26 +1,21 @@ import ox -from app.celery import app +from celery.task import task -@app.task(queue="encoding") +@task(queue="encoding") def extract_fulltext(id): from . import models d = models.Document.objects.get(id=id) d.update_fulltext() - d.create_pages() - for page in d.pages_set.all(): - page.update_fulltext() -@app.task(queue='default') +@task(queue='default') def bulk_edit(data, username): from django.db import transaction from . import models from item.models import Item user = models.User.objects.get(username=username) item = 'item' in data and Item.objects.get(public_id=data['item']) or None - ids = data['id'] - del data['id'] - documents = models.Document.objects.filter(pk__in=map(ox.fromAZ, ids)) + documents = models.Document.objects.filter(pk__in=map(ox.fromAZ, data['id'])) for document in documents: if document.editable(user, item): with transaction.atomic(): diff --git a/pandora/document/txt.py b/pandora/document/txt.py deleted file mode 100755 index 6189b9ac..00000000 --- a/pandora/document/txt.py +++ /dev/null @@ -1,71 +0,0 @@ -import os - -from PIL import Image -from argparse import ArgumentParser -from ox.image import drawText, wrapText - -from django.conf import settings - - -def decode_line(line): - try: - line = line.decode('utf-8') - except: - try: - line = line.decode('latin-1') - except: - line = line.decode('utf-8', errors='replace') - return line - -def render(infile, outfile): - - with open(infile, 'rb') as f: - - image_size = (768, 1024) - margin = 64 - offset = margin - font_file = settings.TXT_TTF - font_size = 24 - line_height = 32 - max_lines = (image_size[1] - 2 * margin) / line_height - - image = Image.new('L', image_size, (255)) - - for line in f: - line = decode_line(line) - - for line_ in line.strip().split('\r'): - - lines = wrapText( - line_, - image_size[0] - 2 * margin, - # we don't want the last line that ends with an ellipsis - max_lines + 1, - font_file, - font_size - ) - - for line__ in lines: - drawText( - image, - (margin, offset), - line__, - font_file, - font_size, - (0) - ) - offset += line_height - max_lines -= 1 - - if max_lines == 0: - break - - if max_lines == 0: - break - - if max_lines == 0: - break - - image.save(outfile, quality=50) - - diff --git a/pandora/document/views.py b/pandora/document/views.py index 843518ed..5fc47466 100644 --- a/pandora/document/views.py +++ b/pandora/document/views.py @@ -1,11 +1,9 @@ # -*- coding: utf-8 -*- -from glob import glob -import mimetypes import os import re +from glob import glob import unicodedata -import zipfile import ox from ox.utils import json @@ -14,10 +12,8 @@ from oxdjango.decorators import login_required_json from oxdjango.http import HttpFileResponse from oxdjango.shortcuts import render_to_json_response, get_object_or_404_json, json_response, HttpErrorJson from django import forms -from django.conf import settings from django.db.models import Count, Sum -from django.http import HttpResponse, Http404 -from django.shortcuts import render +from django.conf import settings from item import utils from item.models import Item @@ -28,7 +24,6 @@ from changelog.models import add_changelog from . import models from . import tasks -from . import page_views def get_document_or_404_json(request, id): response = {'status': {'code': 404, @@ -380,25 +375,12 @@ actions.register(sortDocuments, cache=False) def file(request, id, name=None): document = get_document_or_404_json(request, id) - accept = request.headers.get("Accept") - mime_type = mimetypes.guess_type(document.file.path)[0] - mime_type = 'image/%s' % document.extension - if accept and 'image/' in accept and document.extension in ( - 'webp', 'heif', 'heic', 'avif', 'tiff', - ) and mime_type not in accept: - image_size = max(document.width, document.height) - return HttpFileResponse(document.thumbnail(image_size, accept=accept)) return HttpFileResponse(document.file.path) def thumbnail(request, id, size=256, page=None): size = int(size) document = get_document_or_404_json(request, id) - accept = request.headers.get("Accept") - if "q" in request.GET and page: - img = document.highlight_page(page, request.GET["q"], size) - return HttpResponse(img, content_type="image/jpeg") - return HttpFileResponse(document.thumbnail(size, page=page, accept=accept)) - + return HttpFileResponse(document.thumbnail(size, page=page)) @login_required_json def upload(request): @@ -524,58 +506,3 @@ def autocompleteDocuments(request, data): response['data']['items'] = [i['value'] for i in qs] return render_to_json_response(response) actions.register(autocompleteDocuments) - - -def document(request, fragment): - context = {} - parts = fragment.split('/') - # FIXME: parse collection urls and return the right metadata for those - id = parts[0] - page = None - crop = None - if len(parts) == 2: - rect = parts[1].split(',') - if len(rect) == 1: - page = rect[0] - else: - crop = rect - try: - document = models.Document.objects.filter(id=ox.fromAZ(id)).first() - except: - document = None - if document and document.access(request.user): - context['title'] = document.data['title'] - if document.data.get('description'): - context['description'] = document.data['description'] - link = request.build_absolute_uri(document.get_absolute_url()) - public_id = ox.toAZ(document.id) - preview = '/documents/%s/512p.jpg' % public_id - if page: - preview = '/documents/%s/512p%s.jpg' % (public_id, page) - if crop: - preview = '/documents/%s/512p%s.jpg' % (public_id, ','.join(crop)) - context['preview'] = request.build_absolute_uri(preview) - context['url'] = request.build_absolute_uri('/documents/' + fragment) - context['settings'] = settings - return render(request, "document.html", context) - -def epub(request, id, filename): - document = get_document_or_404_json(request, id) - if not document.access(request.user): - raise Http404 - if document.extension != 'epub': - raise Http404 - z = zipfile.ZipFile(document.file.path) - if filename == '': - context = {} - context["epub"] = document - return render(request, "epub.html", context) - elif filename not in [f.filename for f in z.filelist]: - raise Http404 - else: - content_type = { - 'xpgt': 'application/vnd.adobe-page-template+xml' - }.get(filename.split('.')[0], mimetypes.guess_type(filename)[0]) or 'text/plain' - content = z.read(filename) - response = HttpResponse(content, content_type=content_type) - return response diff --git a/pandora/documentcollection/apps.py b/pandora/documentcollection/apps.py deleted file mode 100644 index 10e2984f..00000000 --- a/pandora/documentcollection/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class DocumentcollectionConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'documentcollection' - diff --git a/pandora/documentcollection/migrations/0005_alter_collection_description_alter_collection_id_and_more.py b/pandora/documentcollection/migrations/0005_alter_collection_description_alter_collection_id_and_more.py deleted file mode 100644 index 72155308..00000000 --- a/pandora/documentcollection/migrations/0005_alter_collection_description_alter_collection_id_and_more.py +++ /dev/null @@ -1,61 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -import django.core.serializers.json -from django.db import migrations, models -import documentcollection.models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('documentcollection', '0004_jsonfield'), - ] - - operations = [ - migrations.AlterField( - model_name='collection', - name='description', - field=models.TextField(default=''), - ), - migrations.AlterField( - model_name='collection', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='collection', - name='poster_frames', - field=oxdjango.fields.JSONField(default=list, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='collection', - name='query', - field=oxdjango.fields.JSONField(default=documentcollection.models.default_query, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='collection', - name='sort', - field=oxdjango.fields.JSONField(default=documentcollection.models.get_collectionsort, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='collection', - name='status', - field=models.CharField(default='private', max_length=20), - ), - migrations.AlterField( - model_name='collection', - name='type', - field=models.CharField(default='static', max_length=255), - ), - migrations.AlterField( - model_name='collectiondocument', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='position', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/documentcollection/models.py b/pandora/documentcollection/models.py index 7c471ce2..8504ae47 100644 --- a/pandora/documentcollection/models.py +++ b/pandora/documentcollection/models.py @@ -34,9 +34,6 @@ def get_collectionview(): def get_collectionsort(): return tuple(settings.CONFIG['user']['ui']['collectionSort']) -def default_query(): - return {"static": True} - class Collection(models.Model): class Meta: @@ -49,7 +46,7 @@ class Collection(models.Model): name = models.CharField(max_length=255) status = models.CharField(max_length=20, default='private') _status = ['private', 'public', 'featured'] - query = JSONField(default=default_query, editable=False) + query = JSONField(default=lambda: {"static": True}, editable=False) type = models.CharField(max_length=255, default='static') description = models.TextField(default='') @@ -188,7 +185,7 @@ class Collection(models.Model): self.status = value elif key == 'name': - data['name'] = re.sub(r' \[\d+\]$', '', data['name']).strip() + data['name'] = re.sub(' \[\d+\]$', '', data['name']).strip() if not data['name']: data['name'] = "Untitled" name = data['name'] diff --git a/pandora/documentcollection/views.py b/pandora/documentcollection/views.py index a678bd17..66fa746d 100644 --- a/pandora/documentcollection/views.py +++ b/pandora/documentcollection/views.py @@ -86,11 +86,6 @@ def findCollections(request, data): for x in data.get('query', {}).get('conditions', []) ) - is_personal = request.user.is_authenticated and any( - (x['key'] == 'user' and x['value'] == request.user.username and x['operator'] == '==') - for x in data.get('query', {}).get('conditions', []) - ) - if is_section_request: qs = query['qs'] if not is_featured and not request.user.is_anonymous: @@ -99,9 +94,6 @@ def findCollections(request, data): else: qs = _order_query(query['qs'], query['sort']) - if is_personal and request.user.profile.ui.get('hidden', {}).get('collections'): - qs = qs.exclude(name__in=request.user.profile.ui['hidden']['collections']) - response = json_response() if 'keys' in data: qs = qs[query['range'][0]:query['range'][1]] @@ -246,7 +238,7 @@ def addCollection(request, data): 'type' and 'view'. see: editCollection, findCollections, getCollection, removeCollection, sortCollections ''' - data['name'] = re.sub(r' \[\d+\]$', '', data.get('name', 'Untitled')).strip() + data['name'] = re.sub(' \[\d+\]$', '', data.get('name', 'Untitled')).strip() name = data['name'] if not name: name = "Untitled" diff --git a/pandora/edit/apps.py b/pandora/edit/apps.py deleted file mode 100644 index 56f70942..00000000 --- a/pandora/edit/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class EditConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'edit' - diff --git a/pandora/edit/migrations/0006_id_bigint_jsonfield.py b/pandora/edit/migrations/0006_id_bigint_jsonfield.py deleted file mode 100644 index a2e58e5c..00000000 --- a/pandora/edit/migrations/0006_id_bigint_jsonfield.py +++ /dev/null @@ -1,41 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -import django.core.serializers.json -from django.db import migrations, models -import edit.models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('edit', '0005_jsonfield'), - ] - - operations = [ - migrations.AlterField( - model_name='clip', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='edit', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='edit', - name='poster_frames', - field=oxdjango.fields.JSONField(default=list, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='edit', - name='query', - field=oxdjango.fields.JSONField(default=edit.models.default_query, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='position', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/edit/models.py b/pandora/edit/models.py index 1ab58541..d71525a0 100644 --- a/pandora/edit/models.py +++ b/pandora/edit/models.py @@ -13,7 +13,6 @@ from django.conf import settings from django.db import models, transaction from django.db.models import Max from django.contrib.auth import get_user_model -from django.core.cache import cache from oxdjango.fields import JSONField @@ -25,7 +24,6 @@ import clip.models from archive import extract from user.utils import update_groups from user.models import Group -from clip.utils import add_cuts from . import managers @@ -35,9 +33,6 @@ User = get_user_model() def get_path(f, x): return f.path(x) def get_icon_path(f, x): return get_path(f, 'icon.jpg') -def default_query(): - return {"static": True} - class Edit(models.Model): class Meta: @@ -56,7 +51,7 @@ class Edit(models.Model): description = models.TextField(default='') rightslevel = models.IntegerField(db_index=True, default=0) - query = JSONField(default=default_query, editable=False) + query = JSONField(default=lambda: {"static": True}, editable=False) type = models.CharField(max_length=255, default='static') icon = models.ImageField(default=None, blank=True, null=True, upload_to=get_icon_path) @@ -98,8 +93,6 @@ class Edit(models.Model): # dont add clip if in/out are invalid if not c.annotation: duration = c.item.sort.duration - if c.start is None or c.end is None: - return False if c.start > c.end \ or round(c.start, 3) >= round(duration, 3) \ or round(c.end, 3) > round(duration, 3): @@ -196,7 +189,7 @@ class Edit(models.Model): self.status = value elif key == 'name': - data['name'] = re.sub(r' \[\d+\]$', '', data['name']).strip() + data['name'] = re.sub(' \[\d+\]$', '', data['name']).strip() if not data['name']: data['name'] = "Untitled" name = data['name'] @@ -495,9 +488,6 @@ class Clip(models.Model): 'id': self.get_id(), 'index': self.index, 'volume': self.volume, - 'hue': self.hue, - 'saturation': self.saturation, - 'lightness': self.lightness, } if self.annotation: data['annotation'] = self.annotation.public_id @@ -517,7 +507,7 @@ class Clip(models.Model): if value: data[key] = value data['duration'] = data['out'] - data['in'] - add_cuts(data, self.item, self.start, self.end) + data['cuts'] = tuple([c for c in self.item.get('cuts', []) if c > self.start and c < self.end]) data['layers'] = self.get_layers(user) data['streams'] = [s.file.oshash for s in self.item.streams()] return data diff --git a/pandora/edit/views.py b/pandora/edit/views.py index c096b464..09261310 100644 --- a/pandora/edit/views.py +++ b/pandora/edit/views.py @@ -3,16 +3,14 @@ import os import re -from oxdjango.api import actions -from oxdjango.decorators import login_required_json -from oxdjango.http import HttpFileResponse -from oxdjango.shortcuts import render_to_json_response, get_object_or_404_json, json_response import ox - -from django.conf import settings +from oxdjango.decorators import login_required_json +from oxdjango.shortcuts import render_to_json_response, get_object_or_404_json, json_response from django.db import transaction from django.db.models import Max -from django.db.models import Sum +from oxdjango.http import HttpFileResponse +from oxdjango.api import actions +from django.conf import settings from item import utils from changelog.models import add_changelog @@ -192,7 +190,7 @@ def _order_clips(edit, sort): 'in': 'start', 'out': 'end', 'text': 'sortvalue', - 'volume': 'volume' if edit.type == 'smart' else 'sortvolume', + 'volume': 'sortvolume', 'item__sort__item': 'item__sort__public_id', }.get(key, key) order = '%s%s' % (operator, key) @@ -262,7 +260,7 @@ def addEdit(request, data): } see: editEdit, findEdit, getEdit, removeEdit, sortEdits ''' - data['name'] = re.sub(r' \[\d+\]$', '', data.get('name', 'Untitled')).strip() + data['name'] = re.sub(' \[\d+\]$', '', data.get('name', 'Untitled')).strip() name = data['name'] if not name: name = "Untitled" @@ -414,11 +412,6 @@ def findEdits(request, data): is_featured = any(filter(is_featured_condition, data.get('query', {}).get('conditions', []))) - is_personal = request.user.is_authenticated and any( - (x['key'] == 'user' and x['value'] == request.user.username and x['operator'] == '==') - for x in data.get('query', {}).get('conditions', []) - ) - if is_section_request: qs = query['qs'] if not is_featured and not request.user.is_anonymous: @@ -427,9 +420,6 @@ def findEdits(request, data): else: qs = _order_query(query['qs'], query['sort']) - if is_personal and request.user.profile.ui.get('hidden', {}).get('edits'): - qs = qs.exclude(name__in=request.user.profile.ui['hidden']['edits']) - response = json_response() if 'keys' in data: qs = qs[query['range'][0]:query['range'][1]] diff --git a/pandora/encoding.conf.in b/pandora/encoding.conf.in deleted file mode 100644 index af15426c..00000000 --- a/pandora/encoding.conf.in +++ /dev/null @@ -1,3 +0,0 @@ -LOGLEVEL=info -MAX_TASKS_PER_CHILD=500 -CONCURRENCY=1 diff --git a/pandora/entity/apps.py b/pandora/entity/apps.py deleted file mode 100644 index 621c7135..00000000 --- a/pandora/entity/apps.py +++ /dev/null @@ -1,6 +0,0 @@ -from django.apps import AppConfig - - -class EntityConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'entity' diff --git a/pandora/entity/migrations/0007_alter_documentproperties_data_and_more.py b/pandora/entity/migrations/0007_alter_documentproperties_data_and_more.py deleted file mode 100644 index 83d9c0bd..00000000 --- a/pandora/entity/migrations/0007_alter_documentproperties_data_and_more.py +++ /dev/null @@ -1,50 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -import django.core.serializers.json -from django.db import migrations, models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('entity', '0006_auto_20180918_0903'), - ] - - operations = [ - migrations.AlterField( - model_name='documentproperties', - name='data', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='documentproperties', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='entity', - name='data', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='entity', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='entity', - name='name_find', - field=models.TextField(default=''), - ), - migrations.AlterField( - model_name='find', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='link', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/entity/models.py b/pandora/entity/models.py index d43444de..e97a6963 100644 --- a/pandora/entity/models.py +++ b/pandora/entity/models.py @@ -131,7 +131,7 @@ class Entity(models.Model): config_keys = {k['id']: k for k in entity['keys']} for key, value in data.items(): if key == 'name': - data['name'] = re.sub(r' \[\d+\]$', '', data['name']).strip() + data['name'] = re.sub(' \[\d+\]$', '', data['name']).strip() if not data['name']: data['name'] = "Unnamed" name = data['name'] @@ -147,7 +147,7 @@ class Entity(models.Model): names = [] for v in data[key]: name = ox.decode_html(v) - name = re.sub(r' \[\d+\]$', '', name).strip() + name = re.sub(' \[\d+\]$', '', name).strip() name_ = name n = 1 while name in used_names or \ diff --git a/pandora/event/apps.py b/pandora/event/apps.py deleted file mode 100644 index ff9d6ab7..00000000 --- a/pandora/event/apps.py +++ /dev/null @@ -1,6 +0,0 @@ -from django.apps import AppConfig - - -class EventConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'event' diff --git a/pandora/event/migrations/0004_alter_event_duration_alter_event_end_alter_event_id_and_more.py b/pandora/event/migrations/0004_alter_event_duration_alter_event_end_alter_event_id_and_more.py deleted file mode 100644 index 7d422113..00000000 --- a/pandora/event/migrations/0004_alter_event_duration_alter_event_end_alter_event_id_and_more.py +++ /dev/null @@ -1,43 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('event', '0003_auto_20160304_1644'), - ] - - operations = [ - migrations.AlterField( - model_name='event', - name='duration', - field=models.CharField(default='', max_length=255), - ), - migrations.AlterField( - model_name='event', - name='end', - field=models.CharField(default='', max_length=255), - ), - migrations.AlterField( - model_name='event', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='event', - name='name_find', - field=models.TextField(default=''), - ), - migrations.AlterField( - model_name='event', - name='start', - field=models.CharField(default='', max_length=255), - ), - migrations.AlterField( - model_name='event', - name='type', - field=models.CharField(default='', max_length=255), - ), - ] diff --git a/pandora/event/tasks.py b/pandora/event/tasks.py index 46acdda2..234dd5a7 100644 --- a/pandora/event/tasks.py +++ b/pandora/event/tasks.py @@ -1,26 +1,20 @@ # -*- coding: utf-8 -*- -from app.celery import app +from celery.task import task from .models import Event ''' -from celery.schedules import crontab - -@app.task(ignore_results=True, queue='encoding') +@periodic_task(run_every=crontab(hour=7, minute=30), queue='encoding') def update_all_matches(**kwargs): ids = [e['id'] for e in Event.objects.all().values('id')] for i in ids: e = Event.objects.get(pk=i) e.update_matches() - -@app.on_after_finalize.connect -def setup_periodic_tasks(sender, **kwargs): - sender.add_periodic_task(crontab(hour=7, minute=30), update_all_matches.s()) ''' -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_matches(eventId): event = Event.objects.get(pk=eventId) event.update_matches() diff --git a/pandora/home/apps.py b/pandora/home/apps.py index 8bb98271..90dc7137 100644 --- a/pandora/home/apps.py +++ b/pandora/home/apps.py @@ -2,5 +2,4 @@ from django.apps import AppConfig class HomeConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" name = 'home' diff --git a/pandora/home/migrations/0003_alter_item_data_alter_item_id_alter_item_index.py b/pandora/home/migrations/0003_alter_item_data_alter_item_id_alter_item_index.py deleted file mode 100644 index 84328309..00000000 --- a/pandora/home/migrations/0003_alter_item_data_alter_item_id_alter_item_index.py +++ /dev/null @@ -1,30 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -import django.core.serializers.json -from django.db import migrations, models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('home', '0002_jsonfield'), - ] - - operations = [ - migrations.AlterField( - model_name='item', - name='data', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='item', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='item', - name='index', - field=models.IntegerField(default=-1), - ), - ] diff --git a/pandora/item/apps.py b/pandora/item/apps.py deleted file mode 100644 index 5c6b394d..00000000 --- a/pandora/item/apps.py +++ /dev/null @@ -1,6 +0,0 @@ -from django.apps import AppConfig - - -class ItemConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'item' diff --git a/pandora/item/managers.py b/pandora/item/managers.py index f7398a0e..654f1dfe 100644 --- a/pandora/item/managers.py +++ b/pandora/item/managers.py @@ -33,7 +33,7 @@ def parseCondition(condition, user, owner=None): k = {'id': 'public_id'}.get(k, k) if not k: k = '*' - v = condition.get('value', '') + v = condition['value'] op = condition.get('operator') if not op: op = '=' @@ -62,9 +62,6 @@ def parseCondition(condition, user, owner=None): if k == 'list': key_type = '' - if k in ('width', 'height'): - key_type = 'integer' - if k == 'groups': if op == '==' and v == '$my': if not owner: @@ -89,11 +86,8 @@ def parseCondition(condition, user, owner=None): elif k == 'rendered': return Q(rendered=v) elif k == 'resolution': - if isinstance(v, list) and len(v) == 2: - q = parseCondition({'key': 'width', 'value': v[0], 'operator': op}, user) \ - & parseCondition({'key': 'height', 'value': v[1], 'operator': op}, user) - else: - q = Q(id=0) + q = parseCondition({'key': 'width', 'value': v[0], 'operator': op}, user) \ + & parseCondition({'key': 'height', 'value': v[1], 'operator': op}, user) if exclude: q = ~q return q @@ -324,8 +318,6 @@ class ItemManager(Manager): q |= Q(groups__in=user.groups.all()) rendered_q |= Q(groups__in=user.groups.all()) qs = qs.filter(q) - max_level = len(settings.CONFIG['rightsLevels']) - qs = qs.filter(level__lte=max_level) if settings.CONFIG.get('itemRequiresVideo') and level != 'admin': qs = qs.filter(rendered_q) return qs diff --git a/pandora/item/migrations/0001_initial.py b/pandora/item/migrations/0001_initial.py index a92c0e66..ef095583 100644 --- a/pandora/item/migrations/0001_initial.py +++ b/pandora/item/migrations/0001_initial.py @@ -71,7 +71,7 @@ class Migration(migrations.Migration): ('poster_width', models.IntegerField(default=0)), ('poster_frame', models.FloatField(default=-1)), ('icon', models.ImageField(blank=True, default=None, upload_to=item.models.get_icon_path)), - ('torrent', models.FileField(blank=True, default=None, max_length=1000)), + ('torrent', models.FileField(blank=True, default=None, max_length=1000, upload_to=item.models.get_torrent_path)), ('stream_info', oxdjango.fields.DictField(default={}, editable=False)), ('stream_aspect', models.FloatField(default=1.3333333333333333)), ], diff --git a/pandora/item/migrations/0005_auto_20230710_0852.py b/pandora/item/migrations/0005_auto_20230710_0852.py deleted file mode 100644 index 156ef526..00000000 --- a/pandora/item/migrations/0005_auto_20230710_0852.py +++ /dev/null @@ -1,19 +0,0 @@ -# Generated by Django 3.0.10 on 2023-07-10 08:52 - -import django.core.serializers.json -from django.db import migrations, models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('item', '0004_json_cache'), - ] - - operations = [ - migrations.RemoveField( - model_name='item', - name='torrent', - ), - ] diff --git a/pandora/item/migrations/0006_id_bigint_jsonfied_and_more.py b/pandora/item/migrations/0006_id_bigint_jsonfied_and_more.py deleted file mode 100644 index dd85858e..00000000 --- a/pandora/item/migrations/0006_id_bigint_jsonfied_and_more.py +++ /dev/null @@ -1,65 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -import django.core.serializers.json -from django.db import migrations, models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('item', '0005_auto_20230710_0852'), - ] - - operations = [ - migrations.AlterField( - model_name='access', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='annotationsequence', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='description', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='facet', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='item', - name='cache', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='item', - name='data', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='item', - name='external_data', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='item', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='item', - name='stream_info', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='itemfind', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/item/models.py b/pandora/item/models.py index 138b4fcd..5172990c 100644 --- a/pandora/item/models.py +++ b/pandora/item/models.py @@ -1,7 +1,6 @@ # -*- coding: utf-8 -*- import json -import logging import os import re import shutil @@ -43,7 +42,6 @@ from user.utils import update_groups from user.models import Group import archive.models -logger = logging.getLogger('pandora.' + __name__) User = get_user_model() @@ -157,6 +155,9 @@ def get_icon_path(f, x): def get_poster_path(f, x): return get_path(f, 'poster.jpg') +def get_torrent_path(f, x): + return get_path(f, 'torrent.torrent') + class Item(models.Model): created = models.DateTimeField(auto_now_add=True) modified = models.DateTimeField(auto_now=True) @@ -182,6 +183,7 @@ class Item(models.Model): icon = models.ImageField(default=None, blank=True, upload_to=get_icon_path) + torrent = models.FileField(default=None, blank=True, max_length=1000, upload_to=get_torrent_path) stream_info = JSONField(default=dict, editable=False) # stream related fields @@ -229,9 +231,6 @@ class Item(models.Model): def editable(self, user): if user.is_anonymous: return False - max_level = len(settings.CONFIG['rightsLevels']) - if self.level > max_level: - return False if user.profile.capability('canEditMetadata') or \ user.is_staff or \ self.user == user or \ @@ -239,7 +238,7 @@ class Item(models.Model): return True return False - def edit(self, data, is_task=False): + def edit(self, data): data = data.copy() # FIXME: how to map the keys to the right place to write them to? if 'id' in data: @@ -256,12 +255,11 @@ class Item(models.Model): description = data.pop(key) if isinstance(description, dict): for value in description: - value = ox.sanitize_html(value) d, created = Description.objects.get_or_create(key=k, value=value) d.description = ox.sanitize_html(description[value]) d.save() else: - value = ox.sanitize_html(data.get(k, self.get(k, ''))) + value = data.get(k, self.get(k, '')) if not description: description = '' d, created = Description.objects.get_or_create(key=k, value=value) @@ -296,10 +294,7 @@ class Item(models.Model): self.data[key] = ox.escape_html(data[key]) p = self.save() if not settings.USE_IMDB and list(filter(lambda k: k in self.poster_keys, data)): - if is_task: - tasks.update_poster(self.public_id) - else: - p = tasks.update_poster.delay(self.public_id) + p = tasks.update_poster.delay(self.public_id) return p def update_external(self): @@ -478,8 +473,7 @@ class Item(models.Model): for a in self.annotations.all().order_by('id'): a.item = other - with transaction.atomic(): - a.set_public_id() + a.set_public_id() Annotation.objects.filter(id=a.id).update(item=other, public_id=a.public_id) try: other_sort = other.sort @@ -523,7 +517,6 @@ class Item(models.Model): cmd, stdout=open('/dev/null', 'w'), stderr=open('/dev/null', 'w'), close_fds=True) p.wait() os.unlink(tmp_output_txt) - os.close(fd) return True else: return None @@ -641,11 +634,11 @@ class Item(models.Model): if self.poster_height: i['posterRatio'] = self.poster_width / self.poster_height - if keys and 'hasSource' in keys: - i['hasSource'] = self.streams().exclude(file__data='').exists() + if keys and 'source' in keys: + i['source'] = self.streams().exclude(file__data='').exists() streams = self.streams() - i['durations'] = [s[0] for s in streams.values_list('duration')] + i['durations'] = [s.duration for s in streams] i['duration'] = sum(i['durations']) i['audioTracks'] = self.audio_tracks() if not i['audioTracks']: @@ -701,12 +694,10 @@ class Item(models.Model): else: values = self.get(key) if values: - values = [ox.sanitize_html(value) for value in values] for d in Description.objects.filter(key=key, value__in=values): i['%sdescription' % key][d.value] = d.description else: - value = ox.sanitize_html(self.get(key, '')) - qs = Description.objects.filter(key=key, value=value) + qs = Description.objects.filter(key=key, value=self.get(key, '')) i['%sdescription' % key] = '' if qs.count() == 0 else qs[0].description if keys: info = {} @@ -864,7 +855,7 @@ class Item(models.Model): values = list(set(values)) else: values = self.get(key, '') - if values and isinstance(values, list) and isinstance(values[0], str): + if isinstance(values, list): save(key, '\n'.join(values)) else: save(key, values) @@ -1026,14 +1017,10 @@ class Item(models.Model): set_value(s, name, value) elif sort_type == 'person': value = sortNames(self.get(source, [])) - if value is None: - value = '' value = utils.sort_string(value)[:955] set_value(s, name, value) elif sort_type == 'string': value = self.get(source, '') - if value is None: - value = '' if isinstance(value, list): value = ','.join([str(v) for v in value]) value = utils.sort_string(value)[:955] @@ -1112,11 +1099,7 @@ class Item(models.Model): _current_values.append(value[0]) current_values = _current_values - try: - current_values = list(set(current_values)) - except: - logger.error('invalid facet data for %s: %s', key, current_values) - current_values = [] + current_values = list(set(current_values)) current_values = [ox.decode_html(ox.strip_tags(v)) for v in current_values] current_values = [unicodedata.normalize('NFKD', v) for v in current_values] self.update_facet_values(key, current_values) @@ -1209,7 +1192,7 @@ class Item(models.Model): if not r: return False path = video.name - duration = sum(self.item.cache['durations']) + duration = sum(item.cache['durations']) else: path = stream.media.path duration = stream.info['duration'] @@ -1305,6 +1288,90 @@ class Item(models.Model): self.files.filter(selected=True).update(selected=False) self.save() + def get_torrent(self, request): + if self.torrent: + self.torrent.seek(0) + data = ox.torrent.bdecode(self.torrent.read()) + url = request.build_absolute_uri("%s/torrent/" % self.get_absolute_url()) + if url.startswith('https://'): + url = 'http' + url[5:] + data['url-list'] = ['%s%s' % (url, u.split('torrent/')[1]) for u in data['url-list']] + return ox.torrent.bencode(data) + + def make_torrent(self): + if not settings.CONFIG['video'].get('torrent'): + return + streams = self.streams() + if streams.count() == 0: + return + base = self.path('torrent') + base = os.path.abspath(os.path.join(settings.MEDIA_ROOT, base)) + if not isinstance(base, bytes): + base = base.encode('utf-8') + if os.path.exists(base): + shutil.rmtree(base) + ox.makedirs(base) + + filename = utils.safe_filename(ox.decode_html(self.get('title'))) + base = self.path('torrent/%s' % filename) + base = os.path.abspath(os.path.join(settings.MEDIA_ROOT, base)) + size = 0 + duration = 0.0 + if streams.count() == 1: + v = streams[0] + media_path = v.media.path + extension = media_path.split('.')[-1] + url = "%s/torrent/%s.%s" % (self.get_absolute_url(), + quote(filename.encode('utf-8')), + extension) + video = "%s.%s" % (base, extension) + if not isinstance(media_path, bytes): + media_path = media_path.encode('utf-8') + if not isinstance(video, bytes): + video = video.encode('utf-8') + media_path = os.path.relpath(media_path, os.path.dirname(video)) + os.symlink(media_path, video) + size = v.media.size + duration = v.duration + else: + url = "%s/torrent/" % self.get_absolute_url() + part = 1 + ox.makedirs(base) + for v in streams: + media_path = v.media.path + extension = media_path.split('.')[-1] + video = "%s/%s.Part %d.%s" % (base, filename, part, extension) + part += 1 + if not isinstance(media_path, bytes): + media_path = media_path.encode('utf-8') + if not isinstance(video, bytes): + video = video.encode('utf-8') + media_path = os.path.relpath(media_path, os.path.dirname(video)) + os.symlink(media_path, video) + size += v.media.size + duration += v.duration + video = base + + torrent = '%s.torrent' % base + url = "http://%s%s" % (settings.CONFIG['site']['url'], url) + meta = { + 'filesystem_encoding': 'utf-8', + 'target': torrent, + 'url-list': url, + } + if duration: + meta['playtime'] = ox.format_duration(duration*1000)[:-4] + + # slightly bigger torrent file but better for streaming + piece_size_pow2 = 15 # 1 mbps -> 32KB pieces + if size / duration >= 1000000: + piece_size_pow2 = 16 # 2 mbps -> 64KB pieces + meta['piece_size_pow2'] = piece_size_pow2 + + ox.torrent.create_torrent(video, settings.TRACKER_URL, meta) + self.torrent.name = torrent[len(settings.MEDIA_ROOT)+1:] + self.save() + def audio_tracks(self): tracks = [f['language'] for f in self.files.filter(selected=True).filter(Q(is_video=True) | Q(is_audio=True)).values('language') @@ -1312,10 +1379,11 @@ class Item(models.Model): return sorted(set(tracks)) def streams(self, track=None): - files = self.files.filter(selected=True).filter(Q(is_audio=True) | Q(is_video=True)) qs = archive.models.Stream.objects.filter( - file__in=files, source=None, available=True - ).select_related() + source=None, available=True, file__item=self, file__selected=True + ).filter( + Q(file__is_audio=True) | Q(file__is_video=True) + ) if not track: tracks = self.audio_tracks() if len(tracks) > 1: @@ -1354,6 +1422,7 @@ class Item(models.Model): self.select_frame() self.make_poster() self.make_icon() + self.make_torrent() self.rendered = streams.count() > 0 self.save() if self.rendered: @@ -1375,7 +1444,7 @@ class Item(models.Model): self.poster_height = self.poster.height self.poster_width = self.poster.width self.clear_poster_cache(self.poster.path) - if self.poster_width and self.cache.get('posterRatio') != self.poster_width / self.poster_height: + if self.cache.get('posterRatio') != self.poster_width / self.poster_height: self.update_cache(poster_width=self.poster_width, poster_height=self.poster_height) @@ -1539,15 +1608,8 @@ class Item(models.Model): cmd += ['-l', timeline] if frame: cmd += ['-f', frame] - if settings.ITEM_ICON_DATA: - cmd += '-d', '-' - data = self.json() - data = utils.normalize_dict('NFC', data) - p = subprocess.Popen(cmd, stdin=subprocess.PIPE, close_fds=True) - p.communicate(json.dumps(data, default=to_json).encode('utf-8')) - else: - p = subprocess.Popen(cmd, close_fds=True) - p.wait() + p = subprocess.Popen(cmd, close_fds=True) + p.wait() # remove cached versions icon = os.path.abspath(os.path.join(settings.MEDIA_ROOT, icon)) for f in glob(icon.replace('.jpg', '*.jpg')): @@ -1559,13 +1621,11 @@ class Item(models.Model): return icon def add_empty_clips(self): - if not settings.EMPTY_CLIPS: - return subtitles = utils.get_by_key(settings.CONFIG['layers'], 'isSubtitles', True) if not subtitles: return # otherwise add empty 5 seconds annotation every minute - duration = sum([s[0] for s in self.streams().values_list('duration')]) + duration = sum([s.duration for s in self.streams()]) layer = subtitles['id'] # FIXME: allow annotations from no user instead? user = User.objects.all().order_by('id')[0] @@ -1814,8 +1874,6 @@ class Description(models.Model): value = models.CharField(max_length=1000, db_index=True) description = models.TextField() - def __str__(self): - return "%s=%s" % (self.key, self.value) class AnnotationSequence(models.Model): item = models.OneToOneField('Item', related_name='_annotation_sequence', on_delete=models.CASCADE) @@ -1831,12 +1889,13 @@ class AnnotationSequence(models.Model): @classmethod def nextid(cls, item): - s, created = cls.objects.get_or_create(item=item) - if created: - nextid = s.value - else: - cursor = connection.cursor() - sql = "UPDATE %s SET value = value + 1 WHERE item_id = %s RETURNING value" % (cls._meta.db_table, item.id) - cursor.execute(sql) - nextid = cursor.fetchone()[0] + with transaction.atomic(): + s, created = cls.objects.get_or_create(item=item) + if created: + nextid = s.value + else: + cursor = connection.cursor() + sql = "UPDATE %s SET value = value + 1 WHERE item_id = %s RETURNING value" % (cls._meta.db_table, item.id) + cursor.execute(sql) + nextid = cursor.fetchone()[0] return "%s/%s" % (item.public_id, ox.toAZ(nextid)) diff --git a/pandora/item/site.py b/pandora/item/site.py index a67871db..cb186eab 100644 --- a/pandora/item/site.py +++ b/pandora/item/site.py @@ -24,6 +24,10 @@ urls = [ re_path(r'^(?P[A-Z0-9].*)/(?P\d+)p(?P\d*)\.(?Pwebm|ogv|mp4)$', views.video), re_path(r'^(?P[A-Z0-9].*)/(?P\d+)p(?P\d*)\.(?P.+)\.(?Pwebm|ogv|mp4)$', views.video), + #torrent + re_path(r'^(?P[A-Z0-9].*)/torrent$', views.torrent), + re_path(r'^(?P[A-Z0-9].*)/torrent/(?P.*?)$', views.torrent), + #export re_path(r'^(?P[A-Z0-9].*)/json$', views.item_json), re_path(r'^(?P[A-Z0-9].*)/xml$', views.item_xml), diff --git a/pandora/item/tasks.py b/pandora/item/tasks.py index 92b3b08f..a7c0c68a 100644 --- a/pandora/item/tasks.py +++ b/pandora/item/tasks.py @@ -2,35 +2,31 @@ from datetime import timedelta, datetime from urllib.parse import quote -import xml.etree.ElementTree as ET import gzip import os import random import logging -from app.celery import app -from celery.schedules import crontab +from celery.task import task, periodic_task from django.conf import settings from django.db import connection, transaction from django.db.models import Q +from ox.utils import ET from app.utils import limit_rate from taskqueue.models import Task -logger = logging.getLogger('pandora.' + __name__) +logger = logging.getLogger(__name__) -@app.task(queue='encoding') + +@periodic_task(run_every=timedelta(days=1), queue='encoding') def cronjob(**kwargs): if limit_rate('item.tasks.cronjob', 8 * 60 * 60): update_random_sort() update_random_clip_sort() clear_cache.delay() -@app.on_after_finalize.connect -def setup_periodic_tasks(sender, **kwargs): - sender.add_periodic_task(timedelta(days=1), cronjob.s()) - def update_random_sort(): from . import models if list(filter(lambda f: f['id'] == 'random', settings.CONFIG['itemKeys'])): @@ -58,7 +54,7 @@ def update_random_clip_sort(): cursor.execute(row) -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_clips(public_id): from . import models try: @@ -67,7 +63,7 @@ def update_clips(public_id): return item.clips.all().update(user=item.user.id) -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_poster(public_id): from . import models try: @@ -85,7 +81,7 @@ def update_poster(public_id): icon=item.icon.name ) -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_file_paths(public_id): from . import models try: @@ -94,7 +90,7 @@ def update_file_paths(public_id): return item.update_file_paths() -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_external(public_id): from . import models try: @@ -103,7 +99,7 @@ def update_external(public_id): return item.update_external() -@app.task(queue="encoding") +@task(queue="encoding") def update_timeline(public_id): from . import models try: @@ -113,7 +109,7 @@ def update_timeline(public_id): item.update_timeline(async_=False) Task.finish(item) -@app.task(queue="encoding") +@task(queue="encoding") def rebuild_timeline(public_id): from . import models i = models.Item.objects.get(public_id=public_id) @@ -121,7 +117,7 @@ def rebuild_timeline(public_id): s.make_timeline() i.update_timeline(async_=False) -@app.task(queue="encoding") +@task(queue="encoding") def load_subtitles(public_id): from . import models try: @@ -134,7 +130,7 @@ def load_subtitles(public_id): item.update_facets() -@app.task(queue="encoding") +@task(queue="encoding") def extract_clip(public_id, in_, out, resolution, format, track=None): from . import models try: @@ -146,7 +142,7 @@ def extract_clip(public_id, in_, out, resolution, format, track=None): return False -@app.task(queue="encoding") +@task(queue="encoding") def clear_cache(days=60): import subprocess path = os.path.join(settings.MEDIA_ROOT, 'media') @@ -160,7 +156,7 @@ def clear_cache(days=60): subprocess.check_output(cmd) -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_sitemap(base_url): from . import models sitemap = os.path.abspath(os.path.join(settings.MEDIA_ROOT, 'sitemap.xml.gz')) @@ -360,7 +356,7 @@ def update_sitemap(base_url): f.write(data) -@app.task(queue='default') +@task(queue='default') def bulk_edit(data, username): from django.db import transaction from . import models @@ -371,5 +367,5 @@ def bulk_edit(data, username): if item.editable(user): with transaction.atomic(): item.refresh_from_db() - response = edit_item(user, item, data, is_task=True) + response = edit_item(user, item, data) return {} diff --git a/pandora/item/timelines.py b/pandora/item/timelines.py index a39ceee6..f6ff9f72 100644 --- a/pandora/item/timelines.py +++ b/pandora/item/timelines.py @@ -27,7 +27,7 @@ def join_tiles(source_paths, durations, target_path): def get_file_info(file_name): for mode in modes: - if re.match(r'^timeline' + mode + r'64p\d+\.jpg', file_name): + if re.match('^timeline' + mode + '64p\d+\.jpg', file_name): return { 'file': file_name, 'mode': mode, @@ -71,7 +71,7 @@ def join_tiles(source_paths, durations, target_path): if not w or large_tile_i < large_tile_n - 1: w = 60 data['target_images']['large'] = data['target_images']['large'].resize( - (w, small_tile_h), Image.LANCZOS + (w, small_tile_h), Image.ANTIALIAS ) if data['target_images']['small']: data['target_images']['small'].paste( @@ -90,7 +90,7 @@ def join_tiles(source_paths, durations, target_path): if data['full_tile_widths'][0]: resized = data['target_images']['large'].resize(( data['full_tile_widths'][0], large_tile_h - ), Image.LANCZOS) + ), Image.ANTIALIAS) data['target_images']['full'].paste(resized, (data['full_tile_offset'], 0)) data['full_tile_offset'] += data['full_tile_widths'][0] data['full_tile_widths'] = data['full_tile_widths'][1:] @@ -196,7 +196,7 @@ def join_tiles(source_paths, durations, target_path): #print(image_file) image_file = '%stimeline%s%dp.jpg' % (target_path, full_tile_mode, small_tile_h) data['target_images']['full'].resize( - (full_tile_w, small_tile_h), Image.LANCZOS + (full_tile_w, small_tile_h), Image.ANTIALIAS ).save(image_file) #print(image_file) @@ -227,8 +227,8 @@ def split_tiles(path, paths, durations): file_names = list(filter(is_timeline_file, os.listdir(path))) tiles = {} for file_name in file_names: - mode = re.split(r'\d+', file_name[8:])[0] - split = re.split(r'[a-z]+', file_name[8 + len(mode):-4]) + mode = re.split('\d+', file_name[8:])[0] + split = re.split('[a-z]+', file_name[8 + len(mode):-4]) height, index = map(lambda x: int(x) if len(x) else -1, split) if mode not in tiles: tiles[mode] = {} diff --git a/pandora/item/utils.py b/pandora/item/utils.py index 70a88086..fce7d724 100644 --- a/pandora/item/utils.py +++ b/pandora/item/utils.py @@ -61,7 +61,7 @@ def sort_title(title): title = sort_string(title) #title - title = re.sub(r'[\'!¿¡,\.;\-"\:\*\[\]]', '', title) + title = re.sub('[\'!¿¡,\.;\-"\:\*\[\]]', '', title) return title.strip() def get_positions(ids, pos, decode_id=False): @@ -75,7 +75,6 @@ def get_positions(ids, pos, decode_id=False): if decode_id: positions[i] = ids.index(ox.fromAZ(i)) else: - i = unicodedata.normalize('NFKD', i) positions[i] = ids.index(i) except: pass diff --git a/pandora/item/views.py b/pandora/item/views.py index 4c5943e9..62c6b21a 100644 --- a/pandora/item/views.py +++ b/pandora/item/views.py @@ -16,13 +16,11 @@ from wsgiref.util import FileWrapper from django.conf import settings from ox.utils import json, ET -import ox -from oxdjango.api import actions from oxdjango.decorators import login_required_json -from oxdjango.http import HttpFileResponse from oxdjango.shortcuts import render_to_json_response, get_object_or_404_json, json_response -import oxdjango +from oxdjango.http import HttpFileResponse +import ox from . import models from . import utils @@ -34,6 +32,7 @@ from clip.models import Clip from user.models import has_capability from changelog.models import add_changelog +from oxdjango.api import actions def _order_query(qs, sort, prefix='sort__'): @@ -309,7 +308,7 @@ def find(request, data): responsive UI: First leave out `keys` to get totals as fast as possible, then pass `positions` to get the positions of previously selected items, finally make the query with the `keys` you need and an appropriate `range`. - For more examples, see https://code.0x2620.org/0x2620/pandora/wiki/QuerySyntax. + For more examples, see https://wiki.0x2620.org/wiki/pandora/QuerySyntax. see: add, edit, get, lookup, remove, upload ''' if settings.JSON_DEBUG: @@ -534,7 +533,7 @@ def get(request, data): return render_to_json_response(response) actions.register(get) -def edit_item(user, item, data, is_task=False): +def edit_item(user, item, data): data = data.copy() update_clips = False response = json_response(status=200, text='ok') @@ -559,7 +558,7 @@ def edit_item(user, item, data, is_task=False): user_groups = set([g.name for g in user.groups.all()]) other_groups = list(groups - user_groups) data['groups'] = [g for g in data['groups'] if g in user_groups] + other_groups - r = item.edit(data, is_task=is_task) + r = item.edit(data) if r: r.wait() if update_clips: @@ -596,7 +595,7 @@ def add(request, data): if p: p.wait() else: - item.make_poster() + i.make_poster() del data['title'] if data: response = edit_item(request.user, item, data) @@ -949,11 +948,9 @@ def timeline(request, id, size, position=-1, format='jpg', mode=None): if not item.access(request.user): return HttpResponseForbidden() - modes = [t['id'] for t in settings.CONFIG['timelines']] if not mode: mode = 'antialias' - if mode not in modes: - mode = modes[0] + modes = [t['id'] for t in settings.CONFIG['timelines']] if mode not in modes: raise Http404 modes.pop(modes.index(mode)) @@ -980,8 +977,6 @@ def download_source(request, id, part=None): item = get_object_or_404(models.Item, public_id=id) if not item.access(request.user): return HttpResponseForbidden() - if not has_capability(request.user, 'canDownloadSource'): - return HttpResponseForbidden() if part: part = int(part) - 1 else: @@ -1006,9 +1001,7 @@ def download_source(request, id, part=None): response['Content-Disposition'] = "attachment; filename*=UTF-8''%s" % quote(filename.encode('utf-8')) return response -def download(request, id, resolution=None, format=None, part=None): - if format is None: - format = settings.CONFIG['video']['formats'][0] +def download(request, id, resolution=None, format='webm', part=None): item = get_object_or_404(models.Item, public_id=id) if not resolution or int(resolution) not in settings.CONFIG['video']['resolutions']: resolution = max(settings.CONFIG['video']['resolutions']) @@ -1051,6 +1044,27 @@ def download(request, id, resolution=None, format=None, part=None): response['Content-Disposition'] = "attachment; filename*=UTF-8''%s" % quote(filename.encode('utf-8')) return response +def torrent(request, id, filename=None): + item = get_object_or_404(models.Item, public_id=id) + if not item.access(request.user): + return HttpResponseForbidden() + if not item.torrent: + raise Http404 + if not filename or filename.endswith('.torrent'): + response = HttpResponse(item.get_torrent(request), + content_type='application/x-bittorrent') + filename = utils.safe_filename("%s.torrent" % item.get('title')) + response['Content-Disposition'] = "attachment; filename*=UTF-8''%s" % quote(filename.encode('utf-8')) + return response + while filename.startswith('/'): + filename = filename[1:] + filename = filename.replace('/../', '/') + filename = item.path('torrent/%s' % filename) + filename = os.path.abspath(os.path.join(settings.MEDIA_ROOT, filename)) + response = HttpFileResponse(filename) + response['Content-Disposition'] = "attachment; filename*=UTF-8''%s" % \ + quote(os.path.basename(filename.encode('utf-8'))) + return response def video(request, id, resolution, format, index=None, track=None): resolution = int(resolution) @@ -1272,6 +1286,12 @@ def atom_xml(request): el.text = "1:1" if has_capability(request.user, 'canDownloadVideo'): + if item.torrent: + el = ET.SubElement(entry, "link") + el.attrib['rel'] = 'enclosure' + el.attrib['type'] = 'application/x-bittorrent' + el.attrib['href'] = '%s/torrent/' % page_link + el.attrib['length'] = '%s' % ox.get_torrent_size(item.torrent.path) # FIXME: loop over streams # for s in item.streams().filter(resolution=max(settings.CONFIG['video']['resolutions'])): for s in item.streams().filter(source=None): @@ -1294,15 +1314,12 @@ def atom_xml(request): 'application/atom+xml' ) - def oembed(request): format = request.GET.get('format', 'json') maxwidth = int(request.GET.get('maxwidth', 640)) maxheight = int(request.GET.get('maxheight', 480)) - url = request.GET.get('url') - if not url: - raise Http404 + url = request.GET['url'] parts = urlparse(url).path.split('/') if len(parts) < 2: raise Http404 diff --git a/pandora/itemlist/apps.py b/pandora/itemlist/apps.py deleted file mode 100644 index 541419f0..00000000 --- a/pandora/itemlist/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class ItemListConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'itemlist' - diff --git a/pandora/itemlist/migrations/0004_alter_list_description_alter_list_id_and_more.py b/pandora/itemlist/migrations/0004_alter_list_description_alter_list_id_and_more.py deleted file mode 100644 index f4f04ebf..00000000 --- a/pandora/itemlist/migrations/0004_alter_list_description_alter_list_id_and_more.py +++ /dev/null @@ -1,61 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -import django.core.serializers.json -from django.db import migrations, models -import itemlist.models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('itemlist', '0003_jsonfield'), - ] - - operations = [ - migrations.AlterField( - model_name='list', - name='description', - field=models.TextField(default=''), - ), - migrations.AlterField( - model_name='list', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='list', - name='poster_frames', - field=oxdjango.fields.JSONField(default=list, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='list', - name='query', - field=oxdjango.fields.JSONField(default=itemlist.models.default_query, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='list', - name='sort', - field=oxdjango.fields.JSONField(default=itemlist.models.get_listsort, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='list', - name='status', - field=models.CharField(default='private', max_length=20), - ), - migrations.AlterField( - model_name='list', - name='type', - field=models.CharField(default='static', max_length=255), - ), - migrations.AlterField( - model_name='listitem', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='position', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/itemlist/models.py b/pandora/itemlist/models.py index 2c7a4901..ad2cfb14 100644 --- a/pandora/itemlist/models.py +++ b/pandora/itemlist/models.py @@ -26,9 +26,6 @@ def get_icon_path(f, x): return get_path(f, 'icon.jpg') def get_listview(): return settings.CONFIG['user']['ui']['listView'] def get_listsort(): return tuple(settings.CONFIG['user']['ui']['listSort']) -def default_query(): - return {"static": True} - class List(models.Model): class Meta: @@ -41,7 +38,7 @@ class List(models.Model): name = models.CharField(max_length=255) status = models.CharField(max_length=20, default='private') _status = ['private', 'public', 'featured'] - query = JSONField(default=default_query, editable=False) + query = JSONField(default=lambda: {"static": True}, editable=False) type = models.CharField(max_length=255, default='static') description = models.TextField(default='') @@ -181,7 +178,7 @@ class List(models.Model): self.status = value elif key == 'name': - data['name'] = re.sub(r' \[\d+\]$', '', data['name']).strip() + data['name'] = re.sub(' \[\d+\]$', '', data['name']).strip() if not data['name']: data['name'] = "Untitled" name = data['name'] diff --git a/pandora/itemlist/views.py b/pandora/itemlist/views.py index a55f5f04..04edcc9d 100644 --- a/pandora/itemlist/views.py +++ b/pandora/itemlist/views.py @@ -84,11 +84,6 @@ def findLists(request, data): for x in data.get('query', {}).get('conditions', []) ) - is_personal = request.user.is_authenticated and any( - (x['key'] == 'user' and x['value'] == request.user.username and x['operator'] == '==') - for x in data.get('query', {}).get('conditions', []) - ) - if is_section_request: qs = query['qs'] if not is_featured and not request.user.is_anonymous: @@ -97,9 +92,6 @@ def findLists(request, data): else: qs = _order_query(query['qs'], query['sort']) - if is_personal and request.user.profile.ui.get('hidden', {}).get('lists'): - qs = qs.exclude(name__in=request.user.profile.ui['hidden']['lists']) - response = json_response() if 'keys' in data: qs = qs[query['range'][0]:query['range'][1]] @@ -242,7 +234,7 @@ def addList(request, data): 'type' and 'view'. see: editList, findLists, getList, removeList, sortLists ''' - data['name'] = re.sub(r' \[\d+\]$', '', data.get('name', 'Untitled')).strip() + data['name'] = re.sub(' \[\d+\]$', '', data.get('name', 'Untitled')).strip() name = data['name'] if not name: name = "Untitled" @@ -420,10 +412,7 @@ def sortLists(request, data): models.Position.objects.filter(section=section, list=l).exclude(id=pos.id).delete() else: for i in ids: - try: - l = get_list_or_404_json(i) - except: - continue + l = get_list_or_404_json(i) pos, created = models.Position.objects.get_or_create(list=l, user=request.user, section=section) if pos.position != position: diff --git a/pandora/log/apps.py b/pandora/log/apps.py deleted file mode 100644 index b7cd1d6a..00000000 --- a/pandora/log/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class LogConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'log' - diff --git a/pandora/log/migrations/0002_alter_log_id_alter_log_url.py b/pandora/log/migrations/0002_alter_log_id_alter_log_url.py deleted file mode 100644 index 4fe90645..00000000 --- a/pandora/log/migrations/0002_alter_log_id_alter_log_url.py +++ /dev/null @@ -1,23 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('log', '0001_initial'), - ] - - operations = [ - migrations.AlterField( - model_name='log', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='log', - name='url', - field=models.CharField(default='', max_length=1000), - ), - ] diff --git a/pandora/log/tasks.py b/pandora/log/tasks.py index bdd9cd1f..768fd731 100644 --- a/pandora/log/tasks.py +++ b/pandora/log/tasks.py @@ -2,15 +2,10 @@ from datetime import timedelta, datetime -from app.celery import app -from celery.schedules import crontab +from celery.task import periodic_task from . import models -@app.task(queue='encoding') +@periodic_task(run_every=timedelta(days=1), queue='encoding') def cronjob(**kwargs): models.Log.objects.filter(modified__lt=datetime.now()-timedelta(days=30)).delete() - -@app.on_after_finalize.connect -def setup_periodic_tasks(sender, **kwargs): - sender.add_periodic_task(timedelta(days=1), cronjob.s()) diff --git a/pandora/log/views.py b/pandora/log/views.py index c0fa7675..d8dfa4f4 100644 --- a/pandora/log/views.py +++ b/pandora/log/views.py @@ -65,7 +65,7 @@ actions.register(removeErrorLogs, cache=False) def parse_query(data, user): query = {} query['range'] = [0, 100] - query['sort'] = [{'key': 'modified', 'operator': '-'}] + query['sort'] = [{'key':'name', 'operator':'+'}] for key in ('keys', 'group', 'list', 'range', 'sort', 'query'): if key in data: query[key] = data[key] diff --git a/pandora/manage.py b/pandora/manage.py index 56cc6a7b..4800a366 100755 --- a/pandora/manage.py +++ b/pandora/manage.py @@ -10,8 +10,7 @@ def activate_venv(base): bin_path = os.path.join(base, 'bin') if bin_path not in old_os_path: os.environ['PATH'] = os.path.join(base, 'bin') + os.pathsep + old_os_path - version = '%s.%s' % (sys.version_info.major, sys.version_info.minor) - site_packages = os.path.join(base, 'lib', 'python%s' % version, 'site-packages') + site_packages = os.path.join(base, 'lib', 'python%s' % sys.version[:3], 'site-packages') prev_sys_path = list(sys.path) import site site.addsitedir(site_packages) diff --git a/pandora/mobile/__init__.py b/pandora/mobile/__init__.py deleted file mode 100644 index e69de29b..00000000 diff --git a/pandora/mobile/admin.py b/pandora/mobile/admin.py deleted file mode 100644 index 8c38f3f3..00000000 --- a/pandora/mobile/admin.py +++ /dev/null @@ -1,3 +0,0 @@ -from django.contrib import admin - -# Register your models here. diff --git a/pandora/mobile/apps.py b/pandora/mobile/apps.py deleted file mode 100644 index 708babdb..00000000 --- a/pandora/mobile/apps.py +++ /dev/null @@ -1,6 +0,0 @@ -from django.apps import AppConfig - - -class MobileConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'mobile' diff --git a/pandora/mobile/migrations/__init__.py b/pandora/mobile/migrations/__init__.py deleted file mode 100644 index e69de29b..00000000 diff --git a/pandora/mobile/models.py b/pandora/mobile/models.py deleted file mode 100644 index 71a83623..00000000 --- a/pandora/mobile/models.py +++ /dev/null @@ -1,3 +0,0 @@ -from django.db import models - -# Create your models here. diff --git a/pandora/mobile/tests.py b/pandora/mobile/tests.py deleted file mode 100644 index 7ce503c2..00000000 --- a/pandora/mobile/tests.py +++ /dev/null @@ -1,3 +0,0 @@ -from django.test import TestCase - -# Create your tests here. diff --git a/pandora/mobile/views.py b/pandora/mobile/views.py deleted file mode 100644 index 57a19053..00000000 --- a/pandora/mobile/views.py +++ /dev/null @@ -1,120 +0,0 @@ -from django.conf import settings -from django.shortcuts import render - -import ox - - -def index(request, fragment): - from item.models import Item, Annotation - from edit.models import Edit - from document.models import Document - from edit.views import _order_clips - context = {} - parts = fragment.split('/') - if parts[0] in ('document', 'documents'): - type = 'document' - id = parts[1] - page = None - crop = None - if len(parts) == 3: - rect = parts[2].split(',') - if len(rect) == 1: - page = rect[0] - else: - crop = rect - document = Document.objects.filter(id=ox.fromAZ(id)).first() - if document and document.access(request.user): - context['title'] = document.data['title'] - if document.data.get('description'): - context['description'] = document.data['description'] - link = request.build_absolute_uri(document.get_absolute_url()) - # FIXME: get preview image or fragment parse from url - public_id = ox.toAZ(document.id) - if document.extension != 'html': - preview = '/documents/%s/512p.jpg' % public_id - if page: - preview = '/documents/%s/512p%s.jpg' % (public_id, page) - if crop: - preview = '/documents/%s/512p%s.jpg' % (public_id, ','.join(crop)) - context['preview'] = request.build_absolute_uri(preview) - - elif parts[0] == 'edits': - type = 'edit' - id = parts[1] - id = id.split(':') - username = id[0] - name = ":".join(id[1:]) - name = name.replace('_', ' ') - edit = Edit.objects.filter(user__username=username, name=name).first() - if edit and edit.accessible(request.user): - link = request.build_absolute_uri('/m' + edit.get_absolute_url()) - context['title'] = name - context['description'] = edit.description.split('\n\n')[0] - resolution = max(settings.CONFIG['video']['resolutions']) - if len(parts) > 3: - sort = parts[3] - if sort[0] in ('+', '-'): - sort = [{ - 'operator': sort[0], - 'key': sort[1:], - }] - else: - sort = [{ - 'operator': '+', - 'key': sort, - }] - clips = _order_clips(edit, sort) - else: - clips = edit.get_clips(request.user) - - preview = None - - if len(parts) >= 3 and ':' in parts[-1]: - ts = ox.parse_timecode(parts[-1]) - position = 0 - for clip in clips: - c = clip.json() - if ts > position and ts < position + c['duration']: - start = ts - position + c.get('in', 0) - preview = '/%s/%sp%0.03f.jpg' % (clip.item.public_id, resolution, float(start)) - break - position += c['duration'] - if not preview: - clip = clips.first() - if clip: - start = clip.json()['in'] - preview = '/%s/%sp%0.03f.jpg' % (clip.item.public_id, resolution, float(start)) - if preview: - context['preview'] = request.build_absolute_uri(preview) - else: - type = 'item' - id = parts[0] - item = Item.objects.filter(public_id=id).first() - if item and item.access(request.user): - link = request.build_absolute_uri(item.get_absolute_url()) - if len(parts) > 1 and parts[1] in ('editor', 'player'): - parts = [parts[0]] + parts[2:] - if len(parts) > 1: - aid = '%s/%s' % (id, parts[1]) - annotation = Annotation.objects.filter(public_id=aid).first() - if annotation: - inout = [annotation.start, annotation.end] - else: - inout = parts[1] - if '-' in inout: - inout = inout.split('-') - else: - inout = inout.split(',') - print(inout) - if len(inout) == 3: - inout.pop(1) - if len(inout) == 2: - inout = [ox.parse_timecode(p) for p in inout] - context['preview'] = link + '/480p%s.jpg' % inout[0] - else: - context['preview'] = link + '/480p.jpg' - context['title'] = item.get('title') - if context: - context['url'] = request.build_absolute_uri('/m/' + fragment) - context['settings'] = settings - return render(request, "mobile/index.html", context) diff --git a/pandora/news/apps.py b/pandora/news/apps.py deleted file mode 100644 index 8ebaec28..00000000 --- a/pandora/news/apps.py +++ /dev/null @@ -1,6 +0,0 @@ -from django.apps import AppConfig - - -class NewsConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'news' diff --git a/pandora/news/managers.py b/pandora/news/managers.py index 213d5ee1..bb1f242d 100644 --- a/pandora/news/managers.py +++ b/pandora/news/managers.py @@ -11,7 +11,7 @@ keymap = { default_key = 'name' def parseCondition(condition, user): - k = condition.get('key', default_key) + k = condition.get('key', defauly_key) k = keymap.get(k, k) if not k: k = default_key diff --git a/pandora/news/migrations/0002_alter_news_id.py b/pandora/news/migrations/0002_alter_news_id.py deleted file mode 100644 index 06cfafd2..00000000 --- a/pandora/news/migrations/0002_alter_news_id.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('news', '0001_initial'), - ] - - operations = [ - migrations.AlterField( - model_name='news', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/oxdjango/api/views.py b/pandora/oxdjango/api/views.py index ce7df892..3a4a2e89 100644 --- a/pandora/oxdjango/api/views.py +++ b/pandora/oxdjango/api/views.py @@ -34,15 +34,8 @@ def api(request): return response if request.META.get('CONTENT_TYPE') == 'application/json': r = json.loads(request.body.decode('utf-8')) - if 'action' not in r: - logger.error("invalid api request: %s", r) - response = render_to_json_response(json_response(status=400, - text='Invalid request')) - response['Access-Control-Allow-Origin'] = '*' - return response - else: - action = r['action'] - data = r.get('data', {}) + action = r['action'] + data = r.get('data', {}) else: action = request.POST['action'] data = json.loads(request.POST.get('data', '{}')) diff --git a/pandora/oxdjango/fields.py b/pandora/oxdjango/fields.py index 75ddd3d8..daebd27c 100644 --- a/pandora/oxdjango/fields.py +++ b/pandora/oxdjango/fields.py @@ -5,12 +5,12 @@ import copy from django.db import models from django.utils import datetime_safe +import django.contrib.postgres.fields from django.core.serializers.json import DjangoJSONEncoder from ox.utils import json - -class JSONField(models.JSONField): +class JSONField(django.contrib.postgres.fields.JSONField): def __init__(self, *args, **kwargs): if 'encoder' not in kwargs: @@ -104,7 +104,7 @@ class TupleField(DictField): try: from south.modelsinspector import add_introspection_rules - add_introspection_rules([], [r"^oxdjango\.fields\.DictField"]) - add_introspection_rules([], [r"^oxdjango\.fields\.TupleField"]) + add_introspection_rules([], ["^oxdjango\.fields\.DictField"]) + add_introspection_rules([], ["^oxdjango\.fields\.TupleField"]) except: pass diff --git a/pandora/oxdjango/query.py b/pandora/oxdjango/query.py index 474f894a..46500717 100644 --- a/pandora/oxdjango/query.py +++ b/pandora/oxdjango/query.py @@ -37,12 +37,12 @@ class NullsLastQuery(Query): obj.nulls_last = self.nulls_last return obj - def get_compiler(self, using=None, connection=None, elide_empty=True): + def get_compiler(self, using=None, connection=None): if using is None and connection is None: raise ValueError("Need either using or connection") if using: connection = connections[using] - return NullLastSQLCompiler(self, connection, using, elide_empty) + return NullLastSQLCompiler(self, connection, using) class QuerySet(django.db.models.query.QuerySet): diff --git a/pandora/person/apps.py b/pandora/person/apps.py deleted file mode 100644 index 100989a3..00000000 --- a/pandora/person/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class PersonConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'person' - diff --git a/pandora/person/migrations/0003_alter_person_id.py b/pandora/person/migrations/0003_alter_person_id.py deleted file mode 100644 index 36e5f691..00000000 --- a/pandora/person/migrations/0003_alter_person_id.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('person', '0002_auto_20190723_1446'), - ] - - operations = [ - migrations.AlterField( - model_name='person', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/person/tasks.py b/pandora/person/tasks.py index 4dcb7bad..a94ed273 100644 --- a/pandora/person/tasks.py +++ b/pandora/person/tasks.py @@ -1,11 +1,11 @@ # -*- coding: utf-8 -*- +from celery.task import task from . import models -from app.celery import app -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_itemsort(id): try: p = models.Person.objects.get(pk=id) @@ -13,7 +13,7 @@ def update_itemsort(id): except models.Person.DoesNotExist: pass -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_file_paths(id): from item.models import Item, ItemFind p = models.Person.objects.get(pk=id) diff --git a/pandora/place/apps.py b/pandora/place/apps.py deleted file mode 100644 index 6dcfb91a..00000000 --- a/pandora/place/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class PlaceConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'place' - diff --git a/pandora/place/migrations/0003_alter_place_countrycode_alter_place_id_and_more.py b/pandora/place/migrations/0003_alter_place_countrycode_alter_place_id_and_more.py deleted file mode 100644 index 66a7c355..00000000 --- a/pandora/place/migrations/0003_alter_place_countrycode_alter_place_id_and_more.py +++ /dev/null @@ -1,33 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('place', '0002_auto_20160304_1644'), - ] - - operations = [ - migrations.AlterField( - model_name='place', - name='countryCode', - field=models.CharField(db_index=True, default='', max_length=16), - ), - migrations.AlterField( - model_name='place', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='place', - name='name_find', - field=models.TextField(default='', editable=False), - ), - migrations.AlterField( - model_name='place', - name='type', - field=models.CharField(db_index=True, default='', max_length=1000), - ), - ] diff --git a/pandora/place/tasks.py b/pandora/place/tasks.py index 96926528..3feb88dd 100644 --- a/pandora/place/tasks.py +++ b/pandora/place/tasks.py @@ -1,26 +1,20 @@ # -*- coding: utf-8 -*- -from app.celery import app +from celery.task import task from . import models ''' -from celery.schedules import crontab - -@app.task(queue='encoding') +@periodic_task(run_every=crontab(hour=6, minute=30), queue='encoding') def update_all_matches(**kwargs): ids = [p['id'] for p in models.Place.objects.all().values('id')] for i in ids: p = models.Place.objects.get(pk=i) p.update_matches() - -@app.on_after_finalize.connect -def setup_periodic_tasks(sender, **kwargs): - sender.add_periodic_task(crontab(hour=6, minute=30), update_all_matches.s()) ''' -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_matches(id): place = models.Place.objects.get(pk=id) place.update_matches() diff --git a/pandora/sequence/migrations/0002_alter_sequence_mode.py b/pandora/sequence/migrations/0002_alter_sequence_mode.py deleted file mode 100644 index 06ce99db..00000000 --- a/pandora/sequence/migrations/0002_alter_sequence_mode.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('sequence', '0001_initial'), - ] - - operations = [ - migrations.AlterField( - model_name='sequence', - name='mode', - field=models.IntegerField(choices=[(0, 'shape'), (1, 'color')], default=0), - ), - ] diff --git a/pandora/sequence/migrations/0003_alter_sequence_id.py b/pandora/sequence/migrations/0003_alter_sequence_id.py deleted file mode 100644 index 711e7d41..00000000 --- a/pandora/sequence/migrations/0003_alter_sequence_id.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-29 11:37 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('sequence', '0002_alter_sequence_mode'), - ] - - operations = [ - migrations.AlterField( - model_name='sequence', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/sequence/tasks.py b/pandora/sequence/tasks.py index 0747bf8c..b90c0d5a 100644 --- a/pandora/sequence/tasks.py +++ b/pandora/sequence/tasks.py @@ -1,12 +1,12 @@ # -*- coding: utf-8 -*- from django.db import connection, transaction -from app.celery import app +from celery.task import task import item.models from . import extract -@app.task(ignore_results=True, queue='encoding') +@task(ignore_results=True, queue='encoding') def get_sequences(public_id): from . import models i = item.models.Item.objects.get(public_id=public_id) diff --git a/pandora/settings.py b/pandora/settings.py index 7c9a890a..b2596015 100644 --- a/pandora/settings.py +++ b/pandora/settings.py @@ -67,8 +67,7 @@ STATICFILES_DIRS = ( STATICFILES_FINDERS = ( 'django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder', - "sass_processor.finders.CssFinder", - "compressor.finders.CompressorFinder", + #'django.contrib.staticfiles.finders.DefaultStorageFinder', ) GEOIP_PATH = normpath(join(PROJECT_ROOT, '..', 'data', 'geo')) @@ -111,7 +110,6 @@ ROOT_URLCONF = 'urls' INSTALLED_APPS = ( 'django.contrib.auth', - 'mozilla_django_oidc', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', @@ -125,10 +123,6 @@ INSTALLED_APPS = ( 'django_extensions', 'django_celery_results', - 'django_celery_beat', - 'compressor', - 'sass_processor', - 'app', 'log', 'annotation', @@ -155,31 +149,9 @@ INSTALLED_APPS = ( 'websocket', 'taskqueue', 'home', - 'mobile', ) AUTH_USER_MODEL = 'system.User' -AUTH_PROFILE_MODULE = 'user.UserProfile' -AUTH_CHECK_USERNAME = True - -AUTHENTICATION_BACKENDS = ( - 'django.contrib.auth.backends.ModelBackend', -) - -# OpenID Connect login support -LOGIN_REDIRECT_URL = "/grid" -LOGOUT_REDIRECT_URL = "/grid" -OIDC_USERNAME_ALGO = "app.oidc.generate_username" -OIDC_RP_CLIENT_ID = None - -# define those in local_settings to enable OCID based login -#OIDC_RP_CLIENT_ID = "" -#OIDC_RP_CLIENT_SECRET = "" -#OIDC_RP_SIGN_ALGO = "RS256" -#OIDC_OP_JWKS_ENDPOINT = "" -#OIDC_OP_AUTHORIZATION_ENDPOINT = "" -#OIDC_OP_TOKEN_ENDPOINT = "" -#OIDC_OP_USER_ENDPOINT = "" # Log errors into db LOGGING = { @@ -189,18 +161,13 @@ LOGGING = { 'errors': { 'level': 'ERROR', 'class': 'log.utils.ErrorHandler' - }, + } }, 'loggers': { - 'django': { + 'django.request': { 'handlers': ['errors'], 'level': 'ERROR', - 'propagate': False, - }, - 'pandora': { - 'handlers': ['errors'], - 'level': 'ERROR', - 'propagate': False, + 'propagate': True, }, } } @@ -212,12 +179,10 @@ CACHES = { } } -DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField" - - +AUTH_PROFILE_MODULE = 'user.UserProfile' +AUTH_CHECK_USERNAME = True FFMPEG = 'ffmpeg' FFPROBE = 'ffprobe' -USE_VP9 = True FFMPEG_SUPPORTS_VP9 = True FFMPEG_DEBUG = False @@ -239,8 +204,6 @@ CELERY_RESULT_BACKEND = 'django-db' CELERY_TASK_SERIALIZER = 'json' CELERY_RESULT_SERIALIZER = 'json' CELERY_ACCEPT_CONTENT = ['json'] -CELERY_TIMEZONE = 'UTC' -CELERY_ENABLE_UTC = True CELERY_BROKER_URL = 'amqp://pandora:box@localhost:5672//pandora' @@ -258,6 +221,9 @@ XACCELREDIRECT = False SITE_CONFIG = join(PROJECT_ROOT, 'config.jsonc') DEFAULT_CONFIG = join(PROJECT_ROOT, 'config.pandora.jsonc') +#used if CONFIG['canDownloadVideo'] is set +TRACKER_URL = "udp://tracker.openbittorrent.com:80" + DATA_SERVICE = '' POSTER_PRECEDENCE = () POSTER_ONLY_PORTRAIT = () @@ -298,7 +264,6 @@ SCRIPT_ROOT = normpath(join(PROJECT_ROOT, '..', 'scripts')) #change script to customize ITEM_POSTER = join(SCRIPT_ROOT, 'poster.py') ITEM_ICON = join(SCRIPT_ROOT, 'item_icon.py') -ITEM_ICON_DATA = False LIST_ICON = join(SCRIPT_ROOT, 'list_icon.py') COLLECTION_ICON = join(SCRIPT_ROOT, 'list_icon.py') @@ -309,17 +274,9 @@ SECURE_PROXY_SSL_HEADER = ('HTTP_X_FORWARDED_PROTO', 'https') DATA_UPLOAD_MAX_MEMORY_SIZE = 32 * 1024 * 1024 -EMPTY_CLIPS = True - -YT_DLP_EXTRA = [] - -TXT_TTF = "/usr/share/fonts/truetype/msttcorefonts/Georgia.ttf" -TXT_TTF = "/usr/share/fonts/truetype/noto/NotoSansMono-Regular.ttf" - #you can ignore things below this line #========================================================================= LOCAL_APPS = [] -LOCAL_URLPATTERNS = [] #load installation specific settings from local_settings.py try: from local_settings import * @@ -346,7 +303,4 @@ except NameError: INSTALLED_APPS = tuple(list(INSTALLED_APPS) + LOCAL_APPS) -if OIDC_RP_CLIENT_ID: - AUTHENTICATION_BACKENDS = list(AUTHENTICATION_BACKENDS) + [ - 'app.oidc.OIDCAuthenticationBackend' - ] + diff --git a/pandora/system/apps.py b/pandora/system/apps.py index b3f493ea..5dc4d64b 100644 --- a/pandora/system/apps.py +++ b/pandora/system/apps.py @@ -2,5 +2,4 @@ from django.apps import AppConfig class SystemConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" name = 'system' diff --git a/pandora/system/migrations/0004_alter_user_first_name_alter_user_id.py b/pandora/system/migrations/0004_alter_user_first_name_alter_user_id.py deleted file mode 100644 index 06f57e29..00000000 --- a/pandora/system/migrations/0004_alter_user_first_name_alter_user_id.py +++ /dev/null @@ -1,23 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('system', '0003_field_length'), - ] - - operations = [ - migrations.AlterField( - model_name='user', - name='first_name', - field=models.CharField(blank=True, max_length=150, verbose_name='first name'), - ), - migrations.AlterField( - model_name='user', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/system/models.py b/pandora/system/models.py index cbb4d971..2f59135c 100644 --- a/pandora/system/models.py +++ b/pandora/system/models.py @@ -1,6 +1,6 @@ from django.db import models from django.contrib.auth.models import AbstractUser -from django.utils.translation import gettext_lazy as _ +from django.utils.translation import ugettext_lazy as _ class User(AbstractUser): diff --git a/pandora/taskqueue/apps.py b/pandora/taskqueue/apps.py deleted file mode 100644 index b699dccd..00000000 --- a/pandora/taskqueue/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class TaskQueueConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'taskqueue' - diff --git a/pandora/taskqueue/migrations/0002_alter_task_id_alter_task_status.py b/pandora/taskqueue/migrations/0002_alter_task_id_alter_task_status.py deleted file mode 100644 index 63627462..00000000 --- a/pandora/taskqueue/migrations/0002_alter_task_id_alter_task_status.py +++ /dev/null @@ -1,23 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('taskqueue', '0001_initial'), - ] - - operations = [ - migrations.AlterField( - model_name='task', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='task', - name='status', - field=models.CharField(default='unknown', max_length=32), - ), - ] diff --git a/pandora/taskqueue/models.py b/pandora/taskqueue/models.py index 0d03f920..214f9a41 100644 --- a/pandora/taskqueue/models.py +++ b/pandora/taskqueue/models.py @@ -8,11 +8,10 @@ from django.contrib.auth import get_user_model from django.conf import settings from django.db import models from django.db.models import Q +import celery.task.control +import kombu.five import ox -from app.celery import app - - User = get_user_model() def get_tasks(username): @@ -88,9 +87,6 @@ class Task(models.Model): except Item.DoesNotExist: return False - if self.status == 'transcribing': - return False - if self.item.files.filter(wanted=True, available=False).count(): status = 'pending' elif self.item.files.filter(uploading=True).count(): @@ -115,7 +111,7 @@ class Task(models.Model): return False def get_job(self): - c = app.control.inspect() + c = celery.task.control.inspect() active = c.active(safe=True) if active: for queue in active: @@ -170,7 +166,7 @@ class Task(models.Model): job = self.get_job() if job: print(job) - r = app.control.revoke(job['id']) + r = celery.task.control.revoke(job['id']) print(r) for f in self.item.files.filter(encoding=True): f.delete() diff --git a/pandora/tasks.conf.in b/pandora/tasks.conf.in deleted file mode 100644 index 245a3562..00000000 --- a/pandora/tasks.conf.in +++ /dev/null @@ -1,3 +0,0 @@ -LOGLEVEL=info -MAX_TASKS_PER_CHILD=1000 -CONCURRENCY=2 diff --git a/pandora/templates/document.html b/pandora/templates/document.html deleted file mode 100644 index 34139cc4..00000000 --- a/pandora/templates/document.html +++ /dev/null @@ -1,38 +0,0 @@ - - - - - {{head_title}} - - {% include "baseheader.html" %} - - {%if description %} {%endif%} - - - - - - - {%if description %}{%endif%} - - - - - - diff --git a/pandora/templates/epub.html b/pandora/templates/epub.html deleted file mode 100644 index b619315e..00000000 --- a/pandora/templates/epub.html +++ /dev/null @@ -1,176 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- -
-
- Menu -
-
- -   –   - -
-
- Bookmark -
-
- -
- -
- - -
-
- -
- - - diff --git a/pandora/templates/item.html b/pandora/templates/item.html index 20a84eb7..6b6e22fd 100644 --- a/pandora/templates/item.html +++ b/pandora/templates/item.html @@ -22,7 +22,7 @@
-
+
{{title}}
{{description_html|safe}}
{% for c in clips %} diff --git a/pandora/templates/mobile/index.html b/pandora/templates/mobile/index.html deleted file mode 100644 index e274b941..00000000 --- a/pandora/templates/mobile/index.html +++ /dev/null @@ -1,45 +0,0 @@ -{% load static sass_tags compress %} - - - - - {% if title %} - {{title}} - - - {% endif %} - {%if description %} - - - {%endif%} - {% if preview %} - - - - {% endif %} - {% if url %} - - {% endif %} - - {% compress css file m %} - - - {% endcompress %} - - - -
- {% compress js file m %} - - - - - - - - - - - {% endcompress %} - - diff --git a/pandora/text/apps.py b/pandora/text/apps.py deleted file mode 100644 index 7f181df1..00000000 --- a/pandora/text/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class TextConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'text' - diff --git a/pandora/text/migrations/0002_alter_position_id_alter_text_description_and_more.py b/pandora/text/migrations/0002_alter_position_id_alter_text_description_and_more.py deleted file mode 100644 index d77e3220..00000000 --- a/pandora/text/migrations/0002_alter_position_id_alter_text_description_and_more.py +++ /dev/null @@ -1,43 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('text', '0001_initial'), - ] - - operations = [ - migrations.AlterField( - model_name='position', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='text', - name='description', - field=models.TextField(default=''), - ), - migrations.AlterField( - model_name='text', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='text', - name='status', - field=models.CharField(default='private', max_length=20), - ), - migrations.AlterField( - model_name='text', - name='text', - field=models.TextField(default=''), - ), - migrations.AlterField( - model_name='text', - name='type', - field=models.CharField(default='html', max_length=255), - ), - ] diff --git a/pandora/text/models.py b/pandora/text/models.py index 0489db31..2973ba6d 100644 --- a/pandora/text/models.py +++ b/pandora/text/models.py @@ -131,7 +131,7 @@ class Text(models.Model): self.status = value elif key == 'name': - data['name'] = re.sub(r' \[\d+\]$', '', data['name']).strip() + data['name'] = re.sub(' \[\d+\]$', '', data['name']).strip() if not data['name']: data['name'] = "Untitled" name = data['name'] @@ -215,7 +215,7 @@ class Text(models.Model): response['embeds'] = self.embeds response['names'] = [] else: - response['names'] = re.compile(r'<[^<>]*?data-name="(.+?)"').findall(self.text) + response['names'] = re.compile('<[^<>]*?data-name="(.+?)"').findall(self.text) for key in list(response): if key not in keys + default_keys: diff --git a/pandora/text/views.py b/pandora/text/views.py index 552db47f..33338675 100644 --- a/pandora/text/views.py +++ b/pandora/text/views.py @@ -39,7 +39,7 @@ def addText(request, data): } see: editText, findTexts, getText, removeText, sortTexts ''' - data['name'] = re.sub(r' \[\d+\]$', '', data.get('name', 'Untitled')).strip() + data['name'] = re.sub(' \[\d+\]$', '', data.get('name', 'Untitled')).strip() name = data['name'] if not name: name = "Untitled" diff --git a/pandora/title/apps.py b/pandora/title/apps.py deleted file mode 100644 index d9e33f02..00000000 --- a/pandora/title/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class TitleConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'title' - diff --git a/pandora/title/migrations/0003_alter_title_id.py b/pandora/title/migrations/0003_alter_title_id.py deleted file mode 100644 index dec18542..00000000 --- a/pandora/title/migrations/0003_alter_title_id.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('title', '0002_auto_20190723_1446'), - ] - - operations = [ - migrations.AlterField( - model_name='title', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/translation/apps.py b/pandora/translation/apps.py index 0e3f39b0..bb46e697 100644 --- a/pandora/translation/apps.py +++ b/pandora/translation/apps.py @@ -2,5 +2,4 @@ from django.apps import AppConfig class TranslationConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" name = 'translation' diff --git a/pandora/translation/migrations/0003_alter_translation_id.py b/pandora/translation/migrations/0003_alter_translation_id.py deleted file mode 100644 index 4daa151c..00000000 --- a/pandora/translation/migrations/0003_alter_translation_id.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('translation', '0002_translation_type'), - ] - - operations = [ - migrations.AlterField( - model_name='translation', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/translation/tasks.py b/pandora/translation/tasks.py index 9e9143d7..8b0be30b 100644 --- a/pandora/translation/tasks.py +++ b/pandora/translation/tasks.py @@ -2,22 +2,17 @@ from datetime import timedelta, datetime +from celery.task import task, periodic_task from django.conf import settings from app.utils import limit_rate -from app.celery import app -from celery.schedules import crontab -@app.task(queue='encoding') +@periodic_task(run_every=timedelta(days=1), queue='encoding') def cronjob(**kwargs): if limit_rate('translations.tasks.cronjob', 8 * 60 * 60): load_translations() -@app.on_after_finalize.connect -def setup_periodic_tasks(sender, **kwargs): - sender.add_periodic_task(timedelta(days=1), cronjob.s()) - -@app.task(ignore_results=True, queue='encoding') +@task(ignore_results=True, queue='encoding') def load_translations(): from .models import load_itemkey_translations, load_translations load_translations() diff --git a/pandora/tv/apps.py b/pandora/tv/apps.py deleted file mode 100644 index 66d6f783..00000000 --- a/pandora/tv/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class TvConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'tv' - diff --git a/pandora/tv/migrations/0003_id_bigint.py b/pandora/tv/migrations/0003_id_bigint.py deleted file mode 100644 index 08bc4cd1..00000000 --- a/pandora/tv/migrations/0003_id_bigint.py +++ /dev/null @@ -1,23 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('tv', '0002_auto_20160219_1734'), - ] - - operations = [ - migrations.AlterField( - model_name='channel', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='program', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/tv/models.py b/pandora/tv/models.py index 600c06d0..e9778d70 100644 --- a/pandora/tv/models.py +++ b/pandora/tv/models.py @@ -31,28 +31,23 @@ class Channel(models.Model): items = Item.objects.filter(rendered=True, level__lte=cansee, sort__duration__gt=0) if items.count() == 0: return None + program = self.program.order_by('-start') changed = False - play_now = program.filter(start__lte=now, end__gt=now).first() - while not play_now or not play_now.next(): - played = self.program.filter(run=self.run) - if played.exists(): - not_played = items.exclude(program__in=self.program.filter(run=self.run)) - not_played_count = not_played.count() - if not_played_count == 0: - self.run += 1 - changed = True - else: + while program.count() < 1 or program[0].end < now: + not_played = items.exclude(program__in=self.program.filter(run=self.run)) + not_played_count = not_played.count() + if not_played_count == 0: + self.run += 1 changed = True - if changed: not_played = items not_played_count = not_played.count() - if not_played_count > 1 and program.exists(): + if not_played_count > 1: not_played = not_played.exclude(id=program[0].id) not_played_count = not_played.count() item = not_played[randint(0, not_played_count-1)] - if program.exists(): - start = program.order_by('-end')[0].end + if program.count() > 0: + start = program.aggregate(Max('end'))['end__max'] else: start = now p = Program() @@ -63,10 +58,9 @@ class Channel(models.Model): p.channel = self p.save() program = self.program.order_by('-start') - play_now = program.filter(start__lte=now, end__gt=now).first() if changed: self.save() - return play_now + return program[0] def json(self, user): now = datetime.now() @@ -88,9 +82,6 @@ class Program(models.Model): def __str__(self): return "%s %s" % (self.item, self.start) - def next(self): - return self.channel.program.filter(start__gte=self.end).order_by('start').first() - def json(self, user, current=False): item_json = self.item.json() r = { @@ -101,6 +92,8 @@ class Program(models.Model): r['layers'] = self.item.get_layers(user) r['streams'] = [s.file.oshash for s in self.item.streams()] if current: - r['position'] = (current - self.start).total_seconds() - r['next'] = self.next().json(user) + #requires python2.7 + #r['position'] = (current - self.start).total_seconds() + td = current - self.start + r['position'] = td.seconds + td.days * 24 * 3600 + float(td.microseconds)/10**6 return r diff --git a/pandora/tv/tasks.py b/pandora/tv/tasks.py index 35dcf416..20a9df94 100644 --- a/pandora/tv/tasks.py +++ b/pandora/tv/tasks.py @@ -2,22 +2,17 @@ from datetime import datetime, timedelta -from app.celery import app -from celery.schedules import crontab +from celery.task import periodic_task from app.utils import limit_rate from . import models -@app.task(queue='encoding') +@periodic_task(run_every=timedelta(days=1), queue='encoding') def update_program(**kwargs): if limit_rate('tv.tasks.update_program', 8 * 60 * 60): for c in models.Channel.objects.all(): c.update_program() old = datetime.now() - timedelta(days=180) models.Program.objects.filter(created__lt=old).delete() - -@app.on_after_finalize.connect -def setup_periodic_tasks(sender, **kwargs): - sender.add_periodic_task(timedelta(days=1), update_program.s()) diff --git a/pandora/urlalias/apps.py b/pandora/urlalias/apps.py deleted file mode 100644 index 4a518b48..00000000 --- a/pandora/urlalias/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class UrlaliasConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'urlalias' - diff --git a/pandora/urlalias/migrations/0002_id_bigint.py b/pandora/urlalias/migrations/0002_id_bigint.py deleted file mode 100644 index 0b979d0d..00000000 --- a/pandora/urlalias/migrations/0002_id_bigint.py +++ /dev/null @@ -1,33 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('urlalias', '0001_initial'), - ] - - operations = [ - migrations.AlterField( - model_name='alias', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='idalias', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='layeralias', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='listalias', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - ] diff --git a/pandora/urlalias/views.py b/pandora/urlalias/views.py index 541f61d8..9ed1a36c 100644 --- a/pandora/urlalias/views.py +++ b/pandora/urlalias/views.py @@ -64,7 +64,7 @@ def padma_video(request, url): except: return app.views.index(request) if view: - timecodes = re.compile(r'(\d{2}:\d{2}:\d{2}\.\d{3})-(\d{2}:\d{2}:\d{2}\.\d{3})').findall(view) + timecodes = re.compile('(\d{2}:\d{2}:\d{2}\.\d{3})-(\d{2}:\d{2}:\d{2}\.\d{3})').findall(view) if timecodes: view = ','.join(timecodes[0]) if view: diff --git a/pandora/urls.py b/pandora/urls.py index c0788646..cd241d66 100644 --- a/pandora/urls.py +++ b/pandora/urls.py @@ -1,8 +1,7 @@ # -*- coding: utf-8 -*- import os -import importlib -from django.urls import path, re_path, include +from django.urls import path, re_path from oxdjango.http import HttpFileResponse from django.conf import settings @@ -26,22 +25,15 @@ import edit.views import itemlist.views import item.views import item.site -import mobile.views import translation.views import urlalias.views def serve_static_file(path, location, content_type): return HttpFileResponse(location, content_type=content_type) - urlpatterns = [ #path('admin/', admin.site.urls), -] -if settings.OIDC_RP_CLIENT_ID: - urlpatterns += [ - path('oidc/', include('mozilla_django_oidc.urls')), - ] -urlpatterns += [ + re_path(r'^api/locale.(?P.*).json$', translation.views.locale_json), re_path(r'^api/upload/text/?$', text.views.upload), re_path(r'^api/upload/document/?$', document.views.upload), @@ -53,9 +45,7 @@ urlpatterns += [ re_path(r'^resetUI$', user.views.reset_ui), re_path(r'^collection/(?P.*?)/icon(?P\d*).jpg$', documentcollection.views.icon), re_path(r'^documents/(?P[A-Z0-9]+)/(?P\d*)p(?P[\d,]*).jpg$', document.views.thumbnail), - re_path(r'^documents/(?P[A-Z0-9]+)/epub/(?P.*?)$', document.views.epub), - re_path(r'^documents/(?P[A-Z0-9]+)/(?P.*?\.[^\d]{3,4})$', document.views.file), - re_path(r'^documents/(?P.*?)$', document.views.document), + re_path(r'^documents/(?P[A-Z0-9]+)/(?P.*?\.[^\d]{3})$', document.views.file), re_path(r'^edit/(?P.*?)/icon(?P\d*).jpg$', edit.views.icon), re_path(r'^list/(?P.*?)/icon(?P\d*).jpg$', itemlist.views.icon), re_path(r'^text/(?P.*?)/icon(?P\d*).jpg$', text.views.icon), @@ -74,7 +64,6 @@ urlpatterns += [ re_path(r'^robots.txt$', app.views.robots_txt), re_path(r'^sitemap.xml$', item.views.sitemap_xml), re_path(r'^sitemap(?P\d+).xml$', item.views.sitemap_part_xml), - re_path(r'm/(?P.*?)$', mobile.views.index), path(r'', item.site.urls), ] #sould this not be enabled by default? nginx should handle those @@ -99,17 +88,3 @@ urlpatterns += [ path(r'', app.views.index), ] -if settings.LOCAL_URLPATTERNS: - patterns = [] - for pattern, fn in settings.LOCAL_URLPATTERNS: - if isinstance(fn, str): - m, f = fn.rsplit('.', 1) - try: - m = importlib.import_module(m) - except ImportError: - logger.error('failed to import urllib module: %s', fn, exc_info=True) - continue - fn = getattr(m, f) - patterns.append(re_path(pattern, fn)) - urlpatterns = patterns + urlpatterns - diff --git a/pandora/user/apps.py b/pandora/user/apps.py deleted file mode 100644 index b21c7aba..00000000 --- a/pandora/user/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class UserConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'user' - diff --git a/pandora/user/migrations/0005_id_bigint_jsonfield.py b/pandora/user/migrations/0005_id_bigint_jsonfield.py deleted file mode 100644 index b164e387..00000000 --- a/pandora/user/migrations/0005_id_bigint_jsonfield.py +++ /dev/null @@ -1,40 +0,0 @@ -# Generated by Django 4.2.3 on 2023-07-27 21:28 - -import django.core.serializers.json -from django.db import migrations, models -import oxdjango.fields - - -class Migration(migrations.Migration): - - dependencies = [ - ('user', '0004_jsonfield'), - ] - - operations = [ - migrations.AlterField( - model_name='sessiondata', - name='info', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='userprofile', - name='id', - field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'), - ), - migrations.AlterField( - model_name='userprofile', - name='notes', - field=models.TextField(default=''), - ), - migrations.AlterField( - model_name='userprofile', - name='preferences', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - migrations.AlterField( - model_name='userprofile', - name='ui', - field=oxdjango.fields.JSONField(default=dict, editable=False, encoder=django.core.serializers.json.DjangoJSONEncoder), - ), - ] diff --git a/pandora/user/models.py b/pandora/user/models.py index 78c68483..fba06561 100644 --- a/pandora/user/models.py +++ b/pandora/user/models.py @@ -79,9 +79,7 @@ class SessionData(models.Model): self.level = self.user.profile.level self.firstseen = self.user.date_joined if self.user.groups.exists(): - self.groupsort = ''.join( - ox.sorted_strings(self.user.groups.all().values_list('name', flat=True)) - ).lower() + self.groupssort = ''.join([g.name for g in self.user.groups.all()]) else: self.groupssort = None self.numberoflists = self.user.lists.count() @@ -102,8 +100,6 @@ class SessionData(models.Model): data, created = cls.objects.get_or_create(session_key=session_key) if request.user.is_authenticated: data.user = request.user - else: - data.user = None data.ip = get_ip(request) data.useragent = request.META.get('HTTP_USER_AGENT', '')[:4096] info = json.loads(request.POST.get('data', '{}')) @@ -438,7 +434,8 @@ def has_capability(user, capability): level = 'guest' else: level = user.profile.get_level() - return settings.CONFIG['capabilities'].get(capability, {}).get(level) + return level in settings.CONFIG['capabilities'][capability] \ + and settings.CONFIG['capabilities'][capability][level] def merge_users(old, new): old.annotations.all().update(user=new) diff --git a/pandora/user/tasks.py b/pandora/user/tasks.py index ad3869c8..c1da304c 100644 --- a/pandora/user/tasks.py +++ b/pandora/user/tasks.py @@ -4,22 +4,17 @@ from datetime import timedelta from itertools import zip_longest import json -from celery.schedules import crontab +from celery.task import task, periodic_task -from app.celery import app from app.utils import limit_rate from app.models import Settings from .statistics import Statistics -@app.task(queue='encoding') +@periodic_task(run_every=timedelta(hours=1), queue='encoding') def cronjob(**kwargs): if limit_rate('user.tasks.cronjob', 30 * 60): update_statistics() -@app.on_after_finalize.connect -def setup_periodic_tasks(sender, **kwargs): - sender.add_periodic_task(timedelta(hours=1), cronjob.s()) - def update_statistics(): from . import models @@ -36,7 +31,7 @@ def update_statistics(): stats.add(u.json()) Settings.set('statistics', stats) -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def parse_data(key): from . import models try: @@ -46,7 +41,7 @@ def parse_data(key): session_data.parse_data() session_data.save() -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_numberoflists(username): from . import models user = models.User.objects.get(username=username) @@ -56,7 +51,7 @@ def update_numberoflists(username): numberoflists=user.lists.count() ) -@app.task(ignore_results=True, queue='default') +@task(ignore_results=True, queue='default') def update_numberofcollections(username): from . import models user = models.User.objects.get(username=username) diff --git a/pandora/user/urls.py b/pandora/user/urls.py new file mode 100644 index 00000000..429e1da9 --- /dev/null +++ b/pandora/user/urls.py @@ -0,0 +1,12 @@ +# -*- coding: utf-8 -*- + +from django.conf.urls.defaults import * + + +urlpatterns = patterns("user.views", + (r'^preferences', 'preferences'), + (r'^login', 'login'), + (r'^logout', 'logout'), + (r'^register', 'register'), +) + diff --git a/pandora/user/utils.py b/pandora/user/utils.py index 9abecaaa..5328a464 100644 --- a/pandora/user/utils.py +++ b/pandora/user/utils.py @@ -3,38 +3,6 @@ from django.contrib.gis.geoip2 import GeoIP2, GeoIP2Exception import ox -def prepare_user(user): - from django.contrib.auth import get_user_model - from django.conf import settings - from itemlist.models import List, Position - from django.db.models import Max - - User = get_user_model() - - first_user_qs = User.objects.all() - if user.id: - first_user_qs = first_user_qs.exclude(id=user.id) - if first_user_qs.count() == 0: - user.is_superuser = True - user.is_staff = True - user.save() - - for l in settings.CONFIG['personalLists']: - list = List(name=l['title'], user=user) - for key in ('query', 'public', 'featured'): - if key in l: - setattr(list, key, l[key]) - if key == 'query': - for c in list.query['conditions']: - if c['key'] == 'user': - c['value'] = c['value'].format(username=user.username) - list.save() - pos = Position(list=list, section='personal', user=user) - qs = Position.objects.filter(user=user, section='personal') - pos.position = (qs.aggregate(Max('position'))['position__max'] or 0) + 1 - pos.save() - - def get_ip(request): if 'HTTP_X_FORWARDED_FOR' in request.META: ip = request.META['HTTP_X_FORWARDED_FOR'].split(',')[0] @@ -56,7 +24,7 @@ def get_location(ip): location = g.city(ip) except: try: - location = g.country(ip) + location = g.country(s.ip) except: location = None if location: diff --git a/pandora/user/views.py b/pandora/user/views.py index 86e31537..aa452cec 100644 --- a/pandora/user/views.py +++ b/pandora/user/views.py @@ -28,7 +28,7 @@ from user.models import Group from . import models from .decorators import capability_required_json -from .utils import rename_user, prepare_user +from .utils import rename_user User = get_user_model() @@ -177,10 +177,28 @@ def signup(request, data): } }) else: + first_user = User.objects.count() == 0 user = User(username=data['username'], email=data['email']) user.set_password(data['password']) + #make first user admin + user.is_superuser = first_user + user.is_staff = first_user user.save() - prepare_user(user) + #create default user lists: + for l in settings.CONFIG['personalLists']: + list = List(name=l['title'], user=user) + for key in ('query', 'public', 'featured'): + if key in l: + setattr(list, key, l[key]) + if key == 'query': + for c in list.query['conditions']: + if c['key'] == 'user': + c['value'] = c['value'].format(username=user.username) + list.save() + pos = Position(list=list, section='personal', user=user) + qs = Position.objects.filter(user=user, section='personal') + pos.position = (qs.aggregate(Max('position'))['position__max'] or 0) + 1 + pos.save() if request.session.session_key: models.SessionData.objects.filter(session_key=request.session.session_key).update(user=user) ui = json.loads(request.session.get('ui', 'null')) @@ -896,7 +914,7 @@ def addGroup(request, data): created = False n = 1 name = data['name'] - _name = re.sub(r' \[\d+\]$', '', name).strip() + _name = re.sub(' \[\d+\]$', '', name).strip() while not created: g, created = Group.objects.get_or_create(name=name) n += 1 @@ -928,7 +946,7 @@ def editGroup(request, data): name = data['name'] n = 1 name = data['name'] - _name = re.sub(r' \[\d+\]$', '', name).strip() + _name = re.sub(' \[\d+\]$', '', name).strip() while Group.objects.filter(name=name).count(): n += 1 name = '%s [%d]' % (_name, n) diff --git a/pandora/websocket/__init__.py b/pandora/websocket/__init__.py index ef74deed..e012f868 100644 --- a/pandora/websocket/__init__.py +++ b/pandora/websocket/__init__.py @@ -1,11 +1,11 @@ # -*- coding: utf-8 -*- +from celery.execute import send_task from django.conf import settings -from app.celery import app key = 'websocket' def trigger_event(event, data): if settings.WEBSOCKET: - app.send_task('trigger_event', [event, data], exchange=key, routing_key=key) + send_task('trigger_event', [event, data], exchange=key, routing_key=key) diff --git a/pandora/websocket/apps.py b/pandora/websocket/apps.py deleted file mode 100644 index 63053af1..00000000 --- a/pandora/websocket/apps.py +++ /dev/null @@ -1,7 +0,0 @@ -from django.apps import AppConfig - - -class WebsocketConfig(AppConfig): - default_auto_field = "django.db.models.BigAutoField" - name = 'websocket' - diff --git a/requirements.txt b/requirements.txt index 12abf958..e2f2c2eb 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,25 +1,16 @@ -Django==4.2.26 +Django==3.0.10 +simplejson chardet -celery==5.3.5 -django-celery-results==2.5.1 -django-celery-beat==2.5.0 -django-extensions==3.2.3 -libsass -django-compressor -django-sass-processor +celery<5.0,>4.3 +django-celery-results +django-extensions==2.2.9 gunicorn==20.0.4 html5lib requests<3.0.0,>=2.24.0 urllib3<2.0.0,>=1.25.2 -tornado==6.3.3 -geoip2==4.7.0 -yt-dlp>=2024.10.22 +tornado<5 +geoip2==4.1.0 +youtube-dl>=2020.5.8 python-memcached -elasticsearch<8 +elasticsearch future -pytz -pypdfium2 -Pillow>=10 -pillow-heif -pillow-avif-plugin -mozilla-django-oidc==4.0.1 diff --git a/scripts/item_icon.pandora.py b/scripts/item_icon.pandora.py index c069bbbb..4f4b1e35 100755 --- a/scripts/item_icon.pandora.py +++ b/scripts/item_icon.pandora.py @@ -20,11 +20,11 @@ def render_icon(frame, timeline, icon): frame_image = Image.open(frame) if frame else Image.new('RGB', (1024, 768), (0, 0, 0)) frame_image_ratio = frame_image.size[0] / frame_image.size[1] if frame_ratio < frame_image_ratio: - frame_image = frame_image.resize((int(frame_height * frame_image_ratio), frame_height), Image.LANCZOS) + frame_image = frame_image.resize((int(frame_height * frame_image_ratio), frame_height), Image.ANTIALIAS) left = int((frame_image.size[0] - frame_width) / 2) frame_image = frame_image.crop((left, 0, left + frame_width, frame_height)) else: - frame_image = frame_image.resize((frame_width, int(frame_width / frame_image_ratio)), Image.LANCZOS) + frame_image = frame_image.resize((frame_width, int(frame_width / frame_image_ratio)), Image.ANTIALIAS) top = int((frame_image.size[1] - frame_height) / 2) frame_image = frame_image.crop((0, top, frame_width, top + frame_height)) icon_image.paste(frame_image, (0, 0)) @@ -36,7 +36,7 @@ def render_icon(frame, timeline, icon): mask_image = Image.open(os.path.join(static_root, 'iconTimelineOuterMask.png')) icon_image.paste(timeline_image, (timeline_left - 4, timeline_top - 4), mask=mask_image) timeline_image = Image.open(timeline) if timeline else Image.new('RGB', (timeline_width, timeline_height), (0, 0, 0)) - timeline_image = timeline_image.resize((timeline_width, timeline_height), Image.LANCZOS) + timeline_image = timeline_image.resize((timeline_width, timeline_height), Image.ANTIALIAS) mask_image = Image.open(os.path.join(static_root, 'iconTimelineInnerMask.png')) icon_image.paste(timeline_image, (timeline_left, timeline_top), mask=mask_image) # we're using jpegs with border-radius diff --git a/scripts/list_icon.pandora.py b/scripts/list_icon.pandora.py index 3d0fbbf1..8c930b7d 100755 --- a/scripts/list_icon.pandora.py +++ b/scripts/list_icon.pandora.py @@ -24,11 +24,11 @@ def render_list_icon(frames, icon): frame_image_ratio = frame_image.size[0] / frame_image.size[1] frame_width_ = frame_width + (1 if i % 2 == 1 else 0) if frame_ratio < frame_image_ratio: - frame_image = frame_image.resize((int(frame_height * frame_image_ratio), frame_height), Image.LANCZOS) + frame_image = frame_image.resize((int(frame_height * frame_image_ratio), frame_height), Image.ANTIALIAS) left = int((frame_image.size[0] - frame_width_) / 2) frame_image = frame_image.crop((left, 0, left + frame_width_, frame_height)) else: - frame_image = frame_image.resize((frame_width_, int(frame_width_ / frame_image_ratio)), Image.LANCZOS) + frame_image = frame_image.resize((frame_width_, int(frame_width_ / frame_image_ratio)), Image.ANTIALIAS) top = int((frame_image.size[1] - frame_height) / 2) frame_image = frame_image.crop((0, top, frame_width_, top + frame_height)) icon_image.paste(frame_image, (i % 2 * frame_width + (1 if i % 2 == 2 else 0), diff --git a/scripts/poster.0xdb.py b/scripts/poster.0xdb.py index 7666702a..9b9f2470 100755 --- a/scripts/poster.0xdb.py +++ b/scripts/poster.0xdb.py @@ -64,11 +64,11 @@ def render_poster(data, poster): frame_image = Image.open(frame) frame_image_ratio = frame_image.size[0] / frame_image.size[1] if frame_ratio < frame_image_ratio: - frame_image = frame_image.resize((int(frame_size[1] * frame_image_ratio), frame_size[1]), Image.LANCZOS) + frame_image = frame_image.resize((int(frame_size[1] * frame_image_ratio), frame_size[1]), Image.ANTIALIAS) left = int((frame_image.size[0] - frame_size[0]) / 2) frame_image = frame_image.crop((left, 0, left + frame_size[0], frame_size[1])) else: - frame_image = frame_image.resize((frame_size[0], int(frame_size[0] / frame_image_ratio)), Image.LANCZOS) + frame_image = frame_image.resize((frame_size[0], int(frame_size[0] / frame_image_ratio)), Image.ANTIALIAS) top = int((frame_image.size[1] - frame_size[1]) / 2) frame_image = frame_image.crop((0, top, frame_size[0], top + frame_size[1])) poster_image.paste(frame_image, (0, 0)) @@ -77,7 +77,7 @@ def render_poster(data, poster): # logo logo_image = Image.open(os.path.join(static_root, 'logo.0xdb.png')) - logo_image = logo_image.resize(logo_size, Image.LANCZOS) + logo_image = logo_image.resize(logo_size, Image.ANTIALIAS) for y in range(logo_size[1]): for x in range(logo_size[0]): poster_color = poster_image.getpixel((margin + x, margin + y)) @@ -95,11 +95,11 @@ def render_poster(data, poster): if small_frame_image: small_frame_image_ratio = small_frame_image.size[0] / small_frame_image.size[1] if small_frame_ratio < small_frame_image_ratio: - small_frame_image = small_frame_image.resize((int(small_frame_size[1] * small_frame_image_ratio), small_frame_size[1]), Image.LANCZOS) + small_frame_image = small_frame_image.resize((int(small_frame_size[1] * small_frame_image_ratio), small_frame_size[1]), Image.ANTIALIAS) left = int((small_frame_image.size[0] - small_frame_size[0]) / 2) small_frame_image = small_frame_image.crop((left, 0, left + small_frame_size[0], small_frame_size[1])) else: - small_frame_image = small_frame_image.resize((small_frame_size[0], int(small_frame_size[0] / small_frame_image_ratio)), Image.LANCZOS) + small_frame_image = small_frame_image.resize((small_frame_size[0], int(small_frame_size[0] / small_frame_image_ratio)), Image.ANTIALIAS) top = int((small_frame_image.size[1] - small_frame_size[1]) / 2) small_frame_image = small_frame_image.crop((0, top, small_frame_size[0], top + small_frame_size[1])) poster_image.paste(small_frame_image, (i * small_frame_size[0], frame_size[1])) @@ -189,7 +189,7 @@ def render_poster(data, poster): # timeline if timeline: timeline_image = Image.open(timeline) - timeline_image = timeline_image.resize(timeline_size, Image.LANCZOS) + timeline_image = timeline_image.resize(timeline_size, Image.ANTIALIAS) poster_image.paste(timeline_image, (0, poster_size[1] - timeline_size[1])) else: draw.rectangle(((0, poster_size[1] - timeline_size[1]), poster_size), fill=image_color) diff --git a/scripts/poster.indiancinema.py b/scripts/poster.indiancinema.py index 9146af31..bc37fca5 100755 --- a/scripts/poster.indiancinema.py +++ b/scripts/poster.indiancinema.py @@ -160,7 +160,7 @@ def render_poster(data, poster): if frame_ratio < frame_image_ratio: frame_image = frame_image.resize( (int(frame_height * frame_image_ratio), frame_height), - Image.LANCZOS + Image.ANTIALIAS ) left = int((frame_image.size[0] - poster_width) / 2) frame_image = frame_image.crop( @@ -169,7 +169,7 @@ def render_poster(data, poster): else: frame_image = frame_image.resize( (poster_width, int(poster_width / frame_image_ratio)), - Image.LANCZOS + Image.ANTIALIAS ) top = int((frame_image.size[1] - frame_height) / 2) frame_image = frame_image.crop( @@ -187,7 +187,7 @@ def render_poster(data, poster): timeline_image = Image.open(timeline) timeline_image = timeline_image.resize( (poster_width, timeline_height), - Image.LANCZOS + Image.ANTIALIAS ) poster_image.paste(timeline_image, (0, poster_height - timeline_height)) else: diff --git a/scripts/poster.padma.py b/scripts/poster.padma.py index bf949801..015aaa9b 100755 --- a/scripts/poster.padma.py +++ b/scripts/poster.padma.py @@ -33,7 +33,7 @@ def render_poster(data, poster): timeline_lines = 16 if timeline: timeline_image = Image.open(timeline) - timeline_image = timeline_image.resize((10240, timeline_height), Image.LANCZOS) + timeline_image = timeline_image.resize((10240, timeline_height), Image.ANTIALIAS) for i in range(timeline_lines): line_image = timeline_image.crop((i * poster_width, 0, (i + 1) * poster_width, 64)) poster_image.paste(line_image, (0, i * timeline_height)) diff --git a/scripts/poster.pandora.py b/scripts/poster.pandora.py index eef8cdac..5f196562 100755 --- a/scripts/poster.pandora.py +++ b/scripts/poster.pandora.py @@ -62,11 +62,11 @@ def render_poster(data, poster): frame_image = Image.open(frame) frame_image_ratio = frame_image.size[0] / frame_image.size[1] if frame_ratio < frame_image_ratio: - frame_image = frame_image.resize((int(frame_height * frame_image_ratio), frame_height), Image.LANCZOS) + frame_image = frame_image.resize((int(frame_height * frame_image_ratio), frame_height), Image.ANTIALIAS) left = int((frame_image.size[0] - frame_width) / 2) frame_image = frame_image.crop((left, 0, left + frame_width, frame_height)) else: - frame_image = frame_image.resize((frame_width, int(frame_width / frame_image_ratio)), Image.LANCZOS) + frame_image = frame_image.resize((frame_width, int(frame_width / frame_image_ratio)), Image.ANTIALIAS) top = int((frame_image.size[1] - frame_height) / 2) frame_image = frame_image.crop((0, top, frame_width, top + frame_height)) poster_image.paste(frame_image, (0, 0)) @@ -76,7 +76,7 @@ def render_poster(data, poster): timeline_height = 64 if timeline: timeline_image = Image.open(timeline) - timeline_image = timeline_image.resize((timeline_width, timeline_height), Image.LANCZOS) + timeline_image = timeline_image.resize((timeline_width, timeline_height), Image.ANTIALIAS) poster_image.paste(timeline_image, (0, frame_height)) # text @@ -115,7 +115,7 @@ def render_poster(data, poster): logo_height = 32 logo_image = Image.open(os.path.join(static_root, '..', '..', 'static', 'png', 'logo.png')) logo_width = int(round(logo_height * logo_image.size[0] / logo_image.size[1])) - logo_image = logo_image.resize((logo_width, logo_height), Image.LANCZOS) + logo_image = logo_image.resize((logo_width, logo_height), Image.ANTIALIAS) logo_left = text_width - text_margin - logo_width logo_top = text_bottom - text_margin - logo_height for y in range(logo_height): diff --git a/static/cbr.js/bitjs/archive.js b/static/cbr.js/bitjs/archive.js deleted file mode 100644 index 1596b74b..00000000 --- a/static/cbr.js/bitjs/archive.js +++ /dev/null @@ -1,353 +0,0 @@ -/** - * archive.js - * - * Provides base functionality for unarchiving. - * - * Licensed under the MIT License - * - * Copyright(c) 2011 Google Inc. - */ - -var bitjs = bitjs || {}; -bitjs.archive = bitjs.archive || {}; - -(function() { - -// =========================================================================== -// Stolen from Closure because it's the best way to do Java-like inheritance. -bitjs.base = function(me, opt_methodName, var_args) { - var caller = arguments.callee.caller; - if (caller.superClass_) { - // This is a constructor. Call the superclass constructor. - return caller.superClass_.constructor.apply( - me, Array.prototype.slice.call(arguments, 1)); - } - - var args = Array.prototype.slice.call(arguments, 2); - var foundCaller = false; - for (var ctor = me.constructor; - ctor; ctor = ctor.superClass_ && ctor.superClass_.constructor) { - if (ctor.prototype[opt_methodName] === caller) { - foundCaller = true; - } else if (foundCaller) { - return ctor.prototype[opt_methodName].apply(me, args); - } - } - - // If we did not find the caller in the prototype chain, - // then one of two things happened: - // 1) The caller is an instance method. - // 2) This method was not called by the right caller. - if (me[opt_methodName] === caller) { - return me.constructor.prototype[opt_methodName].apply(me, args); - } else { - throw Error( - 'goog.base called from a method of one name ' + - 'to a method of a different name'); - } -}; -bitjs.inherits = function(childCtor, parentCtor) { - /** @constructor */ - function tempCtor() {}; - tempCtor.prototype = parentCtor.prototype; - childCtor.superClass_ = parentCtor.prototype; - childCtor.prototype = new tempCtor(); - childCtor.prototype.constructor = childCtor; -}; -// =========================================================================== - -/** - * An unarchive event. - * - * @param {string} type The event type. - * @constructor - */ -bitjs.archive.UnarchiveEvent = function(type) { - /** - * The event type. - * - * @type {string} - */ - this.type = type; -}; - -/** - * The UnarchiveEvent types. - */ -bitjs.archive.UnarchiveEvent.Type = { - START: 'start', - PROGRESS: 'progress', - EXTRACT: 'extract', - FINISH: 'finish', - INFO: 'info', - ERROR: 'error' -}; - -/** - * Useful for passing info up to the client (for debugging). - * - * @param {string} msg The info message. - */ -bitjs.archive.UnarchiveInfoEvent = function(msg) { - bitjs.base(this, bitjs.archive.UnarchiveEvent.Type.INFO); - - /** - * The information message. - * - * @type {string} - */ - this.msg = msg; -}; -bitjs.inherits(bitjs.archive.UnarchiveInfoEvent, bitjs.archive.UnarchiveEvent); - -/** - * An unrecoverable error has occured. - * - * @param {string} msg The error message. - */ -bitjs.archive.UnarchiveErrorEvent = function(msg) { - bitjs.base(this, bitjs.archive.UnarchiveEvent.Type.ERROR); - - /** - * The information message. - * - * @type {string} - */ - this.msg = msg; -}; -bitjs.inherits(bitjs.archive.UnarchiveErrorEvent, bitjs.archive.UnarchiveEvent); - -/** - * Start event. - * - * @param {string} msg The info message. - */ -bitjs.archive.UnarchiveStartEvent = function() { - bitjs.base(this, bitjs.archive.UnarchiveEvent.Type.START); -}; -bitjs.inherits(bitjs.archive.UnarchiveStartEvent, bitjs.archive.UnarchiveEvent); - -/** - * Finish event. - * - * @param {string} msg The info message. - */ -bitjs.archive.UnarchiveFinishEvent = function() { - bitjs.base(this, bitjs.archive.UnarchiveEvent.Type.FINISH); -}; -bitjs.inherits(bitjs.archive.UnarchiveFinishEvent, bitjs.archive.UnarchiveEvent); - -/** - * Progress event. - */ -bitjs.archive.UnarchiveProgressEvent = function( - currentFilename, - currentFileNumber, - currentBytesUnarchivedInFile, - currentBytesUnarchived, - totalUncompressedBytesInArchive, - totalFilesInArchive) { - bitjs.base(this, bitjs.archive.UnarchiveEvent.Type.PROGRESS); - - this.currentFilename = currentFilename; - this.currentFileNumber = currentFileNumber; - this.currentBytesUnarchivedInFile = currentBytesUnarchivedInFile; - this.totalFilesInArchive = totalFilesInArchive; - this.currentBytesUnarchived = currentBytesUnarchived; - this.totalUncompressedBytesInArchive = totalUncompressedBytesInArchive; -}; -bitjs.inherits(bitjs.archive.UnarchiveProgressEvent, bitjs.archive.UnarchiveEvent); - -/** - * All extracted files returned by an Unarchiver will implement - * the following interface: - * - * interface UnarchivedFile { - * string filename - * TypedArray fileData - * } - * - */ - -/** - * Extract event. - */ -bitjs.archive.UnarchiveExtractEvent = function(unarchivedFile) { - bitjs.base(this, bitjs.archive.UnarchiveEvent.Type.EXTRACT); - - /** - * @type {UnarchivedFile} - */ - this.unarchivedFile = unarchivedFile; -}; -bitjs.inherits(bitjs.archive.UnarchiveExtractEvent, bitjs.archive.UnarchiveEvent); - - -/** - * Base class for all Unarchivers. - * - * @param {ArrayBuffer} arrayBuffer The Array Buffer. - * @param {string} opt_pathToBitJS Optional string for where the BitJS files are located. - * @constructor - */ -bitjs.archive.Unarchiver = function(arrayBuffer, opt_pathToBitJS) { - /** - * The ArrayBuffer object. - * @type {ArrayBuffer} - * @protected - */ - this.ab = arrayBuffer; - - /** - * The path to the BitJS files. - * @type {string} - * @private - */ - this.pathToBitJS_ = opt_pathToBitJS || ''; - - /** - * A map from event type to an array of listeners. - * @type {Map.} - */ - this.listeners_ = {}; - for (var type in bitjs.archive.UnarchiveEvent.Type) { - this.listeners_[bitjs.archive.UnarchiveEvent.Type[type]] = []; - } -}; - -/** - * Private web worker initialized during start(). - * @type {Worker} - * @private - */ -bitjs.archive.Unarchiver.prototype.worker_ = null; - -/** - * This method must be overridden by the subclass to return the script filename. - * @return {string} The script filename. - * @protected. - */ -bitjs.archive.Unarchiver.prototype.getScriptFileName = function() { - throw 'Subclasses of AbstractUnarchiver must overload getScriptFileName()'; -}; - -/** - * Adds an event listener for UnarchiveEvents. - * - * @param {string} Event type. - * @param {function} An event handler function. - */ -bitjs.archive.Unarchiver.prototype.addEventListener = function(type, listener) { - if (type in this.listeners_) { - if (this.listeners_[type].indexOf(listener) == -1) { - this.listeners_[type].push(listener); - } - } -}; - -/** - * Removes an event listener. - * - * @param {string} Event type. - * @param {EventListener|function} An event listener or handler function. - */ -bitjs.archive.Unarchiver.prototype.removeEventListener = function(type, listener) { - if (type in this.listeners_) { - var index = this.listeners_[type].indexOf(listener); - if (index != -1) { - this.listeners_[type].splice(index, 1); - } - } -}; - -/** - * Receive an event and pass it to the listener functions. - * - * @param {bitjs.archive.UnarchiveEvent} e - * @private - */ -bitjs.archive.Unarchiver.prototype.handleWorkerEvent_ = function(e) { - if ((e instanceof bitjs.archive.UnarchiveEvent || e.type) && - this.listeners_[e.type] instanceof Array) { - this.listeners_[e.type].forEach(function (listener) { listener(e) }); - if (e.type == bitjs.archive.UnarchiveEvent.Type.FINISH) { - this.worker_.terminate(); - } - } else { - console.log(e); - } -}; - -/** - * Starts the unarchive in a separate Web Worker thread and returns immediately. - */ - bitjs.archive.Unarchiver.prototype.start = function() { - var me = this; - var scriptFileName = this.pathToBitJS_ + this.getScriptFileName(); - if (scriptFileName) { - this.worker_ = new Worker(scriptFileName); - - this.worker_.onerror = function(e) { - console.log('Worker error: message = ' + e.message); - throw e; - }; - - this.worker_.onmessage = function(e) { - if (typeof e.data == 'string') { - // Just log any strings the workers pump our way. - console.log(e.data); - } else { - // Assume that it is an UnarchiveEvent. Some browsers preserve the 'type' - // so that instanceof UnarchiveEvent returns true, but others do not. - me.handleWorkerEvent_(e.data); - } - }; - - this.worker_.postMessage({file: this.ab}); - } -}; - -/** - * Terminates the Web Worker for this Unarchiver and returns immediately. - */ -bitjs.archive.Unarchiver.prototype.stop = function() { - if (this.worker_) { - this.worker_.terminate(); - } -}; - - -/** - * Unzipper - * @extends {bitjs.archive.Unarchiver} - * @constructor - */ -bitjs.archive.Unzipper = function(arrayBuffer, opt_pathToBitJS) { - bitjs.base(this, arrayBuffer, opt_pathToBitJS); -}; -bitjs.inherits(bitjs.archive.Unzipper, bitjs.archive.Unarchiver); -bitjs.archive.Unzipper.prototype.getScriptFileName = function() { return 'unzip.js' }; - -/** - * Unrarrer - * @extends {bitjs.archive.Unarchiver} - * @constructor - */ -bitjs.archive.Unrarrer = function(arrayBuffer, opt_pathToBitJS) { - bitjs.base(this, arrayBuffer, opt_pathToBitJS); -}; -bitjs.inherits(bitjs.archive.Unrarrer, bitjs.archive.Unarchiver); -bitjs.archive.Unrarrer.prototype.getScriptFileName = function() { return 'unrar.js' }; - -/** - * Untarrer - * @extends {bitjs.archive.Unarchiver} - * @constructor - */ -bitjs.archive.Untarrer = function(arrayBuffer, opt_pathToBitJS) { - bitjs.base(this, arrayBuffer, opt_pathToBitJS); -}; -bitjs.inherits(bitjs.archive.Untarrer, bitjs.archive.Unarchiver); -bitjs.archive.Untarrer.prototype.getScriptFileName = function() { return 'untar.js' }; - -})(); \ No newline at end of file diff --git a/static/cbr.js/bitjs/io.js b/static/cbr.js/bitjs/io.js deleted file mode 100644 index 6eabfe9a..00000000 --- a/static/cbr.js/bitjs/io.js +++ /dev/null @@ -1,483 +0,0 @@ -/* - * io.js - * - * Provides readers for bit/byte streams (reading) and a byte buffer (writing). - * - * Licensed under the MIT License - * - * Copyright(c) 2011 Google Inc. - * Copyright(c) 2011 antimatter15 - */ - -var bitjs = bitjs || {}; -bitjs.io = bitjs.io || {}; - -(function() { - -// mask for getting the Nth bit (zero-based) -bitjs.BIT = [ 0x01, 0x02, 0x04, 0x08, - 0x10, 0x20, 0x40, 0x80, - 0x100, 0x200, 0x400, 0x800, - 0x1000, 0x2000, 0x4000, 0x8000]; - -// mask for getting N number of bits (0-8) -var BITMASK = [0, 0x01, 0x03, 0x07, 0x0F, 0x1F, 0x3F, 0x7F, 0xFF ]; - - -/** - * This bit stream peeks and consumes bits out of a binary stream. - * - * @param {ArrayBuffer} ab An ArrayBuffer object or a Uint8Array. - * @param {boolean} rtl Whether the stream reads bits from the byte starting - * from bit 7 to 0 (true) or bit 0 to 7 (false). - * @param {Number} opt_offset The offset into the ArrayBuffer - * @param {Number} opt_length The length of this BitStream - */ -bitjs.io.BitStream = function(ab, rtl, opt_offset, opt_length) { - if (!ab || !ab.toString || ab.toString() !== "[object ArrayBuffer]") { - throw "Error! BitArray constructed with an invalid ArrayBuffer object"; - } - - var offset = opt_offset || 0; - var length = opt_length || ab.byteLength; - this.bytes = new Uint8Array(ab, offset, length); - this.bytePtr = 0; // tracks which byte we are on - this.bitPtr = 0; // tracks which bit we are on (can have values 0 through 7) - this.peekBits = rtl ? this.peekBits_rtl : this.peekBits_ltr; -}; - - -/** - * byte0 byte1 byte2 byte3 - * 7......0 | 7......0 | 7......0 | 7......0 - * - * The bit pointer starts at bit0 of byte0 and moves left until it reaches - * bit7 of byte0, then jumps to bit0 of byte1, etc. - * @param {number} n The number of bits to peek. - * @param {boolean=} movePointers Whether to move the pointer, defaults false. - * @return {number} The peeked bits, as an unsigned number. - */ -bitjs.io.BitStream.prototype.peekBits_ltr = function(n, movePointers) { - if (n <= 0 || typeof n != typeof 1) { - return 0; - } - - var movePointers = movePointers || false, - bytePtr = this.bytePtr, - bitPtr = this.bitPtr, - result = 0, - bitsIn = 0, - bytes = this.bytes; - - // keep going until we have no more bits left to peek at - // TODO: Consider putting all bits from bytes we will need into a variable and then - // shifting/masking it to just extract the bits we want. - // This could be considerably faster when reading more than 3 or 4 bits at a time. - while (n > 0) { - if (bytePtr >= bytes.length) { - throw "Error! Overflowed the bit stream! n=" + n + ", bytePtr=" + bytePtr + ", bytes.length=" + - bytes.length + ", bitPtr=" + bitPtr; - return -1; - } - - var numBitsLeftInThisByte = (8 - bitPtr); - if (n >= numBitsLeftInThisByte) { - var mask = (BITMASK[numBitsLeftInThisByte] << bitPtr); - result |= (((bytes[bytePtr] & mask) >> bitPtr) << bitsIn); - - bytePtr++; - bitPtr = 0; - bitsIn += numBitsLeftInThisByte; - n -= numBitsLeftInThisByte; - } - else { - var mask = (BITMASK[n] << bitPtr); - result |= (((bytes[bytePtr] & mask) >> bitPtr) << bitsIn); - - bitPtr += n; - bitsIn += n; - n = 0; - } - } - - if (movePointers) { - this.bitPtr = bitPtr; - this.bytePtr = bytePtr; - } - - return result; -}; - - -/** - * byte0 byte1 byte2 byte3 - * 7......0 | 7......0 | 7......0 | 7......0 - * - * The bit pointer starts at bit7 of byte0 and moves right until it reaches - * bit0 of byte0, then goes to bit7 of byte1, etc. - * @param {number} n The number of bits to peek. - * @param {boolean=} movePointers Whether to move the pointer, defaults false. - * @return {number} The peeked bits, as an unsigned number. - */ -bitjs.io.BitStream.prototype.peekBits_rtl = function(n, movePointers) { - if (n <= 0 || typeof n != typeof 1) { - return 0; - } - - var movePointers = movePointers || false, - bytePtr = this.bytePtr, - bitPtr = this.bitPtr, - result = 0, - bytes = this.bytes; - - // keep going until we have no more bits left to peek at - // TODO: Consider putting all bits from bytes we will need into a variable and then - // shifting/masking it to just extract the bits we want. - // This could be considerably faster when reading more than 3 or 4 bits at a time. - while (n > 0) { - - if (bytePtr >= bytes.length) { - throw "Error! Overflowed the bit stream! n=" + n + ", bytePtr=" + bytePtr + ", bytes.length=" + - bytes.length + ", bitPtr=" + bitPtr; - return -1; - } - - var numBitsLeftInThisByte = (8 - bitPtr); - if (n >= numBitsLeftInThisByte) { - result <<= numBitsLeftInThisByte; - result |= (BITMASK[numBitsLeftInThisByte] & bytes[bytePtr]); - bytePtr++; - bitPtr = 0; - n -= numBitsLeftInThisByte; - } - else { - result <<= n; - result |= ((bytes[bytePtr] & (BITMASK[n] << (8 - n - bitPtr))) >> (8 - n - bitPtr)); - - bitPtr += n; - n = 0; - } - } - - if (movePointers) { - this.bitPtr = bitPtr; - this.bytePtr = bytePtr; - } - - return result; -}; - - -/** - * Some voodoo magic. - */ -bitjs.io.BitStream.prototype.getBits = function() { - return (((((this.bytes[this.bytePtr] & 0xff) << 16) + - ((this.bytes[this.bytePtr+1] & 0xff) << 8) + - ((this.bytes[this.bytePtr+2] & 0xff))) >>> (8-this.bitPtr)) & 0xffff); -}; - - -/** - * Reads n bits out of the stream, consuming them (moving the bit pointer). - * @param {number} n The number of bits to read. - * @return {number} The read bits, as an unsigned number. - */ -bitjs.io.BitStream.prototype.readBits = function(n) { - return this.peekBits(n, true); -}; - - -/** - * This returns n bytes as a sub-array, advancing the pointer if movePointers - * is true. Only use this for uncompressed blocks as this throws away remaining - * bits in the current byte. - * @param {number} n The number of bytes to peek. - * @param {boolean=} movePointers Whether to move the pointer, defaults false. - * @return {Uint8Array} The subarray. - */ -bitjs.io.BitStream.prototype.peekBytes = function(n, movePointers) { - if (n <= 0 || typeof n != typeof 1) { - return 0; - } - - // from http://tools.ietf.org/html/rfc1951#page-11 - // "Any bits of input up to the next byte boundary are ignored." - while (this.bitPtr != 0) { - this.readBits(1); - } - - var movePointers = movePointers || false; - var bytePtr = this.bytePtr, - bitPtr = this.bitPtr; - - var result = this.bytes.subarray(bytePtr, bytePtr + n); - - if (movePointers) { - this.bytePtr += n; - } - - return result; -}; - - -/** - * @param {number} n The number of bytes to read. - * @return {Uint8Array} The subarray. - */ -bitjs.io.BitStream.prototype.readBytes = function(n) { - return this.peekBytes(n, true); -}; - - -/** - * This object allows you to peek and consume bytes as numbers and strings - * out of an ArrayBuffer. In this buffer, everything must be byte-aligned. - * - * @param {ArrayBuffer} ab The ArrayBuffer object. - * @param {number=} opt_offset The offset into the ArrayBuffer - * @param {number=} opt_length The length of this BitStream - * @constructor - */ -bitjs.io.ByteStream = function(ab, opt_offset, opt_length) { - var offset = opt_offset || 0; - var length = opt_length || ab.byteLength; - this.bytes = new Uint8Array(ab, offset, length); - this.ptr = 0; -}; - - -/** - * Peeks at the next n bytes as an unsigned number but does not advance the - * pointer - * TODO: This apparently cannot read more than 4 bytes as a number? - * @param {number} n The number of bytes to peek at. - * @return {number} The n bytes interpreted as an unsigned number. - */ -bitjs.io.ByteStream.prototype.peekNumber = function(n) { - // TODO: return error if n would go past the end of the stream? - if (n <= 0 || typeof n != typeof 1) - return -1; - - var result = 0; - // read from last byte to first byte and roll them in - var curByte = this.ptr + n - 1; - while (curByte >= this.ptr) { - result <<= 8; - result |= this.bytes[curByte]; - --curByte; - } - return result; -}; - - -/** - * Returns the next n bytes as an unsigned number (or -1 on error) - * and advances the stream pointer n bytes. - * @param {number} n The number of bytes to read. - * @return {number} The n bytes interpreted as an unsigned number. - */ -bitjs.io.ByteStream.prototype.readNumber = function(n) { - var num = this.peekNumber( n ); - this.ptr += n; - return num; -}; - - -/** - * Returns the next n bytes as a signed number but does not advance the - * pointer. - * @param {number} n The number of bytes to read. - * @return {number} The bytes interpreted as a signed number. - */ -bitjs.io.ByteStream.prototype.peekSignedNumber = function(n) { - var num = this.peekNumber(n); - var HALF = Math.pow(2, (n * 8) - 1); - var FULL = HALF * 2; - - if (num >= HALF) num -= FULL; - - return num; -}; - - -/** - * Returns the next n bytes as a signed number and advances the stream pointer. - * @param {number} n The number of bytes to read. - * @return {number} The bytes interpreted as a signed number. - */ -bitjs.io.ByteStream.prototype.readSignedNumber = function(n) { - var num = this.peekSignedNumber(n); - this.ptr += n; - return num; -}; - - -/** - * This returns n bytes as a sub-array, advancing the pointer if movePointers - * is true. - * @param {number} n The number of bytes to read. - * @param {boolean} movePointers Whether to move the pointers. - * @return {Uint8Array} The subarray. - */ -bitjs.io.ByteStream.prototype.peekBytes = function(n, movePointers) { - if (n <= 0 || typeof n != typeof 1) { - return null; - } - - var result = this.bytes.subarray(this.ptr, this.ptr + n); - - if (movePointers) { - this.ptr += n; - } - - return result; -}; - - -/** - * Reads the next n bytes as a sub-array. - * @param {number} n The number of bytes to read. - * @return {Uint8Array} The subarray. - */ -bitjs.io.ByteStream.prototype.readBytes = function(n) { - return this.peekBytes(n, true); -}; - - -/** - * Peeks at the next n bytes as a string but does not advance the pointer. - * @param {number} n The number of bytes to peek at. - * @return {string} The next n bytes as a string. - */ -bitjs.io.ByteStream.prototype.peekString = function(n) { - if (n <= 0 || typeof n != typeof 1) { - return ""; - } - - var result = ""; - for (var p = this.ptr, end = this.ptr + n; p < end; ++p) { - result += String.fromCharCode(this.bytes[p]); - } - return result; -}; - - -/** - * Returns the next n bytes as an ASCII string and advances the stream pointer - * n bytes. - * @param {number} n The number of bytes to read. - * @return {string} The next n bytes as a string. - */ -bitjs.io.ByteStream.prototype.readString = function(n) { - var strToReturn = this.peekString(n); - this.ptr += n; - return strToReturn; -}; - - -/** - * A write-only Byte buffer which uses a Uint8 Typed Array as a backing store. - * @param {number} numBytes The number of bytes to allocate. - * @constructor - */ -bitjs.io.ByteBuffer = function(numBytes) { - if (typeof numBytes != typeof 1 || numBytes <= 0) { - throw "Error! ByteBuffer initialized with '" + numBytes + "'"; - } - this.data = new Uint8Array(numBytes); - this.ptr = 0; -}; - - -/** - * @param {number} b The byte to insert. - */ -bitjs.io.ByteBuffer.prototype.insertByte = function(b) { - // TODO: throw if byte is invalid? - this.data[this.ptr++] = b; -}; - - -/** - * @param {Array.|Uint8Array|Int8Array} bytes The bytes to insert. - */ -bitjs.io.ByteBuffer.prototype.insertBytes = function(bytes) { - // TODO: throw if bytes is invalid? - this.data.set(bytes, this.ptr); - this.ptr += bytes.length; -}; - - -/** - * Writes an unsigned number into the next n bytes. If the number is too large - * to fit into n bytes or is negative, an error is thrown. - * @param {number} num The unsigned number to write. - * @param {number} numBytes The number of bytes to write the number into. - */ -bitjs.io.ByteBuffer.prototype.writeNumber = function(num, numBytes) { - if (numBytes < 1) { - throw 'Trying to write into too few bytes: ' + numBytes; - } - if (num < 0) { - throw 'Trying to write a negative number (' + num + - ') as an unsigned number to an ArrayBuffer'; - } - if (num > (Math.pow(2, numBytes * 8) - 1)) { - throw 'Trying to write ' + num + ' into only ' + numBytes + ' bytes'; - } - - // Roll 8-bits at a time into an array of bytes. - var bytes = []; - while (numBytes-- > 0) { - var eightBits = num & 255; - bytes.push(eightBits); - num >>= 8; - } - - this.insertBytes(bytes); -}; - - -/** - * Writes a signed number into the next n bytes. If the number is too large - * to fit into n bytes, an error is thrown. - * @param {number} num The signed number to write. - * @param {number} numBytes The number of bytes to write the number into. - */ -bitjs.io.ByteBuffer.prototype.writeSignedNumber = function(num, numBytes) { - if (numBytes < 1) { - throw 'Trying to write into too few bytes: ' + numBytes; - } - - var HALF = Math.pow(2, (numBytes * 8) - 1); - if (num >= HALF || num < -HALF) { - throw 'Trying to write ' + num + ' into only ' + numBytes + ' bytes'; - } - - // Roll 8-bits at a time into an array of bytes. - var bytes = []; - while (numBytes-- > 0) { - var eightBits = num & 255; - bytes.push(eightBits); - num >>= 8; - } - - this.insertBytes(bytes); -}; - - -/** - * @param {string} str The ASCII string to write. - */ -bitjs.io.ByteBuffer.prototype.writeASCIIString = function(str) { - for (var i = 0; i < str.length; ++i) { - var curByte = str.charCodeAt(i); - if (curByte < 0 || curByte > 255) { - throw 'Trying to write a non-ASCII string!'; - } - this.insertByte(curByte); - } -}; - -})(); diff --git a/static/cbr.js/bitjs/unrar.js b/static/cbr.js/bitjs/unrar.js deleted file mode 100644 index 15273cd8..00000000 --- a/static/cbr.js/bitjs/unrar.js +++ /dev/null @@ -1,913 +0,0 @@ -/** - * unrar.js - * - * Copyright(c) 2011 Google Inc. - * Copyright(c) 2011 antimatter15 - * - * Reference Documentation: - * - * http://kthoom.googlecode.com/hg/docs/unrar.html - */ - -// This file expects to be invoked as a Worker (see onmessage below). -importScripts('io.js'); -importScripts('archive.js'); - -// Progress variables. -var currentFilename = ""; -var currentFileNumber = 0; -var currentBytesUnarchivedInFile = 0; -var currentBytesUnarchived = 0; -var totalUncompressedBytesInArchive = 0; -var totalFilesInArchive = 0; - -// Helper functions. -var info = function(str) { - postMessage(new bitjs.archive.UnarchiveInfoEvent(str)); -}; -var err = function(str) { - postMessage(new bitjs.archive.UnarchiveErrorEvent(str)); -}; -var postProgress = function() { - postMessage(new bitjs.archive.UnarchiveProgressEvent( - currentFilename, - currentFileNumber, - currentBytesUnarchivedInFile, - currentBytesUnarchived, - totalUncompressedBytesInArchive, - totalFilesInArchive)); -}; - -// shows a byte value as its hex representation -var nibble = "0123456789ABCDEF"; -var byteValueToHexString = function(num) { - return nibble[num>>4] + nibble[num&0xF]; -}; -var twoByteValueToHexString = function(num) { - return nibble[(num>>12)&0xF] + nibble[(num>>8)&0xF] + nibble[(num>>4)&0xF] + nibble[num&0xF]; -}; - - -// Volume Types -var MARK_HEAD = 0x72, - MAIN_HEAD = 0x73, - FILE_HEAD = 0x74, - COMM_HEAD = 0x75, - AV_HEAD = 0x76, - SUB_HEAD = 0x77, - PROTECT_HEAD = 0x78, - SIGN_HEAD = 0x79, - NEWSUB_HEAD = 0x7a, - ENDARC_HEAD = 0x7b; - -// bstream is a bit stream -var RarVolumeHeader = function(bstream) { - - var headPos = bstream.bytePtr; - // byte 1,2 - info("Rar Volume Header @"+bstream.bytePtr); - - this.crc = bstream.readBits(16); - info(" crc=" + this.crc); - - // byte 3 - this.headType = bstream.readBits(8); - info(" headType=" + this.headType); - - // Get flags - // bytes 4,5 - this.flags = {}; - this.flags.value = bstream.peekBits(16); - - info(" flags=" + twoByteValueToHexString(this.flags.value)); - switch (this.headType) { - case MAIN_HEAD: - this.flags.MHD_VOLUME = !!bstream.readBits(1); - this.flags.MHD_COMMENT = !!bstream.readBits(1); - this.flags.MHD_LOCK = !!bstream.readBits(1); - this.flags.MHD_SOLID = !!bstream.readBits(1); - this.flags.MHD_PACK_COMMENT = !!bstream.readBits(1); - this.flags.MHD_NEWNUMBERING = this.flags.MHD_PACK_COMMENT; - this.flags.MHD_AV = !!bstream.readBits(1); - this.flags.MHD_PROTECT = !!bstream.readBits(1); - this.flags.MHD_PASSWORD = !!bstream.readBits(1); - this.flags.MHD_FIRSTVOLUME = !!bstream.readBits(1); - this.flags.MHD_ENCRYPTVER = !!bstream.readBits(1); - bstream.readBits(6); // unused - break; - case FILE_HEAD: - this.flags.LHD_SPLIT_BEFORE = !!bstream.readBits(1); // 0x0001 - this.flags.LHD_SPLIT_AFTER = !!bstream.readBits(1); // 0x0002 - this.flags.LHD_PASSWORD = !!bstream.readBits(1); // 0x0004 - this.flags.LHD_COMMENT = !!bstream.readBits(1); // 0x0008 - this.flags.LHD_SOLID = !!bstream.readBits(1); // 0x0010 - bstream.readBits(3); // unused - this.flags.LHD_LARGE = !!bstream.readBits(1); // 0x0100 - this.flags.LHD_UNICODE = !!bstream.readBits(1); // 0x0200 - this.flags.LHD_SALT = !!bstream.readBits(1); // 0x0400 - this.flags.LHD_VERSION = !!bstream.readBits(1); // 0x0800 - this.flags.LHD_EXTTIME = !!bstream.readBits(1); // 0x1000 - this.flags.LHD_EXTFLAGS = !!bstream.readBits(1); // 0x2000 - bstream.readBits(2); // unused - info(" LHD_SPLIT_BEFORE = " + this.flags.LHD_SPLIT_BEFORE); - break; - default: - bstream.readBits(16); - } - - // byte 6,7 - this.headSize = bstream.readBits(16); - info(" headSize=" + this.headSize); - switch (this.headType) { - case MAIN_HEAD: - this.highPosAv = bstream.readBits(16); - this.posAv = bstream.readBits(32); - if (this.flags.MHD_ENCRYPTVER) { - this.encryptVer = bstream.readBits(8); - } - info("Found MAIN_HEAD with highPosAv=" + this.highPosAv + ", posAv=" + this.posAv); - break; - case FILE_HEAD: - this.packSize = bstream.readBits(32); - this.unpackedSize = bstream.readBits(32); - this.hostOS = bstream.readBits(8); - this.fileCRC = bstream.readBits(32); - this.fileTime = bstream.readBits(32); - this.unpVer = bstream.readBits(8); - this.method = bstream.readBits(8); - this.nameSize = bstream.readBits(16); - this.fileAttr = bstream.readBits(32); - - if (this.flags.LHD_LARGE) { - info("Warning: Reading in LHD_LARGE 64-bit size values"); - this.HighPackSize = bstream.readBits(32); - this.HighUnpSize = bstream.readBits(32); - } else { - this.HighPackSize = 0; - this.HighUnpSize = 0; - if (this.unpackedSize == 0xffffffff) { - this.HighUnpSize = 0x7fffffff - this.unpackedSize = 0xffffffff; - } - } - this.fullPackSize = 0; - this.fullUnpackSize = 0; - this.fullPackSize |= this.HighPackSize; - this.fullPackSize <<= 32; - this.fullPackSize |= this.packSize; - - // read in filename - - this.filename = bstream.readBytes(this.nameSize); - for (var _i = 0, _s = ''; _i < this.filename.length; _i++) { - _s += String.fromCharCode(this.filename[_i]); - } - - this.filename = _s; - - if (this.flags.LHD_SALT) { - info("Warning: Reading in 64-bit salt value"); - this.salt = bstream.readBits(64); // 8 bytes - } - - if (this.flags.LHD_EXTTIME) { - // 16-bit flags - var extTimeFlags = bstream.readBits(16); - - // this is adapted straight out of arcread.cpp, Archive::ReadHeader() - for (var I = 0; I < 4; ++I) { - var rmode = extTimeFlags >> ((3-I)*4); - if ((rmode & 8)==0) - continue; - if (I!=0) - bstream.readBits(16); - var count = (rmode&3); - for (var J = 0; J < count; ++J) - bstream.readBits(8); - } - } - - if (this.flags.LHD_COMMENT) { - info("Found a LHD_COMMENT"); - } - - - while(headPos + this.headSize > bstream.bytePtr) bstream.readBits(1); - - info("Found FILE_HEAD with packSize=" + this.packSize + ", unpackedSize= " + this.unpackedSize + ", hostOS=" + this.hostOS + ", unpVer=" + this.unpVer + ", method=" + this.method + ", filename=" + this.filename); - - break; - default: - info("Found a header of type 0x" + byteValueToHexString(this.headType)); - // skip the rest of the header bytes (for now) - bstream.readBytes( this.headSize - 7 ); - break; - } -}; - -var BLOCK_LZ = 0, - BLOCK_PPM = 1; - -var rLDecode = [0,1,2,3,4,5,6,7,8,10,12,14,16,20,24,28,32,40,48,56,64,80,96,112,128,160,192,224], - rLBits = [0,0,0,0,0,0,0,0,1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5], - rDBitLengthCounts = [4,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,14,0,12], - rSDDecode = [0,4,8,16,32,64,128,192], - rSDBits = [2,2,3, 4, 5, 6, 6, 6]; - -var rDDecode = [0, 1, 2, 3, 4, 6, 8, 12, 16, 24, 32, - 48, 64, 96, 128, 192, 256, 384, 512, 768, 1024, 1536, 2048, 3072, - 4096, 6144, 8192, 12288, 16384, 24576, 32768, 49152, 65536, 98304, - 131072, 196608, 262144, 327680, 393216, 458752, 524288, 589824, - 655360, 720896, 786432, 851968, 917504, 983040]; - -var rDBits = [0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, - 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 14, 14, - 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16]; - -var rLOW_DIST_REP_COUNT = 16; - -var rNC = 299, - rDC = 60, - rLDC = 17, - rRC = 28, - rBC = 20, - rHUFF_TABLE_SIZE = (rNC+rDC+rRC+rLDC); - -var UnpBlockType = BLOCK_LZ; -var UnpOldTable = new Array(rHUFF_TABLE_SIZE); - -var BD = { //bitdecode - DecodeLen: new Array(16), - DecodePos: new Array(16), - DecodeNum: new Array(rBC) -}; -var LD = { //litdecode - DecodeLen: new Array(16), - DecodePos: new Array(16), - DecodeNum: new Array(rNC) -}; -var DD = { //distdecode - DecodeLen: new Array(16), - DecodePos: new Array(16), - DecodeNum: new Array(rDC) -}; -var LDD = { //low dist decode - DecodeLen: new Array(16), - DecodePos: new Array(16), - DecodeNum: new Array(rLDC) -}; -var RD = { //rep decode - DecodeLen: new Array(16), - DecodePos: new Array(16), - DecodeNum: new Array(rRC) -}; - -var rBuffer; - -// read in Huffman tables for RAR -function RarReadTables(bstream) { - var BitLength = new Array(rBC), - Table = new Array(rHUFF_TABLE_SIZE); - - // before we start anything we need to get byte-aligned - bstream.readBits( (8 - bstream.bitPtr) & 0x7 ); - - if (bstream.readBits(1)) { - info("Error! PPM not implemented yet"); - return; - } - - if (!bstream.readBits(1)) { //discard old table - for (var i = UnpOldTable.length; i--;) UnpOldTable[i] = 0; - } - - // read in bit lengths - for (var I = 0; I < rBC; ++I) { - - var Length = bstream.readBits(4); - if (Length == 15) { - var ZeroCount = bstream.readBits(4); - if (ZeroCount == 0) { - BitLength[I] = 15; - } - else { - ZeroCount += 2; - while (ZeroCount-- > 0 && I < rBC) - BitLength[I++] = 0; - --I; - } - } - else { - BitLength[I] = Length; - } - } - - // now all 20 bit lengths are obtained, we construct the Huffman Table: - - RarMakeDecodeTables(BitLength, 0, BD, rBC); - - var TableSize = rHUFF_TABLE_SIZE; - //console.log(DecodeLen, DecodePos, DecodeNum); - for (var i = 0; i < TableSize;) { - var num = RarDecodeNumber(bstream, BD); - if (num < 16) { - Table[i] = (num + UnpOldTable[i]) & 0xf; - i++; - } else if(num < 18) { - var N = (num == 16) ? (bstream.readBits(3) + 3) : (bstream.readBits(7) + 11); - - while (N-- > 0 && i < TableSize) { - Table[i] = Table[i - 1]; - i++; - } - } else { - var N = (num == 18) ? (bstream.readBits(3) + 3) : (bstream.readBits(7) + 11); - - while (N-- > 0 && i < TableSize) { - Table[i++] = 0; - } - } - } - - RarMakeDecodeTables(Table, 0, LD, rNC); - RarMakeDecodeTables(Table, rNC, DD, rDC); - RarMakeDecodeTables(Table, rNC + rDC, LDD, rLDC); - RarMakeDecodeTables(Table, rNC + rDC + rLDC, RD, rRC); - - for (var i = UnpOldTable.length; i--;) { - UnpOldTable[i] = Table[i]; - } - return true; -} - - -function RarDecodeNumber(bstream, dec) { - var DecodeLen = dec.DecodeLen, DecodePos = dec.DecodePos, DecodeNum = dec.DecodeNum; - var bitField = bstream.getBits() & 0xfffe; - //some sort of rolled out binary search - var bits = ((bitField < DecodeLen[8])? - ((bitField < DecodeLen[4])? - ((bitField < DecodeLen[2])? - ((bitField < DecodeLen[1])?1:2) - :((bitField < DecodeLen[3])?3:4)) - :(bitField < DecodeLen[6])? - ((bitField < DecodeLen[5])?5:6) - :((bitField < DecodeLen[7])?7:8)) - :((bitField < DecodeLen[12])? - ((bitField < DecodeLen[10])? - ((bitField < DecodeLen[9])?9:10) - :((bitField < DecodeLen[11])?11:12)) - :(bitField < DecodeLen[14])? - ((bitField < DecodeLen[13])?13:14) - :15)); - bstream.readBits(bits); - var N = DecodePos[bits] + ((bitField - DecodeLen[bits -1]) >>> (16 - bits)); - - return DecodeNum[N]; -} - - - -function RarMakeDecodeTables(BitLength, offset, dec, size) { - var DecodeLen = dec.DecodeLen, DecodePos = dec.DecodePos, DecodeNum = dec.DecodeNum; - var LenCount = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0], - TmpPos = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0], - N = 0, M = 0; - for (var i = DecodeNum.length; i--;) DecodeNum[i] = 0; - for (var i = 0; i < size; i++) { - LenCount[BitLength[i + offset] & 0xF]++; - } - LenCount[0] = 0; - TmpPos[0] = 0; - DecodePos[0] = 0; - DecodeLen[0] = 0; - - for (var I = 1; I < 16; ++I) { - N = 2 * (N+LenCount[I]); - M = (N << (15-I)); - if (M > 0xFFFF) - M = 0xFFFF; - DecodeLen[I] = M; - DecodePos[I] = DecodePos[I-1] + LenCount[I-1]; - TmpPos[I] = DecodePos[I]; - } - for (I = 0; I < size; ++I) - if (BitLength[I + offset] != 0) - DecodeNum[ TmpPos[ BitLength[offset + I] & 0xF ]++] = I; - -} - -// TODO: implement -function Unpack15(bstream, Solid) { - info("ERROR! RAR 1.5 compression not supported"); -} - -function Unpack20(bstream, Solid) { - var destUnpSize = rBuffer.data.length; - var oldDistPtr = 0; - - RarReadTables20(bstream); - while (destUnpSize > rBuffer.ptr) { - var num = RarDecodeNumber(bstream, LD); - if (num < 256) { - rBuffer.insertByte(num); - continue; - } - if (num > 269) { - var Length = rLDecode[num -= 270] + 3; - if ((Bits = rLBits[num]) > 0) { - Length += bstream.readBits(Bits); - } - var DistNumber = RarDecodeNumber(bstream, DD); - var Distance = rDDecode[DistNumber] + 1; - if ((Bits = rDBits[DistNumber]) > 0) { - Distance += bstream.readBits(Bits); - } - if (Distance >= 0x2000) { - Length++; - if(Distance >= 0x40000) Length++; - } - lastLength = Length; - lastDist = rOldDist[oldDistPtr++ & 3] = Distance; - RarCopyString(Length, Distance); - continue; - } - if (num == 269) { - RarReadTables20(bstream); - - RarUpdateProgress() - - continue; - } - if (num == 256) { - lastDist = rOldDist[oldDistPtr++ & 3] = lastDist; - RarCopyString(lastLength, lastDist); - continue; - } - if (num < 261) { - var Distance = rOldDist[(oldDistPtr - (num - 256)) & 3]; - var LengthNumber = RarDecodeNumber(bstream, RD); - var Length = rLDecode[LengthNumber] +2; - if ((Bits = rLBits[LengthNumber]) > 0) { - Length += bstream.readBits(Bits); - } - if (Distance >= 0x101) { - Length++; - if (Distance >= 0x2000) { - Length++ - if (Distance >= 0x40000) Length++; - } - } - lastLength = Length; - lastDist = rOldDist[oldDistPtr++ & 3] = Distance; - RarCopyString(Length, Distance); - continue; - } - if (num < 270) { - var Distance = rSDDecode[num -= 261] + 1; - if ((Bits = rSDBits[num]) > 0) { - Distance += bstream.readBits(Bits); - } - lastLength = 2; - lastDist = rOldDist[oldDistPtr++ & 3] = Distance; - RarCopyString(2, Distance); - continue; - } - - } - RarUpdateProgress() -} - -function RarUpdateProgress() { - var change = rBuffer.ptr - currentBytesUnarchivedInFile; - currentBytesUnarchivedInFile = rBuffer.ptr; - currentBytesUnarchived += change; - postProgress(); -} - - -var rNC20 = 298, - rDC20 = 48, - rRC20 = 28, - rBC20 = 19, - rMC20 = 257; - -var UnpOldTable20 = new Array(rMC20 * 4); - -function RarReadTables20(bstream) { - var BitLength = new Array(rBC20); - var Table = new Array(rMC20 * 4); - var TableSize, N, I; - var AudioBlock = bstream.readBits(1); - if (!bstream.readBits(1)) - for (var i = UnpOldTable20.length; i--;) UnpOldTable20[i] = 0; - TableSize = rNC20 + rDC20 + rRC20; - for (var I = 0; I < rBC20; I++) - BitLength[I] = bstream.readBits(4); - RarMakeDecodeTables(BitLength, 0, BD, rBC20); - I = 0; - while (I < TableSize) { - var num = RarDecodeNumber(bstream, BD); - if (num < 16) { - Table[I] = num + UnpOldTable20[I] & 0xf; - I++; - } else if(num == 16) { - N = bstream.readBits(2) + 3; - while (N-- > 0 && I < TableSize) { - Table[I] = Table[I - 1]; - I++; - } - } else { - if (num == 17) { - N = bstream.readBits(3) + 3; - } else { - N = bstream.readBits(7) + 11; - } - while (N-- > 0 && I < TableSize) { - Table[I++] = 0; - } - } - } - RarMakeDecodeTables(Table, 0, LD, rNC20); - RarMakeDecodeTables(Table, rNC20, DD, rDC20); - RarMakeDecodeTables(Table, rNC20 + rDC20, RD, rRC20); - for (var i = UnpOldTable20.length; i--;) UnpOldTable20[i] = Table[i]; -} - -var lowDistRepCount = 0, prevLowDist = 0; - -var rOldDist = [0,0,0,0]; -var lastDist; -var lastLength; - - -function Unpack29(bstream, Solid) { - // lazy initialize rDDecode and rDBits - - var DDecode = new Array(rDC); - var DBits = new Array(rDC); - - var Dist=0,BitLength=0,Slot=0; - - for (var I = 0; I < rDBitLengthCounts.length; I++,BitLength++) { - for (var J = 0; J < rDBitLengthCounts[I]; J++,Slot++,Dist+=(1<= 271) { - var Length = rLDecode[num -= 271] + 3; - if ((Bits = rLBits[num]) > 0) { - Length += bstream.readBits(Bits); - } - var DistNumber = RarDecodeNumber(bstream, DD); - var Distance = DDecode[DistNumber]+1; - if ((Bits = DBits[DistNumber]) > 0) { - if (DistNumber > 9) { - if (Bits > 4) { - Distance += ((bstream.getBits() >>> (20 - Bits)) << 4); - bstream.readBits(Bits - 4); - //todo: check this - } - if (lowDistRepCount > 0) { - lowDistRepCount--; - Distance += prevLowDist; - } else { - var LowDist = RarDecodeNumber(bstream, LDD); - if (LowDist == 16) { - lowDistRepCount = rLOW_DIST_REP_COUNT - 1; - Distance += prevLowDist; - } else { - Distance += LowDist; - prevLowDist = LowDist; - } - } - } else { - Distance += bstream.readBits(Bits); - } - } - if (Distance >= 0x2000) { - Length++; - if (Distance >= 0x40000) { - Length++; - } - } - RarInsertOldDist(Distance); - RarInsertLastMatch(Length, Distance); - RarCopyString(Length, Distance); - continue; - } - if (num == 256) { - if (!RarReadEndOfBlock(bstream)) break; - - continue; - } - if (num == 257) { - //console.log("READVMCODE"); - if (!RarReadVMCode(bstream)) break; - continue; - } - if (num == 258) { - if (lastLength != 0) { - RarCopyString(lastLength, lastDist); - } - continue; - } - if (num < 263) { - var DistNum = num - 259; - var Distance = rOldDist[DistNum]; - - for (var I = DistNum; I > 0; I--) { - rOldDist[I] = rOldDist[I-1]; - } - rOldDist[0] = Distance; - - var LengthNumber = RarDecodeNumber(bstream, RD); - var Length = rLDecode[LengthNumber] + 2; - if ((Bits = rLBits[LengthNumber]) > 0) { - Length += bstream.readBits(Bits); - } - RarInsertLastMatch(Length, Distance); - RarCopyString(Length, Distance); - continue; - } - if (num < 272) { - var Distance = rSDDecode[num -= 263] + 1; - if ((Bits = rSDBits[num]) > 0) { - Distance += bstream.readBits(Bits); - } - RarInsertOldDist(Distance); - RarInsertLastMatch(2, Distance); - RarCopyString(2, Distance); - continue; - } - - } - RarUpdateProgress() -} - -function RarReadEndOfBlock(bstream) { - - RarUpdateProgress() - - - var NewTable = false, NewFile = false; - if (bstream.readBits(1)) { - NewTable = true; - } else { - NewFile = true; - NewTable = !!bstream.readBits(1); - } - //tablesRead = !NewTable; - return !(NewFile || NewTable && !RarReadTables(bstream)); -} - - -function RarReadVMCode(bstream) { - var FirstByte = bstream.readBits(8); - var Length = (FirstByte & 7) + 1; - if (Length == 7) { - Length = bstream.readBits(8) + 7; - } else if(Length == 8) { - Length = bstream.readBits(16); - } - var vmCode = []; - for(var I = 0; I < Length; I++) { - //do something here with cheking readbuf - vmCode.push(bstream.readBits(8)); - } - return RarAddVMCode(FirstByte, vmCode, Length); -} - -function RarAddVMCode(firstByte, vmCode, length) { - //console.log(vmCode); - if (vmCode.length > 0) { - info("Error! RarVM not supported yet!"); - } - return true; -} - -function RarInsertLastMatch(length, distance) { - lastDist = distance; - lastLength = length; -} - -function RarInsertOldDist(distance) { - rOldDist.splice(3,1); - rOldDist.splice(0,0,distance); -} - -//this is the real function, the other one is for debugging -function RarCopyString(length, distance) { - var destPtr = rBuffer.ptr - distance; - if(destPtr < 0){ - var l = rOldBuffers.length; - while(destPtr < 0){ - destPtr = rOldBuffers[--l].data.length + destPtr; - } - //TODO: lets hope that it never needs to read beyond file boundaries - while(length--) rBuffer.insertByte(rOldBuffers[l].data[destPtr++]); - - } - if (length > distance) { - while(length--) rBuffer.insertByte(rBuffer.data[destPtr++]); - } else { - rBuffer.insertBytes(rBuffer.data.subarray(destPtr, destPtr + length)); - } - -} - -var rOldBuffers = [] -// v must be a valid RarVolume -function unpack(v) { - - // TODO: implement what happens when unpVer is < 15 - var Ver = v.header.unpVer <= 15 ? 15 : v.header.unpVer, - Solid = v.header.LHD_SOLID, - bstream = new bitjs.io.BitStream(v.fileData.buffer, true /* rtl */, v.fileData.byteOffset, v.fileData.byteLength ); - - rBuffer = new bitjs.io.ByteBuffer(v.header.unpackedSize); - - info("Unpacking "+v.filename+" RAR v"+Ver); - - switch(Ver) { - case 15: // rar 1.5 compression - Unpack15(bstream, Solid); - break; - case 20: // rar 2.x compression - case 26: // files larger than 2GB - Unpack20(bstream, Solid); - break; - case 29: // rar 3.x compression - case 36: // alternative hash - Unpack29(bstream, Solid); - break; - } // switch(method) - - rOldBuffers.push(rBuffer); - //TODO: clear these old buffers when there's over 4MB of history - return rBuffer.data; -} - -// bstream is a bit stream -var RarLocalFile = function(bstream) { - - this.header = new RarVolumeHeader(bstream); - this.filename = this.header.filename; - - if (this.header.headType != FILE_HEAD && this.header.headType != ENDARC_HEAD) { - this.isValid = false; - info("Error! RAR Volume did not include a FILE_HEAD header "); - } - else { - // read in the compressed data - this.fileData = null; - if (this.header.packSize > 0) { - this.fileData = bstream.readBytes(this.header.packSize); - this.isValid = true; - } - } -}; - -RarLocalFile.prototype.unrar = function() { - - if (!this.header.flags.LHD_SPLIT_BEFORE) { - // unstore file - if (this.header.method == 0x30) { - info("Unstore "+this.filename); - this.isValid = true; - - currentBytesUnarchivedInFile += this.fileData.length; - currentBytesUnarchived += this.fileData.length; - - // Create a new buffer and copy it over. - var len = this.header.packSize; - var newBuffer = new bitjs.io.ByteBuffer(len); - newBuffer.insertBytes(this.fileData); - this.fileData = newBuffer.data; - } else { - this.isValid = true; - this.fileData = unpack(this); - } - } -} - -var unrar = function(arrayBuffer) { - currentFilename = ""; - currentFileNumber = 0; - currentBytesUnarchivedInFile = 0; - currentBytesUnarchived = 0; - totalUncompressedBytesInArchive = 0; - totalFilesInArchive = 0; - - postMessage(new bitjs.archive.UnarchiveStartEvent()); - var bstream = new bitjs.io.BitStream(arrayBuffer, false /* rtl */); - - var header = new RarVolumeHeader(bstream); - if (header.crc == 0x6152 && - header.headType == 0x72 && - header.flags.value == 0x1A21 && - header.headSize == 7) { - info("Found RAR signature"); - - var mhead = new RarVolumeHeader(bstream); - if (mhead.headType != MAIN_HEAD) { - info("Error! RAR did not include a MAIN_HEAD header"); - } - else { - var localFiles = [], - localFile = null; - do { - try { - localFile = new RarLocalFile(bstream); - info("RAR localFile isValid=" + localFile.isValid + ", volume packSize=" + localFile.header.packSize); - if (localFile && localFile.isValid && localFile.header.packSize > 0) { - totalUncompressedBytesInArchive += localFile.header.unpackedSize; - localFiles.push(localFile); - } else if (localFile.header.packSize == 0 && localFile.header.unpackedSize == 0) { - localFile.isValid = true; - } - } catch(err) { - break; - } - //info("bstream" + bstream.bytePtr+"/"+bstream.bytes.length); - } while( localFile.isValid ); - totalFilesInArchive = localFiles.length; - - // now we have all information but things are unpacked - // TODO: unpack - localFiles = localFiles.sort(function(a,b) { - var aname = a.filename; - var bname = b.filename; - return aname > bname ? 1 : -1; - - // extract the number at the end of both filenames - /* - var aindex = aname.length, bindex = bname.length; - - // Find the last number character from the back of the filename. - while (aname[aindex-1] < '0' || aname[aindex-1] > '9') --aindex; - while (bname[bindex-1] < '0' || bname[bindex-1] > '9') --bindex; - - // Find the first number character from the back of the filename - while (aname[aindex-1] >= '0' && aname[aindex-1] <= '9') --aindex; - while (bname[bindex-1] >= '0' && bname[bindex-1] <= '9') --bindex; - - // parse them into numbers and return comparison - var anum = parseInt(aname.substr(aindex), 10), - bnum = parseInt(bname.substr(bindex), 10); - return bnum - anum;*/ - }); - - info(localFiles.map(function(a){return a.filename}).join(', ')); - for (var i = 0; i < localFiles.length; ++i) { - var localfile = localFiles[i]; - - // update progress - currentFilename = localfile.header.filename; - currentBytesUnarchivedInFile = 0; - - // actually do the unzipping - localfile.unrar(); - - if (localfile.isValid) { - postMessage(new bitjs.archive.UnarchiveExtractEvent(localfile)); - postProgress(); - } - } - - postProgress(); - } - } - else { - err("Invalid RAR file"); - } - postMessage(new bitjs.archive.UnarchiveFinishEvent()); -}; - -// event.data.file has the ArrayBuffer. -onmessage = function(event) { - var ab = event.data.file; - unrar(ab, true); -}; diff --git a/static/cbr.js/bitjs/untar.js b/static/cbr.js/bitjs/untar.js deleted file mode 100644 index 4eafbb32..00000000 --- a/static/cbr.js/bitjs/untar.js +++ /dev/null @@ -1,188 +0,0 @@ -/** - * untar.js - * - * Copyright(c) 2011 Google Inc. - * - * Reference Documentation: - * - * TAR format: http://www.gnu.org/software/automake/manual/tar/Standard.html - */ - -// This file expects to be invoked as a Worker (see onmessage below). -importScripts('io.js'); -importScripts('archive.js'); - -// Progress variables. -var currentFilename = ""; -var currentFileNumber = 0; -var currentBytesUnarchivedInFile = 0; -var currentBytesUnarchived = 0; -var totalUncompressedBytesInArchive = 0; -var totalFilesInArchive = 0; - -// Helper functions. -var info = function(str) { - postMessage(new bitjs.archive.UnarchiveInfoEvent(str)); -}; -var err = function(str) { - postMessage(new bitjs.archive.UnarchiveErrorEvent(str)); -}; -var postProgress = function() { - postMessage(new bitjs.archive.UnarchiveProgressEvent( - currentFilename, - currentFileNumber, - currentBytesUnarchivedInFile, - currentBytesUnarchived, - totalUncompressedBytesInArchive, - totalFilesInArchive)); -}; - -// Removes all characters from the first zero-byte in the string onwards. -var readCleanString = function(bstr, numBytes) { - var str = bstr.readString(numBytes); - var zIndex = str.indexOf(String.fromCharCode(0)); - return zIndex != -1 ? str.substr(0, zIndex) : str; -}; - -// takes a ByteStream and parses out the local file information -var TarLocalFile = function(bstream) { - this.isValid = false; - - // Read in the header block - this.name = readCleanString(bstream, 100); - this.mode = readCleanString(bstream, 8); - this.uid = readCleanString(bstream, 8); - this.gid = readCleanString(bstream, 8); - this.size = parseInt(readCleanString(bstream, 12), 8); - this.mtime = readCleanString(bstream, 12); - this.chksum = readCleanString(bstream, 8); - this.typeflag = readCleanString(bstream, 1); - this.linkname = readCleanString(bstream, 100); - this.maybeMagic = readCleanString(bstream, 6); - - if (this.maybeMagic == "ustar") { - this.version = readCleanString(bstream, 2); - this.uname = readCleanString(bstream, 32); - this.gname = readCleanString(bstream, 32); - this.devmajor = readCleanString(bstream, 8); - this.devminor = readCleanString(bstream, 8); - this.prefix = readCleanString(bstream, 155); - - if (this.prefix.length) { - this.name = this.prefix + this.name; - } - bstream.readBytes(12); // 512 - 500 - } else { - bstream.readBytes(255); // 512 - 257 - } - - // Done header, now rest of blocks are the file contents. - this.filename = this.name; - this.fileData = null; - - info("Untarring file '" + this.filename + "'"); - info(" size = " + this.size); - info(" typeflag = " + this.typeflag); - - // A regular file. - if (this.typeflag == 0) { - info(" This is a regular file."); - var sizeInBytes = parseInt(this.size); - this.fileData = new Uint8Array(bstream.bytes.buffer, bstream.ptr, this.size); - if (this.name.length > 0 && this.size > 0 && this.fileData && this.fileData.buffer) { - this.isValid = true; - } - - bstream.readBytes(this.size); - - // Round up to 512-byte blocks. - var remaining = 512 - this.size % 512; - if (remaining > 0 && remaining < 512) { - bstream.readBytes(remaining); - } - } else if (this.typeflag == 5) { - info(" This is a directory.") - } -}; - -// Takes an ArrayBuffer of a tar file in -// returns null on error -// returns an array of DecompressedFile objects on success -var untar = function(arrayBuffer) { - currentFilename = ""; - currentFileNumber = 0; - currentBytesUnarchivedInFile = 0; - currentBytesUnarchived = 0; - totalUncompressedBytesInArchive = 0; - totalFilesInArchive = 0; - - postMessage(new bitjs.archive.UnarchiveStartEvent()); - var bstream = new bitjs.io.ByteStream(arrayBuffer); - var localFiles = []; - - // While we don't encounter an empty block, keep making TarLocalFiles. - while (bstream.peekNumber(4) != 0) { - var oneLocalFile = new TarLocalFile(bstream); - if (oneLocalFile && oneLocalFile.isValid) { - localFiles.push(oneLocalFile); - totalUncompressedBytesInArchive += oneLocalFile.size; - } - } - totalFilesInArchive = localFiles.length; - - // got all local files, now sort them - localFiles.sort(function(a,b) { - var aname = a.filename; - var bname = b.filename; - return aname > bname ? 1 : -1; - - // extract the number at the end of both filenames - /* - var aname = a.filename; - var bname = b.filename; - var aindex = aname.length, bindex = bname.length; - - // Find the last number character from the back of the filename. - while (aname[aindex-1] < '0' || aname[aindex-1] > '9') --aindex; - while (bname[bindex-1] < '0' || bname[bindex-1] > '9') --bindex; - - // Find the first number character from the back of the filename - while (aname[aindex-1] >= '0' && aname[aindex-1] <= '9') --aindex; - while (bname[bindex-1] >= '0' && bname[bindex-1] <= '9') --bindex; - - // parse them into numbers and return comparison - var anum = parseInt(aname.substr(aindex), 10), - bnum = parseInt(bname.substr(bindex), 10); - return anum - bnum; - */ - }); - - // report # files and total length - if (localFiles.length > 0) { - postProgress(); - } - - // now do the shipping of each file - for (var i = 0; i < localFiles.length; ++i) { - var localfile = localFiles[i]; - info("Sending file '" + localfile.filename + "' up"); - - // update progress - currentFilename = localfile.filename; - currentFileNumber = i; - currentBytesUnarchivedInFile = localfile.size; - currentBytesUnarchived += localfile.size; - postMessage(new bitjs.archive.UnarchiveExtractEvent(localfile)); - postProgress(); - } - - postProgress(); - - postMessage(new bitjs.archive.UnarchiveFinishEvent()); -}; - -// event.data.file has the ArrayBuffer. -onmessage = function(event) { - var ab = event.data.file; - untar(ab); -}; diff --git a/static/cbr.js/bitjs/unzip.js b/static/cbr.js/bitjs/unzip.js deleted file mode 100644 index 1a656212..00000000 --- a/static/cbr.js/bitjs/unzip.js +++ /dev/null @@ -1,637 +0,0 @@ -/** - * unzip.js - * - * Copyright(c) 2011 Google Inc. - * Copyright(c) 2011 antimatter15 - * - * Reference Documentation: - * - * ZIP format: http://www.pkware.com/documents/casestudies/APPNOTE.TXT - * DEFLATE format: http://tools.ietf.org/html/rfc1951 - */ - -// This file expects to be invoked as a Worker (see onmessage below). -importScripts('io.js'); -importScripts('archive.js'); - -// Progress variables. -var currentFilename = ""; -var currentFileNumber = 0; -var currentBytesUnarchivedInFile = 0; -var currentBytesUnarchived = 0; -var totalUncompressedBytesInArchive = 0; -var totalFilesInArchive = 0; - -// Helper functions. -var info = function(str) { - postMessage(new bitjs.archive.UnarchiveInfoEvent(str)); -}; -var err = function(str) { - postMessage(new bitjs.archive.UnarchiveErrorEvent(str)); -}; -var postProgress = function() { - postMessage(new bitjs.archive.UnarchiveProgressEvent( - currentFilename, - currentFileNumber, - currentBytesUnarchivedInFile, - currentBytesUnarchived, - totalUncompressedBytesInArchive, - totalFilesInArchive)); -}; - -var zLocalFileHeaderSignature = 0x04034b50; -var zArchiveExtraDataSignature = 0x08064b50; -var zCentralFileHeaderSignature = 0x02014b50; -var zDigitalSignatureSignature = 0x05054b50; -var zEndOfCentralDirSignature = 0x06064b50; -var zEndOfCentralDirLocatorSignature = 0x07064b50; - -// takes a ByteStream and parses out the local file information -var ZipLocalFile = function(bstream) { - if (typeof bstream != typeof {} || !bstream.readNumber || typeof bstream.readNumber != typeof function(){}) { - return null; - } - - bstream.readNumber(4); // swallow signature - this.version = bstream.readNumber(2); - this.generalPurpose = bstream.readNumber(2); - this.compressionMethod = bstream.readNumber(2); - this.lastModFileTime = bstream.readNumber(2); - this.lastModFileDate = bstream.readNumber(2); - this.crc32 = bstream.readNumber(4); - this.compressedSize = bstream.readNumber(4); - this.uncompressedSize = bstream.readNumber(4); - this.fileNameLength = bstream.readNumber(2); - this.extraFieldLength = bstream.readNumber(2); - - this.filename = null; - if (this.fileNameLength > 0) { - this.filename = bstream.readString(this.fileNameLength); - } - - info("Zip Local File Header:"); - info(" version=" + this.version); - info(" general purpose=" + this.generalPurpose); - info(" compression method=" + this.compressionMethod); - info(" last mod file time=" + this.lastModFileTime); - info(" last mod file date=" + this.lastModFileDate); - info(" crc32=" + this.crc32); - info(" compressed size=" + this.compressedSize); - info(" uncompressed size=" + this.uncompressedSize); - info(" file name length=" + this.fileNameLength); - info(" extra field length=" + this.extraFieldLength); - info(" filename = '" + this.filename + "'"); - - this.extraField = null; - if (this.extraFieldLength > 0) { - this.extraField = bstream.readString(this.extraFieldLength); - info(" extra field=" + this.extraField); - } - - // read in the compressed data - this.fileData = null; - if (this.compressedSize > 0) { - this.fileData = new Uint8Array(bstream.bytes.buffer, bstream.ptr, this.compressedSize); - bstream.ptr += this.compressedSize; - } - - // TODO: deal with data descriptor if present (we currently assume no data descriptor!) - // "This descriptor exists only if bit 3 of the general purpose bit flag is set" - // But how do you figure out how big the file data is if you don't know the compressedSize - // from the header?!? - if ((this.generalPurpose & bitjs.BIT[3]) != 0) { - this.crc32 = bstream.readNumber(4); - this.compressedSize = bstream.readNumber(4); - this.uncompressedSize = bstream.readNumber(4); - } -}; - -// determine what kind of compressed data we have and decompress -ZipLocalFile.prototype.unzip = function() { - - // Zip Version 1.0, no compression (store only) - if (this.compressionMethod == 0 ) { - info("ZIP v"+this.version+", store only: " + this.filename + " (" + this.compressedSize + " bytes)"); - currentBytesUnarchivedInFile = this.compressedSize; - currentBytesUnarchived += this.compressedSize; - } - // version == 20, compression method == 8 (DEFLATE) - else if (this.compressionMethod == 8) { - info("ZIP v2.0, DEFLATE: " + this.filename + " (" + this.compressedSize + " bytes)"); - this.fileData = inflate(this.fileData, this.uncompressedSize); - } - else { - err("UNSUPPORTED VERSION/FORMAT: ZIP v" + this.version + ", compression method=" + this.compressionMethod + ": " + this.filename + " (" + this.compressedSize + " bytes)"); - this.fileData = null; - } -}; - - -// Takes an ArrayBuffer of a zip file in -// returns null on error -// returns an array of DecompressedFile objects on success -var unzip = function(arrayBuffer) { - postMessage(new bitjs.archive.UnarchiveStartEvent()); - - currentFilename = ""; - currentFileNumber = 0; - currentBytesUnarchivedInFile = 0; - currentBytesUnarchived = 0; - totalUncompressedBytesInArchive = 0; - totalFilesInArchive = 0; - currentBytesUnarchived = 0; - - var bstream = new bitjs.io.ByteStream(arrayBuffer); - // detect local file header signature or return null - if (bstream.peekNumber(4) == zLocalFileHeaderSignature) { - var localFiles = []; - // loop until we don't see any more local files - while (bstream.peekNumber(4) == zLocalFileHeaderSignature) { - var oneLocalFile = new ZipLocalFile(bstream); - // this should strip out directories/folders - if (oneLocalFile && oneLocalFile.uncompressedSize > 0 && oneLocalFile.fileData) { - localFiles.push(oneLocalFile); - totalUncompressedBytesInArchive += oneLocalFile.uncompressedSize; - } - } - totalFilesInArchive = localFiles.length; - - // got all local files, now sort them - localFiles.sort(function(a,b) { - var aname = a.filename; - var bname = b.filename; - return aname > bname ? 1 : -1; - - // extract the number at the end of both filenames - /* - var aname = a.filename; - var bname = b.filename; - var aindex = aname.length, bindex = bname.length; - - // Find the last number character from the back of the filename. - while (aname[aindex-1] < '0' || aname[aindex-1] > '9') --aindex; - while (bname[bindex-1] < '0' || bname[bindex-1] > '9') --bindex; - - // Find the first number character from the back of the filename - while (aname[aindex-1] >= '0' && aname[aindex-1] <= '9') --aindex; - while (bname[bindex-1] >= '0' && bname[bindex-1] <= '9') --bindex; - - // parse them into numbers and return comparison - var anum = parseInt(aname.substr(aindex), 10), - bnum = parseInt(bname.substr(bindex), 10); - return anum - bnum; - */ - }); - - // archive extra data record - if (bstream.peekNumber(4) == zArchiveExtraDataSignature) { - info(" Found an Archive Extra Data Signature"); - - // skipping this record for now - bstream.readNumber(4); - var archiveExtraFieldLength = bstream.readNumber(4); - bstream.readString(archiveExtraFieldLength); - } - - // central directory structure - // TODO: handle the rest of the structures (Zip64 stuff) - if (bstream.peekNumber(4) == zCentralFileHeaderSignature) { - info(" Found a Central File Header"); - - // read all file headers - while (bstream.peekNumber(4) == zCentralFileHeaderSignature) { - bstream.readNumber(4); // signature - bstream.readNumber(2); // version made by - bstream.readNumber(2); // version needed to extract - bstream.readNumber(2); // general purpose bit flag - bstream.readNumber(2); // compression method - bstream.readNumber(2); // last mod file time - bstream.readNumber(2); // last mod file date - bstream.readNumber(4); // crc32 - bstream.readNumber(4); // compressed size - bstream.readNumber(4); // uncompressed size - var fileNameLength = bstream.readNumber(2); // file name length - var extraFieldLength = bstream.readNumber(2); // extra field length - var fileCommentLength = bstream.readNumber(2); // file comment length - bstream.readNumber(2); // disk number start - bstream.readNumber(2); // internal file attributes - bstream.readNumber(4); // external file attributes - bstream.readNumber(4); // relative offset of local header - - bstream.readString(fileNameLength); // file name - bstream.readString(extraFieldLength); // extra field - bstream.readString(fileCommentLength); // file comment - } - } - - // digital signature - if (bstream.peekNumber(4) == zDigitalSignatureSignature) { - info(" Found a Digital Signature"); - - bstream.readNumber(4); - var sizeOfSignature = bstream.readNumber(2); - bstream.readString(sizeOfSignature); // digital signature data - } - - // report # files and total length - if (localFiles.length > 0) { - postProgress(); - } - - // now do the unzipping of each file - for (var i = 0; i < localFiles.length; ++i) { - var localfile = localFiles[i]; - - // update progress - currentFilename = localfile.filename; - currentFileNumber = i; - currentBytesUnarchivedInFile = 0; - - // actually do the unzipping - localfile.unzip(); - - if (localfile.fileData != null) { - postMessage(new bitjs.archive.UnarchiveExtractEvent(localfile)); - postProgress(); - } - } - postProgress(); - postMessage(new bitjs.archive.UnarchiveFinishEvent()); - } -} - -// returns a table of Huffman codes -// each entry's index is its code and its value is a JavaScript object -// containing {length: 6, symbol: X} -function getHuffmanCodes(bitLengths) { - // ensure bitLengths is an array containing at least one element - if (typeof bitLengths != typeof [] || bitLengths.length < 1) { - err("Error! getHuffmanCodes() called with an invalid array"); - return null; - } - - // Reference: http://tools.ietf.org/html/rfc1951#page-8 - var numLengths = bitLengths.length, - bl_count = [], - MAX_BITS = 1; - - // Step 1: count up how many codes of each length we have - for (var i = 0; i < numLengths; ++i) { - var length = bitLengths[i]; - // test to ensure each bit length is a positive, non-zero number - if (typeof length != typeof 1 || length < 0) { - err("bitLengths contained an invalid number in getHuffmanCodes(): " + length + " of type " + (typeof length)); - return null; - } - // increment the appropriate bitlength count - if (bl_count[length] == undefined) bl_count[length] = 0; - // a length of zero means this symbol is not participating in the huffman coding - if (length > 0) bl_count[length]++; - - if (length > MAX_BITS) MAX_BITS = length; - } - - // Step 2: Find the numerical value of the smallest code for each code length - var next_code = [], - code = 0; - for (var bits = 1; bits <= MAX_BITS; ++bits) { - var length = bits-1; - // ensure undefined lengths are zero - if (bl_count[length] == undefined) bl_count[length] = 0; - code = (code + bl_count[bits-1]) << 1; - next_code[bits] = code; - } - - // Step 3: Assign numerical values to all codes - var table = {}, tableLength = 0; - for (var n = 0; n < numLengths; ++n) { - var len = bitLengths[n]; - if (len != 0) { - table[next_code[len]] = { length: len, symbol: n }; //, bitstring: binaryValueToString(next_code[len],len) }; - tableLength++; - next_code[len]++; - } - } - table.maxLength = tableLength; - - return table; -} - -/* - The Huffman codes for the two alphabets are fixed, and are not - represented explicitly in the data. The Huffman code lengths - for the literal/length alphabet are: - - Lit Value Bits Codes - --------- ---- ----- - 0 - 143 8 00110000 through - 10111111 - 144 - 255 9 110010000 through - 111111111 - 256 - 279 7 0000000 through - 0010111 - 280 - 287 8 11000000 through - 11000111 -*/ -// fixed Huffman codes go from 7-9 bits, so we need an array whose index can hold up to 9 bits -var fixedHCtoLiteral = null; -var fixedHCtoDistance = null; -function getFixedLiteralTable() { - // create once - if (!fixedHCtoLiteral) { - var bitlengths = new Array(288); - for (var i = 0; i <= 143; ++i) bitlengths[i] = 8; - for (i = 144; i <= 255; ++i) bitlengths[i] = 9; - for (i = 256; i <= 279; ++i) bitlengths[i] = 7; - for (i = 280; i <= 287; ++i) bitlengths[i] = 8; - - // get huffman code table - fixedHCtoLiteral = getHuffmanCodes(bitlengths); - } - return fixedHCtoLiteral; -} -function getFixedDistanceTable() { - // create once - if (!fixedHCtoDistance) { - var bitlengths = new Array(32); - for (var i = 0; i < 32; ++i) { bitlengths[i] = 5; } - - // get huffman code table - fixedHCtoDistance = getHuffmanCodes(bitlengths); - } - return fixedHCtoDistance; -} - -// extract one bit at a time until we find a matching Huffman Code -// then return that symbol -function decodeSymbol(bstream, hcTable) { - var code = 0, len = 0; - var match = false; - - // loop until we match - for (;;) { - // read in next bit - var bit = bstream.readBits(1); - code = (code<<1) | bit; - ++len; - - // check against Huffman Code table and break if found - if (hcTable.hasOwnProperty(code) && hcTable[code].length == len) { - - break; - } - if (len > hcTable.maxLength) { - err("Bit stream out of sync, didn't find a Huffman Code, length was " + len + - " and table only max code length of " + hcTable.maxLength); - break; - } - } - return hcTable[code].symbol; -} - - -var CodeLengthCodeOrder = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15]; - /* - Extra Extra Extra - Code Bits Length(s) Code Bits Lengths Code Bits Length(s) - ---- ---- ------ ---- ---- ------- ---- ---- ------- - 257 0 3 267 1 15,16 277 4 67-82 - 258 0 4 268 1 17,18 278 4 83-98 - 259 0 5 269 2 19-22 279 4 99-114 - 260 0 6 270 2 23-26 280 4 115-130 - 261 0 7 271 2 27-30 281 5 131-162 - 262 0 8 272 2 31-34 282 5 163-194 - 263 0 9 273 3 35-42 283 5 195-226 - 264 0 10 274 3 43-50 284 5 227-257 - 265 1 11,12 275 3 51-58 285 0 258 - 266 1 13,14 276 3 59-66 - - */ -var LengthLookupTable = [ - [0,3], [0,4], [0,5], [0,6], - [0,7], [0,8], [0,9], [0,10], - [1,11], [1,13], [1,15], [1,17], - [2,19], [2,23], [2,27], [2,31], - [3,35], [3,43], [3,51], [3,59], - [4,67], [4,83], [4,99], [4,115], - [5,131], [5,163], [5,195], [5,227], - [0,258] -]; - /* - Extra Extra Extra - Code Bits Dist Code Bits Dist Code Bits Distance - ---- ---- ---- ---- ---- ------ ---- ---- -------- - 0 0 1 10 4 33-48 20 9 1025-1536 - 1 0 2 11 4 49-64 21 9 1537-2048 - 2 0 3 12 5 65-96 22 10 2049-3072 - 3 0 4 13 5 97-128 23 10 3073-4096 - 4 1 5,6 14 6 129-192 24 11 4097-6144 - 5 1 7,8 15 6 193-256 25 11 6145-8192 - 6 2 9-12 16 7 257-384 26 12 8193-12288 - 7 2 13-16 17 7 385-512 27 12 12289-16384 - 8 3 17-24 18 8 513-768 28 13 16385-24576 - 9 3 25-32 19 8 769-1024 29 13 24577-32768 - */ -var DistLookupTable = [ - [0,1], [0,2], [0,3], [0,4], - [1,5], [1,7], - [2,9], [2,13], - [3,17], [3,25], - [4,33], [4,49], - [5,65], [5,97], - [6,129], [6,193], - [7,257], [7,385], - [8,513], [8,769], - [9,1025], [9,1537], - [10,2049], [10,3073], - [11,4097], [11,6145], - [12,8193], [12,12289], - [13,16385], [13,24577] -]; - -function inflateBlockData(bstream, hcLiteralTable, hcDistanceTable, buffer) { - /* - loop (until end of block code recognized) - decode literal/length value from input stream - if value < 256 - copy value (literal byte) to output stream - otherwise - if value = end of block (256) - break from loop - otherwise (value = 257..285) - decode distance from input stream - - move backwards distance bytes in the output - stream, and copy length bytes from this - position to the output stream. - */ - var numSymbols = 0, blockSize = 0; - for (;;) { - var symbol = decodeSymbol(bstream, hcLiteralTable); - ++numSymbols; - if (symbol < 256) { - // copy literal byte to output - buffer.insertByte(symbol); - blockSize++; - } - else { - // end of block reached - if (symbol == 256) { - break; - } - else { - var lengthLookup = LengthLookupTable[symbol-257], - length = lengthLookup[1] + bstream.readBits(lengthLookup[0]), - distLookup = DistLookupTable[decodeSymbol(bstream, hcDistanceTable)], - distance = distLookup[1] + bstream.readBits(distLookup[0]); - - // now apply length and distance appropriately and copy to output - - // TODO: check that backward distance < data.length? - - // http://tools.ietf.org/html/rfc1951#page-11 - // "Note also that the referenced string may overlap the current - // position; for example, if the last 2 bytes decoded have values - // X and Y, a string reference with - // adds X,Y,X,Y,X to the output stream." - // - // loop for each character - var ch = buffer.ptr - distance; - blockSize += length; - if(length > distance) { - var data = buffer.data; - while (length--) { - buffer.insertByte(data[ch++]); - } - } else { - buffer.insertBytes(buffer.data.subarray(ch, ch + length)) - } - - } // length-distance pair - } // length-distance pair or end-of-block - } // loop until we reach end of block - return blockSize; -} - -// {Uint8Array} compressedData A Uint8Array of the compressed file data. -// compression method 8 -// deflate: http://tools.ietf.org/html/rfc1951 -function inflate(compressedData, numDecompressedBytes) { - // Bit stream representing the compressed data. - var bstream = new bitjs.io.BitStream(compressedData.buffer, - false /* rtl */, - compressedData.byteOffset, - compressedData.byteLength); - var buffer = new bitjs.io.ByteBuffer(numDecompressedBytes); - var numBlocks = 0, blockSize = 0; - - // block format: http://tools.ietf.org/html/rfc1951#page-9 - do { - var bFinal = bstream.readBits(1), - bType = bstream.readBits(2); - blockSize = 0; - ++numBlocks; - // no compression - if (bType == 0) { - // skip remaining bits in this byte - while (bstream.bitPtr != 0) bstream.readBits(1); - var len = bstream.readBits(16), - nlen = bstream.readBits(16); - // TODO: check if nlen is the ones-complement of len? - - if(len > 0) buffer.insertBytes(bstream.readBytes(len)); - blockSize = len; - } - // fixed Huffman codes - else if(bType == 1) { - blockSize = inflateBlockData(bstream, getFixedLiteralTable(), getFixedDistanceTable(), buffer); - } - // dynamic Huffman codes - else if(bType == 2) { - var numLiteralLengthCodes = bstream.readBits(5) + 257; - var numDistanceCodes = bstream.readBits(5) + 1, - numCodeLengthCodes = bstream.readBits(4) + 4; - - // populate the array of code length codes (first de-compaction) - var codeLengthsCodeLengths = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]; - for (var i = 0; i < numCodeLengthCodes; ++i) { - codeLengthsCodeLengths[ CodeLengthCodeOrder[i] ] = bstream.readBits(3); - } - - // get the Huffman Codes for the code lengths - var codeLengthsCodes = getHuffmanCodes(codeLengthsCodeLengths); - - // now follow this mapping - /* - 0 - 15: Represent code lengths of 0 - 15 - 16: Copy the previous code length 3 - 6 times. - The next 2 bits indicate repeat length - (0 = 3, ... , 3 = 6) - Example: Codes 8, 16 (+2 bits 11), - 16 (+2 bits 10) will expand to - 12 code lengths of 8 (1 + 6 + 5) - 17: Repeat a code length of 0 for 3 - 10 times. - (3 bits of length) - 18: Repeat a code length of 0 for 11 - 138 times - (7 bits of length) - */ - // to generate the true code lengths of the Huffman Codes for the literal - // and distance tables together - var literalCodeLengths = []; - var prevCodeLength = 0; - while (literalCodeLengths.length < numLiteralLengthCodes + numDistanceCodes) { - var symbol = decodeSymbol(bstream, codeLengthsCodes); - if (symbol <= 15) { - literalCodeLengths.push(symbol); - prevCodeLength = symbol; - } - else if (symbol == 16) { - var repeat = bstream.readBits(2) + 3; - while (repeat--) { - literalCodeLengths.push(prevCodeLength); - } - } - else if (symbol == 17) { - var repeat = bstream.readBits(3) + 3; - while (repeat--) { - literalCodeLengths.push(0); - } - } - else if (symbol == 18) { - var repeat = bstream.readBits(7) + 11; - while (repeat--) { - literalCodeLengths.push(0); - } - } - } - - // now split the distance code lengths out of the literal code array - var distanceCodeLengths = literalCodeLengths.splice(numLiteralLengthCodes, numDistanceCodes); - - // now generate the true Huffman Code tables using these code lengths - var hcLiteralTable = getHuffmanCodes(literalCodeLengths), - hcDistanceTable = getHuffmanCodes(distanceCodeLengths); - blockSize = inflateBlockData(bstream, hcLiteralTable, hcDistanceTable, buffer); - } - // error - else { - err("Error! Encountered deflate block of type 3"); - return null; - } - - // update progress - currentBytesUnarchivedInFile += blockSize; - currentBytesUnarchived += blockSize; - postProgress(); - - } while (bFinal != 1); - // we are done reading blocks if the bFinal bit was set for this block - - // return the buffer data bytes - return buffer.data; -} - -// event.data.file has the ArrayBuffer. -onmessage = function(event) { - unzip(event.data.file, true); -}; diff --git a/static/cbr.js/cbr.js b/static/cbr.js/cbr.js deleted file mode 100644 index c675fbce..00000000 --- a/static/cbr.js/cbr.js +++ /dev/null @@ -1,462 +0,0 @@ -this.cbrjs = {}; - -cbrjs.open = function(url) { - cbrjs.url = url - cbrjs.loadSettings() - Ox.load('UI', function() { - var $body = Ox.$('body') - .css({ - backgroundColor: 'rgb(255, 255, 255)', - overflowX: 'hidden' - }); - window.app = cbrjs.CBRViewer(Ox.extend({ - url: url, - }, cbrjs.settings) - ).bindEvent({ - page: cbrjs.updateSettings, - fitMode: cbrjs.updateSettings, - }).appendTo($body); - Ox.$window.on({ - resize: app.resize - }); - - }); - -}; - -cbrjs.loadSettings = function() { - var settings = {}; - try { - settings = JSON.parse(localStorage['cbrjs.' + cbrjs.url]); - } catch(e) { - settings.page = 1; - settings.fitMode = 'B'; - } - cbrjs.settings = settings; -} - -cbrjs.updateSettings = function(data) { - Ox.forEach(data, function(value, key) { - cbrjs.settings[key] = value; - }); - localStorage['cbrjs.' + cbrjs.url] = JSON.stringify(cbrjs.settings); -} - -cbrjs.CBRViewer = function(options, self) { - self = self || {}; - var that = Ox.Element({}, self) - .defaults({ - url: '', - page: 1 - }) - .options(options || {}) - .update({ - page: setPage, - fitMode: function() { - resize() - that.triggerEvent('fitMode', {fitMode: self.options.fitMode}); - }, - url: loadBook - }), - moveTimeout, - canvas; - - self.pages = []; - self.rotateTimes = 0; - self.hflip = false; - self.vflip = false; - - self.mimeTypes = { - 'png': 'image/png', - 'jpg': 'image/jpeg', - 'jpeg': 'image/jpeg', - 'gif': 'image/gif', - }; - - self.$frame = Ox.Element() - .on({ - mousemove: showMenu, - mousedown: function() { - self.$frame.gainFocus(); - }, - }) - .bindEvent({ - key_down: function() { - self.$frame.scrollTop(self.$frame.scrollTop() + self.$frame.height()) - }, - key_left: function() { - that.options({ - page: Math.max(self.options.page - 1, 1) - }) - }, - key_pagedown: function() { - that.options({ - page: self.pages.length - }) - }, - key_pageup: function() { - that.options({ - page: 1 - }) - }, - key_right: function() { - that.options({ - page: Math.min(self.options.page + 1, self.pages.length) - }) - }, - key_up: function() { - self.$frame.scrollTop(self.$frame.scrollTop() - self.$frame.height()) - }, - key_n: function() { - that.options({ - fitMode: 'N' - }) - }, - key_h: function() { - that.options({ - fitMode: 'H' - }) - }, - key_b: function() { - that.options({ - fitMode: 'B' - }) - }, - key_w: function() { - that.options({ - fitMode: 'W' - }) - }, - key_l: function() { - self.rotateTimes--; - if (self.rotateTimes < 0) { - self.rotateTimes = 3; - } - setPage(); - }, - key_f: function() { - if (!self.hflip && !self.vflip) { - self.hflip = true; - } else if(self.hflip == true) { - self.vflip = true; - self.hflip = false; - } else if(self.vflip == true) { - self.vflip = false; - } - setPage(); - }, - key_space: function() { - var old = self.$frame.scrollTop() - self.$frame.scrollTop(self.$frame.scrollTop() + self.$frame.height()) - if (self.$frame.scrollTop() == old) { - that.options({ - page: Math.min(self.options.page + 1, self.pages.length) - }) - } - }, - singleclick: function(data) { - if (data.clientX < (that.width() / 2)) { - that.options({ - page: Math.max(self.options.page - 1, 1) - }); - } else { - that.options({ - page: Math.min(self.options.page + 1, self.pages.length) - }); - } - } - }) - .css({ - margin: 0, - overflow: 'auto', - padding: 0, - textAlign: 'center' - }); - self.$canvas = Ox.Element('') - .appendTo(self.$frame); - canvas = self.$canvas[0]; - self.$scrollbar = Ox.Range({ - arrows: true, - max: self.options.page, - min: 1, - orientation: 'horizontal', - step: 1, - value: self.options.page, - thumbValue: true, - thumbSize: 64 - }).bindEvent({ - change: function(data) { - Ox.print('change', data); - that.options({ - page: data.value - }) - } - }); - - self.$panel = Ox.SplitPanel({}) - .appendTo(that); - that.setElement( - self.$mainPanel = Ox.SplitPanel({ - elements: [ - { - element: self.$frame, - }, - { - element: self.$scrollbar, - size: 16 - } - ], - orientation: 'vertical' - }) - ); - - self.$loading = Ox.LoadingScreen({ - size: 16, - }) - .css({ - margin: 'auto', - position: 'absolute' - }) - .start() - .appendTo(that); - - self.$menu = Ox.Element().css({ - position: 'fixed', - right: (Ox.UI.SCROLLBAR_SIZE + 4) + 'px', - top: '4px', - opacity: 0 - }) - .addClass('menu') - .appendTo(that); - - self.$zoom = Ox.Button({ - style: 'symbol', - title: 'fill', - tooltip: Ox._('Zoom to fill'), - type: 'image' - }).css({ - width: '16px', - height: '16px', - }).on({ - mousedown: function(event) { - if (self.$zoom.options('title') == 'fill') { - self.$zoom.options({ - title: 'fit', - tooltip: Ox._('Zoom to fit') - }) - that.options({ - fitMode: 'W' - }) - } else { - self.$zoom.options({ - title: 'fill', - tooltip: Ox._('Zoom to fill') - }) - that.options({ - fitMode: 'B' - }) - } - event.stopPropagation() - event.preventDefault(); - } - }) - .appendTo(self.$menu); - - loadBook(); - - function createURLFromArray(array, mimeType) { - var blob = new Blob([array], {type: mimeType}); - blob = blob.slice(array.byteOffset, array.byteOffset + array.byteLength, mimeType); - return URL.createObjectURL(blob); - } - - function isImage(filename) { - var extension = filename.split('.').pop().toLowerCase(); - return !Ox.isUndefined(self.mimeTypes[extension]); - } - - function loadBook() { - var xhr = new XMLHttpRequest(); - xhr.open('GET', self.options.url, true); - xhr.responseType = "arraybuffer"; - xhr.onload = function() { - loadFromArrayBuffer(this.response, function(pages, progress, total) { - self.pages = pages; - self.$scrollbar.options({ - max: Math.max(pages.length, self.options.page), - size: that.width() - }) - if (pages.length == self.options.page) { - setPage(); - if (self.$loading) { - self.$loading.remove(); - delete self.$loading; - } - } - }); - }; - xhr.send(null); - } - - function loadFromArrayBuffer(buffer, progress) { - var extract, - start = (new Date).getTime(), - h = new Uint8Array(buffer, 0, 10), - pathToBitJS = $('script').map(function(i, script) { - return script.src; - }).filter(function(i, url) { - return url.indexOf('bitjs') > -1; - })[0].replace('archive.js', ''); - - var pages = [], filenames = [], total; - - if (h[0] == 0x52 && h[1] == 0x61 && h[2] == 0x72 && h[3] == 0x21) { // RAR - extract = new bitjs.archive.Unrarrer(buffer, pathToBitJS); - } else if (h[0] == 80 && h[1] == 75) { // ZIP - extract = new bitjs.archive.Unzipper(buffer, pathToBitJS); - } else { // try tar otherwise - extract = new bitjs.archive.Untarrer(buffer, pathToBitJS); - } - if (extract) { - extract.addEventListener( - bitjs.archive.UnarchiveEvent.Type.PROGRESS, - function(e) { - var percentage = e.currentBytesUnarchived / e.totalUncompressedBytesInArchive; - total = e.totalFilesInArchive - progress([], percentage, total); - } - ); - extract.addEventListener( - bitjs.archive.UnarchiveEvent.Type.INFO, - function(e) { - Ox.Log('', e.msg); - } - ); - extract.addEventListener( - bitjs.archive.UnarchiveEvent.Type.EXTRACT, - function(e) { - // convert DecompressedFile into a bunch of ImageFiles - if (e.unarchivedFile) { - var f = e.unarchivedFile; - // add any new pages based on the filename - if (!Ox.contains(filenames, f.filename) && isImage(f.filename)) { - filenames.push(f.filename); - pages.push(f); - } else { - total--; - } - progress(pages, pages.length/total, total); - } - } - ); - extract.addEventListener( - bitjs.archive.UnarchiveEvent.Type.FINISH, - function(e) { - total = pages.length; - progress(pages, 1, pages.length); - var diff = ((new Date).getTime() - start)/1000; - Ox.Log('', 'Unarchiving done in ' + diff + 's'); - } - ); - extract.start(); - } else { - Ox.Log('', 'bitjs.archive failed to open file'); - } - } - - function resize(clear) { - canvas.style.width = ''; - canvas.style.height = ''; - canvas.style.maxWidth = ''; - canvas.style.maxHeight = ''; - var maxheight = self.$frame.height() - 4; - if (clear || self.options.fitMode == 'N') { - - } else if (self.options.fitMode == 'B') { - canvas.style.maxWidth = '100%'; - canvas.style.maxHeight = maxheight + 'px'; - } else if (self.options.fitMode == 'H') { - canvas.style.height = maxheight + 'px'; - } else if (self.options.fitMode == 'W') { - canvas.style.width = '100%'; - } - self.$scrollbar.options({ - size: that.width() - }); - } - - function setImage(url) { - var ctx = canvas.getContext('2d'), - img = new Image(); - img.onerror = function(e) { - canvas.width = innerWidth - 100; - canvas.height = 300; - resize(true); - ctx.fillStyle = 'orange'; - ctx.font = '50px sans-serif'; - ctx.strokeStyle = 'black'; - ctx.fillText('Page #' + (currentImage+1) + ' (' + - imageFiles[currentImage].filename + ')', 100, 100) - ctx.fillStyle = 'red'; - ctx.fillText('Is corrupt or not an image', 100, 200); - }; - img.onload = function() { - var h = img.height, - w = img.width, - sw = w, - sh = h; - self.rotateTimes = (4 + self.rotateTimes) % 4; - ctx.save(); - if (self.rotateTimes % 2 == 1) { sh = w; sw = h;} - canvas.height = sh; - canvas.width = sw; - ctx.translate(sw/2, sh/2); - ctx.rotate(Math.PI/2 * self.rotateTimes); - ctx.translate(-w/2, -h/2); - if (self.vflip) { - ctx.scale(1, -1) - ctx.translate(0, -h); - } - if (self.hflip) { - ctx.scale(-1, 1) - ctx.translate(-w, 0); - } - canvas.style.display = 'none'; - scrollTo(0,0); - ctx.drawImage(img, 0, 0); - - resize(); - - canvas.style.display = ''; - document.body.style.overflowY = ''; - ctx.restore(); - }; - img.src = url; - } - - function setPage() { - var file = self.pages[self.options.page - 1], - filename = file.filename, - extension = file.filename.split('.').pop().toLowerCase(), - mimeType = self.mimeTypes[extension]; - setImage(createURLFromArray(file.fileData, mimeType)); - self.$scrollbar.options({value: self.options.page}); - that.triggerEvent('page', {page: self.options.page}); - } - function showMenu() { - if (moveTimeout) { - clearTimeout(moveTimeout); - } else { - self.$menu.animate({opacity: 1}, 250) - } - moveTimeout = setTimeout(function() { - self.$menu.animate({opacity: 0}, 250) - moveTimeout = null - }, 5000); - } - - that.resize = function() { - resize(); - }; - return that; -}; diff --git a/static/cbr.js/index.html b/static/cbr.js/index.html deleted file mode 100644 index a071f617..00000000 --- a/static/cbr.js/index.html +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - diff --git a/static/css/pandora.css b/static/css/pandora.css deleted file mode 100644 index 5a99c177..00000000 --- a/static/css/pandora.css +++ /dev/null @@ -1,6 +0,0 @@ -.InlineImages img { - float: left; - max-width: 256px; - max-height: 256px; - margin: 0 16px 16px 0; -} diff --git a/static/epub.js/css/annotations.css b/static/epub.js/css/annotations.css deleted file mode 100644 index 7a77e668..00000000 --- a/static/epub.js/css/annotations.css +++ /dev/null @@ -1,3 +0,0 @@ -.annotator-adder { - width: 80px; -} diff --git a/static/epub.js/css/main.css b/static/epub.js/css/main.css deleted file mode 100755 index 27e77a32..00000000 --- a/static/epub.js/css/main.css +++ /dev/null @@ -1,817 +0,0 @@ -@font-face { - font-family: 'fontello'; - src: url('../font/fontello.eot?60518104'); - src: url('../font/fontello.eot?60518104#iefix') format('embedded-opentype'), - url('../font/fontello.woff?60518104') format('woff'), - url('../font/fontello.ttf?60518104') format('truetype'), - url('../font/fontello.svg?60518104#fontello') format('svg'); - font-weight: normal; - font-style: normal; -} - -body { - background: #4e4e4e; - overflow: hidden; -} - -#main { - /* height: 500px; */ - position: absolute; - width: 100%; - height: 100%; - right: 0; - /* left: 40px; */ -/* -webkit-transform: translate(40px, 0); - -moz-transform: translate(40px, 0); */ - - /* border-radius: 5px 0px 0px 5px; */ - border-radius: 5px; - background: #fff; - overflow: hidden; - -webkit-transition: -webkit-transform .4s, width .2s; - -moz-transition: -webkit-transform .4s, width .2s; - -ms-transition: -webkit-transform .4s, width .2s; - - -moz-box-shadow: inset 0 0 50px rgba(0,0,0,.1); - -webkit-box-shadow: inset 0 0 50px rgba(0,0,0,.1); - -ms-box-shadow: inset 0 0 50px rgba(0,0,0,.1); - box-shadow: inset 0 0 50px rgba(0,0,0,.1); -} - - -#titlebar { - height: 8%; - min-height: 20px; - padding: 10px; - /* margin: 0 50px 0 50px; */ - position: relative; - color: #4f4f4f; - font-weight: 100; - font-family: Georgia, "Times New Roman", Times, serif; - opacity: .5; - text-align: center; - -webkit-transition: opacity .5s; - -moz-transition: opacity .5s; - -ms-transition: opacity .5s; - z-index: 10; -} - -#titlebar:hover { - opacity: 1; -} - -#titlebar a { - width: 18px; - height: 19px; - line-height: 20px; - overflow: hidden; - display: inline-block; - opacity: .5; - padding: 4px; - border-radius: 4px; -} - -#titlebar a::before { - visibility: visible; -} - -#titlebar a:hover { - opacity: .8; - border: 1px rgba(0,0,0,.2) solid; - padding: 3px; -} - -#titlebar a:active { - opacity: 1; - color: rgba(0,0,0,.6); - /* margin: 1px -1px -1px 1px; */ - -moz-box-shadow: inset 0 0 6px rgba(155,155,155,.8); - -webkit-box-shadow: inset 0 0 6px rgba(155,155,155,.8); - -ms-box-shadow: inset 0 0 6px rgba(155,155,155,.8); - box-shadow: inset 0 0 6px rgba(155,155,155,.8); -} - -#book-title { - font-weight: 600; -} - -#title-seperator { - display: none; -} - -#viewer { - width: 80%; - height: 80%; - /* margin-left: 10%; */ - margin: 0 auto; - max-width: 1250px; - z-index: 2; - position: relative; - overflow: hidden; -} - -#viewer iframe { - border: none; -} - -#prev { - left: 40px; -} - -#next { - right: 40px; -} - -.arrow { - position: absolute; - top: 50%; - margin-top: -32px; - font-size: 64px; - color: #E2E2E2; - font-family: arial, sans-serif; - font-weight: bold; - cursor: pointer; - -webkit-user-select: none; - -khtml-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; -} - -.arrow:hover { - color: #777; -} - -.arrow:active, -.arrow.active { - color: #000; -} - -#sidebar { - background: #6b6b6b; - position: absolute; - /* left: -260px; */ - /* -webkit-transform: translate(-260px, 0); - -moz-transform: translate(-260px, 0); */ - top: 0; - min-width: 300px; - width: 25%; - height: 100%; - -webkit-transition: -webkit-transform .5s; - -moz-transition: -moz-transform .5s; - -ms-transition: -moz-transform .5s; - - overflow: hidden; -} - -#sidebar.open { - /* left: 0; */ - /* -webkit-transform: translate(0, 0); - -moz-transform: translate(0, 0); */ -} - -#main.closed { - /* left: 300px; */ - -webkit-transform: translate(300px, 0); - -moz-transform: translate(300px, 0); - -ms-transform: translate(300px, 0); -} - -#main.single { - width: 75%; -} - -#main.single #viewer { - /* width: 60%; - margin-left: 20%; */ -} - -#panels { - background: #4e4e4e; - position: absolute; - left: 0; - top: 0; - width: 100%; - padding: 13px 0; - height: 14px; - -moz-box-shadow: 0px 1px 3px rgba(0,0,0,.6); - -webkit-box-shadow: 0px 1px 3px rgba(0,0,0,.6); - -ms-box-shadow: 0px 1px 3px rgba(0,0,0,.6); - box-shadow: 0px 1px 3px rgba(0,0,0,.6); -} - -#opener { - /* padding: 10px 10px; */ - float: left; -} - -/* #opener #slider { - width: 25px; -} */ - -#metainfo { - display: inline-block; - text-align: center; - max-width: 80%; -} - -#title-controls { - float: right; -} - -#panels a { - visibility: hidden; - width: 18px; - height: 20px; - overflow: hidden; - display: inline-block; - color: #ccc; - margin-left: 6px; -} - -#panels a::before { - visibility: visible; -} - -#panels a:hover { - color: #AAA; -} - -#panels a:active { - color: #AAA; - margin: 1px 0 -1px 6px; -} - -#panels a.active, -#panels a.active:hover { - color: #AAA; -} - -#searchBox { - width: 165px; - float: left; - margin-left: 10px; - margin-top: -1px; - /* - border-radius: 5px; - background: #9b9b9b; - float: left; - margin-left: 5px; - margin-top: -5px; - padding: 3px 10px; - color: #000; - border: none; - outline: none; */ - -} - -input::-webkit-input-placeholder { - color: #454545; -} -input:-moz-placeholder { - color: #454545; -} -input:-ms-placeholder { - color: #454545; -} - -#divider { - position: absolute; - width: 1px; - border-right: 1px #000 solid; - height: 80%; - z-index: 1; - left: 50%; - margin-left: -1px; - top: 10%; - opacity: .15; - box-shadow: -2px 0 15px rgba(0, 0, 0, 1); - display: none; -} - -#divider.show { - display: block; -} - -#loader { - position: absolute; - z-index: 10; - left: 50%; - top: 50%; - margin: -33px 0 0 -33px; -} - -#tocView, -#bookmarksView { - overflow-x: hidden; - overflow-y: hidden; - min-width: 300px; - width: 25%; - height: 100%; - visibility: hidden; - -webkit-transition: visibility 0 ease .5s; - -moz-transition: visibility 0 ease .5s; - -ms-transition: visibility 0 ease .5s; -} - - - -#sidebar.open #tocView, -#sidebar.open #bookmarksView { - overflow-y: auto; - visibility: visible; - -webkit-transition: visibility 0 ease 0; - -moz-transition: visibility 0 ease 0; - -ms-transition: visibility 0 ease 0; -} - -#sidebar.open #tocView { - display: block; -} - -#tocView > ul, -#bookmarksView > ul { - margin-top: 15px; - margin-bottom: 50px; - padding-left: 20px; - display: block; -} - -#tocView li, -#bookmarksView li { - margin-bottom:10px; - width: 225px; - font-family: Georgia, "Times New Roman", Times, serif; - list-style: none; - text-transform: capitalize; -} - -#tocView li:active, -#tocView li.currentChapter -{ - list-style: none; -} - -.list_item a { - color: #AAA; - text-decoration: none; -} - -.list_item a.chapter { - font-size: 1em; -} - -.list_item a.section { - font-size: .8em; -} - -.list_item.currentChapter > a, -.list_item a:hover { - color: #f1f1f1 -} - -/* #tocView li.openChapter > a, */ -.list_item a:hover { - color: #E2E2E2; -} - -.list_item ul { - padding-left:10px; - margin-top: 8px; - display: none; -} - -.list_item.currentChapter > ul, -.list_item.openChapter > ul { - display: block; -} - -#tocView.hidden { - display: none; -} - -.toc_toggle { - display: inline-block; - width: 14px; - cursor: pointer; - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; -} - -.toc_toggle:before { - content: '▸'; - color: #fff; - margin-right: -4px; -} - -.currentChapter > .toc_toggle:before, -.openChapter > .toc_toggle:before { - content: '▾'; -} - -.view { - width: 300px; - height: 100%; - display: none; - padding-top: 50px; - overflow-y: auto; -} - -#searchResults { - margin-bottom: 50px; - padding-left: 20px; - display: block; -} - -#searchResults li { - margin-bottom:10px; - width: 225px; - font-family: Georgia, "Times New Roman", Times, serif; - list-style: none; -} - -#searchResults a { - color: #AAA; - text-decoration: none; -} - -#searchResults p { - text-decoration: none; - font-size: 12px; - line-height: 16px; -} - -#searchResults p .match { - background: #ccc; - color: #000; -} - -#searchResults li > p { - color: #AAA; -} - -#searchResults li a:hover { - color: #E2E2E2; -} - -#searchView.shown { - display: block; - overflow-y: scroll; -} - -#notes { - padding: 0 0 0 34px; -} - -#notes li { - color: #eee; - font-size: 12px; - width: 240px; - border-top: 1px #fff solid; - padding-top: 6px; - margin-bottom: 6px; -} - -#notes li a { - color: #fff; - display: inline-block; - margin-left: 6px; -} - -#notes li a:hover { - text-decoration: underline; -} - -#notes li img { - max-width: 240px; -} - -#note-text { - display: block; - width: 260px; - height: 80px; - margin: 0 auto; - padding: 5px; - border-radius: 5px; -} - -#note-text[disabled], #note-text[disabled="disabled"]{ - opacity: .5; -} - -#note-anchor { - margin-left: 218px; - margin-top: 5px; -} - -#settingsPanel { - display:none; -} - -#settingsPanel h3 { - color:#f1f1f1; - font-family:Georgia, "Times New Roman", Times, serif; - margin-bottom:10px; -} - -#settingsPanel ul { - margin-top:60px; - list-style-type:none; -} - -#settingsPanel li { - font-size:1em; - color:#f1f1f1; -} - -#settingsPanel .xsmall { font-size:x-small; } -#settingsPanel .small { font-size:small; } -#settingsPanel .medium { font-size:medium; } -#settingsPanel .large { font-size:large; } -#settingsPanel .xlarge { font-size:x-large; } - -.highlight { background-color: yellow } - -.modal { - position: fixed; - top: 50%; - left: 50%; - width: 50%; - width: 630px; - - height: auto; - z-index: 2000; - visibility: hidden; - margin-left: -320px; - margin-top: -160px; - -} - -.overlay { - position: fixed; - width: 100%; - height: 100%; - visibility: hidden; - top: 0; - left: 0; - z-index: 1000; - opacity: 0; - background: rgba(255,255,255,0.8); - -webkit-transition: all 0.3s; - -moz-transition: all 0.3s; - -ms-transition: all 0.3s; - transition: all 0.3s; -} - -.md-show { - visibility: visible; -} - -.md-show ~ .overlay { - opacity: 1; - visibility: visible; -} - -/* Content styles */ -.md-content { - color: #fff; - background: #6b6b6b; - position: relative; - border-radius: 3px; - margin: 0 auto; - height: 320px; -} - -.md-content h3 { - margin: 0; - padding: 6px; - text-align: center; - font-size: 22px; - font-weight: 300; - opacity: 0.8; - background: rgba(0,0,0,0.1); - border-radius: 3px 3px 0 0; -} - -.md-content > div { - padding: 15px 40px 30px; - margin: 0; - font-weight: 300; - font-size: 14px; -} - -.md-content > div p { - margin: 0; - padding: 10px 0; -} - -.md-content > div ul { - margin: 0; - padding: 0 0 30px 20px; -} - -.md-content > div ul li { - padding: 5px 0; -} - -.md-content button { - display: block; - margin: 0 auto; - font-size: 0.8em; -} - -/* Effect 1: Fade in and scale up */ -.md-effect-1 .md-content { - -webkit-transform: scale(0.7); - -moz-transform: scale(0.7); - -ms-transform: scale(0.7); - transform: scale(0.7); - opacity: 0; - -webkit-transition: all 0.3s; - -moz-transition: all 0.3s; - -ms-transition: all 0.3s; - transition: all 0.3s; -} - -.md-show.md-effect-1 .md-content { - -webkit-transform: scale(1); - -moz-transform: scale(1); - -ms-transform: scale(1); - transform: scale(1); - opacity: 1; -} - -.md-content > .closer { - font-size: 18px; - position: absolute; - right: 0; - top: 0; - font-size: 24px; - padding: 4px; -} - -@media only screen and (max-width: 1040px) { - #viewer{ - width: 50%; - margin-left: 25%; - } - - #divider, - #divider.show { - display: none; - } -} - -@media only screen and (max-width: 900px) { - #viewer{ - width: 60%; - margin-left: 20%; - } - - #prev { - left: 20px; - } - - #next { - right: 20px; - } -} - -@media only screen and (max-width: 550px) { - #viewer{ - width: 80%; - margin-left: 10%; - } - - #prev { - left: 0; - } - - #next { - right: 0; - } - - .arrow { - height: 100%; - top: 45px; - width: 10%; - text-indent: -10000px; - } - - #main { - -webkit-transform: translate(0, 0); - -moz-transform: translate(0, 0); - -ms-transform: translate(0, 0); - -webkit-transition: -webkit-transform .3s; - -moz-transition: -moz-transform .3s; - -ms-transition: -moz-transform .3s; - } - - #main.closed { - -webkit-transform: translate(260px, 0); - -moz-transform: translate(260px, 0); - -ms-transform: translate(260px, 0); - } - - #titlebar { - /* font-size: 16px; */ - /* margin: 0 50px 0 50px; */ - } - - #metainfo { - font-size: 10px; - } - - #tocView { - width: 260px; - } - - #tocView li { - font-size: 12px; - } - - #tocView > ul{ - padding-left: 10px; - } -} - - -/* For iPad portrait layouts only */ -@media only screen and (min-device-width: 481px) and (max-device-width: 1024px) and (orientation: portrait) { - #viewer iframe { - width: 460px; - height: 740px; - } -} - /*For iPad landscape layouts only */ -@media only screen and (min-device-width: 481px) and (max-device-width: 1024px) and (orientation: landscape) { - #viewer iframe { - width: 460px; - height: 415px; - } -} -/* For iPhone portrait layouts only */ -@media only screen and (max-device-width: 480px) and (orientation: portrait) { - #viewer { - width: 256px; - height: 432px; - } - #viewer iframe { - width: 256px; - height: 432px; - } -} -/* For iPhone landscape layouts only */ -@media only screen and (max-device-width: 480px) and (orientation: landscape) { - #viewer iframe { - width: 256px; - height: 124px; - } -} - -[class^="icon-"]:before, [class*=" icon-"]:before { - font-family: "fontello"; - font-style: normal; - font-weight: normal; - speak: none; - - display: inline-block; - text-decoration: inherit; - width: 1em; - margin-right: .2em; - text-align: center; - /* opacity: .8; */ - - /* For safety - reset parent styles, that can break glyph codes*/ - font-variant: normal; - text-transform: none; - - /* you can be more comfortable with increased icons size */ - font-size: 112%; -} - - -.icon-search:before { content: '\e807'; } /* '' */ -.icon-resize-full-1:before { content: '\e804'; } /* '' */ -.icon-cancel-circled2:before { content: '\e80f'; } /* '' */ -.icon-link:before { content: '\e80d'; } /* '' */ -.icon-bookmark:before { content: '\e805'; } /* '' */ -.icon-bookmark-empty:before { content: '\e806'; } /* '' */ -.icon-download-cloud:before { content: '\e811'; } /* '' */ -.icon-edit:before { content: '\e814'; } /* '' */ -.icon-menu:before { content: '\e802'; } /* '' */ -.icon-cog:before { content: '\e813'; } /* '' */ -.icon-resize-full:before { content: '\e812'; } /* '' */ -.icon-cancel-circled:before { content: '\e80e'; } /* '' */ -.icon-up-dir:before { content: '\e80c'; } /* '' */ -.icon-right-dir:before { content: '\e80b'; } /* '' */ -.icon-angle-right:before { content: '\e809'; } /* '' */ -.icon-angle-down:before { content: '\e80a'; } /* '' */ -.icon-right:before { content: '\e815'; } /* '' */ -.icon-list-1:before { content: '\e803'; } /* '' */ -.icon-list-numbered:before { content: '\e801'; } /* '' */ -.icon-columns:before { content: '\e810'; } /* '' */ -.icon-list:before { content: '\e800'; } /* '' */ -.icon-resize-small:before { content: '\e808'; } /* '' */ diff --git a/static/epub.js/css/normalize.css b/static/epub.js/css/normalize.css deleted file mode 100755 index c3e014d9..00000000 --- a/static/epub.js/css/normalize.css +++ /dev/null @@ -1,505 +0,0 @@ -/*! normalize.css v1.0.1 | MIT License | git.io/normalize */ - -/* ========================================================================== - HTML5 display definitions - ========================================================================== */ - -/* - * Corrects `block` display not defined in IE 6/7/8/9 and Firefox 3. - */ - -article, -aside, -details, -figcaption, -figure, -footer, -header, -hgroup, -nav, -section, -summary { - display: block; -} - -/* - * Corrects `inline-block` display not defined in IE 6/7/8/9 and Firefox 3. - */ - -audio, -canvas, -video { - display: inline-block; - *display: inline; - *zoom: 1; -} - -/* - * Prevents modern browsers from displaying `audio` without controls. - * Remove excess height in iOS 5 devices. - */ - -audio:not([controls]) { - display: none; - height: 0; -} - -/* - * Addresses styling for `hidden` attribute not present in IE 7/8/9, Firefox 3, - * and Safari 4. - * Known issue: no IE 6 support. - */ - -[hidden] { - display: none; -} - -/* ========================================================================== - Base - ========================================================================== */ - -/* - * 1. Corrects text resizing oddly in IE 6/7 when body `font-size` is set using - * `em` units. - * 2. Prevents iOS text size adjust after orientation change, without disabling - * user zoom. - */ - -html { - font-size: 100%; /* 1 */ - -webkit-text-size-adjust: 100%; /* 2 */ - -ms-text-size-adjust: 100%; /* 2 */ -} - -/* - * Addresses `font-family` inconsistency between `textarea` and other form - * elements. - */ - -html, -button, -input, -select, -textarea { - font-family: sans-serif; -} - -/* - * Addresses margins handled incorrectly in IE 6/7. - */ - -body { - margin: 0; -} - -/* ========================================================================== - Links - ========================================================================== */ - -/* - * Addresses `outline` inconsistency between Chrome and other browsers. - */ - -a:focus { - outline: thin dotted; -} - -/* - * Improves readability when focused and also mouse hovered in all browsers. - */ - -a:active, -a:hover { - outline: 0; -} - -/* ========================================================================== - Typography - ========================================================================== */ - -/* - * Addresses font sizes and margins set differently in IE 6/7. - * Addresses font sizes within `section` and `article` in Firefox 4+, Safari 5, - * and Chrome. - */ - -h1 { - font-size: 2em; - margin: 0.67em 0; -} - -h2 { - font-size: 1.5em; - margin: 0.83em 0; -} - -h3 { - font-size: 1.17em; - margin: 1em 0; -} - -h4 { - font-size: 1em; - margin: 1.33em 0; -} - -h5 { - font-size: 0.83em; - margin: 1.67em 0; -} - -h6 { - font-size: 0.75em; - margin: 2.33em 0; -} - -/* - * Addresses styling not present in IE 7/8/9, Safari 5, and Chrome. - */ - -abbr[title] { - border-bottom: 1px dotted; -} - -/* - * Addresses style set to `bolder` in Firefox 3+, Safari 4/5, and Chrome. - */ - -b, -strong { - font-weight: bold; -} - -blockquote { - margin: 1em 40px; -} - -/* - * Addresses styling not present in Safari 5 and Chrome. - */ - -dfn { - font-style: italic; -} - -/* - * Addresses styling not present in IE 6/7/8/9. - */ - -mark { - background: #ff0; - color: #000; -} - -/* - * Addresses margins set differently in IE 6/7. - */ - -p, -pre { - margin: 1em 0; -} - -/* - * Corrects font family set oddly in IE 6, Safari 4/5, and Chrome. - */ - -code, -kbd, -pre, -samp { - font-family: monospace, serif; - _font-family: 'courier new', monospace; - font-size: 1em; -} - -/* - * Improves readability of pre-formatted text in all browsers. - */ - -pre { - white-space: pre; - white-space: pre-wrap; - word-wrap: break-word; -} - -/* - * Addresses CSS quotes not supported in IE 6/7. - */ - -q { - quotes: none; -} - -/* - * Addresses `quotes` property not supported in Safari 4. - */ - -q:before, -q:after { - content: ''; - content: none; -} - -/* - * Addresses inconsistent and variable font size in all browsers. - */ - -small { - font-size: 80%; -} - -/* - * Prevents `sub` and `sup` affecting `line-height` in all browsers. - */ - -sub, -sup { - font-size: 75%; - line-height: 0; - position: relative; - vertical-align: baseline; -} - -sup { - top: -0.5em; -} - -sub { - bottom: -0.25em; -} - -/* ========================================================================== - Lists - ========================================================================== */ - -/* - * Addresses margins set differently in IE 6/7. - */ - -dl, -menu, -ol, -ul { - margin: 1em 0; -} - -dd { - margin: 0 0 0 40px; -} - -/* - * Addresses paddings set differently in IE 6/7. - */ - -menu, -ol, -ul { - padding: 0 0 0 40px; -} - -/* - * Corrects list images handled incorrectly in IE 7. - */ - -nav ul, -nav ol { - list-style: none; - list-style-image: none; -} - -/* ========================================================================== - Embedded content - ========================================================================== */ - -/* - * 1. Removes border when inside `a` element in IE 6/7/8/9 and Firefox 3. - * 2. Improves image quality when scaled in IE 7. - */ - -img { - border: 0; /* 1 */ - -ms-interpolation-mode: bicubic; /* 2 */ -} - -/* - * Corrects overflow displayed oddly in IE 9. - */ - -svg:not(:root) { - overflow: hidden; -} - -/* ========================================================================== - Figures - ========================================================================== */ - -/* - * Addresses margin not present in IE 6/7/8/9, Safari 5, and Opera 11. - */ - -figure { - margin: 0; -} - -/* ========================================================================== - Forms - ========================================================================== */ - -/* - * Corrects margin displayed oddly in IE 6/7. - */ - -form { - margin: 0; -} - -/* - * Define consistent border, margin, and padding. - */ - -fieldset { - border: 1px solid #c0c0c0; - margin: 0 2px; - padding: 0.35em 0.625em 0.75em; -} - -/* - * 1. Corrects color not being inherited in IE 6/7/8/9. - * 2. Corrects text not wrapping in Firefox 3. - * 3. Corrects alignment displayed oddly in IE 6/7. - */ - -legend { - border: 0; /* 1 */ - padding: 0; - white-space: normal; /* 2 */ - *margin-left: -7px; /* 3 */ -} - -/* - * 1. Corrects font size not being inherited in all browsers. - * 2. Addresses margins set differently in IE 6/7, Firefox 3+, Safari 5, - * and Chrome. - * 3. Improves appearance and consistency in all browsers. - */ - -button, -input, -select, -textarea { - font-size: 100%; /* 1 */ - margin: 0; /* 2 */ - vertical-align: baseline; /* 3 */ - *vertical-align: middle; /* 3 */ -} - -/* - * Addresses Firefox 3+ setting `line-height` on `input` using `!important` in - * the UA stylesheet. - */ - -button, -input { - line-height: normal; -} - -/* - * 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio` - * and `video` controls. - * 2. Corrects inability to style clickable `input` types in iOS. - * 3. Improves usability and consistency of cursor style between image-type - * `input` and others. - * 4. Removes inner spacing in IE 7 without affecting normal text inputs. - * Known issue: inner spacing remains in IE 6. - */ - -button, -html input[type="button"], /* 1 */ -input[type="reset"], -input[type="submit"] { - -webkit-appearance: button; /* 2 */ - cursor: pointer; /* 3 */ - *overflow: visible; /* 4 */ -} - -/* - * Re-set default cursor for disabled elements. - */ - -button[disabled], -input[disabled] { - cursor: default; -} - -/* - * 1. Addresses box sizing set to content-box in IE 8/9. - * 2. Removes excess padding in IE 8/9. - * 3. Removes excess padding in IE 7. - * Known issue: excess padding remains in IE 6. - */ - -input[type="checkbox"], -input[type="radio"] { - box-sizing: border-box; /* 1 */ - padding: 0; /* 2 */ - *height: 13px; /* 3 */ - *width: 13px; /* 3 */ -} - -/* - * 1. Addresses `appearance` set to `searchfield` in Safari 5 and Chrome. - * 2. Addresses `box-sizing` set to `border-box` in Safari 5 and Chrome - * (include `-moz` to future-proof). - */ -/* -input[type="search"] { - -webkit-appearance: textfield; - -moz-box-sizing: content-box; - -webkit-box-sizing: content-box; - box-sizing: content-box; -} -*/ - -/* - * Removes inner padding and search cancel button in Safari 5 and Chrome - * on OS X. - */ - -/* input[type="search"]::-webkit-search-cancel-button, -input[type="search"]::-webkit-search-decoration { - -webkit-appearance: none; -} */ - -/* - * Removes inner padding and border in Firefox 3+. - */ - -button::-moz-focus-inner, -input::-moz-focus-inner { - border: 0; - padding: 0; -} - -/* - * 1. Removes default vertical scrollbar in IE 6/7/8/9. - * 2. Improves readability and alignment in all browsers. - */ - -textarea { - overflow: auto; /* 1 */ - vertical-align: top; /* 2 */ -} - -/* ========================================================================== - Tables - ========================================================================== */ - -/* - * Remove most spacing between table cells. - */ - -table { - border-collapse: collapse; - border-spacing: 0; -} diff --git a/static/epub.js/css/popup.css b/static/epub.js/css/popup.css deleted file mode 100644 index c41aac71..00000000 --- a/static/epub.js/css/popup.css +++ /dev/null @@ -1,96 +0,0 @@ -/* http://davidwalsh.name/css-tooltips */ -/* base CSS element */ -.popup { - background: #eee; - border: 1px solid #ccc; - padding: 10px; - border-radius: 8px; - box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); - position: fixed; - max-width: 300px; - font-size: 12px; - - display: none; - margin-left: 2px; - - margin-top: 30px; -} - -.popup.above { - margin-top: -10px; -} - -.popup.left { - margin-left: -20px; -} - -.popup.right { - margin-left: 40px; -} - -.pop_content { - max-height: 225px; - overflow-y: auto; -} - -.pop_content > p { - margin-top: 0; -} - -/* below */ -.popup:before { - position: absolute; - display: inline-block; - border-bottom: 10px solid #eee; - border-right: 10px solid transparent; - border-left: 10px solid transparent; - border-bottom-color: rgba(0, 0, 0, 0.2); - left: 50%; - top: -10px; - margin-left: -6px; - content: ''; -} - -.popup:after { - position: absolute; - display: inline-block; - border-bottom: 9px solid #eee; - border-right: 9px solid transparent; - border-left: 9px solid transparent; - left: 50%; - top: -9px; - margin-left: -5px; - content: ''; -} - -/* above */ -.popup.above:before { - border-bottom: none; - border-top: 10px solid #eee; - border-top-color: rgba(0, 0, 0, 0.2); - top: 100%; -} - -.popup.above:after { - border-bottom: none; - border-top: 9px solid #eee; - top: 100%; -} - -.popup.left:before, -.popup.left:after -{ - left: 20px; -} - -.popup.right:before, -.popup.right:after -{ - left: auto; - right: 20px; -} - - -.popup.show, .popup.on { - display: block; -} \ No newline at end of file diff --git a/static/epub.js/font/fontello.eot b/static/epub.js/font/fontello.eot deleted file mode 100644 index f63ffa04..00000000 Binary files a/static/epub.js/font/fontello.eot and /dev/null differ diff --git a/static/epub.js/font/fontello.svg b/static/epub.js/font/fontello.svg deleted file mode 100644 index 2db13984..00000000 --- a/static/epub.js/font/fontello.svg +++ /dev/null @@ -1,33 +0,0 @@ - - - -Copyright (C) 2013 by original authors @ fontello.com - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/static/epub.js/font/fontello.ttf b/static/epub.js/font/fontello.ttf deleted file mode 100644 index 95715f86..00000000 Binary files a/static/epub.js/font/fontello.ttf and /dev/null differ diff --git a/static/epub.js/font/fontello.woff b/static/epub.js/font/fontello.woff deleted file mode 100644 index 084f0c55..00000000 Binary files a/static/epub.js/font/fontello.woff and /dev/null differ diff --git a/static/epub.js/img/.gitignore b/static/epub.js/img/.gitignore deleted file mode 100755 index e69de29b..00000000 diff --git a/static/epub.js/img/annotator-glyph-sprite.png b/static/epub.js/img/annotator-glyph-sprite.png deleted file mode 100644 index 5bb11cd8..00000000 Binary files a/static/epub.js/img/annotator-glyph-sprite.png and /dev/null differ diff --git a/static/epub.js/img/annotator-icon-sprite.png b/static/epub.js/img/annotator-icon-sprite.png deleted file mode 100644 index 3058651c..00000000 Binary files a/static/epub.js/img/annotator-icon-sprite.png and /dev/null differ diff --git a/static/epub.js/img/apple-touch-icon.png b/static/epub.js/img/apple-touch-icon.png deleted file mode 100755 index efc5c5a6..00000000 Binary files a/static/epub.js/img/apple-touch-icon.png and /dev/null differ diff --git a/static/epub.js/img/cancelfullscreen.png b/static/epub.js/img/cancelfullscreen.png deleted file mode 100644 index bcf409e7..00000000 Binary files a/static/epub.js/img/cancelfullscreen.png and /dev/null differ diff --git a/static/epub.js/img/close.png b/static/epub.js/img/close.png deleted file mode 100644 index 46189e54..00000000 Binary files a/static/epub.js/img/close.png and /dev/null differ diff --git a/static/epub.js/img/fullscreen.png b/static/epub.js/img/fullscreen.png deleted file mode 100644 index 2f8d48de..00000000 Binary files a/static/epub.js/img/fullscreen.png and /dev/null differ diff --git a/static/epub.js/img/loader.gif b/static/epub.js/img/loader.gif deleted file mode 100644 index 68005bcb..00000000 Binary files a/static/epub.js/img/loader.gif and /dev/null differ diff --git a/static/epub.js/img/menu-icon.png b/static/epub.js/img/menu-icon.png deleted file mode 100644 index 5f40e0e9..00000000 Binary files a/static/epub.js/img/menu-icon.png and /dev/null differ diff --git a/static/epub.js/img/save.png b/static/epub.js/img/save.png deleted file mode 100644 index 5a5bc0e0..00000000 Binary files a/static/epub.js/img/save.png and /dev/null differ diff --git a/static/epub.js/img/saved.png b/static/epub.js/img/saved.png deleted file mode 100644 index 0f1981bd..00000000 Binary files a/static/epub.js/img/saved.png and /dev/null differ diff --git a/static/epub.js/img/settings-s.png b/static/epub.js/img/settings-s.png deleted file mode 100644 index fc21e787..00000000 Binary files a/static/epub.js/img/settings-s.png and /dev/null differ diff --git a/static/epub.js/img/settings.png b/static/epub.js/img/settings.png deleted file mode 100644 index be20cba0..00000000 Binary files a/static/epub.js/img/settings.png and /dev/null differ diff --git a/static/epub.js/img/star.png b/static/epub.js/img/star.png deleted file mode 100644 index 45108935..00000000 Binary files a/static/epub.js/img/star.png and /dev/null differ diff --git a/static/epub.js/index.html b/static/epub.js/index.html deleted file mode 100755 index 8b137891..00000000 --- a/static/epub.js/index.html +++ /dev/null @@ -1 +0,0 @@ - diff --git a/static/epub.js/js/epub.js b/static/epub.js/js/epub.js deleted file mode 100644 index 646e3395..00000000 --- a/static/epub.js/js/epub.js +++ /dev/null @@ -1,23139 +0,0 @@ -(function webpackUniversalModuleDefinition(root, factory) { - if(typeof exports === 'object' && typeof module === 'object') - module.exports = factory(require("xmldom"), (function webpackLoadOptionalExternalModule() { try { return require("jszip"); } catch(e) {} }())); - else if(typeof define === 'function' && define.amd) - define(["xmldom", "jszip"], factory); - else if(typeof exports === 'object') - exports["ePub"] = factory(require("xmldom"), (function webpackLoadOptionalExternalModule() { try { return require("jszip"); } catch(e) {} }())); - else - root["ePub"] = factory(root["xmldom"], root["jszip"]); -})(typeof self !== 'undefined' ? self : this, function(__WEBPACK_EXTERNAL_MODULE_42__, __WEBPACK_EXTERNAL_MODULE_72__) { -return /******/ (function(modules) { // webpackBootstrap -/******/ // The module cache -/******/ var installedModules = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ -/******/ // Check if module is in cache -/******/ if(installedModules[moduleId]) { -/******/ return installedModules[moduleId].exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = installedModules[moduleId] = { -/******/ i: moduleId, -/******/ l: false, -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); -/******/ -/******/ // Flag the module as loaded -/******/ module.l = true; -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = modules; -/******/ -/******/ // expose the module cache -/******/ __webpack_require__.c = installedModules; -/******/ -/******/ // define getter function for harmony exports -/******/ __webpack_require__.d = function(exports, name, getter) { -/******/ if(!__webpack_require__.o(exports, name)) { -/******/ Object.defineProperty(exports, name, { -/******/ configurable: false, -/******/ enumerable: true, -/******/ get: getter -/******/ }); -/******/ } -/******/ }; -/******/ -/******/ // getDefaultExport function for compatibility with non-harmony modules -/******/ __webpack_require__.n = function(module) { -/******/ var getter = module && module.__esModule ? -/******/ function getDefault() { return module['default']; } : -/******/ function getModuleExports() { return module; }; -/******/ __webpack_require__.d(getter, 'a', getter); -/******/ return getter; -/******/ }; -/******/ -/******/ // Object.prototype.hasOwnProperty.call -/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; -/******/ -/******/ // __webpack_public_path__ -/******/ __webpack_require__.p = "/dist/"; -/******/ -/******/ // Load entry module and return exports -/******/ return __webpack_require__(__webpack_require__.s = 25); -/******/ }) -/************************************************************************/ -/******/ ([ -/* 0 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -exports.uuid = uuid; -exports.documentHeight = documentHeight; -exports.isElement = isElement; -exports.isNumber = isNumber; -exports.isFloat = isFloat; -exports.prefixed = prefixed; -exports.defaults = defaults; -exports.extend = extend; -exports.insert = insert; -exports.locationOf = locationOf; -exports.indexOfSorted = indexOfSorted; -exports.bounds = bounds; -exports.borders = borders; -exports.nodeBounds = nodeBounds; -exports.windowBounds = windowBounds; -exports.indexOfNode = indexOfNode; -exports.indexOfTextNode = indexOfTextNode; -exports.indexOfElementNode = indexOfElementNode; -exports.isXml = isXml; -exports.createBlob = createBlob; -exports.createBlobUrl = createBlobUrl; -exports.revokeBlobUrl = revokeBlobUrl; -exports.createBase64Url = createBase64Url; -exports.type = type; -exports.parse = parse; -exports.qs = qs; -exports.qsa = qsa; -exports.qsp = qsp; -exports.sprint = sprint; -exports.treeWalker = treeWalker; -exports.walk = walk; -exports.blob2base64 = blob2base64; -exports.defer = defer; -exports.querySelectorByType = querySelectorByType; -exports.findChildren = findChildren; -exports.parents = parents; -exports.filterChildren = filterChildren; -exports.getParentByTagName = getParentByTagName; - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Core Utilities and Helpers - * @module Core -*/ - -/** - * Vendor prefixed requestAnimationFrame - * @returns {function} requestAnimationFrame - * @memberof Core - */ -var requestAnimationFrame = exports.requestAnimationFrame = typeof window != "undefined" ? window.requestAnimationFrame || window.mozRequestAnimationFrame || window.webkitRequestAnimationFrame || window.msRequestAnimationFrame : false; -var ELEMENT_NODE = 1; -var TEXT_NODE = 3; -var COMMENT_NODE = 8; -var DOCUMENT_NODE = 9; -var _URL = typeof URL != "undefined" ? URL : typeof window != "undefined" ? window.URL || window.webkitURL || window.mozURL : undefined; - -/** - * Generates a UUID - * based on: http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript - * @returns {string} uuid - * @memberof Core - */ -function uuid() { - var d = new Date().getTime(); - var uuid = "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function (c) { - var r = (d + Math.random() * 16) % 16 | 0; - d = Math.floor(d / 16); - return (c == "x" ? r : r & 0x7 | 0x8).toString(16); - }); - return uuid; -} - -/** - * Gets the height of a document - * @returns {number} height - * @memberof Core - */ -function documentHeight() { - return Math.max(document.documentElement.clientHeight, document.body.scrollHeight, document.documentElement.scrollHeight, document.body.offsetHeight, document.documentElement.offsetHeight); -} - -/** - * Checks if a node is an element - * @param {object} obj - * @returns {boolean} - * @memberof Core - */ -function isElement(obj) { - return !!(obj && obj.nodeType == 1); -} - -/** - * @param {any} n - * @returns {boolean} - * @memberof Core - */ -function isNumber(n) { - return !isNaN(parseFloat(n)) && isFinite(n); -} - -/** - * @param {any} n - * @returns {boolean} - * @memberof Core - */ -function isFloat(n) { - var f = parseFloat(n); - - if (isNumber(n) === false) { - return false; - } - - if (typeof n === "string" && n.indexOf(".") > -1) { - return true; - } - - return Math.floor(f) !== f; -} - -/** - * Get a prefixed css property - * @param {string} unprefixed - * @returns {string} - * @memberof Core - */ -function prefixed(unprefixed) { - var vendors = ["Webkit", "webkit", "Moz", "O", "ms"]; - var prefixes = ["-webkit-", "-webkit-", "-moz-", "-o-", "-ms-"]; - var upper = unprefixed[0].toUpperCase() + unprefixed.slice(1); - var length = vendors.length; - - if (typeof document === "undefined" || typeof document.body.style[unprefixed] != "undefined") { - return unprefixed; - } - - for (var i = 0; i < length; i++) { - if (typeof document.body.style[vendors[i] + upper] != "undefined") { - return prefixes[i] + unprefixed; - } - } - - return unprefixed; -} - -/** - * Apply defaults to an object - * @param {object} obj - * @returns {object} - * @memberof Core - */ -function defaults(obj) { - for (var i = 1, length = arguments.length; i < length; i++) { - var source = arguments[i]; - for (var prop in source) { - if (obj[prop] === void 0) obj[prop] = source[prop]; - } - } - return obj; -} - -/** - * Extend properties of an object - * @param {object} target - * @returns {object} - * @memberof Core - */ -function extend(target) { - var sources = [].slice.call(arguments, 1); - sources.forEach(function (source) { - if (!source) return; - Object.getOwnPropertyNames(source).forEach(function (propName) { - Object.defineProperty(target, propName, Object.getOwnPropertyDescriptor(source, propName)); - }); - }); - return target; -} - -/** - * Fast quicksort insert for sorted array -- based on: - * http://stackoverflow.com/questions/1344500/efficient-way-to-insert-a-number-into-a-sorted-array-of-numbers - * @param {any} item - * @param {array} array - * @param {function} [compareFunction] - * @returns {number} location (in array) - * @memberof Core - */ -function insert(item, array, compareFunction) { - var location = locationOf(item, array, compareFunction); - array.splice(location, 0, item); - - return location; -} - -/** - * Finds where something would fit into a sorted array - * @param {any} item - * @param {array} array - * @param {function} [compareFunction] - * @param {function} [_start] - * @param {function} [_end] - * @returns {number} location (in array) - * @memberof Core - */ -function locationOf(item, array, compareFunction, _start, _end) { - var start = _start || 0; - var end = _end || array.length; - var pivot = parseInt(start + (end - start) / 2); - var compared; - if (!compareFunction) { - compareFunction = function compareFunction(a, b) { - if (a > b) return 1; - if (a < b) return -1; - if (a == b) return 0; - }; - } - if (end - start <= 0) { - return pivot; - } - - compared = compareFunction(array[pivot], item); - if (end - start === 1) { - return compared >= 0 ? pivot : pivot + 1; - } - if (compared === 0) { - return pivot; - } - if (compared === -1) { - return locationOf(item, array, compareFunction, pivot, end); - } else { - return locationOf(item, array, compareFunction, start, pivot); - } -} - -/** - * Finds index of something in a sorted array - * Returns -1 if not found - * @param {any} item - * @param {array} array - * @param {function} [compareFunction] - * @param {function} [_start] - * @param {function} [_end] - * @returns {number} index (in array) or -1 - * @memberof Core - */ -function indexOfSorted(item, array, compareFunction, _start, _end) { - var start = _start || 0; - var end = _end || array.length; - var pivot = parseInt(start + (end - start) / 2); - var compared; - if (!compareFunction) { - compareFunction = function compareFunction(a, b) { - if (a > b) return 1; - if (a < b) return -1; - if (a == b) return 0; - }; - } - if (end - start <= 0) { - return -1; // Not found - } - - compared = compareFunction(array[pivot], item); - if (end - start === 1) { - return compared === 0 ? pivot : -1; - } - if (compared === 0) { - return pivot; // Found - } - if (compared === -1) { - return indexOfSorted(item, array, compareFunction, pivot, end); - } else { - return indexOfSorted(item, array, compareFunction, start, pivot); - } -} -/** - * Find the bounds of an element - * taking padding and margin into account - * @param {element} el - * @returns {{ width: Number, height: Number}} - * @memberof Core - */ -function bounds(el) { - - var style = window.getComputedStyle(el); - var widthProps = ["width", "paddingRight", "paddingLeft", "marginRight", "marginLeft", "borderRightWidth", "borderLeftWidth"]; - var heightProps = ["height", "paddingTop", "paddingBottom", "marginTop", "marginBottom", "borderTopWidth", "borderBottomWidth"]; - - var width = 0; - var height = 0; - - widthProps.forEach(function (prop) { - width += parseFloat(style[prop]) || 0; - }); - - heightProps.forEach(function (prop) { - height += parseFloat(style[prop]) || 0; - }); - - return { - height: height, - width: width - }; -} - -/** - * Find the bounds of an element - * taking padding, margin and borders into account - * @param {element} el - * @returns {{ width: Number, height: Number}} - * @memberof Core - */ -function borders(el) { - - var style = window.getComputedStyle(el); - var widthProps = ["paddingRight", "paddingLeft", "marginRight", "marginLeft", "borderRightWidth", "borderLeftWidth"]; - var heightProps = ["paddingTop", "paddingBottom", "marginTop", "marginBottom", "borderTopWidth", "borderBottomWidth"]; - - var width = 0; - var height = 0; - - widthProps.forEach(function (prop) { - width += parseFloat(style[prop]) || 0; - }); - - heightProps.forEach(function (prop) { - height += parseFloat(style[prop]) || 0; - }); - - return { - height: height, - width: width - }; -} - -/** - * Find the bounds of any node - * allows for getting bounds of text nodes by wrapping them in a range - * @param {node} node - * @returns {BoundingClientRect} - * @memberof Core - */ -function nodeBounds(node) { - var elPos = void 0; - var doc = node.ownerDocument; - if (node.nodeType == Node.TEXT_NODE) { - var elRange = doc.createRange(); - elRange.selectNodeContents(node); - elPos = elRange.getBoundingClientRect(); - } else { - elPos = node.getBoundingClientRect(); - } - return elPos; -} - -/** - * Find the equivelent of getBoundingClientRect of a browser window - * @returns {{ width: Number, height: Number, top: Number, left: Number, right: Number, bottom: Number }} - * @memberof Core - */ -function windowBounds() { - - var width = window.innerWidth; - var height = window.innerHeight; - - return { - top: 0, - left: 0, - right: width, - bottom: height, - width: width, - height: height - }; -} - -/** - * Gets the index of a node in its parent - * @param {Node} node - * @param {string} typeId - * @return {number} index - * @memberof Core - */ -function indexOfNode(node, typeId) { - var parent = node.parentNode; - var children = parent.childNodes; - var sib; - var index = -1; - for (var i = 0; i < children.length; i++) { - sib = children[i]; - if (sib.nodeType === typeId) { - index++; - } - if (sib == node) break; - } - - return index; -} - -/** - * Gets the index of a text node in its parent - * @param {node} textNode - * @returns {number} index - * @memberof Core - */ -function indexOfTextNode(textNode) { - return indexOfNode(textNode, TEXT_NODE); -} - -/** - * Gets the index of an element node in its parent - * @param {element} elementNode - * @returns {number} index - * @memberof Core - */ -function indexOfElementNode(elementNode) { - return indexOfNode(elementNode, ELEMENT_NODE); -} - -/** - * Check if extension is xml - * @param {string} ext - * @returns {boolean} - * @memberof Core - */ -function isXml(ext) { - return ["xml", "opf", "ncx"].indexOf(ext) > -1; -} - -/** - * Create a new blob - * @param {any} content - * @param {string} mime - * @returns {Blob} - * @memberof Core - */ -function createBlob(content, mime) { - return new Blob([content], { type: mime }); -} - -/** - * Create a new blob url - * @param {any} content - * @param {string} mime - * @returns {string} url - * @memberof Core - */ -function createBlobUrl(content, mime) { - var tempUrl; - var blob = createBlob(content, mime); - - tempUrl = _URL.createObjectURL(blob); - - return tempUrl; -} - -/** - * Remove a blob url - * @param {string} url - * @memberof Core - */ -function revokeBlobUrl(url) { - return _URL.revokeObjectURL(url); -} - -/** - * Create a new base64 encoded url - * @param {any} content - * @param {string} mime - * @returns {string} url - * @memberof Core - */ -function createBase64Url(content, mime) { - var data; - var datauri; - - if (typeof content !== "string") { - // Only handles strings - return; - } - - data = btoa(encodeURIComponent(content)); - - datauri = "data:" + mime + ";base64," + data; - - return datauri; -} - -/** - * Get type of an object - * @param {object} obj - * @returns {string} type - * @memberof Core - */ -function type(obj) { - return Object.prototype.toString.call(obj).slice(8, -1); -} - -/** - * Parse xml (or html) markup - * @param {string} markup - * @param {string} mime - * @param {boolean} forceXMLDom force using xmlDom to parse instead of native parser - * @returns {document} document - * @memberof Core - */ -function parse(markup, mime, forceXMLDom) { - var doc; - var Parser; - - if (typeof DOMParser === "undefined" || forceXMLDom) { - Parser = __webpack_require__(42).DOMParser; - } else { - Parser = DOMParser; - } - - // Remove byte order mark before parsing - // https://www.w3.org/International/questions/qa-byte-order-mark - if (markup.charCodeAt(0) === 0xFEFF) { - markup = markup.slice(1); - } - - doc = new Parser().parseFromString(markup, mime); - - return doc; -} - -/** - * querySelector polyfill - * @param {element} el - * @param {string} sel selector string - * @returns {element} element - * @memberof Core - */ -function qs(el, sel) { - var elements; - if (!el) { - throw new Error("No Element Provided"); - } - - if (typeof el.querySelector != "undefined") { - return el.querySelector(sel); - } else { - elements = el.getElementsByTagName(sel); - if (elements.length) { - return elements[0]; - } - } -} - -/** - * querySelectorAll polyfill - * @param {element} el - * @param {string} sel selector string - * @returns {element[]} elements - * @memberof Core - */ -function qsa(el, sel) { - - if (typeof el.querySelector != "undefined") { - return el.querySelectorAll(sel); - } else { - return el.getElementsByTagName(sel); - } -} - -/** - * querySelector by property - * @param {element} el - * @param {string} sel selector string - * @param {object[]} props - * @returns {element[]} elements - * @memberof Core - */ -function qsp(el, sel, props) { - var q, filtered; - if (typeof el.querySelector != "undefined") { - sel += "["; - for (var prop in props) { - sel += prop + "~='" + props[prop] + "'"; - } - sel += "]"; - return el.querySelector(sel); - } else { - q = el.getElementsByTagName(sel); - filtered = Array.prototype.slice.call(q, 0).filter(function (el) { - for (var prop in props) { - if (el.getAttribute(prop) === props[prop]) { - return true; - } - } - return false; - }); - - if (filtered) { - return filtered[0]; - } - } -} - -/** - * Sprint through all text nodes in a document - * @memberof Core - * @param {element} root element to start with - * @param {function} func function to run on each element - */ -function sprint(root, func) { - var doc = root.ownerDocument || root; - if (typeof doc.createTreeWalker !== "undefined") { - treeWalker(root, func, NodeFilter.SHOW_TEXT); - } else { - walk(root, function (node) { - if (node && node.nodeType === 3) { - // Node.TEXT_NODE - func(node); - } - }, true); - } -} - -/** - * Create a treeWalker - * @memberof Core - * @param {element} root element to start with - * @param {function} func function to run on each element - * @param {function | object} filter funtion or object to filter with - */ -function treeWalker(root, func, filter) { - var treeWalker = document.createTreeWalker(root, filter, null, false); - var node = void 0; - while (node = treeWalker.nextNode()) { - func(node); - } -} - -/** - * @memberof Core - * @param {node} node - * @param {callback} return false for continue,true for break inside callback - */ -function walk(node, callback) { - if (callback(node)) { - return true; - } - node = node.firstChild; - if (node) { - do { - var walked = walk(node, callback); - if (walked) { - return true; - } - node = node.nextSibling; - } while (node); - } -} - -/** - * Convert a blob to a base64 encoded string - * @param {Blog} blob - * @returns {string} - * @memberof Core - */ -function blob2base64(blob) { - return new Promise(function (resolve, reject) { - var reader = new FileReader(); - reader.readAsDataURL(blob); - reader.onloadend = function () { - resolve(reader.result); - }; - }); -} - -/** - * Creates a new pending promise and provides methods to resolve or reject it. - * From: https://developer.mozilla.org/en-US/docs/Mozilla/JavaScript_code_modules/Promise.jsm/Deferred#backwards_forwards_compatible - * @memberof Core - */ -function defer() { - var _this = this; - - /* A method to resolve the associated Promise with the value passed. - * If the promise is already settled it does nothing. - * - * @param {anything} value : This value is used to resolve the promise - * If the value is a Promise then the associated promise assumes the state - * of Promise passed as value. - */ - this.resolve = null; - - /* A method to reject the assocaited Promise with the value passed. - * If the promise is already settled it does nothing. - * - * @param {anything} reason: The reason for the rejection of the Promise. - * Generally its an Error object. If however a Promise is passed, then the Promise - * itself will be the reason for rejection no matter the state of the Promise. - */ - this.reject = null; - - this.id = uuid(); - - /* A newly created Pomise object. - * Initially in pending state. - */ - this.promise = new Promise(function (resolve, reject) { - _this.resolve = resolve; - _this.reject = reject; - }); - Object.freeze(this); -} - -/** - * querySelector with filter by epub type - * @param {element} html - * @param {string} element element type to find - * @param {string} type epub type to find - * @returns {element[]} elements - * @memberof Core - */ -function querySelectorByType(html, element, type) { - var query; - if (typeof html.querySelector != "undefined") { - query = html.querySelector(element + "[*|type=\"" + type + "\"]"); - } - // Handle IE not supporting namespaced epub:type in querySelector - if (!query || query.length === 0) { - query = qsa(html, element); - for (var i = 0; i < query.length; i++) { - if (query[i].getAttributeNS("http://www.idpf.org/2007/ops", "type") === type || query[i].getAttribute("epub:type") === type) { - return query[i]; - } - } - } else { - return query; - } -} - -/** - * Find direct decendents of an element - * @param {element} el - * @returns {element[]} children - * @memberof Core - */ -function findChildren(el) { - var result = []; - var childNodes = el.childNodes; - for (var i = 0; i < childNodes.length; i++) { - var node = childNodes[i]; - if (node.nodeType === 1) { - result.push(node); - } - } - return result; -} - -/** - * Find all parents (ancestors) of an element - * @param {element} node - * @returns {element[]} parents - * @memberof Core - */ -function parents(node) { - var nodes = [node]; - for (; node; node = node.parentNode) { - nodes.unshift(node); - } - return nodes; -} - -/** - * Find all direct decendents of a specific type - * @param {element} el - * @param {string} nodeName - * @param {boolean} [single] - * @returns {element[]} children - * @memberof Core - */ -function filterChildren(el, nodeName, single) { - var result = []; - var childNodes = el.childNodes; - for (var i = 0; i < childNodes.length; i++) { - var node = childNodes[i]; - if (node.nodeType === 1 && node.nodeName.toLowerCase() === nodeName) { - if (single) { - return node; - } else { - result.push(node); - } - } - } - if (!single) { - return result; - } -} - -/** - * Filter all parents (ancestors) with tag name - * @param {element} node - * @param {string} tagname - * @returns {element[]} parents - * @memberof Core - */ -function getParentByTagName(node, tagname) { - var parent = void 0; - if (node === null || tagname === '') return; - parent = node.parentNode; - while (parent.nodeType === 1) { - if (parent.tagName.toLowerCase() === tagname) { - return parent; - } - parent = parent.parentNode; - } -} - -/** - * Lightweight Polyfill for DOM Range - * @class - * @memberof Core - */ - -var RangeObject = exports.RangeObject = function () { - function RangeObject() { - _classCallCheck(this, RangeObject); - - this.collapsed = false; - this.commonAncestorContainer = undefined; - this.endContainer = undefined; - this.endOffset = undefined; - this.startContainer = undefined; - this.startOffset = undefined; - } - - _createClass(RangeObject, [{ - key: "setStart", - value: function setStart(startNode, startOffset) { - this.startContainer = startNode; - this.startOffset = startOffset; - - if (!this.endContainer) { - this.collapse(true); - } else { - this.commonAncestorContainer = this._commonAncestorContainer(); - } - - this._checkCollapsed(); - } - }, { - key: "setEnd", - value: function setEnd(endNode, endOffset) { - this.endContainer = endNode; - this.endOffset = endOffset; - - if (!this.startContainer) { - this.collapse(false); - } else { - this.collapsed = false; - this.commonAncestorContainer = this._commonAncestorContainer(); - } - - this._checkCollapsed(); - } - }, { - key: "collapse", - value: function collapse(toStart) { - this.collapsed = true; - if (toStart) { - this.endContainer = this.startContainer; - this.endOffset = this.startOffset; - this.commonAncestorContainer = this.startContainer.parentNode; - } else { - this.startContainer = this.endContainer; - this.startOffset = this.endOffset; - this.commonAncestorContainer = this.endOffset.parentNode; - } - } - }, { - key: "selectNode", - value: function selectNode(referenceNode) { - var parent = referenceNode.parentNode; - var index = Array.prototype.indexOf.call(parent.childNodes, referenceNode); - this.setStart(parent, index); - this.setEnd(parent, index + 1); - } - }, { - key: "selectNodeContents", - value: function selectNodeContents(referenceNode) { - var end = referenceNode.childNodes[referenceNode.childNodes - 1]; - var endIndex = referenceNode.nodeType === 3 ? referenceNode.textContent.length : parent.childNodes.length; - this.setStart(referenceNode, 0); - this.setEnd(referenceNode, endIndex); - } - }, { - key: "_commonAncestorContainer", - value: function _commonAncestorContainer(startContainer, endContainer) { - var startParents = parents(startContainer || this.startContainer); - var endParents = parents(endContainer || this.endContainer); - - if (startParents[0] != endParents[0]) return undefined; - - for (var i = 0; i < startParents.length; i++) { - if (startParents[i] != endParents[i]) { - return startParents[i - 1]; - } - } - } - }, { - key: "_checkCollapsed", - value: function _checkCollapsed() { - if (this.startContainer === this.endContainer && this.startOffset === this.endOffset) { - this.collapsed = true; - } else { - this.collapsed = false; - } - } - }, { - key: "toString", - value: function toString() { - // TODO: implement walking between start and end to find text - } - }]); - - return RangeObject; -}(); - -/***/ }), -/* 1 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _core = __webpack_require__(0); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -var ELEMENT_NODE = 1; -var TEXT_NODE = 3; -var COMMENT_NODE = 8; -var DOCUMENT_NODE = 9; - -/** - * Parsing and creation of EpubCFIs: http://www.idpf.org/epub/linking/cfi/epub-cfi.html - - * Implements: - * - Character Offset: epubcfi(/6/4[chap01ref]!/4[body01]/10[para05]/2/1:3) - * - Simple Ranges : epubcfi(/6/4[chap01ref]!/4[body01]/10[para05],/2/1:1,/3:4) - - * Does Not Implement: - * - Temporal Offset (~) - * - Spatial Offset (@) - * - Temporal-Spatial Offset (~ + @) - * - Text Location Assertion ([) - * @class - @param {string | Range | Node } [cfiFrom] - @param {string | object} [base] - @param {string} [ignoreClass] class to ignore when parsing DOM -*/ - -var EpubCFI = function () { - function EpubCFI(cfiFrom, base, ignoreClass) { - _classCallCheck(this, EpubCFI); - - var type; - - this.str = ""; - - this.base = {}; - this.spinePos = 0; // For compatibility - - this.range = false; // true || false; - - this.path = {}; - this.start = null; - this.end = null; - - // Allow instantiation without the "new" keyword - if (!(this instanceof EpubCFI)) { - return new EpubCFI(cfiFrom, base, ignoreClass); - } - - if (typeof base === "string") { - this.base = this.parseComponent(base); - } else if ((typeof base === "undefined" ? "undefined" : _typeof(base)) === "object" && base.steps) { - this.base = base; - } - - type = this.checkType(cfiFrom); - - if (type === "string") { - this.str = cfiFrom; - return (0, _core.extend)(this, this.parse(cfiFrom)); - } else if (type === "range") { - return (0, _core.extend)(this, this.fromRange(cfiFrom, this.base, ignoreClass)); - } else if (type === "node") { - return (0, _core.extend)(this, this.fromNode(cfiFrom, this.base, ignoreClass)); - } else if (type === "EpubCFI" && cfiFrom.path) { - return cfiFrom; - } else if (!cfiFrom) { - return this; - } else { - throw new TypeError("not a valid argument for EpubCFI"); - } - } - - /** - * Check the type of constructor input - * @private - */ - - - _createClass(EpubCFI, [{ - key: "checkType", - value: function checkType(cfi) { - - if (this.isCfiString(cfi)) { - return "string"; - // Is a range object - } else if (cfi && (typeof cfi === "undefined" ? "undefined" : _typeof(cfi)) === "object" && ((0, _core.type)(cfi) === "Range" || typeof cfi.startContainer != "undefined")) { - return "range"; - } else if (cfi && (typeof cfi === "undefined" ? "undefined" : _typeof(cfi)) === "object" && typeof cfi.nodeType != "undefined") { - // || typeof cfi === "function" - return "node"; - } else if (cfi && (typeof cfi === "undefined" ? "undefined" : _typeof(cfi)) === "object" && cfi instanceof EpubCFI) { - return "EpubCFI"; - } else { - return false; - } - } - - /** - * Parse a cfi string to a CFI object representation - * @param {string} cfiStr - * @returns {object} cfi - */ - - }, { - key: "parse", - value: function parse(cfiStr) { - var cfi = { - spinePos: -1, - range: false, - base: {}, - path: {}, - start: null, - end: null - }; - var baseComponent, pathComponent, range; - - if (typeof cfiStr !== "string") { - return { spinePos: -1 }; - } - - if (cfiStr.indexOf("epubcfi(") === 0 && cfiStr[cfiStr.length - 1] === ")") { - // Remove intial epubcfi( and ending ) - cfiStr = cfiStr.slice(8, cfiStr.length - 1); - } - - baseComponent = this.getChapterComponent(cfiStr); - - // Make sure this is a valid cfi or return - if (!baseComponent) { - return { spinePos: -1 }; - } - - cfi.base = this.parseComponent(baseComponent); - - pathComponent = this.getPathComponent(cfiStr); - cfi.path = this.parseComponent(pathComponent); - - range = this.getRange(cfiStr); - - if (range) { - cfi.range = true; - cfi.start = this.parseComponent(range[0]); - cfi.end = this.parseComponent(range[1]); - } - - // Get spine node position - // cfi.spineSegment = cfi.base.steps[1]; - - // Chapter segment is always the second step - cfi.spinePos = cfi.base.steps[1].index; - - return cfi; - } - }, { - key: "parseComponent", - value: function parseComponent(componentStr) { - var component = { - steps: [], - terminal: { - offset: null, - assertion: null - } - }; - var parts = componentStr.split(":"); - var steps = parts[0].split("/"); - var terminal; - - if (parts.length > 1) { - terminal = parts[1]; - component.terminal = this.parseTerminal(terminal); - } - - if (steps[0] === "") { - steps.shift(); // Ignore the first slash - } - - component.steps = steps.map(function (step) { - return this.parseStep(step); - }.bind(this)); - - return component; - } - }, { - key: "parseStep", - value: function parseStep(stepStr) { - var type, num, index, has_brackets, id; - - has_brackets = stepStr.match(/\[(.*)\]/); - if (has_brackets && has_brackets[1]) { - id = has_brackets[1]; - } - - //-- Check if step is a text node or element - num = parseInt(stepStr); - - if (isNaN(num)) { - return; - } - - if (num % 2 === 0) { - // Even = is an element - type = "element"; - index = num / 2 - 1; - } else { - type = "text"; - index = (num - 1) / 2; - } - - return { - "type": type, - "index": index, - "id": id || null - }; - } - }, { - key: "parseTerminal", - value: function parseTerminal(termialStr) { - var characterOffset, textLocationAssertion; - var assertion = termialStr.match(/\[(.*)\]/); - - if (assertion && assertion[1]) { - characterOffset = parseInt(termialStr.split("[")[0]); - textLocationAssertion = assertion[1]; - } else { - characterOffset = parseInt(termialStr); - } - - if (!(0, _core.isNumber)(characterOffset)) { - characterOffset = null; - } - - return { - "offset": characterOffset, - "assertion": textLocationAssertion - }; - } - }, { - key: "getChapterComponent", - value: function getChapterComponent(cfiStr) { - - var indirection = cfiStr.split("!"); - - return indirection[0]; - } - }, { - key: "getPathComponent", - value: function getPathComponent(cfiStr) { - - var indirection = cfiStr.split("!"); - - if (indirection[1]) { - var ranges = indirection[1].split(","); - return ranges[0]; - } - } - }, { - key: "getRange", - value: function getRange(cfiStr) { - - var ranges = cfiStr.split(","); - - if (ranges.length === 3) { - return [ranges[1], ranges[2]]; - } - - return false; - } - }, { - key: "getCharecterOffsetComponent", - value: function getCharecterOffsetComponent(cfiStr) { - var splitStr = cfiStr.split(":"); - return splitStr[1] || ""; - } - }, { - key: "joinSteps", - value: function joinSteps(steps) { - if (!steps) { - return ""; - } - - return steps.map(function (part) { - var segment = ""; - - if (part.type === "element") { - segment += (part.index + 1) * 2; - } - - if (part.type === "text") { - segment += 1 + 2 * part.index; // TODO: double check that this is odd - } - - if (part.id) { - segment += "[" + part.id + "]"; - } - - return segment; - }).join("/"); - } - }, { - key: "segmentString", - value: function segmentString(segment) { - var segmentString = "/"; - - segmentString += this.joinSteps(segment.steps); - - if (segment.terminal && segment.terminal.offset != null) { - segmentString += ":" + segment.terminal.offset; - } - - if (segment.terminal && segment.terminal.assertion != null) { - segmentString += "[" + segment.terminal.assertion + "]"; - } - - return segmentString; - } - - /** - * Convert CFI to a epubcfi(...) string - * @returns {string} epubcfi - */ - - }, { - key: "toString", - value: function toString() { - var cfiString = "epubcfi("; - - cfiString += this.segmentString(this.base); - - cfiString += "!"; - cfiString += this.segmentString(this.path); - - // Add Range, if present - if (this.range && this.start) { - cfiString += ","; - cfiString += this.segmentString(this.start); - } - - if (this.range && this.end) { - cfiString += ","; - cfiString += this.segmentString(this.end); - } - - cfiString += ")"; - - return cfiString; - } - - /** - * Compare which of two CFIs is earlier in the text - * @returns {number} First is earlier = -1, Second is earlier = 1, They are equal = 0 - */ - - }, { - key: "compare", - value: function compare(cfiOne, cfiTwo) { - var stepsA, stepsB; - var terminalA, terminalB; - - var rangeAStartSteps, rangeAEndSteps; - var rangeBEndSteps, rangeBEndSteps; - var rangeAStartTerminal, rangeAEndTerminal; - var rangeBStartTerminal, rangeBEndTerminal; - - if (typeof cfiOne === "string") { - cfiOne = new EpubCFI(cfiOne); - } - if (typeof cfiTwo === "string") { - cfiTwo = new EpubCFI(cfiTwo); - } - // Compare Spine Positions - if (cfiOne.spinePos > cfiTwo.spinePos) { - return 1; - } - if (cfiOne.spinePos < cfiTwo.spinePos) { - return -1; - } - - if (cfiOne.range) { - stepsA = cfiOne.path.steps.concat(cfiOne.start.steps); - terminalA = cfiOne.start.terminal; - } else { - stepsA = cfiOne.path.steps; - terminalA = cfiOne.path.terminal; - } - - if (cfiTwo.range) { - stepsB = cfiTwo.path.steps.concat(cfiTwo.start.steps); - terminalB = cfiTwo.start.terminal; - } else { - stepsB = cfiTwo.path.steps; - terminalB = cfiTwo.path.terminal; - } - - // Compare Each Step in the First item - for (var i = 0; i < stepsA.length; i++) { - if (!stepsA[i]) { - return -1; - } - if (!stepsB[i]) { - return 1; - } - if (stepsA[i].index > stepsB[i].index) { - return 1; - } - if (stepsA[i].index < stepsB[i].index) { - return -1; - } - // Otherwise continue checking - } - - // All steps in First equal to Second and First is Less Specific - if (stepsA.length < stepsB.length) { - return 1; - } - - // Compare the charecter offset of the text node - if (terminalA.offset > terminalB.offset) { - return 1; - } - if (terminalA.offset < terminalB.offset) { - return -1; - } - - // CFI's are equal - return 0; - } - }, { - key: "step", - value: function step(node) { - var nodeType = node.nodeType === TEXT_NODE ? "text" : "element"; - - return { - "id": node.id, - "tagName": node.tagName, - "type": nodeType, - "index": this.position(node) - }; - } - }, { - key: "filteredStep", - value: function filteredStep(node, ignoreClass) { - var filteredNode = this.filter(node, ignoreClass); - var nodeType; - - // Node filtered, so ignore - if (!filteredNode) { - return; - } - - // Otherwise add the filter node in - nodeType = filteredNode.nodeType === TEXT_NODE ? "text" : "element"; - - return { - "id": filteredNode.id, - "tagName": filteredNode.tagName, - "type": nodeType, - "index": this.filteredPosition(filteredNode, ignoreClass) - }; - } - }, { - key: "pathTo", - value: function pathTo(node, offset, ignoreClass) { - var segment = { - steps: [], - terminal: { - offset: null, - assertion: null - } - }; - var currentNode = node; - var step; - - while (currentNode && currentNode.parentNode && currentNode.parentNode.nodeType != DOCUMENT_NODE) { - - if (ignoreClass) { - step = this.filteredStep(currentNode, ignoreClass); - } else { - step = this.step(currentNode); - } - - if (step) { - segment.steps.unshift(step); - } - - currentNode = currentNode.parentNode; - } - - if (offset != null && offset >= 0) { - - segment.terminal.offset = offset; - - // Make sure we are getting to a textNode if there is an offset - if (segment.steps[segment.steps.length - 1].type != "text") { - segment.steps.push({ - "type": "text", - "index": 0 - }); - } - } - - return segment; - } - }, { - key: "equalStep", - value: function equalStep(stepA, stepB) { - if (!stepA || !stepB) { - return false; - } - - if (stepA.index === stepB.index && stepA.id === stepB.id && stepA.type === stepB.type) { - return true; - } - - return false; - } - - /** - * Create a CFI object from a Range - * @param {Range} range - * @param {string | object} base - * @param {string} [ignoreClass] - * @returns {object} cfi - */ - - }, { - key: "fromRange", - value: function fromRange(range, base, ignoreClass) { - var cfi = { - range: false, - base: {}, - path: {}, - start: null, - end: null - }; - - var start = range.startContainer; - var end = range.endContainer; - - var startOffset = range.startOffset; - var endOffset = range.endOffset; - - var needsIgnoring = false; - - if (ignoreClass) { - // Tell pathTo if / what to ignore - needsIgnoring = start.ownerDocument.querySelector("." + ignoreClass) != null; - } - - if (typeof base === "string") { - cfi.base = this.parseComponent(base); - cfi.spinePos = cfi.base.steps[1].index; - } else if ((typeof base === "undefined" ? "undefined" : _typeof(base)) === "object") { - cfi.base = base; - } - - if (range.collapsed) { - if (needsIgnoring) { - startOffset = this.patchOffset(start, startOffset, ignoreClass); - } - cfi.path = this.pathTo(start, startOffset, ignoreClass); - } else { - cfi.range = true; - - if (needsIgnoring) { - startOffset = this.patchOffset(start, startOffset, ignoreClass); - } - - cfi.start = this.pathTo(start, startOffset, ignoreClass); - if (needsIgnoring) { - endOffset = this.patchOffset(end, endOffset, ignoreClass); - } - - cfi.end = this.pathTo(end, endOffset, ignoreClass); - - // Create a new empty path - cfi.path = { - steps: [], - terminal: null - }; - - // Push steps that are shared between start and end to the common path - var len = cfi.start.steps.length; - var i; - - for (i = 0; i < len; i++) { - if (this.equalStep(cfi.start.steps[i], cfi.end.steps[i])) { - if (i === len - 1) { - // Last step is equal, check terminals - if (cfi.start.terminal === cfi.end.terminal) { - // CFI's are equal - cfi.path.steps.push(cfi.start.steps[i]); - // Not a range - cfi.range = false; - } - } else { - cfi.path.steps.push(cfi.start.steps[i]); - } - } else { - break; - } - } - - cfi.start.steps = cfi.start.steps.slice(cfi.path.steps.length); - cfi.end.steps = cfi.end.steps.slice(cfi.path.steps.length); - - // TODO: Add Sanity check to make sure that the end if greater than the start - } - - return cfi; - } - - /** - * Create a CFI object from a Node - * @param {Node} anchor - * @param {string | object} base - * @param {string} [ignoreClass] - * @returns {object} cfi - */ - - }, { - key: "fromNode", - value: function fromNode(anchor, base, ignoreClass) { - var cfi = { - range: false, - base: {}, - path: {}, - start: null, - end: null - }; - - if (typeof base === "string") { - cfi.base = this.parseComponent(base); - cfi.spinePos = cfi.base.steps[1].index; - } else if ((typeof base === "undefined" ? "undefined" : _typeof(base)) === "object") { - cfi.base = base; - } - - cfi.path = this.pathTo(anchor, null, ignoreClass); - - return cfi; - } - }, { - key: "filter", - value: function filter(anchor, ignoreClass) { - var needsIgnoring; - var sibling; // to join with - var parent, previousSibling, nextSibling; - var isText = false; - - if (anchor.nodeType === TEXT_NODE) { - isText = true; - parent = anchor.parentNode; - needsIgnoring = anchor.parentNode.classList.contains(ignoreClass); - } else { - isText = false; - needsIgnoring = anchor.classList.contains(ignoreClass); - } - - if (needsIgnoring && isText) { - previousSibling = parent.previousSibling; - nextSibling = parent.nextSibling; - - // If the sibling is a text node, join the nodes - if (previousSibling && previousSibling.nodeType === TEXT_NODE) { - sibling = previousSibling; - } else if (nextSibling && nextSibling.nodeType === TEXT_NODE) { - sibling = nextSibling; - } - - if (sibling) { - return sibling; - } else { - // Parent will be ignored on next step - return anchor; - } - } else if (needsIgnoring && !isText) { - // Otherwise just skip the element node - return false; - } else { - // No need to filter - return anchor; - } - } - }, { - key: "patchOffset", - value: function patchOffset(anchor, offset, ignoreClass) { - if (anchor.nodeType != TEXT_NODE) { - throw new Error("Anchor must be a text node"); - } - - var curr = anchor; - var totalOffset = offset; - - // If the parent is a ignored node, get offset from it's start - if (anchor.parentNode.classList.contains(ignoreClass)) { - curr = anchor.parentNode; - } - - while (curr.previousSibling) { - if (curr.previousSibling.nodeType === ELEMENT_NODE) { - // Originally a text node, so join - if (curr.previousSibling.classList.contains(ignoreClass)) { - totalOffset += curr.previousSibling.textContent.length; - } else { - break; // Normal node, dont join - } - } else { - // If the previous sibling is a text node, join the nodes - totalOffset += curr.previousSibling.textContent.length; - } - - curr = curr.previousSibling; - } - - return totalOffset; - } - }, { - key: "normalizedMap", - value: function normalizedMap(children, nodeType, ignoreClass) { - var output = {}; - var prevIndex = -1; - var i, - len = children.length; - var currNodeType; - var prevNodeType; - - for (i = 0; i < len; i++) { - - currNodeType = children[i].nodeType; - - // Check if needs ignoring - if (currNodeType === ELEMENT_NODE && children[i].classList.contains(ignoreClass)) { - currNodeType = TEXT_NODE; - } - - if (i > 0 && currNodeType === TEXT_NODE && prevNodeType === TEXT_NODE) { - // join text nodes - output[i] = prevIndex; - } else if (nodeType === currNodeType) { - prevIndex = prevIndex + 1; - output[i] = prevIndex; - } - - prevNodeType = currNodeType; - } - - return output; - } - }, { - key: "position", - value: function position(anchor) { - var children, index; - if (anchor.nodeType === ELEMENT_NODE) { - children = anchor.parentNode.children; - if (!children) { - children = (0, _core.findChildren)(anchor.parentNode); - } - index = Array.prototype.indexOf.call(children, anchor); - } else { - children = this.textNodes(anchor.parentNode); - index = children.indexOf(anchor); - } - - return index; - } - }, { - key: "filteredPosition", - value: function filteredPosition(anchor, ignoreClass) { - var children, index, map; - - if (anchor.nodeType === ELEMENT_NODE) { - children = anchor.parentNode.children; - map = this.normalizedMap(children, ELEMENT_NODE, ignoreClass); - } else { - children = anchor.parentNode.childNodes; - // Inside an ignored node - if (anchor.parentNode.classList.contains(ignoreClass)) { - anchor = anchor.parentNode; - children = anchor.parentNode.childNodes; - } - map = this.normalizedMap(children, TEXT_NODE, ignoreClass); - } - - index = Array.prototype.indexOf.call(children, anchor); - - return map[index]; - } - }, { - key: "stepsToXpath", - value: function stepsToXpath(steps) { - var xpath = [".", "*"]; - - steps.forEach(function (step) { - var position = step.index + 1; - - if (step.id) { - xpath.push("*[position()=" + position + " and @id='" + step.id + "']"); - } else if (step.type === "text") { - xpath.push("text()[" + position + "]"); - } else { - xpath.push("*[" + position + "]"); - } - }); - - return xpath.join("/"); - } - - /* - To get the last step if needed: - // Get the terminal step - lastStep = steps[steps.length-1]; - // Get the query string - query = this.stepsToQuery(steps); - // Find the containing element - startContainerParent = doc.querySelector(query); - // Find the text node within that element - if(startContainerParent && lastStep.type == "text") { - container = startContainerParent.childNodes[lastStep.index]; - } - */ - - }, { - key: "stepsToQuerySelector", - value: function stepsToQuerySelector(steps) { - var query = ["html"]; - - steps.forEach(function (step) { - var position = step.index + 1; - - if (step.id) { - query.push("#" + step.id); - } else if (step.type === "text") { - // unsupported in querySelector - // query.push("text()[" + position + "]"); - } else { - query.push("*:nth-child(" + position + ")"); - } - }); - - return query.join(">"); - } - }, { - key: "textNodes", - value: function textNodes(container, ignoreClass) { - return Array.prototype.slice.call(container.childNodes).filter(function (node) { - if (node.nodeType === TEXT_NODE) { - return true; - } else if (ignoreClass && node.classList.contains(ignoreClass)) { - return true; - } - return false; - }); - } - }, { - key: "walkToNode", - value: function walkToNode(steps, _doc, ignoreClass) { - var doc = _doc || document; - var container = doc.documentElement; - var children; - var step; - var len = steps.length; - var i; - - for (i = 0; i < len; i++) { - step = steps[i]; - - if (step.type === "element") { - //better to get a container using id as some times step.index may not be correct - //For ex.https://github.com/futurepress/epub.js/issues/561 - if (step.id) { - container = doc.getElementById(step.id); - } else { - children = container.children || (0, _core.findChildren)(container); - container = children[step.index]; - } - } else if (step.type === "text") { - container = this.textNodes(container, ignoreClass)[step.index]; - } - if (!container) { - //Break the for loop as due to incorrect index we can get error if - //container is undefined so that other functionailties works fine - //like navigation - break; - } - } - - return container; - } - }, { - key: "findNode", - value: function findNode(steps, _doc, ignoreClass) { - var doc = _doc || document; - var container; - var xpath; - - if (!ignoreClass && typeof doc.evaluate != "undefined") { - xpath = this.stepsToXpath(steps); - container = doc.evaluate(xpath, doc, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue; - } else if (ignoreClass) { - container = this.walkToNode(steps, doc, ignoreClass); - } else { - container = this.walkToNode(steps, doc); - } - - return container; - } - }, { - key: "fixMiss", - value: function fixMiss(steps, offset, _doc, ignoreClass) { - var container = this.findNode(steps.slice(0, -1), _doc, ignoreClass); - var children = container.childNodes; - var map = this.normalizedMap(children, TEXT_NODE, ignoreClass); - var child; - var len; - var lastStepIndex = steps[steps.length - 1].index; - - for (var childIndex in map) { - if (!map.hasOwnProperty(childIndex)) return; - - if (map[childIndex] === lastStepIndex) { - child = children[childIndex]; - len = child.textContent.length; - if (offset > len) { - offset = offset - len; - } else { - if (child.nodeType === ELEMENT_NODE) { - container = child.childNodes[0]; - } else { - container = child; - } - break; - } - } - } - - return { - container: container, - offset: offset - }; - } - - /** - * Creates a DOM range representing a CFI - * @param {document} _doc document referenced in the base - * @param {string} [ignoreClass] - * @return {Range} - */ - - }, { - key: "toRange", - value: function toRange(_doc, ignoreClass) { - var doc = _doc || document; - var range; - var start, end, startContainer, endContainer; - var cfi = this; - var startSteps, endSteps; - var needsIgnoring = ignoreClass ? doc.querySelector("." + ignoreClass) != null : false; - var missed; - - if (typeof doc.createRange !== "undefined") { - range = doc.createRange(); - } else { - range = new _core.RangeObject(); - } - - if (cfi.range) { - start = cfi.start; - startSteps = cfi.path.steps.concat(start.steps); - startContainer = this.findNode(startSteps, doc, needsIgnoring ? ignoreClass : null); - end = cfi.end; - endSteps = cfi.path.steps.concat(end.steps); - endContainer = this.findNode(endSteps, doc, needsIgnoring ? ignoreClass : null); - } else { - start = cfi.path; - startSteps = cfi.path.steps; - startContainer = this.findNode(cfi.path.steps, doc, needsIgnoring ? ignoreClass : null); - } - - if (startContainer) { - try { - - if (start.terminal.offset != null) { - range.setStart(startContainer, start.terminal.offset); - } else { - range.setStart(startContainer, 0); - } - } catch (e) { - missed = this.fixMiss(startSteps, start.terminal.offset, doc, needsIgnoring ? ignoreClass : null); - range.setStart(missed.container, missed.offset); - } - } else { - console.log("No startContainer found for", this.toString()); - // No start found - return null; - } - - if (endContainer) { - try { - - if (end.terminal.offset != null) { - range.setEnd(endContainer, end.terminal.offset); - } else { - range.setEnd(endContainer, 0); - } - } catch (e) { - missed = this.fixMiss(endSteps, cfi.end.terminal.offset, doc, needsIgnoring ? ignoreClass : null); - range.setEnd(missed.container, missed.offset); - } - } - - // doc.defaultView.getSelection().addRange(range); - return range; - } - - /** - * Check if a string is wrapped with "epubcfi()" - * @param {string} str - * @returns {boolean} - */ - - }, { - key: "isCfiString", - value: function isCfiString(str) { - if (typeof str === "string" && str.indexOf("epubcfi(") === 0 && str[str.length - 1] === ")") { - return true; - } - - return false; - } - }, { - key: "generateChapterComponent", - value: function generateChapterComponent(_spineNodeIndex, _pos, id) { - var pos = parseInt(_pos), - spineNodeIndex = (_spineNodeIndex + 1) * 2, - cfi = "/" + spineNodeIndex + "/"; - - cfi += (pos + 1) * 2; - - if (id) { - cfi += "[" + id + "]"; - } - - return cfi; - } - - /** - * Collapse a CFI Range to a single CFI Position - * @param {boolean} [toStart=false] - */ - - }, { - key: "collapse", - value: function collapse(toStart) { - if (!this.range) { - return; - } - - this.range = false; - - if (toStart) { - this.path.steps = this.path.steps.concat(this.start.steps); - this.path.terminal = this.start.terminal; - } else { - this.path.steps = this.path.steps.concat(this.end.steps); - this.path.terminal = this.end.terminal; - } - } - }]); - - return EpubCFI; -}(); - -exports.default = EpubCFI; -module.exports = exports["default"]; - -/***/ }), -/* 2 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); -var EPUBJS_VERSION = exports.EPUBJS_VERSION = "0.3"; - -// Dom events to listen for -var DOM_EVENTS = exports.DOM_EVENTS = ["keydown", "keyup", "keypressed", "mouseup", "mousedown", "click", "touchend", "touchstart", "touchmove"]; - -var EVENTS = exports.EVENTS = { - BOOK: { - OPEN_FAILED: "openFailed" - }, - CONTENTS: { - EXPAND: "expand", - RESIZE: "resize", - SELECTED: "selected", - SELECTED_RANGE: "selectedRange", - LINK_CLICKED: "linkClicked" - }, - LOCATIONS: { - CHANGED: "changed" - }, - MANAGERS: { - RESIZE: "resize", - RESIZED: "resized", - ORIENTATION_CHANGE: "orientationchange", - ADDED: "added", - SCROLL: "scroll", - SCROLLED: "scrolled", - REMOVED: "removed" - }, - VIEWS: { - AXIS: "axis", - LOAD_ERROR: "loaderror", - RENDERED: "rendered", - RESIZED: "resized", - DISPLAYED: "displayed", - SHOWN: "shown", - HIDDEN: "hidden", - MARK_CLICKED: "markClicked" - }, - RENDITION: { - STARTED: "started", - ATTACHED: "attached", - DISPLAYED: "displayed", - DISPLAY_ERROR: "displayerror", - RENDERED: "rendered", - REMOVED: "removed", - RESIZED: "resized", - ORIENTATION_CHANGE: "orientationchange", - LOCATION_CHANGED: "locationChanged", - RELOCATED: "relocated", - MARK_CLICKED: "markClicked", - SELECTED: "selected", - LAYOUT: "layout" - }, - LAYOUT: { - UPDATED: "updated" - }, - ANNOTATION: { - ATTACH: "attach", - DETACH: "detach" - } -}; - -/***/ }), -/* 3 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var d = __webpack_require__(27) - , callable = __webpack_require__(41) - - , apply = Function.prototype.apply, call = Function.prototype.call - , create = Object.create, defineProperty = Object.defineProperty - , defineProperties = Object.defineProperties - , hasOwnProperty = Object.prototype.hasOwnProperty - , descriptor = { configurable: true, enumerable: false, writable: true } - - , on, once, off, emit, methods, descriptors, base; - -on = function (type, listener) { - var data; - - callable(listener); - - if (!hasOwnProperty.call(this, '__ee__')) { - data = descriptor.value = create(null); - defineProperty(this, '__ee__', descriptor); - descriptor.value = null; - } else { - data = this.__ee__; - } - if (!data[type]) data[type] = listener; - else if (typeof data[type] === 'object') data[type].push(listener); - else data[type] = [data[type], listener]; - - return this; -}; - -once = function (type, listener) { - var once, self; - - callable(listener); - self = this; - on.call(this, type, once = function () { - off.call(self, type, once); - apply.call(listener, this, arguments); - }); - - once.__eeOnceListener__ = listener; - return this; -}; - -off = function (type, listener) { - var data, listeners, candidate, i; - - callable(listener); - - if (!hasOwnProperty.call(this, '__ee__')) return this; - data = this.__ee__; - if (!data[type]) return this; - listeners = data[type]; - - if (typeof listeners === 'object') { - for (i = 0; (candidate = listeners[i]); ++i) { - if ((candidate === listener) || - (candidate.__eeOnceListener__ === listener)) { - if (listeners.length === 2) data[type] = listeners[i ? 0 : 1]; - else listeners.splice(i, 1); - } - } - } else { - if ((listeners === listener) || - (listeners.__eeOnceListener__ === listener)) { - delete data[type]; - } - } - - return this; -}; - -emit = function (type) { - var i, l, listener, listeners, args; - - if (!hasOwnProperty.call(this, '__ee__')) return; - listeners = this.__ee__[type]; - if (!listeners) return; - - if (typeof listeners === 'object') { - l = arguments.length; - args = new Array(l - 1); - for (i = 1; i < l; ++i) args[i - 1] = arguments[i]; - - listeners = listeners.slice(); - for (i = 0; (listener = listeners[i]); ++i) { - apply.call(listener, this, args); - } - } else { - switch (arguments.length) { - case 1: - call.call(listeners, this); - break; - case 2: - call.call(listeners, this, arguments[1]); - break; - case 3: - call.call(listeners, this, arguments[1], arguments[2]); - break; - default: - l = arguments.length; - args = new Array(l - 1); - for (i = 1; i < l; ++i) { - args[i - 1] = arguments[i]; - } - apply.call(listeners, this, args); - } - } -}; - -methods = { - on: on, - once: once, - off: off, - emit: emit -}; - -descriptors = { - on: d(on), - once: d(once), - off: d(off), - emit: d(emit) -}; - -base = defineProperties({}, descriptors); - -module.exports = exports = function (o) { - return (o == null) ? create(base) : defineProperties(Object(o), descriptors); -}; -exports.methods = methods; - - -/***/ }), -/* 4 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _pathWebpack = __webpack_require__(7); - -var _pathWebpack2 = _interopRequireDefault(_pathWebpack); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Creates a Path object for parsing and manipulation of a path strings - * - * Uses a polyfill for Nodejs path: https://nodejs.org/api/path.html - * @param {string} pathString a url string (relative or absolute) - * @class - */ -var Path = function () { - function Path(pathString) { - _classCallCheck(this, Path); - - var protocol; - var parsed; - - protocol = pathString.indexOf("://"); - if (protocol > -1) { - pathString = new URL(pathString).pathname; - } - - parsed = this.parse(pathString); - - this.path = pathString; - - if (this.isDirectory(pathString)) { - this.directory = pathString; - } else { - this.directory = parsed.dir + "/"; - } - - this.filename = parsed.base; - this.extension = parsed.ext.slice(1); - } - - /** - * Parse the path: https://nodejs.org/api/path.html#path_path_parse_path - * @param {string} what - * @returns {object} - */ - - - _createClass(Path, [{ - key: "parse", - value: function parse(what) { - return _pathWebpack2.default.parse(what); - } - - /** - * @param {string} what - * @returns {boolean} - */ - - }, { - key: "isAbsolute", - value: function isAbsolute(what) { - return _pathWebpack2.default.isAbsolute(what || this.path); - } - - /** - * Check if path ends with a directory - * @param {string} what - * @returns {boolean} - */ - - }, { - key: "isDirectory", - value: function isDirectory(what) { - return what.charAt(what.length - 1) === "/"; - } - - /** - * Resolve a path against the directory of the Path - * - * https://nodejs.org/api/path.html#path_path_resolve_paths - * @param {string} what - * @returns {string} resolved - */ - - }, { - key: "resolve", - value: function resolve(what) { - return _pathWebpack2.default.resolve(this.directory, what); - } - - /** - * Resolve a path relative to the directory of the Path - * - * https://nodejs.org/api/path.html#path_path_relative_from_to - * @param {string} what - * @returns {string} relative - */ - - }, { - key: "relative", - value: function relative(what) { - var isAbsolute = what && what.indexOf("://") > -1; - - if (isAbsolute) { - return what; - } - - return _pathWebpack2.default.relative(this.directory, what); - } - }, { - key: "splitPath", - value: function splitPath(filename) { - return this.splitPathRe.exec(filename).slice(1); - } - - /** - * Return the path string - * @returns {string} path - */ - - }, { - key: "toString", - value: function toString() { - return this.path; - } - }]); - - return Path; -}(); - -exports.default = Path; -module.exports = exports["default"]; - -/***/ }), -/* 5 */ -/***/ (function(module, exports) { - -var g; - -// This works in non-strict mode -g = (function() { - return this; -})(); - -try { - // This works if eval is allowed (see CSP) - g = g || Function("return this")() || (1,eval)("this"); -} catch(e) { - // This works if the window reference is available - if(typeof window === "object") - g = window; -} - -// g can still be undefined, but nothing to do about it... -// We return undefined, instead of nothing here, so it's -// easier to handle this case. if(!global) { ...} - -module.exports = g; - - -/***/ }), -/* 6 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _path = __webpack_require__(4); - -var _path2 = _interopRequireDefault(_path); - -var _pathWebpack = __webpack_require__(7); - -var _pathWebpack2 = _interopRequireDefault(_pathWebpack); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * creates a Url object for parsing and manipulation of a url string - * @param {string} urlString a url string (relative or absolute) - * @param {string} [baseString] optional base for the url, - * default to window.location.href - */ -var Url = function () { - function Url(urlString, baseString) { - _classCallCheck(this, Url); - - var absolute = urlString.indexOf("://") > -1; - var pathname = urlString; - var basePath; - - this.Url = undefined; - this.href = urlString; - this.protocol = ""; - this.origin = ""; - this.hash = ""; - this.hash = ""; - this.search = ""; - this.base = baseString; - - if (!absolute && baseString !== false && typeof baseString !== "string" && window && window.location) { - this.base = window.location.href; - } - - // URL Polyfill doesn't throw an error if base is empty - if (absolute || this.base) { - try { - if (this.base) { - // Safari doesn't like an undefined base - this.Url = new URL(urlString, this.base); - } else { - this.Url = new URL(urlString); - } - this.href = this.Url.href; - - this.protocol = this.Url.protocol; - this.origin = this.Url.origin; - this.hash = this.Url.hash; - this.search = this.Url.search; - - pathname = this.Url.pathname; - } catch (e) { - // Skip URL parsing - this.Url = undefined; - // resolve the pathname from the base - if (this.base) { - basePath = new _path2.default(this.base); - pathname = basePath.resolve(pathname); - } - } - } - - this.Path = new _path2.default(pathname); - - this.directory = this.Path.directory; - this.filename = this.Path.filename; - this.extension = this.Path.extension; - } - - /** - * @returns {Path} - */ - - - _createClass(Url, [{ - key: "path", - value: function path() { - return this.Path; - } - - /** - * Resolves a relative path to a absolute url - * @param {string} what - * @returns {string} url - */ - - }, { - key: "resolve", - value: function resolve(what) { - var isAbsolute = what.indexOf("://") > -1; - var fullpath; - - if (isAbsolute) { - return what; - } - - fullpath = _pathWebpack2.default.resolve(this.directory, what); - return this.origin + fullpath; - } - - /** - * Resolve a path relative to the url - * @param {string} what - * @returns {string} path - */ - - }, { - key: "relative", - value: function relative(what) { - return _pathWebpack2.default.relative(what, this.directory); - } - - /** - * @returns {string} - */ - - }, { - key: "toString", - value: function toString() { - return this.href; - } - }]); - - return Url; -}(); - -exports.default = Url; -module.exports = exports["default"]; - -/***/ }), -/* 7 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -if (!process) { - var process = { - "cwd" : function () { return '/' } - }; -} - -function assertPath(path) { - if (typeof path !== 'string') { - throw new TypeError('Path must be a string. Received ' + path); - } -} - -// Resolves . and .. elements in a path with directory names -function normalizeStringPosix(path, allowAboveRoot) { - var res = ''; - var lastSlash = -1; - var dots = 0; - var code; - for (var i = 0; i <= path.length; ++i) { - if (i < path.length) - code = path.charCodeAt(i); - else if (code === 47/*/*/) - break; - else - code = 47/*/*/; - if (code === 47/*/*/) { - if (lastSlash === i - 1 || dots === 1) { - // NOOP - } else if (lastSlash !== i - 1 && dots === 2) { - if (res.length < 2 || - res.charCodeAt(res.length - 1) !== 46/*.*/ || - res.charCodeAt(res.length - 2) !== 46/*.*/) { - if (res.length > 2) { - var start = res.length - 1; - var j = start; - for (; j >= 0; --j) { - if (res.charCodeAt(j) === 47/*/*/) - break; - } - if (j !== start) { - if (j === -1) - res = ''; - else - res = res.slice(0, j); - lastSlash = i; - dots = 0; - continue; - } - } else if (res.length === 2 || res.length === 1) { - res = ''; - lastSlash = i; - dots = 0; - continue; - } - } - if (allowAboveRoot) { - if (res.length > 0) - res += '/..'; - else - res = '..'; - } - } else { - if (res.length > 0) - res += '/' + path.slice(lastSlash + 1, i); - else - res = path.slice(lastSlash + 1, i); - } - lastSlash = i; - dots = 0; - } else if (code === 46/*.*/ && dots !== -1) { - ++dots; - } else { - dots = -1; - } - } - return res; -} - -function _format(sep, pathObject) { - var dir = pathObject.dir || pathObject.root; - var base = pathObject.base || - ((pathObject.name || '') + (pathObject.ext || '')); - if (!dir) { - return base; - } - if (dir === pathObject.root) { - return dir + base; - } - return dir + sep + base; -} - -var posix = { - // path.resolve([from ...], to) - resolve: function resolve() { - var resolvedPath = ''; - var resolvedAbsolute = false; - var cwd; - - for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) { - var path; - if (i >= 0) - path = arguments[i]; - else { - if (cwd === undefined) - cwd = process.cwd(); - path = cwd; - } - - assertPath(path); - - // Skip empty entries - if (path.length === 0) { - continue; - } - - resolvedPath = path + '/' + resolvedPath; - resolvedAbsolute = path.charCodeAt(0) === 47/*/*/; - } - - // At this point the path should be resolved to a full absolute path, but - // handle relative paths to be safe (might happen when process.cwd() fails) - - // Normalize the path - resolvedPath = normalizeStringPosix(resolvedPath, !resolvedAbsolute); - - if (resolvedAbsolute) { - if (resolvedPath.length > 0) - return '/' + resolvedPath; - else - return '/'; - } else if (resolvedPath.length > 0) { - return resolvedPath; - } else { - return '.'; - } - }, - - - normalize: function normalize(path) { - assertPath(path); - - if (path.length === 0) - return '.'; - - var isAbsolute = path.charCodeAt(0) === 47/*/*/; - var trailingSeparator = path.charCodeAt(path.length - 1) === 47/*/*/; - - // Normalize the path - path = normalizeStringPosix(path, !isAbsolute); - - if (path.length === 0 && !isAbsolute) - path = '.'; - if (path.length > 0 && trailingSeparator) - path += '/'; - - if (isAbsolute) - return '/' + path; - return path; - }, - - - isAbsolute: function isAbsolute(path) { - assertPath(path); - return path.length > 0 && path.charCodeAt(0) === 47/*/*/; - }, - - - join: function join() { - if (arguments.length === 0) - return '.'; - var joined; - for (var i = 0; i < arguments.length; ++i) { - var arg = arguments[i]; - assertPath(arg); - if (arg.length > 0) { - if (joined === undefined) - joined = arg; - else - joined += '/' + arg; - } - } - if (joined === undefined) - return '.'; - return posix.normalize(joined); - }, - - - relative: function relative(from, to) { - assertPath(from); - assertPath(to); - - if (from === to) - return ''; - - from = posix.resolve(from); - to = posix.resolve(to); - - if (from === to) - return ''; - - // Trim any leading backslashes - var fromStart = 1; - for (; fromStart < from.length; ++fromStart) { - if (from.charCodeAt(fromStart) !== 47/*/*/) - break; - } - var fromEnd = from.length; - var fromLen = (fromEnd - fromStart); - - // Trim any leading backslashes - var toStart = 1; - for (; toStart < to.length; ++toStart) { - if (to.charCodeAt(toStart) !== 47/*/*/) - break; - } - var toEnd = to.length; - var toLen = (toEnd - toStart); - - // Compare paths to find the longest common path from root - var length = (fromLen < toLen ? fromLen : toLen); - var lastCommonSep = -1; - var i = 0; - for (; i <= length; ++i) { - if (i === length) { - if (toLen > length) { - if (to.charCodeAt(toStart + i) === 47/*/*/) { - // We get here if `from` is the exact base path for `to`. - // For example: from='/foo/bar'; to='/foo/bar/baz' - return to.slice(toStart + i + 1); - } else if (i === 0) { - // We get here if `from` is the root - // For example: from='/'; to='/foo' - return to.slice(toStart + i); - } - } else if (fromLen > length) { - if (from.charCodeAt(fromStart + i) === 47/*/*/) { - // We get here if `to` is the exact base path for `from`. - // For example: from='/foo/bar/baz'; to='/foo/bar' - lastCommonSep = i; - } else if (i === 0) { - // We get here if `to` is the root. - // For example: from='/foo'; to='/' - lastCommonSep = 0; - } - } - break; - } - var fromCode = from.charCodeAt(fromStart + i); - var toCode = to.charCodeAt(toStart + i); - if (fromCode !== toCode) - break; - else if (fromCode === 47/*/*/) - lastCommonSep = i; - } - - var out = ''; - // Generate the relative path based on the path difference between `to` - // and `from` - for (i = fromStart + lastCommonSep + 1; i <= fromEnd; ++i) { - if (i === fromEnd || from.charCodeAt(i) === 47/*/*/) { - if (out.length === 0) - out += '..'; - else - out += '/..'; - } - } - - // Lastly, append the rest of the destination (`to`) path that comes after - // the common path parts - if (out.length > 0) - return out + to.slice(toStart + lastCommonSep); - else { - toStart += lastCommonSep; - if (to.charCodeAt(toStart) === 47/*/*/) - ++toStart; - return to.slice(toStart); - } - }, - - - _makeLong: function _makeLong(path) { - return path; - }, - - - dirname: function dirname(path) { - assertPath(path); - if (path.length === 0) - return '.'; - var code = path.charCodeAt(0); - var hasRoot = (code === 47/*/*/); - var end = -1; - var matchedSlash = true; - for (var i = path.length - 1; i >= 1; --i) { - code = path.charCodeAt(i); - if (code === 47/*/*/) { - if (!matchedSlash) { - end = i; - break; - } - } else { - // We saw the first non-path separator - matchedSlash = false; - } - } - - if (end === -1) - return hasRoot ? '/' : '.'; - if (hasRoot && end === 1) - return '//'; - return path.slice(0, end); - }, - - - basename: function basename(path, ext) { - if (ext !== undefined && typeof ext !== 'string') - throw new TypeError('"ext" argument must be a string'); - assertPath(path); - - var start = 0; - var end = -1; - var matchedSlash = true; - var i; - - if (ext !== undefined && ext.length > 0 && ext.length <= path.length) { - if (ext.length === path.length && ext === path) - return ''; - var extIdx = ext.length - 1; - var firstNonSlashEnd = -1; - for (i = path.length - 1; i >= 0; --i) { - var code = path.charCodeAt(i); - if (code === 47/*/*/) { - // If we reached a path separator that was not part of a set of path - // separators at the end of the string, stop now - if (!matchedSlash) { - start = i + 1; - break; - } - } else { - if (firstNonSlashEnd === -1) { - // We saw the first non-path separator, remember this index in case - // we need it if the extension ends up not matching - matchedSlash = false; - firstNonSlashEnd = i + 1; - } - if (extIdx >= 0) { - // Try to match the explicit extension - if (code === ext.charCodeAt(extIdx)) { - if (--extIdx === -1) { - // We matched the extension, so mark this as the end of our path - // component - end = i; - } - } else { - // Extension does not match, so our result is the entire path - // component - extIdx = -1; - end = firstNonSlashEnd; - } - } - } - } - - if (start === end) - end = firstNonSlashEnd; - else if (end === -1) - end = path.length; - return path.slice(start, end); - } else { - for (i = path.length - 1; i >= 0; --i) { - if (path.charCodeAt(i) === 47/*/*/) { - // If we reached a path separator that was not part of a set of path - // separators at the end of the string, stop now - if (!matchedSlash) { - start = i + 1; - break; - } - } else if (end === -1) { - // We saw the first non-path separator, mark this as the end of our - // path component - matchedSlash = false; - end = i + 1; - } - } - - if (end === -1) - return ''; - return path.slice(start, end); - } - }, - - - extname: function extname(path) { - assertPath(path); - var startDot = -1; - var startPart = 0; - var end = -1; - var matchedSlash = true; - // Track the state of characters (if any) we see before our first dot and - // after any path separator we find - var preDotState = 0; - for (var i = path.length - 1; i >= 0; --i) { - var code = path.charCodeAt(i); - if (code === 47/*/*/) { - // If we reached a path separator that was not part of a set of path - // separators at the end of the string, stop now - if (!matchedSlash) { - startPart = i + 1; - break; - } - continue; - } - if (end === -1) { - // We saw the first non-path separator, mark this as the end of our - // extension - matchedSlash = false; - end = i + 1; - } - if (code === 46/*.*/) { - // If this is our first dot, mark it as the start of our extension - if (startDot === -1) - startDot = i; - else if (preDotState !== 1) - preDotState = 1; - } else if (startDot !== -1) { - // We saw a non-dot and non-path separator before our dot, so we should - // have a good chance at having a non-empty extension - preDotState = -1; - } - } - - if (startDot === -1 || - end === -1 || - // We saw a non-dot character immediately before the dot - preDotState === 0 || - // The (right-most) trimmed path component is exactly '..' - (preDotState === 1 && - startDot === end - 1 && - startDot === startPart + 1)) { - return ''; - } - return path.slice(startDot, end); - }, - - - format: function format(pathObject) { - if (pathObject === null || typeof pathObject !== 'object') { - throw new TypeError( - 'Parameter "pathObject" must be an object, not ' + typeof(pathObject) - ); - } - return _format('/', pathObject); - }, - - - parse: function parse(path) { - assertPath(path); - - var ret = { root: '', dir: '', base: '', ext: '', name: '' }; - if (path.length === 0) - return ret; - var code = path.charCodeAt(0); - var isAbsolute = (code === 47/*/*/); - var start; - if (isAbsolute) { - ret.root = '/'; - start = 1; - } else { - start = 0; - } - var startDot = -1; - var startPart = 0; - var end = -1; - var matchedSlash = true; - var i = path.length - 1; - - // Track the state of characters (if any) we see before our first dot and - // after any path separator we find - var preDotState = 0; - - // Get non-dir info - for (; i >= start; --i) { - code = path.charCodeAt(i); - if (code === 47/*/*/) { - // If we reached a path separator that was not part of a set of path - // separators at the end of the string, stop now - if (!matchedSlash) { - startPart = i + 1; - break; - } - continue; - } - if (end === -1) { - // We saw the first non-path separator, mark this as the end of our - // extension - matchedSlash = false; - end = i + 1; - } - if (code === 46/*.*/) { - // If this is our first dot, mark it as the start of our extension - if (startDot === -1) - startDot = i; - else if (preDotState !== 1) - preDotState = 1; - } else if (startDot !== -1) { - // We saw a non-dot and non-path separator before our dot, so we should - // have a good chance at having a non-empty extension - preDotState = -1; - } - } - - if (startDot === -1 || - end === -1 || - // We saw a non-dot character immediately before the dot - preDotState === 0 || - // The (right-most) trimmed path component is exactly '..' - (preDotState === 1 && - startDot === end - 1 && - startDot === startPart + 1)) { - if (end !== -1) { - if (startPart === 0 && isAbsolute) - ret.base = ret.name = path.slice(1, end); - else - ret.base = ret.name = path.slice(startPart, end); - } - } else { - if (startPart === 0 && isAbsolute) { - ret.name = path.slice(1, startDot); - ret.base = path.slice(1, end); - } else { - ret.name = path.slice(startPart, startDot); - ret.base = path.slice(startPart, end); - } - ret.ext = path.slice(startDot, end); - } - - if (startPart > 0) - ret.dir = path.slice(0, startPart - 1); - else if (isAbsolute) - ret.dir = '/'; - - return ret; - }, - - - sep: '/', - delimiter: ':', - posix: null -}; - - -module.exports = posix; - - -/***/ }), -/* 8 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.replaceBase = replaceBase; -exports.replaceCanonical = replaceCanonical; -exports.replaceMeta = replaceMeta; -exports.replaceLinks = replaceLinks; -exports.substitute = substitute; - -var _core = __webpack_require__(0); - -var _url = __webpack_require__(6); - -var _url2 = _interopRequireDefault(_url); - -var _path = __webpack_require__(4); - -var _path2 = _interopRequireDefault(_path); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function replaceBase(doc, section) { - var base; - var head; - var url = section.url; - var absolute = url.indexOf("://") > -1; - - if (!doc) { - return; - } - - head = (0, _core.qs)(doc, "head"); - base = (0, _core.qs)(head, "base"); - - if (!base) { - base = doc.createElement("base"); - head.insertBefore(base, head.firstChild); - } - - // Fix for Safari crashing if the url doesn't have an origin - if (!absolute && window && window.location) { - url = window.location.origin + url; - } - - base.setAttribute("href", url); -} - -function replaceCanonical(doc, section) { - var head; - var link; - var url = section.canonical; - - if (!doc) { - return; - } - - head = (0, _core.qs)(doc, "head"); - link = (0, _core.qs)(head, "link[rel='canonical']"); - - if (link) { - link.setAttribute("href", url); - } else { - link = doc.createElement("link"); - link.setAttribute("rel", "canonical"); - link.setAttribute("href", url); - head.appendChild(link); - } -} - -function replaceMeta(doc, section) { - var head; - var meta; - var id = section.idref; - if (!doc) { - return; - } - - head = (0, _core.qs)(doc, "head"); - meta = (0, _core.qs)(head, "link[property='dc.identifier']"); - - if (meta) { - meta.setAttribute("content", id); - } else { - meta = doc.createElement("meta"); - meta.setAttribute("name", "dc.identifier"); - meta.setAttribute("content", id); - head.appendChild(meta); - } -} - -// TODO: move me to Contents -function replaceLinks(contents, fn) { - - var links = contents.querySelectorAll("a[href]"); - - if (!links.length) { - return; - } - - var base = (0, _core.qs)(contents.ownerDocument, "base"); - var location = base ? base.getAttribute("href") : undefined; - var replaceLink = function (link) { - var href = link.getAttribute("href"); - - if (href.indexOf("mailto:") === 0) { - return; - } - - var absolute = href.indexOf("://") > -1; - - if (absolute) { - - link.setAttribute("target", "_blank"); - } else { - var linkUrl; - try { - linkUrl = new _url2.default(href, location); - } catch (error) { - // NOOP - } - - link.onclick = function () { - - if (linkUrl && linkUrl.hash) { - fn(linkUrl.Path.path + linkUrl.hash); - } else if (linkUrl) { - fn(linkUrl.Path.path); - } else { - fn(href); - } - - return false; - }; - } - }.bind(this); - - for (var i = 0; i < links.length; i++) { - replaceLink(links[i]); - } -} - -function substitute(content, urls, replacements) { - urls.forEach(function (url, i) { - if (url && replacements[i]) { - content = content.replace(new RegExp(url, "g"), replacements[i]); - } - }); - return content; -} - -/***/ }), -/* 9 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _core = __webpack_require__(0); - -var _path = __webpack_require__(4); - -var _path2 = _interopRequireDefault(_path); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function request(url, type, withCredentials, headers) { - var supportsURL = typeof window != "undefined" ? window.URL : false; // TODO: fallback for url if window isn't defined - var BLOB_RESPONSE = supportsURL ? "blob" : "arraybuffer"; - - var deferred = new _core.defer(); - - var xhr = new XMLHttpRequest(); - - //-- Check from PDF.js: - // https://github.com/mozilla/pdf.js/blob/master/web/compatibility.js - var xhrPrototype = XMLHttpRequest.prototype; - - var header; - - if (!("overrideMimeType" in xhrPrototype)) { - // IE10 might have response, but not overrideMimeType - Object.defineProperty(xhrPrototype, "overrideMimeType", { - value: function xmlHttpRequestOverrideMimeType() {} - }); - } - - if (withCredentials) { - xhr.withCredentials = true; - } - - xhr.onreadystatechange = handler; - xhr.onerror = err; - - xhr.open("GET", url, true); - - for (header in headers) { - xhr.setRequestHeader(header, headers[header]); - } - - if (type == "json") { - xhr.setRequestHeader("Accept", "application/json"); - } - - // If type isn"t set, determine it from the file extension - if (!type) { - type = new _path2.default(url).extension; - } - - if (type == "blob") { - xhr.responseType = BLOB_RESPONSE; - } - - if ((0, _core.isXml)(type)) { - // xhr.responseType = "document"; - xhr.overrideMimeType("text/xml"); // for OPF parsing - } - - if (type == "xhtml") { - // xhr.responseType = "document"; - } - - if (type == "html" || type == "htm") { - // xhr.responseType = "document"; - } - - if (type == "binary") { - xhr.responseType = "arraybuffer"; - } - - xhr.send(); - - function err(e) { - deferred.reject(e); - } - - function handler() { - if (this.readyState === XMLHttpRequest.DONE) { - var responseXML = false; - - if (this.responseType === "" || this.responseType === "document") { - responseXML = this.responseXML; - } - - if (this.status === 200 || this.status === 0 || responseXML) { - //-- Firefox is reporting 0 for blob urls - var r; - - if (!this.response && !responseXML) { - deferred.reject({ - status: this.status, - message: "Empty Response", - stack: new Error().stack - }); - return deferred.promise; - } - - if (this.status === 403) { - deferred.reject({ - status: this.status, - response: this.response, - message: "Forbidden", - stack: new Error().stack - }); - return deferred.promise; - } - if (responseXML) { - r = this.responseXML; - } else if ((0, _core.isXml)(type)) { - // xhr.overrideMimeType("text/xml"); // for OPF parsing - // If this.responseXML wasn't set, try to parse using a DOMParser from text - r = (0, _core.parse)(this.response, "text/xml"); - } else if (type == "xhtml") { - r = (0, _core.parse)(this.response, "application/xhtml+xml"); - } else if (type == "html" || type == "htm") { - r = (0, _core.parse)(this.response, "text/html"); - } else if (type == "json") { - r = JSON.parse(this.response); - } else if (type == "blob") { - - if (supportsURL) { - r = this.response; - } else { - //-- Safari doesn't support responseType blob, so create a blob from arraybuffer - r = new Blob([this.response]); - } - } else { - r = this.response; - } - - deferred.resolve(r); - } else { - - deferred.reject({ - status: this.status, - message: this.response, - stack: new Error().stack - }); - } - } - } - - return deferred.promise; -} - -exports.default = request; -module.exports = exports["default"]; - -/***/ }), -/* 10 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var _undefined = __webpack_require__(34)(); // Support ES3 engines - -module.exports = function (val) { - return (val !== _undefined) && (val !== null); -}; - - -/***/ }), -/* 11 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Hooks allow for injecting functions that must all complete in order before finishing - * They will execute in parallel but all must finish before continuing - * Functions may return a promise if they are asycn. - * @param {any} context scope of this - * @example this.content = new EPUBJS.Hook(this); - */ -var Hook = function () { - function Hook(context) { - _classCallCheck(this, Hook); - - this.context = context || this; - this.hooks = []; - } - - /** - * Adds a function to be run before a hook completes - * @example this.content.register(function(){...}); - */ - - - _createClass(Hook, [{ - key: "register", - value: function register() { - for (var i = 0; i < arguments.length; ++i) { - if (typeof arguments[i] === "function") { - this.hooks.push(arguments[i]); - } else { - // unpack array - for (var j = 0; j < arguments[i].length; ++j) { - this.hooks.push(arguments[i][j]); - } - } - } - } - - /** - * Removes a function - * @example this.content.deregister(function(){...}); - */ - - }, { - key: "deregister", - value: function deregister(func) { - var hook = void 0; - for (var i = 0; i < this.hooks.length; i++) { - hook = this.hooks[i]; - if (hook === func) { - this.hooks.splice(i, 1); - break; - } - } - } - - /** - * Triggers a hook to run all functions - * @example this.content.trigger(args).then(function(){...}); - */ - - }, { - key: "trigger", - value: function trigger() { - var args = arguments; - var context = this.context; - var promises = []; - - this.hooks.forEach(function (task) { - var executing = task.apply(context, args); - - if (executing && typeof executing["then"] === "function") { - // Task is a function that returns a promise - promises.push(executing); - } - // Otherwise Task resolves immediately, continue - }); - - return Promise.all(promises); - } - - // Adds a function to be run before a hook completes - - }, { - key: "list", - value: function list() { - return this.hooks; - } - }, { - key: "clear", - value: function clear() { - return this.hooks = []; - } - }]); - - return Hook; -}(); - -exports.default = Hook; -module.exports = exports["default"]; - -/***/ }), -/* 12 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.Task = undefined; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _core = __webpack_require__(0); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Queue for handling tasks one at a time - * @class - * @param {scope} context what this will resolve to in the tasks - */ -var Queue = function () { - function Queue(context) { - _classCallCheck(this, Queue); - - this._q = []; - this.context = context; - this.tick = _core.requestAnimationFrame; - this.running = false; - this.paused = false; - } - - /** - * Add an item to the queue - * @return {Promise} - */ - - - _createClass(Queue, [{ - key: "enqueue", - value: function enqueue() { - var deferred, promise; - var queued; - var task = [].shift.call(arguments); - var args = arguments; - - // Handle single args without context - // if(args && !Array.isArray(args)) { - // args = [args]; - // } - if (!task) { - throw new Error("No Task Provided"); - } - - if (typeof task === "function") { - - deferred = new _core.defer(); - promise = deferred.promise; - - queued = { - "task": task, - "args": args, - //"context" : context, - "deferred": deferred, - "promise": promise - }; - } else { - // Task is a promise - queued = { - "promise": task - }; - } - - this._q.push(queued); - - // Wait to start queue flush - if (this.paused == false && !this.running) { - // setTimeout(this.flush.bind(this), 0); - // this.tick.call(window, this.run.bind(this)); - this.run(); - } - - return queued.promise; - } - - /** - * Run one item - * @return {Promise} - */ - - }, { - key: "dequeue", - value: function dequeue() { - var inwait, task, result; - - if (this._q.length && !this.paused) { - inwait = this._q.shift(); - task = inwait.task; - if (task) { - // console.log(task) - - result = task.apply(this.context, inwait.args); - - if (result && typeof result["then"] === "function") { - // Task is a function that returns a promise - return result.then(function () { - inwait.deferred.resolve.apply(this.context, arguments); - }.bind(this), function () { - inwait.deferred.reject.apply(this.context, arguments); - }.bind(this)); - } else { - // Task resolves immediately - inwait.deferred.resolve.apply(this.context, result); - return inwait.promise; - } - } else if (inwait.promise) { - // Task is a promise - return inwait.promise; - } - } else { - inwait = new _core.defer(); - inwait.deferred.resolve(); - return inwait.promise; - } - } - - // Run All Immediately - - }, { - key: "dump", - value: function dump() { - while (this._q.length) { - this.dequeue(); - } - } - - /** - * Run all tasks sequentially, at convince - * @return {Promise} - */ - - }, { - key: "run", - value: function run() { - var _this = this; - - if (!this.running) { - this.running = true; - this.defered = new _core.defer(); - } - - this.tick.call(window, function () { - - if (_this._q.length) { - - _this.dequeue().then(function () { - this.run(); - }.bind(_this)); - } else { - _this.defered.resolve(); - _this.running = undefined; - } - }); - - // Unpause - if (this.paused == true) { - this.paused = false; - } - - return this.defered.promise; - } - - /** - * Flush all, as quickly as possible - * @return {Promise} - */ - - }, { - key: "flush", - value: function flush() { - - if (this.running) { - return this.running; - } - - if (this._q.length) { - this.running = this.dequeue().then(function () { - this.running = undefined; - return this.flush(); - }.bind(this)); - - return this.running; - } - } - - /** - * Clear all items in wait - */ - - }, { - key: "clear", - value: function clear() { - this._q = []; - } - - /** - * Get the number of tasks in the queue - * @return {number} tasks - */ - - }, { - key: "length", - value: function length() { - return this._q.length; - } - - /** - * Pause a running queue - */ - - }, { - key: "pause", - value: function pause() { - this.paused = true; - } - - /** - * End the queue - */ - - }, { - key: "stop", - value: function stop() { - this._q = []; - this.running = false; - this.paused = true; - } - }]); - - return Queue; -}(); - -/** - * Create a new task from a callback - * @class - * @private - * @param {function} task - * @param {array} args - * @param {scope} context - * @return {function} task - */ - - -var Task = function Task(task, args, context) { - _classCallCheck(this, Task); - - return function () { - var _this2 = this; - - var toApply = arguments || []; - - return new Promise(function (resolve, reject) { - var callback = function callback(value, err) { - if (!value && err) { - reject(err); - } else { - resolve(value); - } - }; - // Add the callback to the arguments list - toApply.push(callback); - - // Apply all arguments to the functions - task.apply(context || _this2, toApply); - }); - }; -}; - -exports.default = Queue; -exports.Task = Task; - -/***/ }), -/* 13 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -/* - From Zip.js, by Gildas Lormeau -edited down - */ - -var table = { - "application": { - "ecmascript": ["es", "ecma"], - "javascript": "js", - "ogg": "ogx", - "pdf": "pdf", - "postscript": ["ps", "ai", "eps", "epsi", "epsf", "eps2", "eps3"], - "rdf+xml": "rdf", - "smil": ["smi", "smil"], - "xhtml+xml": ["xhtml", "xht"], - "xml": ["xml", "xsl", "xsd", "opf", "ncx"], - "zip": "zip", - "x-httpd-eruby": "rhtml", - "x-latex": "latex", - "x-maker": ["frm", "maker", "frame", "fm", "fb", "book", "fbdoc"], - "x-object": "o", - "x-shockwave-flash": ["swf", "swfl"], - "x-silverlight": "scr", - "epub+zip": "epub", - "font-tdpfr": "pfr", - "inkml+xml": ["ink", "inkml"], - "json": "json", - "jsonml+json": "jsonml", - "mathml+xml": "mathml", - "metalink+xml": "metalink", - "mp4": "mp4s", - // "oebps-package+xml" : "opf", - "omdoc+xml": "omdoc", - "oxps": "oxps", - "vnd.amazon.ebook": "azw", - "widget": "wgt", - // "x-dtbncx+xml" : "ncx", - "x-dtbook+xml": "dtb", - "x-dtbresource+xml": "res", - "x-font-bdf": "bdf", - "x-font-ghostscript": "gsf", - "x-font-linux-psf": "psf", - "x-font-otf": "otf", - "x-font-pcf": "pcf", - "x-font-snf": "snf", - "x-font-ttf": ["ttf", "ttc"], - "x-font-type1": ["pfa", "pfb", "pfm", "afm"], - "x-font-woff": "woff", - "x-mobipocket-ebook": ["prc", "mobi"], - "x-mspublisher": "pub", - "x-nzb": "nzb", - "x-tgif": "obj", - "xaml+xml": "xaml", - "xml-dtd": "dtd", - "xproc+xml": "xpl", - "xslt+xml": "xslt", - "internet-property-stream": "acx", - "x-compress": "z", - "x-compressed": "tgz", - "x-gzip": "gz" - }, - "audio": { - "flac": "flac", - "midi": ["mid", "midi", "kar", "rmi"], - "mpeg": ["mpga", "mpega", "mp2", "mp3", "m4a", "mp2a", "m2a", "m3a"], - "mpegurl": "m3u", - "ogg": ["oga", "ogg", "spx"], - "x-aiff": ["aif", "aiff", "aifc"], - "x-ms-wma": "wma", - "x-wav": "wav", - "adpcm": "adp", - "mp4": "mp4a", - "webm": "weba", - "x-aac": "aac", - "x-caf": "caf", - "x-matroska": "mka", - "x-pn-realaudio-plugin": "rmp", - "xm": "xm", - "mid": ["mid", "rmi"] - }, - "image": { - "gif": "gif", - "ief": "ief", - "jpeg": ["jpeg", "jpg", "jpe"], - "pcx": "pcx", - "png": "png", - "svg+xml": ["svg", "svgz"], - "tiff": ["tiff", "tif"], - "x-icon": "ico", - "bmp": "bmp", - "webp": "webp", - "x-pict": ["pic", "pct"], - "x-tga": "tga", - "cis-cod": "cod" - }, - "text": { - "cache-manifest": ["manifest", "appcache"], - "css": "css", - "csv": "csv", - "html": ["html", "htm", "shtml", "stm"], - "mathml": "mml", - "plain": ["txt", "text", "brf", "conf", "def", "list", "log", "in", "bas"], - "richtext": "rtx", - "tab-separated-values": "tsv", - "x-bibtex": "bib" - }, - "video": { - "mpeg": ["mpeg", "mpg", "mpe", "m1v", "m2v", "mp2", "mpa", "mpv2"], - "mp4": ["mp4", "mp4v", "mpg4"], - "quicktime": ["qt", "mov"], - "ogg": "ogv", - "vnd.mpegurl": ["mxu", "m4u"], - "x-flv": "flv", - "x-la-asf": ["lsf", "lsx"], - "x-mng": "mng", - "x-ms-asf": ["asf", "asx", "asr"], - "x-ms-wm": "wm", - "x-ms-wmv": "wmv", - "x-ms-wmx": "wmx", - "x-ms-wvx": "wvx", - "x-msvideo": "avi", - "x-sgi-movie": "movie", - "x-matroska": ["mpv", "mkv", "mk3d", "mks"], - "3gpp2": "3g2", - "h261": "h261", - "h263": "h263", - "h264": "h264", - "jpeg": "jpgv", - "jpm": ["jpm", "jpgm"], - "mj2": ["mj2", "mjp2"], - "vnd.ms-playready.media.pyv": "pyv", - "vnd.uvvu.mp4": ["uvu", "uvvu"], - "vnd.vivo": "viv", - "webm": "webm", - "x-f4v": "f4v", - "x-m4v": "m4v", - "x-ms-vob": "vob", - "x-smv": "smv" - } -}; - -var mimeTypes = function () { - var type, - subtype, - val, - index, - mimeTypes = {}; - for (type in table) { - if (table.hasOwnProperty(type)) { - for (subtype in table[type]) { - if (table[type].hasOwnProperty(subtype)) { - val = table[type][subtype]; - if (typeof val == "string") { - mimeTypes[val] = type + "/" + subtype; - } else { - for (index = 0; index < val.length; index++) { - mimeTypes[val[index]] = type + "/" + subtype; - } - } - } - } - } - } - return mimeTypes; -}(); - -var defaultValue = "text/plain"; //"application/octet-stream"; - -function lookup(filename) { - return filename && mimeTypes[filename.split(".").pop().toLowerCase()] || defaultValue; -}; - -module.exports = { - 'lookup': lookup -}; - -/***/ }), -/* 14 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _eventEmitter = __webpack_require__(3); - -var _eventEmitter2 = _interopRequireDefault(_eventEmitter); - -var _core = __webpack_require__(0); - -var _epubcfi = __webpack_require__(1); - -var _epubcfi2 = _interopRequireDefault(_epubcfi); - -var _mapping = __webpack_require__(19); - -var _mapping2 = _interopRequireDefault(_mapping); - -var _replacements = __webpack_require__(8); - -var _constants = __webpack_require__(2); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -var hasNavigator = typeof navigator !== "undefined"; - -var isChrome = hasNavigator && /Chrome/.test(navigator.userAgent); -var isWebkit = hasNavigator && !isChrome && /AppleWebKit/.test(navigator.userAgent); - -var ELEMENT_NODE = 1; -var TEXT_NODE = 3; - -/** - * Handles DOM manipulation, queries and events for View contents - * @class - * @param {document} doc Document - * @param {element} content Parent Element (typically Body) - * @param {string} cfiBase Section component of CFIs - * @param {number} sectionIndex Index in Spine of Conntent's Section - */ - -var Contents = function () { - function Contents(doc, content, cfiBase, sectionIndex) { - _classCallCheck(this, Contents); - - // Blank Cfi for Parsing - this.epubcfi = new _epubcfi2.default(); - - this.document = doc; - this.documentElement = this.document.documentElement; - this.content = content || this.document.body; - this.window = this.document.defaultView; - - this._size = { - width: 0, - height: 0 - }; - - this.sectionIndex = sectionIndex || 0; - this.cfiBase = cfiBase || ""; - - this.epubReadingSystem("epub.js", _constants.EPUBJS_VERSION); - - this.listeners(); - } - - /** - * Get DOM events that are listened for and passed along - */ - - - _createClass(Contents, [{ - key: "width", - - - /** - * Get or Set width - * @param {number} [w] - * @returns {number} width - */ - value: function width(w) { - // var frame = this.documentElement; - var frame = this.content; - - if (w && (0, _core.isNumber)(w)) { - w = w + "px"; - } - - if (w) { - frame.style.width = w; - // this.content.style.width = w; - } - - return this.window.getComputedStyle(frame)["width"]; - } - - /** - * Get or Set height - * @param {number} [h] - * @returns {number} height - */ - - }, { - key: "height", - value: function height(h) { - // var frame = this.documentElement; - var frame = this.content; - - if (h && (0, _core.isNumber)(h)) { - h = h + "px"; - } - - if (h) { - frame.style.height = h; - // this.content.style.height = h; - } - - return this.window.getComputedStyle(frame)["height"]; - } - - /** - * Get or Set width of the contents - * @param {number} [w] - * @returns {number} width - */ - - }, { - key: "contentWidth", - value: function contentWidth(w) { - - var content = this.content || this.document.body; - - if (w && (0, _core.isNumber)(w)) { - w = w + "px"; - } - - if (w) { - content.style.width = w; - } - - return this.window.getComputedStyle(content)["width"]; - } - - /** - * Get or Set height of the contents - * @param {number} [h] - * @returns {number} height - */ - - }, { - key: "contentHeight", - value: function contentHeight(h) { - - var content = this.content || this.document.body; - - if (h && (0, _core.isNumber)(h)) { - h = h + "px"; - } - - if (h) { - content.style.height = h; - } - - return this.window.getComputedStyle(content)["height"]; - } - - /** - * Get the width of the text using Range - * @returns {number} width - */ - - }, { - key: "textWidth", - value: function textWidth() { - var rect = void 0; - var width = void 0; - var range = this.document.createRange(); - var content = this.content || this.document.body; - var border = (0, _core.borders)(content); - - // Select the contents of frame - range.selectNodeContents(content); - - // get the width of the text content - rect = range.getBoundingClientRect(); - width = rect.width; - - if (border && border.width) { - width += border.width; - } - - return Math.round(width); - } - - /** - * Get the height of the text using Range - * @returns {number} height - */ - - }, { - key: "textHeight", - value: function textHeight() { - var rect = void 0; - var height = void 0; - var range = this.document.createRange(); - var content = this.content || this.document.body; - var border = (0, _core.borders)(content); - - range.selectNodeContents(content); - - rect = range.getBoundingClientRect(); - height = rect.height; - - if (height && border.height) { - height += border.height; - } - - if (height && rect.top) { - height += rect.top; - } - - return Math.round(height); - } - - /** - * Get documentElement scrollWidth - * @returns {number} width - */ - - }, { - key: "scrollWidth", - value: function scrollWidth() { - var width = this.documentElement.scrollWidth; - - return width; - } - - /** - * Get documentElement scrollHeight - * @returns {number} height - */ - - }, { - key: "scrollHeight", - value: function scrollHeight() { - var height = this.documentElement.scrollHeight; - - return height; - } - - /** - * Set overflow css style of the contents - * @param {string} [overflow] - */ - - }, { - key: "overflow", - value: function overflow(_overflow) { - - if (_overflow) { - this.documentElement.style.overflow = _overflow; - } - - return this.window.getComputedStyle(this.documentElement)["overflow"]; - } - - /** - * Set overflowX css style of the documentElement - * @param {string} [overflow] - */ - - }, { - key: "overflowX", - value: function overflowX(overflow) { - - if (overflow) { - this.documentElement.style.overflowX = overflow; - } - - return this.window.getComputedStyle(this.documentElement)["overflowX"]; - } - - /** - * Set overflowY css style of the documentElement - * @param {string} [overflow] - */ - - }, { - key: "overflowY", - value: function overflowY(overflow) { - - if (overflow) { - this.documentElement.style.overflowY = overflow; - } - - return this.window.getComputedStyle(this.documentElement)["overflowY"]; - } - - /** - * Set Css styles on the contents element (typically Body) - * @param {string} property - * @param {string} value - * @param {boolean} [priority] set as "important" - */ - - }, { - key: "css", - value: function css(property, value, priority) { - var content = this.content || this.document.body; - - if (value) { - content.style.setProperty(property, value, priority ? "important" : ""); - } - - return this.window.getComputedStyle(content)[property]; - } - - /** - * Get or Set the viewport element - * @param {object} [options] - * @param {string} [options.width] - * @param {string} [options.height] - * @param {string} [options.scale] - * @param {string} [options.minimum] - * @param {string} [options.maximum] - * @param {string} [options.scalable] - */ - - }, { - key: "viewport", - value: function viewport(options) { - var _width, _height, _scale, _minimum, _maximum, _scalable; - // var width, height, scale, minimum, maximum, scalable; - var $viewport = this.document.querySelector("meta[name='viewport']"); - var parsed = { - "width": undefined, - "height": undefined, - "scale": undefined, - "minimum": undefined, - "maximum": undefined, - "scalable": undefined - }; - var newContent = []; - var settings = {}; - - /* - * check for the viewport size - * - */ - if ($viewport && $viewport.hasAttribute("content")) { - var content = $viewport.getAttribute("content"); - var _width2 = content.match(/width\s*=\s*([^,]*)/); - var _height2 = content.match(/height\s*=\s*([^,]*)/); - var _scale2 = content.match(/initial-scale\s*=\s*([^,]*)/); - var _minimum2 = content.match(/minimum-scale\s*=\s*([^,]*)/); - var _maximum2 = content.match(/maximum-scale\s*=\s*([^,]*)/); - var _scalable2 = content.match(/user-scalable\s*=\s*([^,]*)/); - - if (_width2 && _width2.length && typeof _width2[1] !== "undefined") { - parsed.width = _width2[1]; - } - if (_height2 && _height2.length && typeof _height2[1] !== "undefined") { - parsed.height = _height2[1]; - } - if (_scale2 && _scale2.length && typeof _scale2[1] !== "undefined") { - parsed.scale = _scale2[1]; - } - if (_minimum2 && _minimum2.length && typeof _minimum2[1] !== "undefined") { - parsed.minimum = _minimum2[1]; - } - if (_maximum2 && _maximum2.length && typeof _maximum2[1] !== "undefined") { - parsed.maximum = _maximum2[1]; - } - if (_scalable2 && _scalable2.length && typeof _scalable2[1] !== "undefined") { - parsed.scalable = _scalable2[1]; - } - } - - settings = (0, _core.defaults)(options || {}, parsed); - - if (options) { - if (settings.width) { - newContent.push("width=" + settings.width); - } - - if (settings.height) { - newContent.push("height=" + settings.height); - } - - if (settings.scale) { - newContent.push("initial-scale=" + settings.scale); - } - - if (settings.scalable === "no") { - newContent.push("minimum-scale=" + settings.scale); - newContent.push("maximum-scale=" + settings.scale); - newContent.push("user-scalable=" + settings.scalable); - } else { - - if (settings.scalable) { - newContent.push("user-scalable=" + settings.scalable); - } - - if (settings.minimum) { - newContent.push("minimum-scale=" + settings.minimum); - } - - if (settings.maximum) { - newContent.push("minimum-scale=" + settings.maximum); - } - } - - if (!$viewport) { - $viewport = this.document.createElement("meta"); - $viewport.setAttribute("name", "viewport"); - this.document.querySelector("head").appendChild($viewport); - } - - $viewport.setAttribute("content", newContent.join(", ")); - - this.window.scrollTo(0, 0); - } - - return settings; - } - - /** - * Event emitter for when the contents has expanded - * @private - */ - - }, { - key: "expand", - value: function expand() { - this.emit(_constants.EVENTS.CONTENTS.EXPAND); - } - - /** - * Add DOM listeners - * @private - */ - - }, { - key: "listeners", - value: function listeners() { - - this.imageLoadListeners(); - - this.mediaQueryListeners(); - - // this.fontLoadListeners(); - - this.addEventListeners(); - - this.addSelectionListeners(); - - // this.transitionListeners(); - - this.resizeListeners(); - - // this.resizeObservers(); - - this.linksHandler(); - } - - /** - * Remove DOM listeners - * @private - */ - - }, { - key: "removeListeners", - value: function removeListeners() { - - this.removeEventListeners(); - - this.removeSelectionListeners(); - - clearTimeout(this.expanding); - } - - /** - * Check if size of contents has changed and - * emit 'resize' event if it has. - * @private - */ - - }, { - key: "resizeCheck", - value: function resizeCheck() { - var width = this.textWidth(); - var height = this.textHeight(); - - if (width != this._size.width || height != this._size.height) { - - this._size = { - width: width, - height: height - }; - - this.onResize && this.onResize(this._size); - this.emit(_constants.EVENTS.CONTENTS.RESIZE, this._size); - } - } - - /** - * Poll for resize detection - * @private - */ - - }, { - key: "resizeListeners", - value: function resizeListeners() { - var width, height; - // Test size again - clearTimeout(this.expanding); - - requestAnimationFrame(this.resizeCheck.bind(this)); - this.expanding = setTimeout(this.resizeListeners.bind(this), 350); - } - - /** - * Use css transitions to detect resize - * @private - */ - - }, { - key: "transitionListeners", - value: function transitionListeners() { - var body = this.content; - - body.style['transitionProperty'] = "font, font-size, font-size-adjust, font-stretch, font-variation-settings, font-weight, width, height"; - body.style['transitionDuration'] = "0.001ms"; - body.style['transitionTimingFunction'] = "linear"; - body.style['transitionDelay'] = "0"; - - this._resizeCheck = this.resizeCheck.bind(this); - this.document.addEventListener('transitionend', this._resizeCheck); - } - - /** - * Listen for media query changes and emit 'expand' event - * Adapted from: https://github.com/tylergaw/media-query-events/blob/master/js/mq-events.js - * @private - */ - - }, { - key: "mediaQueryListeners", - value: function mediaQueryListeners() { - var sheets = this.document.styleSheets; - var mediaChangeHandler = function (m) { - if (m.matches && !this._expanding) { - setTimeout(this.expand.bind(this), 1); - } - }.bind(this); - - for (var i = 0; i < sheets.length; i += 1) { - var rules; - // Firefox errors if we access cssRules cross-domain - try { - rules = sheets[i].cssRules; - } catch (e) { - return; - } - if (!rules) return; // Stylesheets changed - for (var j = 0; j < rules.length; j += 1) { - //if (rules[j].constructor === CSSMediaRule) { - if (rules[j].media) { - var mql = this.window.matchMedia(rules[j].media.mediaText); - mql.addListener(mediaChangeHandler); - //mql.onchange = mediaChangeHandler; - } - } - } - } - - /** - * Use MutationObserver to listen for changes in the DOM and check for resize - * @private - */ - - }, { - key: "resizeObservers", - value: function resizeObservers() { - var _this = this; - - // create an observer instance - this.observer = new MutationObserver(function (mutations) { - _this.resizeCheck(); - }); - - // configuration of the observer: - var config = { attributes: true, childList: true, characterData: true, subtree: true }; - - // pass in the target node, as well as the observer options - this.observer.observe(this.document, config); - } - - /** - * Test if images are loaded or add listener for when they load - * @private - */ - - }, { - key: "imageLoadListeners", - value: function imageLoadListeners() { - var images = this.document.querySelectorAll("img"); - var img; - for (var i = 0; i < images.length; i++) { - img = images[i]; - - if (typeof img.naturalWidth !== "undefined" && img.naturalWidth === 0) { - img.onload = this.expand.bind(this); - } - } - } - - /** - * Listen for font load and check for resize when loaded - * @private - */ - - }, { - key: "fontLoadListeners", - value: function fontLoadListeners() { - if (!this.document || !this.document.fonts) { - return; - } - - this.document.fonts.ready.then(function () { - this.resizeCheck(); - }.bind(this)); - } - - /** - * Get the documentElement - * @returns {element} documentElement - */ - - }, { - key: "root", - value: function root() { - if (!this.document) return null; - return this.document.documentElement; - } - - /** - * Get the location offset of a EpubCFI or an #id - * @param {string | EpubCFI} target - * @param {string} [ignoreClass] for the cfi - * @returns { {left: Number, top: Number } - */ - - }, { - key: "locationOf", - value: function locationOf(target, ignoreClass) { - var position; - var targetPos = { "left": 0, "top": 0 }; - - if (!this.document) return targetPos; - - if (this.epubcfi.isCfiString(target)) { - var range = new _epubcfi2.default(target).toRange(this.document, ignoreClass); - - if (range) { - if (range.startContainer.nodeType === Node.ELEMENT_NODE) { - position = range.startContainer.getBoundingClientRect(); - targetPos.left = position.left; - targetPos.top = position.top; - } else { - // Webkit does not handle collapsed range bounds correctly - // https://bugs.webkit.org/show_bug.cgi?id=138949 - - // Construct a new non-collapsed range - if (isWebkit) { - var container = range.startContainer; - var newRange = new Range(); - try { - if (container.nodeType === ELEMENT_NODE) { - position = container.getBoundingClientRect(); - } else if (range.startOffset + 2 < container.length) { - newRange.setStart(container, range.startOffset); - newRange.setEnd(container, range.startOffset + 2); - position = newRange.getBoundingClientRect(); - } else if (range.startOffset - 2 > 0) { - newRange.setStart(container, range.startOffset - 2); - newRange.setEnd(container, range.startOffset); - position = newRange.getBoundingClientRect(); - } else { - // empty, return the parent element - position = container.parentNode.getBoundingClientRect(); - } - } catch (e) { - console.error(e, e.stack); - } - } else { - position = range.getBoundingClientRect(); - } - } - } - } else if (typeof target === "string" && target.indexOf("#") > -1) { - - var id = target.substring(target.indexOf("#") + 1); - var el = this.document.getElementById(id); - if (el) { - if (isWebkit) { - // Webkit reports incorrect bounding rects in Columns - var _newRange = new Range(); - _newRange.selectNode(el); - position = _newRange.getBoundingClientRect(); - } else { - position = el.getBoundingClientRect(); - } - } - } - - if (position) { - targetPos.left = position.left; - targetPos.top = position.top; - } - - return targetPos; - } - - /** - * Append a stylesheet link to the document head - * @param {string} src url - */ - - }, { - key: "addStylesheet", - value: function addStylesheet(src) { - return new Promise(function (resolve, reject) { - var $stylesheet; - var ready = false; - - if (!this.document) { - resolve(false); - return; - } - - // Check if link already exists - $stylesheet = this.document.querySelector("link[href='" + src + "']"); - if ($stylesheet) { - resolve(true); - return; // already present - } - - $stylesheet = this.document.createElement("link"); - $stylesheet.type = "text/css"; - $stylesheet.rel = "stylesheet"; - $stylesheet.href = src; - $stylesheet.onload = $stylesheet.onreadystatechange = function () { - if (!ready && (!this.readyState || this.readyState == "complete")) { - ready = true; - // Let apply - setTimeout(function () { - resolve(true); - }, 1); - } - }; - - this.document.head.appendChild($stylesheet); - }.bind(this)); - } - - /** - * Append stylesheet rules to a generate stylesheet - * Array: https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleSheet/insertRule - * Object: https://github.com/desirable-objects/json-to-css - * @param {array | object} rules - */ - - }, { - key: "addStylesheetRules", - value: function addStylesheetRules(rules) { - var styleEl; - var styleSheet; - var key = "epubjs-inserted-css"; - - if (!this.document || !rules || rules.length === 0) return; - - // Check if link already exists - styleEl = this.document.getElementById("#" + key); - if (!styleEl) { - styleEl = this.document.createElement("style"); - styleEl.id = key; - } - - // Append style element to head - this.document.head.appendChild(styleEl); - - // Grab style sheet - styleSheet = styleEl.sheet; - - if (Object.prototype.toString.call(rules) === "[object Array]") { - for (var i = 0, rl = rules.length; i < rl; i++) { - var j = 1, - rule = rules[i], - selector = rules[i][0], - propStr = ""; - // If the second argument of a rule is an array of arrays, correct our variables. - if (Object.prototype.toString.call(rule[1][0]) === "[object Array]") { - rule = rule[1]; - j = 0; - } - - for (var pl = rule.length; j < pl; j++) { - var prop = rule[j]; - propStr += prop[0] + ":" + prop[1] + (prop[2] ? " !important" : "") + ";\n"; - } - - // Insert CSS Rule - styleSheet.insertRule(selector + "{" + propStr + "}", styleSheet.cssRules.length); - } - } else { - var selectors = Object.keys(rules); - selectors.forEach(function (selector) { - var definition = rules[selector]; - if (Array.isArray(definition)) { - definition.forEach(function (item) { - var _rules = Object.keys(item); - var result = _rules.map(function (rule) { - return rule + ":" + item[rule]; - }).join(';'); - styleSheet.insertRule(selector + "{" + result + "}", styleSheet.cssRules.length); - }); - } else { - var _rules = Object.keys(definition); - var result = _rules.map(function (rule) { - return rule + ":" + definition[rule]; - }).join(';'); - styleSheet.insertRule(selector + "{" + result + "}", styleSheet.cssRules.length); - } - }); - } - } - - /** - * Append a script tag to the document head - * @param {string} src url - * @returns {Promise} loaded - */ - - }, { - key: "addScript", - value: function addScript(src) { - - return new Promise(function (resolve, reject) { - var $script; - var ready = false; - - if (!this.document) { - resolve(false); - return; - } - - $script = this.document.createElement("script"); - $script.type = "text/javascript"; - $script.async = true; - $script.src = src; - $script.onload = $script.onreadystatechange = function () { - if (!ready && (!this.readyState || this.readyState == "complete")) { - ready = true; - setTimeout(function () { - resolve(true); - }, 1); - } - }; - - this.document.head.appendChild($script); - }.bind(this)); - } - - /** - * Add a class to the contents container - * @param {string} className - */ - - }, { - key: "addClass", - value: function addClass(className) { - var content; - - if (!this.document) return; - - content = this.content || this.document.body; - - if (content) { - content.classList.add(className); - } - } - - /** - * Remove a class from the contents container - * @param {string} removeClass - */ - - }, { - key: "removeClass", - value: function removeClass(className) { - var content; - - if (!this.document) return; - - content = this.content || this.document.body; - - if (content) { - content.classList.remove(className); - } - } - - /** - * Add DOM event listeners - * @private - */ - - }, { - key: "addEventListeners", - value: function addEventListeners() { - if (!this.document) { - return; - } - - this._triggerEvent = this.triggerEvent.bind(this); - - _constants.DOM_EVENTS.forEach(function (eventName) { - this.document.addEventListener(eventName, this._triggerEvent, { passive: true }); - }, this); - } - - /** - * Remove DOM event listeners - * @private - */ - - }, { - key: "removeEventListeners", - value: function removeEventListeners() { - if (!this.document) { - return; - } - _constants.DOM_EVENTS.forEach(function (eventName) { - this.document.removeEventListener(eventName, this._triggerEvent, { passive: true }); - }, this); - this._triggerEvent = undefined; - } - - /** - * Emit passed browser events - * @private - */ - - }, { - key: "triggerEvent", - value: function triggerEvent(e) { - this.emit(e.type, e); - } - - /** - * Add listener for text selection - * @private - */ - - }, { - key: "addSelectionListeners", - value: function addSelectionListeners() { - if (!this.document) { - return; - } - this._onSelectionChange = this.onSelectionChange.bind(this); - this.document.addEventListener("selectionchange", this._onSelectionChange, { passive: true }); - } - - /** - * Remove listener for text selection - * @private - */ - - }, { - key: "removeSelectionListeners", - value: function removeSelectionListeners() { - if (!this.document) { - return; - } - this.document.removeEventListener("selectionchange", this._onSelectionChange, { passive: true }); - this._onSelectionChange = undefined; - } - - /** - * Handle getting text on selection - * @private - */ - - }, { - key: "onSelectionChange", - value: function onSelectionChange(e) { - if (this.selectionEndTimeout) { - clearTimeout(this.selectionEndTimeout); - } - this.selectionEndTimeout = setTimeout(function () { - var selection = this.window.getSelection(); - this.triggerSelectedEvent(selection); - }.bind(this), 250); - } - - /** - * Emit event on text selection - * @private - */ - - }, { - key: "triggerSelectedEvent", - value: function triggerSelectedEvent(selection) { - var range, cfirange; - - if (selection && selection.rangeCount > 0) { - range = selection.getRangeAt(0); - if (!range.collapsed) { - // cfirange = this.section.cfiFromRange(range); - cfirange = new _epubcfi2.default(range, this.cfiBase).toString(); - this.emit(_constants.EVENTS.CONTENTS.SELECTED, cfirange); - this.emit(_constants.EVENTS.CONTENTS.SELECTED_RANGE, range); - } - } - } - - /** - * Get a Dom Range from EpubCFI - * @param {EpubCFI} _cfi - * @param {string} [ignoreClass] - * @returns {Range} range - */ - - }, { - key: "range", - value: function range(_cfi, ignoreClass) { - var cfi = new _epubcfi2.default(_cfi); - return cfi.toRange(this.document, ignoreClass); - } - - /** - * Get an EpubCFI from a Dom Range - * @param {Range} range - * @param {string} [ignoreClass] - * @returns {EpubCFI} cfi - */ - - }, { - key: "cfiFromRange", - value: function cfiFromRange(range, ignoreClass) { - return new _epubcfi2.default(range, this.cfiBase, ignoreClass).toString(); - } - - /** - * Get an EpubCFI from a Dom node - * @param {node} node - * @param {string} [ignoreClass] - * @returns {EpubCFI} cfi - */ - - }, { - key: "cfiFromNode", - value: function cfiFromNode(node, ignoreClass) { - return new _epubcfi2.default(node, this.cfiBase, ignoreClass).toString(); - } - - // TODO: find where this is used - remove? - - }, { - key: "map", - value: function map(layout) { - var map = new _mapping2.default(layout); - return map.section(); - } - - /** - * Size the contents to a given width and height - * @param {number} [width] - * @param {number} [height] - */ - - }, { - key: "size", - value: function size(width, height) { - var viewport = { scale: 1.0, scalable: "no" }; - - this.layoutStyle("scrolling"); - - if (width >= 0) { - this.width(width); - viewport.width = width; - this.css("padding", "0 " + width / 12 + "px"); - } - - if (height >= 0) { - this.height(height); - viewport.height = height; - } - - this.css("margin", "0"); - this.css("box-sizing", "border-box"); - - this.viewport(viewport); - } - - /** - * Apply columns to the contents for pagination - * @param {number} width - * @param {number} height - * @param {number} columnWidth - * @param {number} gap - */ - - }, { - key: "columns", - value: function columns(width, height, columnWidth, gap) { - var COLUMN_AXIS = (0, _core.prefixed)("column-axis"); - var COLUMN_GAP = (0, _core.prefixed)("column-gap"); - var COLUMN_WIDTH = (0, _core.prefixed)("column-width"); - var COLUMN_FILL = (0, _core.prefixed)("column-fill"); - - var writingMode = this.writingMode(); - var axis = writingMode.indexOf("vertical") === 0 ? "vertical" : "horizontal"; - - this.layoutStyle("paginated"); - - // Fix body width issues if rtl is only set on body element - if (this.content.dir === "rtl") { - this.direction("rtl"); - } - - this.width(width); - this.height(height); - - // Deal with Mobile trying to scale to viewport - this.viewport({ width: width, height: height, scale: 1.0, scalable: "no" }); - - // TODO: inline-block needs more testing - // Fixes Safari column cut offs, but causes RTL issues - // this.css("display", "inline-block"); - - this.css("overflow-y", "hidden"); - this.css("margin", "0", true); - - if (axis === "vertical") { - this.css("padding-top", gap / 2 + "px", true); - this.css("padding-bottom", gap / 2 + "px", true); - this.css("padding-left", "20px"); - this.css("padding-right", "20px"); - } else { - this.css("padding-top", "20px"); - this.css("padding-bottom", "20px"); - this.css("padding-left", gap / 2 + "px", true); - this.css("padding-right", gap / 2 + "px", true); - } - - this.css("box-sizing", "border-box"); - this.css("max-width", "inherit"); - - this.css(COLUMN_AXIS, "horizontal"); - this.css(COLUMN_FILL, "auto"); - - this.css(COLUMN_GAP, gap + "px"); - this.css(COLUMN_WIDTH, columnWidth + "px"); - } - - /** - * Scale contents from center - * @param {number} scale - * @param {number} offsetX - * @param {number} offsetY - */ - - }, { - key: "scaler", - value: function scaler(scale, offsetX, offsetY) { - var scaleStr = "scale(" + scale + ")"; - var translateStr = ""; - // this.css("position", "absolute")); - this.css("transform-origin", "top left"); - - if (offsetX >= 0 || offsetY >= 0) { - translateStr = " translate(" + (offsetX || 0) + "px, " + (offsetY || 0) + "px )"; - } - - this.css("transform", scaleStr + translateStr); - } - - /** - * Fit contents into a fixed width and height - * @param {number} width - * @param {number} height - */ - - }, { - key: "fit", - value: function fit(width, height) { - var viewport = this.viewport(); - var viewportWidth = parseInt(viewport.width); - var viewportHeight = parseInt(viewport.height); - var widthScale = width / viewportWidth; - var heightScale = height / viewportHeight; - var scale = widthScale < heightScale ? widthScale : heightScale; - - // the translate does not work as intended, elements can end up unaligned - // var offsetY = (height - (viewportHeight * scale)) / 2; - // var offsetX = 0; - // if (this.sectionIndex % 2 === 1) { - // offsetX = width - (viewportWidth * scale); - // } - - this.layoutStyle("paginated"); - - // scale needs width and height to be set - this.width(viewportWidth); - this.height(viewportHeight); - this.overflow("hidden"); - - // Scale to the correct size - this.scaler(scale, 0, 0); - // this.scaler(scale, offsetX > 0 ? offsetX : 0, offsetY); - - // background images are not scaled by transform - this.css("background-size", viewportWidth * scale + "px " + viewportHeight * scale + "px"); - - this.css("background-color", "transparent"); - } - - /** - * Set the direction of the text - * @param {string} [dir="ltr"] "rtl" | "ltr" - */ - - }, { - key: "direction", - value: function direction(dir) { - if (this.documentElement) { - this.documentElement.style["direction"] = dir; - } - } - }, { - key: "mapPage", - value: function mapPage(cfiBase, layout, start, end, dev) { - var mapping = new _mapping2.default(layout, dev); - - return mapping.page(this, cfiBase, start, end); - } - - /** - * Emit event when link in content is clicked - * @private - */ - - }, { - key: "linksHandler", - value: function linksHandler() { - var _this2 = this; - - (0, _replacements.replaceLinks)(this.content, function (href) { - _this2.emit(_constants.EVENTS.CONTENTS.LINK_CLICKED, href); - }); - } - - /** - * Set the writingMode of the text - * @param {string} [mode="horizontal-tb"] "horizontal-tb" | "vertical-rl" | "vertical-lr" - */ - - }, { - key: "writingMode", - value: function writingMode(mode) { - var WRITING_MODE = (0, _core.prefixed)("writing-mode"); - - if (mode && this.documentElement) { - this.documentElement.style[WRITING_MODE] = mode; - } - - return this.window.getComputedStyle(this.documentElement)[WRITING_MODE] || ''; - } - - /** - * Set the layoutStyle of the content - * @param {string} [style="paginated"] "scrolling" | "paginated" - * @private - */ - - }, { - key: "layoutStyle", - value: function layoutStyle(style) { - - if (style) { - this._layoutStyle = style; - navigator.epubReadingSystem.layoutStyle = this._layoutStyle; - } - - return this._layoutStyle || "paginated"; - } - - /** - * Add the epubReadingSystem object to the navigator - * @param {string} name - * @param {string} version - * @private - */ - - }, { - key: "epubReadingSystem", - value: function epubReadingSystem(name, version) { - navigator.epubReadingSystem = { - name: name, - version: version, - layoutStyle: this.layoutStyle(), - hasFeature: function hasFeature(feature) { - switch (feature) { - case "dom-manipulation": - return true; - case "layout-changes": - return true; - case "touch-events": - return true; - case "mouse-events": - return true; - case "keyboard-events": - return true; - case "spine-scripting": - return false; - default: - return false; - } - } - }; - return navigator.epubReadingSystem; - } - }, { - key: "destroy", - value: function destroy() { - // Stop observing - if (this.observer) { - this.observer.disconnect(); - } - - this.document.removeEventListener('transitionend', this._resizeCheck); - - this.removeListeners(); - } - }], [{ - key: "listenedEvents", - get: function get() { - return _constants.DOM_EVENTS; - } - }]); - - return Contents; -}(); - -(0, _eventEmitter2.default)(Contents.prototype); - -exports.default = Contents; -module.exports = exports["default"]; - -/***/ }), -/* 15 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _eventEmitter = __webpack_require__(3); - -var _eventEmitter2 = _interopRequireDefault(_eventEmitter); - -var _core = __webpack_require__(0); - -var _mapping = __webpack_require__(19); - -var _mapping2 = _interopRequireDefault(_mapping); - -var _queue = __webpack_require__(12); - -var _queue2 = _interopRequireDefault(_queue); - -var _stage = __webpack_require__(59); - -var _stage2 = _interopRequireDefault(_stage); - -var _views = __webpack_require__(69); - -var _views2 = _interopRequireDefault(_views); - -var _constants = __webpack_require__(2); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -var DefaultViewManager = function () { - function DefaultViewManager(options) { - _classCallCheck(this, DefaultViewManager); - - this.name = "default"; - this.optsSettings = options.settings; - this.View = options.view; - this.request = options.request; - this.renditionQueue = options.queue; - this.q = new _queue2.default(this); - - this.settings = (0, _core.extend)(this.settings || {}, { - infinite: true, - hidden: false, - width: undefined, - height: undefined, - axis: undefined, - flow: "scrolled", - ignoreClass: "", - fullsize: undefined - }); - - (0, _core.extend)(this.settings, options.settings || {}); - - this.viewSettings = { - ignoreClass: this.settings.ignoreClass, - axis: this.settings.axis, - flow: this.settings.flow, - layout: this.layout, - method: this.settings.method, // srcdoc, blobUrl, write - width: 0, - height: 0, - forceEvenPages: true - }; - - this.rendered = false; - } - - _createClass(DefaultViewManager, [{ - key: "render", - value: function render(element, size) { - var tag = element.tagName; - - if (typeof this.settings.fullsize === "undefined" && tag && (tag.toLowerCase() == "body" || tag.toLowerCase() == "html")) { - this.settings.fullsize = true; - } - - if (this.settings.fullsize) { - this.settings.overflow = "visible"; - this.overflow = this.settings.overflow; - } - - this.settings.size = size; - - // Save the stage - this.stage = new _stage2.default({ - width: size.width, - height: size.height, - overflow: this.overflow, - hidden: this.settings.hidden, - axis: this.settings.axis, - fullsize: this.settings.fullsize, - direction: this.settings.direction - }); - - this.stage.attachTo(element); - - // Get this stage container div - this.container = this.stage.getContainer(); - - // Views array methods - this.views = new _views2.default(this.container); - - // Calculate Stage Size - this._bounds = this.bounds(); - this._stageSize = this.stage.size(); - - // Set the dimensions for views - this.viewSettings.width = this._stageSize.width; - this.viewSettings.height = this._stageSize.height; - - // Function to handle a resize event. - // Will only attach if width and height are both fixed. - this.stage.onResize(this.onResized.bind(this)); - - this.stage.onOrientationChange(this.onOrientationChange.bind(this)); - - // Add Event Listeners - this.addEventListeners(); - - // Add Layout method - // this.applyLayoutMethod(); - if (this.layout) { - this.updateLayout(); - } - - this.rendered = true; - } - }, { - key: "addEventListeners", - value: function addEventListeners() { - var scroller; - - window.addEventListener("unload", function (e) { - this.destroy(); - }.bind(this)); - - if (!this.settings.fullsize) { - scroller = this.container; - } else { - scroller = window; - } - - this._onScroll = this.onScroll.bind(this); - scroller.addEventListener("scroll", this._onScroll); - } - }, { - key: "removeEventListeners", - value: function removeEventListeners() { - var scroller; - - if (!this.settings.fullsize) { - scroller = this.container; - } else { - scroller = window; - } - - scroller.removeEventListener("scroll", this._onScroll); - this._onScroll = undefined; - } - }, { - key: "destroy", - value: function destroy() { - clearTimeout(this.orientationTimeout); - clearTimeout(this.resizeTimeout); - clearTimeout(this.afterScrolled); - - this.clear(); - - this.removeEventListeners(); - - this.stage.destroy(); - - this.rendered = false; - - /* - clearTimeout(this.trimTimeout); - if(this.settings.hidden) { - this.element.removeChild(this.wrapper); - } else { - this.element.removeChild(this.container); - } - */ - } - }, { - key: "onOrientationChange", - value: function onOrientationChange(e) { - var _window = window, - orientation = _window.orientation; - - - if (this.optsSettings.resizeOnOrientationChange) { - this.resize(); - } - - // Per ampproject: - // In IOS 10.3, the measured size of an element is incorrect if the - // element size depends on window size directly and the measurement - // happens in window.resize event. Adding a timeout for correct - // measurement. See https://github.com/ampproject/amphtml/issues/8479 - clearTimeout(this.orientationTimeout); - this.orientationTimeout = setTimeout(function () { - this.orientationTimeout = undefined; - - if (this.optsSettings.resizeOnOrientationChange) { - this.resize(); - } - - this.emit(_constants.EVENTS.MANAGERS.ORIENTATION_CHANGE, orientation); - }.bind(this), 500); - } - }, { - key: "onResized", - value: function onResized(e) { - this.resize(); - } - }, { - key: "resize", - value: function resize(width, height) { - var stageSize = this.stage.size(width, height); - - // For Safari, wait for orientation to catch up - // if the window is a square - this.winBounds = (0, _core.windowBounds)(); - if (this.orientationTimeout && this.winBounds.width === this.winBounds.height) { - // reset the stage size for next resize - this._stageSize = undefined; - return; - } - - if (this._stageSize && this._stageSize.width === stageSize.width && this._stageSize.height === stageSize.height) { - // Size is the same, no need to resize - return; - } - - this._stageSize = stageSize; - - this._bounds = this.bounds(); - - // Clear current views - this.clear(); - - // Update for new views - this.viewSettings.width = this._stageSize.width; - this.viewSettings.height = this._stageSize.height; - - this.updateLayout(); - - this.emit(_constants.EVENTS.MANAGERS.RESIZED, { - width: this._stageSize.width, - height: this._stageSize.height - }); - } - }, { - key: "createView", - value: function createView(section) { - return new this.View(section, this.viewSettings); - } - }, { - key: "display", - value: function display(section, target) { - - var displaying = new _core.defer(); - var displayed = displaying.promise; - - // Check if moving to target is needed - if (target === section.href || (0, _core.isNumber)(target)) { - target = undefined; - } - - // Check to make sure the section we want isn't already shown - var visible = this.views.find(section); - - // View is already shown, just move to correct location in view - if (visible && section) { - var offset = visible.offset(); - - if (this.settings.direction === "ltr") { - this.scrollTo(offset.left, offset.top, true); - } else { - var width = visible.width(); - this.scrollTo(offset.left + width, offset.top, true); - } - - if (target) { - var _offset = visible.locationOf(target); - this.moveTo(_offset); - } - - displaying.resolve(); - return displayed; - } - - // Hide all current views - this.clear(); - - this.add(section).then(function (view) { - - // Move to correct place within the section, if needed - if (target) { - var _offset2 = view.locationOf(target); - this.moveTo(_offset2); - } - }.bind(this), function (err) { - displaying.reject(err); - }).then(function () { - var next; - if (this.layout.name === "pre-paginated" && this.layout.divisor > 1 && section.index > 0) { - // First page (cover) should stand alone for pre-paginated books - next = section.next(); - if (next) { - return this.add(next); - } - } - }.bind(this)).then(function () { - - this.views.show(); - - displaying.resolve(); - }.bind(this)); - // .then(function(){ - // return this.hooks.display.trigger(view); - // }.bind(this)) - // .then(function(){ - // this.views.show(); - // }.bind(this)); - return displayed; - } - }, { - key: "afterDisplayed", - value: function afterDisplayed(view) { - this.emit(_constants.EVENTS.MANAGERS.ADDED, view); - } - }, { - key: "afterResized", - value: function afterResized(view) { - this.emit(_constants.EVENTS.MANAGERS.RESIZE, view.section); - } - }, { - key: "moveTo", - value: function moveTo(offset) { - var distX = 0, - distY = 0; - - if (!this.isPaginated) { - distY = offset.top; - } else { - distX = Math.floor(offset.left / this.layout.delta) * this.layout.delta; - - if (distX + this.layout.delta > this.container.scrollWidth) { - distX = this.container.scrollWidth - this.layout.delta; - } - } - this.scrollTo(distX, distY, true); - } - }, { - key: "add", - value: function add(section) { - var _this = this; - - var view = this.createView(section); - - this.views.append(view); - - // view.on(EVENTS.VIEWS.SHOWN, this.afterDisplayed.bind(this)); - view.onDisplayed = this.afterDisplayed.bind(this); - view.onResize = this.afterResized.bind(this); - - view.on(_constants.EVENTS.VIEWS.AXIS, function (axis) { - _this.updateAxis(axis); - }); - - return view.display(this.request); - } - }, { - key: "append", - value: function append(section) { - var _this2 = this; - - var view = this.createView(section); - this.views.append(view); - - view.onDisplayed = this.afterDisplayed.bind(this); - view.onResize = this.afterResized.bind(this); - - view.on(_constants.EVENTS.VIEWS.AXIS, function (axis) { - _this2.updateAxis(axis); - }); - - return view.display(this.request); - } - }, { - key: "prepend", - value: function prepend(section) { - var _this3 = this; - - var view = this.createView(section); - - view.on(_constants.EVENTS.VIEWS.RESIZED, function (bounds) { - _this3.counter(bounds); - }); - - this.views.prepend(view); - - view.onDisplayed = this.afterDisplayed.bind(this); - view.onResize = this.afterResized.bind(this); - - view.on(_constants.EVENTS.VIEWS.AXIS, function (axis) { - _this3.updateAxis(axis); - }); - - return view.display(this.request); - } - }, { - key: "counter", - value: function counter(bounds) { - if (this.settings.axis === "vertical") { - this.scrollBy(0, bounds.heightDelta, true); - } else { - this.scrollBy(bounds.widthDelta, 0, true); - } - } - - // resizeView(view) { - // - // if(this.settings.globalLayoutProperties.layout === "pre-paginated") { - // view.lock("both", this.bounds.width, this.bounds.height); - // } else { - // view.lock("width", this.bounds.width, this.bounds.height); - // } - // - // }; - - }, { - key: "next", - value: function next() { - var next; - var left; - - var dir = this.settings.direction; - - if (!this.views.length) return; - - if (this.isPaginated && this.settings.axis === "horizontal" && (!dir || dir === "ltr")) { - - this.scrollLeft = this.container.scrollLeft; - - left = this.container.scrollLeft + this.container.offsetWidth + this.layout.delta; - - if (left <= this.container.scrollWidth) { - this.scrollBy(this.layout.delta, 0, true); - } else { - next = this.views.last().section.next(); - } - } else if (this.isPaginated && this.settings.axis === "horizontal" && dir === "rtl") { - - this.scrollLeft = this.container.scrollLeft; - - left = this.container.scrollLeft; - - if (left > 0) { - this.scrollBy(this.layout.delta, 0, true); - } else { - next = this.views.last().section.next(); - } - } else if (this.isPaginated && this.settings.axis === "vertical") { - - this.scrollTop = this.container.scrollTop; - - var top = this.container.scrollTop + this.container.offsetHeight; - - if (top < this.container.scrollHeight) { - this.scrollBy(0, this.layout.height, true); - } else { - next = this.views.last().section.next(); - } - } else { - next = this.views.last().section.next(); - } - - if (next) { - this.clear(); - - return this.append(next).then(function () { - var right; - if (this.layout.name === "pre-paginated" && this.layout.divisor > 1) { - right = next.next(); - if (right) { - return this.append(right); - } - } - }.bind(this), function (err) { - return err; - }).then(function () { - this.views.show(); - }.bind(this)); - } - } - }, { - key: "prev", - value: function prev() { - var prev; - var left; - var dir = this.settings.direction; - - if (!this.views.length) return; - - if (this.isPaginated && this.settings.axis === "horizontal" && (!dir || dir === "ltr")) { - - this.scrollLeft = this.container.scrollLeft; - - left = this.container.scrollLeft; - - if (left > 0) { - this.scrollBy(-this.layout.delta, 0, true); - } else { - prev = this.views.first().section.prev(); - } - } else if (this.isPaginated && this.settings.axis === "horizontal" && dir === "rtl") { - - this.scrollLeft = this.container.scrollLeft; - - left = this.container.scrollLeft + this.container.offsetWidth + this.layout.delta; - - if (left <= this.container.scrollWidth) { - this.scrollBy(-this.layout.delta, 0, true); - } else { - prev = this.views.first().section.prev(); - } - } else if (this.isPaginated && this.settings.axis === "vertical") { - - this.scrollTop = this.container.scrollTop; - - var top = this.container.scrollTop; - - if (top > 0) { - this.scrollBy(0, -this.layout.height, true); - } else { - prev = this.views.first().section.prev(); - } - } else { - - prev = this.views.first().section.prev(); - } - - if (prev) { - this.clear(); - - return this.prepend(prev).then(function () { - var left; - if (this.layout.name === "pre-paginated" && this.layout.divisor > 1) { - left = prev.prev(); - if (left) { - return this.prepend(left); - } - } - }.bind(this), function (err) { - return err; - }).then(function () { - if (this.isPaginated && this.settings.axis === "horizontal") { - if (this.settings.direction === "rtl") { - this.scrollTo(0, 0, true); - } else { - this.scrollTo(this.container.scrollWidth - this.layout.delta, 0, true); - } - } - this.views.show(); - }.bind(this)); - } - } - }, { - key: "current", - value: function current() { - var visible = this.visible(); - if (visible.length) { - // Current is the last visible view - return visible[visible.length - 1]; - } - return null; - } - }, { - key: "clear", - value: function clear() { - - // this.q.clear(); - - if (this.views) { - this.views.hide(); - this.scrollTo(0, 0, true); - this.views.clear(); - } - } - }, { - key: "currentLocation", - value: function currentLocation() { - - if (this.settings.axis === "vertical") { - this.location = this.scrolledLocation(); - } else { - this.location = this.paginatedLocation(); - } - return this.location; - } - }, { - key: "scrolledLocation", - value: function scrolledLocation() { - var _this4 = this; - - var visible = this.visible(); - var container = this.container.getBoundingClientRect(); - var pageHeight = container.height < window.innerHeight ? container.height : window.innerHeight; - - var offset = 0; - var used = 0; - - if (this.settings.fullsize) { - offset = window.scrollY; - } - - var sections = visible.map(function (view) { - var _view$section = view.section, - index = _view$section.index, - href = _view$section.href; - - var position = view.position(); - var height = view.height(); - - var startPos = offset + container.top - position.top + used; - var endPos = startPos + pageHeight - used; - if (endPos > height) { - endPos = height; - used = endPos - startPos; - } - - var totalPages = _this4.layout.count(height, pageHeight).pages; - - var currPage = Math.ceil(startPos / pageHeight); - var pages = []; - var endPage = Math.ceil(endPos / pageHeight); - - pages = []; - for (var i = currPage; i <= endPage; i++) { - var pg = i + 1; - pages.push(pg); - } - - var mapping = _this4.mapping.page(view.contents, view.section.cfiBase, startPos, endPos); - - return { - index: index, - href: href, - pages: pages, - totalPages: totalPages, - mapping: mapping - }; - }); - - return sections; - } - }, { - key: "paginatedLocation", - value: function paginatedLocation() { - var _this5 = this; - - var visible = this.visible(); - var container = this.container.getBoundingClientRect(); - - var left = 0; - var used = 0; - - if (this.settings.fullsize) { - left = window.scrollX; - } - - var sections = visible.map(function (view) { - var _view$section2 = view.section, - index = _view$section2.index, - href = _view$section2.href; - - var offset = view.offset().left; - var position = view.position().left; - var width = view.width(); - - // Find mapping - var start = left + container.left - position + used; - var end = start + _this5.layout.width - used; - - var mapping = _this5.mapping.page(view.contents, view.section.cfiBase, start, end); - - // Find displayed pages - //console.log("pre", end, offset + width); - // if (end > offset + width) { - // end = offset + width; - // used = this.layout.pageWidth; - // } - // console.log("post", end); - - var totalPages = _this5.layout.count(width).pages; - var startPage = Math.floor(start / _this5.layout.pageWidth); - var pages = []; - var endPage = Math.floor(end / _this5.layout.pageWidth); - - // start page should not be negative - if (startPage < 0) { - startPage = 0; - endPage = endPage + 1; - } - - // Reverse page counts for rtl - if (_this5.settings.direction === "rtl") { - var tempStartPage = startPage; - startPage = totalPages - endPage; - endPage = totalPages - tempStartPage; - } - - for (var i = startPage + 1; i <= endPage; i++) { - var pg = i; - pages.push(pg); - } - - return { - index: index, - href: href, - pages: pages, - totalPages: totalPages, - mapping: mapping - }; - }); - - return sections; - } - }, { - key: "isVisible", - value: function isVisible(view, offsetPrev, offsetNext, _container) { - var position = view.position(); - var container = _container || this.bounds(); - - if (this.settings.axis === "horizontal" && position.right > container.left - offsetPrev && position.left < container.right + offsetNext) { - - return true; - } else if (this.settings.axis === "vertical" && position.bottom > container.top - offsetPrev && position.top < container.bottom + offsetNext) { - - return true; - } - - return false; - } - }, { - key: "visible", - value: function visible() { - var container = this.bounds(); - var views = this.views.displayed(); - var viewsLength = views.length; - var visible = []; - var isVisible; - var view; - - for (var i = 0; i < viewsLength; i++) { - view = views[i]; - isVisible = this.isVisible(view, 0, 0, container); - - if (isVisible === true) { - visible.push(view); - } - } - return visible; - } - }, { - key: "scrollBy", - value: function scrollBy(x, y, silent) { - var dir = this.settings.direction === "rtl" ? -1 : 1; - - if (silent) { - this.ignore = true; - } - - if (!this.settings.fullsize) { - if (x) this.container.scrollLeft += x * dir; - if (y) this.container.scrollTop += y; - } else { - window.scrollBy(x * dir, y * dir); - } - this.scrolled = true; - } - }, { - key: "scrollTo", - value: function scrollTo(x, y, silent) { - if (silent) { - this.ignore = true; - } - - if (!this.settings.fullsize) { - this.container.scrollLeft = x; - this.container.scrollTop = y; - } else { - window.scrollTo(x, y); - } - this.scrolled = true; - } - }, { - key: "onScroll", - value: function onScroll() { - var scrollTop = void 0; - var scrollLeft = void 0; - - if (!this.settings.fullsize) { - scrollTop = this.container.scrollTop; - scrollLeft = this.container.scrollLeft; - } else { - scrollTop = window.scrollY; - scrollLeft = window.scrollX; - } - - this.scrollTop = scrollTop; - this.scrollLeft = scrollLeft; - - if (!this.ignore) { - this.emit(_constants.EVENTS.MANAGERS.SCROLL, { - top: scrollTop, - left: scrollLeft - }); - - clearTimeout(this.afterScrolled); - this.afterScrolled = setTimeout(function () { - this.emit(_constants.EVENTS.MANAGERS.SCROLLED, { - top: this.scrollTop, - left: this.scrollLeft - }); - }.bind(this), 20); - } else { - this.ignore = false; - } - } - }, { - key: "bounds", - value: function bounds() { - var bounds; - - bounds = this.stage.bounds(); - - return bounds; - } - }, { - key: "applyLayout", - value: function applyLayout(layout) { - - this.layout = layout; - this.updateLayout(); - // this.manager.layout(this.layout.format); - } - }, { - key: "updateLayout", - value: function updateLayout() { - - if (!this.stage) { - return; - } - - this._stageSize = this.stage.size(); - - if (!this.isPaginated) { - this.layout.calculate(this._stageSize.width, this._stageSize.height); - } else { - this.layout.calculate(this._stageSize.width, this._stageSize.height, this.settings.gap); - - // Set the look ahead offset for what is visible - this.settings.offset = this.layout.delta; - - // this.stage.addStyleRules("iframe", [{"margin-right" : this.layout.gap + "px"}]); - } - - // Set the dimensions for views - this.viewSettings.width = this.layout.width; - this.viewSettings.height = this.layout.height; - - this.setLayout(this.layout); - } - }, { - key: "setLayout", - value: function setLayout(layout) { - - this.viewSettings.layout = layout; - - this.mapping = new _mapping2.default(layout.props, this.settings.direction, this.settings.axis); - - if (this.views) { - - this.views.forEach(function (view) { - if (view) { - view.setLayout(layout); - } - }); - } - } - }, { - key: "updateAxis", - value: function updateAxis(axis, forceUpdate) { - - if (!this.isPaginated) { - axis = "vertical"; - } - - if (!forceUpdate && axis === this.settings.axis) { - return; - } - - this.settings.axis = axis; - - this.stage && this.stage.axis(axis); - - this.viewSettings.axis = axis; - - if (this.mapping) { - this.mapping = new _mapping2.default(this.layout.props, this.settings.direction, this.settings.axis); - } - - if (this.layout) { - if (axis === "vertical") { - this.layout.spread("none"); - } else { - this.layout.spread(this.layout.settings.spread); - } - } - } - }, { - key: "updateFlow", - value: function updateFlow(flow) { - var defaultScrolledOverflow = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "auto"; - - var isPaginated = flow === "paginated" || flow === "auto"; - - this.isPaginated = isPaginated; - - if (flow === "scrolled-doc" || flow === "scrolled-continuous" || flow === "scrolled") { - this.updateAxis("vertical"); - } else { - this.updateAxis("horizontal"); - } - - this.viewSettings.flow = flow; - - if (!this.settings.overflow) { - this.overflow = isPaginated ? "hidden" : defaultScrolledOverflow; - } else { - this.overflow = this.settings.overflow; - } - - this.stage && this.stage.overflow(this.overflow); - - this.updateLayout(); - } - }, { - key: "getContents", - value: function getContents() { - var contents = []; - if (!this.views) { - return contents; - } - this.views.forEach(function (view) { - var viewContents = view && view.contents; - if (viewContents) { - contents.push(viewContents); - } - }); - return contents; - } - }, { - key: "direction", - value: function direction() { - var dir = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "ltr"; - - this.settings.direction = dir; - - this.stage && this.stage.direction(dir); - - this.viewSettings.direction = dir; - - this.updateLayout(); - } - }, { - key: "isRendered", - value: function isRendered() { - return this.rendered; - } - }]); - - return DefaultViewManager; -}(); - -//-- Enable binding events to Manager - - -(0, _eventEmitter2.default)(DefaultViewManager.prototype); - -exports.default = DefaultViewManager; -module.exports = exports["default"]; - -/***/ }), -/* 16 */ -/***/ (function(module, exports) { - -/** - * Checks if `value` is the - * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) - * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return value != null && (type == 'object' || type == 'function'); -} - -module.exports = isObject; - - -/***/ }), -/* 17 */ -/***/ (function(module, exports) { - -/* - * DOM Level 2 - * Object DOMException - * @see http://www.w3.org/TR/REC-DOM-Level-1/ecma-script-language-binding.html - * @see http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/ecma-script-binding.html - */ - -function copy(src,dest){ - for(var p in src){ - dest[p] = src[p]; - } -} -/** -^\w+\.prototype\.([_\w]+)\s*=\s*((?:.*\{\s*?[\r\n][\s\S]*?^})|\S.*?(?=[;\r\n]));? -^\w+\.prototype\.([_\w]+)\s*=\s*(\S.*?(?=[;\r\n]));? - */ -function _extends(Class,Super){ - var pt = Class.prototype; - if(Object.create){ - var ppt = Object.create(Super.prototype) - pt.__proto__ = ppt; - } - if(!(pt instanceof Super)){ - function t(){}; - t.prototype = Super.prototype; - t = new t(); - copy(pt,t); - Class.prototype = pt = t; - } - if(pt.constructor != Class){ - if(typeof Class != 'function'){ - console.error("unknow Class:"+Class) - } - pt.constructor = Class - } -} -var htmlns = 'http://www.w3.org/1999/xhtml' ; -// Node Types -var NodeType = {} -var ELEMENT_NODE = NodeType.ELEMENT_NODE = 1; -var ATTRIBUTE_NODE = NodeType.ATTRIBUTE_NODE = 2; -var TEXT_NODE = NodeType.TEXT_NODE = 3; -var CDATA_SECTION_NODE = NodeType.CDATA_SECTION_NODE = 4; -var ENTITY_REFERENCE_NODE = NodeType.ENTITY_REFERENCE_NODE = 5; -var ENTITY_NODE = NodeType.ENTITY_NODE = 6; -var PROCESSING_INSTRUCTION_NODE = NodeType.PROCESSING_INSTRUCTION_NODE = 7; -var COMMENT_NODE = NodeType.COMMENT_NODE = 8; -var DOCUMENT_NODE = NodeType.DOCUMENT_NODE = 9; -var DOCUMENT_TYPE_NODE = NodeType.DOCUMENT_TYPE_NODE = 10; -var DOCUMENT_FRAGMENT_NODE = NodeType.DOCUMENT_FRAGMENT_NODE = 11; -var NOTATION_NODE = NodeType.NOTATION_NODE = 12; - -// ExceptionCode -var ExceptionCode = {} -var ExceptionMessage = {}; -var INDEX_SIZE_ERR = ExceptionCode.INDEX_SIZE_ERR = ((ExceptionMessage[1]="Index size error"),1); -var DOMSTRING_SIZE_ERR = ExceptionCode.DOMSTRING_SIZE_ERR = ((ExceptionMessage[2]="DOMString size error"),2); -var HIERARCHY_REQUEST_ERR = ExceptionCode.HIERARCHY_REQUEST_ERR = ((ExceptionMessage[3]="Hierarchy request error"),3); -var WRONG_DOCUMENT_ERR = ExceptionCode.WRONG_DOCUMENT_ERR = ((ExceptionMessage[4]="Wrong document"),4); -var INVALID_CHARACTER_ERR = ExceptionCode.INVALID_CHARACTER_ERR = ((ExceptionMessage[5]="Invalid character"),5); -var NO_DATA_ALLOWED_ERR = ExceptionCode.NO_DATA_ALLOWED_ERR = ((ExceptionMessage[6]="No data allowed"),6); -var NO_MODIFICATION_ALLOWED_ERR = ExceptionCode.NO_MODIFICATION_ALLOWED_ERR = ((ExceptionMessage[7]="No modification allowed"),7); -var NOT_FOUND_ERR = ExceptionCode.NOT_FOUND_ERR = ((ExceptionMessage[8]="Not found"),8); -var NOT_SUPPORTED_ERR = ExceptionCode.NOT_SUPPORTED_ERR = ((ExceptionMessage[9]="Not supported"),9); -var INUSE_ATTRIBUTE_ERR = ExceptionCode.INUSE_ATTRIBUTE_ERR = ((ExceptionMessage[10]="Attribute in use"),10); -//level2 -var INVALID_STATE_ERR = ExceptionCode.INVALID_STATE_ERR = ((ExceptionMessage[11]="Invalid state"),11); -var SYNTAX_ERR = ExceptionCode.SYNTAX_ERR = ((ExceptionMessage[12]="Syntax error"),12); -var INVALID_MODIFICATION_ERR = ExceptionCode.INVALID_MODIFICATION_ERR = ((ExceptionMessage[13]="Invalid modification"),13); -var NAMESPACE_ERR = ExceptionCode.NAMESPACE_ERR = ((ExceptionMessage[14]="Invalid namespace"),14); -var INVALID_ACCESS_ERR = ExceptionCode.INVALID_ACCESS_ERR = ((ExceptionMessage[15]="Invalid access"),15); - - -function DOMException(code, message) { - if(message instanceof Error){ - var error = message; - }else{ - error = this; - Error.call(this, ExceptionMessage[code]); - this.message = ExceptionMessage[code]; - if(Error.captureStackTrace) Error.captureStackTrace(this, DOMException); - } - error.code = code; - if(message) this.message = this.message + ": " + message; - return error; -}; -DOMException.prototype = Error.prototype; -copy(ExceptionCode,DOMException) -/** - * @see http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-536297177 - * The NodeList interface provides the abstraction of an ordered collection of nodes, without defining or constraining how this collection is implemented. NodeList objects in the DOM are live. - * The items in the NodeList are accessible via an integral index, starting from 0. - */ -function NodeList() { -}; -NodeList.prototype = { - /** - * The number of nodes in the list. The range of valid child node indices is 0 to length-1 inclusive. - * @standard level1 - */ - length:0, - /** - * Returns the indexth item in the collection. If index is greater than or equal to the number of nodes in the list, this returns null. - * @standard level1 - * @param index unsigned long - * Index into the collection. - * @return Node - * The node at the indexth position in the NodeList, or null if that is not a valid index. - */ - item: function(index) { - return this[index] || null; - }, - toString:function(isHTML,nodeFilter){ - for(var buf = [], i = 0;i=0){ - var lastIndex = list.length-1 - while(i0 || key == 'xmlns'){ -// return null; -// } - //console.log() - var i = this.length; - while(i--){ - var attr = this[i]; - //console.log(attr.nodeName,key) - if(attr.nodeName == key){ - return attr; - } - } - }, - setNamedItem: function(attr) { - var el = attr.ownerElement; - if(el && el!=this._ownerElement){ - throw new DOMException(INUSE_ATTRIBUTE_ERR); - } - var oldAttr = this.getNamedItem(attr.nodeName); - _addNamedNode(this._ownerElement,this,attr,oldAttr); - return oldAttr; - }, - /* returns Node */ - setNamedItemNS: function(attr) {// raises: WRONG_DOCUMENT_ERR,NO_MODIFICATION_ALLOWED_ERR,INUSE_ATTRIBUTE_ERR - var el = attr.ownerElement, oldAttr; - if(el && el!=this._ownerElement){ - throw new DOMException(INUSE_ATTRIBUTE_ERR); - } - oldAttr = this.getNamedItemNS(attr.namespaceURI,attr.localName); - _addNamedNode(this._ownerElement,this,attr,oldAttr); - return oldAttr; - }, - - /* returns Node */ - removeNamedItem: function(key) { - var attr = this.getNamedItem(key); - _removeNamedNode(this._ownerElement,this,attr); - return attr; - - - },// raises: NOT_FOUND_ERR,NO_MODIFICATION_ALLOWED_ERR - - //for level2 - removeNamedItemNS:function(namespaceURI,localName){ - var attr = this.getNamedItemNS(namespaceURI,localName); - _removeNamedNode(this._ownerElement,this,attr); - return attr; - }, - getNamedItemNS: function(namespaceURI, localName) { - var i = this.length; - while(i--){ - var node = this[i]; - if(node.localName == localName && node.namespaceURI == namespaceURI){ - return node; - } - } - return null; - } -}; -/** - * @see http://www.w3.org/TR/REC-DOM-Level-1/level-one-core.html#ID-102161490 - */ -function DOMImplementation(/* Object */ features) { - this._features = {}; - if (features) { - for (var feature in features) { - this._features = features[feature]; - } - } -}; - -DOMImplementation.prototype = { - hasFeature: function(/* string */ feature, /* string */ version) { - var versions = this._features[feature.toLowerCase()]; - if (versions && (!version || version in versions)) { - return true; - } else { - return false; - } - }, - // Introduced in DOM Level 2: - createDocument:function(namespaceURI, qualifiedName, doctype){// raises:INVALID_CHARACTER_ERR,NAMESPACE_ERR,WRONG_DOCUMENT_ERR - var doc = new Document(); - doc.implementation = this; - doc.childNodes = new NodeList(); - doc.doctype = doctype; - if(doctype){ - doc.appendChild(doctype); - } - if(qualifiedName){ - var root = doc.createElementNS(namespaceURI,qualifiedName); - doc.appendChild(root); - } - return doc; - }, - // Introduced in DOM Level 2: - createDocumentType:function(qualifiedName, publicId, systemId){// raises:INVALID_CHARACTER_ERR,NAMESPACE_ERR - var node = new DocumentType(); - node.name = qualifiedName; - node.nodeName = qualifiedName; - node.publicId = publicId; - node.systemId = systemId; - // Introduced in DOM Level 2: - //readonly attribute DOMString internalSubset; - - //TODO:.. - // readonly attribute NamedNodeMap entities; - // readonly attribute NamedNodeMap notations; - return node; - } -}; - - -/** - * @see http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1950641247 - */ - -function Node() { -}; - -Node.prototype = { - firstChild : null, - lastChild : null, - previousSibling : null, - nextSibling : null, - attributes : null, - parentNode : null, - childNodes : null, - ownerDocument : null, - nodeValue : null, - namespaceURI : null, - prefix : null, - localName : null, - // Modified in DOM Level 2: - insertBefore:function(newChild, refChild){//raises - return _insertBefore(this,newChild,refChild); - }, - replaceChild:function(newChild, oldChild){//raises - this.insertBefore(newChild,oldChild); - if(oldChild){ - this.removeChild(oldChild); - } - }, - removeChild:function(oldChild){ - return _removeChild(this,oldChild); - }, - appendChild:function(newChild){ - return this.insertBefore(newChild,null); - }, - hasChildNodes:function(){ - return this.firstChild != null; - }, - cloneNode:function(deep){ - return cloneNode(this.ownerDocument||this,this,deep); - }, - // Modified in DOM Level 2: - normalize:function(){ - var child = this.firstChild; - while(child){ - var next = child.nextSibling; - if(next && next.nodeType == TEXT_NODE && child.nodeType == TEXT_NODE){ - this.removeChild(next); - child.appendData(next.data); - }else{ - child.normalize(); - child = next; - } - } - }, - // Introduced in DOM Level 2: - isSupported:function(feature, version){ - return this.ownerDocument.implementation.hasFeature(feature,version); - }, - // Introduced in DOM Level 2: - hasAttributes:function(){ - return this.attributes.length>0; - }, - lookupPrefix:function(namespaceURI){ - var el = this; - while(el){ - var map = el._nsMap; - //console.dir(map) - if(map){ - for(var n in map){ - if(map[n] == namespaceURI){ - return n; - } - } - } - el = el.nodeType == ATTRIBUTE_NODE?el.ownerDocument : el.parentNode; - } - return null; - }, - // Introduced in DOM Level 3: - lookupNamespaceURI:function(prefix){ - var el = this; - while(el){ - var map = el._nsMap; - //console.dir(map) - if(map){ - if(prefix in map){ - return map[prefix] ; - } - } - el = el.nodeType == ATTRIBUTE_NODE?el.ownerDocument : el.parentNode; - } - return null; - }, - // Introduced in DOM Level 3: - isDefaultNamespace:function(namespaceURI){ - var prefix = this.lookupPrefix(namespaceURI); - return prefix == null; - } -}; - - -function _xmlEncoder(c){ - return c == '<' && '<' || - c == '>' && '>' || - c == '&' && '&' || - c == '"' && '"' || - '&#'+c.charCodeAt()+';' -} - - -copy(NodeType,Node); -copy(NodeType,Node.prototype); - -/** - * @param callback return true for continue,false for break - * @return boolean true: break visit; - */ -function _visitNode(node,callback){ - if(callback(node)){ - return true; - } - if(node = node.firstChild){ - do{ - if(_visitNode(node,callback)){return true} - }while(node=node.nextSibling) - } -} - - - -function Document(){ -} -function _onAddAttribute(doc,el,newAttr){ - doc && doc._inc++; - var ns = newAttr.namespaceURI ; - if(ns == 'http://www.w3.org/2000/xmlns/'){ - //update namespace - el._nsMap[newAttr.prefix?newAttr.localName:''] = newAttr.value - } -} -function _onRemoveAttribute(doc,el,newAttr,remove){ - doc && doc._inc++; - var ns = newAttr.namespaceURI ; - if(ns == 'http://www.w3.org/2000/xmlns/'){ - //update namespace - delete el._nsMap[newAttr.prefix?newAttr.localName:''] - } -} -function _onUpdateChild(doc,el,newChild){ - if(doc && doc._inc){ - doc._inc++; - //update childNodes - var cs = el.childNodes; - if(newChild){ - cs[cs.length++] = newChild; - }else{ - //console.log(1) - var child = el.firstChild; - var i = 0; - while(child){ - cs[i++] = child; - child =child.nextSibling; - } - cs.length = i; - } - } -} - -/** - * attributes; - * children; - * - * writeable properties: - * nodeValue,Attr:value,CharacterData:data - * prefix - */ -function _removeChild(parentNode,child){ - var previous = child.previousSibling; - var next = child.nextSibling; - if(previous){ - previous.nextSibling = next; - }else{ - parentNode.firstChild = next - } - if(next){ - next.previousSibling = previous; - }else{ - parentNode.lastChild = previous; - } - _onUpdateChild(parentNode.ownerDocument,parentNode); - return child; -} -/** - * preformance key(refChild == null) - */ -function _insertBefore(parentNode,newChild,nextChild){ - var cp = newChild.parentNode; - if(cp){ - cp.removeChild(newChild);//remove and update - } - if(newChild.nodeType === DOCUMENT_FRAGMENT_NODE){ - var newFirst = newChild.firstChild; - if (newFirst == null) { - return newChild; - } - var newLast = newChild.lastChild; - }else{ - newFirst = newLast = newChild; - } - var pre = nextChild ? nextChild.previousSibling : parentNode.lastChild; - - newFirst.previousSibling = pre; - newLast.nextSibling = nextChild; - - - if(pre){ - pre.nextSibling = newFirst; - }else{ - parentNode.firstChild = newFirst; - } - if(nextChild == null){ - parentNode.lastChild = newLast; - }else{ - nextChild.previousSibling = newLast; - } - do{ - newFirst.parentNode = parentNode; - }while(newFirst !== newLast && (newFirst= newFirst.nextSibling)) - _onUpdateChild(parentNode.ownerDocument||parentNode,parentNode); - //console.log(parentNode.lastChild.nextSibling == null) - if (newChild.nodeType == DOCUMENT_FRAGMENT_NODE) { - newChild.firstChild = newChild.lastChild = null; - } - return newChild; -} -function _appendSingleChild(parentNode,newChild){ - var cp = newChild.parentNode; - if(cp){ - var pre = parentNode.lastChild; - cp.removeChild(newChild);//remove and update - var pre = parentNode.lastChild; - } - var pre = parentNode.lastChild; - newChild.parentNode = parentNode; - newChild.previousSibling = pre; - newChild.nextSibling = null; - if(pre){ - pre.nextSibling = newChild; - }else{ - parentNode.firstChild = newChild; - } - parentNode.lastChild = newChild; - _onUpdateChild(parentNode.ownerDocument,parentNode,newChild); - return newChild; - //console.log("__aa",parentNode.lastChild.nextSibling == null) -} -Document.prototype = { - //implementation : null, - nodeName : '#document', - nodeType : DOCUMENT_NODE, - doctype : null, - documentElement : null, - _inc : 1, - - insertBefore : function(newChild, refChild){//raises - if(newChild.nodeType == DOCUMENT_FRAGMENT_NODE){ - var child = newChild.firstChild; - while(child){ - var next = child.nextSibling; - this.insertBefore(child,refChild); - child = next; - } - return newChild; - } - if(this.documentElement == null && newChild.nodeType == ELEMENT_NODE){ - this.documentElement = newChild; - } - - return _insertBefore(this,newChild,refChild),(newChild.ownerDocument = this),newChild; - }, - removeChild : function(oldChild){ - if(this.documentElement == oldChild){ - this.documentElement = null; - } - return _removeChild(this,oldChild); - }, - // Introduced in DOM Level 2: - importNode : function(importedNode,deep){ - return importNode(this,importedNode,deep); - }, - // Introduced in DOM Level 2: - getElementById : function(id){ - var rtv = null; - _visitNode(this.documentElement,function(node){ - if(node.nodeType == ELEMENT_NODE){ - if(node.getAttribute('id') == id){ - rtv = node; - return true; - } - } - }) - return rtv; - }, - - //document factory method: - createElement : function(tagName){ - var node = new Element(); - node.ownerDocument = this; - node.nodeName = tagName; - node.tagName = tagName; - node.childNodes = new NodeList(); - var attrs = node.attributes = new NamedNodeMap(); - attrs._ownerElement = node; - return node; - }, - createDocumentFragment : function(){ - var node = new DocumentFragment(); - node.ownerDocument = this; - node.childNodes = new NodeList(); - return node; - }, - createTextNode : function(data){ - var node = new Text(); - node.ownerDocument = this; - node.appendData(data) - return node; - }, - createComment : function(data){ - var node = new Comment(); - node.ownerDocument = this; - node.appendData(data) - return node; - }, - createCDATASection : function(data){ - var node = new CDATASection(); - node.ownerDocument = this; - node.appendData(data) - return node; - }, - createProcessingInstruction : function(target,data){ - var node = new ProcessingInstruction(); - node.ownerDocument = this; - node.tagName = node.target = target; - node.nodeValue= node.data = data; - return node; - }, - createAttribute : function(name){ - var node = new Attr(); - node.ownerDocument = this; - node.name = name; - node.nodeName = name; - node.localName = name; - node.specified = true; - return node; - }, - createEntityReference : function(name){ - var node = new EntityReference(); - node.ownerDocument = this; - node.nodeName = name; - return node; - }, - // Introduced in DOM Level 2: - createElementNS : function(namespaceURI,qualifiedName){ - var node = new Element(); - var pl = qualifiedName.split(':'); - var attrs = node.attributes = new NamedNodeMap(); - node.childNodes = new NodeList(); - node.ownerDocument = this; - node.nodeName = qualifiedName; - node.tagName = qualifiedName; - node.namespaceURI = namespaceURI; - if(pl.length == 2){ - node.prefix = pl[0]; - node.localName = pl[1]; - }else{ - //el.prefix = null; - node.localName = qualifiedName; - } - attrs._ownerElement = node; - return node; - }, - // Introduced in DOM Level 2: - createAttributeNS : function(namespaceURI,qualifiedName){ - var node = new Attr(); - var pl = qualifiedName.split(':'); - node.ownerDocument = this; - node.nodeName = qualifiedName; - node.name = qualifiedName; - node.namespaceURI = namespaceURI; - node.specified = true; - if(pl.length == 2){ - node.prefix = pl[0]; - node.localName = pl[1]; - }else{ - //el.prefix = null; - node.localName = qualifiedName; - } - return node; - } -}; -_extends(Document,Node); - - -function Element() { - this._nsMap = {}; -}; -Element.prototype = { - nodeType : ELEMENT_NODE, - hasAttribute : function(name){ - return this.getAttributeNode(name)!=null; - }, - getAttribute : function(name){ - var attr = this.getAttributeNode(name); - return attr && attr.value || ''; - }, - getAttributeNode : function(name){ - return this.attributes.getNamedItem(name); - }, - setAttribute : function(name, value){ - var attr = this.ownerDocument.createAttribute(name); - attr.value = attr.nodeValue = "" + value; - this.setAttributeNode(attr) - }, - removeAttribute : function(name){ - var attr = this.getAttributeNode(name) - attr && this.removeAttributeNode(attr); - }, - - //four real opeartion method - appendChild:function(newChild){ - if(newChild.nodeType === DOCUMENT_FRAGMENT_NODE){ - return this.insertBefore(newChild,null); - }else{ - return _appendSingleChild(this,newChild); - } - }, - setAttributeNode : function(newAttr){ - return this.attributes.setNamedItem(newAttr); - }, - setAttributeNodeNS : function(newAttr){ - return this.attributes.setNamedItemNS(newAttr); - }, - removeAttributeNode : function(oldAttr){ - //console.log(this == oldAttr.ownerElement) - return this.attributes.removeNamedItem(oldAttr.nodeName); - }, - //get real attribute name,and remove it by removeAttributeNode - removeAttributeNS : function(namespaceURI, localName){ - var old = this.getAttributeNodeNS(namespaceURI, localName); - old && this.removeAttributeNode(old); - }, - - hasAttributeNS : function(namespaceURI, localName){ - return this.getAttributeNodeNS(namespaceURI, localName)!=null; - }, - getAttributeNS : function(namespaceURI, localName){ - var attr = this.getAttributeNodeNS(namespaceURI, localName); - return attr && attr.value || ''; - }, - setAttributeNS : function(namespaceURI, qualifiedName, value){ - var attr = this.ownerDocument.createAttributeNS(namespaceURI, qualifiedName); - attr.value = attr.nodeValue = "" + value; - this.setAttributeNode(attr) - }, - getAttributeNodeNS : function(namespaceURI, localName){ - return this.attributes.getNamedItemNS(namespaceURI, localName); - }, - - getElementsByTagName : function(tagName){ - return new LiveNodeList(this,function(base){ - var ls = []; - _visitNode(base,function(node){ - if(node !== base && node.nodeType == ELEMENT_NODE && (tagName === '*' || node.tagName == tagName)){ - ls.push(node); - } - }); - return ls; - }); - }, - getElementsByTagNameNS : function(namespaceURI, localName){ - return new LiveNodeList(this,function(base){ - var ls = []; - _visitNode(base,function(node){ - if(node !== base && node.nodeType === ELEMENT_NODE && (namespaceURI === '*' || node.namespaceURI === namespaceURI) && (localName === '*' || node.localName == localName)){ - ls.push(node); - } - }); - return ls; - - }); - } -}; -Document.prototype.getElementsByTagName = Element.prototype.getElementsByTagName; -Document.prototype.getElementsByTagNameNS = Element.prototype.getElementsByTagNameNS; - - -_extends(Element,Node); -function Attr() { -}; -Attr.prototype.nodeType = ATTRIBUTE_NODE; -_extends(Attr,Node); - - -function CharacterData() { -}; -CharacterData.prototype = { - data : '', - substringData : function(offset, count) { - return this.data.substring(offset, offset+count); - }, - appendData: function(text) { - text = this.data+text; - this.nodeValue = this.data = text; - this.length = text.length; - }, - insertData: function(offset,text) { - this.replaceData(offset,0,text); - - }, - appendChild:function(newChild){ - throw new Error(ExceptionMessage[HIERARCHY_REQUEST_ERR]) - }, - deleteData: function(offset, count) { - this.replaceData(offset,count,""); - }, - replaceData: function(offset, count, text) { - var start = this.data.substring(0,offset); - var end = this.data.substring(offset+count); - text = start + text + end; - this.nodeValue = this.data = text; - this.length = text.length; - } -} -_extends(CharacterData,Node); -function Text() { -}; -Text.prototype = { - nodeName : "#text", - nodeType : TEXT_NODE, - splitText : function(offset) { - var text = this.data; - var newText = text.substring(offset); - text = text.substring(0, offset); - this.data = this.nodeValue = text; - this.length = text.length; - var newNode = this.ownerDocument.createTextNode(newText); - if(this.parentNode){ - this.parentNode.insertBefore(newNode, this.nextSibling); - } - return newNode; - } -} -_extends(Text,CharacterData); -function Comment() { -}; -Comment.prototype = { - nodeName : "#comment", - nodeType : COMMENT_NODE -} -_extends(Comment,CharacterData); - -function CDATASection() { -}; -CDATASection.prototype = { - nodeName : "#cdata-section", - nodeType : CDATA_SECTION_NODE -} -_extends(CDATASection,CharacterData); - - -function DocumentType() { -}; -DocumentType.prototype.nodeType = DOCUMENT_TYPE_NODE; -_extends(DocumentType,Node); - -function Notation() { -}; -Notation.prototype.nodeType = NOTATION_NODE; -_extends(Notation,Node); - -function Entity() { -}; -Entity.prototype.nodeType = ENTITY_NODE; -_extends(Entity,Node); - -function EntityReference() { -}; -EntityReference.prototype.nodeType = ENTITY_REFERENCE_NODE; -_extends(EntityReference,Node); - -function DocumentFragment() { -}; -DocumentFragment.prototype.nodeName = "#document-fragment"; -DocumentFragment.prototype.nodeType = DOCUMENT_FRAGMENT_NODE; -_extends(DocumentFragment,Node); - - -function ProcessingInstruction() { -} -ProcessingInstruction.prototype.nodeType = PROCESSING_INSTRUCTION_NODE; -_extends(ProcessingInstruction,Node); -function XMLSerializer(){} -XMLSerializer.prototype.serializeToString = function(node,isHtml,nodeFilter){ - return nodeSerializeToString.call(node,isHtml,nodeFilter); -} -Node.prototype.toString = nodeSerializeToString; -function nodeSerializeToString(isHtml,nodeFilter){ - var buf = []; - var refNode = this.nodeType == 9?this.documentElement:this; - var prefix = refNode.prefix; - var uri = refNode.namespaceURI; - - if(uri && prefix == null){ - //console.log(prefix) - var prefix = refNode.lookupPrefix(uri); - if(prefix == null){ - //isHTML = true; - var visibleNamespaces=[ - {namespace:uri,prefix:null} - //{namespace:uri,prefix:''} - ] - } - } - serializeToString(this,buf,isHtml,nodeFilter,visibleNamespaces); - //console.log('###',this.nodeType,uri,prefix,buf.join('')) - return buf.join(''); -} -function needNamespaceDefine(node,isHTML, visibleNamespaces) { - var prefix = node.prefix||''; - var uri = node.namespaceURI; - if (!prefix && !uri){ - return false; - } - if (prefix === "xml" && uri === "http://www.w3.org/XML/1998/namespace" - || uri == 'http://www.w3.org/2000/xmlns/'){ - return false; - } - - var i = visibleNamespaces.length - //console.log('@@@@',node.tagName,prefix,uri,visibleNamespaces) - while (i--) { - var ns = visibleNamespaces[i]; - // get namespace prefix - //console.log(node.nodeType,node.tagName,ns.prefix,prefix) - if (ns.prefix == prefix){ - return ns.namespace != uri; - } - } - //console.log(isHTML,uri,prefix=='') - //if(isHTML && prefix ==null && uri == 'http://www.w3.org/1999/xhtml'){ - // return false; - //} - //node.flag = '11111' - //console.error(3,true,node.flag,node.prefix,node.namespaceURI) - return true; -} -function serializeToString(node,buf,isHTML,nodeFilter,visibleNamespaces){ - if(nodeFilter){ - node = nodeFilter(node); - if(node){ - if(typeof node == 'string'){ - buf.push(node); - return; - } - }else{ - return; - } - //buf.sort.apply(attrs, attributeSorter); - } - switch(node.nodeType){ - case ELEMENT_NODE: - if (!visibleNamespaces) visibleNamespaces = []; - var startVisibleNamespaces = visibleNamespaces.length; - var attrs = node.attributes; - var len = attrs.length; - var child = node.firstChild; - var nodeName = node.tagName; - - isHTML = (htmlns === node.namespaceURI) ||isHTML - buf.push('<',nodeName); - - - - for(var i=0;i'); - //if is cdata child node - if(isHTML && /^script$/i.test(nodeName)){ - while(child){ - if(child.data){ - buf.push(child.data); - }else{ - serializeToString(child,buf,isHTML,nodeFilter,visibleNamespaces); - } - child = child.nextSibling; - } - }else - { - while(child){ - serializeToString(child,buf,isHTML,nodeFilter,visibleNamespaces); - child = child.nextSibling; - } - } - buf.push(''); - }else{ - buf.push('/>'); - } - // remove added visible namespaces - //visibleNamespaces.length = startVisibleNamespaces; - return; - case DOCUMENT_NODE: - case DOCUMENT_FRAGMENT_NODE: - var child = node.firstChild; - while(child){ - serializeToString(child,buf,isHTML,nodeFilter,visibleNamespaces); - child = child.nextSibling; - } - return; - case ATTRIBUTE_NODE: - return buf.push(' ',node.name,'="',node.value.replace(/[<&"]/g,_xmlEncoder),'"'); - case TEXT_NODE: - return buf.push(node.data.replace(/[<&]/g,_xmlEncoder)); - case CDATA_SECTION_NODE: - return buf.push( ''); - case COMMENT_NODE: - return buf.push( ""); - case DOCUMENT_TYPE_NODE: - var pubid = node.publicId; - var sysid = node.systemId; - buf.push(''); - }else if(sysid && sysid!='.'){ - buf.push(' SYSTEM "',sysid,'">'); - }else{ - var sub = node.internalSubset; - if(sub){ - buf.push(" [",sub,"]"); - } - buf.push(">"); - } - return; - case PROCESSING_INSTRUCTION_NODE: - return buf.push( ""); - case ENTITY_REFERENCE_NODE: - return buf.push( '&',node.nodeName,';'); - //case ENTITY_NODE: - //case NOTATION_NODE: - default: - buf.push('??',node.nodeName); - } -} -function importNode(doc,node,deep){ - var node2; - switch (node.nodeType) { - case ELEMENT_NODE: - node2 = node.cloneNode(false); - node2.ownerDocument = doc; - //var attrs = node2.attributes; - //var len = attrs.length; - //for(var i=0;i 0) && (this.settings.height === 0 || this.settings.height > 0)) { - // viewport = "width="+this.settings.width+", height="+this.settings.height+""; - } - - properties = { - layout: layout, - spread: spread, - orientation: orientation, - flow: flow, - viewport: viewport, - minSpreadWidth: minSpreadWidth, - direction: direction - }; - - return properties; - } - - /** - * Adjust the flow of the rendition to paginated or scrolled - * (scrolled-continuous vs scrolled-doc are handled by different view managers) - * @param {string} flow - */ - - }, { - key: "flow", - value: function flow(_flow2) { - var _flow = _flow2; - if (_flow2 === "scrolled" || _flow2 === "scrolled-doc" || _flow2 === "scrolled-continuous") { - _flow = "scrolled"; - } - - if (_flow2 === "auto" || _flow2 === "paginated") { - _flow = "paginated"; - } - - this.settings.flow = _flow2; - - if (this._layout) { - this._layout.flow(_flow); - } - - if (this.manager && this._layout) { - this.manager.applyLayout(this._layout); - } - - if (this.manager) { - this.manager.updateFlow(_flow); - } - - if (this.manager && this.manager.isRendered() && this.location) { - this.manager.clear(); - this.display(this.location.start.cfi); - } - } - - /** - * Adjust the layout of the rendition to reflowable or pre-paginated - * @param {object} settings - */ - - }, { - key: "layout", - value: function layout(settings) { - var _this4 = this; - - if (settings) { - this._layout = new _layout2.default(settings); - this._layout.spread(settings.spread, this.settings.minSpreadWidth); - - // this.mapping = new Mapping(this._layout.props); - - this._layout.on(_constants.EVENTS.LAYOUT.UPDATED, function (props, changed) { - _this4.emit(_constants.EVENTS.RENDITION.LAYOUT, props, changed); - }); - } - - if (this.manager && this._layout) { - this.manager.applyLayout(this._layout); - } - - return this._layout; - } - - /** - * Adjust if the rendition uses spreads - * @param {string} spread none | auto (TODO: implement landscape, portrait, both) - * @param {int} [min] min width to use spreads at - */ - - }, { - key: "spread", - value: function spread(_spread, min) { - - this.settings.spread = _spread; - - if (min) { - this.settings.minSpreadWidth = min; - } - - if (this._layout) { - this._layout.spread(_spread, min); - } - - if (this.manager && this.manager.isRendered()) { - this.manager.updateLayout(); - } - } - - /** - * Adjust the direction of the rendition - * @param {string} dir - */ - - }, { - key: "direction", - value: function direction(dir) { - - this.settings.direction = dir || "ltr"; - - if (this.manager) { - this.manager.direction(this.settings.direction); - } - - if (this.manager && this.manager.isRendered() && this.location) { - this.manager.clear(); - this.display(this.location.start.cfi); - } - } - - /** - * Report the current location - * @fires relocated - * @fires locationChanged - */ - - }, { - key: "reportLocation", - value: function reportLocation() { - return this.q.enqueue(function reportedLocation() { - requestAnimationFrame(function reportedLocationAfterRAF() { - var location = this.manager.currentLocation(); - if (location && location.then && typeof location.then === "function") { - location.then(function (result) { - var located = this.located(result); - - if (!located || !located.start || !located.end) { - return; - } - - this.location = located; - - this.emit(_constants.EVENTS.RENDITION.LOCATION_CHANGED, { - index: this.location.start.index, - href: this.location.start.href, - start: this.location.start.cfi, - end: this.location.end.cfi, - percentage: this.location.start.percentage - }); - - this.emit(_constants.EVENTS.RENDITION.RELOCATED, this.location); - }.bind(this)); - } else if (location) { - var located = this.located(location); - - if (!located || !located.start || !located.end) { - return; - } - - this.location = located; - - /** - * @event locationChanged - * @deprecated - * @type {object} - * @property {number} index - * @property {string} href - * @property {EpubCFI} start - * @property {EpubCFI} end - * @property {number} percentage - * @memberof Rendition - */ - this.emit(_constants.EVENTS.RENDITION.LOCATION_CHANGED, { - index: this.location.start.index, - href: this.location.start.href, - start: this.location.start.cfi, - end: this.location.end.cfi, - percentage: this.location.start.percentage - }); - - /** - * @event relocated - * @type {displayedLocation} - * @memberof Rendition - */ - this.emit(_constants.EVENTS.RENDITION.RELOCATED, this.location); - } - }.bind(this)); - }.bind(this)); - } - - /** - * Get the Current Location object - * @return {displayedLocation | promise} location (may be a promise) - */ - - }, { - key: "currentLocation", - value: function currentLocation() { - var location = this.manager.currentLocation(); - if (location && location.then && typeof location.then === "function") { - location.then(function (result) { - var located = this.located(result); - return located; - }.bind(this)); - } else if (location) { - var located = this.located(location); - return located; - } - } - - /** - * Creates a Rendition#locationRange from location - * passed by the Manager - * @returns {displayedLocation} - * @private - */ - - }, { - key: "located", - value: function located(location) { - if (!location.length) { - return {}; - } - var start = location[0]; - var end = location[location.length - 1]; - - var located = { - start: { - index: start.index, - href: start.href, - cfi: start.mapping.start, - displayed: { - page: start.pages[0] || 1, - total: start.totalPages - } - }, - end: { - index: end.index, - href: end.href, - cfi: end.mapping.end, - displayed: { - page: end.pages[end.pages.length - 1] || 1, - total: end.totalPages - } - } - }; - - var locationStart = this.book.locations.locationFromCfi(start.mapping.start); - var locationEnd = this.book.locations.locationFromCfi(end.mapping.end); - - if (locationStart != null) { - located.start.location = locationStart; - located.start.percentage = this.book.locations.percentageFromLocation(locationStart); - } - if (locationEnd != null) { - located.end.location = locationEnd; - located.end.percentage = this.book.locations.percentageFromLocation(locationEnd); - } - - var pageStart = this.book.pageList.pageFromCfi(start.mapping.start); - var pageEnd = this.book.pageList.pageFromCfi(end.mapping.end); - - if (pageStart != -1) { - located.start.page = pageStart; - } - if (pageEnd != -1) { - located.end.page = pageEnd; - } - - if (end.index === this.book.spine.last().index && located.end.displayed.page >= located.end.displayed.total) { - located.atEnd = true; - } - - if (start.index === this.book.spine.first().index && located.start.displayed.page === 1) { - located.atStart = true; - } - - return located; - } - - /** - * Remove and Clean Up the Rendition - */ - - }, { - key: "destroy", - value: function destroy() { - // Clear the queue - // this.q.clear(); - // this.q = undefined; - - this.manager && this.manager.destroy(); - - this.book = undefined; - - // this.views = null; - - // this.hooks.display.clear(); - // this.hooks.serialize.clear(); - // this.hooks.content.clear(); - // this.hooks.layout.clear(); - // this.hooks.render.clear(); - // this.hooks.show.clear(); - // this.hooks = {}; - - // this.themes.destroy(); - // this.themes = undefined; - - // this.epubcfi = undefined; - - // this.starting = undefined; - // this.started = undefined; - - } - - /** - * Pass the events from a view's Contents - * @private - * @param {Contents} view contents - */ - - }, { - key: "passEvents", - value: function passEvents(contents) { - var _this5 = this; - - _constants.DOM_EVENTS.forEach(function (e) { - contents.on(e, function (ev) { - return _this5.triggerViewEvent(ev, contents); - }); - }); - - contents.on(_constants.EVENTS.CONTENTS.SELECTED, function (e) { - return _this5.triggerSelectedEvent(e, contents); - }); - } - - /** - * Emit events passed by a view - * @private - * @param {event} e - */ - - }, { - key: "triggerViewEvent", - value: function triggerViewEvent(e, contents) { - this.emit(e.type, e, contents); - } - - /** - * Emit a selection event's CFI Range passed from a a view - * @private - * @param {EpubCFI} cfirange - */ - - }, { - key: "triggerSelectedEvent", - value: function triggerSelectedEvent(cfirange, contents) { - /** - * Emit that a text selection has occured - * @event selected - * @param {EpubCFI} cfirange - * @param {Contents} contents - * @memberof Rendition - */ - this.emit(_constants.EVENTS.RENDITION.SELECTED, cfirange, contents); - } - - /** - * Emit a markClicked event with the cfiRange and data from a mark - * @private - * @param {EpubCFI} cfirange - */ - - }, { - key: "triggerMarkEvent", - value: function triggerMarkEvent(cfiRange, data, contents) { - /** - * Emit that a mark was clicked - * @event markClicked - * @param {EpubCFI} cfirange - * @param {object} data - * @param {Contents} contents - * @memberof Rendition - */ - this.emit(_constants.EVENTS.RENDITION.MARK_CLICKED, cfiRange, data, contents); - } - - /** - * Get a Range from a Visible CFI - * @param {string} cfi EpubCfi String - * @param {string} ignoreClass - * @return {range} - */ - - }, { - key: "getRange", - value: function getRange(cfi, ignoreClass) { - var _cfi = new _epubcfi2.default(cfi); - var found = this.manager.visible().filter(function (view) { - if (_cfi.spinePos === view.index) return true; - }); - - // Should only every return 1 item - if (found.length) { - return found[0].contents.range(_cfi, ignoreClass); - } - } - - /** - * Hook to adjust images to fit in columns - * @param {Contents} contents - * @private - */ - - }, { - key: "adjustImages", - value: function adjustImages(contents) { - - if (this._layout.name === "pre-paginated") { - return new Promise(function (resolve) { - resolve(); - }); - } - - var computed = contents.window.getComputedStyle(contents.content, null); - var height = (contents.content.offsetHeight - (parseFloat(computed.paddingTop) + parseFloat(computed.paddingBottom))) * .95; - var verticalPadding = parseFloat(computed.verticalPadding); - - contents.addStylesheetRules({ - "img": { - "max-width": (this._layout.columnWidth ? this._layout.columnWidth - verticalPadding + "px" : "100%") + "!important", - "max-height": height + "px" + "!important", - "object-fit": "contain", - "page-break-inside": "avoid", - "break-inside": "avoid", - "box-sizing": "border-box" - }, - "svg": { - "max-width": (this._layout.columnWidth ? this._layout.columnWidth - verticalPadding + "px" : "100%") + "!important", - "max-height": height + "px" + "!important", - "page-break-inside": "avoid", - "break-inside": "avoid" - } - }); - - return new Promise(function (resolve, reject) { - // Wait to apply - setTimeout(function () { - resolve(); - }, 1); - }); - } - - /** - * Get the Contents object of each rendered view - * @returns {Contents[]} - */ - - }, { - key: "getContents", - value: function getContents() { - return this.manager ? this.manager.getContents() : []; - } - - /** - * Get the views member from the manager - * @returns {Views} - */ - - }, { - key: "views", - value: function views() { - var views = this.manager ? this.manager.views : undefined; - return views || []; - } - - /** - * Hook to handle link clicks in rendered content - * @param {Contents} contents - * @private - */ - - }, { - key: "handleLinks", - value: function handleLinks(contents) { - var _this6 = this; - - if (contents) { - contents.on(_constants.EVENTS.CONTENTS.LINK_CLICKED, function (href) { - var relative = _this6.book.path.relative(href); - _this6.display(relative); - }); - } - } - - /** - * Hook to handle injecting stylesheet before - * a Section is serialized - * @param {document} doc - * @param {Section} section - * @private - */ - - }, { - key: "injectStylesheet", - value: function injectStylesheet(doc, section) { - var style = doc.createElement("link"); - style.setAttribute("type", "text/css"); - style.setAttribute("rel", "stylesheet"); - style.setAttribute("href", this.settings.stylesheet); - doc.getElementsByTagName("head")[0].appendChild(style); - } - - /** - * Hook to handle injecting scripts before - * a Section is serialized - * @param {document} doc - * @param {Section} section - * @private - */ - - }, { - key: "injectScript", - value: function injectScript(doc, section) { - var script = doc.createElement("script"); - script.setAttribute("type", "text/javascript"); - script.setAttribute("src", this.settings.script); - script.textContent = " "; // Needed to prevent self closing tag - doc.getElementsByTagName("head")[0].appendChild(script); - } - - /** - * Hook to handle the document identifier before - * a Section is serialized - * @param {document} doc - * @param {Section} section - * @private - */ - - }, { - key: "injectIdentifier", - value: function injectIdentifier(doc, section) { - var ident = this.book.packaging.metadata.identifier; - var meta = doc.createElement("meta"); - meta.setAttribute("name", "dc.relation.ispartof"); - if (ident) { - meta.setAttribute("content", ident); - } - doc.getElementsByTagName("head")[0].appendChild(meta); - } - }]); - - return Rendition; -}(); - -//-- Enable binding events to Renderer - - -(0, _eventEmitter2.default)(Rendition.prototype); - -exports.default = Rendition; -module.exports = exports["default"]; - -/***/ }), -/* 19 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _epubcfi = __webpack_require__(1); - -var _epubcfi2 = _interopRequireDefault(_epubcfi); - -var _core = __webpack_require__(0); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Map text locations to CFI ranges - * @class - * @param {Layout} layout Layout to apply - * @param {string} [direction="ltr"] Text direction - * @param {string} [axis="horizontal"] vertical or horizontal axis - * @param {boolean} [dev] toggle developer highlighting - */ -var Mapping = function () { - function Mapping(layout, direction, axis, dev) { - _classCallCheck(this, Mapping); - - this.layout = layout; - this.horizontal = axis === "horizontal" ? true : false; - this.direction = direction || "ltr"; - this._dev = dev; - } - - /** - * Find CFI pairs for entire section at once - */ - - - _createClass(Mapping, [{ - key: "section", - value: function section(view) { - var ranges = this.findRanges(view); - var map = this.rangeListToCfiList(view.section.cfiBase, ranges); - - return map; - } - - /** - * Find CFI pairs for a page - * @param {Contents} contents Contents from view - * @param {string} cfiBase string of the base for a cfi - * @param {number} start position to start at - * @param {number} end position to end at - */ - - }, { - key: "page", - value: function page(contents, cfiBase, start, end) { - var root = contents && contents.document ? contents.document.body : false; - var result; - - if (!root) { - return; - } - - result = this.rangePairToCfiPair(cfiBase, { - start: this.findStart(root, start, end), - end: this.findEnd(root, start, end) - }); - - if (this._dev === true) { - var doc = contents.document; - var startRange = new _epubcfi2.default(result.start).toRange(doc); - var endRange = new _epubcfi2.default(result.end).toRange(doc); - - var selection = doc.defaultView.getSelection(); - var r = doc.createRange(); - selection.removeAllRanges(); - r.setStart(startRange.startContainer, startRange.startOffset); - r.setEnd(endRange.endContainer, endRange.endOffset); - selection.addRange(r); - } - - return result; - } - - /** - * Walk a node, preforming a function on each node it finds - * @private - * @param {Node} root Node to walkToNode - * @param {function} func walk function - * @return {*} returns the result of the walk function - */ - - }, { - key: "walk", - value: function walk(root, func) { - // IE11 has strange issue, if root is text node IE throws exception on - // calling treeWalker.nextNode(), saying - // Unexpected call to method or property access instead of returing null value - if (root && root.nodeType === Node.TEXT_NODE) { - return; - } - // safeFilter is required so that it can work in IE as filter is a function for IE - // and for other browser filter is an object. - var filter = { - acceptNode: function acceptNode(node) { - if (node.data.trim().length > 0) { - return NodeFilter.FILTER_ACCEPT; - } else { - return NodeFilter.FILTER_REJECT; - } - } - }; - var safeFilter = filter.acceptNode; - safeFilter.acceptNode = filter.acceptNode; - - var treeWalker = document.createTreeWalker(root, NodeFilter.SHOW_TEXT, safeFilter, false); - var node; - var result; - while (node = treeWalker.nextNode()) { - result = func(node); - if (result) break; - } - - return result; - } - }, { - key: "findRanges", - value: function findRanges(view) { - var columns = []; - var scrollWidth = view.contents.scrollWidth(); - var spreads = Math.ceil(scrollWidth / this.layout.spreadWidth); - var count = spreads * this.layout.divisor; - var columnWidth = this.layout.columnWidth; - var gap = this.layout.gap; - var start, end; - - for (var i = 0; i < count.pages; i++) { - start = (columnWidth + gap) * i; - end = columnWidth * (i + 1) + gap * i; - columns.push({ - start: this.findStart(view.document.body, start, end), - end: this.findEnd(view.document.body, start, end) - }); - } - - return columns; - } - - /** - * Find Start Range - * @private - * @param {Node} root root node - * @param {number} start position to start at - * @param {number} end position to end at - * @return {Range} - */ - - }, { - key: "findStart", - value: function findStart(root, start, end) { - var _this = this; - - var stack = [root]; - var $el; - var found; - var $prev = root; - - while (stack.length) { - - $el = stack.shift(); - - found = this.walk($el, function (node) { - var left, right, top, bottom; - var elPos; - var elRange; - - elPos = (0, _core.nodeBounds)(node); - - if (_this.horizontal && _this.direction === "ltr") { - - left = _this.horizontal ? elPos.left : elPos.top; - right = _this.horizontal ? elPos.right : elPos.bottom; - - if (left >= start && left <= end) { - return node; - } else if (right > start) { - return node; - } else { - $prev = node; - stack.push(node); - } - } else if (_this.horizontal && _this.direction === "rtl") { - - left = elPos.left; - right = elPos.right; - - if (right <= end && right >= start) { - return node; - } else if (left < end) { - return node; - } else { - $prev = node; - stack.push(node); - } - } else { - - top = elPos.top; - bottom = elPos.bottom; - - if (top >= start && top <= end) { - return node; - } else if (bottom > start) { - return node; - } else { - $prev = node; - stack.push(node); - } - } - }); - - if (found) { - return this.findTextStartRange(found, start, end); - } - } - - // Return last element - return this.findTextStartRange($prev, start, end); - } - - /** - * Find End Range - * @private - * @param {Node} root root node - * @param {number} start position to start at - * @param {number} end position to end at - * @return {Range} - */ - - }, { - key: "findEnd", - value: function findEnd(root, start, end) { - var _this2 = this; - - var stack = [root]; - var $el; - var $prev = root; - var found; - - while (stack.length) { - - $el = stack.shift(); - - found = this.walk($el, function (node) { - - var left, right, top, bottom; - var elPos; - var elRange; - - elPos = (0, _core.nodeBounds)(node); - - if (_this2.horizontal && _this2.direction === "ltr") { - - left = Math.round(elPos.left); - right = Math.round(elPos.right); - - if (left > end && $prev) { - return $prev; - } else if (right > end) { - return node; - } else { - $prev = node; - stack.push(node); - } - } else if (_this2.horizontal && _this2.direction === "rtl") { - - left = Math.round(_this2.horizontal ? elPos.left : elPos.top); - right = Math.round(_this2.horizontal ? elPos.right : elPos.bottom); - - if (right < start && $prev) { - return $prev; - } else if (left < start) { - return node; - } else { - $prev = node; - stack.push(node); - } - } else { - - top = Math.round(elPos.top); - bottom = Math.round(elPos.bottom); - - if (top > end && $prev) { - return $prev; - } else if (bottom > end) { - return node; - } else { - $prev = node; - stack.push(node); - } - } - }); - - if (found) { - return this.findTextEndRange(found, start, end); - } - } - - // end of chapter - return this.findTextEndRange($prev, start, end); - } - - /** - * Find Text Start Range - * @private - * @param {Node} root root node - * @param {number} start position to start at - * @param {number} end position to end at - * @return {Range} - */ - - }, { - key: "findTextStartRange", - value: function findTextStartRange(node, start, end) { - var ranges = this.splitTextNodeIntoRanges(node); - var range; - var pos; - var left, top, right; - - for (var i = 0; i < ranges.length; i++) { - range = ranges[i]; - - pos = range.getBoundingClientRect(); - - if (this.horizontal && this.direction === "ltr") { - - left = pos.left; - if (left >= start) { - return range; - } - } else if (this.horizontal && this.direction === "rtl") { - - right = pos.right; - if (right <= end) { - return range; - } - } else { - - top = pos.top; - if (top >= start) { - return range; - } - } - - // prev = range; - } - - return ranges[0]; - } - - /** - * Find Text End Range - * @private - * @param {Node} root root node - * @param {number} start position to start at - * @param {number} end position to end at - * @return {Range} - */ - - }, { - key: "findTextEndRange", - value: function findTextEndRange(node, start, end) { - var ranges = this.splitTextNodeIntoRanges(node); - var prev; - var range; - var pos; - var left, right, top, bottom; - - for (var i = 0; i < ranges.length; i++) { - range = ranges[i]; - - pos = range.getBoundingClientRect(); - - if (this.horizontal && this.direction === "ltr") { - - left = pos.left; - right = pos.right; - - if (left > end && prev) { - return prev; - } else if (right > end) { - return range; - } - } else if (this.horizontal && this.direction === "rtl") { - - left = pos.left; - right = pos.right; - - if (right < start && prev) { - return prev; - } else if (left < start) { - return range; - } - } else { - - top = pos.top; - bottom = pos.bottom; - - if (top > end && prev) { - return prev; - } else if (bottom > end) { - return range; - } - } - - prev = range; - } - - // Ends before limit - return ranges[ranges.length - 1]; - } - - /** - * Split up a text node into ranges for each word - * @private - * @param {Node} root root node - * @param {string} [_splitter] what to split on - * @return {Range[]} - */ - - }, { - key: "splitTextNodeIntoRanges", - value: function splitTextNodeIntoRanges(node, _splitter) { - var ranges = []; - var textContent = node.textContent || ""; - var text = textContent.trim(); - var range; - var doc = node.ownerDocument; - var splitter = _splitter || " "; - - var pos = text.indexOf(splitter); - - if (pos === -1 || node.nodeType != Node.TEXT_NODE) { - range = doc.createRange(); - range.selectNodeContents(node); - return [range]; - } - - range = doc.createRange(); - range.setStart(node, 0); - range.setEnd(node, pos); - ranges.push(range); - range = false; - - while (pos != -1) { - - pos = text.indexOf(splitter, pos + 1); - if (pos > 0) { - - if (range) { - range.setEnd(node, pos); - ranges.push(range); - } - - range = doc.createRange(); - range.setStart(node, pos + 1); - } - } - - if (range) { - range.setEnd(node, text.length); - ranges.push(range); - } - - return ranges; - } - - /** - * Turn a pair of ranges into a pair of CFIs - * @private - * @param {string} cfiBase base string for an EpubCFI - * @param {object} rangePair { start: Range, end: Range } - * @return {object} { start: "epubcfi(...)", end: "epubcfi(...)" } - */ - - }, { - key: "rangePairToCfiPair", - value: function rangePairToCfiPair(cfiBase, rangePair) { - - var startRange = rangePair.start; - var endRange = rangePair.end; - - startRange.collapse(true); - endRange.collapse(false); - - var startCfi = new _epubcfi2.default(startRange, cfiBase).toString(); - var endCfi = new _epubcfi2.default(endRange, cfiBase).toString(); - - return { - start: startCfi, - end: endCfi - }; - } - }, { - key: "rangeListToCfiList", - value: function rangeListToCfiList(cfiBase, columns) { - var map = []; - var cifPair; - - for (var i = 0; i < columns.length; i++) { - cifPair = this.rangePairToCfiPair(cfiBase, columns[i]); - - map.push(cifPair); - } - - return map; - } - - /** - * Set the axis for mapping - * @param {string} axis horizontal | vertical - * @return {boolean} is it horizontal? - */ - - }, { - key: "axis", - value: function axis(_axis) { - if (_axis) { - this.horizontal = _axis === "horizontal" ? true : false; - } - return this.horizontal; - } - }]); - - return Mapping; -}(); - -exports.default = Mapping; -module.exports = exports["default"]; - -/***/ }), -/* 20 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _eventEmitter = __webpack_require__(3); - -var _eventEmitter2 = _interopRequireDefault(_eventEmitter); - -var _core = __webpack_require__(0); - -var _epubcfi = __webpack_require__(1); - -var _epubcfi2 = _interopRequireDefault(_epubcfi); - -var _contents = __webpack_require__(14); - -var _contents2 = _interopRequireDefault(_contents); - -var _constants = __webpack_require__(2); - -var _marksPane = __webpack_require__(56); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -var IframeView = function () { - function IframeView(section, options) { - _classCallCheck(this, IframeView); - - this.settings = (0, _core.extend)({ - ignoreClass: "", - axis: options.layout && options.layout.props.flow === "scrolled" ? "vertical" : "horizontal", - direction: undefined, - width: 0, - height: 0, - layout: undefined, - globalLayoutProperties: {}, - method: undefined - }, options || {}); - - this.id = "epubjs-view-" + (0, _core.uuid)(); - this.section = section; - this.index = section.index; - - this.element = this.container(this.settings.axis); - - this.added = false; - this.displayed = false; - this.rendered = false; - - // this.width = this.settings.width; - // this.height = this.settings.height; - - this.fixedWidth = 0; - this.fixedHeight = 0; - - // Blank Cfi for Parsing - this.epubcfi = new _epubcfi2.default(); - - this.layout = this.settings.layout; - // Dom events to listen for - // this.listenedEvents = ["keydown", "keyup", "keypressed", "mouseup", "mousedown", "click", "touchend", "touchstart"]; - - this.pane = undefined; - this.highlights = {}; - this.underlines = {}; - this.marks = {}; - } - - _createClass(IframeView, [{ - key: "container", - value: function container(axis) { - var element = document.createElement("div"); - - element.classList.add("epub-view"); - - // this.element.style.minHeight = "100px"; - element.style.height = "0px"; - element.style.width = "0px"; - element.style.overflow = "hidden"; - element.style.position = "relative"; - element.style.display = "block"; - - if (axis && axis == "horizontal") { - element.style.flex = "none"; - } else { - element.style.flex = "initial"; - } - - return element; - } - }, { - key: "create", - value: function create() { - - if (this.iframe) { - return this.iframe; - } - - if (!this.element) { - this.element = this.createContainer(); - } - - this.iframe = document.createElement("iframe"); - this.iframe.id = this.id; - this.iframe.scrolling = "no"; // Might need to be removed: breaks ios width calculations - this.iframe.style.overflow = "hidden"; - this.iframe.seamless = "seamless"; - // Back up if seamless isn't supported - this.iframe.style.border = "none"; - - this.iframe.setAttribute("enable-annotation", "true"); - - this.resizing = true; - - // this.iframe.style.display = "none"; - this.element.style.visibility = "hidden"; - this.iframe.style.visibility = "hidden"; - - this.iframe.style.width = "0"; - this.iframe.style.height = "0"; - this._width = 0; - this._height = 0; - - this.element.setAttribute("ref", this.index); - - this.added = true; - - this.elementBounds = (0, _core.bounds)(this.element); - - // if(width || height){ - // this.resize(width, height); - // } else if(this.width && this.height){ - // this.resize(this.width, this.height); - // } else { - // this.iframeBounds = bounds(this.iframe); - // } - - - if ("srcdoc" in this.iframe) { - this.supportsSrcdoc = true; - } else { - this.supportsSrcdoc = false; - } - - if (!this.settings.method) { - this.settings.method = this.supportsSrcdoc ? "srcdoc" : "write"; - } - - return this.iframe; - } - }, { - key: "render", - value: function render(request, show) { - - // view.onLayout = this.layout.format.bind(this.layout); - this.create(); - - // Fit to size of the container, apply padding - this.size(); - - if (!this.sectionRender) { - this.sectionRender = this.section.render(request); - } - - // Render Chain - return this.sectionRender.then(function (contents) { - return this.load(contents); - }.bind(this)).then(function () { - var _this = this; - - // apply the layout function to the contents - this.layout.format(this.contents); - - // find and report the writingMode axis - var writingMode = this.contents.writingMode(); - var axis = writingMode.indexOf("vertical") === 0 ? "vertical" : "horizontal"; - - this.setAxis(axis); - this.emit(_constants.EVENTS.VIEWS.AXIS, axis); - - // Listen for events that require an expansion of the iframe - this.addListeners(); - - return new Promise(function (resolve, reject) { - // Expand the iframe to the full size of the content - _this.expand(); - resolve(); - }); - }.bind(this), function (e) { - this.emit(_constants.EVENTS.VIEWS.LOAD_ERROR, e); - return new Promise(function (resolve, reject) { - reject(e); - }); - }.bind(this)).then(function () { - this.emit(_constants.EVENTS.VIEWS.RENDERED, this.section); - }.bind(this)); - } - }, { - key: "reset", - value: function reset() { - if (this.iframe) { - this.iframe.style.width = "0"; - this.iframe.style.height = "0"; - this._width = 0; - this._height = 0; - this._textWidth = undefined; - this._contentWidth = undefined; - this._textHeight = undefined; - this._contentHeight = undefined; - } - this._needsReframe = true; - } - - // Determine locks base on settings - - }, { - key: "size", - value: function size(_width, _height) { - var width = _width || this.settings.width; - var height = _height || this.settings.height; - - if (this.layout.name === "pre-paginated") { - this.lock("both", width, height); - } else if (this.settings.axis === "horizontal") { - this.lock("height", width, height); - } else { - this.lock("width", width, height); - } - - this.settings.width = width; - this.settings.height = height; - } - - // Lock an axis to element dimensions, taking borders into account - - }, { - key: "lock", - value: function lock(what, width, height) { - var elBorders = (0, _core.borders)(this.element); - var iframeBorders; - - if (this.iframe) { - iframeBorders = (0, _core.borders)(this.iframe); - } else { - iframeBorders = { width: 0, height: 0 }; - } - - if (what == "width" && (0, _core.isNumber)(width)) { - this.lockedWidth = width - elBorders.width - iframeBorders.width; - // this.resize(this.lockedWidth, width); // width keeps ratio correct - } - - if (what == "height" && (0, _core.isNumber)(height)) { - this.lockedHeight = height - elBorders.height - iframeBorders.height; - // this.resize(width, this.lockedHeight); - } - - if (what === "both" && (0, _core.isNumber)(width) && (0, _core.isNumber)(height)) { - - this.lockedWidth = width - elBorders.width - iframeBorders.width; - this.lockedHeight = height - elBorders.height - iframeBorders.height; - // this.resize(this.lockedWidth, this.lockedHeight); - } - - if (this.displayed && this.iframe) { - - // this.contents.layout(); - this.expand(); - } - } - - // Resize a single axis based on content dimensions - - }, { - key: "expand", - value: function expand(force) { - var width = this.lockedWidth; - var height = this.lockedHeight; - var columns; - - var textWidth, textHeight; - - if (!this.iframe || this._expanding) return; - - this._expanding = true; - - if (this.layout.name === "pre-paginated") { - width = this.layout.columnWidth; - height = this.layout.height; - } - // Expand Horizontally - else if (this.settings.axis === "horizontal") { - // Get the width of the text - width = this.contents.textWidth(); - - if (width % this.layout.pageWidth > 0) { - width = Math.ceil(width / this.layout.pageWidth) * this.layout.pageWidth; - } - - if (this.settings.forceEvenPages) { - columns = width / this.layout.pageWidth; - if (this.layout.divisor > 1 && this.layout.name === "reflowable" && columns % 2 > 0) { - // add a blank page - width += this.layout.pageWidth; - } - } - } // Expand Vertically - else if (this.settings.axis === "vertical") { - height = this.contents.textHeight(); - } - - // Only Resize if dimensions have changed or - // if Frame is still hidden, so needs reframing - if (this._needsReframe || width != this._width || height != this._height) { - this.reframe(width, height); - } - - this._expanding = false; - } - }, { - key: "reframe", - value: function reframe(width, height) { - var _this2 = this; - - var size; - - if ((0, _core.isNumber)(width)) { - this.element.style.width = width + "px"; - this.iframe.style.width = width + "px"; - this._width = width; - } - - if ((0, _core.isNumber)(height)) { - this.element.style.height = height + "px"; - this.iframe.style.height = height + "px"; - this._height = height; - } - - var widthDelta = this.prevBounds ? width - this.prevBounds.width : width; - var heightDelta = this.prevBounds ? height - this.prevBounds.height : height; - - size = { - width: width, - height: height, - widthDelta: widthDelta, - heightDelta: heightDelta - }; - - this.pane && this.pane.render(); - - requestAnimationFrame(function () { - var mark = void 0; - for (var m in _this2.marks) { - if (_this2.marks.hasOwnProperty(m)) { - mark = _this2.marks[m]; - _this2.placeMark(mark.element, mark.range); - } - } - }); - - this.onResize(this, size); - - this.emit(_constants.EVENTS.VIEWS.RESIZED, size); - - this.prevBounds = size; - - this.elementBounds = (0, _core.bounds)(this.element); - } - }, { - key: "load", - value: function load(contents) { - var loading = new _core.defer(); - var loaded = loading.promise; - - if (!this.iframe) { - loading.reject(new Error("No Iframe Available")); - return loaded; - } - - this.iframe.onload = function (event) { - - this.onLoad(event, loading); - }.bind(this); - - if (this.settings.method === "blobUrl") { - this.blobUrl = (0, _core.createBlobUrl)(contents, "application/xhtml+xml"); - this.iframe.src = this.blobUrl; - this.element.appendChild(this.iframe); - } else if (this.settings.method === "srcdoc") { - this.iframe.srcdoc = contents; - this.element.appendChild(this.iframe); - } else { - - this.element.appendChild(this.iframe); - - this.document = this.iframe.contentDocument; - - if (!this.document) { - loading.reject(new Error("No Document Available")); - return loaded; - } - - this.iframe.contentDocument.open(); - this.iframe.contentDocument.write(contents); - this.iframe.contentDocument.close(); - } - - return loaded; - } - }, { - key: "onLoad", - value: function onLoad(event, promise) { - var _this3 = this; - - this.window = this.iframe.contentWindow; - this.document = this.iframe.contentDocument; - - this.contents = new _contents2.default(this.document, this.document.body, this.section.cfiBase, this.section.index); - - this.rendering = false; - - var link = this.document.querySelector("link[rel='canonical']"); - if (link) { - link.setAttribute("href", this.section.canonical); - } else { - link = this.document.createElement("link"); - link.setAttribute("rel", "canonical"); - link.setAttribute("href", this.section.canonical); - this.document.querySelector("head").appendChild(link); - } - - this.contents.on(_constants.EVENTS.CONTENTS.EXPAND, function () { - if (_this3.displayed && _this3.iframe) { - _this3.expand(); - if (_this3.contents) { - _this3.layout.format(_this3.contents); - } - } - }); - - this.contents.on(_constants.EVENTS.CONTENTS.RESIZE, function (e) { - if (_this3.displayed && _this3.iframe) { - _this3.expand(); - if (_this3.contents) { - _this3.layout.format(_this3.contents); - } - } - }); - - promise.resolve(this.contents); - } - }, { - key: "setLayout", - value: function setLayout(layout) { - this.layout = layout; - - if (this.contents) { - this.layout.format(this.contents); - this.expand(); - } - } - }, { - key: "setAxis", - value: function setAxis(axis) { - - // Force vertical for scrolled - if (this.layout.props.flow === "scrolled") { - axis = "vertical"; - } - - this.settings.axis = axis; - - if (axis == "horizontal") { - this.element.style.flex = "none"; - } else { - this.element.style.flex = "initial"; - } - - this.size(); - } - }, { - key: "addListeners", - value: function addListeners() { - //TODO: Add content listeners for expanding - } - }, { - key: "removeListeners", - value: function removeListeners(layoutFunc) { - //TODO: remove content listeners for expanding - } - }, { - key: "display", - value: function display(request) { - var displayed = new _core.defer(); - - if (!this.displayed) { - - this.render(request).then(function () { - - this.emit(_constants.EVENTS.VIEWS.DISPLAYED, this); - this.onDisplayed(this); - - this.displayed = true; - displayed.resolve(this); - }.bind(this), function (err) { - displayed.reject(err, this); - }); - } else { - displayed.resolve(this); - } - - return displayed.promise; - } - }, { - key: "show", - value: function show() { - - this.element.style.visibility = "visible"; - - if (this.iframe) { - this.iframe.style.visibility = "visible"; - - // Remind Safari to redraw the iframe - this.iframe.style.transform = "translateZ(0)"; - this.iframe.offsetWidth; - this.iframe.style.transform = null; - } - - this.emit(_constants.EVENTS.VIEWS.SHOWN, this); - } - }, { - key: "hide", - value: function hide() { - // this.iframe.style.display = "none"; - this.element.style.visibility = "hidden"; - this.iframe.style.visibility = "hidden"; - - this.stopExpanding = true; - this.emit(_constants.EVENTS.VIEWS.HIDDEN, this); - } - }, { - key: "offset", - value: function offset() { - return { - top: this.element.offsetTop, - left: this.element.offsetLeft - }; - } - }, { - key: "width", - value: function width() { - return this._width; - } - }, { - key: "height", - value: function height() { - return this._height; - } - }, { - key: "position", - value: function position() { - return this.element.getBoundingClientRect(); - } - }, { - key: "locationOf", - value: function locationOf(target) { - var parentPos = this.iframe.getBoundingClientRect(); - var targetPos = this.contents.locationOf(target, this.settings.ignoreClass); - - return { - "left": targetPos.left, - "top": targetPos.top - }; - } - }, { - key: "onDisplayed", - value: function onDisplayed(view) { - // Stub, override with a custom functions - } - }, { - key: "onResize", - value: function onResize(view, e) { - // Stub, override with a custom functions - } - }, { - key: "bounds", - value: function bounds(force) { - if (force || !this.elementBounds) { - this.elementBounds = (0, _core.bounds)(this.element); - } - - return this.elementBounds; - } - }, { - key: "highlight", - value: function highlight(cfiRange) { - var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; - var cb = arguments[2]; - - var _this4 = this; - - var className = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : "epubjs-hl"; - var styles = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {}; - - if (!this.contents) { - return; - } - var attributes = Object.assign({ "fill": "yellow", "fill-opacity": "0.3", "mix-blend-mode": "multiply" }, styles); - var range = this.contents.range(cfiRange); - - var emitter = function emitter() { - _this4.emit(_constants.EVENTS.VIEWS.MARK_CLICKED, cfiRange, data); - }; - - data["epubcfi"] = cfiRange; - - if (!this.pane) { - this.pane = new _marksPane.Pane(this.iframe, this.element); - } - - var m = new _marksPane.Highlight(range, className, data, attributes); - var h = this.pane.addMark(m); - - this.highlights[cfiRange] = { "mark": h, "element": h.element, "listeners": [emitter, cb] }; - - h.element.setAttribute("ref", className); - h.element.addEventListener("click", emitter); - h.element.addEventListener("touchstart", emitter); - - if (cb) { - h.element.addEventListener("click", cb); - h.element.addEventListener("touchstart", cb); - } - return h; - } - }, { - key: "underline", - value: function underline(cfiRange) { - var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; - var cb = arguments[2]; - - var _this5 = this; - - var className = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : "epubjs-ul"; - var styles = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {}; - - if (!this.contents) { - return; - } - var attributes = Object.assign({ "stroke": "black", "stroke-opacity": "0.3", "mix-blend-mode": "multiply" }, styles); - var range = this.contents.range(cfiRange); - var emitter = function emitter() { - _this5.emit(_constants.EVENTS.VIEWS.MARK_CLICKED, cfiRange, data); - }; - - data["epubcfi"] = cfiRange; - - if (!this.pane) { - this.pane = new _marksPane.Pane(this.iframe, this.element); - } - - var m = new _marksPane.Underline(range, className, data, attributes); - var h = this.pane.addMark(m); - - this.underlines[cfiRange] = { "mark": h, "element": h.element, "listeners": [emitter, cb] }; - - h.element.setAttribute("ref", className); - h.element.addEventListener("click", emitter); - h.element.addEventListener("touchstart", emitter); - - if (cb) { - h.element.addEventListener("click", cb); - h.element.addEventListener("touchstart", cb); - } - return h; - } - }, { - key: "mark", - value: function mark(cfiRange) { - var _this6 = this; - - var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; - var cb = arguments[2]; - - if (!this.contents) { - return; - } - - if (cfiRange in this.marks) { - var item = this.marks[cfiRange]; - return item; - } - - var range = this.contents.range(cfiRange); - if (!range) { - return; - } - var container = range.commonAncestorContainer; - var parent = container.nodeType === 1 ? container : container.parentNode; - - var emitter = function emitter(e) { - _this6.emit(_constants.EVENTS.VIEWS.MARK_CLICKED, cfiRange, data); - }; - - if (range.collapsed && container.nodeType === 1) { - range = new Range(); - range.selectNodeContents(container); - } else if (range.collapsed) { - // Webkit doesn't like collapsed ranges - range = new Range(); - range.selectNodeContents(parent); - } - - var mark = this.document.createElement("a"); - mark.setAttribute("ref", "epubjs-mk"); - mark.style.position = "absolute"; - - mark.dataset["epubcfi"] = cfiRange; - - if (data) { - Object.keys(data).forEach(function (key) { - mark.dataset[key] = data[key]; - }); - } - - if (cb) { - mark.addEventListener("click", cb); - mark.addEventListener("touchstart", cb); - } - - mark.addEventListener("click", emitter); - mark.addEventListener("touchstart", emitter); - - this.placeMark(mark, range); - - this.element.appendChild(mark); - - this.marks[cfiRange] = { "element": mark, "range": range, "listeners": [emitter, cb] }; - - return parent; - } - }, { - key: "placeMark", - value: function placeMark(element, range) { - var top = void 0, - right = void 0, - left = void 0; - - if (this.layout.name === "pre-paginated" || this.settings.axis !== "horizontal") { - var pos = range.getBoundingClientRect(); - top = pos.top; - right = pos.right; - } else { - // Element might break columns, so find the left most element - var rects = range.getClientRects(); - - var rect = void 0; - for (var i = 0; i != rects.length; i++) { - rect = rects[i]; - if (!left || rect.left < left) { - left = rect.left; - // right = rect.right; - right = Math.ceil(left / this.layout.props.pageWidth) * this.layout.props.pageWidth - this.layout.gap / 2; - top = rect.top; - } - } - } - - element.style.top = top + "px"; - element.style.left = right + "px"; - } - }, { - key: "unhighlight", - value: function unhighlight(cfiRange) { - var item = void 0; - if (cfiRange in this.highlights) { - item = this.highlights[cfiRange]; - - this.pane.removeMark(item.mark); - item.listeners.forEach(function (l) { - if (l) { - item.element.removeEventListener("click", l); - item.element.removeEventListener("touchstart", l); - }; - }); - delete this.highlights[cfiRange]; - } - } - }, { - key: "ununderline", - value: function ununderline(cfiRange) { - var item = void 0; - if (cfiRange in this.underlines) { - item = this.underlines[cfiRange]; - this.pane.removeMark(item.mark); - item.listeners.forEach(function (l) { - if (l) { - item.element.removeEventListener("click", l); - item.element.removeEventListener("touchstart", l); - }; - }); - delete this.underlines[cfiRange]; - } - } - }, { - key: "unmark", - value: function unmark(cfiRange) { - var item = void 0; - if (cfiRange in this.marks) { - item = this.marks[cfiRange]; - this.element.removeChild(item.element); - item.listeners.forEach(function (l) { - if (l) { - item.element.removeEventListener("click", l); - item.element.removeEventListener("touchstart", l); - }; - }); - delete this.marks[cfiRange]; - } - } - }, { - key: "destroy", - value: function destroy() { - - for (var cfiRange in this.highlights) { - this.unhighlight(cfiRange); - } - - for (var _cfiRange in this.underlines) { - this.ununderline(_cfiRange); - } - - for (var _cfiRange2 in this.marks) { - this.unmark(_cfiRange2); - } - - if (this.blobUrl) { - (0, _core.revokeBlobUrl)(this.blobUrl); - } - - if (this.displayed) { - this.displayed = false; - - this.removeListeners(); - this.contents.destroy(); - - this.stopExpanding = true; - this.element.removeChild(this.iframe); - - this.iframe = undefined; - this.contents = undefined; - - this._textWidth = null; - this._textHeight = null; - this._width = null; - this._height = null; - } - - // this.element.style.height = "0px"; - // this.element.style.width = "0px"; - } - }]); - - return IframeView; -}(); - -(0, _eventEmitter2.default)(IframeView.prototype); - -exports.default = IframeView; -module.exports = exports["default"]; - -/***/ }), -/* 21 */ -/***/ (function(module, exports, __webpack_require__) { - -var isObject = __webpack_require__(16), - now = __webpack_require__(61), - toNumber = __webpack_require__(63); - -/** Error message constants. */ -var FUNC_ERROR_TEXT = 'Expected a function'; - -/* Built-in method references for those with the same name as other `lodash` methods. */ -var nativeMax = Math.max, - nativeMin = Math.min; - -/** - * Creates a debounced function that delays invoking `func` until after `wait` - * milliseconds have elapsed since the last time the debounced function was - * invoked. The debounced function comes with a `cancel` method to cancel - * delayed `func` invocations and a `flush` method to immediately invoke them. - * Provide `options` to indicate whether `func` should be invoked on the - * leading and/or trailing edge of the `wait` timeout. The `func` is invoked - * with the last arguments provided to the debounced function. Subsequent - * calls to the debounced function return the result of the last `func` - * invocation. - * - * **Note:** If `leading` and `trailing` options are `true`, `func` is - * invoked on the trailing edge of the timeout only if the debounced function - * is invoked more than once during the `wait` timeout. - * - * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred - * until to the next tick, similar to `setTimeout` with a timeout of `0`. - * - * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/) - * for details over the differences between `_.debounce` and `_.throttle`. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Function - * @param {Function} func The function to debounce. - * @param {number} [wait=0] The number of milliseconds to delay. - * @param {Object} [options={}] The options object. - * @param {boolean} [options.leading=false] - * Specify invoking on the leading edge of the timeout. - * @param {number} [options.maxWait] - * The maximum time `func` is allowed to be delayed before it's invoked. - * @param {boolean} [options.trailing=true] - * Specify invoking on the trailing edge of the timeout. - * @returns {Function} Returns the new debounced function. - * @example - * - * // Avoid costly calculations while the window size is in flux. - * jQuery(window).on('resize', _.debounce(calculateLayout, 150)); - * - * // Invoke `sendMail` when clicked, debouncing subsequent calls. - * jQuery(element).on('click', _.debounce(sendMail, 300, { - * 'leading': true, - * 'trailing': false - * })); - * - * // Ensure `batchLog` is invoked once after 1 second of debounced calls. - * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 }); - * var source = new EventSource('/stream'); - * jQuery(source).on('message', debounced); - * - * // Cancel the trailing debounced invocation. - * jQuery(window).on('popstate', debounced.cancel); - */ -function debounce(func, wait, options) { - var lastArgs, - lastThis, - maxWait, - result, - timerId, - lastCallTime, - lastInvokeTime = 0, - leading = false, - maxing = false, - trailing = true; - - if (typeof func != 'function') { - throw new TypeError(FUNC_ERROR_TEXT); - } - wait = toNumber(wait) || 0; - if (isObject(options)) { - leading = !!options.leading; - maxing = 'maxWait' in options; - maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait; - trailing = 'trailing' in options ? !!options.trailing : trailing; - } - - function invokeFunc(time) { - var args = lastArgs, - thisArg = lastThis; - - lastArgs = lastThis = undefined; - lastInvokeTime = time; - result = func.apply(thisArg, args); - return result; - } - - function leadingEdge(time) { - // Reset any `maxWait` timer. - lastInvokeTime = time; - // Start the timer for the trailing edge. - timerId = setTimeout(timerExpired, wait); - // Invoke the leading edge. - return leading ? invokeFunc(time) : result; - } - - function remainingWait(time) { - var timeSinceLastCall = time - lastCallTime, - timeSinceLastInvoke = time - lastInvokeTime, - timeWaiting = wait - timeSinceLastCall; - - return maxing - ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke) - : timeWaiting; - } - - function shouldInvoke(time) { - var timeSinceLastCall = time - lastCallTime, - timeSinceLastInvoke = time - lastInvokeTime; - - // Either this is the first call, activity has stopped and we're at the - // trailing edge, the system time has gone backwards and we're treating - // it as the trailing edge, or we've hit the `maxWait` limit. - return (lastCallTime === undefined || (timeSinceLastCall >= wait) || - (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait)); - } - - function timerExpired() { - var time = now(); - if (shouldInvoke(time)) { - return trailingEdge(time); - } - // Restart the timer. - timerId = setTimeout(timerExpired, remainingWait(time)); - } - - function trailingEdge(time) { - timerId = undefined; - - // Only invoke if we have `lastArgs` which means `func` has been - // debounced at least once. - if (trailing && lastArgs) { - return invokeFunc(time); - } - lastArgs = lastThis = undefined; - return result; - } - - function cancel() { - if (timerId !== undefined) { - clearTimeout(timerId); - } - lastInvokeTime = 0; - lastArgs = lastCallTime = lastThis = timerId = undefined; - } - - function flush() { - return timerId === undefined ? result : trailingEdge(now()); - } - - function debounced() { - var time = now(), - isInvoking = shouldInvoke(time); - - lastArgs = arguments; - lastThis = this; - lastCallTime = time; - - if (isInvoking) { - if (timerId === undefined) { - return leadingEdge(lastCallTime); - } - if (maxing) { - // Handle invocations in a tight loop. - timerId = setTimeout(timerExpired, wait); - return invokeFunc(lastCallTime); - } - } - if (timerId === undefined) { - timerId = setTimeout(timerExpired, wait); - } - return result; - } - debounced.cancel = cancel; - debounced.flush = flush; - return debounced; -} - -module.exports = debounce; - - -/***/ }), -/* 22 */ -/***/ (function(module, exports, __webpack_require__) { - -var freeGlobal = __webpack_require__(62); - -/** Detect free variable `self`. */ -var freeSelf = typeof self == 'object' && self && self.Object === Object && self; - -/** Used as a reference to the global object. */ -var root = freeGlobal || freeSelf || Function('return this')(); - -module.exports = root; - - -/***/ }), -/* 23 */ -/***/ (function(module, exports, __webpack_require__) { - -var root = __webpack_require__(22); - -/** Built-in value references. */ -var Symbol = root.Symbol; - -module.exports = Symbol; - - -/***/ }), -/* 24 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _get = function get(object, property, receiver) { if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { return get(parent, property, receiver); } } else if ("value" in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } }; - -var _core = __webpack_require__(0); - -var _default = __webpack_require__(15); - -var _default2 = _interopRequireDefault(_default); - -var _snap = __webpack_require__(70); - -var _snap2 = _interopRequireDefault(_snap); - -var _constants = __webpack_require__(2); - -var _debounce = __webpack_require__(21); - -var _debounce2 = _interopRequireDefault(_debounce); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var ContinuousViewManager = function (_DefaultViewManager) { - _inherits(ContinuousViewManager, _DefaultViewManager); - - function ContinuousViewManager(options) { - _classCallCheck(this, ContinuousViewManager); - - var _this = _possibleConstructorReturn(this, (ContinuousViewManager.__proto__ || Object.getPrototypeOf(ContinuousViewManager)).call(this, options)); - - _this.name = "continuous"; - - _this.settings = (0, _core.extend)(_this.settings || {}, { - infinite: true, - overflow: undefined, - axis: undefined, - flow: "scrolled", - offset: 500, - offsetDelta: 250, - width: undefined, - height: undefined, - snap: false, - afterScrolledTimeout: 10 - }); - - (0, _core.extend)(_this.settings, options.settings || {}); - - // Gap can be 0, but defaults doesn't handle that - if (options.settings.gap != "undefined" && options.settings.gap === 0) { - _this.settings.gap = options.settings.gap; - } - - _this.viewSettings = { - ignoreClass: _this.settings.ignoreClass, - axis: _this.settings.axis, - flow: _this.settings.flow, - layout: _this.layout, - width: 0, - height: 0, - forceEvenPages: false - }; - - _this.scrollTop = 0; - _this.scrollLeft = 0; - return _this; - } - - _createClass(ContinuousViewManager, [{ - key: "display", - value: function display(section, target) { - return _default2.default.prototype.display.call(this, section, target).then(function () { - return this.fill(); - }.bind(this)); - } - }, { - key: "fill", - value: function fill(_full) { - var _this2 = this; - - var full = _full || new _core.defer(); - - this.q.enqueue(function () { - return _this2.check(); - }).then(function (result) { - if (result) { - _this2.fill(full); - } else { - full.resolve(); - } - }); - - return full.promise; - } - }, { - key: "moveTo", - value: function moveTo(offset) { - // var bounds = this.stage.bounds(); - // var dist = Math.floor(offset.top / bounds.height) * bounds.height; - var distX = 0, - distY = 0; - - var offsetX = 0, - offsetY = 0; - - if (!this.isPaginated) { - distY = offset.top; - offsetY = offset.top + this.settings.offsetDelta; - } else { - distX = Math.floor(offset.left / this.layout.delta) * this.layout.delta; - offsetX = distX + this.settings.offsetDelta; - } - - if (distX > 0 || distY > 0) { - this.scrollBy(distX, distY, true); - } - } - }, { - key: "afterResized", - value: function afterResized(view) { - this.emit(_constants.EVENTS.MANAGERS.RESIZE, view.section); - } - - // Remove Previous Listeners if present - - }, { - key: "removeShownListeners", - value: function removeShownListeners(view) { - - // view.off("shown", this.afterDisplayed); - // view.off("shown", this.afterDisplayedAbove); - view.onDisplayed = function () {}; - } - }, { - key: "add", - value: function add(section) { - var _this3 = this; - - var view = this.createView(section); - - this.views.append(view); - - view.on(_constants.EVENTS.VIEWS.RESIZED, function (bounds) { - view.expanded = true; - }); - - view.on(_constants.EVENTS.VIEWS.AXIS, function (axis) { - _this3.updateAxis(axis); - }); - - // view.on(EVENTS.VIEWS.SHOWN, this.afterDisplayed.bind(this)); - view.onDisplayed = this.afterDisplayed.bind(this); - view.onResize = this.afterResized.bind(this); - - return view.display(this.request); - } - }, { - key: "append", - value: function append(section) { - var _this4 = this; - - var view = this.createView(section); - - view.on(_constants.EVENTS.VIEWS.RESIZED, function (bounds) { - view.expanded = true; - }); - - view.on(_constants.EVENTS.VIEWS.AXIS, function (axis) { - _this4.updateAxis(axis); - }); - - this.views.append(view); - - view.onDisplayed = this.afterDisplayed.bind(this); - - return view; - } - }, { - key: "prepend", - value: function prepend(section) { - var _this5 = this; - - var view = this.createView(section); - - view.on(_constants.EVENTS.VIEWS.RESIZED, function (bounds) { - _this5.counter(bounds); - view.expanded = true; - }); - - view.on(_constants.EVENTS.VIEWS.AXIS, function (axis) { - _this5.updateAxis(axis); - }); - - this.views.prepend(view); - - view.onDisplayed = this.afterDisplayed.bind(this); - - return view; - } - }, { - key: "counter", - value: function counter(bounds) { - if (this.settings.axis === "vertical") { - this.scrollBy(0, bounds.heightDelta, true); - } else { - this.scrollBy(bounds.widthDelta, 0, true); - } - } - }, { - key: "update", - value: function update(_offset) { - var container = this.bounds(); - var views = this.views.all(); - var viewsLength = views.length; - var visible = []; - var offset = typeof _offset != "undefined" ? _offset : this.settings.offset || 0; - var isVisible; - var view; - - var updating = new _core.defer(); - var promises = []; - for (var i = 0; i < viewsLength; i++) { - view = views[i]; - - isVisible = this.isVisible(view, offset, offset, container); - - if (isVisible === true) { - // console.log("visible " + view.index); - - if (!view.displayed) { - var displayed = view.display(this.request).then(function (view) { - view.show(); - }, function (err) { - view.hide(); - }); - promises.push(displayed); - } else { - view.show(); - } - visible.push(view); - } else { - this.q.enqueue(view.destroy.bind(view)); - // console.log("hidden " + view.index); - - clearTimeout(this.trimTimeout); - this.trimTimeout = setTimeout(function () { - this.q.enqueue(this.trim.bind(this)); - }.bind(this), 250); - } - } - - if (promises.length) { - return Promise.all(promises).catch(function (err) { - updating.reject(err); - }); - } else { - updating.resolve(); - return updating.promise; - } - } - }, { - key: "check", - value: function check(_offsetLeft, _offsetTop) { - var _this6 = this; - - var checking = new _core.defer(); - var newViews = []; - - var horizontal = this.settings.axis === "horizontal"; - var delta = this.settings.offset || 0; - - if (_offsetLeft && horizontal) { - delta = _offsetLeft; - } - - if (_offsetTop && !horizontal) { - delta = _offsetTop; - } - - var bounds = this._bounds; // bounds saved this until resize - - var rtl = this.settings.direction === "rtl"; - var dir = horizontal && rtl ? -1 : 1; //RTL reverses scrollTop - - var offset = horizontal ? this.scrollLeft : this.scrollTop * dir; - var visibleLength = horizontal ? Math.floor(bounds.width) : bounds.height; - var contentLength = horizontal ? this.container.scrollWidth : this.container.scrollHeight; - - var prepend = function prepend() { - var first = _this6.views.first(); - var prev = first && first.section.prev(); - - if (prev) { - newViews.push(_this6.prepend(prev)); - } - }; - - var append = function append() { - var last = _this6.views.last(); - var next = last && last.section.next(); - - if (next) { - newViews.push(_this6.append(next)); - } - }; - - if (offset + visibleLength + delta >= contentLength) { - if (horizontal && rtl) { - prepend(); - } else { - append(); - } - } - - if (offset - delta < 0) { - if (horizontal && rtl) { - append(); - } else { - prepend(); - } - } - - var promises = newViews.map(function (view) { - return view.displayed; - }); - - if (newViews.length) { - return Promise.all(promises).then(function () { - if (_this6.layout.name === "pre-paginated" && _this6.layout.props.spread) { - return _this6.check(); - } - }).then(function () { - // Check to see if anything new is on screen after rendering - return _this6.update(delta); - }, function (err) { - return err; - }); - } else { - this.q.enqueue(function () { - this.update(); - }.bind(this)); - checking.resolve(false); - return checking.promise; - } - } - }, { - key: "trim", - value: function trim() { - var task = new _core.defer(); - var displayed = this.views.displayed(); - var first = displayed[0]; - var last = displayed[displayed.length - 1]; - var firstIndex = this.views.indexOf(first); - var lastIndex = this.views.indexOf(last); - var above = this.views.slice(0, firstIndex); - var below = this.views.slice(lastIndex + 1); - - // Erase all but last above - for (var i = 0; i < above.length - 1; i++) { - this.erase(above[i], above); - } - - // Erase all except first below - for (var j = 1; j < below.length; j++) { - this.erase(below[j]); - } - - task.resolve(); - return task.promise; - } - }, { - key: "erase", - value: function erase(view, above) { - //Trim - - var prevTop; - var prevLeft; - - if (!this.settings.fullsize) { - prevTop = this.container.scrollTop; - prevLeft = this.container.scrollLeft; - } else { - prevTop = window.scrollY; - prevLeft = window.scrollX; - } - - var bounds = view.bounds(); - - this.views.remove(view); - - if (above) { - if (this.settings.axis === "vertical") { - this.scrollTo(0, prevTop - bounds.height, true); - } else { - this.scrollTo(prevLeft - Math.floor(bounds.width), 0, true); - } - } - } - }, { - key: "addEventListeners", - value: function addEventListeners(stage) { - - window.addEventListener("unload", function (e) { - this.ignore = true; - // this.scrollTo(0,0); - this.destroy(); - }.bind(this)); - - this.addScrollListeners(); - - if (this.isPaginated && this.settings.snap) { - this.snapper = new _snap2.default(this, this.settings.snap && _typeof(this.settings.snap) === "object" && this.settings.snap); - } - } - }, { - key: "addScrollListeners", - value: function addScrollListeners() { - var scroller; - - this.tick = _core.requestAnimationFrame; - - if (!this.settings.fullsize) { - this.prevScrollTop = this.container.scrollTop; - this.prevScrollLeft = this.container.scrollLeft; - } else { - this.prevScrollTop = window.scrollY; - this.prevScrollLeft = window.scrollX; - } - - this.scrollDeltaVert = 0; - this.scrollDeltaHorz = 0; - - if (!this.settings.fullsize) { - scroller = this.container; - this.scrollTop = this.container.scrollTop; - this.scrollLeft = this.container.scrollLeft; - } else { - scroller = window; - this.scrollTop = window.scrollY; - this.scrollLeft = window.scrollX; - } - - this._onScroll = this.onScroll.bind(this); - scroller.addEventListener("scroll", this._onScroll); - this._scrolled = (0, _debounce2.default)(this.scrolled.bind(this), 30); - // this.tick.call(window, this.onScroll.bind(this)); - - this.didScroll = false; - } - }, { - key: "removeEventListeners", - value: function removeEventListeners() { - var scroller; - - if (!this.settings.fullsize) { - scroller = this.container; - } else { - scroller = window; - } - - scroller.removeEventListener("scroll", this._onScroll); - this._onScroll = undefined; - } - }, { - key: "onScroll", - value: function onScroll() { - var scrollTop = void 0; - var scrollLeft = void 0; - var dir = this.settings.direction === "rtl" ? -1 : 1; - - if (!this.settings.fullsize) { - scrollTop = this.container.scrollTop; - scrollLeft = this.container.scrollLeft; - } else { - scrollTop = window.scrollY * dir; - scrollLeft = window.scrollX * dir; - } - - this.scrollTop = scrollTop; - this.scrollLeft = scrollLeft; - - if (!this.ignore) { - - this._scrolled(); - } else { - this.ignore = false; - } - - this.scrollDeltaVert += Math.abs(scrollTop - this.prevScrollTop); - this.scrollDeltaHorz += Math.abs(scrollLeft - this.prevScrollLeft); - - this.prevScrollTop = scrollTop; - this.prevScrollLeft = scrollLeft; - - clearTimeout(this.scrollTimeout); - this.scrollTimeout = setTimeout(function () { - this.scrollDeltaVert = 0; - this.scrollDeltaHorz = 0; - }.bind(this), 150); - - clearTimeout(this.afterScrolled); - - this.didScroll = false; - } - }, { - key: "scrolled", - value: function scrolled() { - - this.q.enqueue(function () { - this.check(); - }.bind(this)); - - this.emit(_constants.EVENTS.MANAGERS.SCROLL, { - top: this.scrollTop, - left: this.scrollLeft - }); - - clearTimeout(this.afterScrolled); - this.afterScrolled = setTimeout(function () { - - // Don't report scroll if we are about the snap - if (this.snapper && this.snapper.supportsTouch && this.snapper.needsSnap()) { - return; - } - - this.emit(_constants.EVENTS.MANAGERS.SCROLLED, { - top: this.scrollTop, - left: this.scrollLeft - }); - }.bind(this), this.settings.afterScrolledTimeout); - } - }, { - key: "next", - value: function next() { - - var dir = this.settings.direction; - var delta = this.layout.props.name === "pre-paginated" && this.layout.props.spread ? this.layout.props.delta * 2 : this.layout.props.delta; - - if (!this.views.length) return; - - if (this.isPaginated && this.settings.axis === "horizontal") { - - this.scrollBy(delta, 0, true); - } else { - - this.scrollBy(0, this.layout.height, true); - } - - this.q.enqueue(function () { - this.check(); - }.bind(this)); - } - }, { - key: "prev", - value: function prev() { - - var dir = this.settings.direction; - var delta = this.layout.props.name === "pre-paginated" && this.layout.props.spread ? this.layout.props.delta * 2 : this.layout.props.delta; - - if (!this.views.length) return; - - if (this.isPaginated && this.settings.axis === "horizontal") { - - this.scrollBy(-delta, 0, true); - } else { - - this.scrollBy(0, -this.layout.height, true); - } - - this.q.enqueue(function () { - this.check(); - }.bind(this)); - } - - // updateAxis(axis, forceUpdate){ - // - // super.updateAxis(axis, forceUpdate); - // - // if (axis === "vertical") { - // this.settings.infinite = true; - // } else { - // this.settings.infinite = false; - // } - // } - - }, { - key: "updateFlow", - value: function updateFlow(flow) { - if (this.rendered && this.snapper) { - this.snapper.destroy(); - this.snapper = undefined; - } - - _get(ContinuousViewManager.prototype.__proto__ || Object.getPrototypeOf(ContinuousViewManager.prototype), "updateFlow", this).call(this, flow, "scroll"); - - if (this.rendered && this.isPaginated && this.settings.snap) { - this.snapper = new _snap2.default(this, this.settings.snap && _typeof(this.settings.snap) === "object" && this.settings.snap); - } - } - }, { - key: "destroy", - value: function destroy() { - _get(ContinuousViewManager.prototype.__proto__ || Object.getPrototypeOf(ContinuousViewManager.prototype), "destroy", this).call(this); - - if (this.snapper) { - this.snapper.destroy(); - } - } - }]); - - return ContinuousViewManager; -}(_default2.default); - -exports.default = ContinuousViewManager; -module.exports = exports["default"]; - -/***/ }), -/* 25 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(global) { - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _book = __webpack_require__(26); - -var _book2 = _interopRequireDefault(_book); - -var _rendition = __webpack_require__(18); - -var _rendition2 = _interopRequireDefault(_rendition); - -var _epubcfi = __webpack_require__(1); - -var _epubcfi2 = _interopRequireDefault(_epubcfi); - -var _contents = __webpack_require__(14); - -var _contents2 = _interopRequireDefault(_contents); - -var _core = __webpack_require__(0); - -var utils = _interopRequireWildcard(_core); - -var _constants = __webpack_require__(2); - -var _urlPolyfill = __webpack_require__(76); - -var URLpolyfill = _interopRequireWildcard(_urlPolyfill); - -var _iframe = __webpack_require__(20); - -var _iframe2 = _interopRequireDefault(_iframe); - -var _default = __webpack_require__(15); - -var _default2 = _interopRequireDefault(_default); - -var _continuous = __webpack_require__(24); - -var _continuous2 = _interopRequireDefault(_continuous); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -/** - * Creates a new Book - * @param {string|ArrayBuffer} url URL, Path or ArrayBuffer - * @param {object} options to pass to the book - * @returns {Book} a new Book object - * @example ePub("/path/to/book.epub", {}) - */ -function ePub(url, options) { - return new _book2.default(url, options); -} - -ePub.VERSION = _constants.EPUBJS_VERSION; - -if (typeof global !== "undefined") { - global.EPUBJS_VERSION = _constants.EPUBJS_VERSION; -} - -ePub.Book = _book2.default; -ePub.Rendition = _rendition2.default; -ePub.Contents = _contents2.default; -ePub.CFI = _epubcfi2.default; -ePub.utils = utils; - -exports.default = ePub; -module.exports = exports["default"]; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5))) - -/***/ }), -/* 26 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _eventEmitter = __webpack_require__(3); - -var _eventEmitter2 = _interopRequireDefault(_eventEmitter); - -var _core = __webpack_require__(0); - -var _url = __webpack_require__(6); - -var _url2 = _interopRequireDefault(_url); - -var _path = __webpack_require__(4); - -var _path2 = _interopRequireDefault(_path); - -var _spine = __webpack_require__(43); - -var _spine2 = _interopRequireDefault(_spine); - -var _locations = __webpack_require__(47); - -var _locations2 = _interopRequireDefault(_locations); - -var _container = __webpack_require__(48); - -var _container2 = _interopRequireDefault(_container); - -var _packaging = __webpack_require__(49); - -var _packaging2 = _interopRequireDefault(_packaging); - -var _navigation = __webpack_require__(50); - -var _navigation2 = _interopRequireDefault(_navigation); - -var _resources = __webpack_require__(51); - -var _resources2 = _interopRequireDefault(_resources); - -var _pagelist = __webpack_require__(52); - -var _pagelist2 = _interopRequireDefault(_pagelist); - -var _rendition = __webpack_require__(18); - -var _rendition2 = _interopRequireDefault(_rendition); - -var _archive = __webpack_require__(71); - -var _archive2 = _interopRequireDefault(_archive); - -var _request2 = __webpack_require__(9); - -var _request3 = _interopRequireDefault(_request2); - -var _epubcfi = __webpack_require__(1); - -var _epubcfi2 = _interopRequireDefault(_epubcfi); - -var _store = __webpack_require__(73); - -var _store2 = _interopRequireDefault(_store); - -var _displayoptions = __webpack_require__(75); - -var _displayoptions2 = _interopRequireDefault(_displayoptions); - -var _constants = __webpack_require__(2); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -var CONTAINER_PATH = "META-INF/container.xml"; -var IBOOKS_DISPLAY_OPTIONS_PATH = "META-INF/com.apple.ibooks.display-options.xml"; - -var INPUT_TYPE = { - BINARY: "binary", - BASE64: "base64", - EPUB: "epub", - OPF: "opf", - MANIFEST: "json", - DIRECTORY: "directory" -}; - -/** - * An Epub representation with methods for the loading, parsing and manipulation - * of its contents. - * @class - * @param {string} [url] - * @param {object} [options] - * @param {method} [options.requestMethod] a request function to use instead of the default - * @param {boolean} [options.requestCredentials=undefined] send the xhr request withCredentials - * @param {object} [options.requestHeaders=undefined] send the xhr request headers - * @param {string} [options.encoding=binary] optional to pass 'binary' or base64' for archived Epubs - * @param {string} [options.replacements=none] use base64, blobUrl, or none for replacing assets in archived Epubs - * @param {method} [options.canonical] optional function to determine canonical urls for a path - * @param {string} [options.openAs] optional string to determine the input type - * @param {string} [options.store=false] cache the contents in local storage, value should be the name of the reader - * @returns {Book} - * @example new Book("/path/to/book.epub", {}) - * @example new Book({ replacements: "blobUrl" }) - */ - -var Book = function () { - function Book(url, options) { - var _this = this; - - _classCallCheck(this, Book); - - // Allow passing just options to the Book - if (typeof options === "undefined" && typeof url !== "string" && url instanceof Blob === false) { - options = url; - url = undefined; - } - - this.settings = (0, _core.extend)(this.settings || {}, { - requestMethod: undefined, - requestCredentials: undefined, - requestHeaders: undefined, - encoding: undefined, - replacements: undefined, - canonical: undefined, - openAs: undefined, - store: undefined - }); - - (0, _core.extend)(this.settings, options); - - // Promises - this.opening = new _core.defer(); - /** - * @member {promise} opened returns after the book is loaded - * @memberof Book - */ - this.opened = this.opening.promise; - this.isOpen = false; - - this.loading = { - manifest: new _core.defer(), - spine: new _core.defer(), - metadata: new _core.defer(), - cover: new _core.defer(), - navigation: new _core.defer(), - pageList: new _core.defer(), - resources: new _core.defer(), - displayOptions: new _core.defer() - }; - - this.loaded = { - manifest: this.loading.manifest.promise, - spine: this.loading.spine.promise, - metadata: this.loading.metadata.promise, - cover: this.loading.cover.promise, - navigation: this.loading.navigation.promise, - pageList: this.loading.pageList.promise, - resources: this.loading.resources.promise, - displayOptions: this.loading.displayOptions.promise - }; - - /** - * @member {promise} ready returns after the book is loaded and parsed - * @memberof Book - * @private - */ - this.ready = Promise.all([this.loaded.manifest, this.loaded.spine, this.loaded.metadata, this.loaded.cover, this.loaded.navigation, this.loaded.resources, this.loaded.displayOptions]); - - // Queue for methods used before opening - this.isRendered = false; - // this._q = queue(this); - - /** - * @member {method} request - * @memberof Book - * @private - */ - this.request = this.settings.requestMethod || _request3.default; - - /** - * @member {Spine} spine - * @memberof Book - */ - this.spine = new _spine2.default(); - - /** - * @member {Locations} locations - * @memberof Book - */ - this.locations = new _locations2.default(this.spine, this.load.bind(this)); - - /** - * @member {Navigation} navigation - * @memberof Book - */ - this.navigation = undefined; - - /** - * @member {PageList} pagelist - * @memberof Book - */ - this.pageList = undefined; - - /** - * @member {Url} url - * @memberof Book - * @private - */ - this.url = undefined; - - /** - * @member {Path} path - * @memberof Book - * @private - */ - this.path = undefined; - - /** - * @member {boolean} archived - * @memberof Book - * @private - */ - this.archived = false; - - /** - * @member {Archive} archive - * @memberof Book - * @private - */ - this.archive = undefined; - - /** - * @member {Store} storage - * @memberof Book - * @private - */ - this.storage = undefined; - - /** - * @member {Resources} resources - * @memberof Book - * @private - */ - this.resources = undefined; - - /** - * @member {Rendition} rendition - * @memberof Book - * @private - */ - this.rendition = undefined; - - /** - * @member {Container} container - * @memberof Book - * @private - */ - this.container = undefined; - - /** - * @member {Packaging} packaging - * @memberof Book - * @private - */ - this.packaging = undefined; - - /** - * @member {DisplayOptions} displayOptions - * @memberof DisplayOptions - * @private - */ - this.displayOptions = undefined; - - // this.toc = undefined; - if (this.settings.store) { - this.store(this.settings.store); - } - - if (url) { - this.open(url, this.settings.openAs).catch(function (error) { - var err = new Error("Cannot load book at " + url); - _this.emit(_constants.EVENTS.BOOK.OPEN_FAILED, err); - }); - } - } - - /** - * Open a epub or url - * @param {string | ArrayBuffer} input Url, Path or ArrayBuffer - * @param {string} [what="binary", "base64", "epub", "opf", "json", "directory"] force opening as a certain type - * @returns {Promise} of when the book has been loaded - * @example book.open("/path/to/book.epub") - */ - - - _createClass(Book, [{ - key: "open", - value: function open(input, what) { - var opening; - var type = what || this.determineType(input); - - if (type === INPUT_TYPE.BINARY) { - this.archived = true; - this.url = new _url2.default("/", ""); - opening = this.openEpub(input); - } else if (type === INPUT_TYPE.BASE64) { - this.archived = true; - this.url = new _url2.default("/", ""); - opening = this.openEpub(input, type); - } else if (type === INPUT_TYPE.EPUB) { - this.archived = true; - this.url = new _url2.default("/", ""); - opening = this.request(input, "binary", this.settings.requestCredentials).then(this.openEpub.bind(this)); - } else if (type == INPUT_TYPE.OPF) { - this.url = new _url2.default(input); - opening = this.openPackaging(this.url.Path.toString()); - } else if (type == INPUT_TYPE.MANIFEST) { - this.url = new _url2.default(input); - opening = this.openManifest(this.url.Path.toString()); - } else { - this.url = new _url2.default(input); - opening = this.openContainer(CONTAINER_PATH).then(this.openPackaging.bind(this)); - } - - return opening; - } - - /** - * Open an archived epub - * @private - * @param {binary} data - * @param {string} [encoding] - * @return {Promise} - */ - - }, { - key: "openEpub", - value: function openEpub(data, encoding) { - var _this2 = this; - - return this.unarchive(data, encoding || this.settings.encoding).then(function () { - return _this2.openContainer(CONTAINER_PATH); - }).then(function (packagePath) { - return _this2.openPackaging(packagePath); - }); - } - - /** - * Open the epub container - * @private - * @param {string} url - * @return {string} packagePath - */ - - }, { - key: "openContainer", - value: function openContainer(url) { - var _this3 = this; - - return this.load(url).then(function (xml) { - _this3.container = new _container2.default(xml); - return _this3.resolve(_this3.container.packagePath); - }); - } - - /** - * Open the Open Packaging Format Xml - * @private - * @param {string} url - * @return {Promise} - */ - - }, { - key: "openPackaging", - value: function openPackaging(url) { - var _this4 = this; - - this.path = new _path2.default(url); - return this.load(url).then(function (xml) { - _this4.packaging = new _packaging2.default(xml); - return _this4.unpack(_this4.packaging); - }); - } - - /** - * Open the manifest JSON - * @private - * @param {string} url - * @return {Promise} - */ - - }, { - key: "openManifest", - value: function openManifest(url) { - var _this5 = this; - - this.path = new _path2.default(url); - return this.load(url).then(function (json) { - _this5.packaging = new _packaging2.default(); - _this5.packaging.load(json); - return _this5.unpack(_this5.packaging); - }); - } - - /** - * Load a resource from the Book - * @param {string} path path to the resource to load - * @return {Promise} returns a promise with the requested resource - */ - - }, { - key: "load", - value: function load(path) { - var resolved = this.resolve(path); - if (this.archived) { - return this.archive.request(resolved); - } else { - return this.request(resolved, null, this.settings.requestCredentials, this.settings.requestHeaders); - } - } - - /** - * Resolve a path to it's absolute position in the Book - * @param {string} path - * @param {boolean} [absolute] force resolving the full URL - * @return {string} the resolved path string - */ - - }, { - key: "resolve", - value: function resolve(path, absolute) { - if (!path) { - return; - } - var resolved = path; - var isAbsolute = path.indexOf("://") > -1; - - if (isAbsolute) { - return path; - } - - if (this.path) { - resolved = this.path.resolve(path); - } - - if (absolute != false && this.url) { - resolved = this.url.resolve(resolved); - } - - return resolved; - } - - /** - * Get a canonical link to a path - * @param {string} path - * @return {string} the canonical path string - */ - - }, { - key: "canonical", - value: function canonical(path) { - var url = path; - - if (!path) { - return ""; - } - - if (this.settings.canonical) { - url = this.settings.canonical(path); - } else { - url = this.resolve(path, true); - } - - return url; - } - - /** - * Determine the type of they input passed to open - * @private - * @param {string} input - * @return {string} binary | directory | epub | opf - */ - - }, { - key: "determineType", - value: function determineType(input) { - var url; - var path; - var extension; - - if (this.settings.encoding === "base64") { - return INPUT_TYPE.BASE64; - } - - if (typeof input != "string") { - return INPUT_TYPE.BINARY; - } - - url = new _url2.default(input); - path = url.path(); - extension = path.extension; - - if (!extension) { - return INPUT_TYPE.DIRECTORY; - } - - if (extension === "epub") { - return INPUT_TYPE.EPUB; - } - - if (extension === "opf") { - return INPUT_TYPE.OPF; - } - - if (extension === "json") { - return INPUT_TYPE.MANIFEST; - } - } - - /** - * unpack the contents of the Books packaging - * @private - * @param {Packaging} packaging object - */ - - }, { - key: "unpack", - value: function unpack(packaging) { - var _this6 = this; - - this.package = packaging; //TODO: deprecated this - - if (this.packaging.metadata.layout === "") { - // rendition:layout not set - check display options if book is pre-paginated - this.load(this.url.resolve(IBOOKS_DISPLAY_OPTIONS_PATH)).then(function (xml) { - _this6.displayOptions = new _displayoptions2.default(xml); - _this6.loading.displayOptions.resolve(_this6.displayOptions); - }).catch(function (err) { - _this6.displayOptions = new _displayoptions2.default(); - _this6.loading.displayOptions.resolve(_this6.displayOptions); - }); - } else { - this.displayOptions = new _displayoptions2.default(); - this.loading.displayOptions.resolve(this.displayOptions); - } - - this.spine.unpack(this.packaging, this.resolve.bind(this), this.canonical.bind(this)); - - this.resources = new _resources2.default(this.packaging.manifest, { - archive: this.archive, - resolver: this.resolve.bind(this), - request: this.request.bind(this), - replacements: this.settings.replacements || (this.archived ? "blobUrl" : "base64") - }); - - this.loadNavigation(this.packaging).then(function () { - // this.toc = this.navigation.toc; - _this6.loading.navigation.resolve(_this6.navigation); - }); - - if (this.packaging.coverPath) { - this.cover = this.resolve(this.packaging.coverPath); - } - // Resolve promises - this.loading.manifest.resolve(this.packaging.manifest); - this.loading.metadata.resolve(this.packaging.metadata); - this.loading.spine.resolve(this.spine); - this.loading.cover.resolve(this.cover); - this.loading.resources.resolve(this.resources); - this.loading.pageList.resolve(this.pageList); - - this.isOpen = true; - - if (this.archived || this.settings.replacements && this.settings.replacements != "none") { - this.replacements().then(function () { - _this6.loaded.displayOptions.then(function () { - _this6.opening.resolve(_this6); - }); - }).catch(function (err) { - console.error(err); - }); - } else { - // Resolve book opened promise - this.loaded.displayOptions.then(function () { - _this6.opening.resolve(_this6); - }); - } - } - - /** - * Load Navigation and PageList from package - * @private - * @param {Packaging} packaging - */ - - }, { - key: "loadNavigation", - value: function loadNavigation(packaging) { - var _this7 = this; - - var navPath = packaging.navPath || packaging.ncxPath; - var toc = packaging.toc; - - // From json manifest - if (toc) { - return new Promise(function (resolve, reject) { - _this7.navigation = new _navigation2.default(toc); - - if (packaging.pageList) { - _this7.pageList = new _pagelist2.default(packaging.pageList); // TODO: handle page lists from Manifest - } - - resolve(_this7.navigation); - }); - } - - if (!navPath) { - return new Promise(function (resolve, reject) { - _this7.navigation = new _navigation2.default(); - _this7.pageList = new _pagelist2.default(); - - resolve(_this7.navigation); - }); - } - - return this.load(navPath, "xml").then(function (xml) { - _this7.navigation = new _navigation2.default(xml); - _this7.pageList = new _pagelist2.default(xml); - return _this7.navigation; - }); - } - - /** - * Gets a Section of the Book from the Spine - * Alias for `book.spine.get` - * @param {string} target - * @return {Section} - */ - - }, { - key: "section", - value: function section(target) { - return this.spine.get(target); - } - - /** - * Sugar to render a book to an element - * @param {element | string} element element or string to add a rendition to - * @param {object} [options] - * @return {Rendition} - */ - - }, { - key: "renderTo", - value: function renderTo(element, options) { - this.rendition = new _rendition2.default(this, options); - this.rendition.attachTo(element); - - return this.rendition; - } - - /** - * Set if request should use withCredentials - * @param {boolean} credentials - */ - - }, { - key: "setRequestCredentials", - value: function setRequestCredentials(credentials) { - this.settings.requestCredentials = credentials; - } - - /** - * Set headers request should use - * @param {object} headers - */ - - }, { - key: "setRequestHeaders", - value: function setRequestHeaders(headers) { - this.settings.requestHeaders = headers; - } - - /** - * Unarchive a zipped epub - * @private - * @param {binary} input epub data - * @param {string} [encoding] - * @return {Archive} - */ - - }, { - key: "unarchive", - value: function unarchive(input, encoding) { - this.archive = new _archive2.default(); - return this.archive.open(input, encoding); - } - - /** - * Store the epubs contents - * @private - * @param {binary} input epub data - * @param {string} [encoding] - * @return {Store} - */ - - }, { - key: "store", - value: function store(name) { - var _this8 = this; - - // Use "blobUrl" or "base64" for replacements - var replacementsSetting = this.settings.replacements && this.settings.replacements !== "none"; - // Save original url - var originalUrl = this.url; - // Save original request method - var requester = this.settings.requestMethod || _request3.default.bind(this); - // Create new Store - this.storage = new _store2.default(name, requester, this.resolve.bind(this)); - // Replace request method to go through store - this.request = this.storage.request.bind(this.storage); - - this.opened.then(function () { - if (_this8.archived) { - _this8.storage.requester = _this8.archive.request.bind(_this8.archive); - } - // Substitute hook - var substituteResources = function substituteResources(output, section) { - section.output = _this8.resources.substitute(output, section.url); - }; - - // Set to use replacements - _this8.resources.settings.replacements = replacementsSetting || "blobUrl"; - // Create replacement urls - _this8.resources.replacements().then(function () { - return _this8.resources.replaceCss(); - }); - - _this8.storage.on("offline", function () { - // Remove url to use relative resolving for hrefs - _this8.url = new _url2.default("/", ""); - // Add hook to replace resources in contents - _this8.spine.hooks.serialize.register(substituteResources); - }); - - _this8.storage.on("online", function () { - // Restore original url - _this8.url = originalUrl; - // Remove hook - _this8.spine.hooks.serialize.deregister(substituteResources); - }); - }); - - return this.storage; - } - - /** - * Get the cover url - * @return {string} coverUrl - */ - - }, { - key: "coverUrl", - value: function coverUrl() { - var _this9 = this; - - var retrieved = this.loaded.cover.then(function (url) { - if (_this9.archived) { - // return this.archive.createUrl(this.cover); - return _this9.resources.get(_this9.cover); - } else { - return _this9.cover; - } - }); - - return retrieved; - } - - /** - * Load replacement urls - * @private - * @return {Promise} completed loading urls - */ - - }, { - key: "replacements", - value: function replacements() { - var _this10 = this; - - this.spine.hooks.serialize.register(function (output, section) { - section.output = _this10.resources.substitute(output, section.url); - }); - - return this.resources.replacements().then(function () { - return _this10.resources.replaceCss(); - }); - } - - /** - * Find a DOM Range for a given CFI Range - * @param {EpubCFI} cfiRange a epub cfi range - * @return {Range} - */ - - }, { - key: "getRange", - value: function getRange(cfiRange) { - var cfi = new _epubcfi2.default(cfiRange); - var item = this.spine.get(cfi.spinePos); - var _request = this.load.bind(this); - if (!item) { - return new Promise(function (resolve, reject) { - reject("CFI could not be found"); - }); - } - return item.load(_request).then(function (contents) { - var range = cfi.toRange(item.document); - return range; - }); - } - - /** - * Generates the Book Key using the identifer in the manifest or other string provided - * @param {string} [identifier] to use instead of metadata identifier - * @return {string} key - */ - - }, { - key: "key", - value: function key(identifier) { - var ident = identifier || this.packaging.metadata.identifier || this.url.filename; - return "epubjs:" + _constants.EPUBJS_VERSION + ":" + ident; - } - - /** - * Destroy the Book and all associated objects - */ - - }, { - key: "destroy", - value: function destroy() { - this.opened = undefined; - this.loading = undefined; - this.loaded = undefined; - this.ready = undefined; - - this.isOpen = false; - this.isRendered = false; - - this.spine && this.spine.destroy(); - this.locations && this.locations.destroy(); - this.pageList && this.pageList.destroy(); - this.archive && this.archive.destroy(); - this.resources && this.resources.destroy(); - this.container && this.container.destroy(); - this.packaging && this.packaging.destroy(); - this.rendition && this.rendition.destroy(); - this.displayOptions && this.displayOptions.destroy(); - - this.spine = undefined; - this.locations = undefined; - this.pageList = undefined; - this.archive = undefined; - this.resources = undefined; - this.container = undefined; - this.packaging = undefined; - this.rendition = undefined; - - this.navigation = undefined; - this.url = undefined; - this.path = undefined; - this.archived = false; - } - }]); - - return Book; -}(); - -//-- Enable binding events to book - - -(0, _eventEmitter2.default)(Book.prototype); - -exports.default = Book; -module.exports = exports["default"]; - -/***/ }), -/* 27 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var assign = __webpack_require__(28) - , normalizeOpts = __webpack_require__(36) - , isCallable = __webpack_require__(37) - , contains = __webpack_require__(38) - - , d; - -d = module.exports = function (dscr, value/*, options*/) { - var c, e, w, options, desc; - if ((arguments.length < 2) || (typeof dscr !== 'string')) { - options = value; - value = dscr; - dscr = null; - } else { - options = arguments[2]; - } - if (dscr == null) { - c = w = true; - e = false; - } else { - c = contains.call(dscr, 'c'); - e = contains.call(dscr, 'e'); - w = contains.call(dscr, 'w'); - } - - desc = { value: value, configurable: c, enumerable: e, writable: w }; - return !options ? desc : assign(normalizeOpts(options), desc); -}; - -d.gs = function (dscr, get, set/*, options*/) { - var c, e, options, desc; - if (typeof dscr !== 'string') { - options = set; - set = get; - get = dscr; - dscr = null; - } else { - options = arguments[3]; - } - if (get == null) { - get = undefined; - } else if (!isCallable(get)) { - options = get; - get = set = undefined; - } else if (set == null) { - set = undefined; - } else if (!isCallable(set)) { - options = set; - set = undefined; - } - if (dscr == null) { - c = true; - e = false; - } else { - c = contains.call(dscr, 'c'); - e = contains.call(dscr, 'e'); - } - - desc = { get: get, set: set, configurable: c, enumerable: e }; - return !options ? desc : assign(normalizeOpts(options), desc); -}; - - -/***/ }), -/* 28 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = __webpack_require__(29)() - ? Object.assign - : __webpack_require__(30); - - -/***/ }), -/* 29 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = function () { - var assign = Object.assign, obj; - if (typeof assign !== "function") return false; - obj = { foo: "raz" }; - assign(obj, { bar: "dwa" }, { trzy: "trzy" }); - return (obj.foo + obj.bar + obj.trzy) === "razdwatrzy"; -}; - - -/***/ }), -/* 30 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var keys = __webpack_require__(31) - , value = __webpack_require__(35) - , max = Math.max; - -module.exports = function (dest, src /*, …srcn*/) { - var error, i, length = max(arguments.length, 2), assign; - dest = Object(value(dest)); - assign = function (key) { - try { - dest[key] = src[key]; - } catch (e) { - if (!error) error = e; - } - }; - for (i = 1; i < length; ++i) { - src = arguments[i]; - keys(src).forEach(assign); - } - if (error !== undefined) throw error; - return dest; -}; - - -/***/ }), -/* 31 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = __webpack_require__(32)() ? Object.keys : __webpack_require__(33); - - -/***/ }), -/* 32 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = function () { - try { - Object.keys("primitive"); - return true; - } catch (e) { - return false; - } -}; - - -/***/ }), -/* 33 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var isValue = __webpack_require__(10); - -var keys = Object.keys; - -module.exports = function (object) { return keys(isValue(object) ? Object(object) : object); }; - - -/***/ }), -/* 34 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -// eslint-disable-next-line no-empty-function -module.exports = function () {}; - - -/***/ }), -/* 35 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var isValue = __webpack_require__(10); - -module.exports = function (value) { - if (!isValue(value)) throw new TypeError("Cannot use null or undefined"); - return value; -}; - - -/***/ }), -/* 36 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var isValue = __webpack_require__(10); - -var forEach = Array.prototype.forEach, create = Object.create; - -var process = function (src, obj) { - var key; - for (key in src) obj[key] = src[key]; -}; - -// eslint-disable-next-line no-unused-vars -module.exports = function (opts1 /*, …options*/) { - var result = create(null); - forEach.call(arguments, function (options) { - if (!isValue(options)) return; - process(Object(options), result); - }); - return result; -}; - - -/***/ }), -/* 37 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -// Deprecated - - - -module.exports = function (obj) { - return typeof obj === "function"; -}; - - -/***/ }), -/* 38 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = __webpack_require__(39)() - ? String.prototype.contains - : __webpack_require__(40); - - -/***/ }), -/* 39 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var str = "razdwatrzy"; - -module.exports = function () { - if (typeof str.contains !== "function") return false; - return (str.contains("dwa") === true) && (str.contains("foo") === false); -}; - - -/***/ }), -/* 40 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var indexOf = String.prototype.indexOf; - -module.exports = function (searchString/*, position*/) { - return indexOf.call(this, searchString, arguments[1]) > -1; -}; - - -/***/ }), -/* 41 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = function (fn) { - if (typeof fn !== "function") throw new TypeError(fn + " is not a function"); - return fn; -}; - - -/***/ }), -/* 42 */ -/***/ (function(module, exports) { - -module.exports = __WEBPACK_EXTERNAL_MODULE_42__; - -/***/ }), -/* 43 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _epubcfi = __webpack_require__(1); - -var _epubcfi2 = _interopRequireDefault(_epubcfi); - -var _hook = __webpack_require__(11); - -var _hook2 = _interopRequireDefault(_hook); - -var _section = __webpack_require__(44); - -var _section2 = _interopRequireDefault(_section); - -var _replacements = __webpack_require__(8); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * A collection of Spine Items - */ -var Spine = function () { - function Spine() { - _classCallCheck(this, Spine); - - this.spineItems = []; - this.spineByHref = {}; - this.spineById = {}; - - this.hooks = {}; - this.hooks.serialize = new _hook2.default(); - this.hooks.content = new _hook2.default(); - - // Register replacements - this.hooks.content.register(_replacements.replaceBase); - this.hooks.content.register(_replacements.replaceCanonical); - this.hooks.content.register(_replacements.replaceMeta); - - this.epubcfi = new _epubcfi2.default(); - - this.loaded = false; - - this.items = undefined; - this.manifest = undefined; - this.spineNodeIndex = undefined; - this.baseUrl = undefined; - this.length = undefined; - } - - /** - * Unpack items from a opf into spine items - * @param {Packaging} _package - * @param {method} resolver URL resolver - * @param {method} canonical Resolve canonical url - */ - - - _createClass(Spine, [{ - key: "unpack", - value: function unpack(_package, resolver, canonical) { - var _this = this; - - this.items = _package.spine; - this.manifest = _package.manifest; - this.spineNodeIndex = _package.spineNodeIndex; - this.baseUrl = _package.baseUrl || _package.basePath || ""; - this.length = this.items.length; - - this.items.forEach(function (item, index) { - var manifestItem = _this.manifest[item.idref]; - var spineItem; - - item.index = index; - item.cfiBase = _this.epubcfi.generateChapterComponent(_this.spineNodeIndex, item.index, item.idref); - - if (item.href) { - item.url = resolver(item.href, true); - item.canonical = canonical(item.href); - } - - if (manifestItem) { - item.href = manifestItem.href; - item.url = resolver(item.href, true); - item.canonical = canonical(item.href); - - if (manifestItem.properties.length) { - item.properties.push.apply(item.properties, manifestItem.properties); - } - } - - if (item.linear === "yes") { - item.prev = function () { - var prevIndex = item.index; - while (prevIndex > 0) { - var prev = this.get(prevIndex - 1); - if (prev && prev.linear) { - return prev; - } - prevIndex -= 1; - } - return; - }.bind(_this); - item.next = function () { - var nextIndex = item.index; - while (nextIndex < this.spineItems.length - 1) { - var next = this.get(nextIndex + 1); - if (next && next.linear) { - return next; - } - nextIndex += 1; - } - return; - }.bind(_this); - } else { - item.prev = function () { - return; - }; - item.next = function () { - return; - }; - } - - spineItem = new _section2.default(item, _this.hooks); - - _this.append(spineItem); - }); - - this.loaded = true; - } - - /** - * Get an item from the spine - * @param {string|number} [target] - * @return {Section} section - * @example spine.get(); - * @example spine.get(1); - * @example spine.get("chap1.html"); - * @example spine.get("#id1234"); - */ - - }, { - key: "get", - value: function get(target) { - var index = 0; - - if (typeof target === "undefined") { - while (index < this.spineItems.length) { - var next = this.spineItems[index]; - if (next && next.linear) { - break; - } - index += 1; - } - } else if (this.epubcfi.isCfiString(target)) { - var cfi = new _epubcfi2.default(target); - index = cfi.spinePos; - } else if (typeof target === "number" || isNaN(target) === false) { - index = target; - } else if (typeof target === "string" && target.indexOf("#") === 0) { - index = this.spineById[target.substring(1)]; - } else if (typeof target === "string") { - // Remove fragments - target = target.split("#")[0]; - index = this.spineByHref[target] || this.spineByHref[encodeURI(target)]; - } - - return this.spineItems[index] || null; - } - - /** - * Append a Section to the Spine - * @private - * @param {Section} section - */ - - }, { - key: "append", - value: function append(section) { - var index = this.spineItems.length; - section.index = index; - - this.spineItems.push(section); - - // Encode and Decode href lookups - // see pr for details: https://github.com/futurepress/epub.js/pull/358 - this.spineByHref[decodeURI(section.href)] = index; - this.spineByHref[encodeURI(section.href)] = index; - this.spineByHref[section.href] = index; - - this.spineById[section.idref] = index; - - return index; - } - - /** - * Prepend a Section to the Spine - * @private - * @param {Section} section - */ - - }, { - key: "prepend", - value: function prepend(section) { - // var index = this.spineItems.unshift(section); - this.spineByHref[section.href] = 0; - this.spineById[section.idref] = 0; - - // Re-index - this.spineItems.forEach(function (item, index) { - item.index = index; - }); - - return 0; - } - - // insert(section, index) { - // - // }; - - /** - * Remove a Section from the Spine - * @private - * @param {Section} section - */ - - }, { - key: "remove", - value: function remove(section) { - var index = this.spineItems.indexOf(section); - - if (index > -1) { - delete this.spineByHref[section.href]; - delete this.spineById[section.idref]; - - return this.spineItems.splice(index, 1); - } - } - - /** - * Loop over the Sections in the Spine - * @return {method} forEach - */ - - }, { - key: "each", - value: function each() { - return this.spineItems.forEach.apply(this.spineItems, arguments); - } - - /** - * Find the first Section in the Spine - * @return {Section} first section - */ - - }, { - key: "first", - value: function first() { - var index = 0; - - do { - var next = this.get(index); - - if (next && next.linear) { - return next; - } - index += 1; - } while (index < this.spineItems.length); - } - - /** - * Find the last Section in the Spine - * @return {Section} last section - */ - - }, { - key: "last", - value: function last() { - var index = this.spineItems.length - 1; - - do { - var prev = this.get(index); - if (prev && prev.linear) { - return prev; - } - index -= 1; - } while (index >= 0); - } - }, { - key: "destroy", - value: function destroy() { - this.each(function (section) { - return section.destroy(); - }); - - this.spineItems = undefined; - this.spineByHref = undefined; - this.spineById = undefined; - - this.hooks.serialize.clear(); - this.hooks.content.clear(); - this.hooks = undefined; - - this.epubcfi = undefined; - - this.loaded = false; - - this.items = undefined; - this.manifest = undefined; - this.spineNodeIndex = undefined; - this.baseUrl = undefined; - this.length = undefined; - } - }]); - - return Spine; -}(); - -exports.default = Spine; -module.exports = exports["default"]; - -/***/ }), -/* 44 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _core = __webpack_require__(0); - -var _epubcfi = __webpack_require__(1); - -var _epubcfi2 = _interopRequireDefault(_epubcfi); - -var _hook = __webpack_require__(11); - -var _hook2 = _interopRequireDefault(_hook); - -var _replacements = __webpack_require__(8); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Represents a Section of the Book - * - * In most books this is equivelent to a Chapter - * @param {object} item The spine item representing the section - * @param {object} hooks hooks for serialize and content - */ -var Section = function () { - function Section(item, hooks) { - _classCallCheck(this, Section); - - this.idref = item.idref; - this.linear = item.linear === "yes"; - this.properties = item.properties; - this.index = item.index; - this.href = item.href; - this.url = item.url; - this.canonical = item.canonical; - this.next = item.next; - this.prev = item.prev; - - this.cfiBase = item.cfiBase; - - if (hooks) { - this.hooks = hooks; - } else { - this.hooks = {}; - this.hooks.serialize = new _hook2.default(this); - this.hooks.content = new _hook2.default(this); - } - - this.document = undefined; - this.contents = undefined; - this.output = undefined; - } - - /** - * Load the section from its url - * @param {method} [_request] a request method to use for loading - * @return {document} a promise with the xml document - */ - - - _createClass(Section, [{ - key: "load", - value: function load(_request) { - var request = _request || this.request || __webpack_require__(9); - var loading = new _core.defer(); - var loaded = loading.promise; - - if (this.contents) { - loading.resolve(this.contents); - } else { - request(this.url).then(function (xml) { - // var directory = new Url(this.url).directory; - - this.document = xml; - this.contents = xml.documentElement; - - return this.hooks.content.trigger(this.document, this); - }.bind(this)).then(function () { - loading.resolve(this.contents); - }.bind(this)).catch(function (error) { - loading.reject(error); - }); - } - - return loaded; - } - - /** - * Adds a base tag for resolving urls in the section - * @private - */ - - }, { - key: "base", - value: function base() { - return (0, _replacements.replaceBase)(this.document, this); - } - - /** - * Render the contents of a section - * @param {method} [_request] a request method to use for loading - * @return {string} output a serialized XML Document - */ - - }, { - key: "render", - value: function render(_request) { - var rendering = new _core.defer(); - var rendered = rendering.promise; - this.output; // TODO: better way to return this from hooks? - - this.load(_request).then(function (contents) { - var userAgent = typeof navigator !== 'undefined' && navigator.userAgent || ''; - var isIE = userAgent.indexOf('Trident') >= 0; - var Serializer; - if (typeof XMLSerializer === "undefined" || isIE) { - Serializer = __webpack_require__(45).XMLSerializer; - } else { - Serializer = XMLSerializer; - } - var serializer = new Serializer(); - this.output = serializer.serializeToString(contents); - return this.output; - }.bind(this)).then(function () { - return this.hooks.serialize.trigger(this.output, this); - }.bind(this)).then(function () { - rendering.resolve(this.output); - }.bind(this)).catch(function (error) { - rendering.reject(error); - }); - - return rendered; - } - - /** - * Find a string in a section - * @param {string} _query The query string to find - * @return {object[]} A list of matches, with form {cfi, excerpt} - */ - - }, { - key: "find", - value: function find(_query) { - var section = this; - var matches = []; - var query = _query.toLowerCase(); - var find = function find(node) { - var text = node.textContent.toLowerCase(); - var range = section.document.createRange(); - var cfi; - var pos; - var last = -1; - var excerpt; - var limit = 150; - - while (pos != -1) { - // Search for the query - pos = text.indexOf(query, last + 1); - - if (pos != -1) { - // We found it! Generate a CFI - range = section.document.createRange(); - range.setStart(node, pos); - range.setEnd(node, pos + query.length); - - cfi = section.cfiFromRange(range); - - // Generate the excerpt - if (node.textContent.length < limit) { - excerpt = node.textContent; - } else { - excerpt = node.textContent.substring(pos - limit / 2, pos + limit / 2); - excerpt = "..." + excerpt + "..."; - } - - // Add the CFI to the matches list - matches.push({ - cfi: cfi, - excerpt: excerpt - }); - } - - last = pos; - } - }; - - (0, _core.sprint)(section.document, function (node) { - find(node); - }); - - return matches; - } - }, { - key: "reconcileLayoutSettings", - - - /** - * Reconciles the current chapters layout properies with - * the global layout properities. - * @param {object} globalLayout The global layout settings object, chapter properties string - * @return {object} layoutProperties Object with layout properties - */ - value: function reconcileLayoutSettings(globalLayout) { - //-- Get the global defaults - var settings = { - layout: globalLayout.layout, - spread: globalLayout.spread, - orientation: globalLayout.orientation - }; - - //-- Get the chapter's display type - this.properties.forEach(function (prop) { - var rendition = prop.replace("rendition:", ""); - var split = rendition.indexOf("-"); - var property, value; - - if (split != -1) { - property = rendition.slice(0, split); - value = rendition.slice(split + 1); - - settings[property] = value; - } - }); - return settings; - } - - /** - * Get a CFI from a Range in the Section - * @param {range} _range - * @return {string} cfi an EpubCFI string - */ - - }, { - key: "cfiFromRange", - value: function cfiFromRange(_range) { - return new _epubcfi2.default(_range, this.cfiBase).toString(); - } - - /** - * Get a CFI from an Element in the Section - * @param {element} el - * @return {string} cfi an EpubCFI string - */ - - }, { - key: "cfiFromElement", - value: function cfiFromElement(el) { - return new _epubcfi2.default(el, this.cfiBase).toString(); - } - - /** - * Unload the section document - */ - - }, { - key: "unload", - value: function unload() { - this.document = undefined; - this.contents = undefined; - this.output = undefined; - } - }, { - key: "destroy", - value: function destroy() { - this.unload(); - this.hooks.serialize.clear(); - this.hooks.content.clear(); - - this.hooks = undefined; - this.idref = undefined; - this.linear = undefined; - this.properties = undefined; - this.index = undefined; - this.href = undefined; - this.url = undefined; - this.next = undefined; - this.prev = undefined; - - this.cfiBase = undefined; - } - }]); - - return Section; -}(); - -exports.default = Section; -module.exports = exports["default"]; - -/***/ }), -/* 45 */ -/***/ (function(module, exports, __webpack_require__) { - -function DOMParser(options){ - this.options = options ||{locator:{}}; - -} -DOMParser.prototype.parseFromString = function(source,mimeType){ - var options = this.options; - var sax = new XMLReader(); - var domBuilder = options.domBuilder || new DOMHandler();//contentHandler and LexicalHandler - var errorHandler = options.errorHandler; - var locator = options.locator; - var defaultNSMap = options.xmlns||{}; - var entityMap = {'lt':'<','gt':'>','amp':'&','quot':'"','apos':"'"} - if(locator){ - domBuilder.setDocumentLocator(locator) - } - - sax.errorHandler = buildErrorHandler(errorHandler,domBuilder,locator); - sax.domBuilder = options.domBuilder || domBuilder; - if(/\/x?html?$/.test(mimeType)){ - entityMap.nbsp = '\xa0'; - entityMap.copy = '\xa9'; - defaultNSMap['']= 'http://www.w3.org/1999/xhtml'; - } - defaultNSMap.xml = defaultNSMap.xml || 'http://www.w3.org/XML/1998/namespace'; - if(source){ - sax.parse(source,defaultNSMap,entityMap); - }else{ - sax.errorHandler.error("invalid doc source"); - } - return domBuilder.doc; -} -function buildErrorHandler(errorImpl,domBuilder,locator){ - if(!errorImpl){ - if(domBuilder instanceof DOMHandler){ - return domBuilder; - } - errorImpl = domBuilder ; - } - var errorHandler = {} - var isCallback = errorImpl instanceof Function; - locator = locator||{} - function build(key){ - var fn = errorImpl[key]; - if(!fn && isCallback){ - fn = errorImpl.length == 2?function(msg){errorImpl(key,msg)}:errorImpl; - } - errorHandler[key] = fn && function(msg){ - fn('[xmldom '+key+']\t'+msg+_locator(locator)); - }||function(){}; - } - build('warning'); - build('error'); - build('fatalError'); - return errorHandler; -} - -//console.log('#\n\n\n\n\n\n\n####') -/** - * +ContentHandler+ErrorHandler - * +LexicalHandler+EntityResolver2 - * -DeclHandler-DTDHandler - * - * DefaultHandler:EntityResolver, DTDHandler, ContentHandler, ErrorHandler - * DefaultHandler2:DefaultHandler,LexicalHandler, DeclHandler, EntityResolver2 - * @link http://www.saxproject.org/apidoc/org/xml/sax/helpers/DefaultHandler.html - */ -function DOMHandler() { - this.cdata = false; -} -function position(locator,node){ - node.lineNumber = locator.lineNumber; - node.columnNumber = locator.columnNumber; -} -/** - * @see org.xml.sax.ContentHandler#startDocument - * @link http://www.saxproject.org/apidoc/org/xml/sax/ContentHandler.html - */ -DOMHandler.prototype = { - startDocument : function() { - this.doc = new DOMImplementation().createDocument(null, null, null); - if (this.locator) { - this.doc.documentURI = this.locator.systemId; - } - }, - startElement:function(namespaceURI, localName, qName, attrs) { - var doc = this.doc; - var el = doc.createElementNS(namespaceURI, qName||localName); - var len = attrs.length; - appendElement(this, el); - this.currentElement = el; - - this.locator && position(this.locator,el) - for (var i = 0 ; i < len; i++) { - var namespaceURI = attrs.getURI(i); - var value = attrs.getValue(i); - var qName = attrs.getQName(i); - var attr = doc.createAttributeNS(namespaceURI, qName); - this.locator &&position(attrs.getLocator(i),attr); - attr.value = attr.nodeValue = value; - el.setAttributeNode(attr) - } - }, - endElement:function(namespaceURI, localName, qName) { - var current = this.currentElement - var tagName = current.tagName; - this.currentElement = current.parentNode; - }, - startPrefixMapping:function(prefix, uri) { - }, - endPrefixMapping:function(prefix) { - }, - processingInstruction:function(target, data) { - var ins = this.doc.createProcessingInstruction(target, data); - this.locator && position(this.locator,ins) - appendElement(this, ins); - }, - ignorableWhitespace:function(ch, start, length) { - }, - characters:function(chars, start, length) { - chars = _toString.apply(this,arguments) - //console.log(chars) - if(chars){ - if (this.cdata) { - var charNode = this.doc.createCDATASection(chars); - } else { - var charNode = this.doc.createTextNode(chars); - } - if(this.currentElement){ - this.currentElement.appendChild(charNode); - }else if(/^\s*$/.test(chars)){ - this.doc.appendChild(charNode); - //process xml - } - this.locator && position(this.locator,charNode) - } - }, - skippedEntity:function(name) { - }, - endDocument:function() { - this.doc.normalize(); - }, - setDocumentLocator:function (locator) { - if(this.locator = locator){// && !('lineNumber' in locator)){ - locator.lineNumber = 0; - } - }, - //LexicalHandler - comment:function(chars, start, length) { - chars = _toString.apply(this,arguments) - var comm = this.doc.createComment(chars); - this.locator && position(this.locator,comm) - appendElement(this, comm); - }, - - startCDATA:function() { - //used in characters() methods - this.cdata = true; - }, - endCDATA:function() { - this.cdata = false; - }, - - startDTD:function(name, publicId, systemId) { - var impl = this.doc.implementation; - if (impl && impl.createDocumentType) { - var dt = impl.createDocumentType(name, publicId, systemId); - this.locator && position(this.locator,dt) - appendElement(this, dt); - } - }, - /** - * @see org.xml.sax.ErrorHandler - * @link http://www.saxproject.org/apidoc/org/xml/sax/ErrorHandler.html - */ - warning:function(error) { - console.warn('[xmldom warning]\t'+error,_locator(this.locator)); - }, - error:function(error) { - console.error('[xmldom error]\t'+error,_locator(this.locator)); - }, - fatalError:function(error) { - console.error('[xmldom fatalError]\t'+error,_locator(this.locator)); - throw error; - } -} -function _locator(l){ - if(l){ - return '\n@'+(l.systemId ||'')+'#[line:'+l.lineNumber+',col:'+l.columnNumber+']' - } -} -function _toString(chars,start,length){ - if(typeof chars == 'string'){ - return chars.substr(start,length) - }else{//java sax connect width xmldom on rhino(what about: "? && !(chars instanceof String)") - if(chars.length >= start+length || start){ - return new java.lang.String(chars,start,length)+''; - } - return chars; - } -} - -/* - * @link http://www.saxproject.org/apidoc/org/xml/sax/ext/LexicalHandler.html - * used method of org.xml.sax.ext.LexicalHandler: - * #comment(chars, start, length) - * #startCDATA() - * #endCDATA() - * #startDTD(name, publicId, systemId) - * - * - * IGNORED method of org.xml.sax.ext.LexicalHandler: - * #endDTD() - * #startEntity(name) - * #endEntity(name) - * - * - * @link http://www.saxproject.org/apidoc/org/xml/sax/ext/DeclHandler.html - * IGNORED method of org.xml.sax.ext.DeclHandler - * #attributeDecl(eName, aName, type, mode, value) - * #elementDecl(name, model) - * #externalEntityDecl(name, publicId, systemId) - * #internalEntityDecl(name, value) - * @link http://www.saxproject.org/apidoc/org/xml/sax/ext/EntityResolver2.html - * IGNORED method of org.xml.sax.EntityResolver2 - * #resolveEntity(String name,String publicId,String baseURI,String systemId) - * #resolveEntity(publicId, systemId) - * #getExternalSubset(name, baseURI) - * @link http://www.saxproject.org/apidoc/org/xml/sax/DTDHandler.html - * IGNORED method of org.xml.sax.DTDHandler - * #notationDecl(name, publicId, systemId) {}; - * #unparsedEntityDecl(name, publicId, systemId, notationName) {}; - */ -"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(key){ - DOMHandler.prototype[key] = function(){return null} -}) - -/* Private static helpers treated below as private instance methods, so don't need to add these to the public API; we might use a Relator to also get rid of non-standard public properties */ -function appendElement (hander,node) { - if (!hander.currentElement) { - hander.doc.appendChild(node); - } else { - hander.currentElement.appendChild(node); - } -}//appendChild and setAttributeNS are preformance key - -//if(typeof require == 'function'){ - var XMLReader = __webpack_require__(46).XMLReader; - var DOMImplementation = exports.DOMImplementation = __webpack_require__(17).DOMImplementation; - exports.XMLSerializer = __webpack_require__(17).XMLSerializer ; - exports.DOMParser = DOMParser; -//} - - -/***/ }), -/* 46 */ -/***/ (function(module, exports) { - -//[4] NameStartChar ::= ":" | [A-Z] | "_" | [a-z] | [#xC0-#xD6] | [#xD8-#xF6] | [#xF8-#x2FF] | [#x370-#x37D] | [#x37F-#x1FFF] | [#x200C-#x200D] | [#x2070-#x218F] | [#x2C00-#x2FEF] | [#x3001-#xD7FF] | [#xF900-#xFDCF] | [#xFDF0-#xFFFD] | [#x10000-#xEFFFF] -//[4a] NameChar ::= NameStartChar | "-" | "." | [0-9] | #xB7 | [#x0300-#x036F] | [#x203F-#x2040] -//[5] Name ::= NameStartChar (NameChar)* -var nameStartChar = /[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]///\u10000-\uEFFFF -var nameChar = new RegExp("[\\-\\.0-9"+nameStartChar.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"); -var tagNamePattern = new RegExp('^'+nameStartChar.source+nameChar.source+'*(?:\:'+nameStartChar.source+nameChar.source+'*)?$'); -//var tagNamePattern = /^[a-zA-Z_][\w\-\.]*(?:\:[a-zA-Z_][\w\-\.]*)?$/ -//var handlers = 'resolveEntity,getExternalSubset,characters,endDocument,endElement,endPrefixMapping,ignorableWhitespace,processingInstruction,setDocumentLocator,skippedEntity,startDocument,startElement,startPrefixMapping,notationDecl,unparsedEntityDecl,error,fatalError,warning,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,comment,endCDATA,endDTD,endEntity,startCDATA,startDTD,startEntity'.split(',') - -//S_TAG, S_ATTR, S_EQ, S_ATTR_NOQUOT_VALUE -//S_ATTR_SPACE, S_ATTR_END, S_TAG_SPACE, S_TAG_CLOSE -var S_TAG = 0;//tag name offerring -var S_ATTR = 1;//attr name offerring -var S_ATTR_SPACE=2;//attr name end and space offer -var S_EQ = 3;//=space? -var S_ATTR_NOQUOT_VALUE = 4;//attr value(no quot value only) -var S_ATTR_END = 5;//attr value end and no space(quot end) -var S_TAG_SPACE = 6;//(attr value end || tag end ) && (space offer) -var S_TAG_CLOSE = 7;//closed el - -function XMLReader(){ - -} - -XMLReader.prototype = { - parse:function(source,defaultNSMap,entityMap){ - var domBuilder = this.domBuilder; - domBuilder.startDocument(); - _copy(defaultNSMap ,defaultNSMap = {}) - parse(source,defaultNSMap,entityMap, - domBuilder,this.errorHandler); - domBuilder.endDocument(); - } -} -function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){ - function fixedFromCharCode(code) { - // String.prototype.fromCharCode does not supports - // > 2 bytes unicode chars directly - if (code > 0xffff) { - code -= 0x10000; - var surrogate1 = 0xd800 + (code >> 10) - , surrogate2 = 0xdc00 + (code & 0x3ff); - - return String.fromCharCode(surrogate1, surrogate2); - } else { - return String.fromCharCode(code); - } - } - function entityReplacer(a){ - var k = a.slice(1,-1); - if(k in entityMap){ - return entityMap[k]; - }else if(k.charAt(0) === '#'){ - return fixedFromCharCode(parseInt(k.substr(1).replace('x','0x'))) - }else{ - errorHandler.error('entity not found:'+a); - return a; - } - } - function appendText(end){//has some bugs - if(end>start){ - var xt = source.substring(start,end).replace(/&#?\w+;/g,entityReplacer); - locator&&position(start); - domBuilder.characters(xt,0,end-start); - start = end - } - } - function position(p,m){ - while(p>=lineEnd && (m = linePattern.exec(source))){ - lineStart = m.index; - lineEnd = lineStart + m[0].length; - locator.lineNumber++; - //console.log('line++:',locator,startPos,endPos) - } - locator.columnNumber = p-lineStart+1; - } - var lineStart = 0; - var lineEnd = 0; - var linePattern = /.*(?:\r\n?|\n)|.*$/g - var locator = domBuilder.locator; - - var parseStack = [{currentNSMap:defaultNSMapCopy}] - var closeMap = {}; - var start = 0; - while(true){ - try{ - var tagStart = source.indexOf('<',start); - if(tagStart<0){ - if(!source.substr(start).match(/^\s*$/)){ - var doc = domBuilder.doc; - var text = doc.createTextNode(source.substr(start)); - doc.appendChild(text); - domBuilder.currentElement = text; - } - return; - } - if(tagStart>start){ - appendText(tagStart); - } - switch(source.charAt(tagStart+1)){ - case '/': - var end = source.indexOf('>',tagStart+3); - var tagName = source.substring(tagStart+2,end); - var config = parseStack.pop(); - if(end<0){ - - tagName = source.substring(tagStart+2).replace(/[\s<].*/,''); - //console.error('#@@@@@@'+tagName) - errorHandler.error("end tag name: "+tagName+' is not complete:'+config.tagName); - end = tagStart+1+tagName.length; - }else if(tagName.match(/\s - locator&&position(tagStart); - end = parseInstruction(source,tagStart,domBuilder); - break; - case '!':// start){ - start = end; - }else{ - //TODO: 这里有可能sax回退,有位置错误风险 - appendText(Math.max(tagStart,start)+1); - } - } -} -function copyLocator(f,t){ - t.lineNumber = f.lineNumber; - t.columnNumber = f.columnNumber; - return t; -} - -/** - * @see #appendElement(source,elStartEnd,el,selfClosed,entityReplacer,domBuilder,parseStack); - * @return end of the elementStartPart(end of elementEndPart for selfClosed el) - */ -function parseElementStartPart(source,start,el,currentNSMap,entityReplacer,errorHandler){ - var attrName; - var value; - var p = ++start; - var s = S_TAG;//status - while(true){ - var c = source.charAt(p); - switch(c){ - case '=': - if(s === S_ATTR){//attrName - attrName = source.slice(start,p); - s = S_EQ; - }else if(s === S_ATTR_SPACE){ - s = S_EQ; - }else{ - //fatalError: equal must after attrName or space after attrName - throw new Error('attribute equal must after attrName'); - } - break; - case '\'': - case '"': - if(s === S_EQ || s === S_ATTR //|| s == S_ATTR_SPACE - ){//equal - if(s === S_ATTR){ - errorHandler.warning('attribute value must after "="') - attrName = source.slice(start,p) - } - start = p+1; - p = source.indexOf(c,start) - if(p>0){ - value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer); - el.add(attrName,value,start-1); - s = S_ATTR_END; - }else{ - //fatalError: no end quot match - throw new Error('attribute value no end \''+c+'\' match'); - } - }else if(s == S_ATTR_NOQUOT_VALUE){ - value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer); - //console.log(attrName,value,start,p) - el.add(attrName,value,start); - //console.dir(el) - errorHandler.warning('attribute "'+attrName+'" missed start quot('+c+')!!'); - start = p+1; - s = S_ATTR_END - }else{ - //fatalError: no equal before - throw new Error('attribute value must after "="'); - } - break; - case '/': - switch(s){ - case S_TAG: - el.setTagName(source.slice(start,p)); - case S_ATTR_END: - case S_TAG_SPACE: - case S_TAG_CLOSE: - s =S_TAG_CLOSE; - el.closed = true; - case S_ATTR_NOQUOT_VALUE: - case S_ATTR: - case S_ATTR_SPACE: - break; - //case S_EQ: - default: - throw new Error("attribute invalid close char('/')") - } - break; - case ''://end document - //throw new Error('unexpected end of input') - errorHandler.error('unexpected end of input'); - if(s == S_TAG){ - el.setTagName(source.slice(start,p)); - } - return p; - case '>': - switch(s){ - case S_TAG: - el.setTagName(source.slice(start,p)); - case S_ATTR_END: - case S_TAG_SPACE: - case S_TAG_CLOSE: - break;//normal - case S_ATTR_NOQUOT_VALUE://Compatible state - case S_ATTR: - value = source.slice(start,p); - if(value.slice(-1) === '/'){ - el.closed = true; - value = value.slice(0,-1) - } - case S_ATTR_SPACE: - if(s === S_ATTR_SPACE){ - value = attrName; - } - if(s == S_ATTR_NOQUOT_VALUE){ - errorHandler.warning('attribute "'+value+'" missed quot(")!!'); - el.add(attrName,value.replace(/&#?\w+;/g,entityReplacer),start) - }else{ - if(currentNSMap[''] !== 'http://www.w3.org/1999/xhtml' || !value.match(/^(?:disabled|checked|selected)$/i)){ - errorHandler.warning('attribute "'+value+'" missed value!! "'+value+'" instead!!') - } - el.add(value,value,start) - } - break; - case S_EQ: - throw new Error('attribute value missed!!'); - } -// console.log(tagName,tagNamePattern,tagNamePattern.test(tagName)) - return p; - /*xml space '\x20' | #x9 | #xD | #xA; */ - case '\u0080': - c = ' '; - default: - if(c<= ' '){//space - switch(s){ - case S_TAG: - el.setTagName(source.slice(start,p));//tagName - s = S_TAG_SPACE; - break; - case S_ATTR: - attrName = source.slice(start,p) - s = S_ATTR_SPACE; - break; - case S_ATTR_NOQUOT_VALUE: - var value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer); - errorHandler.warning('attribute "'+value+'" missed quot(")!!'); - el.add(attrName,value,start) - case S_ATTR_END: - s = S_TAG_SPACE; - break; - //case S_TAG_SPACE: - //case S_EQ: - //case S_ATTR_SPACE: - // void();break; - //case S_TAG_CLOSE: - //ignore warning - } - }else{//not space -//S_TAG, S_ATTR, S_EQ, S_ATTR_NOQUOT_VALUE -//S_ATTR_SPACE, S_ATTR_END, S_TAG_SPACE, S_TAG_CLOSE - switch(s){ - //case S_TAG:void();break; - //case S_ATTR:void();break; - //case S_ATTR_NOQUOT_VALUE:void();break; - case S_ATTR_SPACE: - var tagName = el.tagName; - if(currentNSMap[''] !== 'http://www.w3.org/1999/xhtml' || !attrName.match(/^(?:disabled|checked|selected)$/i)){ - errorHandler.warning('attribute "'+attrName+'" missed value!! "'+attrName+'" instead2!!') - } - el.add(attrName,attrName,start); - start = p; - s = S_ATTR; - break; - case S_ATTR_END: - errorHandler.warning('attribute space is required"'+attrName+'"!!') - case S_TAG_SPACE: - s = S_ATTR; - start = p; - break; - case S_EQ: - s = S_ATTR_NOQUOT_VALUE; - start = p; - break; - case S_TAG_CLOSE: - throw new Error("elements closed character '/' and '>' must be connected to"); - } - } - }//end outer switch - //console.log('p++',p) - p++; - } -} -/** - * @return true if has new namespace define - */ -function appendElement(el,domBuilder,currentNSMap){ - var tagName = el.tagName; - var localNSMap = null; - //var currentNSMap = parseStack[parseStack.length-1].currentNSMap; - var i = el.length; - while(i--){ - var a = el[i]; - var qName = a.qName; - var value = a.value; - var nsp = qName.indexOf(':'); - if(nsp>0){ - var prefix = a.prefix = qName.slice(0,nsp); - var localName = qName.slice(nsp+1); - var nsPrefix = prefix === 'xmlns' && localName - }else{ - localName = qName; - prefix = null - nsPrefix = qName === 'xmlns' && '' - } - //can not set prefix,because prefix !== '' - a.localName = localName ; - //prefix == null for no ns prefix attribute - if(nsPrefix !== false){//hack!! - if(localNSMap == null){ - localNSMap = {} - //console.log(currentNSMap,0) - _copy(currentNSMap,currentNSMap={}) - //console.log(currentNSMap,1) - } - currentNSMap[nsPrefix] = localNSMap[nsPrefix] = value; - a.uri = 'http://www.w3.org/2000/xmlns/' - domBuilder.startPrefixMapping(nsPrefix, value) - } - } - var i = el.length; - while(i--){ - a = el[i]; - var prefix = a.prefix; - if(prefix){//no prefix attribute has no namespace - if(prefix === 'xml'){ - a.uri = 'http://www.w3.org/XML/1998/namespace'; - }if(prefix !== 'xmlns'){ - a.uri = currentNSMap[prefix || ''] - - //{console.log('###'+a.qName,domBuilder.locator.systemId+'',currentNSMap,a.uri)} - } - } - } - var nsp = tagName.indexOf(':'); - if(nsp>0){ - prefix = el.prefix = tagName.slice(0,nsp); - localName = el.localName = tagName.slice(nsp+1); - }else{ - prefix = null;//important!! - localName = el.localName = tagName; - } - //no prefix element has default namespace - var ns = el.uri = currentNSMap[prefix || '']; - domBuilder.startElement(ns,localName,tagName,el); - //endPrefixMapping and startPrefixMapping have not any help for dom builder - //localNSMap = null - if(el.closed){ - domBuilder.endElement(ns,localName,tagName); - if(localNSMap){ - for(prefix in localNSMap){ - domBuilder.endPrefixMapping(prefix) - } - } - }else{ - el.currentNSMap = currentNSMap; - el.localNSMap = localNSMap; - //parseStack.push(el); - return true; - } -} -function parseHtmlSpecialContent(source,elStartEnd,tagName,entityReplacer,domBuilder){ - if(/^(?:script|textarea)$/i.test(tagName)){ - var elEndStart = source.indexOf('',elStartEnd); - var text = source.substring(elStartEnd+1,elEndStart); - if(/[&<]/.test(text)){ - if(/^script$/i.test(tagName)){ - //if(!/\]\]>/.test(text)){ - //lexHandler.startCDATA(); - domBuilder.characters(text,0,text.length); - //lexHandler.endCDATA(); - return elEndStart; - //} - }//}else{//text area - text = text.replace(/&#?\w+;/g,entityReplacer); - domBuilder.characters(text,0,text.length); - return elEndStart; - //} - - } - } - return elStartEnd+1; -} -function fixSelfClosed(source,elStartEnd,tagName,closeMap){ - //if(tagName in closeMap){ - var pos = closeMap[tagName]; - if(pos == null){ - //console.log(tagName) - pos = source.lastIndexOf('') - if(pos',start+4); - //append comment source.substring(4,end)// https://davidwalsh.name/add-rules-stylesheets - style.appendChild(document.createTextNode("")); - - document.head.appendChild(style); - - return style.sheet; - } - }, { - key: "addStyleRules", - value: function addStyleRules(selector, rulesArray) { - var scope = "#" + this.id + " "; - var rules = ""; - - if (!this.sheet) { - this.sheet = this.getSheet(); - } - - rulesArray.forEach(function (set) { - for (var prop in set) { - if (set.hasOwnProperty(prop)) { - rules += prop + ":" + set[prop] + ";"; - } - } - }); - - this.sheet.insertRule(scope + selector + " {" + rules + "}", 0); - } - }, { - key: "axis", - value: function axis(_axis) { - if (_axis === "horizontal") { - this.container.style.display = "flex"; - this.container.style.flexDirection = "row"; - this.container.style.flexWrap = "nowrap"; - } else { - this.container.style.display = "block"; - } - this.settings.axis = _axis; - } - - // orientation(orientation) { - // if (orientation === "landscape") { - // - // } else { - // - // } - // - // this.orientation = orientation; - // } - - }, { - key: "direction", - value: function direction(dir) { - if (this.container) { - this.container.dir = dir; - this.container.style["direction"] = dir; - } - - if (this.settings.fullsize) { - document.body.style["direction"] = dir; - } - this.settings.dir = dir; - } - }, { - key: "overflow", - value: function overflow(_overflow) { - if (this.container) { - if (_overflow === "scroll" && this.settings.axis === "vertical") { - this.container.style["overflow-y"] = _overflow; - this.container.style["overflow-x"] = "hidden"; - } else if (_overflow === "scroll" && this.settings.axis === "horizontal") { - this.container.style["overflow-y"] = "hidden"; - this.container.style["overflow-x"] = _overflow; - } else { - this.container.style["overflow"] = _overflow; - } - } - this.settings.overflow = _overflow; - } - }, { - key: "destroy", - value: function destroy() { - var base; - - if (this.element) { - - if (this.settings.hidden) { - base = this.wrapper; - } else { - base = this.container; - } - - if (this.element.contains(this.container)) { - this.element.removeChild(this.container); - } - - window.removeEventListener("resize", this.resizeFunc); - window.removeEventListener("orientationChange", this.orientationChangeFunc); - } - } - }]); - - return Stage; -}(); - -exports.default = Stage; -module.exports = exports["default"]; - -/***/ }), -/* 60 */ -/***/ (function(module, exports, __webpack_require__) { - -var debounce = __webpack_require__(21), - isObject = __webpack_require__(16); - -/** Error message constants. */ -var FUNC_ERROR_TEXT = 'Expected a function'; - -/** - * Creates a throttled function that only invokes `func` at most once per - * every `wait` milliseconds. The throttled function comes with a `cancel` - * method to cancel delayed `func` invocations and a `flush` method to - * immediately invoke them. Provide `options` to indicate whether `func` - * should be invoked on the leading and/or trailing edge of the `wait` - * timeout. The `func` is invoked with the last arguments provided to the - * throttled function. Subsequent calls to the throttled function return the - * result of the last `func` invocation. - * - * **Note:** If `leading` and `trailing` options are `true`, `func` is - * invoked on the trailing edge of the timeout only if the throttled function - * is invoked more than once during the `wait` timeout. - * - * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred - * until to the next tick, similar to `setTimeout` with a timeout of `0`. - * - * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/) - * for details over the differences between `_.throttle` and `_.debounce`. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Function - * @param {Function} func The function to throttle. - * @param {number} [wait=0] The number of milliseconds to throttle invocations to. - * @param {Object} [options={}] The options object. - * @param {boolean} [options.leading=true] - * Specify invoking on the leading edge of the timeout. - * @param {boolean} [options.trailing=true] - * Specify invoking on the trailing edge of the timeout. - * @returns {Function} Returns the new throttled function. - * @example - * - * // Avoid excessively updating the position while scrolling. - * jQuery(window).on('scroll', _.throttle(updatePosition, 100)); - * - * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes. - * var throttled = _.throttle(renewToken, 300000, { 'trailing': false }); - * jQuery(element).on('click', throttled); - * - * // Cancel the trailing throttled invocation. - * jQuery(window).on('popstate', throttled.cancel); - */ -function throttle(func, wait, options) { - var leading = true, - trailing = true; - - if (typeof func != 'function') { - throw new TypeError(FUNC_ERROR_TEXT); - } - if (isObject(options)) { - leading = 'leading' in options ? !!options.leading : leading; - trailing = 'trailing' in options ? !!options.trailing : trailing; - } - return debounce(func, wait, { - 'leading': leading, - 'maxWait': wait, - 'trailing': trailing - }); -} - -module.exports = throttle; - - -/***/ }), -/* 61 */ -/***/ (function(module, exports, __webpack_require__) { - -var root = __webpack_require__(22); - -/** - * Gets the timestamp of the number of milliseconds that have elapsed since - * the Unix epoch (1 January 1970 00:00:00 UTC). - * - * @static - * @memberOf _ - * @since 2.4.0 - * @category Date - * @returns {number} Returns the timestamp. - * @example - * - * _.defer(function(stamp) { - * console.log(_.now() - stamp); - * }, _.now()); - * // => Logs the number of milliseconds it took for the deferred invocation. - */ -var now = function() { - return root.Date.now(); -}; - -module.exports = now; - - -/***/ }), -/* 62 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(global) {/** Detect free variable `global` from Node.js. */ -var freeGlobal = typeof global == 'object' && global && global.Object === Object && global; - -module.exports = freeGlobal; - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5))) - -/***/ }), -/* 63 */ -/***/ (function(module, exports, __webpack_require__) { - -var isObject = __webpack_require__(16), - isSymbol = __webpack_require__(64); - -/** Used as references for various `Number` constants. */ -var NAN = 0 / 0; - -/** Used to match leading and trailing whitespace. */ -var reTrim = /^\s+|\s+$/g; - -/** Used to detect bad signed hexadecimal string values. */ -var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; - -/** Used to detect binary string values. */ -var reIsBinary = /^0b[01]+$/i; - -/** Used to detect octal string values. */ -var reIsOctal = /^0o[0-7]+$/i; - -/** Built-in method references without a dependency on `root`. */ -var freeParseInt = parseInt; - -/** - * Converts `value` to a number. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to process. - * @returns {number} Returns the number. - * @example - * - * _.toNumber(3.2); - * // => 3.2 - * - * _.toNumber(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toNumber(Infinity); - * // => Infinity - * - * _.toNumber('3.2'); - * // => 3.2 - */ -function toNumber(value) { - if (typeof value == 'number') { - return value; - } - if (isSymbol(value)) { - return NAN; - } - if (isObject(value)) { - var other = typeof value.valueOf == 'function' ? value.valueOf() : value; - value = isObject(other) ? (other + '') : other; - } - if (typeof value != 'string') { - return value === 0 ? value : +value; - } - value = value.replace(reTrim, ''); - var isBinary = reIsBinary.test(value); - return (isBinary || reIsOctal.test(value)) - ? freeParseInt(value.slice(2), isBinary ? 2 : 8) - : (reIsBadHex.test(value) ? NAN : +value); -} - -module.exports = toNumber; - - -/***/ }), -/* 64 */ -/***/ (function(module, exports, __webpack_require__) { - -var baseGetTag = __webpack_require__(65), - isObjectLike = __webpack_require__(68); - -/** `Object#toString` result references. */ -var symbolTag = '[object Symbol]'; - -/** - * Checks if `value` is classified as a `Symbol` primitive or object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. - * @example - * - * _.isSymbol(Symbol.iterator); - * // => true - * - * _.isSymbol('abc'); - * // => false - */ -function isSymbol(value) { - return typeof value == 'symbol' || - (isObjectLike(value) && baseGetTag(value) == symbolTag); -} - -module.exports = isSymbol; - - -/***/ }), -/* 65 */ -/***/ (function(module, exports, __webpack_require__) { - -var Symbol = __webpack_require__(23), - getRawTag = __webpack_require__(66), - objectToString = __webpack_require__(67); - -/** `Object#toString` result references. */ -var nullTag = '[object Null]', - undefinedTag = '[object Undefined]'; - -/** Built-in value references. */ -var symToStringTag = Symbol ? Symbol.toStringTag : undefined; - -/** - * The base implementation of `getTag` without fallbacks for buggy environments. - * - * @private - * @param {*} value The value to query. - * @returns {string} Returns the `toStringTag`. - */ -function baseGetTag(value) { - if (value == null) { - return value === undefined ? undefinedTag : nullTag; - } - return (symToStringTag && symToStringTag in Object(value)) - ? getRawTag(value) - : objectToString(value); -} - -module.exports = baseGetTag; - - -/***/ }), -/* 66 */ -/***/ (function(module, exports, __webpack_require__) { - -var Symbol = __webpack_require__(23); - -/** Used for built-in method references. */ -var objectProto = Object.prototype; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; - -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var nativeObjectToString = objectProto.toString; - -/** Built-in value references. */ -var symToStringTag = Symbol ? Symbol.toStringTag : undefined; - -/** - * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values. - * - * @private - * @param {*} value The value to query. - * @returns {string} Returns the raw `toStringTag`. - */ -function getRawTag(value) { - var isOwn = hasOwnProperty.call(value, symToStringTag), - tag = value[symToStringTag]; - - try { - value[symToStringTag] = undefined; - var unmasked = true; - } catch (e) {} - - var result = nativeObjectToString.call(value); - if (unmasked) { - if (isOwn) { - value[symToStringTag] = tag; - } else { - delete value[symToStringTag]; - } - } - return result; -} - -module.exports = getRawTag; - - -/***/ }), -/* 67 */ -/***/ (function(module, exports) { - -/** Used for built-in method references. */ -var objectProto = Object.prototype; - -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var nativeObjectToString = objectProto.toString; - -/** - * Converts `value` to a string using `Object.prototype.toString`. - * - * @private - * @param {*} value The value to convert. - * @returns {string} Returns the converted string. - */ -function objectToString(value) { - return nativeObjectToString.call(value); -} - -module.exports = objectToString; - - -/***/ }), -/* 68 */ -/***/ (function(module, exports) { - -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return value != null && typeof value == 'object'; -} - -module.exports = isObjectLike; - - -/***/ }), -/* 69 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -var Views = function () { - function Views(container) { - _classCallCheck(this, Views); - - this.container = container; - this._views = []; - this.length = 0; - this.hidden = false; - } - - _createClass(Views, [{ - key: "all", - value: function all() { - return this._views; - } - }, { - key: "first", - value: function first() { - return this._views[0]; - } - }, { - key: "last", - value: function last() { - return this._views[this._views.length - 1]; - } - }, { - key: "indexOf", - value: function indexOf(view) { - return this._views.indexOf(view); - } - }, { - key: "slice", - value: function slice() { - return this._views.slice.apply(this._views, arguments); - } - }, { - key: "get", - value: function get(i) { - return this._views[i]; - } - }, { - key: "append", - value: function append(view) { - this._views.push(view); - if (this.container) { - this.container.appendChild(view.element); - } - this.length++; - return view; - } - }, { - key: "prepend", - value: function prepend(view) { - this._views.unshift(view); - if (this.container) { - this.container.insertBefore(view.element, this.container.firstChild); - } - this.length++; - return view; - } - }, { - key: "insert", - value: function insert(view, index) { - this._views.splice(index, 0, view); - - if (this.container) { - if (index < this.container.children.length) { - this.container.insertBefore(view.element, this.container.children[index]); - } else { - this.container.appendChild(view.element); - } - } - - this.length++; - return view; - } - }, { - key: "remove", - value: function remove(view) { - var index = this._views.indexOf(view); - - if (index > -1) { - this._views.splice(index, 1); - } - - this.destroy(view); - - this.length--; - } - }, { - key: "destroy", - value: function destroy(view) { - if (view.displayed) { - view.destroy(); - } - - if (this.container) { - this.container.removeChild(view.element); - } - view = null; - } - - // Iterators - - }, { - key: "forEach", - value: function forEach() { - return this._views.forEach.apply(this._views, arguments); - } - }, { - key: "clear", - value: function clear() { - // Remove all views - var view; - var len = this.length; - - if (!this.length) return; - - for (var i = 0; i < len; i++) { - view = this._views[i]; - this.destroy(view); - } - - this._views = []; - this.length = 0; - } - }, { - key: "find", - value: function find(section) { - - var view; - var len = this.length; - - for (var i = 0; i < len; i++) { - view = this._views[i]; - if (view.displayed && view.section.index == section.index) { - return view; - } - } - } - }, { - key: "displayed", - value: function displayed() { - var displayed = []; - var view; - var len = this.length; - - for (var i = 0; i < len; i++) { - view = this._views[i]; - if (view.displayed) { - displayed.push(view); - } - } - return displayed; - } - }, { - key: "show", - value: function show() { - var view; - var len = this.length; - - for (var i = 0; i < len; i++) { - view = this._views[i]; - if (view.displayed) { - view.show(); - } - } - this.hidden = false; - } - }, { - key: "hide", - value: function hide() { - var view; - var len = this.length; - - for (var i = 0; i < len; i++) { - view = this._views[i]; - if (view.displayed) { - view.hide(); - } - } - this.hidden = true; - } - }]); - - return Views; -}(); - -exports.default = Views; -module.exports = exports["default"]; - -/***/ }), -/* 70 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _core = __webpack_require__(0); - -var _constants = __webpack_require__(2); - -var _eventEmitter = __webpack_require__(3); - -var _eventEmitter2 = _interopRequireDefault(_eventEmitter); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -// easing equations from https://github.com/danro/easing-js/blob/master/easing.js -var PI_D2 = Math.PI / 2; -var EASING_EQUATIONS = { - easeOutSine: function easeOutSine(pos) { - return Math.sin(pos * PI_D2); - }, - easeInOutSine: function easeInOutSine(pos) { - return -0.5 * (Math.cos(Math.PI * pos) - 1); - }, - easeInOutQuint: function easeInOutQuint(pos) { - if ((pos /= 0.5) < 1) { - return 0.5 * Math.pow(pos, 5); - } - return 0.5 * (Math.pow(pos - 2, 5) + 2); - }, - easeInCubic: function easeInCubic(pos) { - return Math.pow(pos, 3); - } -}; - -var Snap = function () { - function Snap(manager, options) { - _classCallCheck(this, Snap); - - this.settings = (0, _core.extend)({ - duration: 80, - minVelocity: 0.2, - minDistance: 10, - easing: EASING_EQUATIONS['easeInCubic'] - }, options || {}); - - this.supportsTouch = this.supportsTouch(); - - if (this.supportsTouch) { - this.setup(manager); - } - } - - _createClass(Snap, [{ - key: "setup", - value: function setup(manager) { - this.manager = manager; - - this.layout = this.manager.layout; - - this.fullsize = this.manager.settings.fullsize; - if (this.fullsize) { - this.element = this.manager.stage.element; - this.scroller = window; - this.disableScroll(); - } else { - this.element = this.manager.stage.container; - this.scroller = this.element; - this.element.style["WebkitOverflowScrolling"] = "touch"; - } - - // this.overflow = this.manager.overflow; - - // set lookahead offset to page width - this.manager.settings.offset = this.layout.width; - this.manager.settings.afterScrolledTimeout = this.settings.duration * 2; - - this.isVertical = this.manager.settings.axis === "vertical"; - - // disable snapping if not paginated or axis in not horizontal - if (!this.manager.isPaginated || this.isVertical) { - return; - } - - this.touchCanceler = false; - this.resizeCanceler = false; - this.snapping = false; - - this.scrollLeft; - this.scrollTop; - - this.startTouchX = undefined; - this.startTouchY = undefined; - this.startTime = undefined; - this.endTouchX = undefined; - this.endTouchY = undefined; - this.endTime = undefined; - - this.addListeners(); - } - }, { - key: "supportsTouch", - value: function supportsTouch() { - if ('ontouchstart' in window || window.DocumentTouch && document instanceof DocumentTouch) { - return true; - } - - return false; - } - }, { - key: "disableScroll", - value: function disableScroll() { - this.element.style.overflow = "hidden"; - } - }, { - key: "enableScroll", - value: function enableScroll() { - this.element.style.overflow = ""; - } - }, { - key: "addListeners", - value: function addListeners() { - this._onResize = this.onResize.bind(this); - window.addEventListener('resize', this._onResize); - - this._onScroll = this.onScroll.bind(this); - this.scroller.addEventListener('scroll', this._onScroll); - - this._onTouchStart = this.onTouchStart.bind(this); - this.scroller.addEventListener('touchstart', this._onTouchStart, { passive: true }); - this.on('touchstart', this._onTouchStart); - - this._onTouchMove = this.onTouchMove.bind(this); - this.scroller.addEventListener('touchmove', this._onTouchMove, { passive: true }); - this.on('touchmove', this._onTouchMove); - - this._onTouchEnd = this.onTouchEnd.bind(this); - this.scroller.addEventListener('touchend', this._onTouchEnd, { passive: true }); - this.on('touchend', this._onTouchEnd); - - this._afterDisplayed = this.afterDisplayed.bind(this); - this.manager.on(_constants.EVENTS.MANAGERS.ADDED, this._afterDisplayed); - } - }, { - key: "removeListeners", - value: function removeListeners() { - window.removeEventListener('resize', this._onResize); - this._onResize = undefined; - - this.scroller.removeEventListener('scroll', this._onScroll); - this._onScroll = undefined; - - this.scroller.removeEventListener('touchstart', this._onTouchStart, { passive: true }); - this.off('touchstart', this._onTouchStart); - this._onTouchStart = undefined; - - this.scroller.removeEventListener('touchmove', this._onTouchMove, { passive: true }); - this.off('touchmove', this._onTouchMove); - this._onTouchMove = undefined; - - this.scroller.removeEventListener('touchend', this._onTouchEnd, { passive: true }); - this.off('touchend', this._onTouchEnd); - this._onTouchEnd = undefined; - - this.manager.off(_constants.EVENTS.MANAGERS.ADDED, this._afterDisplayed); - this._afterDisplayed = undefined; - } - }, { - key: "afterDisplayed", - value: function afterDisplayed(view) { - var _this = this; - - var contents = view.contents; - ["touchstart", "touchmove", "touchend"].forEach(function (e) { - contents.on(e, function (ev) { - return _this.triggerViewEvent(ev, contents); - }); - }); - } - }, { - key: "triggerViewEvent", - value: function triggerViewEvent(e, contents) { - this.emit(e.type, e, contents); - } - }, { - key: "onScroll", - value: function onScroll(e) { - this.scrollLeft = this.fullsize ? window.scrollX : this.scroller.scrollLeft; - this.scrollTop = this.fullsize ? window.scrollY : this.scroller.scrollTop; - } - }, { - key: "onResize", - value: function onResize(e) { - this.resizeCanceler = true; - } - }, { - key: "onTouchStart", - value: function onTouchStart(e) { - var _e$touches$ = e.touches[0], - screenX = _e$touches$.screenX, - screenY = _e$touches$.screenY; - - - if (this.fullsize) { - this.enableScroll(); - } - - this.touchCanceler = true; - - if (!this.startTouchX) { - this.startTouchX = screenX; - this.startTouchY = screenY; - this.startTime = this.now(); - } - - this.endTouchX = screenX; - this.endTouchY = screenY; - this.endTime = this.now(); - } - }, { - key: "onTouchMove", - value: function onTouchMove(e) { - var _e$touches$2 = e.touches[0], - screenX = _e$touches$2.screenX, - screenY = _e$touches$2.screenY; - - var deltaY = Math.abs(screenY - this.endTouchY); - - this.touchCanceler = true; - - if (!this.fullsize && deltaY < 10) { - this.element.scrollLeft -= screenX - this.endTouchX; - } - - this.endTouchX = screenX; - this.endTouchY = screenY; - this.endTime = this.now(); - } - }, { - key: "onTouchEnd", - value: function onTouchEnd(e) { - if (this.fullsize) { - this.disableScroll(); - } - - this.touchCanceler = false; - - var swipped = this.wasSwiped(); - - if (swipped !== 0) { - this.snap(swipped); - } else { - this.snap(); - } - - this.startTouchX = undefined; - this.startTouchY = undefined; - this.startTime = undefined; - this.endTouchX = undefined; - this.endTouchY = undefined; - this.endTime = undefined; - } - }, { - key: "wasSwiped", - value: function wasSwiped() { - var snapWidth = this.layout.pageWidth * this.layout.divisor; - var distance = this.endTouchX - this.startTouchX; - var absolute = Math.abs(distance); - var time = this.endTime - this.startTime; - var velocity = distance / time; - var minVelocity = this.settings.minVelocity; - - if (absolute <= this.settings.minDistance || absolute >= snapWidth) { - return 0; - } - - if (velocity > minVelocity) { - // previous - return -1; - } else if (velocity < -minVelocity) { - // next - return 1; - } - } - }, { - key: "needsSnap", - value: function needsSnap() { - var left = this.scrollLeft; - var snapWidth = this.layout.pageWidth * this.layout.divisor; - return left % snapWidth !== 0; - } - }, { - key: "snap", - value: function snap() { - var howMany = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0; - - var left = this.scrollLeft; - var snapWidth = this.layout.pageWidth * this.layout.divisor; - var snapTo = Math.round(left / snapWidth) * snapWidth; - - if (howMany) { - snapTo += howMany * snapWidth; - } - - return this.smoothScrollTo(snapTo); - } - }, { - key: "smoothScrollTo", - value: function smoothScrollTo(destination) { - var deferred = new _core.defer(); - var start = this.scrollLeft; - var startTime = this.now(); - - var duration = this.settings.duration; - var easing = this.settings.easing; - - this.snapping = true; - - // add animation loop - function tick() { - var now = this.now(); - var time = Math.min(1, (now - startTime) / duration); - var timeFunction = easing(time); - - if (this.touchCanceler || this.resizeCanceler) { - this.resizeCanceler = false; - this.snapping = false; - deferred.resolve(); - return; - } - - if (time < 1) { - window.requestAnimationFrame(tick.bind(this)); - this.scrollTo(start + (destination - start) * time, 0); - } else { - this.scrollTo(destination, 0); - this.snapping = false; - deferred.resolve(); - } - } - - tick.call(this); - - return deferred.promise; - } - }, { - key: "scrollTo", - value: function scrollTo() { - var left = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0; - var top = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0; - - if (this.fullsize) { - window.scroll(left, top); - } else { - this.scroller.scrollLeft = left; - this.scroller.scrollTop = top; - } - } - }, { - key: "now", - value: function now() { - return 'now' in window.performance ? performance.now() : new Date().getTime(); - } - }, { - key: "destroy", - value: function destroy() { - if (!this.scroller) { - return; - } - - if (this.fullsize) { - this.enableScroll(); - } - - this.removeListeners(); - - this.scroller = undefined; - } - }]); - - return Snap; -}(); - -(0, _eventEmitter2.default)(Snap.prototype); - -exports.default = Snap; -module.exports = exports["default"]; - -/***/ }), -/* 71 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _core = __webpack_require__(0); - -var _request = __webpack_require__(9); - -var _request2 = _interopRequireDefault(_request); - -var _mime = __webpack_require__(13); - -var _mime2 = _interopRequireDefault(_mime); - -var _path = __webpack_require__(4); - -var _path2 = _interopRequireDefault(_path); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Handles Unzipping a requesting files from an Epub Archive - * @class - */ -var Archive = function () { - function Archive() { - _classCallCheck(this, Archive); - - this.zip = undefined; - this.urlCache = {}; - - this.checkRequirements(); - } - - /** - * Checks to see if JSZip exists in global namspace, - * Requires JSZip if it isn't there - * @private - */ - - - _createClass(Archive, [{ - key: "checkRequirements", - value: function checkRequirements() { - try { - if (typeof JSZip === "undefined") { - var _JSZip = __webpack_require__(72); - this.zip = new _JSZip(); - } else { - this.zip = new JSZip(); - } - } catch (e) { - throw new Error("JSZip lib not loaded"); - } - } - - /** - * Open an archive - * @param {binary} input - * @param {boolean} [isBase64] tells JSZip if the input data is base64 encoded - * @return {Promise} zipfile - */ - - }, { - key: "open", - value: function open(input, isBase64) { - return this.zip.loadAsync(input, { "base64": isBase64 }); - } - - /** - * Load and Open an archive - * @param {string} zipUrl - * @param {boolean} [isBase64] tells JSZip if the input data is base64 encoded - * @return {Promise} zipfile - */ - - }, { - key: "openUrl", - value: function openUrl(zipUrl, isBase64) { - return (0, _request2.default)(zipUrl, "binary").then(function (data) { - return this.zip.loadAsync(data, { "base64": isBase64 }); - }.bind(this)); - } - - /** - * Request a url from the archive - * @param {string} url a url to request from the archive - * @param {string} [type] specify the type of the returned result - * @return {Promise} - */ - - }, { - key: "request", - value: function request(url, type) { - var deferred = new _core.defer(); - var response; - var path = new _path2.default(url); - - // If type isn't set, determine it from the file extension - if (!type) { - type = path.extension; - } - - if (type == "blob") { - response = this.getBlob(url); - } else { - response = this.getText(url); - } - - if (response) { - response.then(function (r) { - var result = this.handleResponse(r, type); - deferred.resolve(result); - }.bind(this)); - } else { - deferred.reject({ - message: "File not found in the epub: " + url, - stack: new Error().stack - }); - } - return deferred.promise; - } - - /** - * Handle the response from request - * @private - * @param {any} response - * @param {string} [type] - * @return {any} the parsed result - */ - - }, { - key: "handleResponse", - value: function handleResponse(response, type) { - var r; - - if (type == "json") { - r = JSON.parse(response); - } else if ((0, _core.isXml)(type)) { - r = (0, _core.parse)(response, "text/xml"); - } else if (type == "xhtml") { - r = (0, _core.parse)(response, "application/xhtml+xml"); - } else if (type == "html" || type == "htm") { - r = (0, _core.parse)(response, "text/html"); - } else { - r = response; - } - - return r; - } - - /** - * Get a Blob from Archive by Url - * @param {string} url - * @param {string} [mimeType] - * @return {Blob} - */ - - }, { - key: "getBlob", - value: function getBlob(url, mimeType) { - var decodededUrl = window.decodeURIComponent(url.substr(1)); // Remove first slash - var entry = this.zip.file(decodededUrl); - - if (entry) { - mimeType = mimeType || _mime2.default.lookup(entry.name); - return entry.async("uint8array").then(function (uint8array) { - return new Blob([uint8array], { type: mimeType }); - }); - } - } - - /** - * Get Text from Archive by Url - * @param {string} url - * @param {string} [encoding] - * @return {string} - */ - - }, { - key: "getText", - value: function getText(url, encoding) { - var decodededUrl = window.decodeURIComponent(url.substr(1)); // Remove first slash - var entry = this.zip.file(decodededUrl); - - if (entry) { - return entry.async("string").then(function (text) { - return text; - }); - } - } - - /** - * Get a base64 encoded result from Archive by Url - * @param {string} url - * @param {string} [mimeType] - * @return {string} base64 encoded - */ - - }, { - key: "getBase64", - value: function getBase64(url, mimeType) { - var decodededUrl = window.decodeURIComponent(url.substr(1)); // Remove first slash - var entry = this.zip.file(decodededUrl); - - if (entry) { - mimeType = mimeType || _mime2.default.lookup(entry.name); - return entry.async("base64").then(function (data) { - return "data:" + mimeType + ";base64," + data; - }); - } - } - - /** - * Create a Url from an unarchived item - * @param {string} url - * @param {object} [options.base64] use base64 encoding or blob url - * @return {Promise} url promise with Url string - */ - - }, { - key: "createUrl", - value: function createUrl(url, options) { - var deferred = new _core.defer(); - var _URL = window.URL || window.webkitURL || window.mozURL; - var tempUrl; - var response; - var useBase64 = options && options.base64; - - if (url in this.urlCache) { - deferred.resolve(this.urlCache[url]); - return deferred.promise; - } - - if (useBase64) { - response = this.getBase64(url); - - if (response) { - response.then(function (tempUrl) { - - this.urlCache[url] = tempUrl; - deferred.resolve(tempUrl); - }.bind(this)); - } - } else { - - response = this.getBlob(url); - - if (response) { - response.then(function (blob) { - - tempUrl = _URL.createObjectURL(blob); - this.urlCache[url] = tempUrl; - deferred.resolve(tempUrl); - }.bind(this)); - } - } - - if (!response) { - deferred.reject({ - message: "File not found in the epub: " + url, - stack: new Error().stack - }); - } - - return deferred.promise; - } - - /** - * Revoke Temp Url for a achive item - * @param {string} url url of the item in the archive - */ - - }, { - key: "revokeUrl", - value: function revokeUrl(url) { - var _URL = window.URL || window.webkitURL || window.mozURL; - var fromCache = this.urlCache[url]; - if (fromCache) _URL.revokeObjectURL(fromCache); - } - }, { - key: "destroy", - value: function destroy() { - var _URL = window.URL || window.webkitURL || window.mozURL; - for (var fromCache in this.urlCache) { - _URL.revokeObjectURL(fromCache); - } - this.zip = undefined; - this.urlCache = {}; - } - }]); - - return Archive; -}(); - -exports.default = Archive; -module.exports = exports["default"]; - -/***/ }), -/* 72 */ -/***/ (function(module, exports) { - -if(typeof __WEBPACK_EXTERNAL_MODULE_72__ === 'undefined') {var e = new Error("Cannot find module \"jszip\""); e.code = 'MODULE_NOT_FOUND'; throw e;} -module.exports = __WEBPACK_EXTERNAL_MODULE_72__; - -/***/ }), -/* 73 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _core = __webpack_require__(0); - -var _request = __webpack_require__(9); - -var _request2 = _interopRequireDefault(_request); - -var _mime = __webpack_require__(13); - -var _mime2 = _interopRequireDefault(_mime); - -var _path = __webpack_require__(4); - -var _path2 = _interopRequireDefault(_path); - -var _eventEmitter = __webpack_require__(3); - -var _eventEmitter2 = _interopRequireDefault(_eventEmitter); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Handles saving and requesting files from local storage - * @class - * @param {string} name This should be the name of the application for modals - * @param {function} [requester] - * @param {function} [resolver] - */ -var Store = function () { - function Store(name, requester, resolver) { - _classCallCheck(this, Store); - - this.urlCache = {}; - - this.storage = undefined; - - this.name = name; - this.requester = requester || _request2.default; - this.resolver = resolver; - - this.online = true; - - this.checkRequirements(); - - this.addListeners(); - } - - /** - * Checks to see if localForage exists in global namspace, - * Requires localForage if it isn't there - * @private - */ - - - _createClass(Store, [{ - key: "checkRequirements", - value: function checkRequirements() { - try { - var store = void 0; - if (typeof localforage === "undefined") { - store = __webpack_require__(74); - } else { - store = localforage; - } - this.storage = store.createInstance({ - name: this.name - }); - } catch (e) { - throw new Error("localForage lib not loaded"); - } - } - - /** - * Add online and offline event listeners - * @private - */ - - }, { - key: "addListeners", - value: function addListeners() { - this._status = this.status.bind(this); - window.addEventListener('online', this._status); - window.addEventListener('offline', this._status); - } - - /** - * Remove online and offline event listeners - * @private - */ - - }, { - key: "removeListeners", - value: function removeListeners() { - window.removeEventListener('online', this._status); - window.removeEventListener('offline', this._status); - this._status = undefined; - } - - /** - * Update the online / offline status - * @private - */ - - }, { - key: "status", - value: function status(event) { - var online = navigator.onLine; - this.online = online; - if (online) { - this.emit("online", this); - } else { - this.emit("offline", this); - } - } - - /** - * Add all of a book resources to the store - * @param {Resources} resources book resources - * @param {boolean} [force] force resaving resources - * @return {Promise} store objects - */ - - }, { - key: "add", - value: function add(resources, force) { - var _this = this; - - var mapped = resources.resources.map(function (item) { - var href = item.href; - - var url = _this.resolver(href); - var encodedUrl = window.encodeURIComponent(url); - - return _this.storage.getItem(encodedUrl).then(function (item) { - if (!item || force) { - return _this.requester(url, "binary").then(function (data) { - return _this.storage.setItem(encodedUrl, data); - }); - } else { - return item; - } - }); - }); - return Promise.all(mapped); - } - - /** - * Put binary data from a url to storage - * @param {string} url a url to request from storage - * @param {boolean} [withCredentials] - * @param {object} [headers] - * @return {Promise} - */ - - }, { - key: "put", - value: function put(url, withCredentials, headers) { - var _this2 = this; - - var encodedUrl = window.encodeURIComponent(url); - - return this.storage.getItem(encodedUrl).then(function (result) { - if (!result) { - return _this2.requester(url, "binary", withCredentials, headers).then(function (data) { - return _this2.storage.setItem(encodedUrl, data); - }); - } - return result; - }); - } - - /** - * Request a url - * @param {string} url a url to request from storage - * @param {string} [type] specify the type of the returned result - * @param {boolean} [withCredentials] - * @param {object} [headers] - * @return {Promise} - */ - - }, { - key: "request", - value: function request(url, type, withCredentials, headers) { - var _this3 = this; - - if (this.online) { - // From network - return this.requester(url, type, withCredentials, headers).then(function (data) { - // save to store if not present - _this3.put(url); - return data; - }); - } else { - // From store - return this.retrieve(url, type); - } - } - - /** - * Request a url from storage - * @param {string} url a url to request from storage - * @param {string} [type] specify the type of the returned result - * @return {Promise} - */ - - }, { - key: "retrieve", - value: function retrieve(url, type) { - var _this4 = this; - - var deferred = new _core.defer(); - var response; - var path = new _path2.default(url); - - // If type isn't set, determine it from the file extension - if (!type) { - type = path.extension; - } - - if (type == "blob") { - response = this.getBlob(url); - } else { - response = this.getText(url); - } - - return response.then(function (r) { - var deferred = new _core.defer(); - var result; - if (r) { - result = _this4.handleResponse(r, type); - deferred.resolve(result); - } else { - deferred.reject({ - message: "File not found in storage: " + url, - stack: new Error().stack - }); - } - return deferred.promise; - }); - } - - /** - * Handle the response from request - * @private - * @param {any} response - * @param {string} [type] - * @return {any} the parsed result - */ - - }, { - key: "handleResponse", - value: function handleResponse(response, type) { - var r; - - if (type == "json") { - r = JSON.parse(response); - } else if ((0, _core.isXml)(type)) { - r = (0, _core.parse)(response, "text/xml"); - } else if (type == "xhtml") { - r = (0, _core.parse)(response, "application/xhtml+xml"); - } else if (type == "html" || type == "htm") { - r = (0, _core.parse)(response, "text/html"); - } else { - r = response; - } - - return r; - } - - /** - * Get a Blob from Storage by Url - * @param {string} url - * @param {string} [mimeType] - * @return {Blob} - */ - - }, { - key: "getBlob", - value: function getBlob(url, mimeType) { - var encodedUrl = window.encodeURIComponent(url); - - return this.storage.getItem(encodedUrl).then(function (uint8array) { - if (!uint8array) return; - - mimeType = mimeType || _mime2.default.lookup(url); - - return new Blob([uint8array], { type: mimeType }); - }); - } - - /** - * Get Text from Storage by Url - * @param {string} url - * @param {string} [mimeType] - * @return {string} - */ - - }, { - key: "getText", - value: function getText(url, mimeType) { - var encodedUrl = window.encodeURIComponent(url); - - mimeType = mimeType || _mime2.default.lookup(url); - - return this.storage.getItem(encodedUrl).then(function (uint8array) { - var deferred = new _core.defer(); - var reader = new FileReader(); - var blob; - - if (!uint8array) return; - - blob = new Blob([uint8array], { type: mimeType }); - - reader.addEventListener("loadend", function () { - deferred.resolve(reader.result); - }); - - reader.readAsText(blob, mimeType); - - return deferred.promise; - }); - } - - /** - * Get a base64 encoded result from Storage by Url - * @param {string} url - * @param {string} [mimeType] - * @return {string} base64 encoded - */ - - }, { - key: "getBase64", - value: function getBase64(url, mimeType) { - var encodedUrl = window.encodeURIComponent(url); - - mimeType = mimeType || _mime2.default.lookup(url); - - return this.storage.getItem(encodedUrl).then(function (uint8array) { - var deferred = new _core.defer(); - var reader = new FileReader(); - var blob; - - if (!uint8array) return; - - blob = new Blob([uint8array], { type: mimeType }); - - reader.addEventListener("loadend", function () { - deferred.resolve(reader.result); - }); - reader.readAsDataURL(blob, mimeType); - - return deferred.promise; - }); - } - - /** - * Create a Url from a stored item - * @param {string} url - * @param {object} [options.base64] use base64 encoding or blob url - * @return {Promise} url promise with Url string - */ - - }, { - key: "createUrl", - value: function createUrl(url, options) { - var deferred = new _core.defer(); - var _URL = window.URL || window.webkitURL || window.mozURL; - var tempUrl; - var response; - var useBase64 = options && options.base64; - - if (url in this.urlCache) { - deferred.resolve(this.urlCache[url]); - return deferred.promise; - } - - if (useBase64) { - response = this.getBase64(url); - - if (response) { - response.then(function (tempUrl) { - - this.urlCache[url] = tempUrl; - deferred.resolve(tempUrl); - }.bind(this)); - } - } else { - - response = this.getBlob(url); - - if (response) { - response.then(function (blob) { - - tempUrl = _URL.createObjectURL(blob); - this.urlCache[url] = tempUrl; - deferred.resolve(tempUrl); - }.bind(this)); - } - } - - if (!response) { - deferred.reject({ - message: "File not found in storage: " + url, - stack: new Error().stack - }); - } - - return deferred.promise; - } - - /** - * Revoke Temp Url for a achive item - * @param {string} url url of the item in the store - */ - - }, { - key: "revokeUrl", - value: function revokeUrl(url) { - var _URL = window.URL || window.webkitURL || window.mozURL; - var fromCache = this.urlCache[url]; - if (fromCache) _URL.revokeObjectURL(fromCache); - } - }, { - key: "destroy", - value: function destroy() { - var _URL = window.URL || window.webkitURL || window.mozURL; - for (var fromCache in this.urlCache) { - _URL.revokeObjectURL(fromCache); - } - this.urlCache = {}; - this.removeListeners(); - } - }]); - - return Store; -}(); - -(0, _eventEmitter2.default)(Store.prototype); - -exports.default = Store; -module.exports = exports["default"]; - -/***/ }), -/* 74 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(global) {var require;var require;/*! - localForage -- Offline Storage, Improved - Version 1.7.3 - https://localforage.github.io/localForage - (c) 2013-2017 Mozilla, Apache License 2.0 -*/ -(function(f){if(true){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.localforage = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw (f.code="MODULE_NOT_FOUND", f)}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o element; its readystatechange event will be fired asynchronously once it is inserted - // into the document. Do so, thus queuing up the task. Remember to clean up once it's been called. - var scriptEl = global.document.createElement('script'); - scriptEl.onreadystatechange = function () { - nextTick(); - - scriptEl.onreadystatechange = null; - scriptEl.parentNode.removeChild(scriptEl); - scriptEl = null; - }; - global.document.documentElement.appendChild(scriptEl); - }; - } else { - scheduleDrain = function () { - setTimeout(nextTick, 0); - }; - } -} - -var draining; -var queue = []; -//named nextTick for less confusing stack traces -function nextTick() { - draining = true; - var i, oldQueue; - var len = queue.length; - while (len) { - oldQueue = queue; - queue = []; - i = -1; - while (++i < len) { - oldQueue[i](); - } - len = queue.length; - } - draining = false; -} - -module.exports = immediate; -function immediate(task) { - if (queue.push(task) === 1 && !draining) { - scheduleDrain(); - } -} - -}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {}) -},{}],2:[function(_dereq_,module,exports){ -'use strict'; -var immediate = _dereq_(1); - -/* istanbul ignore next */ -function INTERNAL() {} - -var handlers = {}; - -var REJECTED = ['REJECTED']; -var FULFILLED = ['FULFILLED']; -var PENDING = ['PENDING']; - -module.exports = Promise; - -function Promise(resolver) { - if (typeof resolver !== 'function') { - throw new TypeError('resolver must be a function'); - } - this.state = PENDING; - this.queue = []; - this.outcome = void 0; - if (resolver !== INTERNAL) { - safelyResolveThenable(this, resolver); - } -} - -Promise.prototype["catch"] = function (onRejected) { - return this.then(null, onRejected); -}; -Promise.prototype.then = function (onFulfilled, onRejected) { - if (typeof onFulfilled !== 'function' && this.state === FULFILLED || - typeof onRejected !== 'function' && this.state === REJECTED) { - return this; - } - var promise = new this.constructor(INTERNAL); - if (this.state !== PENDING) { - var resolver = this.state === FULFILLED ? onFulfilled : onRejected; - unwrap(promise, resolver, this.outcome); - } else { - this.queue.push(new QueueItem(promise, onFulfilled, onRejected)); - } - - return promise; -}; -function QueueItem(promise, onFulfilled, onRejected) { - this.promise = promise; - if (typeof onFulfilled === 'function') { - this.onFulfilled = onFulfilled; - this.callFulfilled = this.otherCallFulfilled; - } - if (typeof onRejected === 'function') { - this.onRejected = onRejected; - this.callRejected = this.otherCallRejected; - } -} -QueueItem.prototype.callFulfilled = function (value) { - handlers.resolve(this.promise, value); -}; -QueueItem.prototype.otherCallFulfilled = function (value) { - unwrap(this.promise, this.onFulfilled, value); -}; -QueueItem.prototype.callRejected = function (value) { - handlers.reject(this.promise, value); -}; -QueueItem.prototype.otherCallRejected = function (value) { - unwrap(this.promise, this.onRejected, value); -}; - -function unwrap(promise, func, value) { - immediate(function () { - var returnValue; - try { - returnValue = func(value); - } catch (e) { - return handlers.reject(promise, e); - } - if (returnValue === promise) { - handlers.reject(promise, new TypeError('Cannot resolve promise with itself')); - } else { - handlers.resolve(promise, returnValue); - } - }); -} - -handlers.resolve = function (self, value) { - var result = tryCatch(getThen, value); - if (result.status === 'error') { - return handlers.reject(self, result.value); - } - var thenable = result.value; - - if (thenable) { - safelyResolveThenable(self, thenable); - } else { - self.state = FULFILLED; - self.outcome = value; - var i = -1; - var len = self.queue.length; - while (++i < len) { - self.queue[i].callFulfilled(value); - } - } - return self; -}; -handlers.reject = function (self, error) { - self.state = REJECTED; - self.outcome = error; - var i = -1; - var len = self.queue.length; - while (++i < len) { - self.queue[i].callRejected(error); - } - return self; -}; - -function getThen(obj) { - // Make sure we only access the accessor once as required by the spec - var then = obj && obj.then; - if (obj && (typeof obj === 'object' || typeof obj === 'function') && typeof then === 'function') { - return function appyThen() { - then.apply(obj, arguments); - }; - } -} - -function safelyResolveThenable(self, thenable) { - // Either fulfill, reject or reject with error - var called = false; - function onError(value) { - if (called) { - return; - } - called = true; - handlers.reject(self, value); - } - - function onSuccess(value) { - if (called) { - return; - } - called = true; - handlers.resolve(self, value); - } - - function tryToUnwrap() { - thenable(onSuccess, onError); - } - - var result = tryCatch(tryToUnwrap); - if (result.status === 'error') { - onError(result.value); - } -} - -function tryCatch(func, value) { - var out = {}; - try { - out.value = func(value); - out.status = 'success'; - } catch (e) { - out.status = 'error'; - out.value = e; - } - return out; -} - -Promise.resolve = resolve; -function resolve(value) { - if (value instanceof this) { - return value; - } - return handlers.resolve(new this(INTERNAL), value); -} - -Promise.reject = reject; -function reject(reason) { - var promise = new this(INTERNAL); - return handlers.reject(promise, reason); -} - -Promise.all = all; -function all(iterable) { - var self = this; - if (Object.prototype.toString.call(iterable) !== '[object Array]') { - return this.reject(new TypeError('must be an array')); - } - - var len = iterable.length; - var called = false; - if (!len) { - return this.resolve([]); - } - - var values = new Array(len); - var resolved = 0; - var i = -1; - var promise = new this(INTERNAL); - - while (++i < len) { - allResolver(iterable[i], i); - } - return promise; - function allResolver(value, i) { - self.resolve(value).then(resolveFromAll, function (error) { - if (!called) { - called = true; - handlers.reject(promise, error); - } - }); - function resolveFromAll(outValue) { - values[i] = outValue; - if (++resolved === len && !called) { - called = true; - handlers.resolve(promise, values); - } - } - } -} - -Promise.race = race; -function race(iterable) { - var self = this; - if (Object.prototype.toString.call(iterable) !== '[object Array]') { - return this.reject(new TypeError('must be an array')); - } - - var len = iterable.length; - var called = false; - if (!len) { - return this.resolve([]); - } - - var i = -1; - var promise = new this(INTERNAL); - - while (++i < len) { - resolver(iterable[i]); - } - return promise; - function resolver(value) { - self.resolve(value).then(function (response) { - if (!called) { - called = true; - handlers.resolve(promise, response); - } - }, function (error) { - if (!called) { - called = true; - handlers.reject(promise, error); - } - }); - } -} - -},{"1":1}],3:[function(_dereq_,module,exports){ -(function (global){ -'use strict'; -if (typeof global.Promise !== 'function') { - global.Promise = _dereq_(2); -} - -}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {}) -},{"2":2}],4:[function(_dereq_,module,exports){ -'use strict'; - -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function getIDB() { - /* global indexedDB,webkitIndexedDB,mozIndexedDB,OIndexedDB,msIndexedDB */ - try { - if (typeof indexedDB !== 'undefined') { - return indexedDB; - } - if (typeof webkitIndexedDB !== 'undefined') { - return webkitIndexedDB; - } - if (typeof mozIndexedDB !== 'undefined') { - return mozIndexedDB; - } - if (typeof OIndexedDB !== 'undefined') { - return OIndexedDB; - } - if (typeof msIndexedDB !== 'undefined') { - return msIndexedDB; - } - } catch (e) { - return; - } -} - -var idb = getIDB(); - -function isIndexedDBValid() { - try { - // Initialize IndexedDB; fall back to vendor-prefixed versions - // if needed. - if (!idb) { - return false; - } - // We mimic PouchDB here; - // - // We test for openDatabase because IE Mobile identifies itself - // as Safari. Oh the lulz... - var isSafari = typeof openDatabase !== 'undefined' && /(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent) && !/Chrome/.test(navigator.userAgent) && !/BlackBerry/.test(navigator.platform); - - var hasFetch = typeof fetch === 'function' && fetch.toString().indexOf('[native code') !== -1; - - // Safari <10.1 does not meet our requirements for IDB support (#5572) - // since Safari 10.1 shipped with fetch, we can use that to detect it - return (!isSafari || hasFetch) && typeof indexedDB !== 'undefined' && - // some outdated implementations of IDB that appear on Samsung - // and HTC Android devices <4.4 are missing IDBKeyRange - // See: https://github.com/mozilla/localForage/issues/128 - // See: https://github.com/mozilla/localForage/issues/272 - typeof IDBKeyRange !== 'undefined'; - } catch (e) { - return false; - } -} - -// Abstracts constructing a Blob object, so it also works in older -// browsers that don't support the native Blob constructor. (i.e. -// old QtWebKit versions, at least). -// Abstracts constructing a Blob object, so it also works in older -// browsers that don't support the native Blob constructor. (i.e. -// old QtWebKit versions, at least). -function createBlob(parts, properties) { - /* global BlobBuilder,MSBlobBuilder,MozBlobBuilder,WebKitBlobBuilder */ - parts = parts || []; - properties = properties || {}; - try { - return new Blob(parts, properties); - } catch (e) { - if (e.name !== 'TypeError') { - throw e; - } - var Builder = typeof BlobBuilder !== 'undefined' ? BlobBuilder : typeof MSBlobBuilder !== 'undefined' ? MSBlobBuilder : typeof MozBlobBuilder !== 'undefined' ? MozBlobBuilder : WebKitBlobBuilder; - var builder = new Builder(); - for (var i = 0; i < parts.length; i += 1) { - builder.append(parts[i]); - } - return builder.getBlob(properties.type); - } -} - -// This is CommonJS because lie is an external dependency, so Rollup -// can just ignore it. -if (typeof Promise === 'undefined') { - // In the "nopromises" build this will just throw if you don't have - // a global promise object, but it would throw anyway later. - _dereq_(3); -} -var Promise$1 = Promise; - -function executeCallback(promise, callback) { - if (callback) { - promise.then(function (result) { - callback(null, result); - }, function (error) { - callback(error); - }); - } -} - -function executeTwoCallbacks(promise, callback, errorCallback) { - if (typeof callback === 'function') { - promise.then(callback); - } - - if (typeof errorCallback === 'function') { - promise["catch"](errorCallback); - } -} - -function normalizeKey(key) { - // Cast the key to a string, as that's all we can set as a key. - if (typeof key !== 'string') { - console.warn(key + ' used as a key, but it is not a string.'); - key = String(key); - } - - return key; -} - -function getCallback() { - if (arguments.length && typeof arguments[arguments.length - 1] === 'function') { - return arguments[arguments.length - 1]; - } -} - -// Some code originally from async_storage.js in -// [Gaia](https://github.com/mozilla-b2g/gaia). - -var DETECT_BLOB_SUPPORT_STORE = 'local-forage-detect-blob-support'; -var supportsBlobs = void 0; -var dbContexts = {}; -var toString = Object.prototype.toString; - -// Transaction Modes -var READ_ONLY = 'readonly'; -var READ_WRITE = 'readwrite'; - -// Transform a binary string to an array buffer, because otherwise -// weird stuff happens when you try to work with the binary string directly. -// It is known. -// From http://stackoverflow.com/questions/14967647/ (continues on next line) -// encode-decode-image-with-base64-breaks-image (2013-04-21) -function _binStringToArrayBuffer(bin) { - var length = bin.length; - var buf = new ArrayBuffer(length); - var arr = new Uint8Array(buf); - for (var i = 0; i < length; i++) { - arr[i] = bin.charCodeAt(i); - } - return buf; -} - -// -// Blobs are not supported in all versions of IndexedDB, notably -// Chrome <37 and Android <5. In those versions, storing a blob will throw. -// -// Various other blob bugs exist in Chrome v37-42 (inclusive). -// Detecting them is expensive and confusing to users, and Chrome 37-42 -// is at very low usage worldwide, so we do a hacky userAgent check instead. -// -// content-type bug: https://code.google.com/p/chromium/issues/detail?id=408120 -// 404 bug: https://code.google.com/p/chromium/issues/detail?id=447916 -// FileReader bug: https://code.google.com/p/chromium/issues/detail?id=447836 -// -// Code borrowed from PouchDB. See: -// https://github.com/pouchdb/pouchdb/blob/master/packages/node_modules/pouchdb-adapter-idb/src/blobSupport.js -// -function _checkBlobSupportWithoutCaching(idb) { - return new Promise$1(function (resolve) { - var txn = idb.transaction(DETECT_BLOB_SUPPORT_STORE, READ_WRITE); - var blob = createBlob(['']); - txn.objectStore(DETECT_BLOB_SUPPORT_STORE).put(blob, 'key'); - - txn.onabort = function (e) { - // If the transaction aborts now its due to not being able to - // write to the database, likely due to the disk being full - e.preventDefault(); - e.stopPropagation(); - resolve(false); - }; - - txn.oncomplete = function () { - var matchedChrome = navigator.userAgent.match(/Chrome\/(\d+)/); - var matchedEdge = navigator.userAgent.match(/Edge\//); - // MS Edge pretends to be Chrome 42: - // https://msdn.microsoft.com/en-us/library/hh869301%28v=vs.85%29.aspx - resolve(matchedEdge || !matchedChrome || parseInt(matchedChrome[1], 10) >= 43); - }; - })["catch"](function () { - return false; // error, so assume unsupported - }); -} - -function _checkBlobSupport(idb) { - if (typeof supportsBlobs === 'boolean') { - return Promise$1.resolve(supportsBlobs); - } - return _checkBlobSupportWithoutCaching(idb).then(function (value) { - supportsBlobs = value; - return supportsBlobs; - }); -} - -function _deferReadiness(dbInfo) { - var dbContext = dbContexts[dbInfo.name]; - - // Create a deferred object representing the current database operation. - var deferredOperation = {}; - - deferredOperation.promise = new Promise$1(function (resolve, reject) { - deferredOperation.resolve = resolve; - deferredOperation.reject = reject; - }); - - // Enqueue the deferred operation. - dbContext.deferredOperations.push(deferredOperation); - - // Chain its promise to the database readiness. - if (!dbContext.dbReady) { - dbContext.dbReady = deferredOperation.promise; - } else { - dbContext.dbReady = dbContext.dbReady.then(function () { - return deferredOperation.promise; - }); - } -} - -function _advanceReadiness(dbInfo) { - var dbContext = dbContexts[dbInfo.name]; - - // Dequeue a deferred operation. - var deferredOperation = dbContext.deferredOperations.pop(); - - // Resolve its promise (which is part of the database readiness - // chain of promises). - if (deferredOperation) { - deferredOperation.resolve(); - return deferredOperation.promise; - } -} - -function _rejectReadiness(dbInfo, err) { - var dbContext = dbContexts[dbInfo.name]; - - // Dequeue a deferred operation. - var deferredOperation = dbContext.deferredOperations.pop(); - - // Reject its promise (which is part of the database readiness - // chain of promises). - if (deferredOperation) { - deferredOperation.reject(err); - return deferredOperation.promise; - } -} - -function _getConnection(dbInfo, upgradeNeeded) { - return new Promise$1(function (resolve, reject) { - dbContexts[dbInfo.name] = dbContexts[dbInfo.name] || createDbContext(); - - if (dbInfo.db) { - if (upgradeNeeded) { - _deferReadiness(dbInfo); - dbInfo.db.close(); - } else { - return resolve(dbInfo.db); - } - } - - var dbArgs = [dbInfo.name]; - - if (upgradeNeeded) { - dbArgs.push(dbInfo.version); - } - - var openreq = idb.open.apply(idb, dbArgs); - - if (upgradeNeeded) { - openreq.onupgradeneeded = function (e) { - var db = openreq.result; - try { - db.createObjectStore(dbInfo.storeName); - if (e.oldVersion <= 1) { - // Added when support for blob shims was added - db.createObjectStore(DETECT_BLOB_SUPPORT_STORE); - } - } catch (ex) { - if (ex.name === 'ConstraintError') { - console.warn('The database "' + dbInfo.name + '"' + ' has been upgraded from version ' + e.oldVersion + ' to version ' + e.newVersion + ', but the storage "' + dbInfo.storeName + '" already exists.'); - } else { - throw ex; - } - } - }; - } - - openreq.onerror = function (e) { - e.preventDefault(); - reject(openreq.error); - }; - - openreq.onsuccess = function () { - resolve(openreq.result); - _advanceReadiness(dbInfo); - }; - }); -} - -function _getOriginalConnection(dbInfo) { - return _getConnection(dbInfo, false); -} - -function _getUpgradedConnection(dbInfo) { - return _getConnection(dbInfo, true); -} - -function _isUpgradeNeeded(dbInfo, defaultVersion) { - if (!dbInfo.db) { - return true; - } - - var isNewStore = !dbInfo.db.objectStoreNames.contains(dbInfo.storeName); - var isDowngrade = dbInfo.version < dbInfo.db.version; - var isUpgrade = dbInfo.version > dbInfo.db.version; - - if (isDowngrade) { - // If the version is not the default one - // then warn for impossible downgrade. - if (dbInfo.version !== defaultVersion) { - console.warn('The database "' + dbInfo.name + '"' + " can't be downgraded from version " + dbInfo.db.version + ' to version ' + dbInfo.version + '.'); - } - // Align the versions to prevent errors. - dbInfo.version = dbInfo.db.version; - } - - if (isUpgrade || isNewStore) { - // If the store is new then increment the version (if needed). - // This will trigger an "upgradeneeded" event which is required - // for creating a store. - if (isNewStore) { - var incVersion = dbInfo.db.version + 1; - if (incVersion > dbInfo.version) { - dbInfo.version = incVersion; - } - } - - return true; - } - - return false; -} - -// encode a blob for indexeddb engines that don't support blobs -function _encodeBlob(blob) { - return new Promise$1(function (resolve, reject) { - var reader = new FileReader(); - reader.onerror = reject; - reader.onloadend = function (e) { - var base64 = btoa(e.target.result || ''); - resolve({ - __local_forage_encoded_blob: true, - data: base64, - type: blob.type - }); - }; - reader.readAsBinaryString(blob); - }); -} - -// decode an encoded blob -function _decodeBlob(encodedBlob) { - var arrayBuff = _binStringToArrayBuffer(atob(encodedBlob.data)); - return createBlob([arrayBuff], { type: encodedBlob.type }); -} - -// is this one of our fancy encoded blobs? -function _isEncodedBlob(value) { - return value && value.__local_forage_encoded_blob; -} - -// Specialize the default `ready()` function by making it dependent -// on the current database operations. Thus, the driver will be actually -// ready when it's been initialized (default) *and* there are no pending -// operations on the database (initiated by some other instances). -function _fullyReady(callback) { - var self = this; - - var promise = self._initReady().then(function () { - var dbContext = dbContexts[self._dbInfo.name]; - - if (dbContext && dbContext.dbReady) { - return dbContext.dbReady; - } - }); - - executeTwoCallbacks(promise, callback, callback); - return promise; -} - -// Try to establish a new db connection to replace the -// current one which is broken (i.e. experiencing -// InvalidStateError while creating a transaction). -function _tryReconnect(dbInfo) { - _deferReadiness(dbInfo); - - var dbContext = dbContexts[dbInfo.name]; - var forages = dbContext.forages; - - for (var i = 0; i < forages.length; i++) { - var forage = forages[i]; - if (forage._dbInfo.db) { - forage._dbInfo.db.close(); - forage._dbInfo.db = null; - } - } - dbInfo.db = null; - - return _getOriginalConnection(dbInfo).then(function (db) { - dbInfo.db = db; - if (_isUpgradeNeeded(dbInfo)) { - // Reopen the database for upgrading. - return _getUpgradedConnection(dbInfo); - } - return db; - }).then(function (db) { - // store the latest db reference - // in case the db was upgraded - dbInfo.db = dbContext.db = db; - for (var i = 0; i < forages.length; i++) { - forages[i]._dbInfo.db = db; - } - })["catch"](function (err) { - _rejectReadiness(dbInfo, err); - throw err; - }); -} - -// FF doesn't like Promises (micro-tasks) and IDDB store operations, -// so we have to do it with callbacks -function createTransaction(dbInfo, mode, callback, retries) { - if (retries === undefined) { - retries = 1; - } - - try { - var tx = dbInfo.db.transaction(dbInfo.storeName, mode); - callback(null, tx); - } catch (err) { - if (retries > 0 && (!dbInfo.db || err.name === 'InvalidStateError' || err.name === 'NotFoundError')) { - return Promise$1.resolve().then(function () { - if (!dbInfo.db || err.name === 'NotFoundError' && !dbInfo.db.objectStoreNames.contains(dbInfo.storeName) && dbInfo.version <= dbInfo.db.version) { - // increase the db version, to create the new ObjectStore - if (dbInfo.db) { - dbInfo.version = dbInfo.db.version + 1; - } - // Reopen the database for upgrading. - return _getUpgradedConnection(dbInfo); - } - }).then(function () { - return _tryReconnect(dbInfo).then(function () { - createTransaction(dbInfo, mode, callback, retries - 1); - }); - })["catch"](callback); - } - - callback(err); - } -} - -function createDbContext() { - return { - // Running localForages sharing a database. - forages: [], - // Shared database. - db: null, - // Database readiness (promise). - dbReady: null, - // Deferred operations on the database. - deferredOperations: [] - }; -} - -// Open the IndexedDB database (automatically creates one if one didn't -// previously exist), using any options set in the config. -function _initStorage(options) { - var self = this; - var dbInfo = { - db: null - }; - - if (options) { - for (var i in options) { - dbInfo[i] = options[i]; - } - } - - // Get the current context of the database; - var dbContext = dbContexts[dbInfo.name]; - - // ...or create a new context. - if (!dbContext) { - dbContext = createDbContext(); - // Register the new context in the global container. - dbContexts[dbInfo.name] = dbContext; - } - - // Register itself as a running localForage in the current context. - dbContext.forages.push(self); - - // Replace the default `ready()` function with the specialized one. - if (!self._initReady) { - self._initReady = self.ready; - self.ready = _fullyReady; - } - - // Create an array of initialization states of the related localForages. - var initPromises = []; - - function ignoreErrors() { - // Don't handle errors here, - // just makes sure related localForages aren't pending. - return Promise$1.resolve(); - } - - for (var j = 0; j < dbContext.forages.length; j++) { - var forage = dbContext.forages[j]; - if (forage !== self) { - // Don't wait for itself... - initPromises.push(forage._initReady()["catch"](ignoreErrors)); - } - } - - // Take a snapshot of the related localForages. - var forages = dbContext.forages.slice(0); - - // Initialize the connection process only when - // all the related localForages aren't pending. - return Promise$1.all(initPromises).then(function () { - dbInfo.db = dbContext.db; - // Get the connection or open a new one without upgrade. - return _getOriginalConnection(dbInfo); - }).then(function (db) { - dbInfo.db = db; - if (_isUpgradeNeeded(dbInfo, self._defaultConfig.version)) { - // Reopen the database for upgrading. - return _getUpgradedConnection(dbInfo); - } - return db; - }).then(function (db) { - dbInfo.db = dbContext.db = db; - self._dbInfo = dbInfo; - // Share the final connection amongst related localForages. - for (var k = 0; k < forages.length; k++) { - var forage = forages[k]; - if (forage !== self) { - // Self is already up-to-date. - forage._dbInfo.db = dbInfo.db; - forage._dbInfo.version = dbInfo.version; - } - } - }); -} - -function getItem(key, callback) { - var self = this; - - key = normalizeKey(key); - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - createTransaction(self._dbInfo, READ_ONLY, function (err, transaction) { - if (err) { - return reject(err); - } - - try { - var store = transaction.objectStore(self._dbInfo.storeName); - var req = store.get(key); - - req.onsuccess = function () { - var value = req.result; - if (value === undefined) { - value = null; - } - if (_isEncodedBlob(value)) { - value = _decodeBlob(value); - } - resolve(value); - }; - - req.onerror = function () { - reject(req.error); - }; - } catch (e) { - reject(e); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -// Iterate over all items stored in database. -function iterate(iterator, callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - createTransaction(self._dbInfo, READ_ONLY, function (err, transaction) { - if (err) { - return reject(err); - } - - try { - var store = transaction.objectStore(self._dbInfo.storeName); - var req = store.openCursor(); - var iterationNumber = 1; - - req.onsuccess = function () { - var cursor = req.result; - - if (cursor) { - var value = cursor.value; - if (_isEncodedBlob(value)) { - value = _decodeBlob(value); - } - var result = iterator(value, cursor.key, iterationNumber++); - - // when the iterator callback retuns any - // (non-`undefined`) value, then we stop - // the iteration immediately - if (result !== void 0) { - resolve(result); - } else { - cursor["continue"](); - } - } else { - resolve(); - } - }; - - req.onerror = function () { - reject(req.error); - }; - } catch (e) { - reject(e); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - - return promise; -} - -function setItem(key, value, callback) { - var self = this; - - key = normalizeKey(key); - - var promise = new Promise$1(function (resolve, reject) { - var dbInfo; - self.ready().then(function () { - dbInfo = self._dbInfo; - if (toString.call(value) === '[object Blob]') { - return _checkBlobSupport(dbInfo.db).then(function (blobSupport) { - if (blobSupport) { - return value; - } - return _encodeBlob(value); - }); - } - return value; - }).then(function (value) { - createTransaction(self._dbInfo, READ_WRITE, function (err, transaction) { - if (err) { - return reject(err); - } - - try { - var store = transaction.objectStore(self._dbInfo.storeName); - - // The reason we don't _save_ null is because IE 10 does - // not support saving the `null` type in IndexedDB. How - // ironic, given the bug below! - // See: https://github.com/mozilla/localForage/issues/161 - if (value === null) { - value = undefined; - } - - var req = store.put(value, key); - - transaction.oncomplete = function () { - // Cast to undefined so the value passed to - // callback/promise is the same as what one would get out - // of `getItem()` later. This leads to some weirdness - // (setItem('foo', undefined) will return `null`), but - // it's not my fault localStorage is our baseline and that - // it's weird. - if (value === undefined) { - value = null; - } - - resolve(value); - }; - transaction.onabort = transaction.onerror = function () { - var err = req.error ? req.error : req.transaction.error; - reject(err); - }; - } catch (e) { - reject(e); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function removeItem(key, callback) { - var self = this; - - key = normalizeKey(key); - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - createTransaction(self._dbInfo, READ_WRITE, function (err, transaction) { - if (err) { - return reject(err); - } - - try { - var store = transaction.objectStore(self._dbInfo.storeName); - // We use a Grunt task to make this safe for IE and some - // versions of Android (including those used by Cordova). - // Normally IE won't like `.delete()` and will insist on - // using `['delete']()`, but we have a build step that - // fixes this for us now. - var req = store["delete"](key); - transaction.oncomplete = function () { - resolve(); - }; - - transaction.onerror = function () { - reject(req.error); - }; - - // The request will be also be aborted if we've exceeded our storage - // space. - transaction.onabort = function () { - var err = req.error ? req.error : req.transaction.error; - reject(err); - }; - } catch (e) { - reject(e); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function clear(callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - createTransaction(self._dbInfo, READ_WRITE, function (err, transaction) { - if (err) { - return reject(err); - } - - try { - var store = transaction.objectStore(self._dbInfo.storeName); - var req = store.clear(); - - transaction.oncomplete = function () { - resolve(); - }; - - transaction.onabort = transaction.onerror = function () { - var err = req.error ? req.error : req.transaction.error; - reject(err); - }; - } catch (e) { - reject(e); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function length(callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - createTransaction(self._dbInfo, READ_ONLY, function (err, transaction) { - if (err) { - return reject(err); - } - - try { - var store = transaction.objectStore(self._dbInfo.storeName); - var req = store.count(); - - req.onsuccess = function () { - resolve(req.result); - }; - - req.onerror = function () { - reject(req.error); - }; - } catch (e) { - reject(e); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function key(n, callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - if (n < 0) { - resolve(null); - - return; - } - - self.ready().then(function () { - createTransaction(self._dbInfo, READ_ONLY, function (err, transaction) { - if (err) { - return reject(err); - } - - try { - var store = transaction.objectStore(self._dbInfo.storeName); - var advanced = false; - var req = store.openCursor(); - - req.onsuccess = function () { - var cursor = req.result; - if (!cursor) { - // this means there weren't enough keys - resolve(null); - - return; - } - - if (n === 0) { - // We have the first key, return it if that's what they - // wanted. - resolve(cursor.key); - } else { - if (!advanced) { - // Otherwise, ask the cursor to skip ahead n - // records. - advanced = true; - cursor.advance(n); - } else { - // When we get here, we've got the nth key. - resolve(cursor.key); - } - } - }; - - req.onerror = function () { - reject(req.error); - }; - } catch (e) { - reject(e); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function keys(callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - createTransaction(self._dbInfo, READ_ONLY, function (err, transaction) { - if (err) { - return reject(err); - } - - try { - var store = transaction.objectStore(self._dbInfo.storeName); - var req = store.openCursor(); - var keys = []; - - req.onsuccess = function () { - var cursor = req.result; - - if (!cursor) { - resolve(keys); - return; - } - - keys.push(cursor.key); - cursor["continue"](); - }; - - req.onerror = function () { - reject(req.error); - }; - } catch (e) { - reject(e); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function dropInstance(options, callback) { - callback = getCallback.apply(this, arguments); - - var currentConfig = this.config(); - options = typeof options !== 'function' && options || {}; - if (!options.name) { - options.name = options.name || currentConfig.name; - options.storeName = options.storeName || currentConfig.storeName; - } - - var self = this; - var promise; - if (!options.name) { - promise = Promise$1.reject('Invalid arguments'); - } else { - var isCurrentDb = options.name === currentConfig.name && self._dbInfo.db; - - var dbPromise = isCurrentDb ? Promise$1.resolve(self._dbInfo.db) : _getOriginalConnection(options).then(function (db) { - var dbContext = dbContexts[options.name]; - var forages = dbContext.forages; - dbContext.db = db; - for (var i = 0; i < forages.length; i++) { - forages[i]._dbInfo.db = db; - } - return db; - }); - - if (!options.storeName) { - promise = dbPromise.then(function (db) { - _deferReadiness(options); - - var dbContext = dbContexts[options.name]; - var forages = dbContext.forages; - - db.close(); - for (var i = 0; i < forages.length; i++) { - var forage = forages[i]; - forage._dbInfo.db = null; - } - - var dropDBPromise = new Promise$1(function (resolve, reject) { - var req = idb.deleteDatabase(options.name); - - req.onerror = req.onblocked = function (err) { - var db = req.result; - if (db) { - db.close(); - } - reject(err); - }; - - req.onsuccess = function () { - var db = req.result; - if (db) { - db.close(); - } - resolve(db); - }; - }); - - return dropDBPromise.then(function (db) { - dbContext.db = db; - for (var i = 0; i < forages.length; i++) { - var _forage = forages[i]; - _advanceReadiness(_forage._dbInfo); - } - })["catch"](function (err) { - (_rejectReadiness(options, err) || Promise$1.resolve())["catch"](function () {}); - throw err; - }); - }); - } else { - promise = dbPromise.then(function (db) { - if (!db.objectStoreNames.contains(options.storeName)) { - return; - } - - var newVersion = db.version + 1; - - _deferReadiness(options); - - var dbContext = dbContexts[options.name]; - var forages = dbContext.forages; - - db.close(); - for (var i = 0; i < forages.length; i++) { - var forage = forages[i]; - forage._dbInfo.db = null; - forage._dbInfo.version = newVersion; - } - - var dropObjectPromise = new Promise$1(function (resolve, reject) { - var req = idb.open(options.name, newVersion); - - req.onerror = function (err) { - var db = req.result; - db.close(); - reject(err); - }; - - req.onupgradeneeded = function () { - var db = req.result; - db.deleteObjectStore(options.storeName); - }; - - req.onsuccess = function () { - var db = req.result; - db.close(); - resolve(db); - }; - }); - - return dropObjectPromise.then(function (db) { - dbContext.db = db; - for (var j = 0; j < forages.length; j++) { - var _forage2 = forages[j]; - _forage2._dbInfo.db = db; - _advanceReadiness(_forage2._dbInfo); - } - })["catch"](function (err) { - (_rejectReadiness(options, err) || Promise$1.resolve())["catch"](function () {}); - throw err; - }); - }); - } - } - - executeCallback(promise, callback); - return promise; -} - -var asyncStorage = { - _driver: 'asyncStorage', - _initStorage: _initStorage, - _support: isIndexedDBValid(), - iterate: iterate, - getItem: getItem, - setItem: setItem, - removeItem: removeItem, - clear: clear, - length: length, - key: key, - keys: keys, - dropInstance: dropInstance -}; - -function isWebSQLValid() { - return typeof openDatabase === 'function'; -} - -// Sadly, the best way to save binary data in WebSQL/localStorage is serializing -// it to Base64, so this is how we store it to prevent very strange errors with less -// verbose ways of binary <-> string data storage. -var BASE_CHARS = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'; - -var BLOB_TYPE_PREFIX = '~~local_forage_type~'; -var BLOB_TYPE_PREFIX_REGEX = /^~~local_forage_type~([^~]+)~/; - -var SERIALIZED_MARKER = '__lfsc__:'; -var SERIALIZED_MARKER_LENGTH = SERIALIZED_MARKER.length; - -// OMG the serializations! -var TYPE_ARRAYBUFFER = 'arbf'; -var TYPE_BLOB = 'blob'; -var TYPE_INT8ARRAY = 'si08'; -var TYPE_UINT8ARRAY = 'ui08'; -var TYPE_UINT8CLAMPEDARRAY = 'uic8'; -var TYPE_INT16ARRAY = 'si16'; -var TYPE_INT32ARRAY = 'si32'; -var TYPE_UINT16ARRAY = 'ur16'; -var TYPE_UINT32ARRAY = 'ui32'; -var TYPE_FLOAT32ARRAY = 'fl32'; -var TYPE_FLOAT64ARRAY = 'fl64'; -var TYPE_SERIALIZED_MARKER_LENGTH = SERIALIZED_MARKER_LENGTH + TYPE_ARRAYBUFFER.length; - -var toString$1 = Object.prototype.toString; - -function stringToBuffer(serializedString) { - // Fill the string into a ArrayBuffer. - var bufferLength = serializedString.length * 0.75; - var len = serializedString.length; - var i; - var p = 0; - var encoded1, encoded2, encoded3, encoded4; - - if (serializedString[serializedString.length - 1] === '=') { - bufferLength--; - if (serializedString[serializedString.length - 2] === '=') { - bufferLength--; - } - } - - var buffer = new ArrayBuffer(bufferLength); - var bytes = new Uint8Array(buffer); - - for (i = 0; i < len; i += 4) { - encoded1 = BASE_CHARS.indexOf(serializedString[i]); - encoded2 = BASE_CHARS.indexOf(serializedString[i + 1]); - encoded3 = BASE_CHARS.indexOf(serializedString[i + 2]); - encoded4 = BASE_CHARS.indexOf(serializedString[i + 3]); - - /*jslint bitwise: true */ - bytes[p++] = encoded1 << 2 | encoded2 >> 4; - bytes[p++] = (encoded2 & 15) << 4 | encoded3 >> 2; - bytes[p++] = (encoded3 & 3) << 6 | encoded4 & 63; - } - return buffer; -} - -// Converts a buffer to a string to store, serialized, in the backend -// storage library. -function bufferToString(buffer) { - // base64-arraybuffer - var bytes = new Uint8Array(buffer); - var base64String = ''; - var i; - - for (i = 0; i < bytes.length; i += 3) { - /*jslint bitwise: true */ - base64String += BASE_CHARS[bytes[i] >> 2]; - base64String += BASE_CHARS[(bytes[i] & 3) << 4 | bytes[i + 1] >> 4]; - base64String += BASE_CHARS[(bytes[i + 1] & 15) << 2 | bytes[i + 2] >> 6]; - base64String += BASE_CHARS[bytes[i + 2] & 63]; - } - - if (bytes.length % 3 === 2) { - base64String = base64String.substring(0, base64String.length - 1) + '='; - } else if (bytes.length % 3 === 1) { - base64String = base64String.substring(0, base64String.length - 2) + '=='; - } - - return base64String; -} - -// Serialize a value, afterwards executing a callback (which usually -// instructs the `setItem()` callback/promise to be executed). This is how -// we store binary data with localStorage. -function serialize(value, callback) { - var valueType = ''; - if (value) { - valueType = toString$1.call(value); - } - - // Cannot use `value instanceof ArrayBuffer` or such here, as these - // checks fail when running the tests using casper.js... - // - // TODO: See why those tests fail and use a better solution. - if (value && (valueType === '[object ArrayBuffer]' || value.buffer && toString$1.call(value.buffer) === '[object ArrayBuffer]')) { - // Convert binary arrays to a string and prefix the string with - // a special marker. - var buffer; - var marker = SERIALIZED_MARKER; - - if (value instanceof ArrayBuffer) { - buffer = value; - marker += TYPE_ARRAYBUFFER; - } else { - buffer = value.buffer; - - if (valueType === '[object Int8Array]') { - marker += TYPE_INT8ARRAY; - } else if (valueType === '[object Uint8Array]') { - marker += TYPE_UINT8ARRAY; - } else if (valueType === '[object Uint8ClampedArray]') { - marker += TYPE_UINT8CLAMPEDARRAY; - } else if (valueType === '[object Int16Array]') { - marker += TYPE_INT16ARRAY; - } else if (valueType === '[object Uint16Array]') { - marker += TYPE_UINT16ARRAY; - } else if (valueType === '[object Int32Array]') { - marker += TYPE_INT32ARRAY; - } else if (valueType === '[object Uint32Array]') { - marker += TYPE_UINT32ARRAY; - } else if (valueType === '[object Float32Array]') { - marker += TYPE_FLOAT32ARRAY; - } else if (valueType === '[object Float64Array]') { - marker += TYPE_FLOAT64ARRAY; - } else { - callback(new Error('Failed to get type for BinaryArray')); - } - } - - callback(marker + bufferToString(buffer)); - } else if (valueType === '[object Blob]') { - // Conver the blob to a binaryArray and then to a string. - var fileReader = new FileReader(); - - fileReader.onload = function () { - // Backwards-compatible prefix for the blob type. - var str = BLOB_TYPE_PREFIX + value.type + '~' + bufferToString(this.result); - - callback(SERIALIZED_MARKER + TYPE_BLOB + str); - }; - - fileReader.readAsArrayBuffer(value); - } else { - try { - callback(JSON.stringify(value)); - } catch (e) { - console.error("Couldn't convert value into a JSON string: ", value); - - callback(null, e); - } - } -} - -// Deserialize data we've inserted into a value column/field. We place -// special markers into our strings to mark them as encoded; this isn't -// as nice as a meta field, but it's the only sane thing we can do whilst -// keeping localStorage support intact. -// -// Oftentimes this will just deserialize JSON content, but if we have a -// special marker (SERIALIZED_MARKER, defined above), we will extract -// some kind of arraybuffer/binary data/typed array out of the string. -function deserialize(value) { - // If we haven't marked this string as being specially serialized (i.e. - // something other than serialized JSON), we can just return it and be - // done with it. - if (value.substring(0, SERIALIZED_MARKER_LENGTH) !== SERIALIZED_MARKER) { - return JSON.parse(value); - } - - // The following code deals with deserializing some kind of Blob or - // TypedArray. First we separate out the type of data we're dealing - // with from the data itself. - var serializedString = value.substring(TYPE_SERIALIZED_MARKER_LENGTH); - var type = value.substring(SERIALIZED_MARKER_LENGTH, TYPE_SERIALIZED_MARKER_LENGTH); - - var blobType; - // Backwards-compatible blob type serialization strategy. - // DBs created with older versions of localForage will simply not have the blob type. - if (type === TYPE_BLOB && BLOB_TYPE_PREFIX_REGEX.test(serializedString)) { - var matcher = serializedString.match(BLOB_TYPE_PREFIX_REGEX); - blobType = matcher[1]; - serializedString = serializedString.substring(matcher[0].length); - } - var buffer = stringToBuffer(serializedString); - - // Return the right type based on the code/type set during - // serialization. - switch (type) { - case TYPE_ARRAYBUFFER: - return buffer; - case TYPE_BLOB: - return createBlob([buffer], { type: blobType }); - case TYPE_INT8ARRAY: - return new Int8Array(buffer); - case TYPE_UINT8ARRAY: - return new Uint8Array(buffer); - case TYPE_UINT8CLAMPEDARRAY: - return new Uint8ClampedArray(buffer); - case TYPE_INT16ARRAY: - return new Int16Array(buffer); - case TYPE_UINT16ARRAY: - return new Uint16Array(buffer); - case TYPE_INT32ARRAY: - return new Int32Array(buffer); - case TYPE_UINT32ARRAY: - return new Uint32Array(buffer); - case TYPE_FLOAT32ARRAY: - return new Float32Array(buffer); - case TYPE_FLOAT64ARRAY: - return new Float64Array(buffer); - default: - throw new Error('Unkown type: ' + type); - } -} - -var localforageSerializer = { - serialize: serialize, - deserialize: deserialize, - stringToBuffer: stringToBuffer, - bufferToString: bufferToString -}; - -/* - * Includes code from: - * - * base64-arraybuffer - * https://github.com/niklasvh/base64-arraybuffer - * - * Copyright (c) 2012 Niklas von Hertzen - * Licensed under the MIT license. - */ - -function createDbTable(t, dbInfo, callback, errorCallback) { - t.executeSql('CREATE TABLE IF NOT EXISTS ' + dbInfo.storeName + ' ' + '(id INTEGER PRIMARY KEY, key unique, value)', [], callback, errorCallback); -} - -// Open the WebSQL database (automatically creates one if one didn't -// previously exist), using any options set in the config. -function _initStorage$1(options) { - var self = this; - var dbInfo = { - db: null - }; - - if (options) { - for (var i in options) { - dbInfo[i] = typeof options[i] !== 'string' ? options[i].toString() : options[i]; - } - } - - var dbInfoPromise = new Promise$1(function (resolve, reject) { - // Open the database; the openDatabase API will automatically - // create it for us if it doesn't exist. - try { - dbInfo.db = openDatabase(dbInfo.name, String(dbInfo.version), dbInfo.description, dbInfo.size); - } catch (e) { - return reject(e); - } - - // Create our key/value table if it doesn't exist. - dbInfo.db.transaction(function (t) { - createDbTable(t, dbInfo, function () { - self._dbInfo = dbInfo; - resolve(); - }, function (t, error) { - reject(error); - }); - }, reject); - }); - - dbInfo.serializer = localforageSerializer; - return dbInfoPromise; -} - -function tryExecuteSql(t, dbInfo, sqlStatement, args, callback, errorCallback) { - t.executeSql(sqlStatement, args, callback, function (t, error) { - if (error.code === error.SYNTAX_ERR) { - t.executeSql('SELECT name FROM sqlite_master ' + "WHERE type='table' AND name = ?", [dbInfo.storeName], function (t, results) { - if (!results.rows.length) { - // if the table is missing (was deleted) - // re-create it table and retry - createDbTable(t, dbInfo, function () { - t.executeSql(sqlStatement, args, callback, errorCallback); - }, errorCallback); - } else { - errorCallback(t, error); - } - }, errorCallback); - } else { - errorCallback(t, error); - } - }, errorCallback); -} - -function getItem$1(key, callback) { - var self = this; - - key = normalizeKey(key); - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - var dbInfo = self._dbInfo; - dbInfo.db.transaction(function (t) { - tryExecuteSql(t, dbInfo, 'SELECT * FROM ' + dbInfo.storeName + ' WHERE key = ? LIMIT 1', [key], function (t, results) { - var result = results.rows.length ? results.rows.item(0).value : null; - - // Check to see if this is serialized content we need to - // unpack. - if (result) { - result = dbInfo.serializer.deserialize(result); - } - - resolve(result); - }, function (t, error) { - reject(error); - }); - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function iterate$1(iterator, callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - var dbInfo = self._dbInfo; - - dbInfo.db.transaction(function (t) { - tryExecuteSql(t, dbInfo, 'SELECT * FROM ' + dbInfo.storeName, [], function (t, results) { - var rows = results.rows; - var length = rows.length; - - for (var i = 0; i < length; i++) { - var item = rows.item(i); - var result = item.value; - - // Check to see if this is serialized content - // we need to unpack. - if (result) { - result = dbInfo.serializer.deserialize(result); - } - - result = iterator(result, item.key, i + 1); - - // void(0) prevents problems with redefinition - // of `undefined`. - if (result !== void 0) { - resolve(result); - return; - } - } - - resolve(); - }, function (t, error) { - reject(error); - }); - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function _setItem(key, value, callback, retriesLeft) { - var self = this; - - key = normalizeKey(key); - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - // The localStorage API doesn't return undefined values in an - // "expected" way, so undefined is always cast to null in all - // drivers. See: https://github.com/mozilla/localForage/pull/42 - if (value === undefined) { - value = null; - } - - // Save the original value to pass to the callback. - var originalValue = value; - - var dbInfo = self._dbInfo; - dbInfo.serializer.serialize(value, function (value, error) { - if (error) { - reject(error); - } else { - dbInfo.db.transaction(function (t) { - tryExecuteSql(t, dbInfo, 'INSERT OR REPLACE INTO ' + dbInfo.storeName + ' ' + '(key, value) VALUES (?, ?)', [key, value], function () { - resolve(originalValue); - }, function (t, error) { - reject(error); - }); - }, function (sqlError) { - // The transaction failed; check - // to see if it's a quota error. - if (sqlError.code === sqlError.QUOTA_ERR) { - // We reject the callback outright for now, but - // it's worth trying to re-run the transaction. - // Even if the user accepts the prompt to use - // more storage on Safari, this error will - // be called. - // - // Try to re-run the transaction. - if (retriesLeft > 0) { - resolve(_setItem.apply(self, [key, originalValue, callback, retriesLeft - 1])); - return; - } - reject(sqlError); - } - }); - } - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function setItem$1(key, value, callback) { - return _setItem.apply(this, [key, value, callback, 1]); -} - -function removeItem$1(key, callback) { - var self = this; - - key = normalizeKey(key); - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - var dbInfo = self._dbInfo; - dbInfo.db.transaction(function (t) { - tryExecuteSql(t, dbInfo, 'DELETE FROM ' + dbInfo.storeName + ' WHERE key = ?', [key], function () { - resolve(); - }, function (t, error) { - reject(error); - }); - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -// Deletes every item in the table. -// TODO: Find out if this resets the AUTO_INCREMENT number. -function clear$1(callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - var dbInfo = self._dbInfo; - dbInfo.db.transaction(function (t) { - tryExecuteSql(t, dbInfo, 'DELETE FROM ' + dbInfo.storeName, [], function () { - resolve(); - }, function (t, error) { - reject(error); - }); - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -// Does a simple `COUNT(key)` to get the number of items stored in -// localForage. -function length$1(callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - var dbInfo = self._dbInfo; - dbInfo.db.transaction(function (t) { - // Ahhh, SQL makes this one soooooo easy. - tryExecuteSql(t, dbInfo, 'SELECT COUNT(key) as c FROM ' + dbInfo.storeName, [], function (t, results) { - var result = results.rows.item(0).c; - resolve(result); - }, function (t, error) { - reject(error); - }); - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -// Return the key located at key index X; essentially gets the key from a -// `WHERE id = ?`. This is the most efficient way I can think to implement -// this rarely-used (in my experience) part of the API, but it can seem -// inconsistent, because we do `INSERT OR REPLACE INTO` on `setItem()`, so -// the ID of each key will change every time it's updated. Perhaps a stored -// procedure for the `setItem()` SQL would solve this problem? -// TODO: Don't change ID on `setItem()`. -function key$1(n, callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - var dbInfo = self._dbInfo; - dbInfo.db.transaction(function (t) { - tryExecuteSql(t, dbInfo, 'SELECT key FROM ' + dbInfo.storeName + ' WHERE id = ? LIMIT 1', [n + 1], function (t, results) { - var result = results.rows.length ? results.rows.item(0).key : null; - resolve(result); - }, function (t, error) { - reject(error); - }); - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -function keys$1(callback) { - var self = this; - - var promise = new Promise$1(function (resolve, reject) { - self.ready().then(function () { - var dbInfo = self._dbInfo; - dbInfo.db.transaction(function (t) { - tryExecuteSql(t, dbInfo, 'SELECT key FROM ' + dbInfo.storeName, [], function (t, results) { - var keys = []; - - for (var i = 0; i < results.rows.length; i++) { - keys.push(results.rows.item(i).key); - } - - resolve(keys); - }, function (t, error) { - reject(error); - }); - }); - })["catch"](reject); - }); - - executeCallback(promise, callback); - return promise; -} - -// https://www.w3.org/TR/webdatabase/#databases -// > There is no way to enumerate or delete the databases available for an origin from this API. -function getAllStoreNames(db) { - return new Promise$1(function (resolve, reject) { - db.transaction(function (t) { - t.executeSql('SELECT name FROM sqlite_master ' + "WHERE type='table' AND name <> '__WebKitDatabaseInfoTable__'", [], function (t, results) { - var storeNames = []; - - for (var i = 0; i < results.rows.length; i++) { - storeNames.push(results.rows.item(i).name); - } - - resolve({ - db: db, - storeNames: storeNames - }); - }, function (t, error) { - reject(error); - }); - }, function (sqlError) { - reject(sqlError); - }); - }); -} - -function dropInstance$1(options, callback) { - callback = getCallback.apply(this, arguments); - - var currentConfig = this.config(); - options = typeof options !== 'function' && options || {}; - if (!options.name) { - options.name = options.name || currentConfig.name; - options.storeName = options.storeName || currentConfig.storeName; - } - - var self = this; - var promise; - if (!options.name) { - promise = Promise$1.reject('Invalid arguments'); - } else { - promise = new Promise$1(function (resolve) { - var db; - if (options.name === currentConfig.name) { - // use the db reference of the current instance - db = self._dbInfo.db; - } else { - db = openDatabase(options.name, '', '', 0); - } - - if (!options.storeName) { - // drop all database tables - resolve(getAllStoreNames(db)); - } else { - resolve({ - db: db, - storeNames: [options.storeName] - }); - } - }).then(function (operationInfo) { - return new Promise$1(function (resolve, reject) { - operationInfo.db.transaction(function (t) { - function dropTable(storeName) { - return new Promise$1(function (resolve, reject) { - t.executeSql('DROP TABLE IF EXISTS ' + storeName, [], function () { - resolve(); - }, function (t, error) { - reject(error); - }); - }); - } - - var operations = []; - for (var i = 0, len = operationInfo.storeNames.length; i < len; i++) { - operations.push(dropTable(operationInfo.storeNames[i])); - } - - Promise$1.all(operations).then(function () { - resolve(); - })["catch"](function (e) { - reject(e); - }); - }, function (sqlError) { - reject(sqlError); - }); - }); - }); - } - - executeCallback(promise, callback); - return promise; -} - -var webSQLStorage = { - _driver: 'webSQLStorage', - _initStorage: _initStorage$1, - _support: isWebSQLValid(), - iterate: iterate$1, - getItem: getItem$1, - setItem: setItem$1, - removeItem: removeItem$1, - clear: clear$1, - length: length$1, - key: key$1, - keys: keys$1, - dropInstance: dropInstance$1 -}; - -function isLocalStorageValid() { - try { - return typeof localStorage !== 'undefined' && 'setItem' in localStorage && - // in IE8 typeof localStorage.setItem === 'object' - !!localStorage.setItem; - } catch (e) { - return false; - } -} - -function _getKeyPrefix(options, defaultConfig) { - var keyPrefix = options.name + '/'; - - if (options.storeName !== defaultConfig.storeName) { - keyPrefix += options.storeName + '/'; - } - return keyPrefix; -} - -// Check if localStorage throws when saving an item -function checkIfLocalStorageThrows() { - var localStorageTestKey = '_localforage_support_test'; - - try { - localStorage.setItem(localStorageTestKey, true); - localStorage.removeItem(localStorageTestKey); - - return false; - } catch (e) { - return true; - } -} - -// Check if localStorage is usable and allows to save an item -// This method checks if localStorage is usable in Safari Private Browsing -// mode, or in any other case where the available quota for localStorage -// is 0 and there wasn't any saved items yet. -function _isLocalStorageUsable() { - return !checkIfLocalStorageThrows() || localStorage.length > 0; -} - -// Config the localStorage backend, using options set in the config. -function _initStorage$2(options) { - var self = this; - var dbInfo = {}; - if (options) { - for (var i in options) { - dbInfo[i] = options[i]; - } - } - - dbInfo.keyPrefix = _getKeyPrefix(options, self._defaultConfig); - - if (!_isLocalStorageUsable()) { - return Promise$1.reject(); - } - - self._dbInfo = dbInfo; - dbInfo.serializer = localforageSerializer; - - return Promise$1.resolve(); -} - -// Remove all keys from the datastore, effectively destroying all data in -// the app's key/value store! -function clear$2(callback) { - var self = this; - var promise = self.ready().then(function () { - var keyPrefix = self._dbInfo.keyPrefix; - - for (var i = localStorage.length - 1; i >= 0; i--) { - var key = localStorage.key(i); - - if (key.indexOf(keyPrefix) === 0) { - localStorage.removeItem(key); - } - } - }); - - executeCallback(promise, callback); - return promise; -} - -// Retrieve an item from the store. Unlike the original async_storage -// library in Gaia, we don't modify return values at all. If a key's value -// is `undefined`, we pass that value to the callback function. -function getItem$2(key, callback) { - var self = this; - - key = normalizeKey(key); - - var promise = self.ready().then(function () { - var dbInfo = self._dbInfo; - var result = localStorage.getItem(dbInfo.keyPrefix + key); - - // If a result was found, parse it from the serialized - // string into a JS object. If result isn't truthy, the key - // is likely undefined and we'll pass it straight to the - // callback. - if (result) { - result = dbInfo.serializer.deserialize(result); - } - - return result; - }); - - executeCallback(promise, callback); - return promise; -} - -// Iterate over all items in the store. -function iterate$2(iterator, callback) { - var self = this; - - var promise = self.ready().then(function () { - var dbInfo = self._dbInfo; - var keyPrefix = dbInfo.keyPrefix; - var keyPrefixLength = keyPrefix.length; - var length = localStorage.length; - - // We use a dedicated iterator instead of the `i` variable below - // so other keys we fetch in localStorage aren't counted in - // the `iterationNumber` argument passed to the `iterate()` - // callback. - // - // See: github.com/mozilla/localForage/pull/435#discussion_r38061530 - var iterationNumber = 1; - - for (var i = 0; i < length; i++) { - var key = localStorage.key(i); - if (key.indexOf(keyPrefix) !== 0) { - continue; - } - var value = localStorage.getItem(key); - - // If a result was found, parse it from the serialized - // string into a JS object. If result isn't truthy, the - // key is likely undefined and we'll pass it straight - // to the iterator. - if (value) { - value = dbInfo.serializer.deserialize(value); - } - - value = iterator(value, key.substring(keyPrefixLength), iterationNumber++); - - if (value !== void 0) { - return value; - } - } - }); - - executeCallback(promise, callback); - return promise; -} - -// Same as localStorage's key() method, except takes a callback. -function key$2(n, callback) { - var self = this; - var promise = self.ready().then(function () { - var dbInfo = self._dbInfo; - var result; - try { - result = localStorage.key(n); - } catch (error) { - result = null; - } - - // Remove the prefix from the key, if a key is found. - if (result) { - result = result.substring(dbInfo.keyPrefix.length); - } - - return result; - }); - - executeCallback(promise, callback); - return promise; -} - -function keys$2(callback) { - var self = this; - var promise = self.ready().then(function () { - var dbInfo = self._dbInfo; - var length = localStorage.length; - var keys = []; - - for (var i = 0; i < length; i++) { - var itemKey = localStorage.key(i); - if (itemKey.indexOf(dbInfo.keyPrefix) === 0) { - keys.push(itemKey.substring(dbInfo.keyPrefix.length)); - } - } - - return keys; - }); - - executeCallback(promise, callback); - return promise; -} - -// Supply the number of keys in the datastore to the callback function. -function length$2(callback) { - var self = this; - var promise = self.keys().then(function (keys) { - return keys.length; - }); - - executeCallback(promise, callback); - return promise; -} - -// Remove an item from the store, nice and simple. -function removeItem$2(key, callback) { - var self = this; - - key = normalizeKey(key); - - var promise = self.ready().then(function () { - var dbInfo = self._dbInfo; - localStorage.removeItem(dbInfo.keyPrefix + key); - }); - - executeCallback(promise, callback); - return promise; -} - -// Set a key's value and run an optional callback once the value is set. -// Unlike Gaia's implementation, the callback function is passed the value, -// in case you want to operate on that value only after you're sure it -// saved, or something like that. -function setItem$2(key, value, callback) { - var self = this; - - key = normalizeKey(key); - - var promise = self.ready().then(function () { - // Convert undefined values to null. - // https://github.com/mozilla/localForage/pull/42 - if (value === undefined) { - value = null; - } - - // Save the original value to pass to the callback. - var originalValue = value; - - return new Promise$1(function (resolve, reject) { - var dbInfo = self._dbInfo; - dbInfo.serializer.serialize(value, function (value, error) { - if (error) { - reject(error); - } else { - try { - localStorage.setItem(dbInfo.keyPrefix + key, value); - resolve(originalValue); - } catch (e) { - // localStorage capacity exceeded. - // TODO: Make this a specific error/event. - if (e.name === 'QuotaExceededError' || e.name === 'NS_ERROR_DOM_QUOTA_REACHED') { - reject(e); - } - reject(e); - } - } - }); - }); - }); - - executeCallback(promise, callback); - return promise; -} - -function dropInstance$2(options, callback) { - callback = getCallback.apply(this, arguments); - - options = typeof options !== 'function' && options || {}; - if (!options.name) { - var currentConfig = this.config(); - options.name = options.name || currentConfig.name; - options.storeName = options.storeName || currentConfig.storeName; - } - - var self = this; - var promise; - if (!options.name) { - promise = Promise$1.reject('Invalid arguments'); - } else { - promise = new Promise$1(function (resolve) { - if (!options.storeName) { - resolve(options.name + '/'); - } else { - resolve(_getKeyPrefix(options, self._defaultConfig)); - } - }).then(function (keyPrefix) { - for (var i = localStorage.length - 1; i >= 0; i--) { - var key = localStorage.key(i); - - if (key.indexOf(keyPrefix) === 0) { - localStorage.removeItem(key); - } - } - }); - } - - executeCallback(promise, callback); - return promise; -} - -var localStorageWrapper = { - _driver: 'localStorageWrapper', - _initStorage: _initStorage$2, - _support: isLocalStorageValid(), - iterate: iterate$2, - getItem: getItem$2, - setItem: setItem$2, - removeItem: removeItem$2, - clear: clear$2, - length: length$2, - key: key$2, - keys: keys$2, - dropInstance: dropInstance$2 -}; - -var sameValue = function sameValue(x, y) { - return x === y || typeof x === 'number' && typeof y === 'number' && isNaN(x) && isNaN(y); -}; - -var includes = function includes(array, searchElement) { - var len = array.length; - var i = 0; - while (i < len) { - if (sameValue(array[i], searchElement)) { - return true; - } - i++; - } - - return false; -}; - -var isArray = Array.isArray || function (arg) { - return Object.prototype.toString.call(arg) === '[object Array]'; -}; - -// Drivers are stored here when `defineDriver()` is called. -// They are shared across all instances of localForage. -var DefinedDrivers = {}; - -var DriverSupport = {}; - -var DefaultDrivers = { - INDEXEDDB: asyncStorage, - WEBSQL: webSQLStorage, - LOCALSTORAGE: localStorageWrapper -}; - -var DefaultDriverOrder = [DefaultDrivers.INDEXEDDB._driver, DefaultDrivers.WEBSQL._driver, DefaultDrivers.LOCALSTORAGE._driver]; - -var OptionalDriverMethods = ['dropInstance']; - -var LibraryMethods = ['clear', 'getItem', 'iterate', 'key', 'keys', 'length', 'removeItem', 'setItem'].concat(OptionalDriverMethods); - -var DefaultConfig = { - description: '', - driver: DefaultDriverOrder.slice(), - name: 'localforage', - // Default DB size is _JUST UNDER_ 5MB, as it's the highest size - // we can use without a prompt. - size: 4980736, - storeName: 'keyvaluepairs', - version: 1.0 -}; - -function callWhenReady(localForageInstance, libraryMethod) { - localForageInstance[libraryMethod] = function () { - var _args = arguments; - return localForageInstance.ready().then(function () { - return localForageInstance[libraryMethod].apply(localForageInstance, _args); - }); - }; -} - -function extend() { - for (var i = 1; i < arguments.length; i++) { - var arg = arguments[i]; - - if (arg) { - for (var _key in arg) { - if (arg.hasOwnProperty(_key)) { - if (isArray(arg[_key])) { - arguments[0][_key] = arg[_key].slice(); - } else { - arguments[0][_key] = arg[_key]; - } - } - } - } - } - - return arguments[0]; -} - -var LocalForage = function () { - function LocalForage(options) { - _classCallCheck(this, LocalForage); - - for (var driverTypeKey in DefaultDrivers) { - if (DefaultDrivers.hasOwnProperty(driverTypeKey)) { - var driver = DefaultDrivers[driverTypeKey]; - var driverName = driver._driver; - this[driverTypeKey] = driverName; - - if (!DefinedDrivers[driverName]) { - // we don't need to wait for the promise, - // since the default drivers can be defined - // in a blocking manner - this.defineDriver(driver); - } - } - } - - this._defaultConfig = extend({}, DefaultConfig); - this._config = extend({}, this._defaultConfig, options); - this._driverSet = null; - this._initDriver = null; - this._ready = false; - this._dbInfo = null; - - this._wrapLibraryMethodsWithReady(); - this.setDriver(this._config.driver)["catch"](function () {}); - } - - // Set any config values for localForage; can be called anytime before - // the first API call (e.g. `getItem`, `setItem`). - // We loop through options so we don't overwrite existing config - // values. - - - LocalForage.prototype.config = function config(options) { - // If the options argument is an object, we use it to set values. - // Otherwise, we return either a specified config value or all - // config values. - if ((typeof options === 'undefined' ? 'undefined' : _typeof(options)) === 'object') { - // If localforage is ready and fully initialized, we can't set - // any new configuration values. Instead, we return an error. - if (this._ready) { - return new Error("Can't call config() after localforage " + 'has been used.'); - } - - for (var i in options) { - if (i === 'storeName') { - options[i] = options[i].replace(/\W/g, '_'); - } - - if (i === 'version' && typeof options[i] !== 'number') { - return new Error('Database version must be a number.'); - } - - this._config[i] = options[i]; - } - - // after all config options are set and - // the driver option is used, try setting it - if ('driver' in options && options.driver) { - return this.setDriver(this._config.driver); - } - - return true; - } else if (typeof options === 'string') { - return this._config[options]; - } else { - return this._config; - } - }; - - // Used to define a custom driver, shared across all instances of - // localForage. - - - LocalForage.prototype.defineDriver = function defineDriver(driverObject, callback, errorCallback) { - var promise = new Promise$1(function (resolve, reject) { - try { - var driverName = driverObject._driver; - var complianceError = new Error('Custom driver not compliant; see ' + 'https://mozilla.github.io/localForage/#definedriver'); - - // A driver name should be defined and not overlap with the - // library-defined, default drivers. - if (!driverObject._driver) { - reject(complianceError); - return; - } - - var driverMethods = LibraryMethods.concat('_initStorage'); - for (var i = 0, len = driverMethods.length; i < len; i++) { - var driverMethodName = driverMethods[i]; - - // when the property is there, - // it should be a method even when optional - var isRequired = !includes(OptionalDriverMethods, driverMethodName); - if ((isRequired || driverObject[driverMethodName]) && typeof driverObject[driverMethodName] !== 'function') { - reject(complianceError); - return; - } - } - - var configureMissingMethods = function configureMissingMethods() { - var methodNotImplementedFactory = function methodNotImplementedFactory(methodName) { - return function () { - var error = new Error('Method ' + methodName + ' is not implemented by the current driver'); - var promise = Promise$1.reject(error); - executeCallback(promise, arguments[arguments.length - 1]); - return promise; - }; - }; - - for (var _i = 0, _len = OptionalDriverMethods.length; _i < _len; _i++) { - var optionalDriverMethod = OptionalDriverMethods[_i]; - if (!driverObject[optionalDriverMethod]) { - driverObject[optionalDriverMethod] = methodNotImplementedFactory(optionalDriverMethod); - } - } - }; - - configureMissingMethods(); - - var setDriverSupport = function setDriverSupport(support) { - if (DefinedDrivers[driverName]) { - console.info('Redefining LocalForage driver: ' + driverName); - } - DefinedDrivers[driverName] = driverObject; - DriverSupport[driverName] = support; - // don't use a then, so that we can define - // drivers that have simple _support methods - // in a blocking manner - resolve(); - }; - - if ('_support' in driverObject) { - if (driverObject._support && typeof driverObject._support === 'function') { - driverObject._support().then(setDriverSupport, reject); - } else { - setDriverSupport(!!driverObject._support); - } - } else { - setDriverSupport(true); - } - } catch (e) { - reject(e); - } - }); - - executeTwoCallbacks(promise, callback, errorCallback); - return promise; - }; - - LocalForage.prototype.driver = function driver() { - return this._driver || null; - }; - - LocalForage.prototype.getDriver = function getDriver(driverName, callback, errorCallback) { - var getDriverPromise = DefinedDrivers[driverName] ? Promise$1.resolve(DefinedDrivers[driverName]) : Promise$1.reject(new Error('Driver not found.')); - - executeTwoCallbacks(getDriverPromise, callback, errorCallback); - return getDriverPromise; - }; - - LocalForage.prototype.getSerializer = function getSerializer(callback) { - var serializerPromise = Promise$1.resolve(localforageSerializer); - executeTwoCallbacks(serializerPromise, callback); - return serializerPromise; - }; - - LocalForage.prototype.ready = function ready(callback) { - var self = this; - - var promise = self._driverSet.then(function () { - if (self._ready === null) { - self._ready = self._initDriver(); - } - - return self._ready; - }); - - executeTwoCallbacks(promise, callback, callback); - return promise; - }; - - LocalForage.prototype.setDriver = function setDriver(drivers, callback, errorCallback) { - var self = this; - - if (!isArray(drivers)) { - drivers = [drivers]; - } - - var supportedDrivers = this._getSupportedDrivers(drivers); - - function setDriverToConfig() { - self._config.driver = self.driver(); - } - - function extendSelfWithDriver(driver) { - self._extend(driver); - setDriverToConfig(); - - self._ready = self._initStorage(self._config); - return self._ready; - } - - function initDriver(supportedDrivers) { - return function () { - var currentDriverIndex = 0; - - function driverPromiseLoop() { - while (currentDriverIndex < supportedDrivers.length) { - var driverName = supportedDrivers[currentDriverIndex]; - currentDriverIndex++; - - self._dbInfo = null; - self._ready = null; - - return self.getDriver(driverName).then(extendSelfWithDriver)["catch"](driverPromiseLoop); - } - - setDriverToConfig(); - var error = new Error('No available storage method found.'); - self._driverSet = Promise$1.reject(error); - return self._driverSet; - } - - return driverPromiseLoop(); - }; - } - - // There might be a driver initialization in progress - // so wait for it to finish in order to avoid a possible - // race condition to set _dbInfo - var oldDriverSetDone = this._driverSet !== null ? this._driverSet["catch"](function () { - return Promise$1.resolve(); - }) : Promise$1.resolve(); - - this._driverSet = oldDriverSetDone.then(function () { - var driverName = supportedDrivers[0]; - self._dbInfo = null; - self._ready = null; - - return self.getDriver(driverName).then(function (driver) { - self._driver = driver._driver; - setDriverToConfig(); - self._wrapLibraryMethodsWithReady(); - self._initDriver = initDriver(supportedDrivers); - }); - })["catch"](function () { - setDriverToConfig(); - var error = new Error('No available storage method found.'); - self._driverSet = Promise$1.reject(error); - return self._driverSet; - }); - - executeTwoCallbacks(this._driverSet, callback, errorCallback); - return this._driverSet; - }; - - LocalForage.prototype.supports = function supports(driverName) { - return !!DriverSupport[driverName]; - }; - - LocalForage.prototype._extend = function _extend(libraryMethodsAndProperties) { - extend(this, libraryMethodsAndProperties); - }; - - LocalForage.prototype._getSupportedDrivers = function _getSupportedDrivers(drivers) { - var supportedDrivers = []; - for (var i = 0, len = drivers.length; i < len; i++) { - var driverName = drivers[i]; - if (this.supports(driverName)) { - supportedDrivers.push(driverName); - } - } - return supportedDrivers; - }; - - LocalForage.prototype._wrapLibraryMethodsWithReady = function _wrapLibraryMethodsWithReady() { - // Add a stub for each driver API method that delays the call to the - // corresponding driver method until localForage is ready. These stubs - // will be replaced by the driver methods as soon as the driver is - // loaded, so there is no performance impact. - for (var i = 0, len = LibraryMethods.length; i < len; i++) { - callWhenReady(this, LibraryMethods[i]); - } - }; - - LocalForage.prototype.createInstance = function createInstance(options) { - return new LocalForage(options); - }; - - return LocalForage; -}(); - -// The actual localForage object that we expose as a module or via a -// global. It's extended by pulling in one of our other libraries. - - -var localforage_js = new LocalForage(); - -module.exports = localforage_js; - -},{"3":3}]},{},[4])(4) -}); - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5))) - -/***/ }), -/* 75 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _core = __webpack_require__(0); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -/** - * Open DisplayOptions Format Parser - * @class - * @param {document} displayOptionsDocument XML - */ -var DisplayOptions = function () { - function DisplayOptions(displayOptionsDocument) { - _classCallCheck(this, DisplayOptions); - - this.interactive = ""; - this.fixedLayout = ""; - this.openToSpread = ""; - this.orientationLock = ""; - - if (displayOptionsDocument) { - this.parse(displayOptionsDocument); - } - } - - /** - * Parse XML - * @param {document} displayOptionsDocument XML - * @return {DisplayOptions} self - */ - - - _createClass(DisplayOptions, [{ - key: "parse", - value: function parse(displayOptionsDocument) { - var _this = this; - - if (!displayOptionsDocument) { - return this; - } - - var displayOptionsNode = (0, _core.qs)(displayOptionsDocument, "display_options"); - if (!displayOptionsNode) { - return this; - } - - var options = (0, _core.qsa)(displayOptionsNode, "option"); - options.forEach(function (el) { - var value = ""; - - if (el.childNodes.length) { - value = el.childNodes[0].nodeValue; - } - - switch (el.attributes.name.value) { - case "interactive": - _this.interactive = value; - break; - case "fixed-layout": - _this.fixedLayout = value; - break; - case "open-to-spread": - _this.openToSpread = value; - break; - case "orientation-lock": - _this.orientationLock = value; - break; - } - }); - - return this; - } - }, { - key: "destroy", - value: function destroy() { - this.interactive = undefined; - this.fixedLayout = undefined; - this.openToSpread = undefined; - this.orientationLock = undefined; - } - }]); - - return DisplayOptions; -}(); - -exports.default = DisplayOptions; -module.exports = exports["default"]; - -/***/ }), -/* 76 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(global) {(function(global) { - /** - * Polyfill URLSearchParams - * - * Inspired from : https://github.com/WebReflection/url-search-params/blob/master/src/url-search-params.js - */ - - var checkIfIteratorIsSupported = function() { - try { - return !!Symbol.iterator; - } catch (error) { - return false; - } - }; - - - var iteratorSupported = checkIfIteratorIsSupported(); - - var createIterator = function(items) { - var iterator = { - next: function() { - var value = items.shift(); - return { done: value === void 0, value: value }; - } - }; - - if (iteratorSupported) { - iterator[Symbol.iterator] = function() { - return iterator; - }; - } - - return iterator; - }; - - /** - * Search param name and values should be encoded according to https://url.spec.whatwg.org/#urlencoded-serializing - * encodeURIComponent() produces the same result except encoding spaces as `%20` instead of `+`. - */ - var serializeParam = function(value) { - return encodeURIComponent(value).replace(/%20/g, '+'); - }; - - var deserializeParam = function(value) { - return decodeURIComponent(value).replace(/\+/g, ' '); - }; - - var polyfillURLSearchParams = function() { - - var URLSearchParams = function(searchString) { - Object.defineProperty(this, '_entries', { writable: true, value: {} }); - var typeofSearchString = typeof searchString; - - if (typeofSearchString === 'undefined') { - // do nothing - } else if (typeofSearchString === 'string') { - if (searchString !== '') { - this._fromString(searchString); - } - } else if (searchString instanceof URLSearchParams) { - var _this = this; - searchString.forEach(function(value, name) { - _this.append(name, value); - }); - } else if ((searchString !== null) && (typeofSearchString === 'object')) { - if (Object.prototype.toString.call(searchString) === '[object Array]') { - for (var i = 0; i < searchString.length; i++) { - var entry = searchString[i]; - if ((Object.prototype.toString.call(entry) === '[object Array]') || (entry.length !== 2)) { - this.append(entry[0], entry[1]); - } else { - throw new TypeError('Expected [string, any] as entry at index ' + i + ' of URLSearchParams\'s input'); - } - } - } else { - for (var key in searchString) { - if (searchString.hasOwnProperty(key)) { - this.append(key, searchString[key]); - } - } - } - } else { - throw new TypeError('Unsupported input\'s type for URLSearchParams'); - } - }; - - var proto = URLSearchParams.prototype; - - proto.append = function(name, value) { - if (name in this._entries) { - this._entries[name].push(String(value)); - } else { - this._entries[name] = [String(value)]; - } - }; - - proto.delete = function(name) { - delete this._entries[name]; - }; - - proto.get = function(name) { - return (name in this._entries) ? this._entries[name][0] : null; - }; - - proto.getAll = function(name) { - return (name in this._entries) ? this._entries[name].slice(0) : []; - }; - - proto.has = function(name) { - return (name in this._entries); - }; - - proto.set = function(name, value) { - this._entries[name] = [String(value)]; - }; - - proto.forEach = function(callback, thisArg) { - var entries; - for (var name in this._entries) { - if (this._entries.hasOwnProperty(name)) { - entries = this._entries[name]; - for (var i = 0; i < entries.length; i++) { - callback.call(thisArg, entries[i], name, this); - } - } - } - }; - - proto.keys = function() { - var items = []; - this.forEach(function(value, name) { - items.push(name); - }); - return createIterator(items); - }; - - proto.values = function() { - var items = []; - this.forEach(function(value) { - items.push(value); - }); - return createIterator(items); - }; - - proto.entries = function() { - var items = []; - this.forEach(function(value, name) { - items.push([name, value]); - }); - return createIterator(items); - }; - - if (iteratorSupported) { - proto[Symbol.iterator] = proto.entries; - } - - proto.toString = function() { - var searchArray = []; - this.forEach(function(value, name) { - searchArray.push(serializeParam(name) + '=' + serializeParam(value)); - }); - return searchArray.join('&'); - }; - - - global.URLSearchParams = URLSearchParams; - }; - - if (!('URLSearchParams' in global) || (new URLSearchParams('?a=1').toString() !== 'a=1')) { - polyfillURLSearchParams(); - } - - var proto = URLSearchParams.prototype; - - if (typeof proto.sort !== 'function') { - proto.sort = function() { - var _this = this; - var items = []; - this.forEach(function(value, name) { - items.push([name, value]); - if (!_this._entries) { - _this.delete(name); - } - }); - items.sort(function(a, b) { - if (a[0] < b[0]) { - return -1; - } else if (a[0] > b[0]) { - return +1; - } else { - return 0; - } - }); - if (_this._entries) { // force reset because IE keeps keys index - _this._entries = {}; - } - for (var i = 0; i < items.length; i++) { - this.append(items[i][0], items[i][1]); - } - }; - } - - if (typeof proto._fromString !== 'function') { - Object.defineProperty(proto, '_fromString', { - enumerable: false, - configurable: false, - writable: false, - value: function(searchString) { - if (this._entries) { - this._entries = {}; - } else { - var keys = []; - this.forEach(function(value, name) { - keys.push(name); - }); - for (var i = 0; i < keys.length; i++) { - this.delete(keys[i]); - } - } - - searchString = searchString.replace(/^\?/, ''); - var attributes = searchString.split('&'); - var attribute; - for (var i = 0; i < attributes.length; i++) { - attribute = attributes[i].split('='); - this.append( - deserializeParam(attribute[0]), - (attribute.length > 1) ? deserializeParam(attribute[1]) : '' - ); - } - } - }); - } - - // HTMLAnchorElement - -})( - (typeof global !== 'undefined') ? global - : ((typeof window !== 'undefined') ? window - : ((typeof self !== 'undefined') ? self : this)) -); - -(function(global) { - /** - * Polyfill URL - * - * Inspired from : https://github.com/arv/DOM-URL-Polyfill/blob/master/src/url.js - */ - - var checkIfURLIsSupported = function() { - try { - var u = new URL('b', 'http://a'); - u.pathname = 'c%20d'; - return (u.href === 'http://a/c%20d') && u.searchParams; - } catch (e) { - return false; - } - }; - - - var polyfillURL = function() { - var _URL = global.URL; - - var URL = function(url, base) { - if (typeof url !== 'string') url = String(url); - - // Only create another document if the base is different from current location. - var doc = document, baseElement; - if (base && (global.location === void 0 || base !== global.location.href)) { - doc = document.implementation.createHTMLDocument(''); - baseElement = doc.createElement('base'); - baseElement.href = base; - doc.head.appendChild(baseElement); - try { - if (baseElement.href.indexOf(base) !== 0) throw new Error(baseElement.href); - } catch (err) { - throw new Error('URL unable to set base ' + base + ' due to ' + err); - } - } - - var anchorElement = doc.createElement('a'); - anchorElement.href = url; - if (baseElement) { - doc.body.appendChild(anchorElement); - anchorElement.href = anchorElement.href; // force href to refresh - } - - if (anchorElement.protocol === ':' || !/:/.test(anchorElement.href)) { - throw new TypeError('Invalid URL'); - } - - Object.defineProperty(this, '_anchorElement', { - value: anchorElement - }); - - - // create a linked searchParams which reflect its changes on URL - var searchParams = new URLSearchParams(this.search); - var enableSearchUpdate = true; - var enableSearchParamsUpdate = true; - var _this = this; - ['append', 'delete', 'set'].forEach(function(methodName) { - var method = searchParams[methodName]; - searchParams[methodName] = function() { - method.apply(searchParams, arguments); - if (enableSearchUpdate) { - enableSearchParamsUpdate = false; - _this.search = searchParams.toString(); - enableSearchParamsUpdate = true; - } - }; - }); - - Object.defineProperty(this, 'searchParams', { - value: searchParams, - enumerable: true - }); - - var search = void 0; - Object.defineProperty(this, '_updateSearchParams', { - enumerable: false, - configurable: false, - writable: false, - value: function() { - if (this.search !== search) { - search = this.search; - if (enableSearchParamsUpdate) { - enableSearchUpdate = false; - this.searchParams._fromString(this.search); - enableSearchUpdate = true; - } - } - } - }); - }; - - var proto = URL.prototype; - - var linkURLWithAnchorAttribute = function(attributeName) { - Object.defineProperty(proto, attributeName, { - get: function() { - return this._anchorElement[attributeName]; - }, - set: function(value) { - this._anchorElement[attributeName] = value; - }, - enumerable: true - }); - }; - - ['hash', 'host', 'hostname', 'port', 'protocol'] - .forEach(function(attributeName) { - linkURLWithAnchorAttribute(attributeName); - }); - - Object.defineProperty(proto, 'search', { - get: function() { - return this._anchorElement['search']; - }, - set: function(value) { - this._anchorElement['search'] = value; - this._updateSearchParams(); - }, - enumerable: true - }); - - Object.defineProperties(proto, { - - 'toString': { - get: function() { - var _this = this; - return function() { - return _this.href; - }; - } - }, - - 'href': { - get: function() { - return this._anchorElement.href.replace(/\?$/, ''); - }, - set: function(value) { - this._anchorElement.href = value; - this._updateSearchParams(); - }, - enumerable: true - }, - - 'pathname': { - get: function() { - return this._anchorElement.pathname.replace(/(^\/?)/, '/'); - }, - set: function(value) { - this._anchorElement.pathname = value; - }, - enumerable: true - }, - - 'origin': { - get: function() { - // get expected port from protocol - var expectedPort = { 'http:': 80, 'https:': 443, 'ftp:': 21 }[this._anchorElement.protocol]; - // add port to origin if, expected port is different than actual port - // and it is not empty f.e http://foo:8080 - // 8080 != 80 && 8080 != '' - var addPortToOrigin = this._anchorElement.port != expectedPort && - this._anchorElement.port !== ''; - - return this._anchorElement.protocol + - '//' + - this._anchorElement.hostname + - (addPortToOrigin ? (':' + this._anchorElement.port) : ''); - }, - enumerable: true - }, - - 'password': { // TODO - get: function() { - return ''; - }, - set: function(value) { - }, - enumerable: true - }, - - 'username': { // TODO - get: function() { - return ''; - }, - set: function(value) { - }, - enumerable: true - }, - }); - - URL.createObjectURL = function(blob) { - return _URL.createObjectURL.apply(_URL, arguments); - }; - - URL.revokeObjectURL = function(url) { - return _URL.revokeObjectURL.apply(_URL, arguments); - }; - - global.URL = URL; - - }; - - if (!checkIfURLIsSupported()) { - polyfillURL(); - } - - if ((global.location !== void 0) && !('origin' in global.location)) { - var getOrigin = function() { - return global.location.protocol + '//' + global.location.hostname + (global.location.port ? (':' + global.location.port) : ''); - }; - - try { - Object.defineProperty(global.location, 'origin', { - get: getOrigin, - enumerable: true - }); - } catch (e) { - setInterval(function() { - global.location.origin = getOrigin(); - }, 100); - } - } - -})( - (typeof global !== 'undefined') ? global - : ((typeof window !== 'undefined') ? window - : ((typeof self !== 'undefined') ? self : this)) -); - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5))) - -/***/ }) -/******/ ]); -}); diff --git a/static/epub.js/js/epub.min.js b/static/epub.js/js/epub.min.js deleted file mode 100644 index 708d146a..00000000 --- a/static/epub.js/js/epub.min.js +++ /dev/null @@ -1 +0,0 @@ -(function(e,t){'object'==typeof exports&&'object'==typeof module?module.exports=t(require('xmldom'),function(){try{return require('jszip')}catch(t){}}()):'function'==typeof define&&define.amd?define(['xmldom','jszip'],t):'object'==typeof exports?exports.ePub=t(require('xmldom'),function(){try{return require('jszip')}catch(t){}}()):e.ePub=t(e.xmldom,e.jszip)})('undefined'==typeof self?this:self,function(e,t){var n=String.prototype,a=Math.abs,i=Math.min,o=Math.ceil,r=Math.round,s=Math.max,l=Math.floor;return function(e){function t(a){if(n[a])return n[a].exports;var i=n[a]={i:a,l:!1,exports:{}};return e[a].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var n={};return t.m=e,t.c=n,t.d=function(e,n,a){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:a})},t.n=function(e){var n=e&&e.__esModule?function(){return e['default']}:function(){return e};return t.d(n,'a',n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p='/dist/',t(t.s=25)}([function(e,t,n){'use strict';function a(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')}function i(){var e=new Date().getTime(),t='xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g,function(t){var n=0|(e+16*Math.random())%16;return e=l(e/16),('x'==t?n:8|7&n).toString(16)});return t}function o(e){return!isNaN(parseFloat(e))&&isFinite(e)}function r(e,t,n,a,i){var o=a||0,s=i||t.length,l=parseInt(o+(s-o)/2),d;return(n||(n=function(e,t){return e>t?1:e=s-o)?l:(d=n(t[l],e),1==s-o?0<=d?l:l+1:0===d?l:-1===d?r(e,t,n,l,s):r(e,t,n,o,l))}function d(e,t,n,a,i){var o=a||0,r=i||t.length,s=parseInt(o+(r-o)/2),l;return(n||(n=function(e,t){return e>t?1:e=r-o)?-1:(l=n(t[s],e),1==r-o?0===l?s:-1:0===l?s:-1===l?d(e,t,n,s,r):d(e,t,n,o,s))}function u(e,t){for(var n=e.parentNode,a=n.childNodes,o=-1,r=0,i;rn.spinePos)return 1;if(t.spinePoso[d].index)return 1;if(a[d].indexs.offset?1:r.offset')}},{key:'textNodes',value:function(e,t){return Array.prototype.slice.call(e.childNodes).filter(function(e){return e.nodeType===l||t&&e.classList.contains(t)})}},{key:'walkToNode',value:function(e,t,n){var a=t||document,o=a.documentElement,s=e.length,l,d,u;for(u=0;uc)t-=c;else{i=u.nodeType===s?u.childNodes[0]:u;break}}return{container:i,offset:t}}},{key:'toRange',value:function(e,t){var n=e||document,a=this,i=!!t&&null!=n.querySelector('.'+t),o,s,l,d,u,c,p,g;if(o='undefined'==typeof n.createRange?new r.RangeObject:n.createRange(),a.range?(s=a.start,c=a.path.steps.concat(s.steps),d=this.findNode(c,n,i?t:null),l=a.end,p=a.path.steps.concat(l.steps),u=this.findNode(p,n,i?t:null)):(s=a.path,c=a.path.steps,d=this.findNode(a.path.steps,n,i?t:null)),d)try{null==s.terminal.offset?o.setStart(d,0):o.setStart(d,s.terminal.offset)}catch(a){g=this.fixMiss(c,s.terminal.offset,n,i?t:null),o.setStart(g.container,g.offset)}else return console.log('No startContainer found for',this.toString()),null;if(u)try{null==l.terminal.offset?o.setEnd(u,0):o.setEnd(u,l.terminal.offset)}catch(r){g=this.fixMiss(p,a.end.terminal.offset,n,i?t:null),o.setEnd(g.container,g.offset)}return o}},{key:'isCfiString',value:function(e){return'string'==typeof e&&0===e.indexOf('epubcfi(')&&')'===e[e.length-1]}},{key:'generateChapterComponent',value:function(e,t,n){var a=parseInt(t),i='/'+2*(e+1)+'/';return i+=2*(a+1),n&&(i+='['+n+']'),i}},{key:'collapse',value:function(e){this.range&&(this.range=!1,e?(this.path.steps=this.path.steps.concat(this.start.steps),this.path.terminal=this.start.terminal):(this.path.steps=this.path.steps.concat(this.end.steps),this.path.terminal=this.end.terminal))}}]),e}();t.default=d,e.exports=t['default']},function(e,t){'use strict';Object.defineProperty(t,'__esModule',{value:!0});var n=t.EPUBJS_VERSION='0.3',a=t.DOM_EVENTS=['keydown','keyup','keypressed','mouseup','mousedown','click','touchend','touchstart','touchmove'],i=t.EVENTS={BOOK:{OPEN_FAILED:'openFailed'},CONTENTS:{EXPAND:'expand',RESIZE:'resize',SELECTED:'selected',SELECTED_RANGE:'selectedRange',LINK_CLICKED:'linkClicked'},LOCATIONS:{CHANGED:'changed'},MANAGERS:{RESIZE:'resize',RESIZED:'resized',ORIENTATION_CHANGE:'orientationchange',ADDED:'added',SCROLL:'scroll',SCROLLED:'scrolled',REMOVED:'removed'},VIEWS:{AXIS:'axis',LOAD_ERROR:'loaderror',RENDERED:'rendered',RESIZED:'resized',DISPLAYED:'displayed',SHOWN:'shown',HIDDEN:'hidden',MARK_CLICKED:'markClicked'},RENDITION:{STARTED:'started',ATTACHED:'attached',DISPLAYED:'displayed',DISPLAY_ERROR:'displayerror',RENDERED:'rendered',REMOVED:'removed',RESIZED:'resized',ORIENTATION_CHANGE:'orientationchange',LOCATION_CHANGED:'locationChanged',RELOCATED:'relocated',MARK_CLICKED:'markClicked',SELECTED:'selected',LAYOUT:'layout'},LAYOUT:{UPDATED:'updated'},ANNOTATION:{ATTACH:'attach',DETACH:'detach'}}},function(e,t,n){'use strict';var a=n(27),o=n(41),r=Function.prototype.apply,s=Function.prototype.call,i=Object.create,l=Object.defineProperty,d=Object.defineProperties,u=Object.prototype.hasOwnProperty,c={configurable:!0,enumerable:!1,writable:!0},p,g,h,m,f,y,v;p=function(e,t){var n;return o(t),u.call(this,'__ee__')?n=this.__ee__:(n=c.value=i(null),l(this,'__ee__',c),c.value=null),n[e]?'object'==typeof n[e]?n[e].push(t):n[e]=[n[e],t]:n[e]=t,this},g=function(e,t){var n,a;return o(t),a=this,p.call(this,e,n=function(){h.call(a,e,n),r.call(t,this,arguments)}),n.__eeOnceListener__=t,this},h=function(e,t){var n,a,r,s;if(o(t),!u.call(this,'__ee__'))return this;if(n=this.__ee__,!n[e])return this;if(a=n[e],'object'==typeof a)for(s=0;r=a[s];++s)(r===t||r.__eeOnceListener__===t)&&(2===a.length?n[e]=a[s?0:1]:a.splice(s,1));else(a===t||a.__eeOnceListener__===t)&&delete n[e];return this},m=function(e){var t,n,a,i,o;if(u.call(this,'__ee__')&&(i=this.__ee__[e],!!i))if('object'==typeof i){for(n=arguments.length,o=Array(n-1),t=1;tn.length||46!==n.charCodeAt(n.length-1)||46!==n.charCodeAt(n.length-2))if(2c){if(47===n.charCodeAt(l+g))return n.slice(l+g+1);if(0==g)return n.slice(l+g)}else s>c&&(47===e.charCodeAt(a+g)?p=g:0==g&&(p=0));break}var i=e.charCodeAt(a+g),h=n.charCodeAt(l+g);if(i!==h)break;else 47===i&&(p=g)}var m='';for(g=a+p+1;g<=o;++g)(g===o||47===e.charCodeAt(g))&&(m+=0===m.length?'..':'/..');return 0=r;--c){if(a=e.charCodeAt(c),47===a){if(!u){l=c+1;break}continue}-1==d&&(u=!1,d=c+1),46===a?-1==s?s=c:1!=i&&(i=1):-1!=s&&(i=-1)}return-1==s||-1==d||0==i||1==i&&s==d-1&&s==l+1?-1!=d&&(0==l&&o?n.base=n.name=e.slice(1,d):n.base=n.name=e.slice(l,d)):(0==l&&o?(n.name=e.slice(1,s),n.base=e.slice(1,d)):(n.name=e.slice(l,s),n.base=e.slice(l,d)),n.ext=e.slice(s,d)),0this.container.scrollWidth&&(t=this.container.scrollWidth-this.layout.delta)):n=e.top,this.scrollTo(t,n,!0)}},{key:'add',value:function(e){var t=this,n=this.createView(e);return this.views.append(n),n.onDisplayed=this.afterDisplayed.bind(this),n.onResize=this.afterResized.bind(this),n.on(b.EVENTS.VIEWS.AXIS,function(e){t.updateAxis(e)}),n.display(this.request)}},{key:'append',value:function(e){var t=this,n=this.createView(e);return this.views.append(n),n.onDisplayed=this.afterDisplayed.bind(this),n.onResize=this.afterResized.bind(this),n.on(b.EVENTS.VIEWS.AXIS,function(e){t.updateAxis(e)}),n.display(this.request)}},{key:'prepend',value:function(e){var t=this,n=this.createView(e);return n.on(b.EVENTS.VIEWS.RESIZED,function(e){t.counter(e)}),this.views.prepend(n),n.onDisplayed=this.afterDisplayed.bind(this),n.onResize=this.afterResized.bind(this),n.on(b.EVENTS.VIEWS.AXIS,function(e){t.updateAxis(e)}),n.display(this.request)}},{key:'counter',value:function(e){'vertical'===this.settings.axis?this.scrollBy(0,e.heightDelta,!0):this.scrollBy(e.widthDelta,0,!0)}},{key:'next',value:function(){var e=this.settings.direction,t,n;if(this.views.length){if(this.isPaginated&&'horizontal'===this.settings.axis&&(!e||'ltr'===e))this.scrollLeft=this.container.scrollLeft,n=this.container.scrollLeft+this.container.offsetWidth+this.layout.delta,n<=this.container.scrollWidth?this.scrollBy(this.layout.delta,0,!0):t=this.views.last().section.next();else if(this.isPaginated&&'horizontal'===this.settings.axis&&'rtl'===e)this.scrollLeft=this.container.scrollLeft,n=this.container.scrollLeft,0p&&(h=p,s=h-g);var m=e.layout.count(p,a).pages,f=o(g/a),y=[],v=o(h/a);y=[];for(var b=f,i;b<=v;b++)i=b+1,y.push(i);var k=e.mapping.page(t.contents,t.section.cfiBase,g,h);return{index:d,href:u,pages:y,totalPages:m,mapping:k}});return i}},{key:'paginatedLocation',value:function(){var e=this,t=this.visible(),n=this.container.getBoundingClientRect(),a=0,o=0;this.settings.fullsize&&(a=window.scrollX);var i=t.map(function(t){var r=t.section,s=r.index,d=r.href,u=t.offset().left,c=t.position().left,p=t.width(),g=a+n.left-c+o,h=g+e.layout.width-o,m=e.mapping.page(t.contents,t.section.cfiBase,g,h),f=e.layout.count(p).pages,y=l(g/e.layout.pageWidth),v=[],b=l(h/e.layout.pageWidth);if(0>y&&(y=0,++b),'rtl'===e.settings.direction){var k=y;y=f-b,b=f-k}for(var x=y+1,i;x<=b;x++)i=x,v.push(i);return{index:s,href:d,pages:v,totalPages:f,mapping:m}});return i}},{key:'isVisible',value:function(e,t,n,a){var i=e.position(),o=a||this.bounds();return'horizontal'===this.settings.axis&&i.right>o.left-t&&i.lefto.top-t&&i.top'==e&&'>'||'&'==e&&'&'||'"'==e&&'"'||'&#'+e.charCodeAt()+';'}function m(e,t){if(t(e))return!0;if(e=e.firstChild)do if(m(e,t))return!0;while(e=e.nextSibling)}function f(){}function y(e,t,n){e&&e._inc++;var a=n.namespaceURI;'http://www.w3.org/2000/xmlns/'==a&&(t._nsMap[n.prefix?n.localName:'']=n.value)}function v(e,t,n){e&&e._inc++;var a=n.namespaceURI;'http://www.w3.org/2000/xmlns/'==a&&delete t._nsMap[n.prefix?n.localName:'']}function b(e,t,n){if(e&&e._inc){e._inc++;var a=t.childNodes;if(n)a[a.length++]=n;else{for(var o=t.firstChild,r=0;o;)a[r++]=o,o=o.nextSibling;a.length=r}}}function k(e,t){var n=t.previousSibling,a=t.nextSibling;return n?n.nextSibling=a:e.firstChild=a,a?a.previousSibling=n:e.lastChild=n,b(e.ownerDocument,e),t}function x(e,t,n){var a=t.parentNode;if(a&&a.removeChild(t),t.nodeType===ee){var i=t.firstChild;if(null==i)return t;var o=t.lastChild}else i=o=t;var r=n?n.previousSibling:e.lastChild;i.previousSibling=r,o.nextSibling=n,r?r.nextSibling=i:e.firstChild=i,null==n?e.lastChild=o:n.previousSibling=o;do i.parentNode=e;while(i!==o&&(i=i.nextSibling));return b(e.ownerDocument||e,e),t.nodeType==ee&&(t.firstChild=t.lastChild=null),t}function E(e,t){var n=t.parentNode;if(n){var a=e.lastChild;n.removeChild(t);var a=e.lastChild}var a=e.lastChild;return t.parentNode=e,t.previousSibling=a,t.nextSibling=null,a?a.nextSibling=t:e.firstChild=t,e.lastChild=t,b(e.ownerDocument,e,t),t}function _(){this._nsMap={}}function N(){}function S(){}function w(){}function T(){}function C(){}function R(){}function I(){}function A(){}function L(){}function O(){}function D(){}function P(){}function z(e,t){var n=[],a=9==this.nodeType?this.documentElement:this,i=a.prefix,o=a.namespaceURI;if(o&&null==i){var i=a.lookupPrefix(o);if(null==i)var r=[{namespace:o,prefix:null}]}return B(this,n,e,t,r),n.join('')}function M(e,t,n){var a=e.prefix||'',o=e.namespaceURI;if(!a&&!o)return!1;if('xml'===a&&'http://www.w3.org/XML/1998/namespace'===o||'http://www.w3.org/2000/xmlns/'==o)return!1;for(var r=n.length;r--;){var i=n[r];if(i.prefix==a)return i.namespace!=o}return!0}function B(e,t,n,a,o){if(a){if(e=a(e),!e)return;if('string'==typeof e)return void t.push(e)}switch(e.nodeType){case F:o||(o=[]);var r=o.length,s=e.attributes,l=s.length,d=e.firstChild,u=e.tagName;n=V===e.namespaceURI||n,t.push('<',u);for(var c=0,i;c'),n&&/^script$/i.test(u))for(;d;)d.data?t.push(d.data):B(d,t,n,a,o),d=d.nextSibling;else for(;d;)B(d,t,n,a,o),d=d.nextSibling;t.push('')}else t.push('/>');return;case J:case ee:for(var d=e.firstChild;d;)B(d,t,n,a,o),d=d.nextSibling;return;case H:return t.push(' ',e.name,'="',e.value.replace(/[<&"]/g,h),'"');case X:return t.push(e.data.replace(/[<&]/g,h));case Y:return t.push('');case Q:return t.push('');case $:var f=e.publicId,y=e.systemId;if(t.push('');else if(y&&'.'!=y)t.push(' SYSTEM "',y,'">');else{var v=e.internalSubset;v&&t.push(' [',v,']'),t.push('>')}return;case Z:return t.push('');case G:return t.push('&',e.nodeName,';');default:t.push('??',e.nodeName);}}function j(e,t,n){var a;switch(t.nodeType){case F:a=t.cloneNode(!1),a.ownerDocument=e;case ee:break;case H:n=!0;}if(a||(a=t.cloneNode(!1)),a.ownerDocument=e,a.parentNode=null,n)for(var i=t.firstChild;i;)a.appendChild(j(e,i,n)),i=i.nextSibling;return a}function q(e,t,a){var o=new t.constructor;for(var s in t){var n=t[s];'object'!=typeof n&&n!=o[s]&&(o[s]=n)}switch(t.childNodes&&(o.childNodes=new r),o.ownerDocument=e,o.nodeType){case F:var d=t.attributes,u=o.attributes=new l,c=d.length;u._ownerElement=o;for(var p=0;p=a.end.displayed.total&&(a.atEnd=!0),t.index===this.book.spine.first().index&&1===a.start.displayed.page&&(a.atStart=!0),a}},{key:'destroy',value:function(){this.manager&&this.manager.destroy(),this.book=void 0}},{key:'passEvents',value:function(t){var n=this;N.DOM_EVENTS.forEach(function(a){t.on(a,function(e){return n.triggerViewEvent(e,t)})}),t.on(N.EVENTS.CONTENTS.SELECTED,function(a){return n.triggerSelectedEvent(a,t)})}},{key:'triggerViewEvent',value:function(t,e){this.emit(t.type,t,e)}},{key:'triggerSelectedEvent',value:function(e,t){this.emit(N.EVENTS.RENDITION.SELECTED,e,t)}},{key:'triggerMarkEvent',value:function(e,t,n){this.emit(N.EVENTS.RENDITION.MARK_CLICKED,e,t,n)}},{key:'getRange',value:function(e,t){var n=new g.default(e),a=this.manager.visible().filter(function(e){if(n.spinePos===e.index)return!0});if(a.length)return a[0].contents.range(n,t)}},{key:'adjustImages',value:function(e){if('pre-paginated'===this._layout.name)return new Promise(function(e){e()});var t=e.window.getComputedStyle(e.content,null),n=.95*(e.content.offsetHeight-(parseFloat(t.paddingTop)+parseFloat(t.paddingBottom))),a=parseFloat(t.verticalPadding);return e.addStylesheetRules({img:{"max-width":(this._layout.columnWidth?this._layout.columnWidth-a+'px':'100%')+'!important',"max-height":n+'px!important',"object-fit":'contain',"page-break-inside":'avoid',"break-inside":'avoid',"box-sizing":'border-box'},svg:{"max-width":(this._layout.columnWidth?this._layout.columnWidth-a+'px':'100%')+'!important',"max-height":n+'px!important',"page-break-inside":'avoid',"break-inside":'avoid'}}),new Promise(function(e){setTimeout(function(){e()},1)})}},{key:'getContents',value:function(){return this.manager?this.manager.getContents():[]}},{key:'views',value:function(){var e=this.manager?this.manager.views:void 0;return e||[]}},{key:'handleLinks',value:function(e){var t=this;e&&e.on(N.EVENTS.CONTENTS.LINK_CLICKED,function(e){var n=t.book.path.relative(e);t.display(n)})}},{key:'injectStylesheet',value:function(e){var t=e.createElement('link');t.setAttribute('type','text/css'),t.setAttribute('rel','stylesheet'),t.setAttribute('href',this.settings.stylesheet),e.getElementsByTagName('head')[0].appendChild(t)}},{key:'injectScript',value:function(e){var t=e.createElement('script');t.setAttribute('type','text/javascript'),t.setAttribute('src',this.settings.script),t.textContent=' ',e.getElementsByTagName('head')[0].appendChild(t)}},{key:'injectIdentifier',value:function(e){var t=this.book.packaging.metadata.identifier,n=e.createElement('meta');n.setAttribute('name','dc.relation.ispartof'),t&&n.setAttribute('content',t),e.getElementsByTagName('head')[0].appendChild(n)}}]),e}();(0,l.default)(A.prototype),t.default=A,e.exports=t['default']},function(e,t,n){'use strict';function a(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')}Object.defineProperty(t,'__esModule',{value:!0});var i=function(){function e(e,t){for(var n=0,a;n=t&&r<=n)return e;if(s>t)return e;o=e,i.push(e)}else if(a.horizontal&&'rtl'===a.direction){if(r=c.left,s=c.right,s<=n&&s>=t)return e;if(r=t&&l<=n)return e;if(u>t)return e;o=e,i.push(e)}}),s)return this.findTextStartRange(s,t,n);return this.findTextStartRange(o,t,n)}},{key:'findEnd',value:function(e,t,n){for(var a=this,i=[e],o=e,s,l;i.length;)if(s=i.shift(),l=this.walk(s,function(e){var s,l,u,c,p;if(p=(0,d.nodeBounds)(e),a.horizontal&&'ltr'===a.direction){if(s=r(p.left),l=r(p.right),s>n&&o)return o;if(l>n)return e;o=e,i.push(e)}else if(a.horizontal&&'rtl'===a.direction){if(s=r(a.horizontal?p.left:p.top),l=r(a.horizontal?p.right:p.bottom),ln&&o)return o;if(c>n)return e;o=e,i.push(e)}}),l)return this.findTextEndRange(l,t,n);return this.findTextEndRange(o,t,n)}},{key:'findTextStartRange',value:function(e,t,n){for(var a=this.splitTextNodeIntoRanges(e),o=0,i,r,s,l,d;o=t)return i;}else if(this.horizontal&&'rtl'===this.direction){if(d=r.right,d<=n)return i;}else if(l=r.top,l>=t)return i;return a[0]}},{key:'findTextEndRange',value:function(e,t,n){for(var a=this.splitTextNodeIntoRanges(e),o=0,i,r,s,l,d,u,c;on&&i)return i;if(d>n)return r}else if(this.horizontal&&'rtl'===this.direction){if(l=s.left,d=s.right,dn&&i)return i;if(c>n)return r}i=r}return a[a.length-1]}},{key:'splitTextNodeIntoRanges',value:function(e,t){var n=[],a=e.textContent||'',i=a.trim(),o=e.ownerDocument,r=t||' ',s=i.indexOf(r),l;if(-1===s||e.nodeType!=Node.TEXT_NODE)return l=o.createRange(),l.selectNodeContents(e),[l];for(l=o.createRange(),l.setStart(e,0),l.setEnd(e,s),n.push(l),l=!1;-1!=s;)s=i.indexOf(r,s+1),0=t||0>n||y&&a>=x}function p(){var e=o();return c(e)?g(e):void(_=setTimeout(p,u(e)))}function g(e){return(_=void 0,v&&b)?l(e):(b=k=void 0,E)}function h(){var e=o(),n=c(e);if(b=arguments,k=this,N=e,n){if(void 0===_)return d(N);if(y)return _=setTimeout(p,t),l(N)}return void 0===_&&(_=setTimeout(p,t)),E}var m=0,f=!1,y=!1,v=!0,b,k,x,E,_,N;if('function'!=typeof e)throw new TypeError('Expected a function');return t=r(t)||0,a(n)&&(f=!!n.leading,y='maxWait'in n,x=y?s(r(n.maxWait)||0,t):x,v='trailing'in n?!!n.trailing:v),h.cancel=function(){void 0!==_&&clearTimeout(_),m=0,b=N=k=_=void 0},h.flush=function(){return void 0===_?E:g(o())},h}},function(e,t,n){var a=n(62),i='object'==typeof self&&self&&self.Object===Object&&self,o=a||i||Function('return this')();e.exports=o},function(e,t,n){var a=n(22),i=a.Symbol;e.exports=i},function(e,t,n){'use strict';function i(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')}function r(e,t){if(!e)throw new ReferenceError('this hasn\'t been initialised - super() hasn\'t been called');return t&&('object'==typeof t||'function'==typeof t)?t:e}function s(e,t){if('function'!=typeof t&&null!==t)throw new TypeError('Super expression must either be null or a function, not '+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,'__esModule',{value:!0});var d='function'==typeof Symbol&&'symbol'==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&'function'==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?'symbol':typeof e},u=function(){function e(e,t){for(var n=0,a;n=h&&(o&&d?m():f()),0>c-r&&(o&&d?f():m());var y=i.map(function(e){return e.displayed});return i.length?Promise.all(y).then(function(){if('pre-paginated'===n.layout.name&&n.layout.props.spread)return n.check()}).then(function(){return n.update(r)},function(e){return e}):(this.q.enqueue(function(){this.update()}.bind(this)),a.resolve(!1),a.promise)}},{key:'trim',value:function(){for(var e=new p.defer,t=this.views.displayed(),n=t[0],a=t[t.length-1],o=this.views.indexOf(n),r=this.views.indexOf(a),s=this.views.slice(0,o),l=this.views.slice(r+1),d=0;darguments.length||'string'!=typeof t?(d=n,n=t,t=null):d=arguments[2],null==t?(o=l=!0,s=!1):(o=r.call(t,'c'),s=r.call(t,'e'),l=r.call(t,'w')),u={value:n,configurable:o,enumerable:s,writable:l},d?a(i(d),u):u},s.gs=function(t,n,s){var l,d,u,p;return'string'==typeof t?u=arguments[3]:(u=s,s=n,n=t,t=null),null==n?n=void 0:o(n)?null==s?s=void 0:!o(s)&&(u=s,s=void 0):(u=n,n=s=void 0),null==t?(l=!0,d=!1):(l=r.call(t,'c'),d=r.call(t,'e')),p={get:n,set:s,configurable:l,enumerable:d},u?a(i(u),p):p}},function(e,t,n){'use strict';e.exports=n(29)()?Object.assign:n(30)},function(e){'use strict';e.exports=function(){var e=Object.assign,t;return!('function'!=typeof e)&&(t={foo:'raz'},e(t,{bar:'dwa'},{trzy:'trzy'}),'razdwatrzy'===t.foo+t.bar+t.trzy)}},function(e,t,n){'use strict';var a=n(31),o=n(35);e.exports=function(e,t){var n=s(arguments.length,2),r,l,i;for(e=Object(o(e)),i=function(n){try{e[n]=t[n]}catch(t){r||(r=t)}},l=1;l=t+n||t?new java.lang.String(e,t,n)+'':e}function d(e,t){e.currentElement?e.currentElement.appendChild(t):e.doc.appendChild(t)}a.prototype.parseFromString=function(e,t){var n=this.options,a=new u,r=n.domBuilder||new o,s=n.errorHandler,l=n.locator,d=n.xmlns||{},c={lt:'<',gt:'>',amp:'&',quot:'"',apos:'\''};return l&&r.setDocumentLocator(l),a.errorHandler=i(s,r,l),a.domBuilder=n.domBuilder||r,/\/x?html?$/.test(t)&&(c.nbsp='\xA0',c.copy='\xA9',d['']='http://www.w3.org/1999/xhtml'),d.xml=d.xml||'http://www.w3.org/XML/1998/namespace',e?a.parse(e,d,c):a.errorHandler.error('invalid doc source'),r.doc},o.prototype={startDocument:function(){this.doc=new c().createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(e,t,n,a){var o=this.doc,s=o.createElementNS(e,n||t),l=a.length;d(this,s),this.currentElement=s,this.locator&&r(this.locator,s);for(var u=0;u>10),a=56320+(1023&e);return t(n,a)}return t(e)}function y(e){var t=e.slice(1,-1);return t in n?n[t]:'#'===t.charAt(0)?f(parseInt(t.substr(1).replace('x','0x'))):(m.error('entity not found:'+e),e)}function v(t){if(t>w){var n=e.substring(w,t).replace(/&#?\w+;/g,y);_&&b(w),c.characters(n,0,t-w),w=t}}function b(t,n){for(;t>=x&&(n=E.exec(e));)k=n.index,x=k+n[0].length,_.lineNumber++;_.columnNumber=t-k+1}for(var k=0,x=0,E=/.*(?:\r\n?|\n)|.*$/g,_=c.locator,N=[{currentNSMap:t}],S={},w=0;;){try{var T=e.indexOf('<',w);if(0>T){if(!e.substr(w).match(/^\s*$/)){var C=c.doc,R=C.createTextNode(e.substr(w));C.appendChild(R),c.currentElement=R}return}switch(T>w&&v(T),e.charAt(T+1)){case'/':var I=e.indexOf('>',T+3),A=e.substring(T+2,I),L=N.pop();0>I?(A=e.substring(T+2).replace(/[\s<].*/,''),m.error('end tag name: '+A+' is not complete:'+L.tagName),I=T+1+A.length):A.match(/\sw?w=I:v(s(T,w)+1)}}function o(e,n){return n.lineNumber=e.lineNumber,n.columnNumber=e.columnNumber,n}function r(e,t,n,a,i,o){for(var r=++t,l=b,s,d;;){var u=e.charAt(r);switch(u){case'=':if(l==k)s=e.slice(t,r),l=E;else if(l==x)l=E;else throw new Error('attribute equal must after attrName');break;case'\'':case'"':if(l==E||l==k){if(l==k&&(o.warning('attribute value must after "="'),s=e.slice(t,r)),t=r+1,r=e.indexOf(u,t),0=u)switch(l){case b:n.setTagName(e.slice(t,r)),l=S;break;case k:s=e.slice(t,r),l=x;break;case _:var d=e.slice(t,r).replace(/&#?\w+;/g,i);o.warning('attribute "'+d+'" missed quot(")!!'),n.add(s,d,t);case N:l=S;}else switch(l){case x:n.tagName;'http://www.w3.org/1999/xhtml'===a['']&&s.match(/^(?:disabled|checked|selected)$/i)||o.warning('attribute "'+s+'" missed value!! "'+s+'" instead2!!'),n.add(s,s,t),t=r,l=k;break;case N:o.warning('attribute space is required"'+s+'"!!');case S:l=k,t=r;break;case E:l=_,t=r;break;case w:throw new Error('elements closed character \'/\' and \'>\' must be connected to');}}r++}}function l(e,t,n){for(var o=e.tagName,r=null,s=e.length;s--;){var i=e[s],a=i.qName,l=i.value,d=a.indexOf(':');if(0',t),r=e.substring(t+1,o);if(/[&<]/.test(r))return /^script$/i.test(n)?(i.characters(r,0,r.length),o):(r=r.replace(/&#?\w+;/g,a),i.characters(r,0,r.length),o)}return t+1}function u(e,t,n,a){var i=a[n];return null==i&&(i=e.lastIndexOf(''),i',t+4);return o>t?(n.comment(e,t+4,o-t-4),o+3):(a.error('Unclosed comment'),-1)}return-1;default:if('CDATA['==e.substr(t+3,6)){var o=e.indexOf(']]>',t+9);return n.startCDATA(),n.characters(e,t+9,o-t-9),n.endCDATA(),o+3}var r=m(e,t),s=r.length;if(1',t);if(a){var i=e.substring(t,a).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);if(i){i[0].length;return n.processingInstruction(i[1],i[2]),a+2}return-1}return-1}function h(){}function i(e,t){return e.__proto__=t,e}function m(e,t){var n=[],a=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g,i;for(a.lastIndex=t,a.exec(e);i=a.exec(e);)if(n.push(i),i[1])return n}var f=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,y=new RegExp('[\\-\\.0-9'+f.source.slice(1,-1)+'\\u00B7\\u0300-\\u036F\\u203F-\\u2040]'),v=new RegExp('^'+f.source+y.source+'*(?::'+f.source+y.source+'*)?$'),b=0,k=1,x=2,E=3,_=4,N=5,S=6,w=7;n.prototype={parse:function(e,t,n){var i=this.domBuilder;i.startDocument(),c(t,t={}),a(e,t,n,i,this.errorHandler),i.endDocument()}},h.prototype={setTagName:function(e){if(!v.test(e))throw new Error('invalid tagName:'+e);this.tagName=e},add:function(e,t,n){if(!v.test(e))throw new Error('invalid attribute:'+e);this[this.length++]={qName:e,value:t,offset:n}},length:0,getLocalName:function(e){return this[e].localName},getLocator:function(e){return this[e].locator},getQName:function(e){return this[e].qName},getURI:function(e){return this[e].uri},getValue:function(e){return this[e].value}},i({},i.prototype)instanceof i||(i=function(e,t){function n(){}for(t in n.prototype=t,n=new n,e)n[t]=e[t];return n}),t.XMLReader=n},function(e,t,n){'use strict';function a(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')}Object.defineProperty(t,'__esModule',{value:!0});var r=function(){function e(e,t){for(var n=0,a;nn&&(r+=n,i=n);i=n)r+=n-i,i=n;else{i+=o,d.endContainer=e,d.endOffset=i;var s=new c.default(d,t).toString();a.push(s),r=0}u=e}.bind(this)),d&&d.startContainer&&u){d.endContainer=u,d.endOffset=u.length;var p=new c.default(d,t).toString();a.push(p),r=0}return a}},{key:'locationFromCfi',value:function(e){var t;return(c.default.prototype.isCfiString(e)&&(e=new c.default(e)),0===this._locations.length)?-1:(t=(0,s.locationOf)(e,this._locations,this.epubcfi.compare),t>this.total?this.total:t)}},{key:'percentageFromCfi',value:function(e){if(0===this._locations.length)return null;var t=this.locationFromCfi(e);return this.percentageFromLocation(t)}},{key:'percentageFromLocation',value:function(e){return e&&this.total?e/this.total:0}},{key:'cfiFromLocation',value:function(e){var t=-1;return'number'!=typeof e&&(e=parseInt(e)),0<=e&&e=this._minSpreadWidth?2:1,'reflowable'!==this.name||'paginated'!==this._flow||0<=n||(i=0==s%2?s:s-1),'pre-paginated'===this.name&&(i=0),1=e.left&&t.top>=e.top&&t.bottom<=e.bottom}var u='function'==typeof Symbol&&'symbol'==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&'function'==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?'symbol':typeof e};Object.defineProperty(t,'__esModule',{value:!0}),t.Underline=t.Highlight=t.Mark=t.Pane=void 0;var c=function e(t,n,a){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(i===void 0){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,a)}if('value'in i)return i.value;var r=i.get;return void 0===r?void 0:r.call(a)},p=function(){function e(e,t){for(var n=0,a;nn&&r>t}var s=t.getBoundingClientRect(),r=e.getBoundingClientRect();if(!o(r,n,a))return!1;for(var l=e.getClientRects(),d=0,i=l.length;d(e/=0.5)?0.5*s(e,5):0.5*(s(e-2,5)+2)},easeInCubic:function(e){return s(e,3)}},m=function(){function e(t,n){o(this,e),this.settings=(0,u.extend)({duration:80,minVelocity:0.2,minDistance:10,easing:h.easeInCubic},n||{}),this.supportsTouch=this.supportsTouch(),this.supportsTouch&&this.setup(t)}return d(e,[{key:'setup',value:function(e){this.manager=e,this.layout=this.manager.layout,this.fullsize=this.manager.settings.fullsize,this.fullsize?(this.element=this.manager.stage.element,this.scroller=window,this.disableScroll()):(this.element=this.manager.stage.container,this.scroller=this.element,this.element.style.WebkitOverflowScrolling='touch'),this.manager.settings.offset=this.layout.width,this.manager.settings.afterScrolledTimeout=2*this.settings.duration,this.isVertical='vertical'===this.manager.settings.axis,!this.manager.isPaginated||this.isVertical||(this.touchCanceler=!1,this.resizeCanceler=!1,this.snapping=!1,this.scrollLeft,this.scrollTop,this.startTouchX=void 0,this.startTouchY=void 0,this.startTime=void 0,this.endTouchX=void 0,this.endTouchY=void 0,this.endTime=void 0,this.addListeners())}},{key:'supportsTouch',value:function(){return'ontouchstart'in window||window.DocumentTouch&&document instanceof DocumentTouch}},{key:'disableScroll',value:function(){this.element.style.overflow='hidden'}},{key:'enableScroll',value:function(){this.element.style.overflow=''}},{key:'addListeners',value:function(){this._onResize=this.onResize.bind(this),window.addEventListener('resize',this._onResize),this._onScroll=this.onScroll.bind(this),this.scroller.addEventListener('scroll',this._onScroll),this._onTouchStart=this.onTouchStart.bind(this),this.scroller.addEventListener('touchstart',this._onTouchStart,{passive:!0}),this.on('touchstart',this._onTouchStart),this._onTouchMove=this.onTouchMove.bind(this),this.scroller.addEventListener('touchmove',this._onTouchMove,{passive:!0}),this.on('touchmove',this._onTouchMove),this._onTouchEnd=this.onTouchEnd.bind(this),this.scroller.addEventListener('touchend',this._onTouchEnd,{passive:!0}),this.on('touchend',this._onTouchEnd),this._afterDisplayed=this.afterDisplayed.bind(this),this.manager.on(c.EVENTS.MANAGERS.ADDED,this._afterDisplayed)}},{key:'removeListeners',value:function(){window.removeEventListener('resize',this._onResize),this._onResize=void 0,this.scroller.removeEventListener('scroll',this._onScroll),this._onScroll=void 0,this.scroller.removeEventListener('touchstart',this._onTouchStart,{passive:!0}),this.off('touchstart',this._onTouchStart),this._onTouchStart=void 0,this.scroller.removeEventListener('touchmove',this._onTouchMove,{passive:!0}),this.off('touchmove',this._onTouchMove),this._onTouchMove=void 0,this.scroller.removeEventListener('touchend',this._onTouchEnd,{passive:!0}),this.off('touchend',this._onTouchEnd),this._onTouchEnd=void 0,this.manager.off(c.EVENTS.MANAGERS.ADDED,this._afterDisplayed),this._afterDisplayed=void 0}},{key:'afterDisplayed',value:function(e){var t=this,n=e.contents;['touchstart','touchmove','touchend'].forEach(function(a){n.on(a,function(e){return t.triggerViewEvent(e,n)})})}},{key:'triggerViewEvent',value:function(t,e){this.emit(t.type,t,e)}},{key:'onScroll',value:function(){this.scrollLeft=this.fullsize?window.scrollX:this.scroller.scrollLeft,this.scrollTop=this.fullsize?window.scrollY:this.scroller.scrollTop}},{key:'onResize',value:function(){this.resizeCanceler=!0}},{key:'onTouchStart',value:function(t){var e=t.touches[0],n=e.screenX,a=e.screenY;this.fullsize&&this.enableScroll(),this.touchCanceler=!0,this.startTouchX||(this.startTouchX=n,this.startTouchY=a,this.startTime=this.now()),this.endTouchX=n,this.endTouchY=a,this.endTime=this.now()}},{key:'onTouchMove',value:function(t){var e=t.touches[0],n=e.screenX,i=e.screenY,o=a(i-this.endTouchY);this.touchCanceler=!0,!this.fullsize&&10>o&&(this.element.scrollLeft-=n-this.endTouchX),this.endTouchX=n,this.endTouchY=i,this.endTime=this.now()}},{key:'onTouchEnd',value:function(){this.fullsize&&this.disableScroll(),this.touchCanceler=!1;var e=this.wasSwiped();0===e?this.snap():this.snap(e),this.startTouchX=void 0,this.startTouchY=void 0,this.startTime=void 0,this.endTouchX=void 0,this.endTouchY=void 0,this.endTime=void 0}},{key:'wasSwiped',value:function(){var e=this.layout.pageWidth*this.layout.divisor,t=this.endTouchX-this.startTouchX,n=a(t),i=this.endTime-this.startTime,o=t/i,r=this.settings.minVelocity;return n<=this.settings.minDistance||n>=e?0:o>r?-1:o<-r?1:void 0}},{key:'needsSnap',value:function(){var e=this.scrollLeft,t=this.layout.pageWidth*this.layout.divisor;return 0!=e%t}},{key:'snap',value:function(){var e=0d?(window.requestAnimationFrame(t.bind(this)),this.scrollTo(a+(e-a)*d,0)):(this.scrollTo(e,0),this.snapping=!1,n.resolve()))}var n=new u.defer,a=this.scrollLeft,o=this.now(),r=this.settings.duration,s=this.settings.easing;return this.snapping=!0,t.call(this),n.promise}},{key:'scrollTo',value:function(){var e=0=n.oldVersion&&e.createObjectStore(j)}catch(e){if('ConstraintError'===e.name)console.warn('The database "'+t.name+'" has been upgraded from version '+n.oldVersion+' to version '+n.newVersion+', but the storage "'+t.storeName+'" already exists.');else throw e}}),o.onerror=function(t){t.preventDefault(),a(o.error)},o.onsuccess=function(){n(o.result),p(t)}})}function m(e){return h(e,!1)}function f(e){return h(e,!0)}function y(e,t){if(!e.db)return!0;var n=!e.db.objectStoreNames.contains(e.storeName),a=e.versione.db.version;if(a&&(e.version!==t&&console.warn('The database "'+e.name+'" can\'t be downgraded from version '+e.db.version+' to version '+e.version+'.'),e.version=e.db.version),i||n){if(n){var o=e.db.version+1;o>e.version&&(e.version=o)}return!0}return!1}function v(t){return new B(function(n,e){var a=new FileReader;a.onerror=e,a.onloadend=function(a){var e=btoa(a.target.result||'');n({__local_forage_encoded_blob:!0,data:e,type:t.type})},a.readAsBinaryString(t)})}function b(e){var t=l(atob(e.data));return a([t],{type:e.type})}function k(e){return e&&e.__local_forage_encoded_blob}function x(e){var t=this,n=t._initReady().then(function(){var e=U[t._dbInfo.name];if(e&&e.dbReady)return e.dbReady});return o(n,e,e),n}function E(e){c(e);for(var t=U[e.name],n=t.forages,a=0,i;a>4,u[a++]=(15&r)<<4|s>>2,u[a++]=(3&s)<<6|63&l;return d}function w(e){var t=new Uint8Array(e),n='',a;for(a=0;a>2],n+=X[(3&t[a])<<4|t[a+1]>>4],n+=X[(15&t[a+1])<<2|t[a+2]>>6],n+=X[63&t[a+2]];return 2==t.length%3?n=n.substring(0,n.length-1)+'=':1==t.length%3&&(n=n.substring(0,n.length-2)+'=='),n}function T(e,t,n,a){e.executeSql('CREATE TABLE IF NOT EXISTS '+t.storeName+' (id INTEGER PRIMARY KEY, key unique, value)',[],n,a)}function C(e,n,a,i,o,r){e.executeSql(a,i,o,function(e,s){s.code===s.SYNTAX_ERR?e.executeSql('SELECT name FROM sqlite_master WHERE type=\'table\' AND name = ?',[n.storeName],function(e,t){t.rows.length?r(e,s):T(e,n,function(){e.executeSql(a,i,o,r)},r)},r):r(e,s)},r)}function R(e,t,n,a){var o=this;e=r(e);var s=new B(function(i,r){o.ready().then(function(){void 0===t&&(t=null);var s=t,l=o._dbInfo;l.serializer.serialize(t,function(d,t){t?r(t):l.db.transaction(function(n){C(n,l,'INSERT OR REPLACE INTO '+l.storeName+' (key, value) VALUES (?, ?)',[e,d],function(){i(s)},function(e,t){r(t)})},function(t){if(t.code===t.QUOTA_ERR){if(0 \'__WebKitDatabaseInfoTable__\'',[],function(a,t){for(var o=[],r=0;re?void t(null):void n.ready().then(function(){_(n._dbInfo,W,function(i,o){if(i)return a(i);try{var r=o.objectStore(n._dbInfo.storeName),s=!1,l=r.openCursor();l.onsuccess=function(){var n=l.result;return n?void(0===e?t(n.key):s?t(n.key):(s=!0,n.advance(e))):void t(null)},l.onerror=function(){a(l.error)}}catch(t){a(t)}})})['catch'](a)});return i(a,t),a},keys:function(e){var t=this,n=new B(function(e,n){t.ready().then(function(){_(t._dbInfo,W,function(a,i){if(a)return n(a);try{var o=i.objectStore(t._dbInfo.storeName),r=o.openCursor(),s=[];r.onsuccess=function(){var t=r.result;return t?void(s.push(t.key),t['continue']()):void e(s)},r.onerror=function(){n(r.error)}}catch(t){n(t)}})})['catch'](n)});return i(n,e),n},dropInstance:function(e,t){t=s.apply(this,arguments);var n=this.config();e='function'!=typeof e&&e||{},e.name||(e.name=e.name||n.name,e.storeName=e.storeName||n.storeName);var a=this,o;if(!e.name)o=B.reject('Invalid arguments');else{var r=e.name===n.name&&a._dbInfo.db,l=r?B.resolve(a._dbInfo.db):m(e).then(function(t){var n=U[e.name],a=n.forages;n.db=t;for(var o=0;ot[0]?1:0}),e._entries&&(e._entries={});for(var n=0;nn/2.5&&(p=n/2.5,pop_content.style.maxHeight=p+"px"),popRect.height+l>=n-25?(c.style.top=l-popRect.height+"px",c.classList.add("above")):c.classList.remove("above"),k-popRect.width<=0?(c.style.left=k+"px",c.classList.add("left")):c.classList.remove("left"),k+popRect.width/2>=o?(c.style.left=k-300+"px",popRect=c.getBoundingClientRect(),c.style.left=k-popRect.width+"px",popRect.height+l>=n-25?(c.style.top=l-popRect.height+"px",c.classList.add("above")):c.classList.remove("above"),c.classList.add("right")):c.classList.remove("right")}function d(){f[i].classList.add("on")}function e(){f[i].classList.remove("on")}function g(){setTimeout(function(){f[i].classList.remove("show")},100)}var h,i,j,k,l,m;"noteref"==a.getAttribute("epub:type")&&(h=a.getAttribute("href"),i=h.replace("#",""),j=b.render.document.getElementById(i),a.addEventListener("mouseover",c,!1),a.addEventListener("mouseout",g,!1))}),a&&a()},EPUBJS.Hooks.register("beforeChapterDisplay").mathml=function(a,b){if(b.currentChapter.manifestProperties.indexOf("mathml")!==-1){b.render.iframe.contentWindow.mathmlCallback=a;var c=document.createElement("script");c.type="text/x-mathjax-config",c.innerHTML=' MathJax.Hub.Register.StartupHook("End",function () { window.mathmlCallback(); }); MathJax.Hub.Config({jax: ["input/TeX","input/MathML","output/SVG"],extensions: ["tex2jax.js","mml2jax.js","MathEvents.js"],TeX: {extensions: ["noErrors.js","noUndefined.js","autoload-all.js"]},MathMenu: {showRenderer: false},menuSettings: {zoom: "Click"},messageStyle: "none"}); ',b.doc.body.appendChild(c),EPUBJS.core.addScript("http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML",null,b.doc.head)}else a&&a()},EPUBJS.Hooks.register("beforeChapterDisplay").smartimages=function(a,b){var c=b.contents.querySelectorAll("img"),d=Array.prototype.slice.call(c),e=b.height;if("reflowable"!=b.layoutSettings.layout)return void a();d.forEach(function(a){var c=function(){var c,d=a.getBoundingClientRect(),f=d.height,g=d.top,h=a.getAttribute("data-height"),i=h||f,j=Number(getComputedStyle(a,"").fontSize.match(/(\d*(\.\d*)?)px/)[1]),k=j?j/2:0;e=b.contents.clientHeight,g<0&&(g=0),a.style.maxWidth="100%",i+g>=e?(ge&&(a.style.maxHeight=e+"px",a.style.width="auto",d=a.getBoundingClientRect(),i=d.height),a.style.display="block",a.style.WebkitColumnBreakBefore="always",a.style.breakBefore="column"),a.setAttribute("data-height",c)):(a.style.removeProperty("max-height"),a.style.removeProperty("margin-top"))},d=function(){b.off("renderer:resized",c),b.off("renderer:chapterUnload",this)};a.addEventListener("load",c,!1),b.on("renderer:resized",c),b.on("renderer:chapterUnload",d),c()}),a&&a()},EPUBJS.Hooks.register("beforeChapterDisplay").transculsions=function(a,b){var c=b.contents.querySelectorAll("[transclusion]");Array.prototype.slice.call(c).forEach(function(a){function c(){j=g,k=h,j>chapter.colWidth&&(d=chapter.colWidth/j,j=chapter.colWidth,k*=d),f.width=j,f.height=k}var d,e=a.getAttribute("ref"),f=document.createElement("iframe"),g=a.getAttribute("width"),h=a.getAttribute("height"),i=a.parentNode,j=g,k=h;c(),b.listenUntil("renderer:resized","renderer:chapterUnloaded",c),f.src=e,i.replaceChild(f,a)}),a&&a()}; \ No newline at end of file diff --git a/static/epub.js/js/hooks.min.map b/static/epub.js/js/hooks.min.map deleted file mode 100644 index 5da22bee..00000000 --- a/static/epub.js/js/hooks.min.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"hooks.min.js","sources":["../../hooks/default/endnotes.js","../../hooks/default/mathml.js","../../hooks/default/smartimages.js","../../hooks/default/transculsions.js"],"names":["EPUBJS","Hooks","register","endnotes","callback","renderer","notes","contents","querySelectorAll","items","Array","prototype","slice","call","attr","type","folder","core","location","pathname","popups","cssPath","addCss","render","document","head","forEach","item","showPop","pop","itemRect","iheight","height","iwidth","width","maxHeight","txt","el","cloneNode","querySelector","id","createElement","setAttribute","pop_content","appendChild","body","addEventListener","onPop","offPop","on","hidePop","this","getBoundingClientRect","left","top","classList","add","popRect","style","remove","setTimeout","href","epubType","getAttribute","replace","getElementById","mathml","currentChapter","manifestProperties","indexOf","iframe","contentWindow","mathmlCallback","s","innerHTML","doc","addScript","smartimages","images","layoutSettings","layout","size","newHeight","rectHeight","oHeight","fontSize","Number","getComputedStyle","match","fontAdjust","clientHeight","display","removeProperty","unloaded","off","transculsions","trans","orginal_width","orginal_height","chapter","colWidth","ratio","src","parent","parentNode","listenUntil","replaceChild"],"mappings":"AAAAA,OAAOC,MAAMC,SAAS,wBAAwBC,SAAW,SAASC,EAAUC,GAE1E,GAAIC,GAAQD,EAASE,SAASC,iBAAiB,WAC9CC,EAAQC,MAAMC,UAAUC,MAAMC,KAAKP,GACnCQ,EAAO,YACPC,EAAO,UACPC,EAAShB,OAAOiB,KAAKD,OAAOE,SAASC,UAErCC,GADWJ,EAAShB,OAAOqB,SAAYL,KAGxChB,QAAOiB,KAAKK,OAAOtB,OAAOqB,QAAU,aAAa,EAAOhB,EAASkB,OAAOC,SAASC,MAGjFhB,EAAMiB,QAAQ,SAASC,GAqBtB,QAASC,KACR,GAICC,GAEAC,EALAC,EAAU1B,EAAS2B,OACnBC,EAAS5B,EAAS6B,MAGlBC,EAAY,GAGTC,KACHP,EAAMQ,EAAGC,WAAU,GACnBF,EAAMP,EAAIU,cAAc,MAKrBnB,EAAOoB,KACVpB,EAAOoB,GAAMhB,SAASiB,cAAc,OACpCrB,EAAOoB,GAAIE,aAAa,QAAS,SAEjCC,YAAcnB,SAASiB,cAAc,OAErCrB,EAAOoB,GAAII,YAAYD,aAEvBA,YAAYC,YAAYR,GACxBO,YAAYD,aAAa,QAAS,eAElCrC,EAASkB,OAAOC,SAASqB,KAAKD,YAAYxB,EAAOoB,IAGjDpB,EAAOoB,GAAIM,iBAAiB,YAAaC,GAAO,GAChD3B,EAAOoB,GAAIM,iBAAiB,WAAYE,GAAQ,GAKhD3C,EAAS4C,GAAG,uBAAwBC,EAASC,MAC7C9C,EAAS4C,GAAG,uBAAwBD,EAAQG,OAI7CtB,EAAMT,EAAOoB,GAIbV,EAAWH,EAAKyB,wBAChBC,EAAOvB,EAASuB,KAChBC,EAAMxB,EAASwB,IAGfzB,EAAI0B,UAAUC,IAAI,QAGlBC,Q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/static/epub.js/js/hooks/extensions/highlight.js deleted file mode 100644 index 1dd1c671..00000000 --- a/static/epub.js/js/hooks/extensions/highlight.js +++ /dev/null @@ -1,14 +0,0 @@ -EPUBJS.Hooks.register("beforeChapterDisplay").highlight = function(callback, renderer){ - - // EPUBJS.core.addScript("js/libs/jquery.highlight.js", null, renderer.doc.head); - - var s = document.createElement("style"); - s.innerHTML =".highlight { background: yellow; font-weight: normal; }"; - - renderer.render.document.head.appendChild(s); - - if(callback) callback(); - -} - - diff --git a/static/epub.js/js/libs/jquery.min.js b/static/epub.js/js/libs/jquery.min.js deleted file mode 100644 index 4024b662..00000000 --- a/static/epub.js/js/libs/jquery.min.js +++ /dev/null @@ -1,4 +0,0 @@ -/*! jQuery v2.2.4 | (c) jQuery Foundation | jquery.org/license */ -!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=a.document,e=c.slice,f=c.concat,g=c.push,h=c.indexOf,i={},j=i.toString,k=i.hasOwnProperty,l={},m="2.2.4",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return e.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:e.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a){return n.each(this,a)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(e.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor()},push:g,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(n.isPlainObject(d)||(e=n.isArray(d)))?(e?(e=!1,f=c&&n.isArray(c)?c:[]):f=c&&n.isPlainObject(c)?c:{},g[b]=n.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray,isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){var b=a&&a.toString();return!n.isArray(a)&&b-parseFloat(b)+1>=0},isPlainObject:function(a){var b;if("object"!==n.type(a)||a.nodeType||n.isWindow(a))return!1;if(a.constructor&&!k.call(a,"constructor")&&!k.call(a.constructor.prototype||{},"isPrototypeOf"))return!1;for(b in a);return void 0===b||k.call(a,b)},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?i[j.call(a)]||"object":typeof a},globalEval:function(a){var b,c=eval;a=n.trim(a),a&&(1===a.indexOf("use strict")?(b=d.createElement("script"),b.text=a,d.head.appendChild(b).parentNode.removeChild(b)):c(a))},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b){var c,d=0;if(s(a)){for(c=a.length;c>d;d++)if(b.call(a[d],d,a[d])===!1)break}else for(d in a)if(b.call(a[d],d,a[d])===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):g.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:h.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,e,g=0,h=[];if(s(a))for(d=a.length;d>g;g++)e=b(a[g],g,c),null!=e&&h.push(e);else for(g in a)e=b(a[g],g,c),null!=e&&h.push(e);return f.apply([],h)},guid:1,proxy:function(a,b){var c,d,f;return"string"==typeof b&&(c=a[b],b=a,a=c),n.isFunction(a)?(d=e.call(arguments,2),f=function(){return a.apply(b||this,d.concat(e.call(arguments)))},f.guid=a.guid=a.guid||n.guid++,f):void 0},now:Date.now,support:l}),"function"==typeof Symbol&&(n.fn[Symbol.iterator]=c[Symbol.iterator]),n.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(a,b){i["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=!!a&&"length"in a&&a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=ga(),z=ga(),A=ga(),B=function(a,b){return a===b&&(l=!0),0},C=1<<31,D={}.hasOwnProperty,E=[],F=E.pop,G=E.push,H=E.push,I=E.slice,J=function(a,b){for(var c=0,d=a.length;d>c;c++)if(a[c]===b)return c;return-1},K="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",L="[\\x20\\t\\r\\n\\f]",M="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",N="\\["+L+"*("+M+")(?:"+L+"*([*^$|!~]?=)"+L+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+M+"))|)"+L+"*\\]",O=":("+M+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+N+")*)|.*)\\)|)",P=new RegExp(L+"+","g"),Q=new RegExp("^"+L+"+|((?:^|[^\\\\])(?:\\\\.)*)"+L+"+$","g"),R=new RegExp("^"+L+"*,"+L+"*"),S=new RegExp("^"+L+"*([>+~]|"+L+")"+L+"*"),T=new RegExp("="+L+"*([^\\]'\"]*?)"+L+"*\\]","g"),U=new RegExp(O),V=new RegExp("^"+M+"$"),W={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),TAG:new RegExp("^("+M+"|[*])"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},X=/^(?:input|select|textarea|button)$/i,Y=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,$=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,_=/[+~]/,aa=/'|\\/g,ba=new RegExp("\\\\([\\da-f]{1,6}"+L+"?|("+L+")|.)","ig"),ca=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},da=function(){m()};try{H.apply(E=I.call(v.childNodes),v.childNodes),E[v.childNodes.length].nodeType}catch(ea){H={apply:E.length?function(a,b){G.apply(a,I.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fa(a,b,d,e){var f,h,j,k,l,o,r,s,w=b&&b.ownerDocument,x=b?b.nodeType:9;if(d=d||[],"string"!=typeof a||!a||1!==x&&9!==x&&11!==x)return d;if(!e&&((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,p)){if(11!==x&&(o=$.exec(a)))if(f=o[1]){if(9===x){if(!(j=b.getElementById(f)))return d;if(j.id===f)return d.push(j),d}else if(w&&(j=w.getElementById(f))&&t(b,j)&&j.id===f)return d.push(j),d}else{if(o[2])return H.apply(d,b.getElementsByTagName(a)),d;if((f=o[3])&&c.getElementsByClassName&&b.getElementsByClassName)return H.apply(d,b.getElementsByClassName(f)),d}if(c.qsa&&!A[a+" "]&&(!q||!q.test(a))){if(1!==x)w=b,s=a;else if("object"!==b.nodeName.toLowerCase()){(k=b.getAttribute("id"))?k=k.replace(aa,"\\$&"):b.setAttribute("id",k=u),r=g(a),h=r.length,l=V.test(k)?"#"+k:"[id='"+k+"']";while(h--)r[h]=l+" "+qa(r[h]);s=r.join(","),w=_.test(a)&&oa(b.parentNode)||b}if(s)try{return H.apply(d,w.querySelectorAll(s)),d}catch(y){}finally{k===u&&b.removeAttribute("id")}}}return i(a.replace(Q,"$1"),b,d,e)}function ga(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ha(a){return a[u]=!0,a}function ia(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ja(a,b){var c=a.split("|"),e=c.length;while(e--)d.attrHandle[c[e]]=b}function ka(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||C)-(~a.sourceIndex||C);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function la(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function ma(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function na(a){return ha(function(b){return b=+b,ha(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function oa(a){return a&&"undefined"!=typeof a.getElementsByTagName&&a}c=fa.support={},f=fa.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fa.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=n.documentElement,p=!f(n),(e=n.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",da,!1):e.attachEvent&&e.attachEvent("onunload",da)),c.attributes=ia(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ia(function(a){return a.appendChild(n.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Z.test(n.getElementsByClassName),c.getById=ia(function(a){return o.appendChild(a).id=u,!n.getElementsByName||!n.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c=b.getElementById(a);return c?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){var c="undefined"!=typeof a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return"undefined"!=typeof b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return"undefined"!=typeof b.getElementsByClassName&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=Z.test(n.querySelectorAll))&&(ia(function(a){o.appendChild(a).innerHTML="",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+L+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+L+"*(?:value|"+K+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ia(function(a){var b=n.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+L+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=Z.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ia(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",O)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=Z.test(o.compareDocumentPosition),t=b||Z.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===n||a.ownerDocument===v&&t(v,a)?-1:b===n||b.ownerDocument===v&&t(v,b)?1:k?J(k,a)-J(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,g=[a],h=[b];if(!e||!f)return a===n?-1:b===n?1:e?-1:f?1:k?J(k,a)-J(k,b):0;if(e===f)return ka(a,b);c=a;while(c=c.parentNode)g.unshift(c);c=b;while(c=c.parentNode)h.unshift(c);while(g[d]===h[d])d++;return d?ka(g[d],h[d]):g[d]===v?-1:h[d]===v?1:0},n):n},fa.matches=function(a,b){return fa(a,null,null,b)},fa.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(T,"='$1']"),c.matchesSelector&&p&&!A[b+" "]&&(!r||!r.test(b))&&(!q||!q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fa(b,n,null,[a]).length>0},fa.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fa.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&D.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fa.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fa.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fa.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fa.selectors={cacheLength:50,createPseudo:ha,match:W,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ba,ca),a[3]=(a[3]||a[4]||a[5]||"").replace(ba,ca),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fa.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fa.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return W.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&U.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ba,ca).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+L+")"+a+"("+L+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||"undefined"!=typeof a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fa.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(P," ")+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h,t=!1;if(q){if(f){while(p){m=b;while(m=m[p])if(h?m.nodeName.toLowerCase()===r:1===m.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){m=q,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n&&j[2],m=n&&q.childNodes[n];while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if(1===m.nodeType&&++t&&m===b){k[a]=[w,n,t];break}}else if(s&&(m=b,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n),t===!1)while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if((h?m.nodeName.toLowerCase()===r:1===m.nodeType)&&++t&&(s&&(l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),k[a]=[w,t]),m===b))break;return t-=e,t===d||t%d===0&&t/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fa.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ha(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=J(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ha(function(a){var b=[],c=[],d=h(a.replace(Q,"$1"));return d[u]?ha(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ha(function(a){return function(b){return fa(a,b).length>0}}),contains:ha(function(a){return a=a.replace(ba,ca),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ha(function(a){return V.test(a||"")||fa.error("unsupported lang: "+a),a=a.replace(ba,ca).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Y.test(a.nodeName)},input:function(a){return X.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:na(function(){return[0]}),last:na(function(a,b){return[b-1]}),eq:na(function(a,b,c){return[0>c?c+b:c]}),even:na(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:na(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:na(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:na(function(a,b,c){for(var d=0>c?c+b:c;++db;b++)d+=a[b].value;return d}function ra(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j,k=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(j=b[u]||(b[u]={}),i=j[b.uniqueID]||(j[b.uniqueID]={}),(h=i[d])&&h[0]===w&&h[1]===f)return k[2]=h[2];if(i[d]=k,k[2]=a(b,c,g))return!0}}}function sa(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function ta(a,b,c){for(var d=0,e=b.length;e>d;d++)fa(a,b[d],c);return c}function ua(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(c&&!c(f,d,e)||(g.push(f),j&&b.push(h)));return g}function va(a,b,c,d,e,f){return d&&!d[u]&&(d=va(d)),e&&!e[u]&&(e=va(e,f)),ha(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||ta(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ua(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ua(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?J(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ua(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):H.apply(g,r)})}function wa(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=ra(function(a){return a===b},h,!0),l=ra(function(a){return J(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];f>i;i++)if(c=d.relative[a[i].type])m=[ra(sa(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return va(i>1&&sa(m),i>1&&qa(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(Q,"$1"),c,e>i&&wa(a.slice(i,e)),f>e&&wa(a=a.slice(e)),f>e&&qa(a))}m.push(c)}return sa(m)}function xa(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,o,q,r=0,s="0",t=f&&[],u=[],v=j,x=f||e&&d.find.TAG("*",k),y=w+=null==v?1:Math.random()||.1,z=x.length;for(k&&(j=g===n||g||k);s!==z&&null!=(l=x[s]);s++){if(e&&l){o=0,g||l.ownerDocument===n||(m(l),h=!p);while(q=a[o++])if(q(l,g||n,h)){i.push(l);break}k&&(w=y)}c&&((l=!q&&l)&&r--,f&&t.push(l))}if(r+=s,c&&s!==r){o=0;while(q=b[o++])q(t,u,g,h);if(f){if(r>0)while(s--)t[s]||u[s]||(u[s]=F.call(i));u=ua(u)}H.apply(i,u),k&&!f&&u.length>0&&r+b.length>1&&fa.uniqueSort(i)}return k&&(w=y,j=v),t};return c?ha(f):f}return h=fa.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wa(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xa(e,d)),f.selector=a}return f},i=fa.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(ba,ca),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=W.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(ba,ca),_.test(j[0].type)&&oa(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qa(j),!a)return H.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,!b||_.test(a)&&oa(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ia(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ia(function(a){return a.innerHTML="","#"===a.firstChild.getAttribute("href")})||ja("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ia(function(a){return a.innerHTML="",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ja("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ia(function(a){return null==a.getAttribute("disabled")})||ja(K,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fa}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.uniqueSort=n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},v=function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c},w=n.expr.match.needsContext,x=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,y=/^.[^:#\[\.,]*$/;function z(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(y.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return h.call(b,a)>-1!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=this.length,d=[],e=this;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;c>b;b++)if(n.contains(e[b],this))return!0}));for(b=0;c>b;b++)n.find(a,e[b],d);return d=this.pushStack(c>1?n.unique(d):d),d.selector=this.selector?this.selector+" "+a:a,d},filter:function(a){return this.pushStack(z(this,a||[],!1))},not:function(a){return this.pushStack(z(this,a||[],!0))},is:function(a){return!!z(this,"string"==typeof a&&w.test(a)?n(a):a||[],!1).length}});var A,B=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,C=n.fn.init=function(a,b,c){var e,f;if(!a)return this;if(c=c||A,"string"==typeof a){if(e="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:B.exec(a),!e||!e[1]&&b)return!b||b.jquery?(b||c).find(a):this.constructor(b).find(a);if(e[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(e[1],b&&b.nodeType?b.ownerDocument||b:d,!0)),x.test(e[1])&&n.isPlainObject(b))for(e in b)n.isFunction(this[e])?this[e](b[e]):this.attr(e,b[e]);return this}return f=d.getElementById(e[2]),f&&f.parentNode&&(this.length=1,this[0]=f),this.context=d,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?void 0!==c.ready?c.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};C.prototype=n.fn,A=n(d);var D=/^(?:parents|prev(?:Until|All))/,E={children:!0,contents:!0,next:!0,prev:!0};n.fn.extend({has:function(a){var b=n(a,this),c=b.length;return this.filter(function(){for(var a=0;c>a;a++)if(n.contains(this,b[a]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=w.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.uniqueSort(f):f)},index:function(a){return a?"string"==typeof a?h.call(n(a),this[0]):h.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.uniqueSort(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function F(a,b){while((a=a[b])&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return u(a,"parentNode")},parentsUntil:function(a,b,c){return u(a,"parentNode",c)},next:function(a){return F(a,"nextSibling")},prev:function(a){return F(a,"previousSibling")},nextAll:function(a){return u(a,"nextSibling")},prevAll:function(a){return u(a,"previousSibling")},nextUntil:function(a,b,c){return u(a,"nextSibling",c)},prevUntil:function(a,b,c){return u(a,"previousSibling",c)},siblings:function(a){return v((a.parentNode||{}).firstChild,a)},children:function(a){return v(a.firstChild)},contents:function(a){return a.contentDocument||n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(E[a]||n.uniqueSort(e),D.test(a)&&e.reverse()),this.pushStack(e)}});var G=/\S+/g;function H(a){var b={};return n.each(a.match(G)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?H(a):n.extend({},a);var b,c,d,e,f=[],g=[],h=-1,i=function(){for(e=a.once,d=b=!0;g.length;h=-1){c=g.shift();while(++h-1)f.splice(c,1),h>=c&&h--}),this},has:function(a){return a?n.inArray(a,f)>-1:f.length>0},empty:function(){return f&&(f=[]),this},disable:function(){return e=g=[],f=c="",this},disabled:function(){return!f},lock:function(){return e=g=[],c||(f=c=""),this},locked:function(){return!!e},fireWith:function(a,c){return e||(c=c||[],c=[a,c.slice?c.slice():c],g.push(c),b||i()),this},fire:function(){return j.fireWith(this,arguments),this},fired:function(){return!!d}};return j},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().progress(c.notify).done(c.resolve).fail(c.reject):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=e.call(arguments),d=c.length,f=1!==d||a&&n.isFunction(a.promise)?d:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(d){b[a]=this,c[a]=arguments.length>1?e.call(arguments):d,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(d>1)for(i=new Array(d),j=new Array(d),k=new Array(d);d>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().progress(h(b,j,i)).done(h(b,k,c)).fail(g.reject):--f;return f||g.resolveWith(k,c),g.promise()}});var I;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(I.resolveWith(d,[n]),n.fn.triggerHandler&&(n(d).triggerHandler("ready"),n(d).off("ready"))))}});function J(){d.removeEventListener("DOMContentLoaded",J),a.removeEventListener("load",J),n.ready()}n.ready.promise=function(b){return I||(I=n.Deferred(),"complete"===d.readyState||"loading"!==d.readyState&&!d.documentElement.doScroll?a.setTimeout(n.ready):(d.addEventListener("DOMContentLoaded",J),a.addEventListener("load",J))),I.promise(b)},n.ready.promise();var K=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)K(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},L=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function M(){this.expando=n.expando+M.uid++}M.uid=1,M.prototype={register:function(a,b){var c=b||{};return a.nodeType?a[this.expando]=c:Object.defineProperty(a,this.expando,{value:c,writable:!0,configurable:!0}),a[this.expando]},cache:function(a){if(!L(a))return{};var b=a[this.expando];return b||(b={},L(a)&&(a.nodeType?a[this.expando]=b:Object.defineProperty(a,this.expando,{value:b,configurable:!0}))),b},set:function(a,b,c){var d,e=this.cache(a);if("string"==typeof b)e[b]=c;else for(d in b)e[d]=b[d];return e},get:function(a,b){return void 0===b?this.cache(a):a[this.expando]&&a[this.expando][b]},access:function(a,b,c){var d;return void 0===b||b&&"string"==typeof b&&void 0===c?(d=this.get(a,b),void 0!==d?d:this.get(a,n.camelCase(b))):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d,e,f=a[this.expando];if(void 0!==f){if(void 0===b)this.register(a);else{n.isArray(b)?d=b.concat(b.map(n.camelCase)):(e=n.camelCase(b),b in f?d=[b,e]:(d=e,d=d in f?[d]:d.match(G)||[])),c=d.length;while(c--)delete f[d[c]]}(void 0===b||n.isEmptyObject(f))&&(a.nodeType?a[this.expando]=void 0:delete a[this.expando])}},hasData:function(a){var b=a[this.expando];return void 0!==b&&!n.isEmptyObject(b)}};var N=new M,O=new M,P=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Q=/[A-Z]/g;function R(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(Q,"-$&").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:P.test(c)?n.parseJSON(c):c; -}catch(e){}O.set(a,b,c)}else c=void 0;return c}n.extend({hasData:function(a){return O.hasData(a)||N.hasData(a)},data:function(a,b,c){return O.access(a,b,c)},removeData:function(a,b){O.remove(a,b)},_data:function(a,b,c){return N.access(a,b,c)},_removeData:function(a,b){N.remove(a,b)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=O.get(f),1===f.nodeType&&!N.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),R(f,d,e[d])));N.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){O.set(this,a)}):K(this,function(b){var c,d;if(f&&void 0===b){if(c=O.get(f,a)||O.get(f,a.replace(Q,"-$&").toLowerCase()),void 0!==c)return c;if(d=n.camelCase(a),c=O.get(f,d),void 0!==c)return c;if(c=R(f,d,void 0),void 0!==c)return c}else d=n.camelCase(a),this.each(function(){var c=O.get(this,d);O.set(this,d,b),a.indexOf("-")>-1&&void 0!==c&&O.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){O.remove(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=N.get(a,b),c&&(!d||n.isArray(c)?d=N.access(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return N.get(a,c)||N.access(a,c,{empty:n.Callbacks("once memory").add(function(){N.remove(a,[b+"queue",c])})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length",""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};$.optgroup=$.option,$.tbody=$.tfoot=$.colgroup=$.caption=$.thead,$.th=$.td;function _(a,b){var c="undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName(b||"*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&n.nodeName(a,b)?n.merge([a],c):c}function aa(a,b){for(var c=0,d=a.length;d>c;c++)N.set(a[c],"globalEval",!b||N.get(b[c],"globalEval"))}var ba=/<|&#?\w+;/;function ca(a,b,c,d,e){for(var f,g,h,i,j,k,l=b.createDocumentFragment(),m=[],o=0,p=a.length;p>o;o++)if(f=a[o],f||0===f)if("object"===n.type(f))n.merge(m,f.nodeType?[f]:f);else if(ba.test(f)){g=g||l.appendChild(b.createElement("div")),h=(Y.exec(f)||["",""])[1].toLowerCase(),i=$[h]||$._default,g.innerHTML=i[1]+n.htmlPrefilter(f)+i[2],k=i[0];while(k--)g=g.lastChild;n.merge(m,g.childNodes),g=l.firstChild,g.textContent=""}else m.push(b.createTextNode(f));l.textContent="",o=0;while(f=m[o++])if(d&&n.inArray(f,d)>-1)e&&e.push(f);else if(j=n.contains(f.ownerDocument,f),g=_(l.appendChild(f),"script"),j&&aa(g),c){k=0;while(f=g[k++])Z.test(f.type||"")&&c.push(f)}return l}!function(){var a=d.createDocumentFragment(),b=a.appendChild(d.createElement("div")),c=d.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),l.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="",l.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var da=/^key/,ea=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,fa=/^([^.]*)(?:\.(.+)|)/;function ga(){return!0}function ha(){return!1}function ia(){try{return d.activeElement}catch(a){}}function ja(a,b,c,d,e,f){var g,h;if("object"==typeof b){"string"!=typeof c&&(d=d||c,c=void 0);for(h in b)ja(a,h,c,d,b[h],f);return a}if(null==d&&null==e?(e=c,d=c=void 0):null==e&&("string"==typeof c?(e=d,d=void 0):(e=d,d=c,c=void 0)),e===!1)e=ha;else if(!e)return a;return 1===f&&(g=e,e=function(a){return n().off(a),g.apply(this,arguments)},e.guid=g.guid||(g.guid=n.guid++)),a.each(function(){n.event.add(this,b,e,d,c)})}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=N.get(a);if(r){c.handler&&(f=c,c=f.handler,e=f.selector),c.guid||(c.guid=n.guid++),(i=r.events)||(i=r.events={}),(g=r.handle)||(g=r.handle=function(b){return"undefined"!=typeof n&&n.event.triggered!==b.type?n.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(G)||[""],j=b.length;while(j--)h=fa.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o&&(l=n.event.special[o]||{},o=(e?l.delegateType:l.bindType)||o,l=n.event.special[o]||{},k=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},f),(m=i[o])||(m=i[o]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,p,g)!==!1||a.addEventListener&&a.addEventListener(o,g)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),n.event.global[o]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=N.hasData(a)&&N.get(a);if(r&&(i=r.events)){b=(b||"").match(G)||[""],j=b.length;while(j--)if(h=fa.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=i[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&q!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete i[o])}else for(o in i)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(i)&&N.remove(a,"handle events")}},dispatch:function(a){a=n.event.fix(a);var b,c,d,f,g,h=[],i=e.call(arguments),j=(N.get(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())a.rnamespace&&!a.rnamespace.test(g.namespace)||(a.handleObj=g,a.data=g.data,d=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==d&&(a.result=d)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&("click"!==a.type||isNaN(a.button)||a.button<1))for(;i!==this;i=i.parentNode||this)if(1===i.nodeType&&(i.disabled!==!0||"click"!==a.type)){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>-1:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h]*)\/>/gi,la=/\s*$/g;function pa(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function qa(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function ra(a){var b=na.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function sa(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(N.hasData(a)&&(f=N.access(a),g=N.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)n.event.add(b,e,j[e][c])}O.hasData(a)&&(h=O.access(a),i=n.extend({},h),O.set(b,i))}}function ta(a,b){var c=b.nodeName.toLowerCase();"input"===c&&X.test(a.type)?b.checked=a.checked:"input"!==c&&"textarea"!==c||(b.defaultValue=a.defaultValue)}function ua(a,b,c,d){b=f.apply([],b);var e,g,h,i,j,k,m=0,o=a.length,p=o-1,q=b[0],r=n.isFunction(q);if(r||o>1&&"string"==typeof q&&!l.checkClone&&ma.test(q))return a.each(function(e){var f=a.eq(e);r&&(b[0]=q.call(this,e,f.html())),ua(f,b,c,d)});if(o&&(e=ca(b,a[0].ownerDocument,!1,a,d),g=e.firstChild,1===e.childNodes.length&&(e=g),g||d)){for(h=n.map(_(e,"script"),qa),i=h.length;o>m;m++)j=e,m!==p&&(j=n.clone(j,!0,!0),i&&n.merge(h,_(j,"script"))),c.call(a[m],j,m);if(i)for(k=h[h.length-1].ownerDocument,n.map(h,ra),m=0;i>m;m++)j=h[m],Z.test(j.type||"")&&!N.access(j,"globalEval")&&n.contains(k,j)&&(j.src?n._evalUrl&&n._evalUrl(j.src):n.globalEval(j.textContent.replace(oa,"")))}return a}function va(a,b,c){for(var d,e=b?n.filter(b,a):a,f=0;null!=(d=e[f]);f++)c||1!==d.nodeType||n.cleanData(_(d)),d.parentNode&&(c&&n.contains(d.ownerDocument,d)&&aa(_(d,"script")),d.parentNode.removeChild(d));return a}n.extend({htmlPrefilter:function(a){return a.replace(ka,"<$1>")},clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=n.contains(a.ownerDocument,a);if(!(l.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(g=_(h),f=_(a),d=0,e=f.length;e>d;d++)ta(f[d],g[d]);if(b)if(c)for(f=f||_(a),g=g||_(h),d=0,e=f.length;e>d;d++)sa(f[d],g[d]);else sa(a,h);return g=_(h,"script"),g.length>0&&aa(g,!i&&_(a,"script")),h},cleanData:function(a){for(var b,c,d,e=n.event.special,f=0;void 0!==(c=a[f]);f++)if(L(c)){if(b=c[N.expando]){if(b.events)for(d in b.events)e[d]?n.event.remove(c,d):n.removeEvent(c,d,b.handle);c[N.expando]=void 0}c[O.expando]&&(c[O.expando]=void 0)}}}),n.fn.extend({domManip:ua,detach:function(a){return va(this,a,!0)},remove:function(a){return va(this,a)},text:function(a){return K(this,function(a){return void 0===a?n.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=a)})},null,a,arguments.length)},append:function(){return ua(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=pa(this,a);b.appendChild(a)}})},prepend:function(){return ua(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=pa(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return ua(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return ua(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(n.cleanData(_(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return K(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!la.test(a)&&!$[(Y.exec(a)||["",""])[1].toLowerCase()]){a=n.htmlPrefilter(a);try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(_(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=[];return ua(this,arguments,function(b){var c=this.parentNode;n.inArray(this,a)<0&&(n.cleanData(_(this)),c&&c.replaceChild(b,this))},a)}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=[],e=n(a),f=e.length-1,h=0;f>=h;h++)c=h===f?this:this.clone(!0),n(e[h])[b](c),g.apply(d,c.get());return this.pushStack(d)}});var wa,xa={HTML:"block",BODY:"block"};function ya(a,b){var c=n(b.createElement(a)).appendTo(b.body),d=n.css(c[0],"display");return c.detach(),d}function za(a){var b=d,c=xa[a];return c||(c=ya(a,b),"none"!==c&&c||(wa=(wa||n(" - - - ` - } else if (data.document.extension == "jpg" || data.document.extension == "png") { - var img = `${pandora.proto}://${data.site}/documents/${data.document.id}/${safeDocumentName(data.document.title)}.${data.document.extension}` - var open_text = `Open on ${data.site}` - if (data.crop) { - img = `${pandora.proto}://${data.site}/documents/${data.document.id}/1024p${data.crop.join(',')}.jpg` - data.link = getLink(`documents/${data.document.id}`) - open_text = `Open image` - } - div.innerHTML = ` -

${data.document.title}

-
- -
- - ` - - } else { - div.innerHTML = `unsupported document type` - } - document.querySelector(".content").replaceWith(div) -} diff --git a/static/mobile/js/edits.js b/static/mobile/js/edits.js deleted file mode 100644 index f691d618..00000000 --- a/static/mobile/js/edits.js +++ /dev/null @@ -1,235 +0,0 @@ - - -const sortByKey = function(array, by) { - return array.sort(function(a, b) { - var aValue, bValue, index = 0, key, ret = 0; - while (ret == 0 && index < by.length) { - key = by[index].key; - aValue = getSortValue(a[key]) - bValue = getSortValue(b[key]) - if ((aValue === null) != (bValue === null)) { - ret = aValue === null ? 1 : -1; - } else if (aValue < bValue) { - ret = by[index].operator == '+' ? -1 : 1; - } else if (aValue > bValue) { - ret = by[index].operator == '+' ? 1 : -1; - } else { - index++; - } - } - return ret; - }); -}; - -async function sortClips(edit, sort) { - var key = sort.key, index; - if (key == 'position') { - key = 'in'; - } - if ([ - 'id', 'index', 'in', 'out', 'duration', - 'title', 'director', 'year', 'videoRatio' - ].indexOf(key) > -1) { - sortBy(sort); - index = 0; - edit.clips.forEach(function(clip) { - clip.sort = index++; - if (sort.operator == '-') { - clip.sort = -clip.sort; - } - }); - } else { - var response = await pandoraAPI('sortClips', { - edit: edit.id, - sort: [sort] - }) - edit.clips.forEach(function(clip) { - clip.sort = response.data.clips.indexOf(clip.id); - if (sort.operator == '-') { - clip.sort = -clip.sort; - } - }); - sortBy({ - key: 'sort', - operator: '+' - }); - } - function sortBy(key) { - edit.clips = sortByKey(edit.clips, [key]); - } -} - -function getClip(edit, position) { - const response = {} - let pos = 0 - edit.clips.forEach(function(clip) { - if (clip.position < position && clip.position + clip.duration > position) { - response.item = clip.item - response.position = position - clip.position - if (clip['in']) { - response.position += clip['in'] - } - } - }); - return response -} - -async function loadEdit(id, args) { - var data = window.data = {} - data.id = id - data.site = pandora.hostname - - var response = await pandoraAPI('getEdit', { - id: data.id, - keys: [ - ] - }) - if (response.status.code != 200) { - return { - site: data.site, - error: response.status - } - } - data.edit = response['data'] - if (['public', 'featured'].indexOf(data.edit.status) == -1) { - return { - site: data.site, - error: { - code: 403, - text: 'permission denied' - } - } - } - data.layers = {} - data.videos = [] - - if (args.sort) { - await sortClips(data.edit, args.sort) - } - - data.edit.duration = 0; - data.edit.clips.forEach(function(clip) { - clip.position = data.edit.duration; - data.edit.duration += clip.duration; - }); - - data.edit.clips.forEach(clip => { - var start = clip['in'] || 0, end = clip.out, position = 0; - clip.durations.forEach((duration, idx) => { - if (!duration) { - return - } - if (position + duration <= start || position > end) { - // pass - } else { - var video = {} - var oshash = clip.streams[idx] - video.src = getVideoURL(clip.item, pandora.resolution, idx+1, '', oshash) - /* - if (clip['in'] && clip.out) { - video.src += `#t=${clip['in']},${clip.out}` - } - */ - if (isNumber(clip.volume)) { - video.volume = clip.volume; - } - if ( - position <= start - && position + duration > start - ) { - video['in'] = start - position; - } - if (position + duration >= end) { - video.out = end - position; - } - if (video['in'] && video.out) { - video.duration = video.out - video['in'] - } else if (video.out) { - video.duration = video.out; - } else if (!isUndefined(video['in'])) { - video.duration = duration - video['in']; - video.out = duration; - } else { - video.duration = duration; - video['in'] = 0; - video.out = video.duration; - } - data.videos.push(video) - } - position += duration - }) - Object.keys(clip.layers).forEach(layer => { - clip.layers[layer].forEach(annotation => { - if (args.users && !args.users.includes(annotation.user)) { - return - } - if (args.layers && !args.layers.includes(layer)) { - return - } - var a = {...annotation} - a['id'] = clip['id'] + '/' + a['id']; - a['in'] = Math.max( - clip['position'], - a['in'] - clip['in'] + clip['position'] - ); - a.out = Math.min( - clip['position'] + clip['duration'], - a.out - clip['in'] + clip['position'] - ); - data.layers[layer] = data.layers[layer] || [] - data.layers[layer].push(a) - }) - }) - }) - if (data.layers[pandora.subtitleLayer]) { - var previous; - data.layers[pandora.subtitleLayer].forEach(annotation => { - if (previous) { - previous.out = annotation['in'] - } - previous = annotation - }) - } - var value = [] - pandora.layerKeys.forEach(layer => { - if (!data.layers[layer]) { - return - } - var html = [] - var layerData = getObjectById(pandora.site.layers, layer) - html.push(`

- ${icon.down} - ${layerData.title} -

`) - data.layers[layer].forEach(annotation => { - html.push(` -
- ${annotation.value} -
- `) - }) - var layerClass = "" - if (layerData.isSubtitles) { - layerClass = " is-subtitles" - } - value.push('
' + html.join('\n') + '
') - }) - data.value = value.join('\n') - - data.title = data.edit.name - data.byline = data.edit.description - data.link = `${pandora.proto}://${data.site}/edits/${data.edit.id}` - let poster = data.edit.posterFrames[0] - if (args.parts[2] && args.parts[2].indexOf(':') > -1) { - poster = getClip(data.edit, parseDuration(args.parts[2])) - } - if (poster && poster.item) { - data.poster = `${pandora.proto}://${data.site}/${poster.item}/${pandora.resolution}p${poster.position.toFixed(3)}.jpg` - } else { - data.poster = data.videos[0].src.split('/48')[0] + `/${pandora.resolution}p${data.videos[0].in.toFixed(3)}.jpg` - } - data.aspectratio = data.edit.clips[0].videoRatio - data.duration = data.edit.duration - return data - -} diff --git a/static/mobile/js/icons.js b/static/mobile/js/icons.js deleted file mode 100644 index 50116108..00000000 --- a/static/mobile/js/icons.js +++ /dev/null @@ -1,200 +0,0 @@ -var icon = {} -icon.enterFullscreen = ` - - - - - - - - -` -icon.exitFullscreen = ` - - - - - - - - -` - -icon.mute = ` - - - - - - - -` - -icon.unmute = ` - - - - -` - -icon.play = ` - - - -` -icon.pause = ` - - - - - -` -icon.loading = ` - - - - - - -` - -icon.loading_w = ` - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -` - -icon.right = ` - - - -` -icon.left = ` - - - -` -icon.down = ` - - - -` - -icon.publishComment = ` - - - - - - -` diff --git a/static/mobile/js/item.js b/static/mobile/js/item.js deleted file mode 100644 index 42c4d2cd..00000000 --- a/static/mobile/js/item.js +++ /dev/null @@ -1,182 +0,0 @@ - -async function loadData(id, args) { - var data = window.data = {} - data.id = id - data.site = pandora.hostname - - var response = await pandoraAPI('get', { - id: data.id.split('/')[0], - keys: [ - "id", - "title", - "director", - "year", - "date", - "source", - "summary", - "streams", - "duration", - "durations", - "layers", - "rightslevel", - "videoRatio" - ] - }) - - if (response.status.code != 200) { - return { - site: data.site, - error: response.status - } - } - data.item = response['data'] - if (data.item.rightslevel > pandora.site.capabilities.canPlayClips['guest']) { - return { - site: data.site, - error: { - code: 403, - text: 'permission denied' - } - } - } - if (id.split('/').length == 1 || id.split('/')[1] == 'info') { - data.view = 'info' - data.title = data.item.title - if (data.item.source) { - data.byline = data.item.source - } else { - data.byline = data.item.director ? data.item.director.join(', ') : '' - } - if (data.item.year) { - data.byline += ' (' + data.item.year + ')' - } else if (data.item.date) { - data.byline += ' (' + data.item.date.split('-')[0] + ')' - } - data.link = `${pandora.proto}://${data.site}/${data.item.id}/info` - let poster = pandora.site.user.ui.icons == 'posters' ? 'poster' : 'icon' - data.icon = `${pandora.proto}://${data.site}/${data.item.id}/${poster}.jpg` - return data - } - - if (id.includes('-') || id.includes(',')) { - var inout = id.split('/')[1].split(id.includes('-') ? '-' : ',').map(parseDuration) - data.out = inout.pop() - data['in'] = inout.pop() - } else if (args.full) { - data.out = data.item.duration - data['in'] = 0 - } else { - var annotation = await pandoraAPI('getAnnotation', { - id: data.id, - }) - if (annotation.status.code != 200) { - return { - site: data.site, - error: annotation.status - } - } - data.annotation = annotation['data'] - data['in'] = data.annotation['in'] - data.out = data.annotation['out'] - } - - data.layers = {} - - pandora.layerKeys.forEach(layer => { - data.item.layers[layer].forEach(annot => { - if (data.annotation) { - if (annot.id == data.annotation.id) { - data.layers[layer] = data.layers[layer] || [] - data["layers"][layer].push(annot) - } - } else if (annot['out'] > data['in'] && annot['in'] < data['out']) { - if (args.users && !args.users.includes(annot.user)) { - return - } - if (args.layers && !args.layers.includes(layer)) { - return - } - data.layers[layer] = data.layers[layer] || [] - //annot['in'] = Math.max([annot['in'], data['in']]) - //annot['out'] = Math.min([annot['out'], data['out']]) - data["layers"][layer].push(annot) - } - }) - }) - data.videos = [] - data.item.durations.forEach((duration, idx) => { - var oshash = data.item.streams[idx] - var url = getVideoURL(data.item.id, pandora.resolution, idx+1, '', oshash) - data.videos.push({ - src: url, - duration: duration - }) - }) - if (data.layers[pandora.subtitleLayer]) { - var previous; - data.layers[pandora.subtitleLayer].forEach(annotation => { - if (previous) { - previous.out = annotation['in'] - } - previous = annotation - }) - } - var value = [] - Object.keys(data.layers).forEach(layer => { - var html = [] - var layerData = getObjectById(pandora.site.layers, layer) - html.push(`

- ${icon.down} - ${layerData.title} -

`) - data.layers[layer] = sortBy(data.layers[layer], [ - {key: "in", operator: "+"}, - {key: "created", operator: "+"} - ]) - data.layers[layer].forEach(annotation => { - if (pandora.url) { - annotation.value = annotation.value.replace( - /src="\//g, `src="${pandora.url.origin}/` - ).replace( - /href="\//g, `href="${pandora.url.origin}/` - ) - } - let content = annotation.value - if (!layerData.isSubtitles && layerData.type == "text" && args.show && args.show.includes("user")) { - content += `\n
— ${annotation.user}
` - } - html.push(` -
- ${content} -
- `) - }) - var layerClass = "" - if (layerData.isSubtitles) { - layerClass = " is-subtitles" - } - value.push('
' + html.join('\n') + '
') - }) - data.value = value.join('\n') - - data.title = data.item.title - if (data.item.source) { - data.byline = data.item.source - } else { - data.byline = data.item.director ? data.item.director.join(', ') : '' - } - if (data.item.year) { - data.byline += ' (' + data.item.year + ')' - } else if (data.item.date) { - data.byline += ' (' + data.item.date.split('-')[0] + ')' - } - data.link = `${pandora.proto}://${data.site}/${data.item.id}/${data["in"]},${data.out}` - data.poster = `${pandora.proto}://${data.site}/${data.item.id}/${pandora.resolution}p${data["in"]}.jpg` - data.aspectratio = data.item.videoRatio - if (data['in'] == data['out']) { - data['out'] += 0.04 - } - data.duration = data.out - data['in'] - return data -} - diff --git a/static/mobile/js/main.js b/static/mobile/js/main.js deleted file mode 100644 index 421eacc2..00000000 --- a/static/mobile/js/main.js +++ /dev/null @@ -1,133 +0,0 @@ - - -function parseURL() { - var url = pandora.url ? pandora.url : document.location, - fragment = url.hash.slice(1) - if (!fragment && url.pathname.startsWith('/m/')) { - var prefix = url.protocol + '//' + url.hostname + '/m/' - fragment = url.href.slice(prefix.length) - } - var args = fragment.split('?') - var id = args.shift() - if (args) { - args = args.join('?').split('&').map(arg => { - var kv = arg.split('=') - k = kv.shift() - v = kv.join('=') - if (['users', 'layers', 'show'].includes(k)) { - v = v.split(',') - } - return [k, v] - }).filter(kv => { - return kv[0].length - }) - if (args) { - args = Object.fromEntries(args); - } else { - args = {} - } - } else { - args = {} - } - var type = "item" - if (id.startsWith('document')) { - id = id.split('/') - id.shift() - id = id.join('/') - type = "document" - } else if (id.startsWith('edits/')) { - var parts = id.split('/') - parts.shift() - id = parts.shift().replace(/_/g, ' ').replace(/%09/g, '_') - type = "edit" - if (parts.length >= 2) { - args.sort = parts[1] - if (args.sort[0] == '-') { - args.sort = { - key: args.sort.slice(1), - operator: '-' - } - } else if (args.sort[0] == '+') { - args.sort = { - key: args.sort.slice(1), - operator: '+' - } - } else { - args.sort = { - key: args.sort, - operator: '+' - } - } - } - args.parts = parts - } else { - if (id.endsWith('/player') || id.endsWith('/editor')) { - args.full = true - } - id = id.replace('/editor/', '/').replace('/player/', '/') - type = "item" - } - //console.log(type, id, args) - return [type, id, args] -} - -function render() { - var type, id, args; - [type, id, args] = parseURL() - document.querySelector(".content").innerHTML = loadingScreen - if (type == "document") { - loadDocument(id, args).then(renderDocument) - } else if (type == "edit") { - loadEdit(id, args).then(renderItem) - } else { - loadData(id, args).then(renderItem) - } - -} -var loadingScreen = ` - -
${icon.loading}
-` - -document.querySelector(".content").innerHTML = loadingScreen -pandoraAPI("init").then(response => { - pandora = { - ...pandora, - ...response.data - } - pandora.proto = pandora.site.site.https ? 'https' : 'http' - pandora.resolution = Math.max.apply(null, pandora.site.video.resolutions) - if (pandora.site.site.videoprefix.startsWith('//')) { - pandora.site.site.videoprefix = pandora.proto + ':' + pandora.site.site.videoprefix - } - var layerKeys = [] - var subtitleLayer = pandora.site.layers.filter(layer => {return layer.isSubtitles})[0] - if (subtitleLayer) { - layerKeys.push(subtitleLayer.id) - } - pandora.subtitleLayer = subtitleLayer.id - pandora.site.layers.map(layer => { - return layer.id - }).filter(layer => { - return !subtitleLayer || layer != subtitleLayer.id - }).forEach(layer => { - layerKeys.push(layer) - }) - pandora.layerKeys = layerKeys - id = document.location.hash.slice(1) - window.addEventListener("hashchange", event => { - render() - }) - window.addEventListener("popstate", event => { - console.log("popsatte") - render() - }) - window.addEventListener('resize', event => { - }) - render() -}) diff --git a/static/mobile/js/render.js b/static/mobile/js/render.js deleted file mode 100644 index 40422e55..00000000 --- a/static/mobile/js/render.js +++ /dev/null @@ -1,159 +0,0 @@ - -function renderItemInfo(data) { - div = document.createElement('div') - div.className = "content" - div.innerHTML = ` -

${item.title}

-

${data.title}

- -
- -
- - ` - if (!item.title) { - div.querySelector('item-title').remove() - } - document.querySelector(".content").replaceWith(div) -} - -function renderItem(data) { - window.item = window.item || {} - if (data.error) { - return renderError(data) - } - if (data.view == "info") { - return renderItemInfo(data) - } - div = document.createElement('div') - div.className = "content" - div.innerHTML = ` -

${item.title}

-

${data.title}

- -
-
-
-
- ${data.value} -
-
- - ` - if (!item.title) { - div.querySelector('.item-title').remove() - } - - var comments = div.querySelector('.comments') - if (window.renderComments) { - renderComments(comments, data) - } else { - comments.remove() - } - - div.querySelectorAll('.layer a').forEach(a => { - a.addEventListener("click", clickLink) - }) - - div.querySelectorAll('.layer').forEach(layer => { - layer.querySelector('h3').addEventListener("click", event => { - var img = layer.querySelector('h3 .icon') - if (layer.classList.contains("collapsed")) { - layer.classList.remove("collapsed") - img.innerHTML = icon.down - } else { - layer.classList.add("collapsed") - img.innerHTML = icon.right - } - }) - }) - - var video = window.video = VideoPlayer({ - items: data.videos, - poster: data.poster, - "in": data["in"] || 0, - position: 0, - duration: data.duration, - aspectratio: data.aspectratio - }) - div.querySelector('.video').replaceWith(video) - video.classList.add('video') - - video.addEventListener("loadedmetadata", event => { - // - }) - - function updateAnnotations(currentTime) { - div.querySelectorAll('.annotation').forEach(annot => { - var now = currentTime + (data["in"] || 0) - var start = parseFloat(annot.dataset.in) - var end = parseFloat(annot.dataset.out) - if (now >= start && now <= end) { - annot.classList.add("active") - annot.parentElement.classList.add('active') - } else { - annot.classList.remove("active") - if (!annot.parentElement.querySelector('.active')) { - annot.parentElement.classList.remove('active') - } - } - }) - } - video.addEventListener("timeupdate", event => { - var currentTime = video.currentTime() - if ((currentTime + (data["in"] || 0)) >= data['out']) { - if (!video.paused) { - video.pause() - } - video.currentTime(0) - } - updateAnnotations(currentTime) - }) - updateAnnotations(data["position"] || 0) - if (item.next || item.previous) { - var nav = document.createElement('nav') - nav.classList.add('items') - if (item.previous) { - var a = document.createElement('a') - a.href = item.previous - a.innerText = '<< previous' - nav.appendChild(a) - } - if (item.previous && item.next) { - var e = document.createElement('span') - e.innerText = ' | ' - nav.appendChild(e) - } - if (item.next) { - var a = document.createElement('a') - a.href = item.next - a.innerText = 'next >>' - nav.appendChild(a) - } - div.appendChild(nav) - } - document.querySelector(".content").replaceWith(div) -} - -function renderError(data) { - var link = '/' + document.location.hash.slice(1) - div = document.createElement('div') - div.className = "content" - div.innerHTML = ` - -
- Page not found
- Open on ${data.site} -
- ` - document.querySelector(".content").replaceWith(div) -} diff --git a/static/mobile/js/utils.js b/static/mobile/js/utils.js deleted file mode 100644 index 25e8a401..00000000 --- a/static/mobile/js/utils.js +++ /dev/null @@ -1,226 +0,0 @@ - -const parseDuration = function(string) { - return string.split(':').reverse().slice(0, 4).reduce(function(p, c, i) { - return p + (parseFloat(c) || 0) * (i == 3 ? 86400 : Math.pow(60, i)); - }, 0); -}; - -const formatDuration = function(seconds) { - if (isString(seconds)) { - seconds = parseFloat(seconds) - } - seconds = seconds.toFixed(3) - var parts = [ - parseInt(seconds / 86400), - parseInt(seconds % 86400 / 3600), - parseInt(seconds % 3600 / 60), - parseInt(seconds % 60) - ] - return parts.map(p => { return p.toString().padStart(2, '0')}).join(':') -} - -const typeOf = function(value) { - return Object.prototype.toString.call(value).slice(8, -1).toLowerCase(); -}; -const isUndefined = function(value) { - return typeOf(value) == 'undefined'; -} -const isNumber = function(value) { - return typeOf(value) == 'number'; -}; -const isObject = function(value) { - return typeOf(value) == 'object'; -}; -const isNull = function(value) { - return typeOf(value) == 'null'; -}; -const isString = function(value) { - return typeOf(value) == 'string'; -}; -const isEmpty = function(value) { - var type = typeOf(value) - if (['arguments', 'array', 'nodelist', 'string'].includes(value)) { - return value.length == 0 - } - if (['object', 'storage'].includes(type)) { - return Object.keys(value).length; - } - return false -}; -const mod = function(number, by) { - return (number % by + by) % by; -}; - -const getObjectById = function(array, id) { - return array.filter(obj => { return obj.id == id})[0] -} - -const debug = function() { - if (localStorage.debug) { - console.log.apply(null, arguments) - } -}; - -const canPlayMP4 = function() { - var video = document.createElement('video'); - if (video.canPlayType && video.canPlayType('video/mp4; codecs="avc1.42E01E, mp4a.40.2"').replace('no', '')) { - return true - } - return false -}; - -const canPlayWebm = function() { - var video = document.createElement('video'); - if (video.canPlayType && video.canPlayType('video/webm; codecs="vp8, vorbis"').replace('no', '')) { - return true - } - return false -}; - -const getFormat = function() { - //var format = canPlayWebm() ? "webm" : "mp4" - var format = canPlayMP4() ? "mp4" : "webm" - return format -} - -const safeDocumentName = function(name) { - ['\\?', '#', '%', '/'].forEach(function(c) { - var r = new RegExp(c, 'g') - name = name.replace(r, '_'); - }) - return name; -}; - -const getVideoInfo = function() { - console.log("FIXME implement getvideoInfo") -} - -const isIOS = /(iPad|iPhone|iPod)/g.test(navigator.userAgent); - - -const getLink = function(fragment) { - if (document.location.hash.length > 2) { - return '#' + fragment - } else { - return '/m/' + fragment - } -} - -const clickLink = function(event) { - var a = event.target - while (a && a.tagName != 'A') { - a = a.parentElement - } - if (!a) { - return - } - var href = a.attributes.href.value - var prefix = document.location.protocol + '//' + document.location.hostname - if (href.startsWith(prefix)) { - href = href.slice(prefix.length) - } - if (href.startsWith('/')) { - event.preventDefault() - event.stopPropagation() - var link = href.split('#embed')[0] - if (document.location.hash.length > 2) { - if (link.startsWith('/m')) { - link = link.slice(2) - } - document.location.hash = '#' + link.slice(1) - } else { - if (link.includes('/download/')) { - document.location.href = link - return - } else if (!link.startsWith('/m')) { - link = '/m' + link - } - history.pushState({}, '', link); - render() - } - } -} - -const getUid = (function() { - var uid = 0; - return function() { - return ++uid; - }; -}()); - - -const getVideoURLName = function(id, resolution, part, track, streamId) { - return id + '/' + resolution + 'p' + part + (track ? '.' + track : '') - + '.' + pandora.format + (streamId ? '?' + streamId : ''); -}; - -const getVideoURL = function(id, resolution, part, track, streamId) { - var uid = getUid(), - prefix = pandora.site.site.videoprefix - .replace('{id}', id) - .replace('{part}', part) - .replace('{resolution}', resolution) - .replace('{uid}', uid) - .replace('{uid42}', uid % 42); - if (!prefix) { - prefix = pandoraURL - } - return prefix + '/' + getVideoURLName(id, resolution, part, track, streamId); -}; - -const getSortValue = function(value) { - var sortValue = value; - function trim(value) { - return value.replace(/^\W+(?=\w)/, ''); - } - if ( - isEmpty(value) - || isNull(value) - || isUndefined(value) - ) { - sortValue = null; - } else if (isString(value)) { - // make lowercase and remove leading non-word characters - sortValue = trim(value.toLowerCase()); - // move leading articles to the end - // and remove leading non-word characters - ['a', 'an', 'the'].forEach(function(article) { - if (new RegExp('^' + article + ' ').test(sortValue)) { - sortValue = trim(sortValue.slice(article.length + 1)) - + ', ' + sortValue.slice(0, article.length); - return false; // break - } - }); - // remove thousand separators and pad numbers - sortValue = sortValue.replace(/(\d),(?=(\d{3}))/g, '$1') - .replace(/\d+/g, function(match) { - return match.padStart(64, '0') - }); - } - return sortValue; -}; - -function sortBy(array, by, map) { - return array.sort(function(a, b) { - var aValue, bValue, index = 0, key, ret = 0; - while (ret == 0 && index < by.length) { - key = by[index].key; - aValue = getSortValue( - map && map[key] ? map[key](a[key], a) : a[key] - ); - bValue = getSortValue( - map && map[key] ? map[key](b[key], b) : b[key] - ); - if ((aValue === null) != (bValue === null)) { - ret = aValue === null ? 1 : -1; - } else if (aValue < bValue) { - ret = by[index].operator == '+' ? -1 : 1; - } else if (aValue > bValue) { - ret = by[index].operator == '+' ? 1 : -1; - } else { - index++; - } - } - return ret; - }); -} diff --git a/static/pdf.js/compatibility.js b/static/pdf.js/compatibility.js new file mode 100644 index 00000000..1119a274 --- /dev/null +++ b/static/pdf.js/compatibility.js @@ -0,0 +1,593 @@ +/* Copyright 2012 Mozilla Foundation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/* globals VBArray, PDFJS */ + +'use strict'; + +// Initializing PDFJS global object here, it case if we need to change/disable +// some PDF.js features, e.g. range requests +if (typeof PDFJS === 'undefined') { + (typeof window !== 'undefined' ? window : this).PDFJS = {}; +} + +// Checking if the typed arrays are supported +// Support: iOS<6.0 (subarray), IE<10, Android<4.0 +(function checkTypedArrayCompatibility() { + if (typeof Uint8Array !== 'undefined') { + // Support: iOS<6.0 + if (typeof Uint8Array.prototype.subarray === 'undefined') { + Uint8Array.prototype.subarray = function subarray(start, end) { + return new Uint8Array(this.slice(start, end)); + }; + Float32Array.prototype.subarray = function subarray(start, end) { + return new Float32Array(this.slice(start, end)); + }; + } + + // Support: Android<4.1 + if (typeof Float64Array === 'undefined') { + window.Float64Array = Float32Array; + } + return; + } + + function subarray(start, end) { + return new TypedArray(this.slice(start, end)); + } + + function setArrayOffset(array, offset) { + if (arguments.length < 2) { + offset = 0; + } + for (var i = 0, n = array.length; i < n; ++i, ++offset) { + this[offset] = array[i] & 0xFF; + } + } + + function TypedArray(arg1) { + var result, i, n; + if (typeof arg1 === 'number') { + result = []; + for (i = 0; i < arg1; ++i) { + result[i] = 0; + } + } else if ('slice' in arg1) { + result = arg1.slice(0); + } else { + result = []; + for (i = 0, n = arg1.length; i < n; ++i) { + result[i] = arg1[i]; + } + } + + result.subarray = subarray; + result.buffer = result; + result.byteLength = result.length; + result.set = setArrayOffset; + + if (typeof arg1 === 'object' && arg1.buffer) { + result.buffer = arg1.buffer; + } + return result; + } + + window.Uint8Array = TypedArray; + window.Int8Array = TypedArray; + + // we don't need support for set, byteLength for 32-bit array + // so we can use the TypedArray as well + window.Uint32Array = TypedArray; + window.Int32Array = TypedArray; + window.Uint16Array = TypedArray; + window.Float32Array = TypedArray; + window.Float64Array = TypedArray; +})(); + +// URL = URL || webkitURL +// Support: Safari<7, Android 4.2+ +(function normalizeURLObject() { + if (!window.URL) { + window.URL = window.webkitURL; + } +})(); + +// Object.defineProperty()? +// Support: Android<4.0, Safari<5.1 +(function checkObjectDefinePropertyCompatibility() { + if (typeof Object.defineProperty !== 'undefined') { + var definePropertyPossible = true; + try { + // some browsers (e.g. safari) cannot use defineProperty() on DOM objects + // and thus the native version is not sufficient + Object.defineProperty(new Image(), 'id', { value: 'test' }); + // ... another test for android gb browser for non-DOM objects + var Test = function Test() {}; + Test.prototype = { get id() { } }; + Object.defineProperty(new Test(), 'id', + { value: '', configurable: true, enumerable: true, writable: false }); + } catch (e) { + definePropertyPossible = false; + } + if (definePropertyPossible) { + return; + } + } + + Object.defineProperty = function objectDefineProperty(obj, name, def) { + delete obj[name]; + if ('get' in def) { + obj.__defineGetter__(name, def['get']); + } + if ('set' in def) { + obj.__defineSetter__(name, def['set']); + } + if ('value' in def) { + obj.__defineSetter__(name, function objectDefinePropertySetter(value) { + this.__defineGetter__(name, function objectDefinePropertyGetter() { + return value; + }); + return value; + }); + obj[name] = def.value; + } + }; +})(); + + +// No XMLHttpRequest#response? +// Support: IE<11, Android <4.0 +(function checkXMLHttpRequestResponseCompatibility() { + var xhrPrototype = XMLHttpRequest.prototype; + var xhr = new XMLHttpRequest(); + if (!('overrideMimeType' in xhr)) { + // IE10 might have response, but not overrideMimeType + // Support: IE10 + Object.defineProperty(xhrPrototype, 'overrideMimeType', { + value: function xmlHttpRequestOverrideMimeType(mimeType) {} + }); + } + if ('responseType' in xhr) { + return; + } + + // The worker will be using XHR, so we can save time and disable worker. + PDFJS.disableWorker = true; + + Object.defineProperty(xhrPrototype, 'responseType', { + get: function xmlHttpRequestGetResponseType() { + return this._responseType || 'text'; + }, + set: function xmlHttpRequestSetResponseType(value) { + if (value === 'text' || value === 'arraybuffer') { + this._responseType = value; + if (value === 'arraybuffer' && + typeof this.overrideMimeType === 'function') { + this.overrideMimeType('text/plain; charset=x-user-defined'); + } + } + } + }); + + // Support: IE9 + if (typeof VBArray !== 'undefined') { + Object.defineProperty(xhrPrototype, 'response', { + get: function xmlHttpRequestResponseGet() { + if (this.responseType === 'arraybuffer') { + return new Uint8Array(new VBArray(this.responseBody).toArray()); + } else { + return this.responseText; + } + } + }); + return; + } + + Object.defineProperty(xhrPrototype, 'response', { + get: function xmlHttpRequestResponseGet() { + if (this.responseType !== 'arraybuffer') { + return this.responseText; + } + var text = this.responseText; + var i, n = text.length; + var result = new Uint8Array(n); + for (i = 0; i < n; ++i) { + result[i] = text.charCodeAt(i) & 0xFF; + } + return result.buffer; + } + }); +})(); + +// window.btoa (base64 encode function) ? +// Support: IE<10 +(function checkWindowBtoaCompatibility() { + if ('btoa' in window) { + return; + } + + var digits = + 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='; + + window.btoa = function windowBtoa(chars) { + var buffer = ''; + var i, n; + for (i = 0, n = chars.length; i < n; i += 3) { + var b1 = chars.charCodeAt(i) & 0xFF; + var b2 = chars.charCodeAt(i + 1) & 0xFF; + var b3 = chars.charCodeAt(i + 2) & 0xFF; + var d1 = b1 >> 2, d2 = ((b1 & 3) << 4) | (b2 >> 4); + var d3 = i + 1 < n ? ((b2 & 0xF) << 2) | (b3 >> 6) : 64; + var d4 = i + 2 < n ? (b3 & 0x3F) : 64; + buffer += (digits.charAt(d1) + digits.charAt(d2) + + digits.charAt(d3) + digits.charAt(d4)); + } + return buffer; + }; +})(); + +// window.atob (base64 encode function)? +// Support: IE<10 +(function checkWindowAtobCompatibility() { + if ('atob' in window) { + return; + } + + // https://github.com/davidchambers/Base64.js + var digits = + 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='; + window.atob = function (input) { + input = input.replace(/=+$/, ''); + if (input.length % 4 === 1) { + throw new Error('bad atob input'); + } + for ( + // initialize result and counters + var bc = 0, bs, buffer, idx = 0, output = ''; + // get next character + buffer = input.charAt(idx++); + // character found in table? + // initialize bit storage and add its ascii value + ~buffer && (bs = bc % 4 ? bs * 64 + buffer : buffer, + // and if not first of each 4 characters, + // convert the first 8 bits to one ascii character + bc++ % 4) ? output += String.fromCharCode(255 & bs >> (-2 * bc & 6)) : 0 + ) { + // try to find character in table (0-63, not found => -1) + buffer = digits.indexOf(buffer); + } + return output; + }; +})(); + +// Function.prototype.bind? +// Support: Android<4.0, iOS<6.0 +(function checkFunctionPrototypeBindCompatibility() { + if (typeof Function.prototype.bind !== 'undefined') { + return; + } + + Function.prototype.bind = function functionPrototypeBind(obj) { + var fn = this, headArgs = Array.prototype.slice.call(arguments, 1); + var bound = function functionPrototypeBindBound() { + var args = headArgs.concat(Array.prototype.slice.call(arguments)); + return fn.apply(obj, args); + }; + return bound; + }; +})(); + +// HTMLElement dataset property +// Support: IE<11, Safari<5.1, Android<4.0 +(function checkDatasetProperty() { + var div = document.createElement('div'); + if ('dataset' in div) { + return; // dataset property exists + } + + Object.defineProperty(HTMLElement.prototype, 'dataset', { + get: function() { + if (this._dataset) { + return this._dataset; + } + + var dataset = {}; + for (var j = 0, jj = this.attributes.length; j < jj; j++) { + var attribute = this.attributes[j]; + if (attribute.name.substring(0, 5) !== 'data-') { + continue; + } + var key = attribute.name.substring(5).replace(/\-([a-z])/g, + function(all, ch) { + return ch.toUpperCase(); + }); + dataset[key] = attribute.value; + } + + Object.defineProperty(this, '_dataset', { + value: dataset, + writable: false, + enumerable: false + }); + return dataset; + }, + enumerable: true + }); +})(); + +// HTMLElement classList property +// Support: IE<10, Android<4.0, iOS<5.0 +(function checkClassListProperty() { + var div = document.createElement('div'); + if ('classList' in div) { + return; // classList property exists + } + + function changeList(element, itemName, add, remove) { + var s = element.className || ''; + var list = s.split(/\s+/g); + if (list[0] === '') { + list.shift(); + } + var index = list.indexOf(itemName); + if (index < 0 && add) { + list.push(itemName); + } + if (index >= 0 && remove) { + list.splice(index, 1); + } + element.className = list.join(' '); + return (index >= 0); + } + + var classListPrototype = { + add: function(name) { + changeList(this.element, name, true, false); + }, + contains: function(name) { + return changeList(this.element, name, false, false); + }, + remove: function(name) { + changeList(this.element, name, false, true); + }, + toggle: function(name) { + changeList(this.element, name, true, true); + } + }; + + Object.defineProperty(HTMLElement.prototype, 'classList', { + get: function() { + if (this._classList) { + return this._classList; + } + + var classList = Object.create(classListPrototype, { + element: { + value: this, + writable: false, + enumerable: true + } + }); + Object.defineProperty(this, '_classList', { + value: classList, + writable: false, + enumerable: false + }); + return classList; + }, + enumerable: true + }); +})(); + +// Check console compatibility +// In older IE versions the console object is not available +// unless console is open. +// Support: IE<10 +(function checkConsoleCompatibility() { + if (!('console' in window)) { + window.console = { + log: function() {}, + error: function() {}, + warn: function() {} + }; + } else if (!('bind' in console.log)) { + // native functions in IE9 might not have bind + console.log = (function(fn) { + return function(msg) { return fn(msg); }; + })(console.log); + console.error = (function(fn) { + return function(msg) { return fn(msg); }; + })(console.error); + console.warn = (function(fn) { + return function(msg) { return fn(msg); }; + })(console.warn); + } +})(); + +// Check onclick compatibility in Opera +// Support: Opera<15 +(function checkOnClickCompatibility() { + // workaround for reported Opera bug DSK-354448: + // onclick fires on disabled buttons with opaque content + function ignoreIfTargetDisabled(event) { + if (isDisabled(event.target)) { + event.stopPropagation(); + } + } + function isDisabled(node) { + return node.disabled || (node.parentNode && isDisabled(node.parentNode)); + } + if (navigator.userAgent.indexOf('Opera') !== -1) { + // use browser detection since we cannot feature-check this bug + document.addEventListener('click', ignoreIfTargetDisabled, true); + } +})(); + +// Checks if possible to use URL.createObjectURL() +// Support: IE +(function checkOnBlobSupport() { + // sometimes IE loosing the data created with createObjectURL(), see #3977 + if (navigator.userAgent.indexOf('Trident') >= 0) { + PDFJS.disableCreateObjectURL = true; + } +})(); + +// Checks if navigator.language is supported +(function checkNavigatorLanguage() { + if ('language' in navigator) { + return; + } + PDFJS.locale = navigator.userLanguage || 'en-US'; +})(); + +(function checkRangeRequests() { + // Safari has issues with cached range requests see: + // https://github.com/mozilla/pdf.js/issues/3260 + // Last tested with version 6.0.4. + // Support: Safari 6.0+ + var isSafari = Object.prototype.toString.call( + window.HTMLElement).indexOf('Constructor') > 0; + + // Older versions of Android (pre 3.0) has issues with range requests, see: + // https://github.com/mozilla/pdf.js/issues/3381. + // Make sure that we only match webkit-based Android browsers, + // since Firefox/Fennec works as expected. + // Support: Android<3.0 + var regex = /Android\s[0-2][^\d]/; + var isOldAndroid = regex.test(navigator.userAgent); + + // Range requests are broken in Chrome 39 and 40, https://crbug.com/442318 + var isChromeWithRangeBug = /Chrome\/(39|40)\./.test(navigator.userAgent); + + if (isSafari || isOldAndroid || isChromeWithRangeBug) { + PDFJS.disableRange = true; + PDFJS.disableStream = true; + } +})(); + +// Check if the browser supports manipulation of the history. +// Support: IE<10, Android<4.2 +(function checkHistoryManipulation() { + // Android 2.x has so buggy pushState support that it was removed in + // Android 3.0 and restored as late as in Android 4.2. + // Support: Android 2.x + if (!history.pushState || navigator.userAgent.indexOf('Android 2.') >= 0) { + PDFJS.disableHistory = true; + } +})(); + +// Support: IE<11, Chrome<21, Android<4.4, Safari<6 +(function checkSetPresenceInImageData() { + // IE < 11 will use window.CanvasPixelArray which lacks set function. + if (window.CanvasPixelArray) { + if (typeof window.CanvasPixelArray.prototype.set !== 'function') { + window.CanvasPixelArray.prototype.set = function(arr) { + for (var i = 0, ii = this.length; i < ii; i++) { + this[i] = arr[i]; + } + }; + } + } else { + // Old Chrome and Android use an inaccessible CanvasPixelArray prototype. + // Because we cannot feature detect it, we rely on user agent parsing. + var polyfill = false, versionMatch; + if (navigator.userAgent.indexOf('Chrom') >= 0) { + versionMatch = navigator.userAgent.match(/Chrom(e|ium)\/([0-9]+)\./); + // Chrome < 21 lacks the set function. + polyfill = versionMatch && parseInt(versionMatch[2]) < 21; + } else if (navigator.userAgent.indexOf('Android') >= 0) { + // Android < 4.4 lacks the set function. + // Android >= 4.4 will contain Chrome in the user agent, + // thus pass the Chrome check above and not reach this block. + polyfill = /Android\s[0-4][^\d]/g.test(navigator.userAgent); + } else if (navigator.userAgent.indexOf('Safari') >= 0) { + versionMatch = navigator.userAgent. + match(/Version\/([0-9]+)\.([0-9]+)\.([0-9]+) Safari\//); + // Safari < 6 lacks the set function. + polyfill = versionMatch && parseInt(versionMatch[1]) < 6; + } + + if (polyfill) { + var contextPrototype = window.CanvasRenderingContext2D.prototype; + var createImageData = contextPrototype.createImageData; + contextPrototype.createImageData = function(w, h) { + var imageData = createImageData.call(this, w, h); + imageData.data.set = function(arr) { + for (var i = 0, ii = this.length; i < ii; i++) { + this[i] = arr[i]; + } + }; + return imageData; + }; + // this closure will be kept referenced, so clear its vars + contextPrototype = null; + } + } +})(); + +// Support: IE<10, Android<4.0, iOS +(function checkRequestAnimationFrame() { + function fakeRequestAnimationFrame(callback) { + window.setTimeout(callback, 20); + } + + var isIOS = /(iPad|iPhone|iPod)/g.test(navigator.userAgent); + if (isIOS) { + // requestAnimationFrame on iOS is broken, replacing with fake one. + window.requestAnimationFrame = fakeRequestAnimationFrame; + return; + } + if ('requestAnimationFrame' in window) { + return; + } + window.requestAnimationFrame = + window.mozRequestAnimationFrame || + window.webkitRequestAnimationFrame || + fakeRequestAnimationFrame; +})(); + +(function checkCanvasSizeLimitation() { + var isIOS = /(iPad|iPhone|iPod)/g.test(navigator.userAgent); + var isAndroid = /Android/g.test(navigator.userAgent); + if (isIOS || isAndroid) { + // 5MP + PDFJS.maxCanvasPixels = 5242880; + } +})(); + +// Disable fullscreen support for certain problematic configurations. +// Support: IE11+ (when embedded). +(function checkFullscreenSupport() { + var isEmbeddedIE = (navigator.userAgent.indexOf('Trident') >= 0 && + window.parent !== window); + if (isEmbeddedIE) { + PDFJS.disableFullscreen = true; + } +})(); + +// Provides document.currentScript support +// Support: IE, Chrome<29. +(function checkCurrentScript() { + if ('currentScript' in document) { + return; + } + Object.defineProperty(document, 'currentScript', { + get: function () { + var scripts = document.getElementsByTagName('script'); + return scripts[scripts.length - 1]; + }, + enumerable: true, + configurable: true + }); +})(); diff --git a/static/pdf.js/custom/toolbarButton-crop.png b/static/pdf.js/custom/toolbarButton-crop.png deleted file mode 100644 index 00c56d52..00000000 Binary files a/static/pdf.js/custom/toolbarButton-crop.png and /dev/null differ diff --git a/static/pdf.js/custom/toolbarButton-crop.svg b/static/pdf.js/custom/toolbarButton-crop.svg deleted file mode 100644 index 618195a1..00000000 --- a/static/pdf.js/custom/toolbarButton-crop.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/static/pdf.js/custom/toolbarButton-crop@10.png b/static/pdf.js/custom/toolbarButton-crop@10.png deleted file mode 100644 index 7cc05e5d..00000000 Binary files a/static/pdf.js/custom/toolbarButton-crop@10.png and /dev/null differ diff --git a/static/pdf.js/custom/toolbarButton-crop@2x.png b/static/pdf.js/custom/toolbarButton-crop@2x.png deleted file mode 100644 index 950d2758..00000000 Binary files a/static/pdf.js/custom/toolbarButton-crop@2x.png and /dev/null differ diff --git a/static/pdf.js/debugger.css b/static/pdf.js/debugger.css deleted file mode 100644 index b9d9f819..00000000 --- a/static/pdf.js/debugger.css +++ /dev/null @@ -1,111 +0,0 @@ -/* Copyright 2014 Mozilla Foundation - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -:root { - --panel-width: 300px; -} - -#PDFBug, -#PDFBug :is(input, button, select) { - font: message-box; -} -#PDFBug { - background-color: rgb(255 255 255); - border: 1px solid rgb(102 102 102); - position: fixed; - top: 32px; - right: 0; - bottom: 0; - font-size: 10px; - padding: 0; - width: var(--panel-width); -} -#PDFBug .controls { - background: rgb(238 238 238); - border-bottom: 1px solid rgb(102 102 102); - padding: 3px; -} -#PDFBug .panels { - inset: 27px 0 0; - overflow: auto; - position: absolute; -} -#PDFBug .panels > div { - padding: 5px; -} -#PDFBug button.active { - font-weight: bold; -} -.debuggerShowText, -.debuggerHideText:hover { - background-color: rgb(255 255 0 / 0.25); -} -#PDFBug .stats { - font-family: courier; - font-size: 10px; - white-space: pre; -} -#PDFBug .stats .title { - font-weight: bold; -} -#PDFBug table { - font-size: 10px; - white-space: pre; -} -#PDFBug table.showText { - border-collapse: collapse; - text-align: center; -} -#PDFBug table.showText, -#PDFBug table.showText :is(tr, td) { - border: 1px solid black; - padding: 1px; -} -#PDFBug table.showText td.advance { - color: grey; -} - -#viewer.textLayer-visible .textLayer { - opacity: 1; -} - -#viewer.textLayer-visible .canvasWrapper { - background-color: rgb(128 255 128); -} - -#viewer.textLayer-visible .canvasWrapper canvas { - mix-blend-mode: screen; -} - -#viewer.textLayer-visible .textLayer span { - background-color: rgb(255 255 0 / 0.1); - color: rgb(0 0 0); - border: solid 1px rgb(255 0 0 / 0.5); - box-sizing: border-box; -} - -#viewer.textLayer-visible .textLayer span[aria-owns] { - background-color: rgb(255 0 0 / 0.3); -} - -#viewer.textLayer-hover .textLayer span:hover { - background-color: rgb(255 255 255); - color: rgb(0 0 0); -} - -#viewer.textLayer-shadow .textLayer span { - background-color: rgb(255 255 255 / 0.6); - color: rgb(0 0 0); -} diff --git a/static/pdf.js/debugger.js b/static/pdf.js/debugger.js new file mode 100644 index 00000000..19d29163 --- /dev/null +++ b/static/pdf.js/debugger.js @@ -0,0 +1,618 @@ +/* Copyright 2012 Mozilla Foundation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/* globals PDFJS */ + +'use strict'; + +var FontInspector = (function FontInspectorClosure() { + var fonts; + var active = false; + var fontAttribute = 'data-font-name'; + function removeSelection() { + var divs = document.querySelectorAll('div[' + fontAttribute + ']'); + for (var i = 0, ii = divs.length; i < ii; ++i) { + var div = divs[i]; + div.className = ''; + } + } + function resetSelection() { + var divs = document.querySelectorAll('div[' + fontAttribute + ']'); + for (var i = 0, ii = divs.length; i < ii; ++i) { + var div = divs[i]; + div.className = 'debuggerHideText'; + } + } + function selectFont(fontName, show) { + var divs = document.querySelectorAll('div[' + fontAttribute + '=' + + fontName + ']'); + for (var i = 0, ii = divs.length; i < ii; ++i) { + var div = divs[i]; + div.className = show ? 'debuggerShowText' : 'debuggerHideText'; + } + } + function textLayerClick(e) { + if (!e.target.dataset.fontName || + e.target.tagName.toUpperCase() !== 'DIV') { + return; + } + var fontName = e.target.dataset.fontName; + var selects = document.getElementsByTagName('input'); + for (var i = 0; i < selects.length; ++i) { + var select = selects[i]; + if (select.dataset.fontName !== fontName) { + continue; + } + select.checked = !select.checked; + selectFont(fontName, select.checked); + select.scrollIntoView(); + } + } + return { + // Properties/functions needed by PDFBug. + id: 'FontInspector', + name: 'Font Inspector', + panel: null, + manager: null, + init: function init() { + var panel = this.panel; + panel.setAttribute('style', 'padding: 5px;'); + var tmp = document.createElement('button'); + tmp.addEventListener('click', resetSelection); + tmp.textContent = 'Refresh'; + panel.appendChild(tmp); + + fonts = document.createElement('div'); + panel.appendChild(fonts); + }, + cleanup: function cleanup() { + fonts.textContent = ''; + }, + enabled: false, + get active() { + return active; + }, + set active(value) { + active = value; + if (active) { + document.body.addEventListener('click', textLayerClick, true); + resetSelection(); + } else { + document.body.removeEventListener('click', textLayerClick, true); + removeSelection(); + } + }, + // FontInspector specific functions. + fontAdded: function fontAdded(fontObj, url) { + function properties(obj, list) { + var moreInfo = document.createElement('table'); + for (var i = 0; i < list.length; i++) { + var tr = document.createElement('tr'); + var td1 = document.createElement('td'); + td1.textContent = list[i]; + tr.appendChild(td1); + var td2 = document.createElement('td'); + td2.textContent = obj[list[i]].toString(); + tr.appendChild(td2); + moreInfo.appendChild(tr); + } + return moreInfo; + } + var moreInfo = properties(fontObj, ['name', 'type']); + var fontName = fontObj.loadedName; + var font = document.createElement('div'); + var name = document.createElement('span'); + name.textContent = fontName; + var download = document.createElement('a'); + if (url) { + url = /url\(['"]?([^\)"']+)/.exec(url); + download.href = url[1]; + } else if (fontObj.data) { + url = URL.createObjectURL(new Blob([fontObj.data], { + type: fontObj.mimeType + })); + download.href = url; + } + download.textContent = 'Download'; + var logIt = document.createElement('a'); + logIt.href = ''; + logIt.textContent = 'Log'; + logIt.addEventListener('click', function(event) { + event.preventDefault(); + console.log(fontObj); + }); + var select = document.createElement('input'); + select.setAttribute('type', 'checkbox'); + select.dataset.fontName = fontName; + select.addEventListener('click', (function(select, fontName) { + return (function() { + selectFont(fontName, select.checked); + }); + })(select, fontName)); + font.appendChild(select); + font.appendChild(name); + font.appendChild(document.createTextNode(' ')); + font.appendChild(download); + font.appendChild(document.createTextNode(' ')); + font.appendChild(logIt); + font.appendChild(moreInfo); + fonts.appendChild(font); + // Somewhat of a hack, should probably add a hook for when the text layer + // is done rendering. + setTimeout(function() { + if (this.active) { + resetSelection(); + } + }.bind(this), 2000); + } + }; +})(); + +// Manages all the page steppers. +var StepperManager = (function StepperManagerClosure() { + var steppers = []; + var stepperDiv = null; + var stepperControls = null; + var stepperChooser = null; + var breakPoints = Object.create(null); + return { + // Properties/functions needed by PDFBug. + id: 'Stepper', + name: 'Stepper', + panel: null, + manager: null, + init: function init() { + var self = this; + this.panel.setAttribute('style', 'padding: 5px;'); + stepperControls = document.createElement('div'); + stepperChooser = document.createElement('select'); + stepperChooser.addEventListener('change', function(event) { + self.selectStepper(this.value); + }); + stepperControls.appendChild(stepperChooser); + stepperDiv = document.createElement('div'); + this.panel.appendChild(stepperControls); + this.panel.appendChild(stepperDiv); + if (sessionStorage.getItem('pdfjsBreakPoints')) { + breakPoints = JSON.parse(sessionStorage.getItem('pdfjsBreakPoints')); + } + }, + cleanup: function cleanup() { + stepperChooser.textContent = ''; + stepperDiv.textContent = ''; + steppers = []; + }, + enabled: false, + active: false, + // Stepper specific functions. + create: function create(pageIndex) { + var debug = document.createElement('div'); + debug.id = 'stepper' + pageIndex; + debug.setAttribute('hidden', true); + debug.className = 'stepper'; + stepperDiv.appendChild(debug); + var b = document.createElement('option'); + b.textContent = 'Page ' + (pageIndex + 1); + b.value = pageIndex; + stepperChooser.appendChild(b); + var initBreakPoints = breakPoints[pageIndex] || []; + var stepper = new Stepper(debug, pageIndex, initBreakPoints); + steppers.push(stepper); + if (steppers.length === 1) { + this.selectStepper(pageIndex, false); + } + return stepper; + }, + selectStepper: function selectStepper(pageIndex, selectPanel) { + var i; + pageIndex = pageIndex | 0; + if (selectPanel) { + this.manager.selectPanel(this); + } + for (i = 0; i < steppers.length; ++i) { + var stepper = steppers[i]; + if (stepper.pageIndex === pageIndex) { + stepper.panel.removeAttribute('hidden'); + } else { + stepper.panel.setAttribute('hidden', true); + } + } + var options = stepperChooser.options; + for (i = 0; i < options.length; ++i) { + var option = options[i]; + option.selected = (option.value | 0) === pageIndex; + } + }, + saveBreakPoints: function saveBreakPoints(pageIndex, bps) { + breakPoints[pageIndex] = bps; + sessionStorage.setItem('pdfjsBreakPoints', JSON.stringify(breakPoints)); + } + }; +})(); + +// The stepper for each page's IRQueue. +var Stepper = (function StepperClosure() { + // Shorter way to create element and optionally set textContent. + function c(tag, textContent) { + var d = document.createElement(tag); + if (textContent) { + d.textContent = textContent; + } + return d; + } + + var opMap = null; + + function simplifyArgs(args) { + if (typeof args === 'string') { + var MAX_STRING_LENGTH = 75; + return args.length <= MAX_STRING_LENGTH ? args : + args.substr(0, MAX_STRING_LENGTH) + '...'; + } + if (typeof args !== 'object' || args === null) { + return args; + } + if ('length' in args) { // array + var simpleArgs = [], i, ii; + var MAX_ITEMS = 10; + for (i = 0, ii = Math.min(MAX_ITEMS, args.length); i < ii; i++) { + simpleArgs.push(simplifyArgs(args[i])); + } + if (i < args.length) { + simpleArgs.push('...'); + } + return simpleArgs; + } + var simpleObj = {}; + for (var key in args) { + simpleObj[key] = simplifyArgs(args[key]); + } + return simpleObj; + } + + function Stepper(panel, pageIndex, initialBreakPoints) { + this.panel = panel; + this.breakPoint = 0; + this.nextBreakPoint = null; + this.pageIndex = pageIndex; + this.breakPoints = initialBreakPoints; + this.currentIdx = -1; + this.operatorListIdx = 0; + } + Stepper.prototype = { + init: function init() { + var panel = this.panel; + var content = c('div', 'c=continue, s=step'); + var table = c('table'); + content.appendChild(table); + table.cellSpacing = 0; + var headerRow = c('tr'); + table.appendChild(headerRow); + headerRow.appendChild(c('th', 'Break')); + headerRow.appendChild(c('th', 'Idx')); + headerRow.appendChild(c('th', 'fn')); + headerRow.appendChild(c('th', 'args')); + panel.appendChild(content); + this.table = table; + if (!opMap) { + opMap = Object.create(null); + for (var key in PDFJS.OPS) { + opMap[PDFJS.OPS[key]] = key; + } + } + }, + updateOperatorList: function updateOperatorList(operatorList) { + var self = this; + + function cboxOnClick() { + var x = +this.dataset.idx; + if (this.checked) { + self.breakPoints.push(x); + } else { + self.breakPoints.splice(self.breakPoints.indexOf(x), 1); + } + StepperManager.saveBreakPoints(self.pageIndex, self.breakPoints); + } + + var MAX_OPERATORS_COUNT = 15000; + if (this.operatorListIdx > MAX_OPERATORS_COUNT) { + return; + } + + var chunk = document.createDocumentFragment(); + var operatorsToDisplay = Math.min(MAX_OPERATORS_COUNT, + operatorList.fnArray.length); + for (var i = this.operatorListIdx; i < operatorsToDisplay; i++) { + var line = c('tr'); + line.className = 'line'; + line.dataset.idx = i; + chunk.appendChild(line); + var checked = this.breakPoints.indexOf(i) !== -1; + var args = operatorList.argsArray[i] || []; + + var breakCell = c('td'); + var cbox = c('input'); + cbox.type = 'checkbox'; + cbox.className = 'points'; + cbox.checked = checked; + cbox.dataset.idx = i; + cbox.onclick = cboxOnClick; + + breakCell.appendChild(cbox); + line.appendChild(breakCell); + line.appendChild(c('td', i.toString())); + var fn = opMap[operatorList.fnArray[i]]; + var decArgs = args; + if (fn === 'showText') { + var glyphs = args[0]; + var newArgs = []; + var str = []; + for (var j = 0; j < glyphs.length; j++) { + var glyph = glyphs[j]; + if (typeof glyph === 'object' && glyph !== null) { + str.push(glyph.fontChar); + } else { + if (str.length > 0) { + newArgs.push(str.join('')); + str = []; + } + newArgs.push(glyph); // null or number + } + } + if (str.length > 0) { + newArgs.push(str.join('')); + } + decArgs = [newArgs]; + } + line.appendChild(c('td', fn)); + line.appendChild(c('td', JSON.stringify(simplifyArgs(decArgs)))); + } + if (operatorsToDisplay < operatorList.fnArray.length) { + line = c('tr'); + var lastCell = c('td', '...'); + lastCell.colspan = 4; + chunk.appendChild(lastCell); + } + this.operatorListIdx = operatorList.fnArray.length; + this.table.appendChild(chunk); + }, + getNextBreakPoint: function getNextBreakPoint() { + this.breakPoints.sort(function(a, b) { return a - b; }); + for (var i = 0; i < this.breakPoints.length; i++) { + if (this.breakPoints[i] > this.currentIdx) { + return this.breakPoints[i]; + } + } + return null; + }, + breakIt: function breakIt(idx, callback) { + StepperManager.selectStepper(this.pageIndex, true); + var self = this; + var dom = document; + self.currentIdx = idx; + var listener = function(e) { + switch (e.keyCode) { + case 83: // step + dom.removeEventListener('keydown', listener, false); + self.nextBreakPoint = self.currentIdx + 1; + self.goTo(-1); + callback(); + break; + case 67: // continue + dom.removeEventListener('keydown', listener, false); + var breakPoint = self.getNextBreakPoint(); + self.nextBreakPoint = breakPoint; + self.goTo(-1); + callback(); + break; + } + }; + dom.addEventListener('keydown', listener, false); + self.goTo(idx); + }, + goTo: function goTo(idx) { + var allRows = this.panel.getElementsByClassName('line'); + for (var x = 0, xx = allRows.length; x < xx; ++x) { + var row = allRows[x]; + if ((row.dataset.idx | 0) === idx) { + row.style.backgroundColor = 'rgb(251,250,207)'; + row.scrollIntoView(); + } else { + row.style.backgroundColor = null; + } + } + } + }; + return Stepper; +})(); + +var Stats = (function Stats() { + var stats = []; + function clear(node) { + while (node.hasChildNodes()) { + node.removeChild(node.lastChild); + } + } + function getStatIndex(pageNumber) { + for (var i = 0, ii = stats.length; i < ii; ++i) { + if (stats[i].pageNumber === pageNumber) { + return i; + } + } + return false; + } + return { + // Properties/functions needed by PDFBug. + id: 'Stats', + name: 'Stats', + panel: null, + manager: null, + init: function init() { + this.panel.setAttribute('style', 'padding: 5px;'); + PDFJS.enableStats = true; + }, + enabled: false, + active: false, + // Stats specific functions. + add: function(pageNumber, stat) { + if (!stat) { + return; + } + var statsIndex = getStatIndex(pageNumber); + if (statsIndex !== false) { + var b = stats[statsIndex]; + this.panel.removeChild(b.div); + stats.splice(statsIndex, 1); + } + var wrapper = document.createElement('div'); + wrapper.className = 'stats'; + var title = document.createElement('div'); + title.className = 'title'; + title.textContent = 'Page: ' + pageNumber; + var statsDiv = document.createElement('div'); + statsDiv.textContent = stat.toString(); + wrapper.appendChild(title); + wrapper.appendChild(statsDiv); + stats.push({ pageNumber: pageNumber, div: wrapper }); + stats.sort(function(a, b) { return a.pageNumber - b.pageNumber; }); + clear(this.panel); + for (var i = 0, ii = stats.length; i < ii; ++i) { + this.panel.appendChild(stats[i].div); + } + }, + cleanup: function () { + stats = []; + clear(this.panel); + } + }; +})(); + +// Manages all the debugging tools. +var PDFBug = (function PDFBugClosure() { + var panelWidth = 300; + var buttons = []; + var activePanel = null; + + return { + tools: [ + FontInspector, + StepperManager, + Stats + ], + enable: function(ids) { + var all = false, tools = this.tools; + if (ids.length === 1 && ids[0] === 'all') { + all = true; + } + for (var i = 0; i < tools.length; ++i) { + var tool = tools[i]; + if (all || ids.indexOf(tool.id) !== -1) { + tool.enabled = true; + } + } + if (!all) { + // Sort the tools by the order they are enabled. + tools.sort(function(a, b) { + var indexA = ids.indexOf(a.id); + indexA = indexA < 0 ? tools.length : indexA; + var indexB = ids.indexOf(b.id); + indexB = indexB < 0 ? tools.length : indexB; + return indexA - indexB; + }); + } + }, + init: function init() { + /* + * Basic Layout: + * PDFBug + * Controls + * Panels + * Panel + * Panel + * ... + */ + var ui = document.createElement('div'); + ui.id = 'PDFBug'; + + var controls = document.createElement('div'); + controls.setAttribute('class', 'controls'); + ui.appendChild(controls); + + var panels = document.createElement('div'); + panels.setAttribute('class', 'panels'); + ui.appendChild(panels); + + var container = document.getElementById('viewerContainer'); + container.appendChild(ui); + container.style.right = panelWidth + 'px'; + + // Initialize all the debugging tools. + var tools = this.tools; + var self = this; + for (var i = 0; i < tools.length; ++i) { + var tool = tools[i]; + var panel = document.createElement('div'); + var panelButton = document.createElement('button'); + panelButton.textContent = tool.name; + panelButton.addEventListener('click', (function(selected) { + return function(event) { + event.preventDefault(); + self.selectPanel(selected); + }; + })(i)); + controls.appendChild(panelButton); + panels.appendChild(panel); + tool.panel = panel; + tool.manager = this; + if (tool.enabled) { + tool.init(); + } else { + panel.textContent = tool.name + ' is disabled. To enable add ' + + ' "' + tool.id + '" to the pdfBug parameter ' + + 'and refresh (seperate multiple by commas).'; + } + buttons.push(panelButton); + } + this.selectPanel(0); + }, + cleanup: function cleanup() { + for (var i = 0, ii = this.tools.length; i < ii; i++) { + if (this.tools[i].enabled) { + this.tools[i].cleanup(); + } + } + }, + selectPanel: function selectPanel(index) { + if (typeof index !== 'number') { + index = this.tools.indexOf(index); + } + if (index === activePanel) { + return; + } + activePanel = index; + var tools = this.tools; + for (var j = 0; j < tools.length; ++j) { + if (j === index) { + buttons[j].setAttribute('class', 'active'); + tools[j].active = true; + tools[j].panel.removeAttribute('hidden'); + } else { + buttons[j].setAttribute('class', ''); + tools[j].active = false; + tools[j].panel.setAttribute('hidden', 'true'); + } + } + } + }; +})(); diff --git a/static/pdf.js/debugger.mjs b/static/pdf.js/debugger.mjs deleted file mode 100644 index 59c1871b..00000000 --- a/static/pdf.js/debugger.mjs +++ /dev/null @@ -1,623 +0,0 @@ -/* Copyright 2012 Mozilla Foundation - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -const { OPS } = globalThis.pdfjsLib || (await import("pdfjs-lib")); - -const opMap = Object.create(null); -for (const key in OPS) { - opMap[OPS[key]] = key; -} - -const FontInspector = (function FontInspectorClosure() { - let fonts; - let active = false; - const fontAttribute = "data-font-name"; - function removeSelection() { - const divs = document.querySelectorAll(`span[${fontAttribute}]`); - for (const div of divs) { - div.className = ""; - } - } - function resetSelection() { - const divs = document.querySelectorAll(`span[${fontAttribute}]`); - for (const div of divs) { - div.className = "debuggerHideText"; - } - } - function selectFont(fontName, show) { - const divs = document.querySelectorAll( - `span[${fontAttribute}=${fontName}]` - ); - for (const div of divs) { - div.className = show ? "debuggerShowText" : "debuggerHideText"; - } - } - function textLayerClick(e) { - if ( - !e.target.dataset.fontName || - e.target.tagName.toUpperCase() !== "SPAN" - ) { - return; - } - const fontName = e.target.dataset.fontName; - const selects = document.getElementsByTagName("input"); - for (const select of selects) { - if (select.dataset.fontName !== fontName) { - continue; - } - select.checked = !select.checked; - selectFont(fontName, select.checked); - select.scrollIntoView(); - } - } - return { - // Properties/functions needed by PDFBug. - id: "FontInspector", - name: "Font Inspector", - panel: null, - manager: null, - init() { - const panel = this.panel; - const tmp = document.createElement("button"); - tmp.addEventListener("click", resetSelection); - tmp.textContent = "Refresh"; - panel.append(tmp); - - fonts = document.createElement("div"); - panel.append(fonts); - }, - cleanup() { - fonts.textContent = ""; - }, - enabled: false, - get active() { - return active; - }, - set active(value) { - active = value; - if (active) { - document.body.addEventListener("click", textLayerClick, true); - resetSelection(); - } else { - document.body.removeEventListener("click", textLayerClick, true); - removeSelection(); - } - }, - // FontInspector specific functions. - fontAdded(fontObj, url) { - function properties(obj, list) { - const moreInfo = document.createElement("table"); - for (const entry of list) { - const tr = document.createElement("tr"); - const td1 = document.createElement("td"); - td1.textContent = entry; - tr.append(td1); - const td2 = document.createElement("td"); - td2.textContent = obj[entry].toString(); - tr.append(td2); - moreInfo.append(tr); - } - return moreInfo; - } - - const moreInfo = fontObj.css - ? properties(fontObj, ["baseFontName"]) - : properties(fontObj, ["name", "type"]); - - const fontName = fontObj.loadedName; - const font = document.createElement("div"); - const name = document.createElement("span"); - name.textContent = fontName; - let download; - if (!fontObj.css) { - download = document.createElement("a"); - if (url) { - url = /url\(['"]?([^)"']+)/.exec(url); - download.href = url[1]; - } else if (fontObj.data) { - download.href = URL.createObjectURL( - new Blob([fontObj.data], { type: fontObj.mimetype }) - ); - } - download.textContent = "Download"; - } - - const logIt = document.createElement("a"); - logIt.href = ""; - logIt.textContent = "Log"; - logIt.addEventListener("click", function (event) { - event.preventDefault(); - console.log(fontObj); - }); - const select = document.createElement("input"); - select.setAttribute("type", "checkbox"); - select.dataset.fontName = fontName; - select.addEventListener("click", function () { - selectFont(fontName, select.checked); - }); - if (download) { - font.append(select, name, " ", download, " ", logIt, moreInfo); - } else { - font.append(select, name, " ", logIt, moreInfo); - } - fonts.append(font); - // Somewhat of a hack, should probably add a hook for when the text layer - // is done rendering. - setTimeout(() => { - if (this.active) { - resetSelection(); - } - }, 2000); - }, - }; -})(); - -// Manages all the page steppers. -const StepperManager = (function StepperManagerClosure() { - let steppers = []; - let stepperDiv = null; - let stepperControls = null; - let stepperChooser = null; - let breakPoints = Object.create(null); - return { - // Properties/functions needed by PDFBug. - id: "Stepper", - name: "Stepper", - panel: null, - manager: null, - init() { - const self = this; - stepperControls = document.createElement("div"); - stepperChooser = document.createElement("select"); - stepperChooser.addEventListener("change", function (event) { - self.selectStepper(this.value); - }); - stepperControls.append(stepperChooser); - stepperDiv = document.createElement("div"); - this.panel.append(stepperControls, stepperDiv); - if (sessionStorage.getItem("pdfjsBreakPoints")) { - breakPoints = JSON.parse(sessionStorage.getItem("pdfjsBreakPoints")); - } - }, - cleanup() { - stepperChooser.textContent = ""; - stepperDiv.textContent = ""; - steppers = []; - }, - enabled: false, - active: false, - // Stepper specific functions. - create(pageIndex) { - const debug = document.createElement("div"); - debug.id = "stepper" + pageIndex; - debug.hidden = true; - debug.className = "stepper"; - stepperDiv.append(debug); - const b = document.createElement("option"); - b.textContent = "Page " + (pageIndex + 1); - b.value = pageIndex; - stepperChooser.append(b); - const initBreakPoints = breakPoints[pageIndex] || []; - const stepper = new Stepper(debug, pageIndex, initBreakPoints); - steppers.push(stepper); - if (steppers.length === 1) { - this.selectStepper(pageIndex, false); - } - return stepper; - }, - selectStepper(pageIndex, selectPanel) { - pageIndex |= 0; - if (selectPanel) { - this.manager.selectPanel(this); - } - for (const stepper of steppers) { - stepper.panel.hidden = stepper.pageIndex !== pageIndex; - } - for (const option of stepperChooser.options) { - option.selected = (option.value | 0) === pageIndex; - } - }, - saveBreakPoints(pageIndex, bps) { - breakPoints[pageIndex] = bps; - sessionStorage.setItem("pdfjsBreakPoints", JSON.stringify(breakPoints)); - }, - }; -})(); - -// The stepper for each page's operatorList. -class Stepper { - // Shorter way to create element and optionally set textContent. - #c(tag, textContent) { - const d = document.createElement(tag); - if (textContent) { - d.textContent = textContent; - } - return d; - } - - #simplifyArgs(args) { - if (typeof args === "string") { - const MAX_STRING_LENGTH = 75; - return args.length <= MAX_STRING_LENGTH - ? args - : args.substring(0, MAX_STRING_LENGTH) + "..."; - } - if (typeof args !== "object" || args === null) { - return args; - } - if ("length" in args) { - // array - const MAX_ITEMS = 10, - simpleArgs = []; - let i, ii; - for (i = 0, ii = Math.min(MAX_ITEMS, args.length); i < ii; i++) { - simpleArgs.push(this.#simplifyArgs(args[i])); - } - if (i < args.length) { - simpleArgs.push("..."); - } - return simpleArgs; - } - const simpleObj = {}; - for (const key in args) { - simpleObj[key] = this.#simplifyArgs(args[key]); - } - return simpleObj; - } - - constructor(panel, pageIndex, initialBreakPoints) { - this.panel = panel; - this.breakPoint = 0; - this.nextBreakPoint = null; - this.pageIndex = pageIndex; - this.breakPoints = initialBreakPoints; - this.currentIdx = -1; - this.operatorListIdx = 0; - this.indentLevel = 0; - } - - init(operatorList) { - const panel = this.panel; - const content = this.#c("div", "c=continue, s=step"); - const table = this.#c("table"); - content.append(table); - table.cellSpacing = 0; - const headerRow = this.#c("tr"); - table.append(headerRow); - headerRow.append( - this.#c("th", "Break"), - this.#c("th", "Idx"), - this.#c("th", "fn"), - this.#c("th", "args") - ); - panel.append(content); - this.table = table; - this.updateOperatorList(operatorList); - } - - updateOperatorList(operatorList) { - const self = this; - - function cboxOnClick() { - const x = +this.dataset.idx; - if (this.checked) { - self.breakPoints.push(x); - } else { - self.breakPoints.splice(self.breakPoints.indexOf(x), 1); - } - StepperManager.saveBreakPoints(self.pageIndex, self.breakPoints); - } - - const MAX_OPERATORS_COUNT = 15000; - if (this.operatorListIdx > MAX_OPERATORS_COUNT) { - return; - } - - const chunk = document.createDocumentFragment(); - const operatorsToDisplay = Math.min( - MAX_OPERATORS_COUNT, - operatorList.fnArray.length - ); - for (let i = this.operatorListIdx; i < operatorsToDisplay; i++) { - const line = this.#c("tr"); - line.className = "line"; - line.dataset.idx = i; - chunk.append(line); - const checked = this.breakPoints.includes(i); - const args = operatorList.argsArray[i] || []; - - const breakCell = this.#c("td"); - const cbox = this.#c("input"); - cbox.type = "checkbox"; - cbox.className = "points"; - cbox.checked = checked; - cbox.dataset.idx = i; - cbox.onclick = cboxOnClick; - - breakCell.append(cbox); - line.append(breakCell, this.#c("td", i.toString())); - const fn = opMap[operatorList.fnArray[i]]; - let decArgs = args; - if (fn === "showText") { - const glyphs = args[0]; - const charCodeRow = this.#c("tr"); - const fontCharRow = this.#c("tr"); - const unicodeRow = this.#c("tr"); - for (const glyph of glyphs) { - if (typeof glyph === "object" && glyph !== null) { - charCodeRow.append(this.#c("td", glyph.originalCharCode)); - fontCharRow.append(this.#c("td", glyph.fontChar)); - unicodeRow.append(this.#c("td", glyph.unicode)); - } else { - // null or number - const advanceEl = this.#c("td", glyph); - advanceEl.classList.add("advance"); - charCodeRow.append(advanceEl); - fontCharRow.append(this.#c("td")); - unicodeRow.append(this.#c("td")); - } - } - decArgs = this.#c("td"); - const table = this.#c("table"); - table.classList.add("showText"); - decArgs.append(table); - table.append(charCodeRow, fontCharRow, unicodeRow); - } else if (fn === "restore" && this.indentLevel > 0) { - this.indentLevel--; - } - line.append(this.#c("td", " ".repeat(this.indentLevel * 2) + fn)); - if (fn === "save") { - this.indentLevel++; - } - - if (decArgs instanceof HTMLElement) { - line.append(decArgs); - } else { - line.append(this.#c("td", JSON.stringify(this.#simplifyArgs(decArgs)))); - } - } - if (operatorsToDisplay < operatorList.fnArray.length) { - const lastCell = this.#c("td", "..."); - lastCell.colspan = 4; - chunk.append(lastCell); - } - this.operatorListIdx = operatorList.fnArray.length; - this.table.append(chunk); - } - - getNextBreakPoint() { - this.breakPoints.sort(function (a, b) { - return a - b; - }); - for (const breakPoint of this.breakPoints) { - if (breakPoint > this.currentIdx) { - return breakPoint; - } - } - return null; - } - - breakIt(idx, callback) { - StepperManager.selectStepper(this.pageIndex, true); - this.currentIdx = idx; - - const listener = evt => { - switch (evt.keyCode) { - case 83: // step - document.removeEventListener("keydown", listener); - this.nextBreakPoint = this.currentIdx + 1; - this.goTo(-1); - callback(); - break; - case 67: // continue - document.removeEventListener("keydown", listener); - this.nextBreakPoint = this.getNextBreakPoint(); - this.goTo(-1); - callback(); - break; - } - }; - document.addEventListener("keydown", listener); - this.goTo(idx); - } - - goTo(idx) { - const allRows = this.panel.getElementsByClassName("line"); - for (const row of allRows) { - if ((row.dataset.idx | 0) === idx) { - row.style.backgroundColor = "rgb(251,250,207)"; - row.scrollIntoView(); - } else { - row.style.backgroundColor = null; - } - } - } -} - -const Stats = (function Stats() { - let stats = []; - function clear(node) { - node.textContent = ""; // Remove any `node` contents from the DOM. - } - function getStatIndex(pageNumber) { - for (const [i, stat] of stats.entries()) { - if (stat.pageNumber === pageNumber) { - return i; - } - } - return false; - } - return { - // Properties/functions needed by PDFBug. - id: "Stats", - name: "Stats", - panel: null, - manager: null, - init() {}, - enabled: false, - active: false, - // Stats specific functions. - add(pageNumber, stat) { - if (!stat) { - return; - } - const statsIndex = getStatIndex(pageNumber); - if (statsIndex !== false) { - stats[statsIndex].div.remove(); - stats.splice(statsIndex, 1); - } - const wrapper = document.createElement("div"); - wrapper.className = "stats"; - const title = document.createElement("div"); - title.className = "title"; - title.textContent = "Page: " + pageNumber; - const statsDiv = document.createElement("div"); - statsDiv.textContent = stat.toString(); - wrapper.append(title, statsDiv); - stats.push({ pageNumber, div: wrapper }); - stats.sort(function (a, b) { - return a.pageNumber - b.pageNumber; - }); - clear(this.panel); - for (const entry of stats) { - this.panel.append(entry.div); - } - }, - cleanup() { - stats = []; - clear(this.panel); - }, - }; -})(); - -// Manages all the debugging tools. -class PDFBug { - static #buttons = []; - - static #activePanel = null; - - static tools = [FontInspector, StepperManager, Stats]; - - static enable(ids) { - const all = ids.length === 1 && ids[0] === "all"; - const tools = this.tools; - for (const tool of tools) { - if (all || ids.includes(tool.id)) { - tool.enabled = true; - } - } - if (!all) { - // Sort the tools by the order they are enabled. - tools.sort(function (a, b) { - let indexA = ids.indexOf(a.id); - indexA = indexA < 0 ? tools.length : indexA; - let indexB = ids.indexOf(b.id); - indexB = indexB < 0 ? tools.length : indexB; - return indexA - indexB; - }); - } - } - - static init(container, ids) { - this.loadCSS(); - this.enable(ids); - /* - * Basic Layout: - * PDFBug - * Controls - * Panels - * Panel - * Panel - * ... - */ - const ui = document.createElement("div"); - ui.id = "PDFBug"; - - const controls = document.createElement("div"); - controls.setAttribute("class", "controls"); - ui.append(controls); - - const panels = document.createElement("div"); - panels.setAttribute("class", "panels"); - ui.append(panels); - - container.append(ui); - container.style.right = "var(--panel-width)"; - - // Initialize all the debugging tools. - for (const tool of this.tools) { - const panel = document.createElement("div"); - const panelButton = document.createElement("button"); - panelButton.textContent = tool.name; - panelButton.addEventListener("click", event => { - event.preventDefault(); - this.selectPanel(tool); - }); - controls.append(panelButton); - panels.append(panel); - tool.panel = panel; - tool.manager = this; - if (tool.enabled) { - tool.init(); - } else { - panel.textContent = - `${tool.name} is disabled. To enable add "${tool.id}" to ` + - "the pdfBug parameter and refresh (separate multiple by commas)."; - } - this.#buttons.push(panelButton); - } - this.selectPanel(0); - } - - static loadCSS() { - const { url } = import.meta; - - const link = document.createElement("link"); - link.rel = "stylesheet"; - link.href = url.replace(/\.mjs$/, ".css"); - - document.head.append(link); - } - - static cleanup() { - for (const tool of this.tools) { - if (tool.enabled) { - tool.cleanup(); - } - } - } - - static selectPanel(index) { - if (typeof index !== "number") { - index = this.tools.indexOf(index); - } - if (index === this.#activePanel) { - return; - } - this.#activePanel = index; - for (const [j, tool] of this.tools.entries()) { - const isActive = j === index; - this.#buttons[j].classList.toggle("active", isActive); - tool.active = isActive; - tool.panel.hidden = !isActive; - } - } -} - -globalThis.FontInspector = FontInspector; -globalThis.StepperManager = StepperManager; -globalThis.Stats = Stats; - -export { PDFBug }; diff --git a/static/pdf.js/embeds.js b/static/pdf.js/embeds.js index c773feeb..d6e52d06 100644 --- a/static/pdf.js/embeds.js +++ b/static/pdf.js/embeds.js @@ -3,27 +3,25 @@ Ox.load({ loadCSS: false } }, function() { - var currentPage = PDFViewerApplication.page; - PDFViewerApplication.initializedPromise.then(function() { - PDFViewerApplication.pdfViewer.eventBus.on("pagechanging", function(event) { - var page = event.pageNumber; - if (page && page != currentPage) { - currentPage = page; - Ox.$parent.postMessage('page', { - page: page - }); - } - }) - }) + var currentPage = PDFView.page; + window.addEventListener('pagechange', function (evt) { + var page = evt.pageNumber; + if (page && page != currentPage) { + currentPage = page; + Ox.$parent.postMessage('page', { + page: Math.round(page) + }); + } + }); Ox.$parent.bindMessage({ page: function(data) { - if (data.page != PDFViewerApplication.page) { - PDFViewerApplication.page = data.page; + if (data.page != PDFView.page) { + PDFView.page = data.page; } }, pdf: function(data) { - if (PDFViewerApplication.url != data.pdf) { - PDFViewerApplication.open(data.pdf); + if (PDFView.url != data.pdf) { + PDFView.open(data.pdf); } } }); diff --git a/static/pdf.js/images/altText_add.svg b/static/pdf.js/images/altText_add.svg deleted file mode 100644 index 3451b536..00000000 --- a/static/pdf.js/images/altText_add.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/altText_done.svg b/static/pdf.js/images/altText_done.svg deleted file mode 100644 index f54924eb..00000000 --- a/static/pdf.js/images/altText_done.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/annotation-paperclip.svg b/static/pdf.js/images/annotation-paperclip.svg deleted file mode 100644 index 2bed2250..00000000 --- a/static/pdf.js/images/annotation-paperclip.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - diff --git a/static/pdf.js/images/annotation-pushpin.svg b/static/pdf.js/images/annotation-pushpin.svg deleted file mode 100644 index 6e0896cf..00000000 --- a/static/pdf.js/images/annotation-pushpin.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - diff --git a/static/pdf.js/images/cursor-editorFreeHighlight.svg b/static/pdf.js/images/cursor-editorFreeHighlight.svg deleted file mode 100644 index 513f6bdf..00000000 --- a/static/pdf.js/images/cursor-editorFreeHighlight.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/static/pdf.js/images/cursor-editorFreeText.svg b/static/pdf.js/images/cursor-editorFreeText.svg deleted file mode 100644 index de2838ef..00000000 --- a/static/pdf.js/images/cursor-editorFreeText.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/cursor-editorInk.svg b/static/pdf.js/images/cursor-editorInk.svg deleted file mode 100644 index 1dadb5c0..00000000 --- a/static/pdf.js/images/cursor-editorInk.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/static/pdf.js/images/cursor-editorTextHighlight.svg b/static/pdf.js/images/cursor-editorTextHighlight.svg deleted file mode 100644 index 800340cb..00000000 --- a/static/pdf.js/images/cursor-editorTextHighlight.svg +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - diff --git a/static/pdf.js/images/editor-toolbar-delete.svg b/static/pdf.js/images/editor-toolbar-delete.svg deleted file mode 100644 index f84520d8..00000000 --- a/static/pdf.js/images/editor-toolbar-delete.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - \ No newline at end of file diff --git a/static/pdf.js/images/findbarButton-next-rtl.png b/static/pdf.js/images/findbarButton-next-rtl.png new file mode 100644 index 00000000..bef02743 Binary files /dev/null and b/static/pdf.js/images/findbarButton-next-rtl.png differ diff --git a/static/pdf.js/images/findbarButton-next-rtl@2x.png b/static/pdf.js/images/findbarButton-next-rtl@2x.png new file mode 100644 index 00000000..1da6dc94 Binary files /dev/null and b/static/pdf.js/images/findbarButton-next-rtl@2x.png differ diff --git a/static/pdf.js/images/findbarButton-next.png b/static/pdf.js/images/findbarButton-next.png new file mode 100644 index 00000000..de1d0fc9 Binary files /dev/null and b/static/pdf.js/images/findbarButton-next.png differ diff --git a/static/pdf.js/images/findbarButton-next.svg b/static/pdf.js/images/findbarButton-next.svg deleted file mode 100644 index 8cb39bec..00000000 --- a/static/pdf.js/images/findbarButton-next.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/findbarButton-next@2x.png b/static/pdf.js/images/findbarButton-next@2x.png new file mode 100644 index 00000000..0250307c Binary files /dev/null and b/static/pdf.js/images/findbarButton-next@2x.png differ diff --git a/static/pdf.js/images/findbarButton-previous-rtl.png b/static/pdf.js/images/findbarButton-previous-rtl.png new file mode 100644 index 00000000..de1d0fc9 Binary files /dev/null and b/static/pdf.js/images/findbarButton-previous-rtl.png differ diff --git a/static/pdf.js/images/findbarButton-previous-rtl@2x.png b/static/pdf.js/images/findbarButton-previous-rtl@2x.png new file mode 100644 index 00000000..0250307c Binary files /dev/null and b/static/pdf.js/images/findbarButton-previous-rtl@2x.png differ diff --git a/static/pdf.js/images/findbarButton-previous.png b/static/pdf.js/images/findbarButton-previous.png new file mode 100644 index 00000000..bef02743 Binary files /dev/null and b/static/pdf.js/images/findbarButton-previous.png differ diff --git a/static/pdf.js/images/findbarButton-previous.svg b/static/pdf.js/images/findbarButton-previous.svg deleted file mode 100644 index b610879d..00000000 --- a/static/pdf.js/images/findbarButton-previous.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/findbarButton-previous@2x.png b/static/pdf.js/images/findbarButton-previous@2x.png new file mode 100644 index 00000000..1da6dc94 Binary files /dev/null and b/static/pdf.js/images/findbarButton-previous@2x.png differ diff --git a/static/pdf.js/images/grab.cur b/static/pdf.js/images/grab.cur new file mode 100644 index 00000000..db7ad5ae Binary files /dev/null and b/static/pdf.js/images/grab.cur differ diff --git a/static/pdf.js/images/grabbing.cur b/static/pdf.js/images/grabbing.cur new file mode 100644 index 00000000..e0dfd04e Binary files /dev/null and b/static/pdf.js/images/grabbing.cur differ diff --git a/static/pdf.js/images/gv-toolbarButton-download.svg b/static/pdf.js/images/gv-toolbarButton-download.svg deleted file mode 100644 index d56cf3ce..00000000 --- a/static/pdf.js/images/gv-toolbarButton-download.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/loading-small.png b/static/pdf.js/images/loading-small.png new file mode 100644 index 00000000..8831a805 Binary files /dev/null and b/static/pdf.js/images/loading-small.png differ diff --git a/static/pdf.js/images/loading-small@2x.png b/static/pdf.js/images/loading-small@2x.png new file mode 100644 index 00000000..b25b4452 Binary files /dev/null and b/static/pdf.js/images/loading-small@2x.png differ diff --git a/static/pdf.js/images/loading.svg b/static/pdf.js/images/loading.svg deleted file mode 100644 index 0a15ff68..00000000 --- a/static/pdf.js/images/loading.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/static/pdf.js/images/secondaryToolbarButton-documentProperties.png b/static/pdf.js/images/secondaryToolbarButton-documentProperties.png new file mode 100644 index 00000000..40925e25 Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-documentProperties.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-documentProperties.svg b/static/pdf.js/images/secondaryToolbarButton-documentProperties.svg deleted file mode 100644 index dd3917b9..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-documentProperties.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-documentProperties@2x.png b/static/pdf.js/images/secondaryToolbarButton-documentProperties@2x.png new file mode 100644 index 00000000..adb240ea Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-documentProperties@2x.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-firstPage.png b/static/pdf.js/images/secondaryToolbarButton-firstPage.png new file mode 100644 index 00000000..e68846aa Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-firstPage.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-firstPage.svg b/static/pdf.js/images/secondaryToolbarButton-firstPage.svg deleted file mode 100644 index f5c917f1..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-firstPage.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-firstPage@2x.png b/static/pdf.js/images/secondaryToolbarButton-firstPage@2x.png new file mode 100644 index 00000000..3ad8af51 Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-firstPage@2x.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-handTool.png b/static/pdf.js/images/secondaryToolbarButton-handTool.png new file mode 100644 index 00000000..cb85a841 Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-handTool.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-handTool.svg b/static/pdf.js/images/secondaryToolbarButton-handTool.svg deleted file mode 100644 index b7073b59..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-handTool.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-handTool@2x.png b/static/pdf.js/images/secondaryToolbarButton-handTool@2x.png new file mode 100644 index 00000000..5c13f77f Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-handTool@2x.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-lastPage.png b/static/pdf.js/images/secondaryToolbarButton-lastPage.png new file mode 100644 index 00000000..be763e0c Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-lastPage.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-lastPage.svg b/static/pdf.js/images/secondaryToolbarButton-lastPage.svg deleted file mode 100644 index c04f6507..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-lastPage.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-lastPage@2x.png b/static/pdf.js/images/secondaryToolbarButton-lastPage@2x.png new file mode 100644 index 00000000..8570984f Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-lastPage@2x.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-rotateCcw.png b/static/pdf.js/images/secondaryToolbarButton-rotateCcw.png new file mode 100644 index 00000000..675d6da2 Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-rotateCcw.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-rotateCcw.svg b/static/pdf.js/images/secondaryToolbarButton-rotateCcw.svg deleted file mode 100644 index da73a1b1..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-rotateCcw.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-rotateCcw@2x.png b/static/pdf.js/images/secondaryToolbarButton-rotateCcw@2x.png new file mode 100644 index 00000000..b9e74312 Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-rotateCcw@2x.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-rotateCw.png b/static/pdf.js/images/secondaryToolbarButton-rotateCw.png new file mode 100644 index 00000000..e1c75988 Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-rotateCw.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-rotateCw.svg b/static/pdf.js/images/secondaryToolbarButton-rotateCw.svg deleted file mode 100644 index c41ce736..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-rotateCw.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-rotateCw@2x.png b/static/pdf.js/images/secondaryToolbarButton-rotateCw@2x.png new file mode 100644 index 00000000..cb257b41 Binary files /dev/null and b/static/pdf.js/images/secondaryToolbarButton-rotateCw@2x.png differ diff --git a/static/pdf.js/images/secondaryToolbarButton-scrollHorizontal.svg b/static/pdf.js/images/secondaryToolbarButton-scrollHorizontal.svg deleted file mode 100644 index fb440b94..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-scrollHorizontal.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-scrollPage.svg b/static/pdf.js/images/secondaryToolbarButton-scrollPage.svg deleted file mode 100644 index 64a9f500..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-scrollPage.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-scrollVertical.svg b/static/pdf.js/images/secondaryToolbarButton-scrollVertical.svg deleted file mode 100644 index dc7e8052..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-scrollVertical.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-scrollWrapped.svg b/static/pdf.js/images/secondaryToolbarButton-scrollWrapped.svg deleted file mode 100644 index 75fe26bc..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-scrollWrapped.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-selectTool.svg b/static/pdf.js/images/secondaryToolbarButton-selectTool.svg deleted file mode 100644 index 94d51410..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-selectTool.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-spreadEven.svg b/static/pdf.js/images/secondaryToolbarButton-spreadEven.svg deleted file mode 100644 index ce201e33..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-spreadEven.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-spreadNone.svg b/static/pdf.js/images/secondaryToolbarButton-spreadNone.svg deleted file mode 100644 index e8d487fa..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-spreadNone.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/secondaryToolbarButton-spreadOdd.svg b/static/pdf.js/images/secondaryToolbarButton-spreadOdd.svg deleted file mode 100644 index 9211a427..00000000 --- a/static/pdf.js/images/secondaryToolbarButton-spreadOdd.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/shadow.png b/static/pdf.js/images/shadow.png new file mode 100644 index 00000000..31d3bdb1 Binary files /dev/null and b/static/pdf.js/images/shadow.png differ diff --git a/static/pdf.js/images/texture.png b/static/pdf.js/images/texture.png new file mode 100644 index 00000000..eb5ccb5e Binary files /dev/null and b/static/pdf.js/images/texture.png differ diff --git a/static/pdf.js/images/toolbarButton-bookmark.png b/static/pdf.js/images/toolbarButton-bookmark.png new file mode 100644 index 00000000..a187be6c Binary files /dev/null and b/static/pdf.js/images/toolbarButton-bookmark.png differ diff --git a/static/pdf.js/images/toolbarButton-bookmark.svg b/static/pdf.js/images/toolbarButton-bookmark.svg deleted file mode 100644 index c4c37c90..00000000 --- a/static/pdf.js/images/toolbarButton-bookmark.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-bookmark@2x.png b/static/pdf.js/images/toolbarButton-bookmark@2x.png new file mode 100644 index 00000000..4efbaa67 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-bookmark@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-currentOutlineItem.svg b/static/pdf.js/images/toolbarButton-currentOutlineItem.svg deleted file mode 100644 index 01e67623..00000000 --- a/static/pdf.js/images/toolbarButton-currentOutlineItem.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-download.png b/static/pdf.js/images/toolbarButton-download.png new file mode 100644 index 00000000..eaab35f0 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-download.png differ diff --git a/static/pdf.js/images/toolbarButton-download.svg b/static/pdf.js/images/toolbarButton-download.svg deleted file mode 100644 index e2e850ad..00000000 --- a/static/pdf.js/images/toolbarButton-download.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/static/pdf.js/images/toolbarButton-download@2x.png b/static/pdf.js/images/toolbarButton-download@2x.png new file mode 100644 index 00000000..896face4 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-download@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-editorFreeText.svg b/static/pdf.js/images/toolbarButton-editorFreeText.svg deleted file mode 100644 index 13a67bd9..00000000 --- a/static/pdf.js/images/toolbarButton-editorFreeText.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/static/pdf.js/images/toolbarButton-editorHighlight.svg b/static/pdf.js/images/toolbarButton-editorHighlight.svg deleted file mode 100644 index b3cd7fda..00000000 --- a/static/pdf.js/images/toolbarButton-editorHighlight.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/static/pdf.js/images/toolbarButton-editorInk.svg b/static/pdf.js/images/toolbarButton-editorInk.svg deleted file mode 100644 index b579eec7..00000000 --- a/static/pdf.js/images/toolbarButton-editorInk.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/static/pdf.js/images/toolbarButton-editorStamp.svg b/static/pdf.js/images/toolbarButton-editorStamp.svg deleted file mode 100644 index a1fef492..00000000 --- a/static/pdf.js/images/toolbarButton-editorStamp.svg +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - diff --git a/static/pdf.js/images/toolbarButton-fullscreen.png b/static/pdf.js/images/toolbarButton-fullscreen.png new file mode 100644 index 00000000..fa730955 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-fullscreen.png differ diff --git a/static/pdf.js/images/toolbarButton-menuArrow.svg b/static/pdf.js/images/toolbarButton-menuArrow.svg deleted file mode 100644 index 82ffeaab..00000000 --- a/static/pdf.js/images/toolbarButton-menuArrow.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-menuArrows.png b/static/pdf.js/images/toolbarButton-menuArrows.png new file mode 100644 index 00000000..306eb43b Binary files /dev/null and b/static/pdf.js/images/toolbarButton-menuArrows.png differ diff --git a/static/pdf.js/images/toolbarButton-menuArrows@2x.png b/static/pdf.js/images/toolbarButton-menuArrows@2x.png new file mode 100644 index 00000000..f7570bc0 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-menuArrows@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-openFile.png b/static/pdf.js/images/toolbarButton-openFile.png new file mode 100644 index 00000000..b5cf1bd0 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-openFile.png differ diff --git a/static/pdf.js/images/toolbarButton-openFile.svg b/static/pdf.js/images/toolbarButton-openFile.svg deleted file mode 100644 index e773781d..00000000 --- a/static/pdf.js/images/toolbarButton-openFile.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-openFile@2x.png b/static/pdf.js/images/toolbarButton-openFile@2x.png new file mode 100644 index 00000000..91ab7659 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-openFile@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-pageDown-rtl.png b/static/pdf.js/images/toolbarButton-pageDown-rtl.png new file mode 100644 index 00000000..1957f79a Binary files /dev/null and b/static/pdf.js/images/toolbarButton-pageDown-rtl.png differ diff --git a/static/pdf.js/images/toolbarButton-pageDown-rtl@2x.png b/static/pdf.js/images/toolbarButton-pageDown-rtl@2x.png new file mode 100644 index 00000000..16ebcb8e Binary files /dev/null and b/static/pdf.js/images/toolbarButton-pageDown-rtl@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-pageDown.png b/static/pdf.js/images/toolbarButton-pageDown.png new file mode 100644 index 00000000..8219ecf8 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-pageDown.png differ diff --git a/static/pdf.js/images/toolbarButton-pageDown.svg b/static/pdf.js/images/toolbarButton-pageDown.svg deleted file mode 100644 index 1fc12e73..00000000 --- a/static/pdf.js/images/toolbarButton-pageDown.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-pageDown@2x.png b/static/pdf.js/images/toolbarButton-pageDown@2x.png new file mode 100644 index 00000000..758c01d8 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-pageDown@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-pageUp-rtl.png b/static/pdf.js/images/toolbarButton-pageUp-rtl.png new file mode 100644 index 00000000..98e7ce48 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-pageUp-rtl.png differ diff --git a/static/pdf.js/images/toolbarButton-pageUp-rtl@2x.png b/static/pdf.js/images/toolbarButton-pageUp-rtl@2x.png new file mode 100644 index 00000000..a01b0238 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-pageUp-rtl@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-pageUp.png b/static/pdf.js/images/toolbarButton-pageUp.png new file mode 100644 index 00000000..fb9daa33 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-pageUp.png differ diff --git a/static/pdf.js/images/toolbarButton-pageUp.svg b/static/pdf.js/images/toolbarButton-pageUp.svg deleted file mode 100644 index 0936b9a5..00000000 --- a/static/pdf.js/images/toolbarButton-pageUp.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-pageUp@2x.png b/static/pdf.js/images/toolbarButton-pageUp@2x.png new file mode 100644 index 00000000..a5cfd755 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-pageUp@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-presentationMode.png b/static/pdf.js/images/toolbarButton-presentationMode.png new file mode 100644 index 00000000..3ac21244 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-presentationMode.png differ diff --git a/static/pdf.js/images/toolbarButton-presentationMode.svg b/static/pdf.js/images/toolbarButton-presentationMode.svg deleted file mode 100644 index 901d5672..00000000 --- a/static/pdf.js/images/toolbarButton-presentationMode.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-presentationMode@2x.png b/static/pdf.js/images/toolbarButton-presentationMode@2x.png new file mode 100644 index 00000000..cada9e79 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-presentationMode@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-print.png b/static/pdf.js/images/toolbarButton-print.png new file mode 100644 index 00000000..51275e54 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-print.png differ diff --git a/static/pdf.js/images/toolbarButton-print.svg b/static/pdf.js/images/toolbarButton-print.svg deleted file mode 100644 index 97a39047..00000000 --- a/static/pdf.js/images/toolbarButton-print.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-print@2x.png b/static/pdf.js/images/toolbarButton-print@2x.png new file mode 100644 index 00000000..53d18daf Binary files /dev/null and b/static/pdf.js/images/toolbarButton-print@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-search.png b/static/pdf.js/images/toolbarButton-search.png new file mode 100644 index 00000000..f9b75579 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-search.png differ diff --git a/static/pdf.js/images/toolbarButton-search.svg b/static/pdf.js/images/toolbarButton-search.svg deleted file mode 100644 index 0cc7ae21..00000000 --- a/static/pdf.js/images/toolbarButton-search.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-search@2x.png b/static/pdf.js/images/toolbarButton-search@2x.png new file mode 100644 index 00000000..456b1332 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-search@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-secondaryToolbarToggle-rtl.png b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle-rtl.png new file mode 100644 index 00000000..84370952 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle-rtl.png differ diff --git a/static/pdf.js/images/toolbarButton-secondaryToolbarToggle-rtl@2x.png b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle-rtl@2x.png new file mode 100644 index 00000000..9d9bfa4f Binary files /dev/null and b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle-rtl@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-secondaryToolbarToggle.png b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle.png new file mode 100644 index 00000000..1f90f83d Binary files /dev/null and b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle.png differ diff --git a/static/pdf.js/images/toolbarButton-secondaryToolbarToggle.svg b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle.svg deleted file mode 100644 index cace8637..00000000 --- a/static/pdf.js/images/toolbarButton-secondaryToolbarToggle.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-secondaryToolbarToggle@2x.png b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle@2x.png new file mode 100644 index 00000000..b066fe5c Binary files /dev/null and b/static/pdf.js/images/toolbarButton-secondaryToolbarToggle@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-sidebarToggle-rtl.png b/static/pdf.js/images/toolbarButton-sidebarToggle-rtl.png new file mode 100644 index 00000000..6f85ec06 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-sidebarToggle-rtl.png differ diff --git a/static/pdf.js/images/toolbarButton-sidebarToggle-rtl@2x.png b/static/pdf.js/images/toolbarButton-sidebarToggle-rtl@2x.png new file mode 100644 index 00000000..291e0067 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-sidebarToggle-rtl@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-sidebarToggle.png b/static/pdf.js/images/toolbarButton-sidebarToggle.png new file mode 100644 index 00000000..025dc904 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-sidebarToggle.png differ diff --git a/static/pdf.js/images/toolbarButton-sidebarToggle.svg b/static/pdf.js/images/toolbarButton-sidebarToggle.svg deleted file mode 100644 index 1d8d0e4b..00000000 --- a/static/pdf.js/images/toolbarButton-sidebarToggle.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-sidebarToggle@2x.png b/static/pdf.js/images/toolbarButton-sidebarToggle@2x.png new file mode 100644 index 00000000..7f834df9 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-sidebarToggle@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-viewAttachments.png b/static/pdf.js/images/toolbarButton-viewAttachments.png new file mode 100644 index 00000000..fcd0b268 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-viewAttachments.png differ diff --git a/static/pdf.js/images/toolbarButton-viewAttachments.svg b/static/pdf.js/images/toolbarButton-viewAttachments.svg deleted file mode 100644 index ab73f6e6..00000000 --- a/static/pdf.js/images/toolbarButton-viewAttachments.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-viewAttachments@2x.png b/static/pdf.js/images/toolbarButton-viewAttachments@2x.png new file mode 100644 index 00000000..b979e523 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-viewAttachments@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-viewLayers.svg b/static/pdf.js/images/toolbarButton-viewLayers.svg deleted file mode 100644 index 1d726682..00000000 --- a/static/pdf.js/images/toolbarButton-viewLayers.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-viewOutline-rtl.png b/static/pdf.js/images/toolbarButton-viewOutline-rtl.png new file mode 100644 index 00000000..aaa94302 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-viewOutline-rtl.png differ diff --git a/static/pdf.js/images/toolbarButton-viewOutline-rtl@2x.png b/static/pdf.js/images/toolbarButton-viewOutline-rtl@2x.png new file mode 100644 index 00000000..3410f70d Binary files /dev/null and b/static/pdf.js/images/toolbarButton-viewOutline-rtl@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-viewOutline.png b/static/pdf.js/images/toolbarButton-viewOutline.png new file mode 100644 index 00000000..976365a5 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-viewOutline.png differ diff --git a/static/pdf.js/images/toolbarButton-viewOutline.svg b/static/pdf.js/images/toolbarButton-viewOutline.svg deleted file mode 100644 index 7ed1bd97..00000000 --- a/static/pdf.js/images/toolbarButton-viewOutline.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-viewOutline@2x.png b/static/pdf.js/images/toolbarButton-viewOutline@2x.png new file mode 100644 index 00000000..b6a197fd Binary files /dev/null and b/static/pdf.js/images/toolbarButton-viewOutline@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-viewThumbnail.png b/static/pdf.js/images/toolbarButton-viewThumbnail.png new file mode 100644 index 00000000..584ba558 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-viewThumbnail.png differ diff --git a/static/pdf.js/images/toolbarButton-viewThumbnail.svg b/static/pdf.js/images/toolbarButton-viewThumbnail.svg deleted file mode 100644 index 040d1232..00000000 --- a/static/pdf.js/images/toolbarButton-viewThumbnail.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-viewThumbnail@2x.png b/static/pdf.js/images/toolbarButton-viewThumbnail@2x.png new file mode 100644 index 00000000..fb7db938 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-viewThumbnail@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-zoomIn.png b/static/pdf.js/images/toolbarButton-zoomIn.png new file mode 100644 index 00000000..513d081b Binary files /dev/null and b/static/pdf.js/images/toolbarButton-zoomIn.png differ diff --git a/static/pdf.js/images/toolbarButton-zoomIn.svg b/static/pdf.js/images/toolbarButton-zoomIn.svg deleted file mode 100644 index 30ec51a2..00000000 --- a/static/pdf.js/images/toolbarButton-zoomIn.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-zoomIn@2x.png b/static/pdf.js/images/toolbarButton-zoomIn@2x.png new file mode 100644 index 00000000..d5d49d5f Binary files /dev/null and b/static/pdf.js/images/toolbarButton-zoomIn@2x.png differ diff --git a/static/pdf.js/images/toolbarButton-zoomOut.png b/static/pdf.js/images/toolbarButton-zoomOut.png new file mode 100644 index 00000000..156c26b9 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-zoomOut.png differ diff --git a/static/pdf.js/images/toolbarButton-zoomOut.svg b/static/pdf.js/images/toolbarButton-zoomOut.svg deleted file mode 100644 index f273b599..00000000 --- a/static/pdf.js/images/toolbarButton-zoomOut.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/static/pdf.js/images/toolbarButton-zoomOut@2x.png b/static/pdf.js/images/toolbarButton-zoomOut@2x.png new file mode 100644 index 00000000..959e1919 Binary files /dev/null and b/static/pdf.js/images/toolbarButton-zoomOut@2x.png differ diff --git a/static/pdf.js/images/treeitem-collapsed-rtl.png b/static/pdf.js/images/treeitem-collapsed-rtl.png new file mode 100644 index 00000000..1c8b9f70 Binary files /dev/null and b/static/pdf.js/images/treeitem-collapsed-rtl.png differ diff --git a/static/pdf.js/images/treeitem-collapsed-rtl@2x.png b/static/pdf.js/images/treeitem-collapsed-rtl@2x.png new file mode 100644 index 00000000..84279368 Binary files /dev/null and b/static/pdf.js/images/treeitem-collapsed-rtl@2x.png differ diff --git a/static/pdf.js/images/treeitem-collapsed.png b/static/pdf.js/images/treeitem-collapsed.png new file mode 100644 index 00000000..06d4d376 Binary files /dev/null and b/static/pdf.js/images/treeitem-collapsed.png differ diff --git a/static/pdf.js/images/treeitem-collapsed.svg b/static/pdf.js/images/treeitem-collapsed.svg deleted file mode 100644 index 831cddfc..00000000 --- a/static/pdf.js/images/treeitem-collapsed.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/static/pdf.js/images/treeitem-collapsed@2x.png b/static/pdf.js/images/treeitem-collapsed@2x.png new file mode 100644 index 00000000..eec1e58c Binary files /dev/null and b/static/pdf.js/images/treeitem-collapsed@2x.png differ diff --git a/static/pdf.js/images/treeitem-expanded.png b/static/pdf.js/images/treeitem-expanded.png new file mode 100644 index 00000000..c8d55735 Binary files /dev/null and b/static/pdf.js/images/treeitem-expanded.png differ diff --git a/static/pdf.js/images/treeitem-expanded.svg b/static/pdf.js/images/treeitem-expanded.svg deleted file mode 100644 index 2d45f0c8..00000000 --- a/static/pdf.js/images/treeitem-expanded.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/static/pdf.js/images/treeitem-expanded@2x.png b/static/pdf.js/images/treeitem-expanded@2x.png new file mode 100644 index 00000000..3b3b6103 Binary files /dev/null and b/static/pdf.js/images/treeitem-expanded@2x.png differ diff --git a/static/pdf.js/index.html b/static/pdf.js/index.html index aef63700..5b103831 100644 --- a/static/pdf.js/index.html +++ b/static/pdf.js/index.html @@ -20,55 +20,50 @@ Adobe CMap resources are covered by their own copyright but the same license: See https://github.com/adobe-type-tools/cmap-resources --> - + - PDF.js viewer + + + + + + + + + + - - - - + + + - - - + + + + + - +
-
-
- - - - -
-
- -
-
-
- - -
+
+ + +
@@ -78,195 +73,80 @@ See https://github.com/adobe-type-tools/cmap-resources
-
-
- - - - - - - - - + + + + + + +
@@ -275,86 +155,81 @@ See https://github.com/adobe-type-tools/cmap-resources
-
- -
-
-
- - - + +
-
- - - - -
- -
- - - -
+ - + + Current View + + +
+ +
-
-
- -
- +
+
+
+ +
+ +
+ + +
- - -
@@ -366,147 +241,187 @@ See https://github.com/adobe-type-tools/cmap-resources
+ + + + + + +
+ +
-
- -
- -
-
- -
-
- - -
-
- -
- File name: -

-

-
-
- File size: -

-

-
-
-
- Title: -

-

-
-
- Author: -

-

-
-
- Subject: -

-

-
-
- Keywords: -

-

-
-
- Creation Date: -

-

-
-
- Modification Date: -

-

-
-
- Creator: -

-

-
-
-
- PDF Producer: -

-

-
-
- PDF Version: -

-

-
-
- Page Count: -

-

-
-
- Page Size: -

-

-
-
-
- Fast Web View: -

-

-
-
- -
-
- -
-
- Choose an option - - Alt text (alternative text) helps when people can’t see the image or when it doesn’t load. - +
- -
- Preparing document for printing… +
+
-
+
+
- + + + + diff --git a/static/pdf.js/l10n.js b/static/pdf.js/l10n.js new file mode 100644 index 00000000..3d5ecffa --- /dev/null +++ b/static/pdf.js/l10n.js @@ -0,0 +1,1033 @@ +/** + * Copyright (c) 2011-2013 Fabien Cazenave, Mozilla. + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to + * deal in the Software without restriction, including without limitation the + * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or + * sell copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS + * IN THE SOFTWARE. + */ +/* + Additional modifications for PDF.js project: + - Disables language initialization on page loading; + - Removes consoleWarn and consoleLog and use console.log/warn directly. + - Removes window._ assignment. + - Remove compatibility code for OldIE. +*/ + +/*jshint browser: true, devel: true, es5: true, globalstrict: true */ +'use strict'; + +document.webL10n = (function(window, document, undefined) { + var gL10nData = {}; + var gTextData = ''; + var gTextProp = 'textContent'; + var gLanguage = ''; + var gMacros = {}; + var gReadyState = 'loading'; + + + /** + * Synchronously loading l10n resources significantly minimizes flickering + * from displaying the app with non-localized strings and then updating the + * strings. Although this will block all script execution on this page, we + * expect that the l10n resources are available locally on flash-storage. + * + * As synchronous XHR is generally considered as a bad idea, we're still + * loading l10n resources asynchronously -- but we keep this in a setting, + * just in case... and applications using this library should hide their + * content until the `localized' event happens. + */ + + var gAsyncResourceLoading = true; // read-only + + + /** + * DOM helpers for the so-called "HTML API". + * + * These functions are written for modern browsers. For old versions of IE, + * they're overridden in the 'startup' section at the end of this file. + */ + + function getL10nResourceLinks() { + return document.querySelectorAll('link[type="application/l10n"]'); + } + + function getL10nDictionary() { + var script = document.querySelector('script[type="application/l10n"]'); + // TODO: support multiple and external JSON dictionaries + return script ? JSON.parse(script.innerHTML) : null; + } + + function getTranslatableChildren(element) { + return element ? element.querySelectorAll('*[data-l10n-id]') : []; + } + + function getL10nAttributes(element) { + if (!element) + return {}; + + var l10nId = element.getAttribute('data-l10n-id'); + var l10nArgs = element.getAttribute('data-l10n-args'); + var args = {}; + if (l10nArgs) { + try { + args = JSON.parse(l10nArgs); + } catch (e) { + console.warn('could not parse arguments for #' + l10nId); + } + } + return { id: l10nId, args: args }; + } + + function fireL10nReadyEvent(lang) { + var evtObject = document.createEvent('Event'); + evtObject.initEvent('localized', true, false); + evtObject.language = lang; + document.dispatchEvent(evtObject); + } + + function xhrLoadText(url, onSuccess, onFailure) { + onSuccess = onSuccess || function _onSuccess(data) {}; + onFailure = onFailure || function _onFailure() { + console.warn(url + ' not found.'); + }; + + var xhr = new XMLHttpRequest(); + xhr.open('GET', url, gAsyncResourceLoading); + if (xhr.overrideMimeType) { + xhr.overrideMimeType('text/plain; charset=utf-8'); + } + xhr.onreadystatechange = function() { + if (xhr.readyState == 4) { + if (xhr.status == 200 || xhr.status === 0) { + onSuccess(xhr.responseText); + } else { + onFailure(); + } + } + }; + xhr.onerror = onFailure; + xhr.ontimeout = onFailure; + + // in Firefox OS with the app:// protocol, trying to XHR a non-existing + // URL will raise an exception here -- hence this ugly try...catch. + try { + xhr.send(null); + } catch (e) { + onFailure(); + } + } + + + /** + * l10n resource parser: + * - reads (async XHR) the l10n resource matching `lang'; + * - imports linked resources (synchronously) when specified; + * - parses the text data (fills `gL10nData' and `gTextData'); + * - triggers success/failure callbacks when done. + * + * @param {string} href + * URL of the l10n resource to parse. + * + * @param {string} lang + * locale (language) to parse. Must be a lowercase string. + * + * @param {Function} successCallback + * triggered when the l10n resource has been successully parsed. + * + * @param {Function} failureCallback + * triggered when the an error has occured. + * + * @return {void} + * uses the following global variables: gL10nData, gTextData, gTextProp. + */ + + function parseResource(href, lang, successCallback, failureCallback) { + var baseURL = href.replace(/[^\/]*$/, '') || './'; + + // handle escaped characters (backslashes) in a string + function evalString(text) { + if (text.lastIndexOf('\\') < 0) + return text; + return text.replace(/\\\\/g, '\\') + .replace(/\\n/g, '\n') + .replace(/\\r/g, '\r') + .replace(/\\t/g, '\t') + .replace(/\\b/g, '\b') + .replace(/\\f/g, '\f') + .replace(/\\{/g, '{') + .replace(/\\}/g, '}') + .replace(/\\"/g, '"') + .replace(/\\'/g, "'"); + } + + // parse *.properties text data into an l10n dictionary + // If gAsyncResourceLoading is false, then the callback will be called + // synchronously. Otherwise it is called asynchronously. + function parseProperties(text, parsedPropertiesCallback) { + var dictionary = {}; + + // token expressions + var reBlank = /^\s*|\s*$/; + var reComment = /^\s*#|^\s*$/; + var reSection = /^\s*\[(.*)\]\s*$/; + var reImport = /^\s*@import\s+url\((.*)\)\s*$/i; + var reSplit = /^([^=\s]*)\s*=\s*(.+)$/; // TODO: escape EOLs with '\' + + // parse the *.properties file into an associative array + function parseRawLines(rawText, extendedSyntax, parsedRawLinesCallback) { + var entries = rawText.replace(reBlank, '').split(/[\r\n]+/); + var currentLang = '*'; + var genericLang = lang.split('-', 1)[0]; + var skipLang = false; + var match = ''; + + function nextEntry() { + // Use infinite loop instead of recursion to avoid reaching the + // maximum recursion limit for content with many lines. + while (true) { + if (!entries.length) { + parsedRawLinesCallback(); + return; + } + var line = entries.shift(); + + // comment or blank line? + if (reComment.test(line)) + continue; + + // the extended syntax supports [lang] sections and @import rules + if (extendedSyntax) { + match = reSection.exec(line); + if (match) { // section start? + // RFC 4646, section 4.4, "All comparisons MUST be performed + // in a case-insensitive manner." + + currentLang = match[1].toLowerCase(); + skipLang = (currentLang !== '*') && + (currentLang !== lang) && (currentLang !== genericLang); + continue; + } else if (skipLang) { + continue; + } + match = reImport.exec(line); + if (match) { // @import rule? + loadImport(baseURL + match[1], nextEntry); + return; + } + } + + // key-value pair + var tmp = line.match(reSplit); + if (tmp && tmp.length == 3) { + dictionary[tmp[1]] = evalString(tmp[2]); + } + } + } + nextEntry(); + } + + // import another *.properties file + function loadImport(url, callback) { + xhrLoadText(url, function(content) { + parseRawLines(content, false, callback); // don't allow recursive imports + }, null); + } + + // fill the dictionary + parseRawLines(text, true, function() { + parsedPropertiesCallback(dictionary); + }); + } + + // load and parse l10n data (warning: global variables are used here) + xhrLoadText(href, function(response) { + gTextData += response; // mostly for debug + + // parse *.properties text data into an l10n dictionary + parseProperties(response, function(data) { + + // find attribute descriptions, if any + for (var key in data) { + var id, prop, index = key.lastIndexOf('.'); + if (index > 0) { // an attribute has been specified + id = key.substring(0, index); + prop = key.substr(index + 1); + } else { // no attribute: assuming text content by default + id = key; + prop = gTextProp; + } + if (!gL10nData[id]) { + gL10nData[id] = {}; + } + gL10nData[id][prop] = data[key]; + } + + // trigger callback + if (successCallback) { + successCallback(); + } + }); + }, failureCallback); + } + + // load and parse all resources for the specified locale + function loadLocale(lang, callback) { + // RFC 4646, section 2.1 states that language tags have to be treated as + // case-insensitive. Convert to lowercase for case-insensitive comparisons. + if (lang) { + lang = lang.toLowerCase(); + } + + callback = callback || function _callback() {}; + + clear(); + gLanguage = lang; + + // check all nodes + // and load the resource files + var langLinks = getL10nResourceLinks(); + var langCount = langLinks.length; + if (langCount === 0) { + // we might have a pre-compiled dictionary instead + var dict = getL10nDictionary(); + if (dict && dict.locales && dict.default_locale) { + console.log('using the embedded JSON directory, early way out'); + gL10nData = dict.locales[lang]; + if (!gL10nData) { + var defaultLocale = dict.default_locale.toLowerCase(); + for (var anyCaseLang in dict.locales) { + anyCaseLang = anyCaseLang.toLowerCase(); + if (anyCaseLang === lang) { + gL10nData = dict.locales[lang]; + break; + } else if (anyCaseLang === defaultLocale) { + gL10nData = dict.locales[defaultLocale]; + } + } + } + callback(); + } else { + console.log('no resource to load, early way out'); + } + // early way out + fireL10nReadyEvent(lang); + gReadyState = 'complete'; + return; + } + + // start the callback when all resources are loaded + var onResourceLoaded = null; + var gResourceCount = 0; + onResourceLoaded = function() { + gResourceCount++; + if (gResourceCount >= langCount) { + callback(); + fireL10nReadyEvent(lang); + gReadyState = 'complete'; + } + }; + + // load all resource files + function L10nResourceLink(link) { + var href = link.href; + // Note: If |gAsyncResourceLoading| is false, then the following callbacks + // are synchronously called. + this.load = function(lang, callback) { + parseResource(href, lang, callback, function() { + console.warn(href + ' not found.'); + // lang not found, used default resource instead + console.warn('"' + lang + '" resource not found'); + gLanguage = ''; + // Resource not loaded, but we still need to call the callback. + callback(); + }); + }; + } + + for (var i = 0; i < langCount; i++) { + var resource = new L10nResourceLink(langLinks[i]); + resource.load(lang, onResourceLoaded); + } + } + + // clear all l10n data + function clear() { + gL10nData = {}; + gTextData = ''; + gLanguage = ''; + // TODO: clear all non predefined macros. + // There's no such macro /yet/ but we're planning to have some... + } + + + /** + * Get rules for plural forms (shared with JetPack), see: + * http://unicode.org/repos/cldr-tmp/trunk/diff/supplemental/language_plural_rules.html + * https://github.com/mozilla/addon-sdk/blob/master/python-lib/plural-rules-generator.p + * + * @param {string} lang + * locale (language) used. + * + * @return {Function} + * returns a function that gives the plural form name for a given integer: + * var fun = getPluralRules('en'); + * fun(1) -> 'one' + * fun(0) -> 'other' + * fun(1000) -> 'other'. + */ + + function getPluralRules(lang) { + var locales2rules = { + 'af': 3, + 'ak': 4, + 'am': 4, + 'ar': 1, + 'asa': 3, + 'az': 0, + 'be': 11, + 'bem': 3, + 'bez': 3, + 'bg': 3, + 'bh': 4, + 'bm': 0, + 'bn': 3, + 'bo': 0, + 'br': 20, + 'brx': 3, + 'bs': 11, + 'ca': 3, + 'cgg': 3, + 'chr': 3, + 'cs': 12, + 'cy': 17, + 'da': 3, + 'de': 3, + 'dv': 3, + 'dz': 0, + 'ee': 3, + 'el': 3, + 'en': 3, + 'eo': 3, + 'es': 3, + 'et': 3, + 'eu': 3, + 'fa': 0, + 'ff': 5, + 'fi': 3, + 'fil': 4, + 'fo': 3, + 'fr': 5, + 'fur': 3, + 'fy': 3, + 'ga': 8, + 'gd': 24, + 'gl': 3, + 'gsw': 3, + 'gu': 3, + 'guw': 4, + 'gv': 23, + 'ha': 3, + 'haw': 3, + 'he': 2, + 'hi': 4, + 'hr': 11, + 'hu': 0, + 'id': 0, + 'ig': 0, + 'ii': 0, + 'is': 3, + 'it': 3, + 'iu': 7, + 'ja': 0, + 'jmc': 3, + 'jv': 0, + 'ka': 0, + 'kab': 5, + 'kaj': 3, + 'kcg': 3, + 'kde': 0, + 'kea': 0, + 'kk': 3, + 'kl': 3, + 'km': 0, + 'kn': 0, + 'ko': 0, + 'ksb': 3, + 'ksh': 21, + 'ku': 3, + 'kw': 7, + 'lag': 18, + 'lb': 3, + 'lg': 3, + 'ln': 4, + 'lo': 0, + 'lt': 10, + 'lv': 6, + 'mas': 3, + 'mg': 4, + 'mk': 16, + 'ml': 3, + 'mn': 3, + 'mo': 9, + 'mr': 3, + 'ms': 0, + 'mt': 15, + 'my': 0, + 'nah': 3, + 'naq': 7, + 'nb': 3, + 'nd': 3, + 'ne': 3, + 'nl': 3, + 'nn': 3, + 'no': 3, + 'nr': 3, + 'nso': 4, + 'ny': 3, + 'nyn': 3, + 'om': 3, + 'or': 3, + 'pa': 3, + 'pap': 3, + 'pl': 13, + 'ps': 3, + 'pt': 3, + 'rm': 3, + 'ro': 9, + 'rof': 3, + 'ru': 11, + 'rwk': 3, + 'sah': 0, + 'saq': 3, + 'se': 7, + 'seh': 3, + 'ses': 0, + 'sg': 0, + 'sh': 11, + 'shi': 19, + 'sk': 12, + 'sl': 14, + 'sma': 7, + 'smi': 7, + 'smj': 7, + 'smn': 7, + 'sms': 7, + 'sn': 3, + 'so': 3, + 'sq': 3, + 'sr': 11, + 'ss': 3, + 'ssy': 3, + 'st': 3, + 'sv': 3, + 'sw': 3, + 'syr': 3, + 'ta': 3, + 'te': 3, + 'teo': 3, + 'th': 0, + 'ti': 4, + 'tig': 3, + 'tk': 3, + 'tl': 4, + 'tn': 3, + 'to': 0, + 'tr': 0, + 'ts': 3, + 'tzm': 22, + 'uk': 11, + 'ur': 3, + 've': 3, + 'vi': 0, + 'vun': 3, + 'wa': 4, + 'wae': 3, + 'wo': 0, + 'xh': 3, + 'xog': 3, + 'yo': 0, + 'zh': 0, + 'zu': 3 + }; + + // utility functions for plural rules methods + function isIn(n, list) { + return list.indexOf(n) !== -1; + } + function isBetween(n, start, end) { + return start <= n && n <= end; + } + + // list of all plural rules methods: + // map an integer to the plural form name to use + var pluralRules = { + '0': function(n) { + return 'other'; + }, + '1': function(n) { + if ((isBetween((n % 100), 3, 10))) + return 'few'; + if (n === 0) + return 'zero'; + if ((isBetween((n % 100), 11, 99))) + return 'many'; + if (n == 2) + return 'two'; + if (n == 1) + return 'one'; + return 'other'; + }, + '2': function(n) { + if (n !== 0 && (n % 10) === 0) + return 'many'; + if (n == 2) + return 'two'; + if (n == 1) + return 'one'; + return 'other'; + }, + '3': function(n) { + if (n == 1) + return 'one'; + return 'other'; + }, + '4': function(n) { + if ((isBetween(n, 0, 1))) + return 'one'; + return 'other'; + }, + '5': function(n) { + if ((isBetween(n, 0, 2)) && n != 2) + return 'one'; + return 'other'; + }, + '6': function(n) { + if (n === 0) + return 'zero'; + if ((n % 10) == 1 && (n % 100) != 11) + return 'one'; + return 'other'; + }, + '7': function(n) { + if (n == 2) + return 'two'; + if (n == 1) + return 'one'; + return 'other'; + }, + '8': function(n) { + if ((isBetween(n, 3, 6))) + return 'few'; + if ((isBetween(n, 7, 10))) + return 'many'; + if (n == 2) + return 'two'; + if (n == 1) + return 'one'; + return 'other'; + }, + '9': function(n) { + if (n === 0 || n != 1 && (isBetween((n % 100), 1, 19))) + return 'few'; + if (n == 1) + return 'one'; + return 'other'; + }, + '10': function(n) { + if ((isBetween((n % 10), 2, 9)) && !(isBetween((n % 100), 11, 19))) + return 'few'; + if ((n % 10) == 1 && !(isBetween((n % 100), 11, 19))) + return 'one'; + return 'other'; + }, + '11': function(n) { + if ((isBetween((n % 10), 2, 4)) && !(isBetween((n % 100), 12, 14))) + return 'few'; + if ((n % 10) === 0 || + (isBetween((n % 10), 5, 9)) || + (isBetween((n % 100), 11, 14))) + return 'many'; + if ((n % 10) == 1 && (n % 100) != 11) + return 'one'; + return 'other'; + }, + '12': function(n) { + if ((isBetween(n, 2, 4))) + return 'few'; + if (n == 1) + return 'one'; + return 'other'; + }, + '13': function(n) { + if ((isBetween((n % 10), 2, 4)) && !(isBetween((n % 100), 12, 14))) + return 'few'; + if (n != 1 && (isBetween((n % 10), 0, 1)) || + (isBetween((n % 10), 5, 9)) || + (isBetween((n % 100), 12, 14))) + return 'many'; + if (n == 1) + return 'one'; + return 'other'; + }, + '14': function(n) { + if ((isBetween((n % 100), 3, 4))) + return 'few'; + if ((n % 100) == 2) + return 'two'; + if ((n % 100) == 1) + return 'one'; + return 'other'; + }, + '15': function(n) { + if (n === 0 || (isBetween((n % 100), 2, 10))) + return 'few'; + if ((isBetween((n % 100), 11, 19))) + return 'many'; + if (n == 1) + return 'one'; + return 'other'; + }, + '16': function(n) { + if ((n % 10) == 1 && n != 11) + return 'one'; + return 'other'; + }, + '17': function(n) { + if (n == 3) + return 'few'; + if (n === 0) + return 'zero'; + if (n == 6) + return 'many'; + if (n == 2) + return 'two'; + if (n == 1) + return 'one'; + return 'other'; + }, + '18': function(n) { + if (n === 0) + return 'zero'; + if ((isBetween(n, 0, 2)) && n !== 0 && n != 2) + return 'one'; + return 'other'; + }, + '19': function(n) { + if ((isBetween(n, 2, 10))) + return 'few'; + if ((isBetween(n, 0, 1))) + return 'one'; + return 'other'; + }, + '20': function(n) { + if ((isBetween((n % 10), 3, 4) || ((n % 10) == 9)) && !( + isBetween((n % 100), 10, 19) || + isBetween((n % 100), 70, 79) || + isBetween((n % 100), 90, 99) + )) + return 'few'; + if ((n % 1000000) === 0 && n !== 0) + return 'many'; + if ((n % 10) == 2 && !isIn((n % 100), [12, 72, 92])) + return 'two'; + if ((n % 10) == 1 && !isIn((n % 100), [11, 71, 91])) + return 'one'; + return 'other'; + }, + '21': function(n) { + if (n === 0) + return 'zero'; + if (n == 1) + return 'one'; + return 'other'; + }, + '22': function(n) { + if ((isBetween(n, 0, 1)) || (isBetween(n, 11, 99))) + return 'one'; + return 'other'; + }, + '23': function(n) { + if ((isBetween((n % 10), 1, 2)) || (n % 20) === 0) + return 'one'; + return 'other'; + }, + '24': function(n) { + if ((isBetween(n, 3, 10) || isBetween(n, 13, 19))) + return 'few'; + if (isIn(n, [2, 12])) + return 'two'; + if (isIn(n, [1, 11])) + return 'one'; + return 'other'; + } + }; + + // return a function that gives the plural form name for a given integer + var index = locales2rules[lang.replace(/-.*$/, '')]; + if (!(index in pluralRules)) { + console.warn('plural form unknown for [' + lang + ']'); + return function() { return 'other'; }; + } + return pluralRules[index]; + } + + // pre-defined 'plural' macro + gMacros.plural = function(str, param, key, prop) { + var n = parseFloat(param); + if (isNaN(n)) + return str; + + // TODO: support other properties (l20n still doesn't...) + if (prop != gTextProp) + return str; + + // initialize _pluralRules + if (!gMacros._pluralRules) { + gMacros._pluralRules = getPluralRules(gLanguage); + } + var index = '[' + gMacros._pluralRules(n) + ']'; + + // try to find a [zero|one|two] key if it's defined + if (n === 0 && (key + '[zero]') in gL10nData) { + str = gL10nData[key + '[zero]'][prop]; + } else if (n == 1 && (key + '[one]') in gL10nData) { + str = gL10nData[key + '[one]'][prop]; + } else if (n == 2 && (key + '[two]') in gL10nData) { + str = gL10nData[key + '[two]'][prop]; + } else if ((key + index) in gL10nData) { + str = gL10nData[key + index][prop]; + } else if ((key + '[other]') in gL10nData) { + str = gL10nData[key + '[other]'][prop]; + } + + return str; + }; + + + /** + * l10n dictionary functions + */ + + // fetch an l10n object, warn if not found, apply `args' if possible + function getL10nData(key, args, fallback) { + var data = gL10nData[key]; + if (!data) { + console.warn('#' + key + ' is undefined.'); + if (!fallback) { + return null; + } + data = fallback; + } + + /** This is where l10n expressions should be processed. + * The plan is to support C-style expressions from the l20n project; + * until then, only two kinds of simple expressions are supported: + * {[ index ]} and {{ arguments }}. + */ + var rv = {}; + for (var prop in data) { + var str = data[prop]; + str = substIndexes(str, args, key, prop); + str = substArguments(str, args, key); + rv[prop] = str; + } + return rv; + } + + // replace {[macros]} with their values + function substIndexes(str, args, key, prop) { + var reIndex = /\{\[\s*([a-zA-Z]+)\(([a-zA-Z]+)\)\s*\]\}/; + var reMatch = reIndex.exec(str); + if (!reMatch || !reMatch.length) + return str; + + // an index/macro has been found + // Note: at the moment, only one parameter is supported + var macroName = reMatch[1]; + var paramName = reMatch[2]; + var param; + if (args && paramName in args) { + param = args[paramName]; + } else if (paramName in gL10nData) { + param = gL10nData[paramName]; + } + + // there's no macro parser yet: it has to be defined in gMacros + if (macroName in gMacros) { + var macro = gMacros[macroName]; + str = macro(str, param, key, prop); + } + return str; + } + + // replace {{arguments}} with their values + function substArguments(str, args, key) { + var reArgs = /\{\{\s*(.+?)\s*\}\}/g; + return str.replace(reArgs, function(matched_text, arg) { + if (args && arg in args) { + return args[arg]; + } + if (arg in gL10nData) { + return gL10nData[arg]; + } + console.log('argument {{' + arg + '}} for #' + key + ' is undefined.'); + return matched_text; + }); + } + + // translate an HTML element + function translateElement(element) { + var l10n = getL10nAttributes(element); + if (!l10n.id) + return; + + // get the related l10n object + var data = getL10nData(l10n.id, l10n.args); + if (!data) { + console.warn('#' + l10n.id + ' is undefined.'); + return; + } + + // translate element (TODO: security checks?) + if (data[gTextProp]) { // XXX + if (getChildElementCount(element) === 0) { + element[gTextProp] = data[gTextProp]; + } else { + // this element has element children: replace the content of the first + // (non-empty) child textNode and clear other child textNodes + var children = element.childNodes; + var found = false; + for (var i = 0, l = children.length; i < l; i++) { + if (children[i].nodeType === 3 && /\S/.test(children[i].nodeValue)) { + if (found) { + children[i].nodeValue = ''; + } else { + children[i].nodeValue = data[gTextProp]; + found = true; + } + } + } + // if no (non-empty) textNode is found, insert a textNode before the + // first element child. + if (!found) { + var textNode = document.createTextNode(data[gTextProp]); + element.insertBefore(textNode, element.firstChild); + } + } + delete data[gTextProp]; + } + + for (var k in data) { + element[k] = data[k]; + } + } + + // webkit browsers don't currently support 'children' on SVG elements... + function getChildElementCount(element) { + if (element.children) { + return element.children.length; + } + if (typeof element.childElementCount !== 'undefined') { + return element.childElementCount; + } + var count = 0; + for (var i = 0; i < element.childNodes.length; i++) { + count += element.nodeType === 1 ? 1 : 0; + } + return count; + } + + // translate an HTML subtree + function translateFragment(element) { + element = element || document.documentElement; + + // check all translatable children (= w/ a `data-l10n-id' attribute) + var children = getTranslatableChildren(element); + var elementCount = children.length; + for (var i = 0; i < elementCount; i++) { + translateElement(children[i]); + } + + // translate element itself if necessary + translateElement(element); + } + + return { + // get a localized string + get: function(key, args, fallbackString) { + var index = key.lastIndexOf('.'); + var prop = gTextProp; + if (index > 0) { // An attribute has been specified + prop = key.substr(index + 1); + key = key.substring(0, index); + } + var fallback; + if (fallbackString) { + fallback = {}; + fallback[prop] = fallbackString; + } + var data = getL10nData(key, args, fallback); + if (data && prop in data) { + return data[prop]; + } + return '{{' + key + '}}'; + }, + + // debug + getData: function() { return gL10nData; }, + getText: function() { return gTextData; }, + + // get|set the document language + getLanguage: function() { return gLanguage; }, + setLanguage: function(lang, callback) { + loadLocale(lang, function() { + if (callback) + callback(); + translateFragment(); + }); + }, + + // get the direction (ltr|rtl) of the current language + getDirection: function() { + // http://www.w3.org/International/questions/qa-scripts + // Arabic, Hebrew, Farsi, Pashto, Urdu + var rtlList = ['ar', 'he', 'fa', 'ps', 'ur']; + var shortCode = gLanguage.split('-', 1)[0]; + return (rtlList.indexOf(shortCode) >= 0) ? 'rtl' : 'ltr'; + }, + + // translate an element or document fragment + translate: translateFragment, + + // this can be used to prevent race conditions + getReadyState: function() { return gReadyState; }, + ready: function(callback) { + if (!callback) { + return; + } else if (gReadyState == 'complete' || gReadyState == 'interactive') { + window.setTimeout(function() { + callback(); + }); + } else if (document.addEventListener) { + document.addEventListener('localized', function once() { + document.removeEventListener('localized', once); + callback(); + }); + } + } + }; +}) (window, document); diff --git a/static/pdf.js/locale/ach/viewer.ftl b/static/pdf.js/locale/ach/viewer.ftl deleted file mode 100644 index 36769b70..00000000 --- a/static/pdf.js/locale/ach/viewer.ftl +++ /dev/null @@ -1,225 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pot buk mukato -pdfjs-previous-button-label = Mukato -pdfjs-next-button = - .title = Pot buk malubo -pdfjs-next-button-label = Malubo -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pot buk -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = pi { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } me { $pagesCount }) -pdfjs-zoom-out-button = - .title = Jwik Matidi -pdfjs-zoom-out-button-label = Jwik Matidi -pdfjs-zoom-in-button = - .title = Kwot Madit -pdfjs-zoom-in-button-label = Kwot Madit -pdfjs-zoom-select = - .title = Kwoti -pdfjs-presentation-mode-button = - .title = Lokke i kit me tyer -pdfjs-presentation-mode-button-label = Kit me tyer -pdfjs-open-file-button = - .title = Yab Pwail -pdfjs-open-file-button-label = Yab -pdfjs-print-button = - .title = Go -pdfjs-print-button-label = Go - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Gintic -pdfjs-tools-button-label = Gintic -pdfjs-first-page-button = - .title = Cit i pot buk mukwongo -pdfjs-first-page-button-label = Cit i pot buk mukwongo -pdfjs-last-page-button = - .title = Cit i pot buk magiko -pdfjs-last-page-button-label = Cit i pot buk magiko -pdfjs-page-rotate-cw-button = - .title = Wire i tung lacuc -pdfjs-page-rotate-cw-button-label = Wire i tung lacuc -pdfjs-page-rotate-ccw-button = - .title = Wire i tung lacam -pdfjs-page-rotate-ccw-button-label = Wire i tung lacam -pdfjs-cursor-text-select-tool-button = - .title = Cak gitic me yero coc -pdfjs-cursor-text-select-tool-button-label = Gitic me yero coc -pdfjs-cursor-hand-tool-button = - .title = Cak gitic me cing -pdfjs-cursor-hand-tool-button-label = Gitic cing - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Jami me gin acoya… -pdfjs-document-properties-button-label = Jami me gin acoya… -pdfjs-document-properties-file-name = Nying pwail: -pdfjs-document-properties-file-size = Dit pa pwail: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Wiye: -pdfjs-document-properties-author = Ngat mucoyo: -pdfjs-document-properties-subject = Subjek: -pdfjs-document-properties-keywords = Lok mapire tek: -pdfjs-document-properties-creation-date = Nino dwe me cwec: -pdfjs-document-properties-modification-date = Nino dwe me yub: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Lacwec: -pdfjs-document-properties-producer = Layub PDF: -pdfjs-document-properties-version = Kit PDF: -pdfjs-document-properties-page-count = Kwan me pot buk: -pdfjs-document-properties-page-size = Dit pa potbuk: -pdfjs-document-properties-page-size-unit-inches = i -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = atir -pdfjs-document-properties-page-size-orientation-landscape = arii -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Waraga -pdfjs-document-properties-page-size-name-legal = Cik - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-linearized-yes = Eyo -pdfjs-document-properties-linearized-no = Pe -pdfjs-document-properties-close-button = Lor - -## Print - -pdfjs-print-progress-message = Yubo coc me agoya… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Juki -pdfjs-printing-not-supported = Ciko: Layeny ma pe teno goyo liweng. -pdfjs-printing-not-ready = Ciko: PDF pe ocane weng me agoya. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Lok gintic ma inget -pdfjs-toggle-sidebar-button-label = Lok gintic ma inget -pdfjs-document-outline-button = - .title = Nyut Wiyewiye me Gin acoya (dii-kiryo me yaro/kano jami weng) -pdfjs-document-outline-button-label = Pek pa gin acoya -pdfjs-attachments-button = - .title = Nyut twec -pdfjs-attachments-button-label = Twec -pdfjs-thumbs-button = - .title = Nyut cal -pdfjs-thumbs-button-label = Cal -pdfjs-findbar-button = - .title = Nong iye gin acoya -pdfjs-findbar-button-label = Nong - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pot buk { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Cal me pot buk { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Nong - .placeholder = Nong i dokumen… -pdfjs-find-previous-button = - .title = Nong timme pa lok mukato -pdfjs-find-previous-button-label = Mukato -pdfjs-find-next-button = - .title = Nong timme pa lok malubo -pdfjs-find-next-button-label = Malubo -pdfjs-find-highlight-checkbox = Ket Lanyut I Weng -pdfjs-find-match-case-checkbox-label = Lok marwate -pdfjs-find-reached-top = Oo iwi gin acoya, omede ki i tere -pdfjs-find-reached-bottom = Oo i agiki me gin acoya, omede ki iwiye -pdfjs-find-not-found = Lok pe ononge - -## Predefined zoom values - -pdfjs-page-scale-width = Lac me iye pot buk -pdfjs-page-scale-fit = Porre me pot buk -pdfjs-page-scale-auto = Kwot pire kene -pdfjs-page-scale-actual = Dite kikome -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Bal otime kun cano PDF. -pdfjs-invalid-file-error = Pwail me PDF ma pe atir onyo obale woko. -pdfjs-missing-file-error = Pwail me PDF tye ka rem. -pdfjs-unexpected-response-error = Lagam mape kigeno pa lapok tic. -pdfjs-rendering-error = Bal otime i kare me nyuto pot buk. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Lok angea manok] - -## Password - -pdfjs-password-label = Ket mung me donyo me yabo pwail me PDF man. -pdfjs-password-invalid = Mung me donyo pe atir. Tim ber i tem doki. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Juki -pdfjs-web-fonts-disabled = Kijuko dit pa coc me kakube woko: pe romo tic ki dit pa coc me PDF ma kiketo i kine. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ach/viewer.properties b/static/pdf.js/locale/ach/viewer.properties new file mode 100644 index 00000000..50747b6e --- /dev/null +++ b/static/pdf.js/locale/ach/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Pot buk mukato +previous_label=Mukato +next.title=Pot buk malubo +next_label=Malubo + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pot buk: +page_of=pi {{pageCount}} + +zoom_out.title=Jwik Matidi +zoom_out_label=Jwik Matidi +zoom_in.title=Kwot Madit +zoom_in_label=Kwot Madit +zoom.title=Kwoti +presentation_mode.title=Lokke i kit me tyer +presentation_mode_label=Kit me tyer +open_file.title=Yab Pwail +open_file_label=Yab +print.title=Go +print_label=Go +download.title=Gam +download_label=Gam +bookmark.title=Neno ma kombedi (lok onyo yab i dirica manyen) +bookmark_label=Neno ma kombedi + +# Secondary toolbar and context menu +tools.title=Gintic +tools_label=Gintic +first_page.title=Cit i pot buk mukwongo +first_page.label=Cit i pot buk mukwongo +first_page_label=Cit i pot buk mukwongo +last_page.title=Cit i pot buk magiko +last_page.label=Cit i pot buk magiko +last_page_label=Cit i pot buk magiko +page_rotate_cw.title=Wire i tung lacuc +page_rotate_cw.label=Wire i tung lacuc +page_rotate_cw_label=Wire i tung lacuc +page_rotate_ccw.title=Wire i tung lacam +page_rotate_ccw.label=Wire i tung lacam +page_rotate_ccw_label=Wire i tung lacam + +hand_tool_enable.title=Ye gintic me cing +hand_tool_enable_label=Ye gintic me cing +hand_tool_disable.title=Juk gintic me cing +hand_tool_disable_label=Juk gintic me cing + +# Document properties dialog box +document_properties.title=Jami me gin acoya… +document_properties_label=Jami me gin acoya… +document_properties_file_name=Nying pwail: +document_properties_file_size=Dit pa pwail: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Wiye: +document_properties_author=Ngat mucoyo: +document_properties_subject=Lok: +document_properties_keywords=Lok mapire tek: +document_properties_creation_date=Nino dwe me cwec: +document_properties_modification_date=Nino dwe me yub: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Lacwec: +document_properties_producer=Layub PDF: +document_properties_version=Kit PDF: +document_properties_page_count=Kwan me pot buk: +document_properties_close=Lor + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Lok gintic ma inget +toggle_sidebar_label=Lok gintic ma inget +outline.title=Nyut rek pa gin acoya +outline_label=Pek pa gin acoya +attachments.title=Nyut twec +attachments_label=Twec +thumbs.title=Nyut cal +thumbs_label=Cal +findbar.title=Nong iye gin acoya +findbar_label=Nong + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pot buk {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Cal me pot buk {{page}} + +# Find panel button title and messages +find_label=Nong: +find_previous.title=Nong timme pa lok mukato +find_previous_label=Mukato +find_next.title=Nong timme pa lok malubo +find_next_label=Malubo +find_highlight=Wer weng +find_match_case_label=Lok marwate +find_reached_top=Oo iwi gin acoya, omede ki i tere +find_reached_bottom=Oo i agiki me gin acoya, omede ki iwiye +find_not_found=Lok pe ononge + +# Error panel labels +error_more_info=Ngec Mukene +error_less_info=Ngec Manok +error_close=Lor +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Kwena: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Can kikore {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Pwail: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rek: {{line}} +rendering_error=Bal otime i kare me nyuto pot buk. + +# Predefined zoom values +page_scale_width=Lac me iye pot buk +page_scale_fit=Porre me pot buk +page_scale_auto=Kwot pire kene +page_scale_actual=Dite kikome +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Bal +loading_error=Bal otime kun cano PDF. +invalid_file_error=Pwail me PDF ma pe atir onyo obale woko. +missing_file_error=Pwail me PDF tye ka rem. +unexpected_response_error=Lagam mape kigeno pa lapok tic. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Lok angea manok] +password_label=Ket mung me donyo me yabo pwail me PDF man. +password_invalid=Mung me donyo pe atir. Tim ber i tem doki. +password_ok=OK +password_cancel=Juk + +printing_not_supported=Ciko: Layeny ma pe teno goyo liweng. +printing_not_ready=Ciko: PDF pe ocane weng me agoya. +web_fonts_disabled=Kijuko dit pa coc me kakube woko: pe romo tic ki dit pa coc me PDF ma kiketo i kine. +document_colors_not_allowed=Pe ki ye ki gin acoya me PDF me tic ki rangi gi kengi: 'Ye pot buk me yero rangi mamegi kengi' kijuko woko i layeny. diff --git a/static/pdf.js/locale/af/viewer.ftl b/static/pdf.js/locale/af/viewer.ftl deleted file mode 100644 index 7c4346fe..00000000 --- a/static/pdf.js/locale/af/viewer.ftl +++ /dev/null @@ -1,212 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Vorige bladsy -pdfjs-previous-button-label = Vorige -pdfjs-next-button = - .title = Volgende bladsy -pdfjs-next-button-label = Volgende -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Bladsy -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = van { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } van { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoem uit -pdfjs-zoom-out-button-label = Zoem uit -pdfjs-zoom-in-button = - .title = Zoem in -pdfjs-zoom-in-button-label = Zoem in -pdfjs-zoom-select = - .title = Zoem -pdfjs-presentation-mode-button = - .title = Wissel na voorleggingsmodus -pdfjs-presentation-mode-button-label = Voorleggingsmodus -pdfjs-open-file-button = - .title = Open lêer -pdfjs-open-file-button-label = Open -pdfjs-print-button = - .title = Druk -pdfjs-print-button-label = Druk - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Nutsgoed -pdfjs-tools-button-label = Nutsgoed -pdfjs-first-page-button = - .title = Gaan na eerste bladsy -pdfjs-first-page-button-label = Gaan na eerste bladsy -pdfjs-last-page-button = - .title = Gaan na laaste bladsy -pdfjs-last-page-button-label = Gaan na laaste bladsy -pdfjs-page-rotate-cw-button = - .title = Roteer kloksgewys -pdfjs-page-rotate-cw-button-label = Roteer kloksgewys -pdfjs-page-rotate-ccw-button = - .title = Roteer anti-kloksgewys -pdfjs-page-rotate-ccw-button-label = Roteer anti-kloksgewys -pdfjs-cursor-text-select-tool-button = - .title = Aktiveer gereedskap om teks te merk -pdfjs-cursor-text-select-tool-button-label = Teksmerkgereedskap -pdfjs-cursor-hand-tool-button = - .title = Aktiveer handjie -pdfjs-cursor-hand-tool-button-label = Handjie - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumenteienskappe… -pdfjs-document-properties-button-label = Dokumenteienskappe… -pdfjs-document-properties-file-name = Lêernaam: -pdfjs-document-properties-file-size = Lêergrootte: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kG ({ $size_b } grepe) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MG ({ $size_b } grepe) -pdfjs-document-properties-title = Titel: -pdfjs-document-properties-author = Outeur: -pdfjs-document-properties-subject = Onderwerp: -pdfjs-document-properties-keywords = Sleutelwoorde: -pdfjs-document-properties-creation-date = Skeppingsdatum: -pdfjs-document-properties-modification-date = Wysigingsdatum: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Skepper: -pdfjs-document-properties-producer = PDF-vervaardiger: -pdfjs-document-properties-version = PDF-weergawe: -pdfjs-document-properties-page-count = Aantal bladsye: - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -pdfjs-document-properties-close-button = Sluit - -## Print - -pdfjs-print-progress-message = Berei tans dokument voor om te druk… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Kanselleer -pdfjs-printing-not-supported = Waarskuwing: Dié blaaier ondersteun nie drukwerk ten volle nie. -pdfjs-printing-not-ready = Waarskuwing: Die PDF is nog nie volledig gelaai vir drukwerk nie. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Sypaneel aan/af -pdfjs-toggle-sidebar-button-label = Sypaneel aan/af -pdfjs-document-outline-button = - .title = Wys dokumentskema (dubbelklik om alle items oop/toe te vou) -pdfjs-document-outline-button-label = Dokumentoorsig -pdfjs-attachments-button = - .title = Wys aanhegsels -pdfjs-attachments-button-label = Aanhegsels -pdfjs-thumbs-button = - .title = Wys duimnaels -pdfjs-thumbs-button-label = Duimnaels -pdfjs-findbar-button = - .title = Soek in dokument -pdfjs-findbar-button-label = Vind - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Bladsy { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Duimnael van bladsy { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Vind - .placeholder = Soek in dokument… -pdfjs-find-previous-button = - .title = Vind die vorige voorkoms van die frase -pdfjs-find-previous-button-label = Vorige -pdfjs-find-next-button = - .title = Vind die volgende voorkoms van die frase -pdfjs-find-next-button-label = Volgende -pdfjs-find-highlight-checkbox = Verlig almal -pdfjs-find-match-case-checkbox-label = Kassensitief -pdfjs-find-reached-top = Bokant van dokument is bereik; gaan voort van onder af -pdfjs-find-reached-bottom = Einde van dokument is bereik; gaan voort van bo af -pdfjs-find-not-found = Frase nie gevind nie - -## Predefined zoom values - -pdfjs-page-scale-width = Bladsywydte -pdfjs-page-scale-fit = Pas bladsy -pdfjs-page-scale-auto = Outomatiese zoem -pdfjs-page-scale-actual = Werklike grootte -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = 'n Fout het voorgekom met die laai van die PDF. -pdfjs-invalid-file-error = Ongeldige of korrupte PDF-lêer. -pdfjs-missing-file-error = PDF-lêer is weg. -pdfjs-unexpected-response-error = Onverwagse antwoord van bediener. -pdfjs-rendering-error = 'n Fout het voorgekom toe die bladsy weergegee is. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type }-annotasie] - -## Password - -pdfjs-password-label = Gee die wagwoord om dié PDF-lêer mee te open. -pdfjs-password-invalid = Ongeldige wagwoord. Probeer gerus weer. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Kanselleer -pdfjs-web-fonts-disabled = Webfonte is gedeaktiveer: kan nie PDF-fonte wat ingebed is, gebruik nie. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/af/viewer.properties b/static/pdf.js/locale/af/viewer.properties new file mode 100644 index 00000000..052413dd --- /dev/null +++ b/static/pdf.js/locale/af/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Vorige bladsy +previous_label=Vorige +next.title=Volgende bladsy +next_label=Volgende + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Bladsy: +page_of=van {{pageCount}} + +zoom_out.title=Zoem uit +zoom_out_label=Zoem uit +zoom_in.title=Zoem in +zoom_in_label=Zoem in +zoom.title=Zoem +presentation_mode.title=Wissel na voorleggingsmodus +presentation_mode_label=Voorleggingsmodus +open_file.title=Open lêer +open_file_label=Open +print.title=Druk +print_label=Druk +download.title=Laai af +download_label=Laai af +bookmark.title=Huidige aansig (kopieer of open in nuwe venster) +bookmark_label=Huidige aansig + +# Secondary toolbar and context menu +tools.title=Nutsgoed +tools_label=Nutsgoed +first_page.title=Gaan na eerste bladsy +first_page.label=Gaan na eerste bladsy +first_page_label=Gaan na eerste bladsy +last_page.title=Gaan na laaste bladsy +last_page.label=Gaan na laaste bladsy +last_page_label=Gaan na laaste bladsy +page_rotate_cw.title=Roteer kloksgewys +page_rotate_cw.label=Roteer kloksgewys +page_rotate_cw_label=Roteer kloksgewys +page_rotate_ccw.title=Roteer anti-kloksgewys +page_rotate_ccw.label=Roteer anti-kloksgewys +page_rotate_ccw_label=Roteer anti-kloksgewys + +hand_tool_enable.title=Aktiveer handjie +hand_tool_enable_label=Aktiveer handjie +hand_tool_disable.title=Deaktiveer handjie +hand_tool_disable_label=Deaktiveer handjie + +# Document properties dialog box +document_properties.title=Dokumenteienskappe… +document_properties_label=Dokumenteienskappe… +document_properties_file_name=Lêernaam: +document_properties_file_size=Lêergrootte: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} kG ({{size_b}} grepe) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MG ({{size_b}} grepe) +document_properties_title=Titel: +document_properties_author=Outeur: +document_properties_subject=Onderwerp: +document_properties_keywords=Sleutelwoorde: +document_properties_creation_date=Skeppingsdatum: +document_properties_modification_date=Wysigingsdatum: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Skepper: +document_properties_producer=PDF-vervaardiger: +document_properties_version=PDF-weergawe: +document_properties_page_count=Aantal bladsye: +document_properties_close=Sluit + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Sypaneel aan/af +toggle_sidebar_label=Sypaneel aan/af +outline.title=Wys dokumentoorsig +outline_label=Dokumentoorsig +attachments.title=Wys aanhegsels +attachments_label=Aanhegsels +thumbs.title=Wys duimnaels +thumbs_label=Duimnaels +findbar.title=Soek in dokument +findbar_label=Vind + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Bladsy {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Duimnael van bladsy {{page}} + +# Find panel button title and messages +find_label=Vind: +find_previous.title=Vind die vorige voorkoms van die frase +find_previous_label=Vorige +find_next.title=Vind die volgende voorkoms van die frase +find_next_label=Volgende +find_highlight=Verlig alle +find_match_case_label=Kassensitief +find_reached_top=Bokant van dokument is bereik; gaan voort van onder af +find_reached_bottom=Einde van dokument is bereik; gaan voort van bo af +find_not_found=Frase nie gevind nie + +# Error panel labels +error_more_info=Meer inligting +error_less_info=Minder inligting +error_close=Sluit +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (ID: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Boodskap: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stapel: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Lêer: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Lyn: {{line}} +rendering_error='n Fout het voorgekom toe die bladsy weergegee is. + +# Predefined zoom values +page_scale_width=Bladsywydte +page_scale_fit=Pas bladsy +page_scale_auto=Outomatiese zoem +page_scale_actual=Werklike grootte +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Fout +loading_error='n Fout het voorgekom met die laai van die PDF. +invalid_file_error=Ongeldige of korrupte PDF-lêer. +missing_file_error=PDF-lêer is weg. +unexpected_response_error=Onverwagse antwoord van bediener. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}}-annotasie +password_label=Gee die wagwoord om dié PDF-lêer mee te open. +password_invalid=Ongeldige wagwoord. Probeer gerus weer. +password_ok=OK +password_cancel=Kanselleer + +printing_not_supported=Waarskuwing: Dié blaaier ondersteun nie drukwerk ten volle nie. +printing_not_ready=Waarskuwing: Die PDF is nog nie volledig gelaai vir drukwerk nie. +web_fonts_disabled=Webfonte is gedeaktiveer: kan nie PDF-fonte wat ingebed is, gebruik nie. +document_colors_not_allowed=PDF-dokumente word nie toegelaat om hul eie kleure te gebruik nie: 'Laat bladsye toe om hul eie kleure te kies' is gedeaktiveer in die blaaier. diff --git a/static/pdf.js/locale/ak/viewer.properties b/static/pdf.js/locale/ak/viewer.properties new file mode 100644 index 00000000..83eacd63 --- /dev/null +++ b/static/pdf.js/locale/ak/viewer.properties @@ -0,0 +1,131 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Krataafa baako a etwa mu +previous_label=Ekyiri-baako +next.title=Krataafa a edi so baako +next_label=Dea-ɛ-di-so-baako + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Krataafa: +page_of=wɔ {{pageCount}} + +zoom_out.title=Zuum pue +zoom_out_label=Zuum ba abɔnten +zoom_in.title=Zuum kɔ mu +zoom_in_label=Zuum kɔ mu +zoom.title=Zuum +presentation_mode.title=Sesa kɔ Yɛkyerɛ Tebea mu +presentation_mode_label=Yɛkyerɛ Tebea +open_file.title=Bue Fael +open_file_label=Bue +print.title=Prente +print_label=Prente +download.title=Twe +download_label=Twe +bookmark.title=Seisei nhwɛ (fa anaaso bue wɔ tokuro foforo mu) +bookmark_label=Seisei nhwɛ + +# Secondary toolbar and context menu + + +# Document properties dialog box +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Ti asɛm: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Sɔ anaaso dum saedbaa +toggle_sidebar_label=Sɔ anaaso dum saedbaa +outline.title=Kyerɛ dɔkomɛnt bɔbea +outline_label=Dɔkomɛnt bɔbea +thumbs.title=Kyerɛ mfoniwaa +thumbs_label=Mfoniwaa +findbar.title=Hu wɔ dɔkomɛnt no mu +findbar_label=Hu + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Krataafa {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Krataafa ne mfoniwaa {{page}} + +# Find panel button title and messages +find_label=Hunu: +find_previous.title=San hu fres wɔ ekyiri baako +find_previous_label=Ekyiri baako +find_next.title=San hu fres no wɔ enim baako +find_next_label=Ndiso +find_highlight=Hyɛ bibiara nso +find_match_case_label=Fa susu kaase +find_reached_top=Edu krataafa ne soro, atoa so efiri ase +find_reached_bottom=Edu krataafa n'ewiei, atoa so efiri soro +find_not_found=Ennhu fres + +# Error panel labels +error_more_info=Infɔmehyɛn bio a wɔka ho +error_less_info=Te infɔmehyɛn bio a wɔka ho so +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{vɛɛhyen}} (nsi: {{si}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Nkrato: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Staake: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fael: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Laen: {{line}} +rendering_error=Mfomso bae wɔ bere a wɔ rekyerɛ krataafa no. + +# Predefined zoom values +page_scale_width=Krataafa tɛtrɛtɛ +page_scale_fit=Krataafa ehimtwa +page_scale_auto=Zuum otomatik +page_scale_actual=Kɛseyɛ ankasa +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Mfomso +loading_error=Mfomso bae wɔ bere a wɔreloode PDF no. +invalid_file_error=PDF fael no nndi mu anaaso ho atɔ kyima. +missing_file_error=PDF fael no ayera. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Tɛkst-nyiano] +password_ok=OK +password_cancel=Twa-mu + +printing_not_supported=Kɔkɔbɔ: Brawsa yi nnhyɛ daa mma prent ho kwan. +printing_not_ready=Kɔkɔbɔ: Wɔnntwee PDF fael no nyinara mmbaee ama wo ɛ tumi aprente. +web_fonts_disabled=Ɔedum wɛb-mfɔnt: nntumi mmfa PDF mfɔnt a wɔhyɛ mu nndi dwuma. +document_colors_not_allowed=Wɔmma ho kwan sɛ PDF adɔkomɛnt de wɔn ara wɔn ahosu bɛdi dwuma: wɔ adum 'Ma ho kwan ma nkrataafa mpaw wɔn ara wɔn ahosu' wɔ brawsa yi mu. diff --git a/static/pdf.js/locale/an/viewer.ftl b/static/pdf.js/locale/an/viewer.ftl deleted file mode 100644 index 67331477..00000000 --- a/static/pdf.js/locale/an/viewer.ftl +++ /dev/null @@ -1,257 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pachina anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Pachina siguient -pdfjs-next-button-label = Siguient -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pachina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Achiquir -pdfjs-zoom-out-button-label = Achiquir -pdfjs-zoom-in-button = - .title = Agrandir -pdfjs-zoom-in-button-label = Agrandir -pdfjs-zoom-select = - .title = Grandaria -pdfjs-presentation-mode-button = - .title = Cambear t'o modo de presentación -pdfjs-presentation-mode-button-label = Modo de presentación -pdfjs-open-file-button = - .title = Ubrir o fichero -pdfjs-open-file-button-label = Ubrir -pdfjs-print-button = - .title = Imprentar -pdfjs-print-button-label = Imprentar - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Ferramientas -pdfjs-tools-button-label = Ferramientas -pdfjs-first-page-button = - .title = Ir ta la primer pachina -pdfjs-first-page-button-label = Ir ta la primer pachina -pdfjs-last-page-button = - .title = Ir ta la zaguer pachina -pdfjs-last-page-button-label = Ir ta la zaguer pachina -pdfjs-page-rotate-cw-button = - .title = Chirar enta la dreita -pdfjs-page-rotate-cw-button-label = Chira enta la dreita -pdfjs-page-rotate-ccw-button = - .title = Chirar enta la zurda -pdfjs-page-rotate-ccw-button-label = Chirar enta la zurda -pdfjs-cursor-text-select-tool-button = - .title = Activar la ferramienta de selección de texto -pdfjs-cursor-text-select-tool-button-label = Ferramienta de selección de texto -pdfjs-cursor-hand-tool-button = - .title = Activar la ferramienta man -pdfjs-cursor-hand-tool-button-label = Ferramienta man -pdfjs-scroll-vertical-button = - .title = Usar lo desplazamiento vertical -pdfjs-scroll-vertical-button-label = Desplazamiento vertical -pdfjs-scroll-horizontal-button = - .title = Usar lo desplazamiento horizontal -pdfjs-scroll-horizontal-button-label = Desplazamiento horizontal -pdfjs-scroll-wrapped-button = - .title = Activaar lo desplazamiento contino -pdfjs-scroll-wrapped-button-label = Desplazamiento contino -pdfjs-spread-none-button = - .title = No unir vistas de pachinas -pdfjs-spread-none-button-label = Una pachina nomás -pdfjs-spread-odd-button = - .title = Mostrar vista de pachinas, con as impars a la zurda -pdfjs-spread-odd-button-label = Doble pachina, impar a la zurda -pdfjs-spread-even-button = - .title = Amostrar vista de pachinas, con as pars a la zurda -pdfjs-spread-even-button-label = Doble pachina, para a la zurda - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propiedatz d'o documento... -pdfjs-document-properties-button-label = Propiedatz d'o documento... -pdfjs-document-properties-file-name = Nombre de fichero: -pdfjs-document-properties-file-size = Grandaria d'o fichero: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Titol: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Afer: -pdfjs-document-properties-keywords = Parolas clau: -pdfjs-document-properties-creation-date = Calendata de creyación: -pdfjs-document-properties-modification-date = Calendata de modificación: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creyador: -pdfjs-document-properties-producer = Creyador de PDF: -pdfjs-document-properties-version = Versión de PDF: -pdfjs-document-properties-page-count = Numero de pachinas: -pdfjs-document-properties-page-size = Mida de pachina: -pdfjs-document-properties-page-size-unit-inches = pulgadas -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = horizontal -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } x { $height } { $unit } { $orientation } -pdfjs-document-properties-page-size-dimension-name-string = { $width } x { $height } { $unit } { $name }, { $orientation } - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista web rapida: -pdfjs-document-properties-linearized-yes = Sí -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Zarrar - -## Print - -pdfjs-print-progress-message = Se ye preparando la documentación pa imprentar… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancelar -pdfjs-printing-not-supported = Pare cuenta: Iste navegador no maneya totalment as impresions. -pdfjs-printing-not-ready = Aviso: Encara no se ha cargau completament o PDF ta imprentar-lo. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Amostrar u amagar a barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Cambiar barra lateral (lo documento contiene esquema/adchuntos/capas) -pdfjs-toggle-sidebar-button-label = Amostrar a barra lateral -pdfjs-document-outline-button = - .title = Amostrar esquema d'o documento (fer doble clic pa expandir/compactar totz los items) -pdfjs-document-outline-button-label = Esquema d'o documento -pdfjs-attachments-button = - .title = Amostrar os adchuntos -pdfjs-attachments-button-label = Adchuntos -pdfjs-layers-button = - .title = Amostrar capas (doble clic para reiniciar totas las capas a lo estau per defecto) -pdfjs-layers-button-label = Capas -pdfjs-thumbs-button = - .title = Amostrar as miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-findbar-button = - .title = Trobar en o documento -pdfjs-findbar-button-label = Trobar -pdfjs-additional-layers = Capas adicionals - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pachina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura d'a pachina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Trobar - .placeholder = Trobar en o documento… -pdfjs-find-previous-button = - .title = Trobar l'anterior coincidencia d'a frase -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button = - .title = Trobar a siguient coincidencia d'a frase -pdfjs-find-next-button-label = Siguient -pdfjs-find-highlight-checkbox = Resaltar-lo tot -pdfjs-find-match-case-checkbox-label = Coincidencia de mayusclas/minusclas -pdfjs-find-entire-word-checkbox-label = Parolas completas -pdfjs-find-reached-top = S'ha plegau a l'inicio d'o documento, se contina dende baixo -pdfjs-find-reached-bottom = S'ha plegau a la fin d'o documento, se contina dende alto -pdfjs-find-not-found = No s'ha trobau a frase - -## Predefined zoom values - -pdfjs-page-scale-width = Amplaria d'a pachina -pdfjs-page-scale-fit = Achuste d'a pachina -pdfjs-page-scale-auto = Grandaria automatica -pdfjs-page-scale-actual = Grandaria actual -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = S'ha produciu una error en cargar o PDF. -pdfjs-invalid-file-error = O PDF no ye valido u ye estorbau. -pdfjs-missing-file-error = No i ha fichero PDF. -pdfjs-unexpected-response-error = Respuesta a lo servicio inasperada. -pdfjs-rendering-error = Ha ocurriu una error en renderizar a pachina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotación { $type }] - -## Password - -pdfjs-password-label = Introduzca a clau ta ubrir iste fichero PDF. -pdfjs-password-invalid = Clau invalida. Torna a intentar-lo. -pdfjs-password-ok-button = Acceptar -pdfjs-password-cancel-button = Cancelar -pdfjs-web-fonts-disabled = As fuents web son desactivadas: no se puet incrustar fichers PDF. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/an/viewer.properties b/static/pdf.js/locale/an/viewer.properties new file mode 100644 index 00000000..ad26285e --- /dev/null +++ b/static/pdf.js/locale/an/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Pachina anterior +previous_label=Anterior +next.title=Pachina siguient +next_label=Siguient + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pachina: +page_of=de {{pageCount}} + +zoom_out.title=Achiquir +zoom_out_label=Achiquir +zoom_in.title=Agrandir +zoom_in_label=Agrandir +zoom.title=Grandaria +presentation_mode.title=Cambear t'o modo de presentación +presentation_mode_label=Modo de presentación +open_file.title=Ubrir o fichero +open_file_label=Ubrir +print.title=Imprentar +print_label=Imprentar +download.title=Descargar +download_label=Descargar +bookmark.title=Vista actual (copiar u ubrir en una nueva finestra) +bookmark_label=Anvista actual + +# Secondary toolbar and context menu +tools.title=Ferramientas +tools_label=Ferramientas +first_page.title=Ir ta la primer pachina +first_page.label=Ir ta la primer pachina +first_page_label=Ir ta la primer pachina +last_page.title=Ir ta la zaguer pachina +last_page.label=Ir ta la zaguera pachina +last_page_label=Ir ta la zaguer pachina +page_rotate_cw.title=Chirar enta la dreita +page_rotate_cw.label=Chirar enta la dreita +page_rotate_cw_label=Chira enta la dreita +page_rotate_ccw.title=Chirar enta la zurda +page_rotate_ccw.label=Chirar en sentiu antihorario +page_rotate_ccw_label=Chirar enta la zurda + +hand_tool_enable.title=Activar a ferramienta man +hand_tool_enable_label=Activar a ferramenta man +hand_tool_disable.title=Desactivar a ferramienta man +hand_tool_disable_label=Desactivar a ferramienta man + +# Document properties dialog box +document_properties.title=Propiedatz d'o documento... +document_properties_label=Propiedatz d'o documento... +document_properties_file_name=Nombre de fichero: +document_properties_file_size=Grandaria d'o fichero: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Titol: +document_properties_author=Autor: +document_properties_subject=Afer: +document_properties_keywords=Parolas clau: +document_properties_creation_date=Calendata de creyación: +document_properties_modification_date=Calendata de modificación: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creyador: +document_properties_producer=Creyador de PDF: +document_properties_version=Versión de PDF: +document_properties_page_count=Numero de pachinas: +document_properties_close=Zarrar + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Amostrar u amagar a barra lateral +toggle_sidebar_label=Amostrar a barra lateral +outline.title=Amostrar o esquema d'o documento +outline_label=Esquema d'o documento +attachments.title=Amostrar os adchuntos +attachments_label=Adchuntos +thumbs.title=Amostrar as miniaturas +thumbs_label=Miniaturas +findbar.title=Trobar en o documento +findbar_label=Trobar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pachina {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura d'a pachina {{page}} + +# Find panel button title and messages +find_label=Trobar: +find_previous.title=Trobar l'anterior coincidencia d'a frase +find_previous_label=Anterior +find_next.title=Trobar a siguient coincidencia d'a frase +find_next_label=Siguient +find_highlight=Resaltar-lo tot +find_match_case_label=Coincidencia de mayusclas/minusclas +find_reached_top=S'ha plegau a l'inicio d'o documento, se contina dende baixo +find_reached_bottom=S'ha plegau a la fin d'o documento, se contina dende alto +find_not_found=No s'ha trobau a frase + +# Error panel labels +error_more_info=Mas información +error_less_info=Menos información +error_close=Zarrar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mensache: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pila: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fichero: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linia: {{line}} +rendering_error=Ha ocurriu una error en renderizar a pachina. + +# Predefined zoom values +page_scale_width=Amplaria d'a pachina +page_scale_fit=Achuste d'a pachina +page_scale_auto=Grandaria automatica +page_scale_actual=Grandaria actual +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Error +loading_error=S'ha produciu una error en cargar o PDF. +invalid_file_error=O PDF no ye valido u ye estorbau. +missing_file_error=No i ha fichero PDF. +unexpected_response_error=Respuesta a lo servicio inasperada. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotación {{type}}] +password_label=Introduzca a clau ta ubrir iste fichero PDF. +password_invalid=Clau invalida. Torna a intentar-lo. +password_ok=Acceptar +password_cancel=Cancelar + +printing_not_supported=Pare cuenta: Iste navegador no maneya totalment as impresions. +printing_not_ready=Aviso: Encara no se ha cargau completament o PDF ta imprentar-lo. +web_fonts_disabled=As fuents web son desactivadas: no se puet incrustar fichers PDF. +document_colors_not_allowed=Os documentos PDF no pueden fer servir as suyas propias colors: 'Permitir que as pachinas triguen as suyas propias colors' ye desactivau en o navegador. diff --git a/static/pdf.js/locale/ar/viewer.ftl b/static/pdf.js/locale/ar/viewer.ftl deleted file mode 100644 index 97d6da57..00000000 --- a/static/pdf.js/locale/ar/viewer.ftl +++ /dev/null @@ -1,404 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = الصفحة السابقة -pdfjs-previous-button-label = السابقة -pdfjs-next-button = - .title = الصفحة التالية -pdfjs-next-button-label = التالية -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = صفحة -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = من { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } من { $pagesCount }) -pdfjs-zoom-out-button = - .title = بعّد -pdfjs-zoom-out-button-label = بعّد -pdfjs-zoom-in-button = - .title = قرّب -pdfjs-zoom-in-button-label = قرّب -pdfjs-zoom-select = - .title = التقريب -pdfjs-presentation-mode-button = - .title = انتقل لوضع العرض التقديمي -pdfjs-presentation-mode-button-label = وضع العرض التقديمي -pdfjs-open-file-button = - .title = افتح ملفًا -pdfjs-open-file-button-label = افتح -pdfjs-print-button = - .title = اطبع -pdfjs-print-button-label = اطبع -pdfjs-save-button = - .title = احفظ -pdfjs-save-button-label = احفظ -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = نزّل -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = نزّل -pdfjs-bookmark-button = - .title = الصفحة الحالية (عرض URL من الصفحة الحالية) -pdfjs-bookmark-button-label = الصفحة الحالية - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = الأدوات -pdfjs-tools-button-label = الأدوات -pdfjs-first-page-button = - .title = انتقل إلى الصفحة الأولى -pdfjs-first-page-button-label = انتقل إلى الصفحة الأولى -pdfjs-last-page-button = - .title = انتقل إلى الصفحة الأخيرة -pdfjs-last-page-button-label = انتقل إلى الصفحة الأخيرة -pdfjs-page-rotate-cw-button = - .title = أدر باتجاه عقارب الساعة -pdfjs-page-rotate-cw-button-label = أدر باتجاه عقارب الساعة -pdfjs-page-rotate-ccw-button = - .title = أدر بعكس اتجاه عقارب الساعة -pdfjs-page-rotate-ccw-button-label = أدر بعكس اتجاه عقارب الساعة -pdfjs-cursor-text-select-tool-button = - .title = فعّل أداة اختيار النص -pdfjs-cursor-text-select-tool-button-label = أداة اختيار النص -pdfjs-cursor-hand-tool-button = - .title = فعّل أداة اليد -pdfjs-cursor-hand-tool-button-label = أداة اليد -pdfjs-scroll-page-button = - .title = استخدم تمرير الصفحة -pdfjs-scroll-page-button-label = تمرير الصفحة -pdfjs-scroll-vertical-button = - .title = استخدم التمرير الرأسي -pdfjs-scroll-vertical-button-label = التمرير الرأسي -pdfjs-scroll-horizontal-button = - .title = استخدم التمرير الأفقي -pdfjs-scroll-horizontal-button-label = التمرير الأفقي -pdfjs-scroll-wrapped-button = - .title = استخدم التمرير الملتف -pdfjs-scroll-wrapped-button-label = التمرير الملتف -pdfjs-spread-none-button = - .title = لا تدمج هوامش الصفحات مع بعضها البعض -pdfjs-spread-none-button-label = بلا هوامش -pdfjs-spread-odd-button = - .title = ادمج هوامش الصفحات الفردية -pdfjs-spread-odd-button-label = هوامش الصفحات الفردية -pdfjs-spread-even-button = - .title = ادمج هوامش الصفحات الزوجية -pdfjs-spread-even-button-label = هوامش الصفحات الزوجية - -## Document properties dialog - -pdfjs-document-properties-button = - .title = خصائص المستند… -pdfjs-document-properties-button-label = خصائص المستند… -pdfjs-document-properties-file-name = اسم الملف: -pdfjs-document-properties-file-size = حجم الملف: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } ك.بايت ({ $size_b } بايت) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } م.بايت ({ $size_b } بايت) -pdfjs-document-properties-title = العنوان: -pdfjs-document-properties-author = المؤلف: -pdfjs-document-properties-subject = الموضوع: -pdfjs-document-properties-keywords = الكلمات الأساسية: -pdfjs-document-properties-creation-date = تاريخ الإنشاء: -pdfjs-document-properties-modification-date = تاريخ التعديل: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }، { $time } -pdfjs-document-properties-creator = المنشئ: -pdfjs-document-properties-producer = منتج PDF: -pdfjs-document-properties-version = إصدارة PDF: -pdfjs-document-properties-page-count = عدد الصفحات: -pdfjs-document-properties-page-size = مقاس الورقة: -pdfjs-document-properties-page-size-unit-inches = بوصة -pdfjs-document-properties-page-size-unit-millimeters = ملم -pdfjs-document-properties-page-size-orientation-portrait = طوليّ -pdfjs-document-properties-page-size-orientation-landscape = عرضيّ -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = خطاب -pdfjs-document-properties-page-size-name-legal = قانونيّ - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = ‏{ $width } × ‏{ $height } ‏{ $unit } (‏{ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = ‏{ $width } × ‏{ $height } ‏{ $unit } (‏{ $name }، { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = العرض السريع عبر الوِب: -pdfjs-document-properties-linearized-yes = نعم -pdfjs-document-properties-linearized-no = لا -pdfjs-document-properties-close-button = أغلق - -## Print - -pdfjs-print-progress-message = يُحضّر المستند للطباعة… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }٪ -pdfjs-print-progress-close-button = ألغِ -pdfjs-printing-not-supported = تحذير: لا يدعم هذا المتصفح الطباعة بشكل كامل. -pdfjs-printing-not-ready = تحذير: ملف PDF لم يُحمّل كاملًا للطباعة. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = بدّل ظهور الشريط الجانبي -pdfjs-toggle-sidebar-notification-button = - .title = بدّل ظهور الشريط الجانبي (يحتوي المستند على مخطط أو مرفقات أو طبقات) -pdfjs-toggle-sidebar-button-label = بدّل ظهور الشريط الجانبي -pdfjs-document-outline-button = - .title = اعرض فهرس المستند (نقر مزدوج لتمديد أو تقليص كل العناصر) -pdfjs-document-outline-button-label = مخطط المستند -pdfjs-attachments-button = - .title = اعرض المرفقات -pdfjs-attachments-button-label = المُرفقات -pdfjs-layers-button = - .title = اعرض الطبقات (انقر مرتين لتصفير كل الطبقات إلى الحالة المبدئية) -pdfjs-layers-button-label = ‏‏الطبقات -pdfjs-thumbs-button = - .title = اعرض مُصغرات -pdfjs-thumbs-button-label = مُصغّرات -pdfjs-current-outline-item-button = - .title = ابحث عن عنصر المخطّط التفصيلي الحالي -pdfjs-current-outline-item-button-label = عنصر المخطّط التفصيلي الحالي -pdfjs-findbar-button = - .title = ابحث في المستند -pdfjs-findbar-button-label = ابحث -pdfjs-additional-layers = الطبقات الإضافية - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = صفحة { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = مصغّرة صفحة { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = ابحث - .placeholder = ابحث في المستند… -pdfjs-find-previous-button = - .title = ابحث عن التّواجد السّابق للعبارة -pdfjs-find-previous-button-label = السابق -pdfjs-find-next-button = - .title = ابحث عن التّواجد التّالي للعبارة -pdfjs-find-next-button-label = التالي -pdfjs-find-highlight-checkbox = أبرِز الكل -pdfjs-find-match-case-checkbox-label = طابق حالة الأحرف -pdfjs-find-match-diacritics-checkbox-label = طابِق الحركات -pdfjs-find-entire-word-checkbox-label = كلمات كاملة -pdfjs-find-reached-top = تابعت من الأسفل بعدما وصلت إلى بداية المستند -pdfjs-find-reached-bottom = تابعت من الأعلى بعدما وصلت إلى نهاية المستند -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [zero] لا مطابقة - [one] { $current } من أصل { $total } مطابقة - [two] { $current } من أصل { $total } مطابقة - [few] { $current } من أصل { $total } مطابقة - [many] { $current } من أصل { $total } مطابقة - *[other] { $current } من أصل { $total } مطابقة - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [zero] { $limit } مطابقة - [one] أكثر من { $limit } مطابقة - [two] أكثر من { $limit } مطابقة - [few] أكثر من { $limit } مطابقة - [many] أكثر من { $limit } مطابقة - *[other] أكثر من { $limit } مطابقات - } -pdfjs-find-not-found = لا وجود للعبارة - -## Predefined zoom values - -pdfjs-page-scale-width = عرض الصفحة -pdfjs-page-scale-fit = ملائمة الصفحة -pdfjs-page-scale-auto = تقريب تلقائي -pdfjs-page-scale-actual = الحجم الفعلي -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }٪ - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = صفحة { $page } - -## Loading indicator messages - -pdfjs-loading-error = حدث عطل أثناء تحميل ملف PDF. -pdfjs-invalid-file-error = ملف PDF تالف أو غير صحيح. -pdfjs-missing-file-error = ملف PDF غير موجود. -pdfjs-unexpected-response-error = استجابة خادوم غير متوقعة. -pdfjs-rendering-error = حدث خطأ أثناء عرض الصفحة. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }، { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [تعليق { $type }] - -## Password - -pdfjs-password-label = أدخل لكلمة السر لفتح هذا الملف. -pdfjs-password-invalid = كلمة سر خطأ. من فضلك أعد المحاولة. -pdfjs-password-ok-button = حسنا -pdfjs-password-cancel-button = ألغِ -pdfjs-web-fonts-disabled = خطوط الوب مُعطّلة: تعذّر استخدام خطوط PDF المُضمّنة. - -## Editing - -pdfjs-editor-free-text-button = - .title = نص -pdfjs-editor-free-text-button-label = نص -pdfjs-editor-ink-button = - .title = ارسم -pdfjs-editor-ink-button-label = ارسم -pdfjs-editor-stamp-button = - .title = أضِف أو حرّر الصور -pdfjs-editor-stamp-button-label = أضِف أو حرّر الصور -pdfjs-editor-highlight-button = - .title = أبرِز -pdfjs-editor-highlight-button-label = أبرِز -pdfjs-highlight-floating-button = - .title = أبرِز -pdfjs-highlight-floating-button1 = - .title = أبرِز - .aria-label = أبرِز -pdfjs-highlight-floating-button-label = أبرِز - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = أزِل الرسم -pdfjs-editor-remove-freetext-button = - .title = أزِل النص -pdfjs-editor-remove-stamp-button = - .title = أزِل الصورة -pdfjs-editor-remove-highlight-button = - .title = أزِل الإبراز - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = اللون -pdfjs-editor-free-text-size-input = الحجم -pdfjs-editor-ink-color-input = اللون -pdfjs-editor-ink-thickness-input = السماكة -pdfjs-editor-ink-opacity-input = العتامة -pdfjs-editor-stamp-add-image-button = - .title = أضِف صورة -pdfjs-editor-stamp-add-image-button-label = أضِف صورة -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = السماكة -pdfjs-editor-free-highlight-thickness-title = - .title = غيّر السُمك عند إبراز عناصر أُخرى غير النص -pdfjs-free-text = - .aria-label = محرِّر النص -pdfjs-free-text-default-content = ابدأ الكتابة… -pdfjs-ink = - .aria-label = محرِّر الرسم -pdfjs-ink-canvas = - .aria-label = صورة أنشأها المستخدم - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = نص بديل -pdfjs-editor-alt-text-edit-button-label = تحرير النص البديل -pdfjs-editor-alt-text-dialog-label = اختر خيار -pdfjs-editor-alt-text-dialog-description = يساعد النص البديل عندما لا يتمكن الأشخاص من رؤية الصورة أو عندما لا يتم تحميلها. -pdfjs-editor-alt-text-add-description-label = أضِف وصف -pdfjs-editor-alt-text-add-description-description = استهدف جملتين تصفان الموضوع أو الإعداد أو الإجراءات. -pdfjs-editor-alt-text-mark-decorative-label = علّمها على أنها زخرفية -pdfjs-editor-alt-text-mark-decorative-description = يُستخدم هذا في الصور المزخرفة، مثل الحدود أو العلامات المائية. -pdfjs-editor-alt-text-cancel-button = ألغِ -pdfjs-editor-alt-text-save-button = احفظ -pdfjs-editor-alt-text-decorative-tooltip = عُلّمت على أنها زخرفية -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = على سبيل المثال، "يجلس شاب على الطاولة لتناول وجبة" - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = الزاوية اليُسرى العُليا — غيّر الحجم -pdfjs-editor-resizer-label-top-middle = أعلى الوسط - غيّر الحجم -pdfjs-editor-resizer-label-top-right = الزاوية اليُمنى العُليا - غيّر الحجم -pdfjs-editor-resizer-label-middle-right = اليمين الأوسط - غيّر الحجم -pdfjs-editor-resizer-label-bottom-right = الزاوية اليُمنى السُفلى - غيّر الحجم -pdfjs-editor-resizer-label-bottom-middle = أسفل الوسط - غيّر الحجم -pdfjs-editor-resizer-label-bottom-left = الزاوية اليُسرى السُفلية - غيّر الحجم -pdfjs-editor-resizer-label-middle-left = مُنتصف اليسار - غيّر الحجم - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = أبرِز اللون -pdfjs-editor-colorpicker-button = - .title = غيّر اللون -pdfjs-editor-colorpicker-dropdown = - .aria-label = اختيارات الألوان -pdfjs-editor-colorpicker-yellow = - .title = أصفر -pdfjs-editor-colorpicker-green = - .title = أخضر -pdfjs-editor-colorpicker-blue = - .title = أزرق -pdfjs-editor-colorpicker-pink = - .title = وردي -pdfjs-editor-colorpicker-red = - .title = أحمر - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = أظهِر الكل -pdfjs-editor-highlight-show-all-button = - .title = أظهِر الكل diff --git a/static/pdf.js/locale/ar/viewer.properties b/static/pdf.js/locale/ar/viewer.properties new file mode 100644 index 00000000..3dd50c88 --- /dev/null +++ b/static/pdf.js/locale/ar/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=الصفحة السابقة +previous_label=السابقة +next.title=الصفحة التالية +next_label=التالية + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=صفحة: +page_of=من {{pageCount}} + +zoom_out.title=بعّد +zoom_out_label=بعّد +zoom_in.title=قرّب +zoom_in_label=قرّب +zoom.title=التقريب +presentation_mode.title=انتقل لوضع العرض التقديمي +presentation_mode_label=وضع العرض التقديمي +open_file.title=افتح ملفًا +open_file_label=افتح +print.title=اطبع +print_label=اطبع +download.title=نزّل +download_label=نزّل +bookmark.title=المنظور الحالي (انسخ أو افتح في نافذة جديدة) +bookmark_label=المنظور الحالي + +# Secondary toolbar and context menu +tools.title=الأدوات +tools_label=الأدوات +first_page.title=اذهب إلى الصفحة الأولى +first_page.label=اذهب إلى الصفحة الأولى +first_page_label=اذهب إلى الصفحة الأولى +last_page.title=اذهب إلى الصفحة الأخيرة +last_page.label=اذهب إلى الصفحة الأخيرة +last_page_label=اذهب إلى الصفحة الأخيرة +page_rotate_cw.title=أدر باتجاه عقارب الساعة +page_rotate_cw.label=أدر باتجاه عقارب الساعة +page_rotate_cw_label=أدر باتجاه عقارب الساعة +page_rotate_ccw.title=أدر بعكس اتجاه عقارب الساعة +page_rotate_ccw.label=أدر بعكس اتجاه عقارب الساعة +page_rotate_ccw_label=أدر بعكس اتجاه عقارب الساعة + +hand_tool_enable.title=فعّل أداة اليد +hand_tool_enable_label=فعّل أداة اليد +hand_tool_disable.title=عطّل أداة اليد +hand_tool_disable_label=عطّل أداة اليد + +# Document properties dialog box +document_properties.title=خصائص المستند… +document_properties_label=خصائص المستند… +document_properties_file_name=اسم الملف: +document_properties_file_size=حجم الملف: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} ك.بايت ({{size_b}} بايت) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} م.بايت ({{size_b}} بايت) +document_properties_title=العنوان: +document_properties_author=المؤلف: +document_properties_subject=الموضوع: +document_properties_keywords=الكلمات الأساسية: +document_properties_creation_date=تاريخ الإنشاء: +document_properties_modification_date=تاريخ التعديل: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}، {{time}} +document_properties_creator=المنشئ: +document_properties_producer=منتج PDF: +document_properties_version=إصدارة PDF: +document_properties_page_count=عدد الصفحات: +document_properties_close=أغلق + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=بدّل الشريط الجانبي +toggle_sidebar_label=بدّل الشريط الجانبي +outline.title=اعرض مخطط المستند +outline_label=مخطط المستند +attachments.title=اعرض المرفقات +attachments_label=المُرفقات +thumbs.title=اعرض مُصغرات +thumbs_label=مُصغّرات +findbar.title=ابحث في المستند +findbar_label=ابحث + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=صفحة {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=مصغّرة صفحة {{page}} + +# Find panel button title and messages +find_label=ابحث: +find_previous.title=ابحث عن التّواجد السّابق للعبارة +find_previous_label=السابق +find_next.title=ابحث عن التّواجد التّالي للعبارة +find_next_label=التالي +find_highlight=أبرِز الكل +find_match_case_label=طابق حالة الأحرف +find_reached_top=تابعت من الأسفل بعدما وصلت إلى بداية المستند +find_reached_bottom=تابعت من الأعلى بعدما وصلت إلى نهاية المستند +find_not_found=لا وجود للعبارة + +# Error panel labels +error_more_info=معلومات أكثر +error_less_info=معلومات أقل +error_close=أغلق +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=‏PDF.js ن{{version}} ‏(بناء: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=الرسالة: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=الرصّة: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=الملف: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=السطر: {{line}} +rendering_error=حدث خطأ أثناء عرض الصفحة. + +# Predefined zoom values +page_scale_width=عرض الصفحة +page_scale_fit=ملائمة الصفحة +page_scale_auto=تقريب تلقائي +page_scale_actual=الحجم الحقيقي +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}٪ + +# Loading indicator messages +loading_error_indicator=عطل +loading_error=حدث عطل أثناء تحميل ملف PDF. +invalid_file_error=ملف PDF تالف أو غير صحيح. +missing_file_error=ملف PDF غير موجود. +unexpected_response_error=استجابة خادوم غير متوقعة. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[تعليق {{type}}] +password_label=أدخل لكلمة السر لفتح هذا الملف. +password_invalid=كلمة سر خطأ. من فضلك أعد المحاولة. +password_ok=حسنا +password_cancel=ألغِ + +printing_not_supported=تحذير: لا يدعم هذا المتصفح الطباعة بشكل كامل. +printing_not_ready=تحذير: ملف PDF لم يُحمّل كاملًا للطباعة. +web_fonts_disabled=خطوط الوب مُعطّلة: تعذّر استخدام خطوط PDF المُضمّنة. +document_colors_not_allowed=ليس مسموحًا لملفات PDF باستخدام ألوانها الخاصة: خيار 'اسمح للصفحات باختيار ألوانها الخاصة' ليس مُفعّلًا في المتصفح. diff --git a/static/pdf.js/locale/as/viewer.properties b/static/pdf.js/locale/as/viewer.properties new file mode 100644 index 00000000..58ccd84e --- /dev/null +++ b/static/pdf.js/locale/as/viewer.properties @@ -0,0 +1,172 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=পূৰ্বৱৰ্তী পৃষ্ঠা +previous_label=পূৰ্বৱৰ্তী +next.title=পৰৱৰ্তী পৃষ্ঠা +next_label=পৰৱৰ্তী + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=পৃষ্ঠা: +page_of=ৰ {{pageCount}} + +zoom_out.title=জুম আউট +zoom_out_label=জুম আউট +zoom_in.title=জুম ইন +zoom_in_label=জুম ইন +zoom.title=জুম কৰক +presentation_mode.title=উপস্থাপন অৱস্থালে যাওক +presentation_mode_label=উপস্থাপন অৱস্থা +open_file.title=ফাইল খোলক +open_file_label=খোলক +print.title=প্ৰিন্ট কৰক +print_label=প্ৰিন্ট কৰক +download.title=ডাউনল'ড কৰক +download_label=ডাউনল'ড কৰক +bookmark.title=বৰ্তমান দৃশ্য (কপি কৰক অথবা নতুন উইন্ডোত খোলক) +bookmark_label=বৰ্তমান দৃশ্য + +# Secondary toolbar and context menu +tools.title=সঁজুলিসমূহ +tools_label=সঁজুলিসমূহ +first_page.title=প্ৰথম পৃষ্ঠাত যাওক +first_page.label=প্ৰথম পৃষ্ঠাত যাওক +first_page_label=প্ৰথম পৃষ্ঠাত যাওক +last_page.title=সৰ্বশেষ পৃষ্ঠাত যাওক +last_page.label=সৰ্বশেষ পৃষ্ঠাত যাওক +last_page_label=সৰ্বশেষ পৃষ্ঠাত যাওক +page_rotate_cw.title=ঘড়ীৰ দিশত ঘুৰাওক +page_rotate_cw.label=ঘড়ীৰ দিশত ঘুৰাওক +page_rotate_cw_label=ঘড়ীৰ দিশত ঘুৰাওক +page_rotate_ccw.title=ঘড়ীৰ ওলোটা দিশত ঘুৰাওক +page_rotate_ccw.label=ঘড়ীৰ ওলোটা দিশত ঘুৰাওক +page_rotate_ccw_label=ঘড়ীৰ ওলোটা দিশত ঘুৰাওক + +hand_tool_enable.title=হাঁত সঁজুলি সামৰ্থবান কৰক +hand_tool_enable_label=হাঁত সঁজুলি সামৰ্থবান কৰক +hand_tool_disable.title=হাঁত সঁজুলি অসামৰ্থবান কৰক +hand_tool_disable_label=হাঁত সঁজুলি অসামৰ্থবান কৰক + +# Document properties dialog box +document_properties.title=দস্তাবেজৰ বৈশিষ্ট্যসমূহ… +document_properties_label=দস্তাবেজৰ বৈশিষ্ট্যসমূহ… +document_properties_file_name=ফাইল নাম: +document_properties_file_size=ফাইলৰ আকাৰ: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=শীৰ্ষক: +document_properties_author=লেখক: +document_properties_subject=বিষয়: +document_properties_keywords=কিৱাৰ্ডসমূহ: +document_properties_creation_date=সৃষ্টিৰ তাৰিখ: +document_properties_modification_date=পৰিবৰ্তনৰ তাৰিখ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=সৃষ্টিকৰ্তা: +document_properties_producer=PDF উৎপাদক: +document_properties_version=PDF সংস্কৰণ: +document_properties_page_count=পৃষ্ঠাৰ গণনা: +document_properties_close=বন্ধ কৰক + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=কাষবাৰ টগল কৰক +toggle_sidebar_label=কাষবাৰ টগল কৰক +outline.title=দস্তাবেজ আউটলাইন দেখুৱাওক +outline_label=দস্তাবেজ আউটলাইন +attachments.title=এটাচমেন্টসমূহ দেখুৱাওক +attachments_label=এটাচমেন্টসমূহ +thumbs.title=থাম্বনেইলসমূহ দেখুৱাওক +thumbs_label=থাম্বনেইলসমূহ +findbar.title=দস্তাবেজত সন্ধান কৰক +findbar_label=সন্ধান কৰক + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=পৃষ্ঠা {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=পৃষ্ঠাৰ থাম্বনেইল {{page}} + +# Find panel button title and messages +find_label=সন্ধান কৰক: +find_previous.title=বাক্যাংশৰ পূৰ্বৱৰ্তী উপস্থিতি সন্ধান কৰক +find_previous_label=পূৰ্বৱৰ্তী +find_next.title=বাক্যাংশৰ পৰৱৰ্তী উপস্থিতি সন্ধান কৰক +find_next_label=পৰৱৰ্তী +find_highlight=সকলো উজ্জ্বল কৰক +find_match_case_label=ফলা মিলাওক +find_reached_top=তলৰ পৰা আৰম্ভ কৰি, দস্তাবেজৰ ওপৰলৈ অহা হৈছে +find_reached_bottom=ওপৰৰ পৰা আৰম্ভ কৰি, দস্তাবেজৰ তললৈ অহা হৈছে +find_not_found=বাক্যাংশ পোৱা নগল + +# Error panel labels +error_more_info=অধিক তথ্য +error_less_info=কম তথ্য +error_close=বন্ধ কৰক +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=বাৰ্তা: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=স্টেক: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ফাইল: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=শাৰী: {{line}} +rendering_error=এই পৃষ্ঠা ৰেণ্ডাৰ কৰোতে এটা ত্ৰুটি দেখা দিলে। + +# Predefined zoom values +page_scale_width=পৃষ্ঠাৰ প্ৰস্থ +page_scale_fit=পৃষ্ঠা খাপ +page_scale_auto=স্বচালিত জুম +page_scale_actual=প্ৰকৃত আকাৰ +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=ত্ৰুটি +loading_error=PDF ল'ড কৰোতে এটা ত্ৰুটি দেখা দিলে। +invalid_file_error=অবৈধ অথবা ক্ষতিগ্ৰস্থ PDF file। +missing_file_error=সন্ধানহিন PDF ফাইল। +unexpected_response_error=অপ্ৰত্যাশিত চাৰ্ভাৰ প্ৰতিক্ৰিয়া। + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} টোকা] +password_label=এই PDF ফাইল খোলিবলৈ পাছৱৰ্ড সুমুৱাওক। +password_invalid=অবৈধ পাছৱৰ্ড। অনুগ্ৰহ কৰি পুনৰ চেষ্টা কৰক। +password_ok=ঠিক আছে +password_cancel=বাতিল কৰক + +printing_not_supported=সতৰ্কবাৰ্তা: প্ৰিন্টিং এই ব্ৰাউছাৰ দ্বাৰা সম্পূৰ্ণভাৱে সমৰ্থিত নহয়। +printing_not_ready=সতৰ্কবাৰ্তা: PDF প্ৰিন্টিংৰ বাবে সম্পূৰ্ণভাৱে ল'ডেড নহয়। +web_fonts_disabled=ৱেব ফন্টসমূহ অসামৰ্থবান কৰা আছে: অন্তৰ্ভুক্ত PDF ফন্টসমূহ ব্যৱহাৰ কৰিবলে অক্ষম। +document_colors_not_allowed=PDF দস্তাবেজসমূহৰ সিহতৰ নিজস্ব ৰঙ ব্যৱহাৰ কৰাৰ অনুমতি নাই: ব্ৰাউছাৰত 'পৃষ্ঠাসমূহক সিহতৰ নিজস্ব ৰঙ নিৰ্বাচন কৰাৰ অনুমতি দিয়ক' অসামৰ্থবান কৰা আছে। diff --git a/static/pdf.js/locale/ast/viewer.ftl b/static/pdf.js/locale/ast/viewer.ftl deleted file mode 100644 index 2503cafc..00000000 --- a/static/pdf.js/locale/ast/viewer.ftl +++ /dev/null @@ -1,201 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Páxina anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Páxina siguiente -pdfjs-next-button-label = Siguiente -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Páxina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Alloñar -pdfjs-zoom-out-button-label = Alloña -pdfjs-zoom-in-button = - .title = Averar -pdfjs-zoom-in-button-label = Avera -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Cambiar al mou de presentación -pdfjs-presentation-mode-button-label = Mou de presentación -pdfjs-open-file-button-label = Abrir -pdfjs-print-button = - .title = Imprentar -pdfjs-print-button-label = Imprentar - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Ferramientes -pdfjs-tools-button-label = Ferramientes -pdfjs-first-page-button-label = Dir a la primer páxina -pdfjs-last-page-button-label = Dir a la última páxina -pdfjs-page-rotate-cw-button = - .title = Voltia a la derecha -pdfjs-page-rotate-cw-button-label = Voltiar a la derecha -pdfjs-page-rotate-ccw-button = - .title = Voltia a la esquierda -pdfjs-page-rotate-ccw-button-label = Voltiar a la esquierda -pdfjs-cursor-text-select-tool-button = - .title = Activa la ferramienta d'esbilla de testu -pdfjs-cursor-text-select-tool-button-label = Ferramienta d'esbilla de testu -pdfjs-cursor-hand-tool-button = - .title = Activa la ferramienta de mano -pdfjs-cursor-hand-tool-button-label = Ferramienta de mano -pdfjs-scroll-vertical-button = - .title = Usa'l desplazamientu vertical -pdfjs-scroll-vertical-button-label = Desplazamientu vertical -pdfjs-scroll-horizontal-button = - .title = Usa'l desplazamientu horizontal -pdfjs-scroll-horizontal-button-label = Desplazamientu horizontal -pdfjs-scroll-wrapped-button = - .title = Usa'l desplazamientu continuu -pdfjs-scroll-wrapped-button-label = Desplazamientu continuu -pdfjs-spread-none-button-label = Fueyes individuales -pdfjs-spread-odd-button-label = Fueyes pares -pdfjs-spread-even-button-label = Fueyes impares - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propiedaes del documentu… -pdfjs-document-properties-button-label = Propiedaes del documentu… -pdfjs-document-properties-file-name = Nome del ficheru: -pdfjs-document-properties-file-size = Tamañu del ficheru: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Títulu: -pdfjs-document-properties-keywords = Pallabres clave: -pdfjs-document-properties-creation-date = Data de creación: -pdfjs-document-properties-modification-date = Data de modificación: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-producer = Productor del PDF: -pdfjs-document-properties-version = Versión del PDF: -pdfjs-document-properties-page-count = Númberu de páxines: -pdfjs-document-properties-page-size = Tamañu de páxina: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = horizontal -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista web rápida: -pdfjs-document-properties-linearized-yes = Sí -pdfjs-document-properties-linearized-no = Non -pdfjs-document-properties-close-button = Zarrar - -## Print - -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Encaboxar - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Alternar la barra llateral -pdfjs-attachments-button = - .title = Amosar los axuntos -pdfjs-attachments-button-label = Axuntos -pdfjs-layers-button-label = Capes -pdfjs-thumbs-button = - .title = Amosar les miniatures -pdfjs-thumbs-button-label = Miniatures -pdfjs-findbar-button-label = Atopar -pdfjs-additional-layers = Capes adicionales - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Páxina { $page } - -## Find panel button title and messages - -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button-label = Siguiente -pdfjs-find-entire-word-checkbox-label = Pallabres completes -pdfjs-find-reached-top = Algamóse'l comienzu de la páxina, síguese dende abaxo -pdfjs-find-reached-bottom = Algamóse la fin del documentu, síguese dende arriba - -## Predefined zoom values - -pdfjs-page-scale-auto = Zoom automáticu -pdfjs-page-scale-actual = Tamañu real -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Páxina { $page } - -## Loading indicator messages - -pdfjs-loading-error = Asocedió un fallu mentanto se cargaba'l PDF. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } - -## Password - -pdfjs-password-ok-button = Aceptar -pdfjs-password-cancel-button = Encaboxar - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ast/viewer.properties b/static/pdf.js/locale/ast/viewer.properties new file mode 100644 index 00000000..2346c54b --- /dev/null +++ b/static/pdf.js/locale/ast/viewer.properties @@ -0,0 +1,111 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +previous.title = Páxina anterior +previous_label = Anterior +next.title = Páxina siguiente +next_label = Siguiente +page_label = Páxina: +page_of = de {{pageCount}} +zoom_out.title = Reducir +zoom_out_label = Reducir +zoom_in.title = Aumentar +zoom_in_label = Aumentar +zoom.title = Tamañu +print.title = Imprentar +print_label = Imprentar +open_file.title = Abrir ficheru +open_file_label = Abrir +download.title = Descargar +download_label = Descargar +bookmark.title = Vista actual (copiar o abrir nuna nueva ventana) +bookmark_label = Vista actual +outline.title = Amosar l'esquema del documentu +outline_label = Esquema del documentu +thumbs.title = Amosar miniatures +thumbs_label = Miniatures +thumb_page_title = Páxina {{page}} +thumb_page_canvas = Miniatura de la páxina {{page}} +error_more_info = Más información +error_less_info = Menos información +error_close = Zarrar +error_message = Mensaxe: {{message}} +error_stack = Pila: {{stack}} +error_file = Ficheru: {{file}} +error_line = Llinia: {{line}} +rendering_error = Hebo un fallu al renderizar la páxina. +page_scale_width = Anchor de la páxina +page_scale_fit = Axuste de la páxina +page_scale_auto = Tamañu automáticu +page_scale_actual = Tamañu actual +loading_error_indicator = Fallu +loading_error = Hebo un fallu al cargar el PDF. +printing_not_supported = Avisu: Imprentar nun tien sofitu téunicu completu nesti navegador. +presentation_mode_label = +presentation_mode.title = +page_rotate_cw.label = +page_rotate_ccw.label = +last_page.label = Dir a la cabera páxina +invalid_file_error = Ficheru PDF inválidu o corruptu. +first_page.label = Dir a la primer páxina +findbar_label = Guetar +findbar.title = Guetar nel documentu +find_previous_label = Anterior +find_previous.title = Alcontrar l'anterior apaición de la fras +find_not_found = Frase non atopada +find_next_label = Siguiente +find_next.title = Alcontrar la siguiente apaición d'esta fras +find_match_case_label = Coincidencia de mayús./minús. +find_label = Guetar: +find_highlight = Remarcar toos +find_reached_top=Algamóse'l principiu del documentu, siguir dende'l final +find_reached_bottom=Algamóse'l final del documentu, siguir dende'l principiu +web_fonts_disabled = Les fontes web tán desactivaes: ye imposible usar les fontes PDF embebíes. +toggle_sidebar_label = Camudar barra llateral +toggle_sidebar.title = Camudar barra llateral +missing_file_error = Nun hai ficheru PDF. +error_version_info = PDF.js v{{version}} (build: {{build}}) +printing_not_ready = Avisu: Esti PDF nun se cargó completamente pa poder imprentase. +text_annotation_type.alt = [Anotación {{type}}] +document_colors_disabled = Los documentos PDF nun tienen permitío usar los sos propios colores: 'Permitir a les páxines elexir los sos propios colores' ta desactivao nel navegador. +tools_label = Ferramientes +tools.title = Ferramientes +password_ok = Aceutar +password_label = Introduz la contraseña p'abrir esti ficheru PDF +password_invalid = Contraseña non válida. Vuelvi a intentalo. +password_cancel = Encaboxar +page_rotate_cw_label = Xirar en sen horariu +page_rotate_cw.title = Xirar en sen horariu +page_rotate_ccw_label = Xirar en sen antihorariu +page_rotate_ccw.title = Xirar en sen antihorariu +last_page_label = Dir a la postrer páxina +last_page.title = Dir a la postrer páxina +hand_tool_enable_label = Activar ferramienta mano +hand_tool_enable.title = Activar ferramienta mano +hand_tool_disable_label = Desactivar ferramienta mano +hand_tool_disable.title = Desactivar ferramienta mano +first_page_label = Dir a la primer páxina +first_page.title = Dir a la primer páxina +document_properties_version = Versión PDF: +document_properties_title = Títulu: +document_properties_subject = Asuntu: +document_properties_producer = Productor PDF: +document_properties_page_count = Númberu de páxines: +document_properties_modification_date = Data de modificación: +document_properties_mb = {{size_mb}} MB ({{size_b}} bytes) +document_properties_label = Propiedaes del documentu… +document_properties_keywords = Pallabres clave: +document_properties_kb = {{size_kb}} KB ({{size_b}} bytes) +document_properties_file_size = Tamañu de ficheru: +document_properties_file_name = Nome de ficheru: +document_properties_date_string = {{date}}, {{time}} +document_properties_creator = Creador: +document_properties_creation_date = Data de creación: +document_properties_close = Zarrar +document_properties_author = Autor: +document_properties.title = Propiedaes del documentu… +attachments_label = Axuntos +attachments.title = Amosar axuntos +unexpected_response_error = Rempuesta inesperada del sirvidor. +page_scale_percent = {{scale}}% diff --git a/static/pdf.js/locale/az/viewer.ftl b/static/pdf.js/locale/az/viewer.ftl deleted file mode 100644 index 773aae4d..00000000 --- a/static/pdf.js/locale/az/viewer.ftl +++ /dev/null @@ -1,257 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Əvvəlki səhifə -pdfjs-previous-button-label = Əvvəlkini tap -pdfjs-next-button = - .title = Növbəti səhifə -pdfjs-next-button-label = İrəli -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Səhifə -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = / { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } / { $pagesCount }) -pdfjs-zoom-out-button = - .title = Uzaqlaş -pdfjs-zoom-out-button-label = Uzaqlaş -pdfjs-zoom-in-button = - .title = Yaxınlaş -pdfjs-zoom-in-button-label = Yaxınlaş -pdfjs-zoom-select = - .title = Yaxınlaşdırma -pdfjs-presentation-mode-button = - .title = Təqdimat Rejiminə Keç -pdfjs-presentation-mode-button-label = Təqdimat Rejimi -pdfjs-open-file-button = - .title = Fayl Aç -pdfjs-open-file-button-label = Aç -pdfjs-print-button = - .title = Yazdır -pdfjs-print-button-label = Yazdır - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Alətlər -pdfjs-tools-button-label = Alətlər -pdfjs-first-page-button = - .title = İlk Səhifəyə get -pdfjs-first-page-button-label = İlk Səhifəyə get -pdfjs-last-page-button = - .title = Son Səhifəyə get -pdfjs-last-page-button-label = Son Səhifəyə get -pdfjs-page-rotate-cw-button = - .title = Saat İstiqamətində Fırlat -pdfjs-page-rotate-cw-button-label = Saat İstiqamətində Fırlat -pdfjs-page-rotate-ccw-button = - .title = Saat İstiqamətinin Əksinə Fırlat -pdfjs-page-rotate-ccw-button-label = Saat İstiqamətinin Əksinə Fırlat -pdfjs-cursor-text-select-tool-button = - .title = Yazı seçmə alətini aktivləşdir -pdfjs-cursor-text-select-tool-button-label = Yazı seçmə aləti -pdfjs-cursor-hand-tool-button = - .title = Əl alətini aktivləşdir -pdfjs-cursor-hand-tool-button-label = Əl aləti -pdfjs-scroll-vertical-button = - .title = Şaquli sürüşdürmə işlət -pdfjs-scroll-vertical-button-label = Şaquli sürüşdürmə -pdfjs-scroll-horizontal-button = - .title = Üfüqi sürüşdürmə işlət -pdfjs-scroll-horizontal-button-label = Üfüqi sürüşdürmə -pdfjs-scroll-wrapped-button = - .title = Bükülü sürüşdürmə işlət -pdfjs-scroll-wrapped-button-label = Bükülü sürüşdürmə -pdfjs-spread-none-button = - .title = Yan-yana birləşdirilmiş səhifələri işlətmə -pdfjs-spread-none-button-label = Birləşdirmə -pdfjs-spread-odd-button = - .title = Yan-yana birləşdirilmiş səhifələri tək nömrəli səhifələrdən başlat -pdfjs-spread-odd-button-label = Tək nömrəli -pdfjs-spread-even-button = - .title = Yan-yana birləşdirilmiş səhifələri cüt nömrəli səhifələrdən başlat -pdfjs-spread-even-button-label = Cüt nömrəli - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Sənəd xüsusiyyətləri… -pdfjs-document-properties-button-label = Sənəd xüsusiyyətləri… -pdfjs-document-properties-file-name = Fayl adı: -pdfjs-document-properties-file-size = Fayl ölçüsü: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bayt) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bayt) -pdfjs-document-properties-title = Başlık: -pdfjs-document-properties-author = Müəllif: -pdfjs-document-properties-subject = Mövzu: -pdfjs-document-properties-keywords = Açar sözlər: -pdfjs-document-properties-creation-date = Yaradılış Tarixi : -pdfjs-document-properties-modification-date = Dəyişdirilmə Tarixi : -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Yaradan: -pdfjs-document-properties-producer = PDF yaradıcısı: -pdfjs-document-properties-version = PDF versiyası: -pdfjs-document-properties-page-count = Səhifə sayı: -pdfjs-document-properties-page-size = Səhifə Ölçüsü: -pdfjs-document-properties-page-size-unit-inches = inç -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portret -pdfjs-document-properties-page-size-orientation-landscape = albom -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Məktub -pdfjs-document-properties-page-size-name-legal = Hüquqi - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Bəli -pdfjs-document-properties-linearized-no = Xeyr -pdfjs-document-properties-close-button = Qapat - -## Print - -pdfjs-print-progress-message = Sənəd çap üçün hazırlanır… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Ləğv et -pdfjs-printing-not-supported = Xəbərdarlıq: Çap bu səyyah tərəfindən tam olaraq dəstəklənmir. -pdfjs-printing-not-ready = Xəbərdarlıq: PDF çap üçün tam yüklənməyib. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Yan Paneli Aç/Bağla -pdfjs-toggle-sidebar-notification-button = - .title = Yan paneli çevir (sənəddə icmal/bağlamalar/laylar mövcuddur) -pdfjs-toggle-sidebar-button-label = Yan Paneli Aç/Bağla -pdfjs-document-outline-button = - .title = Sənədin eskizini göstər (bütün bəndləri açmaq/yığmaq üçün iki dəfə klikləyin) -pdfjs-document-outline-button-label = Sənəd strukturu -pdfjs-attachments-button = - .title = Bağlamaları göstər -pdfjs-attachments-button-label = Bağlamalar -pdfjs-layers-button = - .title = Layları göstər (bütün layları ilkin halına sıfırlamaq üçün iki dəfə klikləyin) -pdfjs-layers-button-label = Laylar -pdfjs-thumbs-button = - .title = Kiçik şəkilləri göstər -pdfjs-thumbs-button-label = Kiçik şəkillər -pdfjs-findbar-button = - .title = Sənəddə Tap -pdfjs-findbar-button-label = Tap -pdfjs-additional-layers = Əlavə laylar - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Səhifə{ $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } səhifəsinin kiçik vəziyyəti - -## Find panel button title and messages - -pdfjs-find-input = - .title = Tap - .placeholder = Sənəddə tap… -pdfjs-find-previous-button = - .title = Bir öncəki uyğun gələn sözü tapır -pdfjs-find-previous-button-label = Geri -pdfjs-find-next-button = - .title = Bir sonrakı uyğun gələn sözü tapır -pdfjs-find-next-button-label = İrəli -pdfjs-find-highlight-checkbox = İşarələ -pdfjs-find-match-case-checkbox-label = Böyük/kiçik hərfə həssaslıq -pdfjs-find-entire-word-checkbox-label = Tam sözlər -pdfjs-find-reached-top = Sənədin yuxarısına çatdı, aşağıdan davam edir -pdfjs-find-reached-bottom = Sənədin sonuna çatdı, yuxarıdan davam edir -pdfjs-find-not-found = Uyğunlaşma tapılmadı - -## Predefined zoom values - -pdfjs-page-scale-width = Səhifə genişliyi -pdfjs-page-scale-fit = Səhifəni sığdır -pdfjs-page-scale-auto = Avtomatik yaxınlaşdır -pdfjs-page-scale-actual = Hazırkı Həcm -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF yüklenərkən bir səhv yarandı. -pdfjs-invalid-file-error = Səhv və ya zədələnmiş olmuş PDF fayl. -pdfjs-missing-file-error = PDF fayl yoxdur. -pdfjs-unexpected-response-error = Gözlənilməz server cavabı. -pdfjs-rendering-error = Səhifə göstərilərkən səhv yarandı. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotasiyası] - -## Password - -pdfjs-password-label = Bu PDF faylı açmaq üçün parolu daxil edin. -pdfjs-password-invalid = Parol səhvdir. Bir daha yoxlayın. -pdfjs-password-ok-button = Tamam -pdfjs-password-cancel-button = Ləğv et -pdfjs-web-fonts-disabled = Web Şriftlər söndürülüb: yerləşdirilmiş PDF şriftlərini istifadə etmək mümkün deyil. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/az/viewer.properties b/static/pdf.js/locale/az/viewer.properties new file mode 100644 index 00000000..7aa41980 --- /dev/null +++ b/static/pdf.js/locale/az/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Əvvəlki səhifə +previous_label=Əvvəlkini tap +next.title=Növbəti səhifə +next_label=İrəli + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Səhifə: +page_of=/ {{pageCount}} + +zoom_out.title=Uzaqlaş +zoom_out_label=Uzaqlaş +zoom_in.title=Yaxınlaş +zoom_in_label=Yaxınlaş +zoom.title=Yaxınlaşdırma +presentation_mode.title=Təqdimat Rejiminə Keç +presentation_mode_label=Təqdimat Rejimi +open_file.title=Fayl Aç +open_file_label=Aç +print.title=Yazdır +print_label=Yazdır +download.title=Yüklə +download_label=Yüklə +bookmark.title=Hazırkı görünüş (köçür və ya yeni pəncərədə aç) +bookmark_label=Hazırki görünüş + +# Secondary toolbar and context menu +tools.title=Alətlər +tools_label=Alətlər +first_page.title=İlk Səhifəyə get +first_page.label=İlk Səhifəyə get +first_page_label=İlk Səhifəyə get +last_page.title=Son Səhifəyə get +last_page.label=Son Səhifəyə get +last_page_label=Son Səhifəyə get +page_rotate_cw.title=Saat İstiqamətində Fırlat +page_rotate_cw.label=Saat İstiqamətində Fırlat +page_rotate_cw_label=Saat İstiqamətində Fırlat +page_rotate_ccw.title=Saat İstiqamətinin Əksinə Fırlat +page_rotate_ccw.label=Saat İstiqamətinin Əksinə Fırlat +page_rotate_ccw_label=Saat İstiqamətinin Əksinə Fırlat + +hand_tool_enable.title=Əl alətini aktiv et +hand_tool_enable_label=Əl alətini aktiv et +hand_tool_disable.title=Əl alətini deaktiv et +hand_tool_disable_label=Əl alətini deaktiv et + +# Document properties dialog box +document_properties.title=Sənəd xüsusiyyətləri… +document_properties_label=Sənəd xüsusiyyətləri… +document_properties_file_name=Fayl adı: +document_properties_file_size=Fayl ölçüsü: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bayt) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bayt) +document_properties_title=Başlık: +document_properties_author=Müəllif: +document_properties_subject=Mövzu: +document_properties_keywords=Açar sözlər: +document_properties_creation_date=Yaradılış Tarixi : +document_properties_modification_date=Dəyişdirilmə Tarixi : +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Yaradan: +document_properties_producer=PDF yaradıcısı: +document_properties_version=PDF versiyası: +document_properties_page_count=Səhifə sayı: +document_properties_close=Qapat + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Yan Paneli Aç/Bağla +toggle_sidebar_label=Yan Paneli Aç/Bağla +outline.title=Sənəd struktunu göstər +outline_label=Sənəd strukturu +attachments.title=Bağlamaları göstər +attachments_label=Bağlamalar +thumbs.title=Kiçik şəkilləri göstər +thumbs_label=Kiçik şəkillər +findbar.title=Sənəddə Tap +findbar_label=Tap + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Səhifə{{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}} səhifəsinin kiçik vəziyyəti + +# Find panel button title and messages +find_label=Tap: +find_previous.title=Bir öncəki uyğun gələn sözü tapır +find_previous_label=Geri +find_next.title=Bir sonrakı uyğun gələn sözü tapır +find_next_label=İrəli +find_highlight=İşarələ +find_match_case_label=Böyük/kiçik hərfə həssaslıq +find_reached_top=Sənədin yuxarısına çatdı, aşağıdan davam edir +find_reached_bottom=Sənədin sonuna çatdı, yuxarıdan davam edir +find_not_found=Uyğunlaşma tapılmadı + +# Error panel labels +error_more_info=Daha çox məlumati +error_less_info=Daha az məlumat +error_close=Qapat +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (yığma: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=İsmarıc: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stek: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fayl: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Sətir: {{line}} +rendering_error=Səhifə göstərilərkən səhv yarandı. + +# Predefined zoom values +page_scale_width=Səhifə genişliyi +page_scale_fit=Səhifəni sığdır +page_scale_auto=Avtomatik yaxınlaşdır +page_scale_actual=Hazırki Həcm +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Səhv +loading_error=PDF yüklenərkən bir səhv yarandı. +invalid_file_error=Səhv və ya zədələnmiş olmuş PDF fayl. +missing_file_error=PDF fayl yoxdur. +unexpected_response_error=Gözlənilməz server cavabı. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotasiyası] +password_label=Bu PDF faylı açmaq üçün şifrəni daxil edin. +password_invalid=Şifrə yanlışdır. Bir daha sınayın. +password_ok=Tamam +password_cancel=Ləğv et + +printing_not_supported=Xəbərdarlıq: Çap bu səyyah tərəfindən tam olaraq dəstəklənmir. +printing_not_ready=Xəbərdarlıq: PDF çap üçün tam yüklənməyib. +web_fonts_disabled=Web Şriftlər söndürülüb: yerləşdirilmiş PDF şriftlərini istifadə etmək mümkün deyil. +document_colors_not_allowed=PDF sənədlərə öz rənglərini işlətməyə icazə verilmir: 'Səhifələrə öz rənglərini istifadə etməyə icazə vermə' səyyahda söndürülüb. diff --git a/static/pdf.js/locale/be/viewer.ftl b/static/pdf.js/locale/be/viewer.ftl deleted file mode 100644 index ee1f4301..00000000 --- a/static/pdf.js/locale/be/viewer.ftl +++ /dev/null @@ -1,404 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Папярэдняя старонка -pdfjs-previous-button-label = Папярэдняя -pdfjs-next-button = - .title = Наступная старонка -pdfjs-next-button-label = Наступная -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Старонка -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = з { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } з { $pagesCount }) -pdfjs-zoom-out-button = - .title = Паменшыць -pdfjs-zoom-out-button-label = Паменшыць -pdfjs-zoom-in-button = - .title = Павялічыць -pdfjs-zoom-in-button-label = Павялічыць -pdfjs-zoom-select = - .title = Павялічэнне тэксту -pdfjs-presentation-mode-button = - .title = Пераключыцца ў рэжым паказу -pdfjs-presentation-mode-button-label = Рэжым паказу -pdfjs-open-file-button = - .title = Адкрыць файл -pdfjs-open-file-button-label = Адкрыць -pdfjs-print-button = - .title = Друкаваць -pdfjs-print-button-label = Друкаваць -pdfjs-save-button = - .title = Захаваць -pdfjs-save-button-label = Захаваць -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Сцягнуць -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Сцягнуць -pdfjs-bookmark-button = - .title = Дзейная старонка (паглядзець URL-адрас з дзейнай старонкі) -pdfjs-bookmark-button-label = Цяперашняя старонка -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Адкрыць у праграме -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Адкрыць у праграме - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Прылады -pdfjs-tools-button-label = Прылады -pdfjs-first-page-button = - .title = Перайсці на першую старонку -pdfjs-first-page-button-label = Перайсці на першую старонку -pdfjs-last-page-button = - .title = Перайсці на апошнюю старонку -pdfjs-last-page-button-label = Перайсці на апошнюю старонку -pdfjs-page-rotate-cw-button = - .title = Павярнуць па сонцу -pdfjs-page-rotate-cw-button-label = Павярнуць па сонцу -pdfjs-page-rotate-ccw-button = - .title = Павярнуць супраць сонца -pdfjs-page-rotate-ccw-button-label = Павярнуць супраць сонца -pdfjs-cursor-text-select-tool-button = - .title = Уключыць прыладу выбару тэксту -pdfjs-cursor-text-select-tool-button-label = Прылада выбару тэксту -pdfjs-cursor-hand-tool-button = - .title = Уключыць ручную прыладу -pdfjs-cursor-hand-tool-button-label = Ручная прылада -pdfjs-scroll-page-button = - .title = Выкарыстоўваць пракрутку старонкi -pdfjs-scroll-page-button-label = Пракрутка старонкi -pdfjs-scroll-vertical-button = - .title = Ужываць вертыкальную пракрутку -pdfjs-scroll-vertical-button-label = Вертыкальная пракрутка -pdfjs-scroll-horizontal-button = - .title = Ужываць гарызантальную пракрутку -pdfjs-scroll-horizontal-button-label = Гарызантальная пракрутка -pdfjs-scroll-wrapped-button = - .title = Ужываць маштабавальную пракрутку -pdfjs-scroll-wrapped-button-label = Маштабавальная пракрутка -pdfjs-spread-none-button = - .title = Не выкарыстоўваць разгорнутыя старонкі -pdfjs-spread-none-button-label = Без разгорнутых старонак -pdfjs-spread-odd-button = - .title = Разгорнутыя старонкі пачынаючы з няцотных нумароў -pdfjs-spread-odd-button-label = Няцотныя старонкі злева -pdfjs-spread-even-button = - .title = Разгорнутыя старонкі пачынаючы з цотных нумароў -pdfjs-spread-even-button-label = Цотныя старонкі злева - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Уласцівасці дакумента… -pdfjs-document-properties-button-label = Уласцівасці дакумента… -pdfjs-document-properties-file-name = Назва файла: -pdfjs-document-properties-file-size = Памер файла: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } КБ ({ $size_b } байт) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } МБ ({ $size_b } байт) -pdfjs-document-properties-title = Загаловак: -pdfjs-document-properties-author = Аўтар: -pdfjs-document-properties-subject = Тэма: -pdfjs-document-properties-keywords = Ключавыя словы: -pdfjs-document-properties-creation-date = Дата стварэння: -pdfjs-document-properties-modification-date = Дата змянення: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Стваральнік: -pdfjs-document-properties-producer = Вырабнік PDF: -pdfjs-document-properties-version = Версія PDF: -pdfjs-document-properties-page-count = Колькасць старонак: -pdfjs-document-properties-page-size = Памер старонкі: -pdfjs-document-properties-page-size-unit-inches = цаляў -pdfjs-document-properties-page-size-unit-millimeters = мм -pdfjs-document-properties-page-size-orientation-portrait = кніжная -pdfjs-document-properties-page-size-orientation-landscape = альбомная -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Хуткі прагляд у Інтэрнэце: -pdfjs-document-properties-linearized-yes = Так -pdfjs-document-properties-linearized-no = Не -pdfjs-document-properties-close-button = Закрыць - -## Print - -pdfjs-print-progress-message = Падрыхтоўка дакумента да друку… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Скасаваць -pdfjs-printing-not-supported = Папярэджанне: друк не падтрымліваецца цалкам гэтым браўзерам. -pdfjs-printing-not-ready = Увага: PDF не сцягнуты цалкам для друкавання. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Паказаць/схаваць бакавую панэль -pdfjs-toggle-sidebar-notification-button = - .title = Паказаць/схаваць бакавую панэль (дакумент мае змест/укладанні/пласты) -pdfjs-toggle-sidebar-button-label = Паказаць/схаваць бакавую панэль -pdfjs-document-outline-button = - .title = Паказаць структуру дакумента (двайная пстрычка, каб разгарнуць /згарнуць усе элементы) -pdfjs-document-outline-button-label = Структура дакумента -pdfjs-attachments-button = - .title = Паказаць далучэнні -pdfjs-attachments-button-label = Далучэнні -pdfjs-layers-button = - .title = Паказаць пласты (націсніце двойчы, каб скінуць усе пласты да прадвызначанага стану) -pdfjs-layers-button-label = Пласты -pdfjs-thumbs-button = - .title = Паказ мініяцюр -pdfjs-thumbs-button-label = Мініяцюры -pdfjs-current-outline-item-button = - .title = Знайсці бягучы элемент структуры -pdfjs-current-outline-item-button-label = Бягучы элемент структуры -pdfjs-findbar-button = - .title = Пошук у дакуменце -pdfjs-findbar-button-label = Знайсці -pdfjs-additional-layers = Дадатковыя пласты - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Старонка { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Мініяцюра старонкі { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Шукаць - .placeholder = Шукаць у дакуменце… -pdfjs-find-previous-button = - .title = Знайсці папярэдні выпадак выразу -pdfjs-find-previous-button-label = Папярэдні -pdfjs-find-next-button = - .title = Знайсці наступны выпадак выразу -pdfjs-find-next-button-label = Наступны -pdfjs-find-highlight-checkbox = Падфарбаваць усе -pdfjs-find-match-case-checkbox-label = Адрозніваць вялікія/малыя літары -pdfjs-find-match-diacritics-checkbox-label = З улікам дыякрытык -pdfjs-find-entire-word-checkbox-label = Словы цалкам -pdfjs-find-reached-top = Дасягнуты пачатак дакумента, працяг з канца -pdfjs-find-reached-bottom = Дасягнуты канец дакумента, працяг з пачатку -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } з { $total } супадзенняў - [few] { $current } з { $total } супадзенняў - *[many] { $current } з { $total } супадзенняў - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Больш за { $limit } супадзенне - [few] Больш за { $limit } супадзенні - *[many] Больш за { $limit } супадзенняў - } -pdfjs-find-not-found = Выраз не знойдзены - -## Predefined zoom values - -pdfjs-page-scale-width = Шырыня старонкі -pdfjs-page-scale-fit = Уцісненне старонкі -pdfjs-page-scale-auto = Аўтаматычнае павелічэнне -pdfjs-page-scale-actual = Сапраўдны памер -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Старонка { $page } - -## Loading indicator messages - -pdfjs-loading-error = Здарылася памылка ў часе загрузкі PDF. -pdfjs-invalid-file-error = Няспраўны або пашкоджаны файл PDF. -pdfjs-missing-file-error = Адсутны файл PDF. -pdfjs-unexpected-response-error = Нечаканы адказ сервера. -pdfjs-rendering-error = Здарылася памылка падчас адлюстравання старонкі. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Увядзіце пароль, каб адкрыць гэты файл PDF. -pdfjs-password-invalid = Нядзейсны пароль. Паспрабуйце зноў. -pdfjs-password-ok-button = Добра -pdfjs-password-cancel-button = Скасаваць -pdfjs-web-fonts-disabled = Шрыфты Сеціва забаронены: немагчыма ўжываць укладзеныя шрыфты PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Тэкст -pdfjs-editor-free-text-button-label = Тэкст -pdfjs-editor-ink-button = - .title = Маляваць -pdfjs-editor-ink-button-label = Маляваць -pdfjs-editor-stamp-button = - .title = Дадаць або змяніць выявы -pdfjs-editor-stamp-button-label = Дадаць або змяніць выявы -pdfjs-editor-highlight-button = - .title = Вылучэнне -pdfjs-editor-highlight-button-label = Вылучэнне -pdfjs-highlight-floating-button = - .title = Вылучэнне -pdfjs-highlight-floating-button1 = - .title = Падфарбаваць - .aria-label = Падфарбаваць -pdfjs-highlight-floating-button-label = Падфарбаваць - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Выдаліць малюнак -pdfjs-editor-remove-freetext-button = - .title = Выдаліць тэкст -pdfjs-editor-remove-stamp-button = - .title = Выдаліць выяву -pdfjs-editor-remove-highlight-button = - .title = Выдаліць падфарбоўку - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Колер -pdfjs-editor-free-text-size-input = Памер -pdfjs-editor-ink-color-input = Колер -pdfjs-editor-ink-thickness-input = Таўшчыня -pdfjs-editor-ink-opacity-input = Непразрыстасць -pdfjs-editor-stamp-add-image-button = - .title = Дадаць выяву -pdfjs-editor-stamp-add-image-button-label = Дадаць выяву -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Таўшчыня -pdfjs-editor-free-highlight-thickness-title = - .title = Змяняць таўшчыню пры вылучэнні іншых элементаў, акрамя тэксту -pdfjs-free-text = - .aria-label = Тэкставы рэдактар -pdfjs-free-text-default-content = Пачніце набор тэксту… -pdfjs-ink = - .aria-label = Графічны рэдактар -pdfjs-ink-canvas = - .aria-label = Выява, створаная карыстальнікам - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Альтэрнатыўны тэкст -pdfjs-editor-alt-text-edit-button-label = Змяніць альтэрнатыўны тэкст -pdfjs-editor-alt-text-dialog-label = Выберыце варыянт -pdfjs-editor-alt-text-dialog-description = Альтэрнатыўны тэкст дапамагае, калі людзі не бачаць выяву або калі яна не загружаецца. -pdfjs-editor-alt-text-add-description-label = Дадаць апісанне -pdfjs-editor-alt-text-add-description-description = Старайцеся скласці 1-2 сказы, якія апісваюць прадмет, абстаноўку або дзеянні. -pdfjs-editor-alt-text-mark-decorative-label = Пазначыць як дэкаратыўны -pdfjs-editor-alt-text-mark-decorative-description = Выкарыстоўваецца для дэкаратыўных выяваў, такіх як рамкі або вадзяныя знакі. -pdfjs-editor-alt-text-cancel-button = Скасаваць -pdfjs-editor-alt-text-save-button = Захаваць -pdfjs-editor-alt-text-decorative-tooltip = Пазначаны як дэкаратыўны -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Напрыклад, «Малады чалавек садзіцца за стол есці» - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Верхні левы кут — змяніць памер -pdfjs-editor-resizer-label-top-middle = Уверсе пасярэдзіне — змяніць памер -pdfjs-editor-resizer-label-top-right = Верхні правы кут — змяніць памер -pdfjs-editor-resizer-label-middle-right = Пасярэдзіне справа — змяніць памер -pdfjs-editor-resizer-label-bottom-right = Правы ніжні кут — змяніць памер -pdfjs-editor-resizer-label-bottom-middle = Пасярэдзіне ўнізе — змяніць памер -pdfjs-editor-resizer-label-bottom-left = Левы ніжні кут — змяніць памер -pdfjs-editor-resizer-label-middle-left = Пасярэдзіне злева — змяніць памер - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Колер падфарбоўкі -pdfjs-editor-colorpicker-button = - .title = Змяніць колер -pdfjs-editor-colorpicker-dropdown = - .aria-label = Выбар колеру -pdfjs-editor-colorpicker-yellow = - .title = Жоўты -pdfjs-editor-colorpicker-green = - .title = Зялёны -pdfjs-editor-colorpicker-blue = - .title = Блакітны -pdfjs-editor-colorpicker-pink = - .title = Ружовы -pdfjs-editor-colorpicker-red = - .title = Чырвоны - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Паказаць усе -pdfjs-editor-highlight-show-all-button = - .title = Паказаць усе diff --git a/static/pdf.js/locale/be/viewer.properties b/static/pdf.js/locale/be/viewer.properties new file mode 100644 index 00000000..031b1df5 --- /dev/null +++ b/static/pdf.js/locale/be/viewer.properties @@ -0,0 +1,105 @@ +previous.title = Папярэдняя старонка +previous_label = Папярэдняя +next.title = Наступная старонка +next_label = Наступная +page_label = Старонка: +page_of = з {{pageCount}} +zoom_out.title = Паменшыць +zoom_out_label = Паменшыць +zoom_in.title = Павялічыць +zoom_in_label = Павялічыць +zoom.title = Павялічэнне тэксту +presentation_mode.title = Пераключыцца ў рэжым паказу +presentation_mode_label = Рэжым паказу +open_file.title = Адчыніць файл +open_file_label = Адчыніць +print.title = Друкаваць +print_label = Друкаваць +download.title = Загрузка +download_label = Загрузка +bookmark.title = Цяперашняя праява (скапіяваць або адчыніць у новым акне) +bookmark_label = Цяперашняя праява +tools.title = Прылады +tools_label = Прылады +first_page.title = Перайсці на першую старонку +first_page.label = Перайсці на першую старонку +first_page_label = Перайсці на першую старонку +last_page.title = Перайсці на апошнюю старонку +last_page.label = Перайсці на апошнюю старонку +last_page_label = Перайсці на апошнюю старонку +page_rotate_cw.title = Павярнуць па гадзіннікавай стрэлцы +page_rotate_cw.label = Павярнуць па гадзіннікавай стрэлцы +page_rotate_cw_label = Павярнуць па гадзіннікавай стрэлцы +page_rotate_ccw.title = Павярнуць супраць гадзіннікавай стрэлкі +page_rotate_ccw.label = Павярнуць супраць гадзіннікавай стрэлкі +page_rotate_ccw_label = Павярнуць супраць гадзіннікавай стрэлкі +hand_tool_enable.title = Дазволіць ручную прыладу +hand_tool_enable_label = Дазволіць ручную прыладу +hand_tool_disable.title = Забараніць ручную прыладу +hand_tool_disable_label = Забараніць ручную прыладу +document_properties.title = Уласцівасці дакумента… +document_properties_label = Уласцівасці дакумента… +document_properties_file_name = Назва файла: +document_properties_file_size = Памер файла: +document_properties_kb = {{size_kb}} КБ ({{size_b}} байт) +document_properties_mb = {{size_mb}} МБ ({{size_b}} байт) +document_properties_title = Загаловак: +document_properties_author = Аўтар: +document_properties_subject = Тэма: +document_properties_keywords = Ключавыя словы: +document_properties_creation_date = Дата стварэння: +document_properties_modification_date = Дата змянення: +document_properties_date_string = {{date}}, {{time}} +document_properties_creator = Стваральнік: +document_properties_producer = Вырабнік PDF: +document_properties_version = Версія PDF: +document_properties_page_count = Колькасць старонак: +document_properties_close = Зачыніць +toggle_sidebar.title = Пераключэнне палічкі +toggle_sidebar_label = Пераключыць палічку +outline.title = Паказ будовы дакумента +outline_label = Будова дакумента +attachments.title = Паказаць далучэнні +attachments_label = Далучэнні +thumbs.title = Паказ накідаў +thumbs_label = Накіды +findbar.title = Пошук у дакуменце +findbar_label = Знайсці +thumb_page_title = Старонка {{page}} +thumb_page_canvas = Накід старонкі {{page}} +find_label = Пошук: +find_previous.title = Знайсці папярэдні выпадак выразу +find_previous_label = Папярэдні +find_next.title = Знайсці наступны выпадак выразу +find_next_label = Наступны +find_highlight = Падфарбаваць усе +find_match_case_label = Адрозніваць вялікія/малыя літары +find_reached_top = Дасягнуты пачатак дакумента, працяг з канца +find_reached_bottom = Дасягнуты канец дакумента, працяг з пачатку +find_not_found = Выраз не знойдзены +error_more_info = Падрабязней +error_less_info = Сцісла +error_close = Закрыць +error_version_info = PDF.js в{{version}} (пабудова: {{build}}) +error_message = Паведамленне: {{message}} +error_stack = Стос: {{stack}} +error_file = Файл: {{file}} +error_line = Радок: {{line}} +rendering_error = Здарылася памылка падчас адлюстравання старонкі. +page_scale_width = Шырыня старонкі +page_scale_fit = Уцісненне старонкі +page_scale_auto = Самастойнае павялічэнне +page_scale_actual = Сапраўдны памер +loading_error_indicator = Памылка +loading_error = Здарылася памылка падчас загрузкі PDF. +invalid_file_error = Няспраўны або пашкоджаны файл PDF. +missing_file_error = Адсутны файл PDF. +text_annotation_type.alt = [{{type}} Annotation] +password_label = Увядзіце пароль, каб адчыніць гэты файл PDF. +password_invalid = Крывы пароль. Паспрабуйце зноў. +password_ok = Добра +password_cancel = Скасаваць +printing_not_supported = Папярэджанне: друк не падтрымлівацца цалкам гэтым азіральнікам. +printing_not_ready = Увага: PDF не сцягнуты цалкам для друкавання. +web_fonts_disabled = Шрыфты Сеціва забаронены: немгчыма ўжываць укладзеныя шрыфты PDF. +document_colors_disabled = Дакументам PDF не дазволена карыстацца сваімі ўласнымі колерамі: 'Дазволіць старонкам выбіраць свае ўласныя колеры' абяздзейнена ў азіральніку. diff --git a/static/pdf.js/locale/bg/viewer.ftl b/static/pdf.js/locale/bg/viewer.ftl deleted file mode 100644 index 7522054c..00000000 --- a/static/pdf.js/locale/bg/viewer.ftl +++ /dev/null @@ -1,384 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Предишна страница -pdfjs-previous-button-label = Предишна -pdfjs-next-button = - .title = Следваща страница -pdfjs-next-button-label = Следваща -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Страница -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = от { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } от { $pagesCount }) -pdfjs-zoom-out-button = - .title = Намаляване -pdfjs-zoom-out-button-label = Намаляване -pdfjs-zoom-in-button = - .title = Увеличаване -pdfjs-zoom-in-button-label = Увеличаване -pdfjs-zoom-select = - .title = Мащабиране -pdfjs-presentation-mode-button = - .title = Превключване към режим на представяне -pdfjs-presentation-mode-button-label = Режим на представяне -pdfjs-open-file-button = - .title = Отваряне на файл -pdfjs-open-file-button-label = Отваряне -pdfjs-print-button = - .title = Отпечатване -pdfjs-print-button-label = Отпечатване -pdfjs-save-button = - .title = Запазване -pdfjs-save-button-label = Запазване -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Изтегляне -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Изтегляне -pdfjs-bookmark-button = - .title = Текуща страница (преглед на адреса на страницата) -pdfjs-bookmark-button-label = Текуща страница -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Отваряне в приложение -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Отваряне в приложение - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Инструменти -pdfjs-tools-button-label = Инструменти -pdfjs-first-page-button = - .title = Към първата страница -pdfjs-first-page-button-label = Към първата страница -pdfjs-last-page-button = - .title = Към последната страница -pdfjs-last-page-button-label = Към последната страница -pdfjs-page-rotate-cw-button = - .title = Завъртане по час. стрелка -pdfjs-page-rotate-cw-button-label = Завъртане по часовниковата стрелка -pdfjs-page-rotate-ccw-button = - .title = Завъртане обратно на час. стрелка -pdfjs-page-rotate-ccw-button-label = Завъртане обратно на часовниковата стрелка -pdfjs-cursor-text-select-tool-button = - .title = Включване на инструмента за избор на текст -pdfjs-cursor-text-select-tool-button-label = Инструмент за избор на текст -pdfjs-cursor-hand-tool-button = - .title = Включване на инструмента ръка -pdfjs-cursor-hand-tool-button-label = Инструмент ръка -pdfjs-scroll-page-button = - .title = Използване на плъзгане на страници -pdfjs-scroll-page-button-label = Плъзгане на страници -pdfjs-scroll-vertical-button = - .title = Използване на вертикално плъзгане -pdfjs-scroll-vertical-button-label = Вертикално плъзгане -pdfjs-scroll-horizontal-button = - .title = Използване на хоризонтално -pdfjs-scroll-horizontal-button-label = Хоризонтално плъзгане -pdfjs-scroll-wrapped-button = - .title = Използване на мащабируемо плъзгане -pdfjs-scroll-wrapped-button-label = Мащабируемо плъзгане -pdfjs-spread-none-button = - .title = Режимът на сдвояване е изключен -pdfjs-spread-none-button-label = Без сдвояване -pdfjs-spread-odd-button = - .title = Сдвояване, започвайки от нечетните страници -pdfjs-spread-odd-button-label = Нечетните отляво -pdfjs-spread-even-button = - .title = Сдвояване, започвайки от четните страници -pdfjs-spread-even-button-label = Четните отляво - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Свойства на документа… -pdfjs-document-properties-button-label = Свойства на документа… -pdfjs-document-properties-file-name = Име на файл: -pdfjs-document-properties-file-size = Големина на файл: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } КБ ({ $size_b } байта) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } МБ ({ $size_b } байта) -pdfjs-document-properties-title = Заглавие: -pdfjs-document-properties-author = Автор: -pdfjs-document-properties-subject = Тема: -pdfjs-document-properties-keywords = Ключови думи: -pdfjs-document-properties-creation-date = Дата на създаване: -pdfjs-document-properties-modification-date = Дата на промяна: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Създател: -pdfjs-document-properties-producer = PDF произведен от: -pdfjs-document-properties-version = Издание на PDF: -pdfjs-document-properties-page-count = Брой страници: -pdfjs-document-properties-page-size = Размер на страницата: -pdfjs-document-properties-page-size-unit-inches = инч -pdfjs-document-properties-page-size-unit-millimeters = мм -pdfjs-document-properties-page-size-orientation-portrait = портрет -pdfjs-document-properties-page-size-orientation-landscape = пейзаж -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Правни въпроси - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Бърз преглед: -pdfjs-document-properties-linearized-yes = Да -pdfjs-document-properties-linearized-no = Не -pdfjs-document-properties-close-button = Затваряне - -## Print - -pdfjs-print-progress-message = Подготвяне на документа за отпечатване… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Отказ -pdfjs-printing-not-supported = Внимание: Този четец няма пълна поддръжка на отпечатване. -pdfjs-printing-not-ready = Внимание: Този PDF файл не е напълно зареден за печат. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Превключване на страничната лента -pdfjs-toggle-sidebar-notification-button = - .title = Превключване на страничната лента (документът има структура/прикачени файлове/слоеве) -pdfjs-toggle-sidebar-button-label = Превключване на страничната лента -pdfjs-document-outline-button = - .title = Показване на структурата на документа (двукратно щракване за свиване/разгъване на всичко) -pdfjs-document-outline-button-label = Структура на документа -pdfjs-attachments-button = - .title = Показване на притурките -pdfjs-attachments-button-label = Притурки -pdfjs-layers-button = - .title = Показване на слоевете (двукратно щракване за възстановяване на всички слоеве към състоянието по подразбиране) -pdfjs-layers-button-label = Слоеве -pdfjs-thumbs-button = - .title = Показване на миниатюрите -pdfjs-thumbs-button-label = Миниатюри -pdfjs-current-outline-item-button = - .title = Намиране на текущия елемент от структурата -pdfjs-current-outline-item-button-label = Текущ елемент от структурата -pdfjs-findbar-button = - .title = Намиране в документа -pdfjs-findbar-button-label = Търсене -pdfjs-additional-layers = Допълнителни слоеве - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Страница { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Миниатюра на страница { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Търсене - .placeholder = Търсене в документа… -pdfjs-find-previous-button = - .title = Намиране на предишно съвпадение на фразата -pdfjs-find-previous-button-label = Предишна -pdfjs-find-next-button = - .title = Намиране на следващо съвпадение на фразата -pdfjs-find-next-button-label = Следваща -pdfjs-find-highlight-checkbox = Открояване на всички -pdfjs-find-match-case-checkbox-label = Съвпадение на регистъра -pdfjs-find-match-diacritics-checkbox-label = Без производни букви -pdfjs-find-entire-word-checkbox-label = Цели думи -pdfjs-find-reached-top = Достигнато е началото на документа, продължаване от края -pdfjs-find-reached-bottom = Достигнат е краят на документа, продължаване от началото -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } от { $total } съвпадение - *[other] { $current } от { $total } съвпадения - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Повече от { $limit } съвпадение - *[other] Повече от { $limit } съвпадения - } -pdfjs-find-not-found = Фразата не е намерена - -## Predefined zoom values - -pdfjs-page-scale-width = Ширина на страницата -pdfjs-page-scale-fit = Вместване в страницата -pdfjs-page-scale-auto = Автоматично мащабиране -pdfjs-page-scale-actual = Действителен размер -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Страница { $page } - -## Loading indicator messages - -pdfjs-loading-error = Получи се грешка при зареждане на PDF-а. -pdfjs-invalid-file-error = Невалиден или повреден PDF файл. -pdfjs-missing-file-error = Липсващ PDF файл. -pdfjs-unexpected-response-error = Неочакван отговор от сървъра. -pdfjs-rendering-error = Грешка при изчертаване на страницата. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Анотация { $type }] - -## Password - -pdfjs-password-label = Въведете парола за отваряне на този PDF файл. -pdfjs-password-invalid = Невалидна парола. Моля, опитайте отново. -pdfjs-password-ok-button = Добре -pdfjs-password-cancel-button = Отказ -pdfjs-web-fonts-disabled = Уеб-шрифтовете са забранени: разрешаване на използването на вградените PDF шрифтове. - -## Editing - -pdfjs-editor-free-text-button = - .title = Текст -pdfjs-editor-free-text-button-label = Текст -pdfjs-editor-ink-button = - .title = Рисуване -pdfjs-editor-ink-button-label = Рисуване -pdfjs-editor-stamp-button = - .title = Добавяне или променяне на изображения -pdfjs-editor-stamp-button-label = Добавяне или променяне на изображения -pdfjs-editor-remove-button = - .title = Премахване - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Премахване на рисунката -pdfjs-editor-remove-freetext-button = - .title = Премахване на текста -pdfjs-editor-remove-stamp-button = - .title = Пермахване на изображението -pdfjs-editor-remove-highlight-button = - .title = Премахване на открояването - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Цвят -pdfjs-editor-free-text-size-input = Размер -pdfjs-editor-ink-color-input = Цвят -pdfjs-editor-ink-thickness-input = Дебелина -pdfjs-editor-ink-opacity-input = Прозрачност -pdfjs-editor-stamp-add-image-button = - .title = Добавяне на изображение -pdfjs-editor-stamp-add-image-button-label = Добавяне на изображение -pdfjs-free-text = - .aria-label = Текстов редактор -pdfjs-free-text-default-content = Започнете да пишете… -pdfjs-ink = - .aria-label = Промяна на рисунка -pdfjs-ink-canvas = - .aria-label = Изображение, създадено от потребител - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Алтернативен текст -pdfjs-editor-alt-text-edit-button-label = Промяна на алтернативния текст -pdfjs-editor-alt-text-dialog-label = Изберете от възможностите -pdfjs-editor-alt-text-dialog-description = Алтернативният текст помага на потребителите, когато не могат да видят изображението или то не се зарежда. -pdfjs-editor-alt-text-add-description-label = Добавяне на описание -pdfjs-editor-alt-text-add-description-description = Стремете се към 1-2 изречения, описващи предмета, настройката или действията. -pdfjs-editor-alt-text-mark-decorative-label = Отбелязване като декоративно -pdfjs-editor-alt-text-mark-decorative-description = Използва се за орнаменти или декоративни изображения, като контури и водни знаци. -pdfjs-editor-alt-text-cancel-button = Отказ -pdfjs-editor-alt-text-save-button = Запазване -pdfjs-editor-alt-text-decorative-tooltip = Отбелязване като декоративно -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Например, „Млад мъж седи на маса и се храни“ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Горен ляв ъгъл — преоразмеряване -pdfjs-editor-resizer-label-top-middle = Горе в средата — преоразмеряване -pdfjs-editor-resizer-label-top-right = Горен десен ъгъл — преоразмеряване -pdfjs-editor-resizer-label-middle-right = Дясно в средата — преоразмеряване -pdfjs-editor-resizer-label-bottom-right = Долен десен ъгъл — преоразмеряване -pdfjs-editor-resizer-label-bottom-middle = Долу в средата — преоразмеряване -pdfjs-editor-resizer-label-bottom-left = Долен ляв ъгъл — преоразмеряване -pdfjs-editor-resizer-label-middle-left = Ляво в средата — преоразмеряване - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Цвят на открояване -pdfjs-editor-colorpicker-button = - .title = Промяна на цвят -pdfjs-editor-colorpicker-dropdown = - .aria-label = Избор на цвят -pdfjs-editor-colorpicker-yellow = - .title = Жълто -pdfjs-editor-colorpicker-green = - .title = Зелено -pdfjs-editor-colorpicker-blue = - .title = Синьо -pdfjs-editor-colorpicker-pink = - .title = Розово -pdfjs-editor-colorpicker-red = - .title = Червено diff --git a/static/pdf.js/locale/bg/viewer.properties b/static/pdf.js/locale/bg/viewer.properties new file mode 100644 index 00000000..576cb567 --- /dev/null +++ b/static/pdf.js/locale/bg/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Предишна страница +previous_label=Предишна +next.title=Следваща страница +next_label=Следваща + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Страница: +page_of=от {{pageCount}} + +zoom_out.title=Отдалечаване +zoom_out_label=Отдалечаване +zoom_in.title=Приближаване +zoom_in_label=Приближаване +zoom.title=Мащабиране +presentation_mode.title=Превключване към режим на представяне +presentation_mode_label=Режим на представяне +open_file.title=Отваряне на файл +open_file_label=Отваряне +print.title=Отпечатване +print_label=Отпечатване +download.title=Изтегляне +download_label=Изтегляне +bookmark.title=Текущ изглед (копиране или отваряне в нов прозорец) +bookmark_label=Текущ изглед + +# Secondary toolbar and context menu +tools.title=Инструменти +tools_label=Инструменти +first_page.title=Към първата страница +first_page.label=Към първата страница +first_page_label=Към първата страница +last_page.title=Към последната страница +last_page.label=Към последната страница +last_page_label=Към последната страница +page_rotate_cw.title=Превъртане по часовниковата стрелка +page_rotate_cw.label=Превъртане по часовниковата стрелка +page_rotate_cw_label=Превъртане по часовниковата стрелка +page_rotate_ccw.title=Превъртане обратно на часовниковата стрелка +page_rotate_ccw.label=Превъртане обратно на часовниковата стрелка +page_rotate_ccw_label=Превъртане обратно на часовниковата стрелка + +hand_tool_enable.title=Включване на инструмента ръка +hand_tool_enable_label=Включване на инструмента ръка +hand_tool_disable.title=Изключване на инструмента ръка +hand_tool_disable_label=Изключване на инструмента ръка + +# Document properties dialog box +document_properties.title=Свойства на документа… +document_properties_label=Свойства на документа… +document_properties_file_name=Име на файл: +document_properties_file_size=Големина на файл: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} КБ ({{size_b}} байта) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} МБ ({{size_b}} байта) +document_properties_title=Заглавие: +document_properties_author=Автор: +document_properties_subject=Тема: +document_properties_keywords=Ключови думи: +document_properties_creation_date=Дата на създаване: +document_properties_modification_date=Дата на промяна: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Създател: +document_properties_producer=PDF произведен от: +document_properties_version=PDF версия: +document_properties_page_count=Брой страници: +document_properties_close=Затваряне + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Превключване на страничната лента +toggle_sidebar_label=Превключване на страничната лента +outline.title=Показване на очертанията на документа +outline_label=Очертание на документа +attachments.title=Показване на притурките +attachments_label=Притурки +thumbs.title=Показване на миниатюрите +thumbs_label=Миниатюри +findbar.title=Намиране в документа +findbar_label=Търсене + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Страница {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Миниатюра на страница {{page}} + +# Find panel button title and messages +find_label=Търсене: +find_previous.title=Намиране на предното споменаване на тази фраза +find_previous_label=Предишна +find_next.title=Намиране на следващото споменаване на тази фраза +find_next_label=Следваща +find_highlight=Маркирай всички +find_match_case_label=Точно съвпадения +find_reached_top=Достигнато е началото на документа, продължаване от края +find_reached_bottom=Достигнат е краят на документа, продължаване от началото +find_not_found=Фразата не е намерена + +# Error panel labels +error_more_info=Повече информация +error_less_info=По-малко информация +error_close=Затваряне +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js версия {{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Съобщение: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Стек: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Файл: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Ред: {{line}} +rendering_error=Грешка при изчертаване на страницата. + +# Predefined zoom values +page_scale_width=Ширина на страницата +page_scale_fit=Вместване в страницата +page_scale_auto=Автоматично мащабиране +page_scale_actual=Действителен размер +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Грешка +loading_error=Получи се грешка при зареждане на PDF-а. +invalid_file_error=Невалиден или повреден PDF файл. +missing_file_error=Липсващ PDF файл. +unexpected_response_error=Неочакван отговор от сървъра. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Анотация {{type}}] +password_label=Въведете парола за отваряне на този PDF файл. +password_invalid=Невалидна парола. Моля, опитайте отново. +password_ok=Добре +password_cancel=Отказ + +printing_not_supported=Внимание: Този браузър няма пълна поддръжка на отпечатване. +printing_not_ready=Внимание: Този PDF файл не е напълно зареден за печат. +web_fonts_disabled=Уеб-шрифтовете са забранени: разрешаване на използването на вградените PDF шрифтове. +document_colors_not_allowed=На PDF-документите не е разрешено да използват собствени цветове: „Разрешаване на страниците да избират собствени цветове“ е изключено в браузъра. diff --git a/static/pdf.js/locale/bn-BD/viewer.properties b/static/pdf.js/locale/bn-BD/viewer.properties new file mode 100644 index 00000000..b5e3048b --- /dev/null +++ b/static/pdf.js/locale/bn-BD/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=পূর্ববর্তী পৃষ্ঠা +previous_label=পূর্ববর্তী +next.title=পরবর্তী পৃষ্ঠা +next_label=পরবর্তী + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=পৃষ্ঠা: +page_of={{pageCount}} এর + +zoom_out.title=ছোট আকারে প্রদর্শন +zoom_out_label=ছোট আকারে প্রদর্শন +zoom_in.title=বড় আকারে প্রদর্শন +zoom_in_label=বড় আকারে প্রদর্শন +zoom.title=বড় আকারে প্রদর্শন +presentation_mode.title=উপস্থাপনা মোডে স্যুইচ করুন +presentation_mode_label=উপস্থাপনা মোড +open_file.title=ফাইল খুলুন +open_file_label=খুলুন +print.title=মুদ্রণ +print_label=মুদ্রণ +download.title=ডাউনলোড +download_label=ডাউনলোড +bookmark.title=বর্তমান অবস্থা (অনুলিপি অথবা নতুন উইন্ডো তে খুলুন) +bookmark_label=বর্তমান অবস্থা + +# Secondary toolbar and context menu +tools.title=টুল +tools_label=টুল +first_page.title=প্রথম পাতায় যাও +first_page.label=প্রথম পাতায় যাও +first_page_label=প্রথম পাতায় যাও +last_page.title=শেষ পাতায় যাও +last_page.label=শেষ পাতায় যাও +last_page_label=শেষ পাতায় যাও +page_rotate_cw.title=ঘড়ির কাঁটার দিকে ঘোরাও +page_rotate_cw.label=ঘড়ির কাঁটার দিকে ঘোরাও +page_rotate_cw_label=ঘড়ির কাঁটার দিকে ঘোরাও +page_rotate_ccw.title=ঘড়ির কাঁটার বিপরীতে ঘোরাও +page_rotate_ccw.label=ঘড়ির কাঁটার বিপরীতে ঘোরাও +page_rotate_ccw_label=ঘড়ির কাঁটার বিপরীতে ঘোরাও + +hand_tool_enable.title=হ্যান্ড টুল সক্রিয় করুন +hand_tool_enable_label=হ্যান্ড টুল সক্রিয় করুন +hand_tool_disable.title=হ্যান্ড টুল নিস্ক্রিয় করুন +hand_tool_disable_label=হ্যান্ড টুল নিস্ক্রিয় করুন + +# Document properties dialog box +document_properties.title=নথি বৈশিষ্ট্য… +document_properties_label=নথি বৈশিষ্ট্য… +document_properties_file_name=ফাইলের নাম: +document_properties_file_size=ফাইলের আকার: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} কেবি ({{size_b}} বাইট) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} এমবি ({{size_b}} বাইট) +document_properties_title=শিরোনাম: +document_properties_author=লেখক: +document_properties_subject=বিষয়: +document_properties_keywords=কীওয়ার্ড: +document_properties_creation_date=তৈরির তারিখ: +document_properties_modification_date=পরিবর্তনের তারিখ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=প্রস্তুতকারক: +document_properties_producer=পিডিএফ প্রস্তুতকারক: +document_properties_version=পিডিএফ সংষ্করণ: +document_properties_page_count=মোট পাতা: +document_properties_close=বন্ধ + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=সাইডবার টগল করুন +toggle_sidebar_label=সাইডবার টগল করুন +outline.title=নথির রূপরেখা প্রদর্শন করুন +outline_label=নথির রূপরেখা +attachments.title=সংযুক্তি দেখাও +attachments_label=সংযুক্তি +thumbs.title=থাম্বনেইল সমূহ প্রদর্শন করুন +thumbs_label=থাম্বনেইল সমূহ +findbar.title=নথির মধ্যে খুঁজুন +findbar_label=অনুসন্ধান + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=পৃষ্ঠা {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}} পৃষ্ঠার থাম্বনেইল + +# Find panel button title and messages +find_label=অনুসন্ধান: +find_previous.title=বাক্যাংশের পূর্ববর্তী উপস্থিতি অনুসন্ধান +find_previous_label=পূর্ববর্তী +find_next.title=বাক্যাংশের পরবর্তী উপস্থিতি অনুসন্ধান +find_next_label=পরবর্তী +find_highlight=সব হাইলাইট করা হবে +find_match_case_label=অক্ষরের ছাঁদ মেলানো +find_reached_top=পৃষ্ঠার শুরুতে পৌছে গেছে, নীচ থেকে আরম্ভ করা হয়েছে +find_reached_bottom=পৃষ্ঠার শেষে পৌছে গেছে, উপর থেকে আরম্ভ করা হয়েছে +find_not_found=বাক্যাংশ পাওয়া যায়নি + +# Error panel labels +error_more_info=আরও তথ্য +error_less_info=কম তথ্য +error_close=বন্ধ +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=বার্তা: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=নথি: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=লাইন: {{line}} +rendering_error=পৃষ্ঠা উপস্থাপনার সময় ত্রুটি দেখা দিয়েছে। + +# Predefined zoom values +page_scale_width=পৃষ্ঠার প্রস্থ +page_scale_fit=পৃষ্ঠা ফিট করুন +page_scale_auto=স্বয়ংক্রিয় জুম +page_scale_actual=প্রকৃত আকার +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=ত্রুটি +loading_error=পিডিএফ লোড করার সময় ত্রুটি দেখা দিয়েছে। +invalid_file_error=অকার্যকর অথবা ক্ষতিগ্রস্ত পিডিএফ ফাইল। +missing_file_error=পিডিএফ ফাইল পাওয়া যাচ্ছে না। +unexpected_response_error=অপ্রত্যাশীত সার্ভার প্রতিক্রিয়া। + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} টীকা] +password_label=পিডিএফ ফাইলটি ওপেন করতে পাসওয়ার্ড দিন। +password_invalid=ভুল পাসওয়ার্ড। অনুগ্রহ করে আবার চেষ্টা করুন। +password_ok=ঠিক আছে +password_cancel=বাতিল + +printing_not_supported=সতর্কতা: এই ব্রাউজারে মুদ্রণ সম্পূর্ণভাবে সমর্থিত নয়। +printing_not_ready=সতর্কীকরণ: পিডিএফটি মুদ্রণের জন্য সম্পূর্ণ লোড হয়নি। +web_fonts_disabled=ওয়েব ফন্ট নিষ্ক্রিয়: সংযুক্ত পিডিএফ ফন্ট ব্যবহার করা যাচ্ছে না। +document_colors_not_allowed=পিডিএফ ডকুমেন্টকে তাদের নিজস্ব রঙ ব্যবহারে অনুমতি নেই: 'পাতা তাদের নিজেস্ব রঙ নির্বাচন করতে অনুমতি দিন' এই ব্রাউজারে নিষ্ক্রিয় রয়েছে। diff --git a/static/pdf.js/locale/bn-IN/viewer.properties b/static/pdf.js/locale/bn-IN/viewer.properties new file mode 100644 index 00000000..9aef9ffa --- /dev/null +++ b/static/pdf.js/locale/bn-IN/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=পূর্ববর্তী পৃষ্ঠা +previous_label=পূর্ববর্তী +next.title=পরবর্তী পৃষ্ঠা +next_label=পরবর্তী + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=পৃষ্ঠা: +page_of=সর্বমোট {{pageCount}} + +zoom_out.title=ছোট মাপে প্রদর্শন +zoom_out_label=ছোট মাপে প্রদর্শন +zoom_in.title=বড় মাপে প্রদর্শন +zoom_in_label=বড় মাপে প্রদর্শন +zoom.title=প্রদর্শনের মাপ +presentation_mode.title=উপস্থাপনা মোড স্যুইচ করুন +presentation_mode_label=উপস্থাপনা মোড +open_file.title=ফাইল খুলুন +open_file_label=খুলুন +print.title=প্রিন্ট করুন +print_label=প্রিন্ট করুন +download.title=ডাউনলোড করুন +download_label=ডাউনলোড করুন +bookmark.title=বর্তমান প্রদর্শন (কপি করুন অথবা নতুন উইন্ডোতে খুলুন) +bookmark_label=বর্তমান প্রদর্শন + +# Secondary toolbar and context menu +tools.title=সরঞ্জাম +tools_label=সরঞ্জাম +first_page.title=প্রথম পৃষ্ঠায় চলুন +first_page.label=প্রথম পৃষ্ঠায় চলুন +first_page_label=প্রথম পৃষ্ঠায় চলুন +last_page.title=সর্বশেষ পৃষ্ঠায় চলুন +last_page.label=সর্বশেষ পৃষ্ঠায় চলুন +last_page_label=সর্বশেষ পৃষ্ঠায় চলুন +page_rotate_cw.title=ডানদিকে ঘোরানো হবে +page_rotate_cw.label=ডানদিকে ঘোরানো হবে +page_rotate_cw_label=ডানদিকে ঘোরানো হবে +page_rotate_ccw.title=বাঁদিকে ঘোরানো হবে +page_rotate_ccw.label=বাঁদিকে ঘোরানো হবে +page_rotate_ccw_label=বাঁদিকে ঘোরানো হবে + +hand_tool_enable.title=হ্যান্ড টুল সক্রিয় করুন +hand_tool_enable_label=হ্যান্ড টুল সক্রিয় করুন +hand_tool_disable.title=হ্যান্ড টুল নিস্ক্রিয় করুন +hand_tool_disable_label=হ্যান্ড টুল নিস্ক্রিয় করুন + +# Document properties dialog box +document_properties.title=নথির বৈশিষ্ট্য… +document_properties_label=নথির বৈশিষ্ট্য… +document_properties_file_name=ফাইলের নাম: +document_properties_file_size=ফাইলের মাপ: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} মেগাবাইট ({{size_b}} bytes) +document_properties_title=শিরোনাম: +document_properties_author=লেখক: +document_properties_subject=বিষয়: +document_properties_keywords=নির্দেশক শব্দ: +document_properties_creation_date=নির্মাণের তারিখ: +document_properties_modification_date=পরিবর্তনের তারিখ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=নির্মাতা: +document_properties_producer=PDF নির্মাতা: +document_properties_version=PDF সংস্করণ: +document_properties_page_count=মোট পৃষ্ঠা: +document_properties_close=বন্ধ করুন + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=সাইডবার টগল করুন +toggle_sidebar_label=সাইডবার টগল করুন +outline.title=নথির রূপরেখা প্রদর্শন +outline_label=নথির রূপরেখা প্রদর্শন +attachments.title=সংযুক্তিসমূহ দেখান +attachments_label=সংযুক্ত বস্তু +thumbs.title=থাম্ব-নেইল প্রদর্শন +thumbs_label=থাম্ব-নেইল প্রদর্শন +findbar.title=নথিতে খুঁজুন +findbar_label=অনুসন্ধান করুন + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=পৃষ্ঠা {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=পৃষ্ঠা {{page}}-র থাম্ব-নেইল + +# Find panel button title and messages +find_label=অনুসন্ধান: +find_previous.title=চিহ্নিত পংক্তির পূর্ববর্তী উপস্থিতি অনুসন্ধান করুন +find_previous_label=পূর্ববর্তী +find_next.title=চিহ্নিত পংক্তির পরবর্তী উপস্থিতি অনুসন্ধান করুন +find_next_label=পরবর্তী +find_highlight=সমগ্র উজ্জ্বল করুন +find_match_case_label=হরফের ছাঁদ মেলানো হবে +find_reached_top=পৃষ্ঠার প্রারম্ভে পৌছে গেছে, নীচের অংশ থেকে আরম্ভ করা হবে +find_reached_bottom=পৃষ্ঠার অন্তিম প্রান্তে পৌছে গেছে, প্রথম অংশ থেকে আরম্ভ করা হবে +find_not_found=পংক্তি পাওয়া যায়নি + +# Error panel labels +error_more_info=অতিরিক্ত তথ্য +error_less_info=কম তথ্য +error_close=বন্ধ করুন +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Message: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=File: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Line: {{line}} +rendering_error=পৃষ্ঠা প্রদর্শনকালে একটি সমস্যা দেখা দিয়েছে। + +# Predefined zoom values +page_scale_width=পৃষ্ঠার প্রস্থ অনুযায়ী +page_scale_fit=পৃষ্ঠার মাপ অনুযায়ী +page_scale_auto=স্বয়ংক্রিয় মাপ নির্ধারণ +page_scale_actual=প্রকৃত মাপ +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=ত্রুটি +loading_error=PDF লোড করার সময় সমস্যা দেখা দিয়েছে। +invalid_file_error=অবৈধ বা ক্ষতিগ্রস্ত পিডিএফ ফাইল। +missing_file_error=অনুপস্থিত PDF ফাইল +unexpected_response_error=সার্ভার থেকে অপ্রত্যাশিত সাড়া পাওয়া গেছে। + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=এই PDF ফাইল খোলার জন্য পাসওয়ার্ড দিন। +password_invalid=পাসওয়ার্ড সঠিক নয়। অনুগ্রহ করে পুনরায় প্রচেষ্টা করুন। +password_ok=OK +password_cancel=বাতিল করুন + +printing_not_supported=সতর্কবার্তা: এই ব্রাউজার দ্বারা প্রিন্ট ব্যবস্থা সম্পূর্ণরূপে সমর্থিত নয়। +printing_not_ready=সতর্কবাণী: পিডিএফ সম্পূর্ণরূপে মুদ্রণের জন্য লোড করা হয় না. +web_fonts_disabled=ওয়েব ফন্ট নিষ্ক্রিয় করা হয়েছে: এমবেডেড পিডিএফ ফন্ট ব্যবহার করতে অক্ষম. +document_colors_not_allowed=পিডিএফ নথি তাদের নিজস্ব রং ব্যবহার করার জন্য অনুমতিপ্রাপ্ত নয়: ব্রাউজারে নিষ্ক্রিয় করা হয়েছে য়েন 'পেজ তাদের নিজস্ব রং নির্বাচন করার অনুমতি প্রদান করা য়ায়।' diff --git a/static/pdf.js/locale/bn/viewer.ftl b/static/pdf.js/locale/bn/viewer.ftl deleted file mode 100644 index 1e20ecb8..00000000 --- a/static/pdf.js/locale/bn/viewer.ftl +++ /dev/null @@ -1,247 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = পূর্ববর্তী পাতা -pdfjs-previous-button-label = পূর্ববর্তী -pdfjs-next-button = - .title = পরবর্তী পাতা -pdfjs-next-button-label = পরবর্তী -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = পাতা -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } এর -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pagesCount } এর { $pageNumber }) -pdfjs-zoom-out-button = - .title = ছোট আকারে প্রদর্শন -pdfjs-zoom-out-button-label = ছোট আকারে প্রদর্শন -pdfjs-zoom-in-button = - .title = বড় আকারে প্রদর্শন -pdfjs-zoom-in-button-label = বড় আকারে প্রদর্শন -pdfjs-zoom-select = - .title = বড় আকারে প্রদর্শন -pdfjs-presentation-mode-button = - .title = উপস্থাপনা মোডে স্যুইচ করুন -pdfjs-presentation-mode-button-label = উপস্থাপনা মোড -pdfjs-open-file-button = - .title = ফাইল খুলুন -pdfjs-open-file-button-label = খুলুন -pdfjs-print-button = - .title = মুদ্রণ -pdfjs-print-button-label = মুদ্রণ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = টুল -pdfjs-tools-button-label = টুল -pdfjs-first-page-button = - .title = প্রথম পাতায় যাও -pdfjs-first-page-button-label = প্রথম পাতায় যাও -pdfjs-last-page-button = - .title = শেষ পাতায় যাও -pdfjs-last-page-button-label = শেষ পাতায় যাও -pdfjs-page-rotate-cw-button = - .title = ঘড়ির কাঁটার দিকে ঘোরাও -pdfjs-page-rotate-cw-button-label = ঘড়ির কাঁটার দিকে ঘোরাও -pdfjs-page-rotate-ccw-button = - .title = ঘড়ির কাঁটার বিপরীতে ঘোরাও -pdfjs-page-rotate-ccw-button-label = ঘড়ির কাঁটার বিপরীতে ঘোরাও -pdfjs-cursor-text-select-tool-button = - .title = লেখা নির্বাচক টুল সক্রিয় করুন -pdfjs-cursor-text-select-tool-button-label = লেখা নির্বাচক টুল -pdfjs-cursor-hand-tool-button = - .title = হ্যান্ড টুল সক্রিয় করুন -pdfjs-cursor-hand-tool-button-label = হ্যান্ড টুল -pdfjs-scroll-vertical-button = - .title = উলম্ব স্ক্রলিং ব্যবহার করুন -pdfjs-scroll-vertical-button-label = উলম্ব স্ক্রলিং -pdfjs-scroll-horizontal-button = - .title = অনুভূমিক স্ক্রলিং ব্যবহার করুন -pdfjs-scroll-horizontal-button-label = অনুভূমিক স্ক্রলিং -pdfjs-scroll-wrapped-button = - .title = Wrapped স্ক্রোলিং ব্যবহার করুন -pdfjs-scroll-wrapped-button-label = Wrapped স্ক্রোলিং -pdfjs-spread-none-button = - .title = পেজ স্প্রেডগুলোতে যোগদান করবেন না -pdfjs-spread-none-button-label = Spreads নেই -pdfjs-spread-odd-button-label = বিজোড় Spreads -pdfjs-spread-even-button-label = জোড় Spreads - -## Document properties dialog - -pdfjs-document-properties-button = - .title = নথি বৈশিষ্ট্য… -pdfjs-document-properties-button-label = নথি বৈশিষ্ট্য… -pdfjs-document-properties-file-name = ফাইলের নাম: -pdfjs-document-properties-file-size = ফাইলের আকার: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } কেবি ({ $size_b } বাইট) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } এমবি ({ $size_b } বাইট) -pdfjs-document-properties-title = শিরোনাম: -pdfjs-document-properties-author = লেখক: -pdfjs-document-properties-subject = বিষয়: -pdfjs-document-properties-keywords = কীওয়ার্ড: -pdfjs-document-properties-creation-date = তৈরির তারিখ: -pdfjs-document-properties-modification-date = পরিবর্তনের তারিখ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = প্রস্তুতকারক: -pdfjs-document-properties-producer = পিডিএফ প্রস্তুতকারক: -pdfjs-document-properties-version = পিডিএফ সংষ্করণ: -pdfjs-document-properties-page-count = মোট পাতা: -pdfjs-document-properties-page-size = পাতার সাইজ: -pdfjs-document-properties-page-size-unit-inches = এর মধ্যে -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = উলম্ব -pdfjs-document-properties-page-size-orientation-landscape = অনুভূমিক -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = লেটার -pdfjs-document-properties-page-size-name-legal = লীগাল - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = হ্যাঁ -pdfjs-document-properties-linearized-no = না -pdfjs-document-properties-close-button = বন্ধ - -## Print - -pdfjs-print-progress-message = মুদ্রণের জন্য নথি প্রস্তুত করা হচ্ছে… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = বাতিল -pdfjs-printing-not-supported = সতর্কতা: এই ব্রাউজারে মুদ্রণ সম্পূর্ণভাবে সমর্থিত নয়। -pdfjs-printing-not-ready = সতর্কীকরণ: পিডিএফটি মুদ্রণের জন্য সম্পূর্ণ লোড হয়নি। - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = সাইডবার টগল করুন -pdfjs-toggle-sidebar-button-label = সাইডবার টগল করুন -pdfjs-document-outline-button = - .title = নথির আউটলাইন দেখাও (সব আইটেম প্রসারিত/সঙ্কুচিত করতে ডবল ক্লিক করুন) -pdfjs-document-outline-button-label = নথির রূপরেখা -pdfjs-attachments-button = - .title = সংযুক্তি দেখাও -pdfjs-attachments-button-label = সংযুক্তি -pdfjs-thumbs-button = - .title = থাম্বনেইল সমূহ প্রদর্শন করুন -pdfjs-thumbs-button-label = থাম্বনেইল সমূহ -pdfjs-findbar-button = - .title = নথির মধ্যে খুঁজুন -pdfjs-findbar-button-label = খুঁজুন - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = পাতা { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } পাতার থাম্বনেইল - -## Find panel button title and messages - -pdfjs-find-input = - .title = খুঁজুন - .placeholder = নথির মধ্যে খুঁজুন… -pdfjs-find-previous-button = - .title = বাক্যাংশের পূর্ববর্তী উপস্থিতি অনুসন্ধান -pdfjs-find-previous-button-label = পূর্ববর্তী -pdfjs-find-next-button = - .title = বাক্যাংশের পরবর্তী উপস্থিতি অনুসন্ধান -pdfjs-find-next-button-label = পরবর্তী -pdfjs-find-highlight-checkbox = সব হাইলাইট করুন -pdfjs-find-match-case-checkbox-label = অক্ষরের ছাঁদ মেলানো -pdfjs-find-entire-word-checkbox-label = সম্পূর্ণ শব্দ -pdfjs-find-reached-top = পাতার শুরুতে পৌছে গেছে, নীচ থেকে আরম্ভ করা হয়েছে -pdfjs-find-reached-bottom = পাতার শেষে পৌছে গেছে, উপর থেকে আরম্ভ করা হয়েছে -pdfjs-find-not-found = বাক্যাংশ পাওয়া যায়নি - -## Predefined zoom values - -pdfjs-page-scale-width = পাতার প্রস্থ -pdfjs-page-scale-fit = পাতা ফিট করুন -pdfjs-page-scale-auto = স্বয়ংক্রিয় জুম -pdfjs-page-scale-actual = প্রকৃত আকার -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = পিডিএফ লোড করার সময় ত্রুটি দেখা দিয়েছে। -pdfjs-invalid-file-error = অকার্যকর অথবা ক্ষতিগ্রস্ত পিডিএফ ফাইল। -pdfjs-missing-file-error = নিখোঁজ PDF ফাইল। -pdfjs-unexpected-response-error = অপ্রত্যাশীত সার্ভার প্রতিক্রিয়া। -pdfjs-rendering-error = পাতা উপস্থাপনার সময় ত্রুটি দেখা দিয়েছে। - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } টীকা] - -## Password - -pdfjs-password-label = পিডিএফ ফাইলটি ওপেন করতে পাসওয়ার্ড দিন। -pdfjs-password-invalid = ভুল পাসওয়ার্ড। অনুগ্রহ করে আবার চেষ্টা করুন। -pdfjs-password-ok-button = ঠিক আছে -pdfjs-password-cancel-button = বাতিল -pdfjs-web-fonts-disabled = ওয়েব ফন্ট নিষ্ক্রিয়: সংযুক্ত পিডিএফ ফন্ট ব্যবহার করা যাচ্ছে না। - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/bo/viewer.ftl b/static/pdf.js/locale/bo/viewer.ftl deleted file mode 100644 index 824eab4f..00000000 --- a/static/pdf.js/locale/bo/viewer.ftl +++ /dev/null @@ -1,247 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = དྲ་ངོས་སྔོན་མ -pdfjs-previous-button-label = སྔོན་མ -pdfjs-next-button = - .title = དྲ་ངོས་རྗེས་མ -pdfjs-next-button-label = རྗེས་མ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = ཤོག་ངོས -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = of { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } of { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom Out -pdfjs-zoom-out-button-label = Zoom Out -pdfjs-zoom-in-button = - .title = Zoom In -pdfjs-zoom-in-button-label = Zoom In -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Switch to Presentation Mode -pdfjs-presentation-mode-button-label = Presentation Mode -pdfjs-open-file-button = - .title = Open File -pdfjs-open-file-button-label = Open -pdfjs-print-button = - .title = Print -pdfjs-print-button-label = Print - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tools -pdfjs-tools-button-label = Tools -pdfjs-first-page-button = - .title = Go to First Page -pdfjs-first-page-button-label = Go to First Page -pdfjs-last-page-button = - .title = Go to Last Page -pdfjs-last-page-button-label = Go to Last Page -pdfjs-page-rotate-cw-button = - .title = Rotate Clockwise -pdfjs-page-rotate-cw-button-label = Rotate Clockwise -pdfjs-page-rotate-ccw-button = - .title = Rotate Counterclockwise -pdfjs-page-rotate-ccw-button-label = Rotate Counterclockwise -pdfjs-cursor-text-select-tool-button = - .title = Enable Text Selection Tool -pdfjs-cursor-text-select-tool-button-label = Text Selection Tool -pdfjs-cursor-hand-tool-button = - .title = Enable Hand Tool -pdfjs-cursor-hand-tool-button-label = Hand Tool -pdfjs-scroll-vertical-button = - .title = Use Vertical Scrolling -pdfjs-scroll-vertical-button-label = Vertical Scrolling -pdfjs-scroll-horizontal-button = - .title = Use Horizontal Scrolling -pdfjs-scroll-horizontal-button-label = Horizontal Scrolling -pdfjs-scroll-wrapped-button = - .title = Use Wrapped Scrolling -pdfjs-scroll-wrapped-button-label = Wrapped Scrolling -pdfjs-spread-none-button = - .title = Do not join page spreads -pdfjs-spread-none-button-label = No Spreads -pdfjs-spread-odd-button = - .title = Join page spreads starting with odd-numbered pages -pdfjs-spread-odd-button-label = Odd Spreads -pdfjs-spread-even-button = - .title = Join page spreads starting with even-numbered pages -pdfjs-spread-even-button-label = Even Spreads - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Document Properties… -pdfjs-document-properties-button-label = Document Properties… -pdfjs-document-properties-file-name = File name: -pdfjs-document-properties-file-size = File size: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Title: -pdfjs-document-properties-author = Author: -pdfjs-document-properties-subject = Subject: -pdfjs-document-properties-keywords = Keywords: -pdfjs-document-properties-creation-date = Creation Date: -pdfjs-document-properties-modification-date = Modification Date: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creator: -pdfjs-document-properties-producer = PDF Producer: -pdfjs-document-properties-version = PDF Version: -pdfjs-document-properties-page-count = Page Count: -pdfjs-document-properties-page-size = Page Size: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portrait -pdfjs-document-properties-page-size-orientation-landscape = landscape -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Yes -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Close - -## Print - -pdfjs-print-progress-message = Preparing document for printing… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancel -pdfjs-printing-not-supported = Warning: Printing is not fully supported by this browser. -pdfjs-printing-not-ready = Warning: The PDF is not fully loaded for printing. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Toggle Sidebar -pdfjs-toggle-sidebar-button-label = Toggle Sidebar -pdfjs-document-outline-button = - .title = Show Document Outline (double-click to expand/collapse all items) -pdfjs-document-outline-button-label = Document Outline -pdfjs-attachments-button = - .title = Show Attachments -pdfjs-attachments-button-label = Attachments -pdfjs-thumbs-button = - .title = Show Thumbnails -pdfjs-thumbs-button-label = Thumbnails -pdfjs-findbar-button = - .title = Find in Document -pdfjs-findbar-button-label = Find - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Page { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Thumbnail of Page { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Find - .placeholder = Find in document… -pdfjs-find-previous-button = - .title = Find the previous occurrence of the phrase -pdfjs-find-previous-button-label = Previous -pdfjs-find-next-button = - .title = Find the next occurrence of the phrase -pdfjs-find-next-button-label = Next -pdfjs-find-highlight-checkbox = Highlight all -pdfjs-find-match-case-checkbox-label = Match case -pdfjs-find-entire-word-checkbox-label = Whole words -pdfjs-find-reached-top = Reached top of document, continued from bottom -pdfjs-find-reached-bottom = Reached end of document, continued from top -pdfjs-find-not-found = Phrase not found - -## Predefined zoom values - -pdfjs-page-scale-width = Page Width -pdfjs-page-scale-fit = Page Fit -pdfjs-page-scale-auto = Automatic Zoom -pdfjs-page-scale-actual = Actual Size -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = An error occurred while loading the PDF. -pdfjs-invalid-file-error = Invalid or corrupted PDF file. -pdfjs-missing-file-error = Missing PDF file. -pdfjs-unexpected-response-error = Unexpected server response. -pdfjs-rendering-error = An error occurred while rendering the page. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Enter the password to open this PDF file. -pdfjs-password-invalid = Invalid password. Please try again. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Cancel -pdfjs-web-fonts-disabled = Web fonts are disabled: unable to use embedded PDF fonts. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/br/viewer.ftl b/static/pdf.js/locale/br/viewer.ftl deleted file mode 100644 index 471b9a5d..00000000 --- a/static/pdf.js/locale/br/viewer.ftl +++ /dev/null @@ -1,312 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pajenn a-raok -pdfjs-previous-button-label = A-raok -pdfjs-next-button = - .title = Pajenn war-lerc'h -pdfjs-next-button-label = War-lerc'h -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pajenn -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = eus { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } war { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoum bihanaat -pdfjs-zoom-out-button-label = Zoum bihanaat -pdfjs-zoom-in-button = - .title = Zoum brasaat -pdfjs-zoom-in-button-label = Zoum brasaat -pdfjs-zoom-select = - .title = Zoum -pdfjs-presentation-mode-button = - .title = Trec'haoliñ etrezek ar mod kinnigadenn -pdfjs-presentation-mode-button-label = Mod kinnigadenn -pdfjs-open-file-button = - .title = Digeriñ ur restr -pdfjs-open-file-button-label = Digeriñ ur restr -pdfjs-print-button = - .title = Moullañ -pdfjs-print-button-label = Moullañ -pdfjs-save-button = - .title = Enrollañ -pdfjs-save-button-label = Enrollañ -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Pellgargañ -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Pellgargañ -pdfjs-bookmark-button-label = Pajenn a-vremañ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Ostilhoù -pdfjs-tools-button-label = Ostilhoù -pdfjs-first-page-button = - .title = Mont d'ar bajenn gentañ -pdfjs-first-page-button-label = Mont d'ar bajenn gentañ -pdfjs-last-page-button = - .title = Mont d'ar bajenn diwezhañ -pdfjs-last-page-button-label = Mont d'ar bajenn diwezhañ -pdfjs-page-rotate-cw-button = - .title = C'hwelañ gant roud ar bizied -pdfjs-page-rotate-cw-button-label = C'hwelañ gant roud ar bizied -pdfjs-page-rotate-ccw-button = - .title = C'hwelañ gant roud gin ar bizied -pdfjs-page-rotate-ccw-button-label = C'hwelañ gant roud gin ar bizied -pdfjs-cursor-text-select-tool-button = - .title = Gweredekaat an ostilh diuzañ testenn -pdfjs-cursor-text-select-tool-button-label = Ostilh diuzañ testenn -pdfjs-cursor-hand-tool-button = - .title = Gweredekaat an ostilh dorn -pdfjs-cursor-hand-tool-button-label = Ostilh dorn -pdfjs-scroll-vertical-button = - .title = Arverañ an dibunañ a-blom -pdfjs-scroll-vertical-button-label = Dibunañ a-serzh -pdfjs-scroll-horizontal-button = - .title = Arverañ an dibunañ a-blaen -pdfjs-scroll-horizontal-button-label = Dibunañ a-blaen -pdfjs-scroll-wrapped-button = - .title = Arverañ an dibunañ paket -pdfjs-scroll-wrapped-button-label = Dibunañ paket -pdfjs-spread-none-button = - .title = Chom hep stagañ ar skignadurioù -pdfjs-spread-none-button-label = Skignadenn ebet -pdfjs-spread-odd-button = - .title = Lakaat ar pajennadoù en ur gregiñ gant ar pajennoù ampar -pdfjs-spread-odd-button-label = Pajennoù ampar -pdfjs-spread-even-button = - .title = Lakaat ar pajennadoù en ur gregiñ gant ar pajennoù par -pdfjs-spread-even-button-label = Pajennoù par - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Perzhioù an teul… -pdfjs-document-properties-button-label = Perzhioù an teul… -pdfjs-document-properties-file-name = Anv restr: -pdfjs-document-properties-file-size = Ment ar restr: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } Ke ({ $size_b } eizhbit) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } Me ({ $size_b } eizhbit) -pdfjs-document-properties-title = Titl: -pdfjs-document-properties-author = Aozer: -pdfjs-document-properties-subject = Danvez: -pdfjs-document-properties-keywords = Gerioù-alc'hwez: -pdfjs-document-properties-creation-date = Deiziad krouiñ: -pdfjs-document-properties-modification-date = Deiziad kemmañ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Krouer: -pdfjs-document-properties-producer = Kenderc'her PDF: -pdfjs-document-properties-version = Handelv PDF: -pdfjs-document-properties-page-count = Niver a bajennoù: -pdfjs-document-properties-page-size = Ment ar bajenn: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = poltred -pdfjs-document-properties-page-size-orientation-landscape = gweledva -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Lizher -pdfjs-document-properties-page-size-name-legal = Lezennel - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Gwel Web Herrek: -pdfjs-document-properties-linearized-yes = Ya -pdfjs-document-properties-linearized-no = Ket -pdfjs-document-properties-close-button = Serriñ - -## Print - -pdfjs-print-progress-message = O prientiñ an teul evit moullañ... -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Nullañ -pdfjs-printing-not-supported = Kemenn: N'eo ket skoret penn-da-benn ar moullañ gant ar merdeer-mañ. -pdfjs-printing-not-ready = Kemenn: N'hall ket bezañ moullet ar restr PDF rak n'eo ket karget penn-da-benn. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Diskouez/kuzhat ar varrenn gostez -pdfjs-toggle-sidebar-notification-button = - .title = Trec'haoliñ ar varrenn-gostez (ur steuñv pe stagadennoù a zo en teul) -pdfjs-toggle-sidebar-button-label = Diskouez/kuzhat ar varrenn gostez -pdfjs-document-outline-button = - .title = Diskouez steuñv an teul (daouglikit evit brasaat/bihanaat an holl elfennoù) -pdfjs-document-outline-button-label = Sinedoù an teuliad -pdfjs-attachments-button = - .title = Diskouez ar c'henstagadurioù -pdfjs-attachments-button-label = Kenstagadurioù -pdfjs-layers-button = - .title = Diskouez ar gwiskadoù (daou-glikañ evit adderaouekaat an holl gwiskadoù d'o stad dre ziouer) -pdfjs-layers-button-label = Gwiskadoù -pdfjs-thumbs-button = - .title = Diskouez ar melvennoù -pdfjs-thumbs-button-label = Melvennoù -pdfjs-findbar-button = - .title = Klask e-barzh an teuliad -pdfjs-findbar-button-label = Klask -pdfjs-additional-layers = Gwiskadoù ouzhpenn - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pajenn { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Melvenn ar bajenn { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Klask - .placeholder = Klask e-barzh an teuliad -pdfjs-find-previous-button = - .title = Kavout an tamm frazenn kent o klotañ ganti -pdfjs-find-previous-button-label = Kent -pdfjs-find-next-button = - .title = Kavout an tamm frazenn war-lerc'h o klotañ ganti -pdfjs-find-next-button-label = War-lerc'h -pdfjs-find-highlight-checkbox = Usskediñ pep tra -pdfjs-find-match-case-checkbox-label = Teurel evezh ouzh ar pennlizherennoù -pdfjs-find-match-diacritics-checkbox-label = Doujañ d’an tiredoù -pdfjs-find-entire-word-checkbox-label = Gerioù a-bezh -pdfjs-find-reached-top = Tizhet eo bet derou ar bajenn, kenderc'hel diouzh an diaz -pdfjs-find-reached-bottom = Tizhet eo bet dibenn ar bajenn, kenderc'hel diouzh ar c'hrec'h -pdfjs-find-not-found = N'haller ket kavout ar frazenn - -## Predefined zoom values - -pdfjs-page-scale-width = Led ar bajenn -pdfjs-page-scale-fit = Pajenn a-bezh -pdfjs-page-scale-auto = Zoum emgefreek -pdfjs-page-scale-actual = Ment wir -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pajenn { $page } - -## Loading indicator messages - -pdfjs-loading-error = Degouezhet ez eus bet ur fazi e-pad kargañ ar PDF. -pdfjs-invalid-file-error = Restr PDF didalvoudek pe kontronet. -pdfjs-missing-file-error = Restr PDF o vankout. -pdfjs-unexpected-response-error = Respont dic'hortoz a-berzh an dafariad -pdfjs-rendering-error = Degouezhet ez eus bet ur fazi e-pad skrammañ ar bajennad. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Notennañ] - -## Password - -pdfjs-password-label = Enankit ar ger-tremen evit digeriñ ar restr PDF-mañ. -pdfjs-password-invalid = Ger-tremen didalvoudek. Klaskit en-dro mar plij. -pdfjs-password-ok-button = Mat eo -pdfjs-password-cancel-button = Nullañ -pdfjs-web-fonts-disabled = Diweredekaet eo an nodrezhoù web: n'haller ket arverañ an nodrezhoù PDF enframmet. - -## Editing - -pdfjs-editor-free-text-button = - .title = Testenn -pdfjs-editor-free-text-button-label = Testenn -pdfjs-editor-ink-button = - .title = Tresañ -pdfjs-editor-ink-button-label = Tresañ -pdfjs-editor-stamp-button = - .title = Ouzhpennañ pe aozañ skeudennoù -pdfjs-editor-stamp-button-label = Ouzhpennañ pe aozañ skeudennoù - -## Remove button for the various kind of editor. - - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Liv -pdfjs-editor-free-text-size-input = Ment -pdfjs-editor-ink-color-input = Liv -pdfjs-editor-ink-thickness-input = Tevder -pdfjs-editor-ink-opacity-input = Boullder -pdfjs-editor-stamp-add-image-button = - .title = Ouzhpennañ ur skeudenn -pdfjs-editor-stamp-add-image-button-label = Ouzhpennañ ur skeudenn -pdfjs-free-text = - .aria-label = Aozer testennoù -pdfjs-ink = - .aria-label = Aozer tresoù -pdfjs-ink-canvas = - .aria-label = Skeudenn bet krouet gant an implijer·ez - -## Alt-text dialog - -pdfjs-editor-alt-text-add-description-label = Ouzhpennañ un deskrivadur -pdfjs-editor-alt-text-cancel-button = Nullañ -pdfjs-editor-alt-text-save-button = Enrollañ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - - -## Color picker - - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - diff --git a/static/pdf.js/locale/br/viewer.properties b/static/pdf.js/locale/br/viewer.properties new file mode 100644 index 00000000..f9672277 --- /dev/null +++ b/static/pdf.js/locale/br/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Pajenn a-raok +previous_label=A-raok +next.title=Pajenn war-lerc'h +next_label=War-lerc'h + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pajenn : +page_of=eus {{pageCount}} + +zoom_out.title=Zoum bihanaat +zoom_out_label=Zoum bihanaat +zoom_in.title=Zoum brasaat +zoom_in_label=Zoum brasaat +zoom.title=Zoum +presentation_mode.title=Trec'haoliñ etrezek ar mod kinnigadenn +presentation_mode_label=Mod kinnigadenn +open_file.title=Digeriñ ur restr +open_file_label=Digeriñ ur restr +print.title=Moullañ +print_label=Moullañ +download.title=Pellgargañ +download_label=Pellgargañ +bookmark.title=Gwel bremanel (eilañ pe zigeriñ e-barzh ur prenestr nevez) +bookmark_label=Gwel bremanel + +# Secondary toolbar and context menu +tools.title=Ostilhoù +tools_label=Ostilhoù +first_page.title=Mont d'ar bajenn gentañ +first_page.label=Mont d'ar bajenn gentañ +first_page_label=Mont d'ar bajenn gentañ +last_page.title=Mont d'ar bajenn diwezhañ +last_page.label=Mont d'ar bajenn diwezhañ +last_page_label=Mont d'ar bajenn diwezhañ +page_rotate_cw.title=C'hwelañ gant roud ar bizied +page_rotate_cw.label=C'hwelañ gant roud ar bizied +page_rotate_cw_label=C'hwelañ gant roud ar bizied +page_rotate_ccw.title=C'hwelañ gant roud gin ar bizied +page_rotate_ccw.label=C'hwelañ gant roud gin ar bizied +page_rotate_ccw_label=C'hwelañ gant roud gin ar bizied + +hand_tool_enable.title=Gweredekaat an ostilh "dorn" +hand_tool_enable_label=Gweredekaat an ostilh "dorn" +hand_tool_disable.title=Diweredekaat an ostilh "dorn" +hand_tool_disable_label=Diweredekaat an ostilh "dorn" + +# Document properties dialog box +document_properties.title=Perzhioù an teul… +document_properties_label=Perzhioù an teul… +document_properties_file_name=Anv restr : +document_properties_file_size=Ment ar restr : +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} Ke ({{size_b}} eizhbit) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} Me ({{size_b}} eizhbit) +document_properties_title=Titl : +document_properties_author=Aozer : +document_properties_subject=Danvez : +document_properties_keywords=Gerioù-alc'hwez : +document_properties_creation_date=Deiziad krouiñ : +document_properties_modification_date=Deiziad kemmañ : +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Krouer : +document_properties_producer=Kenderc'her PDF : +document_properties_version=Handelv PDF : +document_properties_page_count=Niver a bajennoù : +document_properties_close=Serriñ + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Diskouez/kuzhat ar varrenn gostez +toggle_sidebar_label=Diskouez/kuzhat ar varrenn gostez +outline.title=Diskouez ar sinedoù +outline_label=Sinedoù an teuliad +attachments.title=Diskouez ar c'henstagadurioù +attachments_label=Kenstagadurioù +thumbs.title=Diskouez ar melvennoù +thumbs_label=Melvennoù +findbar.title=Klask e-barzh an teuliad +findbar_label=Klask + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pajenn {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Melvenn ar bajenn {{page}} + +# Find panel button title and messages +find_label=Kavout : +find_previous.title=Kavout an tamm frazenn kent o klotañ ganti +find_previous_label=Kent +find_next.title=Kavout an tamm frazenn war-lerc'h o klotañ ganti +find_next_label=War-lerc'h +find_highlight=Usskediñ pep tra +find_match_case_label=Teurel evezh ouzh ar pennlizherennoù +find_reached_top=Tizhet eo bet derou ar bajenn, kenderc'hel diouzh an diaz +find_reached_bottom=Tizhet eo bet dibenn ar bajenn, kenderc'hel diouzh ar c'hrec'h +find_not_found=N'haller ket kavout ar frazenn + +# Error panel labels +error_more_info=Muioc'h a ditouroù +error_less_info=Nebeutoc'h a ditouroù +error_close=Serriñ +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js handelv {{version}} (kempunadur : {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Kemennadenn : {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Torn : {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Restr : {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linenn : {{line}} +rendering_error=Degouezhet ez eus bet ur fazi e-pad skrammañ ar bajennad. + +# Predefined zoom values +page_scale_width=Led ar bajenn +page_scale_fit=Pajenn a-bezh +page_scale_auto=Zoum emgefreek +page_scale_actual=Ment wir +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Fazi +loading_error=Degouezhet ez eus bet ur fazi e-pad kargañ ar PDF. +invalid_file_error=Restr PDF didalvoudek pe kontronet. +missing_file_error=Restr PDF o vankout. +unexpected_response_error=Respont dic'hortoz a-berzh an dafariad + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Notennañ] +password_label=Enankit ar ger-tremen evit digeriñ ar restr PDF-mañ. +password_invalid=Ger-tremen didalvoudek. Klaskit en-dro mar plij. +password_ok=Mat eo +password_cancel=Nullañ + +printing_not_supported=Kemenn : N'eo ket skoret penn-da-benn ar moullañ gant ar merdeer-mañ. +printing_not_ready=Kemenn : N'hall ket bezañ moullet ar restr PDF rak n'eo ket karget penn-da-benn. +web_fonts_disabled=Diweredekaet eo an nodrezhoù web : n'haller ket arverañ an nodrezhoù PDF enframmet. +document_colors_not_allowed=N'eo ket aotreet an teuliadoù PDF da arverañ o livioù dezho : diweredekaet eo 'Aotren ar pajennoù da zibab o livioù dezho' e-barzh ar merdeer. diff --git a/static/pdf.js/locale/brx/viewer.ftl b/static/pdf.js/locale/brx/viewer.ftl deleted file mode 100644 index 53ff72c5..00000000 --- a/static/pdf.js/locale/brx/viewer.ftl +++ /dev/null @@ -1,218 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = आगोलनि बिलाइ -pdfjs-previous-button-label = आगोलनि -pdfjs-next-button = - .title = उननि बिलाइ -pdfjs-next-button-label = उननि -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = बिलाइ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } नि -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pagesCount } नि { $pageNumber }) -pdfjs-zoom-out-button = - .title = फिसायै जुम खालाम -pdfjs-zoom-out-button-label = फिसायै जुम खालाम -pdfjs-zoom-in-button = - .title = गेदेरै जुम खालाम -pdfjs-zoom-in-button-label = गेदेरै जुम खालाम -pdfjs-zoom-select = - .title = जुम खालाम -pdfjs-presentation-mode-button = - .title = दिन्थिफुंनाय म'डआव थां -pdfjs-presentation-mode-button-label = दिन्थिफुंनाय म'ड -pdfjs-open-file-button = - .title = फाइलखौ खेव -pdfjs-open-file-button-label = खेव -pdfjs-print-button = - .title = साफाय -pdfjs-print-button-label = साफाय - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = टुल -pdfjs-tools-button-label = टुल -pdfjs-first-page-button = - .title = गिबि बिलाइआव थां -pdfjs-first-page-button-label = गिबि बिलाइआव थां -pdfjs-last-page-button = - .title = जोबथा बिलाइआव थां -pdfjs-last-page-button-label = जोबथा बिलाइआव थां -pdfjs-page-rotate-cw-button = - .title = घरि गिदिंनाय फार्से फिदिं -pdfjs-page-rotate-cw-button-label = घरि गिदिंनाय फार्से फिदिं -pdfjs-page-rotate-ccw-button = - .title = घरि गिदिंनाय उल्था फार्से फिदिं -pdfjs-page-rotate-ccw-button-label = घरि गिदिंनाय उल्था फार्से फिदिं - -## Document properties dialog - -pdfjs-document-properties-button = - .title = फोरमान बिलाइनि आखुथाय... -pdfjs-document-properties-button-label = फोरमान बिलाइनि आखुथाय... -pdfjs-document-properties-file-name = फाइलनि मुं: -pdfjs-document-properties-file-size = फाइलनि महर: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } बाइट) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } बाइट) -pdfjs-document-properties-title = बिमुं: -pdfjs-document-properties-author = लिरगिरि: -pdfjs-document-properties-subject = आयदा: -pdfjs-document-properties-keywords = गाहाय सोदोब: -pdfjs-document-properties-creation-date = सोरजिनाय अक्ट': -pdfjs-document-properties-modification-date = सुद्रायनाय अक्ट': -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = सोरजिग्रा: -pdfjs-document-properties-producer = PDF दिहुनग्रा: -pdfjs-document-properties-version = PDF बिसान: -pdfjs-document-properties-page-count = बिलाइनि हिसाब: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = प'र्ट्रेट -pdfjs-document-properties-page-size-orientation-landscape = लेण्डस्केप -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = लायजाम - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-linearized-yes = नंगौ -pdfjs-document-properties-linearized-no = नङा -pdfjs-document-properties-close-button = बन्द खालाम - -## Print - -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = नेवसि -pdfjs-printing-not-supported = सांग्रांथि: साफायनाया बे ब्राउजारजों आबुङै हेफाजाब होजाया। -pdfjs-printing-not-ready = सांग्रांथि: PDF खौ साफायनायनि थाखाय फुरायै ल'ड खालामाखै। - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = टग्गल साइडबार -pdfjs-toggle-sidebar-button-label = टग्गल साइडबार -pdfjs-document-outline-button-label = फोरमान बिलाइ सिमा हांखो -pdfjs-attachments-button = - .title = नांजाब होनायखौ दिन्थि -pdfjs-attachments-button-label = नांजाब होनाय -pdfjs-thumbs-button = - .title = थामनेइलखौ दिन्थि -pdfjs-thumbs-button-label = थामनेइल -pdfjs-findbar-button = - .title = फोरमान बिलाइआव नागिरना दिहुन -pdfjs-findbar-button-label = नायगिरना दिहुन - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = बिलाइ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = बिलाइ { $page } नि थामनेइल - -## Find panel button title and messages - -pdfjs-find-input = - .title = नायगिरना दिहुन - .placeholder = फोरमान बिलाइआव नागिरना दिहुन... -pdfjs-find-previous-button = - .title = बाथ्रा खोन्दोबनि सिगांनि नुजाथिनायखौ नागिर -pdfjs-find-previous-button-label = आगोलनि -pdfjs-find-next-button = - .title = बाथ्रा खोन्दोबनि उननि नुजाथिनायखौ नागिर -pdfjs-find-next-button-label = उननि -pdfjs-find-highlight-checkbox = गासैखौबो हाइलाइट खालाम -pdfjs-find-match-case-checkbox-label = गोरोबनाय केस -pdfjs-find-reached-top = थालो निफ्राय जागायनानै फोरमान बिलाइनि बिजौआव सौहैबाय -pdfjs-find-reached-bottom = बिजौ निफ्राय जागायनानै फोरमान बिलाइनि बिजौआव सौहैबाय -pdfjs-find-not-found = बाथ्रा खोन्दोब मोनाखै - -## Predefined zoom values - -pdfjs-page-scale-width = बिलाइनि गुवार -pdfjs-page-scale-fit = बिलाइ गोरोबनाय -pdfjs-page-scale-auto = गावनोगाव जुम -pdfjs-page-scale-actual = थार महर -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF ल'ड खालामनाय समाव मोनसे गोरोन्थि जाबाय। -pdfjs-invalid-file-error = बाहायजायै एबा गाज्रि जानाय PDF फाइल -pdfjs-missing-file-error = गोमानाय PDF फाइल -pdfjs-unexpected-response-error = मिजिंथियै सार्भार फिननाय। -pdfjs-rendering-error = बिलाइखौ राव सोलायनाय समाव मोनसे गोरोन्थि जादों। - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } सोदोब बेखेवनाय] - -## Password - -pdfjs-password-label = बे PDF फाइलखौ खेवनो पासवार्ड हाबहो। -pdfjs-password-invalid = बाहायजायै पासवार्ड। अननानै फिन नाजा। -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = नेवसि -pdfjs-web-fonts-disabled = वेब फन्टखौ लोरबां खालामबाय: अरजाबहोनाय PDF फन्टखौ बाहायनो हायाखै। - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/bs/viewer.ftl b/static/pdf.js/locale/bs/viewer.ftl deleted file mode 100644 index 39440424..00000000 --- a/static/pdf.js/locale/bs/viewer.ftl +++ /dev/null @@ -1,223 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Prethodna strana -pdfjs-previous-button-label = Prethodna -pdfjs-next-button = - .title = Sljedeća strna -pdfjs-next-button-label = Sljedeća -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Strana -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = od { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } od { $pagesCount }) -pdfjs-zoom-out-button = - .title = Umanji -pdfjs-zoom-out-button-label = Umanji -pdfjs-zoom-in-button = - .title = Uvećaj -pdfjs-zoom-in-button-label = Uvećaj -pdfjs-zoom-select = - .title = Uvećanje -pdfjs-presentation-mode-button = - .title = Prebaci se u prezentacijski režim -pdfjs-presentation-mode-button-label = Prezentacijski režim -pdfjs-open-file-button = - .title = Otvori fajl -pdfjs-open-file-button-label = Otvori -pdfjs-print-button = - .title = Štampaj -pdfjs-print-button-label = Štampaj - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Alati -pdfjs-tools-button-label = Alati -pdfjs-first-page-button = - .title = Idi na prvu stranu -pdfjs-first-page-button-label = Idi na prvu stranu -pdfjs-last-page-button = - .title = Idi na zadnju stranu -pdfjs-last-page-button-label = Idi na zadnju stranu -pdfjs-page-rotate-cw-button = - .title = Rotiraj u smjeru kazaljke na satu -pdfjs-page-rotate-cw-button-label = Rotiraj u smjeru kazaljke na satu -pdfjs-page-rotate-ccw-button = - .title = Rotiraj suprotno smjeru kazaljke na satu -pdfjs-page-rotate-ccw-button-label = Rotiraj suprotno smjeru kazaljke na satu -pdfjs-cursor-text-select-tool-button = - .title = Omogući alat za označavanje teksta -pdfjs-cursor-text-select-tool-button-label = Alat za označavanje teksta -pdfjs-cursor-hand-tool-button = - .title = Omogući ručni alat -pdfjs-cursor-hand-tool-button-label = Ručni alat - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Svojstva dokumenta... -pdfjs-document-properties-button-label = Svojstva dokumenta... -pdfjs-document-properties-file-name = Naziv fajla: -pdfjs-document-properties-file-size = Veličina fajla: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bajta) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bajta) -pdfjs-document-properties-title = Naslov: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Predmet: -pdfjs-document-properties-keywords = Ključne riječi: -pdfjs-document-properties-creation-date = Datum kreiranja: -pdfjs-document-properties-modification-date = Datum promjene: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Kreator: -pdfjs-document-properties-producer = PDF stvaratelj: -pdfjs-document-properties-version = PDF verzija: -pdfjs-document-properties-page-count = Broj stranica: -pdfjs-document-properties-page-size = Veličina stranice: -pdfjs-document-properties-page-size-unit-inches = u -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = uspravno -pdfjs-document-properties-page-size-orientation-landscape = vodoravno -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Pismo -pdfjs-document-properties-page-size-name-legal = Pravni - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-close-button = Zatvori - -## Print - -pdfjs-print-progress-message = Pripremam dokument za štampu… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Otkaži -pdfjs-printing-not-supported = Upozorenje: Štampanje nije u potpunosti podržano u ovom browseru. -pdfjs-printing-not-ready = Upozorenje: PDF nije u potpunosti učitan za štampanje. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Uključi/isključi bočnu traku -pdfjs-toggle-sidebar-button-label = Uključi/isključi bočnu traku -pdfjs-document-outline-button = - .title = Prikaži outline dokumenta (dvoklik za skupljanje/širenje svih stavki) -pdfjs-document-outline-button-label = Konture dokumenta -pdfjs-attachments-button = - .title = Prikaži priloge -pdfjs-attachments-button-label = Prilozi -pdfjs-thumbs-button = - .title = Prikaži thumbnailove -pdfjs-thumbs-button-label = Thumbnailovi -pdfjs-findbar-button = - .title = Pronađi u dokumentu -pdfjs-findbar-button-label = Pronađi - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Strana { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Thumbnail strane { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Pronađi - .placeholder = Pronađi u dokumentu… -pdfjs-find-previous-button = - .title = Pronađi prethodno pojavljivanje fraze -pdfjs-find-previous-button-label = Prethodno -pdfjs-find-next-button = - .title = Pronađi sljedeće pojavljivanje fraze -pdfjs-find-next-button-label = Sljedeće -pdfjs-find-highlight-checkbox = Označi sve -pdfjs-find-match-case-checkbox-label = Osjetljivost na karaktere -pdfjs-find-reached-top = Dostigao sam vrh dokumenta, nastavljam sa dna -pdfjs-find-reached-bottom = Dostigao sam kraj dokumenta, nastavljam sa vrha -pdfjs-find-not-found = Fraza nije pronađena - -## Predefined zoom values - -pdfjs-page-scale-width = Širina strane -pdfjs-page-scale-fit = Uklopi stranu -pdfjs-page-scale-auto = Automatsko uvećanje -pdfjs-page-scale-actual = Stvarna veličina -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Došlo je do greške prilikom učitavanja PDF-a. -pdfjs-invalid-file-error = Neispravan ili oštećen PDF fajl. -pdfjs-missing-file-error = Nedostaje PDF fajl. -pdfjs-unexpected-response-error = Neočekivani odgovor servera. -pdfjs-rendering-error = Došlo je do greške prilikom renderiranja strane. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } pribilješka] - -## Password - -pdfjs-password-label = Upišite lozinku da biste otvorili ovaj PDF fajl. -pdfjs-password-invalid = Pogrešna lozinka. Pokušajte ponovo. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Otkaži -pdfjs-web-fonts-disabled = Web fontovi su onemogućeni: nemoguće koristiti ubačene PDF fontove. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/bs/viewer.properties b/static/pdf.js/locale/bs/viewer.properties new file mode 100644 index 00000000..ccc8bec8 --- /dev/null +++ b/static/pdf.js/locale/bs/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Prethodna strana +previous_label=Prethodna +next.title=Sljedeća strna +next_label=Sljedeća + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Strana: +page_of=od {{pageCount}} + +zoom_out.title=Umanji +zoom_out_label=Umanji +zoom_in.title=Uvećaj +zoom_in_label=Uvećaj +zoom.title=Uvećanje +presentation_mode.title=Prebaci se u prezentacijski režim +presentation_mode_label=Prezentacijski režim +open_file.title=Otvori fajl +open_file_label=Otvori +print.title=Štampaj +print_label=Štampaj +download.title=Preuzmi +download_label=Preuzmi +bookmark.title=Trenutni prikaz (kopiraj ili otvori u novom prozoru) +bookmark_label=Trenutni prikaz + +# Secondary toolbar and context menu +tools.title=Alati +tools_label=Alati +first_page.title=Idi na prvu stranu +first_page.label=Idi na prvu stranu +first_page_label=Idi na prvu stranu +last_page.title=Idi na zadnju stranu +last_page.label=Idi na zadnju stranu +last_page_label=Idi na zadnju stranu +page_rotate_cw.title=Rotiraj u smjeru kazaljke na satu +page_rotate_cw.label=Rotiraj u smjeru kazaljke na satu +page_rotate_cw_label=Rotiraj u smjeru kazaljke na satu +page_rotate_ccw.title=Rotiraj suprotno smjeru kazaljke na satu +page_rotate_ccw.label=Rotiraj suprotno smjeru kazaljke na satu +page_rotate_ccw_label=Rotiraj suprotno smjeru kazaljke na satu + +hand_tool_enable.title=Omogući ručni alat +hand_tool_enable_label=Omogući ručni alat +hand_tool_disable.title=Onemogući ručni alat +hand_tool_disable_label=Onemogući ručni alat + +# Document properties dialog box +document_properties.title=Svojstva dokumenta... +document_properties_label=Svojstva dokumenta... +document_properties_file_name=Naziv fajla: +document_properties_file_size=Veličina fajla: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bajta) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bajta) +document_properties_title=Naslov: +document_properties_author=Autor: +document_properties_subject=Predmet: +document_properties_keywords=Ključne riječi: +document_properties_creation_date=Datum kreiranja: +document_properties_modification_date=Datum promjene: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Kreator: +document_properties_producer=PDF stvaratelj: +document_properties_version=PDF verzija: +document_properties_page_count=Broj stranica: +document_properties_close=Zatvori + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Uključi/isključi bočnu traku +toggle_sidebar_label=Uključi/isključi bočnu traku +outline.title=Prikaži konture dokumenta +outline_label=Konture dokumenta +attachments.title=Prikaži priloge +attachments_label=Prilozi +thumbs.title=Prikaži thumbnailove +thumbs_label=Thumbnailovi +findbar.title=Pronađi u dokumentu +findbar_label=Pronađi + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Strana {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Thumbnail strane {{page}} + +# Find panel button title and messages +find_label=Pronađi: +find_previous.title=Pronađi prethodno pojavljivanje fraze +find_previous_label=Prethodno +find_next.title=Pronađi sljedeće pojavljivanje fraze +find_next_label=Sljedeće +find_highlight=Označi sve +find_match_case_label=Osjetljivost na karaktere +find_reached_top=Dostigao sam vrh dokumenta, nastavljam sa dna +find_reached_bottom=Dostigao sam kraj dokumenta, nastavljam sa vrha +find_not_found=Fraza nije pronađena + +# Error panel labels +error_more_info=Više informacija +error_less_info=Manje informacija +error_close=Zatvori +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Poruka: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fajl: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linija: {{line}} +rendering_error=Došlo je do greške prilikom renderiranja strane. + +# Predefined zoom values +page_scale_width=Širina strane +page_scale_fit=Uklopi stranu +page_scale_auto=Automatsko uvećanje +page_scale_actual=Stvarna veličina +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Greška +loading_error=Došlo je do greške prilikom učitavanja PDF-a. +invalid_file_error=Neispravan ili oštećen PDF fajl. +missing_file_error=Nedostaje PDF fajl. +unexpected_response_error=Neočekivani odgovor servera. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} pribilješka] +password_label=Upišite lozinku da biste otvorili ovaj PDF fajl. +password_invalid=Pogrešna lozinka. Pokušajte ponovo. +password_ok=OK +password_cancel=Otkaži + +printing_not_supported=Upozorenje: Štampanje nije u potpunosti podržano u ovom browseru. +printing_not_ready=Upozorenje: PDF nije u potpunosti učitan za štampanje. +web_fonts_disabled=Web fontovi su onemogućeni: nemoguće koristiti ubačene PDF fontove. +document_colors_not_allowed=PDF dokumentima nije dozvoljeno da koriste vlastite boje: 'Dozvoli stranicama da izaberu vlastite boje' je deaktivirano u browseru. diff --git a/static/pdf.js/locale/ca/viewer.ftl b/static/pdf.js/locale/ca/viewer.ftl deleted file mode 100644 index 575dc5fb..00000000 --- a/static/pdf.js/locale/ca/viewer.ftl +++ /dev/null @@ -1,299 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pàgina anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Pàgina següent -pdfjs-next-button-label = Següent -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pàgina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Redueix -pdfjs-zoom-out-button-label = Redueix -pdfjs-zoom-in-button = - .title = Amplia -pdfjs-zoom-in-button-label = Amplia -pdfjs-zoom-select = - .title = Escala -pdfjs-presentation-mode-button = - .title = Canvia al mode de presentació -pdfjs-presentation-mode-button-label = Mode de presentació -pdfjs-open-file-button = - .title = Obre el fitxer -pdfjs-open-file-button-label = Obre -pdfjs-print-button = - .title = Imprimeix -pdfjs-print-button-label = Imprimeix -pdfjs-save-button = - .title = Desa -pdfjs-save-button-label = Desa -pdfjs-bookmark-button = - .title = Pàgina actual (mostra l'URL de la pàgina actual) -pdfjs-bookmark-button-label = Pàgina actual -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Obre en una aplicació -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Obre en una aplicació - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Eines -pdfjs-tools-button-label = Eines -pdfjs-first-page-button = - .title = Vés a la primera pàgina -pdfjs-first-page-button-label = Vés a la primera pàgina -pdfjs-last-page-button = - .title = Vés a l'última pàgina -pdfjs-last-page-button-label = Vés a l'última pàgina -pdfjs-page-rotate-cw-button = - .title = Gira cap a la dreta -pdfjs-page-rotate-cw-button-label = Gira cap a la dreta -pdfjs-page-rotate-ccw-button = - .title = Gira cap a l'esquerra -pdfjs-page-rotate-ccw-button-label = Gira cap a l'esquerra -pdfjs-cursor-text-select-tool-button = - .title = Habilita l'eina de selecció de text -pdfjs-cursor-text-select-tool-button-label = Eina de selecció de text -pdfjs-cursor-hand-tool-button = - .title = Habilita l'eina de mà -pdfjs-cursor-hand-tool-button-label = Eina de mà -pdfjs-scroll-page-button = - .title = Usa el desplaçament de pàgina -pdfjs-scroll-page-button-label = Desplaçament de pàgina -pdfjs-scroll-vertical-button = - .title = Utilitza el desplaçament vertical -pdfjs-scroll-vertical-button-label = Desplaçament vertical -pdfjs-scroll-horizontal-button = - .title = Utilitza el desplaçament horitzontal -pdfjs-scroll-horizontal-button-label = Desplaçament horitzontal -pdfjs-scroll-wrapped-button = - .title = Activa el desplaçament continu -pdfjs-scroll-wrapped-button-label = Desplaçament continu -pdfjs-spread-none-button = - .title = No agrupis les pàgines de dues en dues -pdfjs-spread-none-button-label = Una sola pàgina -pdfjs-spread-odd-button = - .title = Mostra dues pàgines començant per les pàgines de numeració senar -pdfjs-spread-odd-button-label = Doble pàgina (senar) -pdfjs-spread-even-button = - .title = Mostra dues pàgines començant per les pàgines de numeració parell -pdfjs-spread-even-button-label = Doble pàgina (parell) - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propietats del document… -pdfjs-document-properties-button-label = Propietats del document… -pdfjs-document-properties-file-name = Nom del fitxer: -pdfjs-document-properties-file-size = Mida del fitxer: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Títol: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Assumpte: -pdfjs-document-properties-keywords = Paraules clau: -pdfjs-document-properties-creation-date = Data de creació: -pdfjs-document-properties-modification-date = Data de modificació: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creador: -pdfjs-document-properties-producer = Generador de PDF: -pdfjs-document-properties-version = Versió de PDF: -pdfjs-document-properties-page-count = Nombre de pàgines: -pdfjs-document-properties-page-size = Mida de la pàgina: -pdfjs-document-properties-page-size-unit-inches = polzades -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = apaïsat -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista web ràpida: -pdfjs-document-properties-linearized-yes = Sí -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Tanca - -## Print - -pdfjs-print-progress-message = S'està preparant la impressió del document… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancel·la -pdfjs-printing-not-supported = Avís: la impressió no és plenament funcional en aquest navegador. -pdfjs-printing-not-ready = Atenció: el PDF no s'ha acabat de carregar per imprimir-lo. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Mostra/amaga la barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Mostra/amaga la barra lateral (el document conté un esquema, adjuncions o capes) -pdfjs-toggle-sidebar-button-label = Mostra/amaga la barra lateral -pdfjs-document-outline-button = - .title = Mostra l'esquema del document (doble clic per ampliar/reduir tots els elements) -pdfjs-document-outline-button-label = Esquema del document -pdfjs-attachments-button = - .title = Mostra les adjuncions -pdfjs-attachments-button-label = Adjuncions -pdfjs-layers-button = - .title = Mostra les capes (doble clic per restablir totes les capes al seu estat per defecte) -pdfjs-layers-button-label = Capes -pdfjs-thumbs-button = - .title = Mostra les miniatures -pdfjs-thumbs-button-label = Miniatures -pdfjs-current-outline-item-button = - .title = Cerca l'element d'esquema actual -pdfjs-current-outline-item-button-label = Element d'esquema actual -pdfjs-findbar-button = - .title = Cerca al document -pdfjs-findbar-button-label = Cerca -pdfjs-additional-layers = Capes addicionals - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pàgina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura de la pàgina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Cerca - .placeholder = Cerca al document… -pdfjs-find-previous-button = - .title = Cerca l'anterior coincidència de l'expressió -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button = - .title = Cerca la següent coincidència de l'expressió -pdfjs-find-next-button-label = Següent -pdfjs-find-highlight-checkbox = Ressalta-ho tot -pdfjs-find-match-case-checkbox-label = Distingeix entre majúscules i minúscules -pdfjs-find-match-diacritics-checkbox-label = Respecta els diacrítics -pdfjs-find-entire-word-checkbox-label = Paraules senceres -pdfjs-find-reached-top = S'ha arribat al principi del document, es continua pel final -pdfjs-find-reached-bottom = S'ha arribat al final del document, es continua pel principi -pdfjs-find-not-found = No s'ha trobat l'expressió - -## Predefined zoom values - -pdfjs-page-scale-width = Amplada de la pàgina -pdfjs-page-scale-fit = Ajusta la pàgina -pdfjs-page-scale-auto = Zoom automàtic -pdfjs-page-scale-actual = Mida real -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pàgina { $page } - -## Loading indicator messages - -pdfjs-loading-error = S'ha produït un error en carregar el PDF. -pdfjs-invalid-file-error = El fitxer PDF no és vàlid o està malmès. -pdfjs-missing-file-error = Falta el fitxer PDF. -pdfjs-unexpected-response-error = Resposta inesperada del servidor. -pdfjs-rendering-error = S'ha produït un error mentre es renderitzava la pàgina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotació { $type }] - -## Password - -pdfjs-password-label = Introduïu la contrasenya per obrir aquest fitxer PDF. -pdfjs-password-invalid = La contrasenya no és vàlida. Torneu-ho a provar. -pdfjs-password-ok-button = D'acord -pdfjs-password-cancel-button = Cancel·la -pdfjs-web-fonts-disabled = Els tipus de lletra web estan desactivats: no es poden utilitzar els tipus de lletra incrustats al PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Dibuixa -pdfjs-editor-ink-button-label = Dibuixa -# Editor Parameters -pdfjs-editor-free-text-color-input = Color -pdfjs-editor-free-text-size-input = Mida -pdfjs-editor-ink-color-input = Color -pdfjs-editor-ink-thickness-input = Gruix -pdfjs-editor-ink-opacity-input = Opacitat -pdfjs-free-text = - .aria-label = Editor de text -pdfjs-free-text-default-content = Escriviu… -pdfjs-ink = - .aria-label = Editor de dibuix -pdfjs-ink-canvas = - .aria-label = Imatge creada per l'usuari - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ca/viewer.properties b/static/pdf.js/locale/ca/viewer.properties new file mode 100644 index 00000000..6b85bb1b --- /dev/null +++ b/static/pdf.js/locale/ca/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Pàgina anterior +previous_label=Anterior +next.title=Pàgina següent +next_label=Següent + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pàgina: +page_of=de {{pageCount}} + +zoom_out.title=Allunya +zoom_out_label=Allunya +zoom_in.title=Apropa +zoom_in_label=Apropa +zoom.title=Escala +presentation_mode.title=Canvia al mode de presentació +presentation_mode_label=Mode de presentació +open_file.title=Obre el fitxer +open_file_label=Obre +print.title=Imprimeix +print_label=Imprimeix +download.title=Baixa +download_label=Baixa +bookmark.title=Vista actual (copia o obre en una finestra nova) +bookmark_label=Vista actual + +# Secondary toolbar and context menu +tools.title=Eines +tools_label=Eines +first_page.title=Vés a la primera pàgina +first_page.label=Vés a la primera pàgina +first_page_label=Vés a la primera pàgina +last_page.title=Vés a l'última pàgina +last_page.label=Vés a l'última pàgina +last_page_label=Vés a l'última pàgina +page_rotate_cw.title=Gira cap a la dreta +page_rotate_cw.label=Gira cap a la dreta +page_rotate_cw_label=Gira cap a la dreta +page_rotate_ccw.title=Gira cap a l'esquerra +page_rotate_ccw.label=Gira cap a l'esquerra +page_rotate_ccw_label=Gira cap a l'esquerra + +hand_tool_enable.title=Habilita l'eina de mà +hand_tool_enable_label=Habilita l'eina de mà +hand_tool_disable.title=Inhabilita l'eina de mà +hand_tool_disable_label=Inhabilita l'eina de mà + +# Document properties dialog box +document_properties.title=Propietats del document… +document_properties_label=Propietats del document… +document_properties_file_name=Nom del fitxer: +document_properties_file_size=Mida del fitxer: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Títol: +document_properties_author=Autor: +document_properties_subject=Assumpte: +document_properties_keywords=Paraules clau: +document_properties_creation_date=Data de creació: +document_properties_modification_date=Data de modificació: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creador: +document_properties_producer=Generador de PDF: +document_properties_version=Versió de PDF: +document_properties_page_count=Nombre de pàgines: +document_properties_close=Tanca + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Mostra/amaga la barra lateral +toggle_sidebar_label=Mostra/amaga la barra lateral +outline.title=Mostra el contorn del document +outline_label=Contorn del document +attachments.title=Mostra les adjuncions +attachments_label=Adjuncions +thumbs.title=Mostra les miniatures +thumbs_label=Miniatures +findbar.title=Cerca al document +findbar_label=Cerca + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pàgina {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura de la pàgina {{page}} + +# Find panel button title and messages +find_label=Cerca: +find_previous.title=Cerca l'anterior coincidència de l'expressió +find_previous_label=Anterior +find_next.title=Cerca la següent coincidència de l'expressió +find_next_label=Següent +find_highlight=Ressalta-ho tot +find_match_case_label=Distingeix entre majúscules i minúscules +find_reached_top=S'ha arribat al principi del document, es continua pel final +find_reached_bottom=S'ha arribat al final del document, es continua pel principi +find_not_found=No s'ha trobat l'expressió + +# Error panel labels +error_more_info=Més informació +error_less_info=Menys informació +error_close=Tanca +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (muntatge: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Missatge: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pila: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fitxer: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Línia: {{line}} +rendering_error=S'ha produït un error mentre es renderitzava la pàgina. + +# Predefined zoom values +page_scale_width=Amplària de la pàgina +page_scale_fit=Ajusta la pàgina +page_scale_auto=Zoom automàtic +page_scale_actual=Mida real +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Error +loading_error=S'ha produït un error en carregar el PDF. +invalid_file_error=El fitxer PDF no és vàlid o està malmès. +missing_file_error=Falta el fitxer PDF. +unexpected_response_error=Resposta inesperada del servidor. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotació {{type}}] +password_label=Introduïu la contrasenya per obrir aquest fitxer PDF. +password_invalid=La contrasenya no és vàlida. Torneu-ho a provar. +password_ok=D'acord +password_cancel=Cancel·la + +printing_not_supported=Avís: la impressió no és plenament funcional en aquest navegador. +printing_not_ready=Atenció: el PDF no s'ha acabat de carregar per imprimir-lo. +web_fonts_disabled=Les fonts web estan inhabilitades: no es poden incrustar fitxers PDF. +document_colors_not_allowed=Els documents PDF no poden usar els seus colors propis: «Permet a les pàgines triar els colors propis» es troba desactivat al navegador. diff --git a/static/pdf.js/locale/cak/viewer.ftl b/static/pdf.js/locale/cak/viewer.ftl deleted file mode 100644 index f40c1e92..00000000 --- a/static/pdf.js/locale/cak/viewer.ftl +++ /dev/null @@ -1,291 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Jun kan ruxaq -pdfjs-previous-button-label = Jun kan -pdfjs-next-button = - .title = Jun chik ruxaq -pdfjs-next-button-label = Jun chik -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Ruxaq -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = richin { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } richin { $pagesCount }) -pdfjs-zoom-out-button = - .title = Tich'utinirisäx -pdfjs-zoom-out-button-label = Tich'utinirisäx -pdfjs-zoom-in-button = - .title = Tinimirisäx -pdfjs-zoom-in-button-label = Tinimirisäx -pdfjs-zoom-select = - .title = Sum -pdfjs-presentation-mode-button = - .title = Tijal ri rub'anikil niwachin -pdfjs-presentation-mode-button-label = Pa rub'eyal niwachin -pdfjs-open-file-button = - .title = Tijaq Yakb'äl -pdfjs-open-file-button-label = Tijaq -pdfjs-print-button = - .title = Titz'ajb'äx -pdfjs-print-button-label = Titz'ajb'äx -pdfjs-save-button = - .title = Tiyak -pdfjs-save-button-label = Tiyak -pdfjs-bookmark-button-label = Ruxaq k'o wakami - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Samajib'äl -pdfjs-tools-button-label = Samajib'äl -pdfjs-first-page-button = - .title = Tib'e pa nab'ey ruxaq -pdfjs-first-page-button-label = Tib'e pa nab'ey ruxaq -pdfjs-last-page-button = - .title = Tib'e pa ruk'isib'äl ruxaq -pdfjs-last-page-button-label = Tib'e pa ruk'isib'äl ruxaq -pdfjs-page-rotate-cw-button = - .title = Tisutïx pan ajkiq'a' -pdfjs-page-rotate-cw-button-label = Tisutïx pan ajkiq'a' -pdfjs-page-rotate-ccw-button = - .title = Tisutïx pan ajxokon -pdfjs-page-rotate-ccw-button-label = Tisutïx pan ajxokon -pdfjs-cursor-text-select-tool-button = - .title = Titzij ri rusamajib'al Rucha'ik Rucholajem Tzij -pdfjs-cursor-text-select-tool-button-label = Rusamajib'al Rucha'ik Rucholajem Tzij -pdfjs-cursor-hand-tool-button = - .title = Titzij ri q'ab'aj samajib'äl -pdfjs-cursor-hand-tool-button-label = Q'ab'aj Samajib'äl -pdfjs-scroll-page-button = - .title = Tokisäx Ruxaq Q'axanem -pdfjs-scroll-page-button-label = Ruxaq Q'axanem -pdfjs-scroll-vertical-button = - .title = Tokisäx Pa'äl Q'axanem -pdfjs-scroll-vertical-button-label = Pa'äl Q'axanem -pdfjs-scroll-horizontal-button = - .title = Tokisäx Kotz'öl Q'axanem -pdfjs-scroll-horizontal-button-label = Kotz'öl Q'axanem -pdfjs-scroll-wrapped-button = - .title = Tokisäx Tzub'aj Q'axanem -pdfjs-scroll-wrapped-button-label = Tzub'aj Q'axanem -pdfjs-spread-none-button = - .title = Man ketun taq ruxaq pa rub'eyal wuj -pdfjs-spread-none-button-label = Majun Rub'eyal -pdfjs-spread-odd-button = - .title = Ke'atunu' ri taq ruxaq rik'in natikirisaj rik'in jun man k'ulaj ta rajilab'al -pdfjs-spread-odd-button-label = Man K'ulaj Ta Rub'eyal -pdfjs-spread-even-button = - .title = Ke'atunu' ri taq ruxaq rik'in natikirisaj rik'in jun k'ulaj rajilab'al -pdfjs-spread-even-button-label = K'ulaj Rub'eyal - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Taq richinil wuj… -pdfjs-document-properties-button-label = Taq richinil wuj… -pdfjs-document-properties-file-name = Rub'i' yakb'äl: -pdfjs-document-properties-file-size = Runimilem yakb'äl: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = B'i'aj: -pdfjs-document-properties-author = B'anel: -pdfjs-document-properties-subject = Taqikil: -pdfjs-document-properties-keywords = Kixe'el taq tzij: -pdfjs-document-properties-creation-date = Ruq'ijul xtz'uk: -pdfjs-document-properties-modification-date = Ruq'ijul xjalwachïx: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Q'inonel: -pdfjs-document-properties-producer = PDF b'anöy: -pdfjs-document-properties-version = PDF ruwäch: -pdfjs-document-properties-page-count = Jarupe' ruxaq: -pdfjs-document-properties-page-size = Runimilem ri Ruxaq: -pdfjs-document-properties-page-size-unit-inches = pa -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = rupalem -pdfjs-document-properties-page-size-orientation-landscape = rukotz'olem -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Loman wuj -pdfjs-document-properties-page-size-name-legal = Taqanel tzijol - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Anin Rutz'etik Ajk'amaya'l: -pdfjs-document-properties-linearized-yes = Ja' -pdfjs-document-properties-linearized-no = Mani -pdfjs-document-properties-close-button = Titz'apïx - -## Print - -pdfjs-print-progress-message = Ruchojmirisaxik wuj richin nitz'ajb'äx… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Tiq'at -pdfjs-printing-not-supported = Rutzijol k'ayewal: Ri rutz'ajb'axik man koch'el ta ronojel pa re okik'amaya'l re'. -pdfjs-printing-not-ready = Rutzijol k'ayewal: Ri PDF man xusamajij ta ronojel richin nitz'ajb'äx. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Tijal ri ajxikin kajtz'ik -pdfjs-toggle-sidebar-notification-button = - .title = Tik'ex ri ajxikin yuqkajtz'ik (ri wuj eruk'wan taq ruchi'/taqo/kuchuj) -pdfjs-toggle-sidebar-button-label = Tijal ri ajxikin kajtz'ik -pdfjs-document-outline-button = - .title = Tik'ut pe ruch'akulal wuj (kamul-pitz'oj richin nirik'/nich'utinirisäx ronojel ruch'akulal) -pdfjs-document-outline-button-label = Ruch'akulal wuj -pdfjs-attachments-button = - .title = Kek'ut pe ri taq taqoj -pdfjs-attachments-button-label = Taq taqoj -pdfjs-layers-button = - .title = Kek'ut taq Kuchuj (ka'i'-pitz' richin yetzolïx ronojel ri taq kuchuj e k'o wi) -pdfjs-layers-button-label = Taq kuchuj -pdfjs-thumbs-button = - .title = Kek'ut pe taq ch'utiq -pdfjs-thumbs-button-label = Koköj -pdfjs-current-outline-item-button = - .title = Kekanöx Taq Ch'akulal Kik'wan Chib'äl -pdfjs-current-outline-item-button-label = Taq Ch'akulal Kik'wan Chib'äl -pdfjs-findbar-button = - .title = Tikanöx chupam ri wuj -pdfjs-findbar-button-label = Tikanöx -pdfjs-additional-layers = Tz'aqat ta Kuchuj - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Ruxaq { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Ruch'utinirisaxik ruxaq { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Tikanöx - .placeholder = Tikanöx pa wuj… -pdfjs-find-previous-button = - .title = Tib'an b'enam pa ri jun kan q'aptzij xilitäj -pdfjs-find-previous-button-label = Jun kan -pdfjs-find-next-button = - .title = Tib'e pa ri jun chik pajtzij xilitäj -pdfjs-find-next-button-label = Jun chik -pdfjs-find-highlight-checkbox = Tiya' retal ronojel -pdfjs-find-match-case-checkbox-label = Tuk'äm ri' kik'in taq nimatz'ib' chuqa' taq ch'utitz'ib' -pdfjs-find-match-diacritics-checkbox-label = Tiya' Kikojol Tz'aqat taq Tz'ib' -pdfjs-find-entire-word-checkbox-label = Tz'aqät taq tzij -pdfjs-find-reached-top = Xb'eq'i' ri rutikirib'al wuj, xtikanöx k'a pa ruk'isib'äl -pdfjs-find-reached-bottom = Xb'eq'i' ri ruk'isib'äl wuj, xtikanöx pa rutikirib'al -pdfjs-find-not-found = Man xilitäj ta ri pajtzij - -## Predefined zoom values - -pdfjs-page-scale-width = Ruwa ruxaq -pdfjs-page-scale-fit = Tinuk' ruxaq -pdfjs-page-scale-auto = Yonil chi nimilem -pdfjs-page-scale-actual = Runimilem Wakami -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Ruxaq { $page } - -## Loading indicator messages - -pdfjs-loading-error = Xk'ulwachitäj jun sach'oj toq xnuk'ux ri PDF . -pdfjs-invalid-file-error = Man oke ta o yujtajinäq ri PDF yakb'äl. -pdfjs-missing-file-error = Man xilitäj ta ri PDF yakb'äl. -pdfjs-unexpected-response-error = Man oyob'en ta tz'olin rutzij ruk'u'x samaj. -pdfjs-rendering-error = Xk'ulwachitäj jun sachoj toq ninuk'wachij ri ruxaq. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Tz'ib'anïk] - -## Password - -pdfjs-password-label = Tatz'ib'aj ri ewan tzij richin najäq re yakb'äl re' pa PDF. -pdfjs-password-invalid = Man okel ta ri ewan tzij: Tatojtob'ej chik. -pdfjs-password-ok-button = Ütz -pdfjs-password-cancel-button = Tiq'at -pdfjs-web-fonts-disabled = E chupül ri taq ajk'amaya'l tz'ib': man tikirel ta nokisäx ri taq tz'ib' PDF pa ch'ikenïk - -## Editing - -pdfjs-editor-free-text-button = - .title = Rucholajem tz'ib' -pdfjs-editor-free-text-button-label = Rucholajem tz'ib' -pdfjs-editor-ink-button = - .title = Tiwachib'ëx -pdfjs-editor-ink-button-label = Tiwachib'ëx -# Editor Parameters -pdfjs-editor-free-text-color-input = B'onil -pdfjs-editor-free-text-size-input = Nimilem -pdfjs-editor-ink-color-input = B'onil -pdfjs-editor-ink-thickness-input = Rupimil -pdfjs-editor-ink-opacity-input = Q'equmal -pdfjs-free-text = - .aria-label = Nuk'unel tz'ib'atzij -pdfjs-free-text-default-content = Titikitisäx rutz'ib'axik… -pdfjs-ink = - .aria-label = Nuk'unel wachib'äl -pdfjs-ink-canvas = - .aria-label = Wachib'äl nuk'un ruma okisaxel - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ckb/viewer.ftl b/static/pdf.js/locale/ckb/viewer.ftl deleted file mode 100644 index ae87335b..00000000 --- a/static/pdf.js/locale/ckb/viewer.ftl +++ /dev/null @@ -1,242 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = پەڕەی پێشوو -pdfjs-previous-button-label = پێشوو -pdfjs-next-button = - .title = پەڕەی دوواتر -pdfjs-next-button-label = دوواتر -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = پەرە -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = لە { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } لە { $pagesCount }) -pdfjs-zoom-out-button = - .title = ڕۆچوونی -pdfjs-zoom-out-button-label = ڕۆچوونی -pdfjs-zoom-in-button = - .title = هێنانەپێش -pdfjs-zoom-in-button-label = هێنانەپێش -pdfjs-zoom-select = - .title = زووم -pdfjs-presentation-mode-button = - .title = گۆڕین بۆ دۆخی پێشکەشکردن -pdfjs-presentation-mode-button-label = دۆخی پێشکەشکردن -pdfjs-open-file-button = - .title = پەڕگە بکەرەوە -pdfjs-open-file-button-label = کردنەوە -pdfjs-print-button = - .title = چاپکردن -pdfjs-print-button-label = چاپکردن - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ئامرازەکان -pdfjs-tools-button-label = ئامرازەکان -pdfjs-first-page-button = - .title = برۆ بۆ یەکەم پەڕە -pdfjs-first-page-button-label = بڕۆ بۆ یەکەم پەڕە -pdfjs-last-page-button = - .title = بڕۆ بۆ کۆتا پەڕە -pdfjs-last-page-button-label = بڕۆ بۆ کۆتا پەڕە -pdfjs-page-rotate-cw-button = - .title = ئاڕاستەی میلی کاتژمێر -pdfjs-page-rotate-cw-button-label = ئاڕاستەی میلی کاتژمێر -pdfjs-page-rotate-ccw-button = - .title = پێچەوانەی میلی کاتژمێر -pdfjs-page-rotate-ccw-button-label = پێچەوانەی میلی کاتژمێر -pdfjs-cursor-text-select-tool-button = - .title = توڵامرازی نیشانکەری دەق چالاک بکە -pdfjs-cursor-text-select-tool-button-label = توڵامرازی نیشانکەری دەق -pdfjs-cursor-hand-tool-button = - .title = توڵامرازی دەستی چالاک بکە -pdfjs-cursor-hand-tool-button-label = توڵامرازی دەستی -pdfjs-scroll-vertical-button = - .title = ناردنی ئەستوونی بەکاربێنە -pdfjs-scroll-vertical-button-label = ناردنی ئەستوونی -pdfjs-scroll-horizontal-button = - .title = ناردنی ئاسۆیی بەکاربێنە -pdfjs-scroll-horizontal-button-label = ناردنی ئاسۆیی -pdfjs-scroll-wrapped-button = - .title = ناردنی لوولکراو بەکاربێنە -pdfjs-scroll-wrapped-button-label = ناردنی لوولکراو - -## Document properties dialog - -pdfjs-document-properties-button = - .title = تایبەتمەندییەکانی بەڵگەنامە... -pdfjs-document-properties-button-label = تایبەتمەندییەکانی بەڵگەنامە... -pdfjs-document-properties-file-name = ناوی پەڕگە: -pdfjs-document-properties-file-size = قەبارەی پەڕگە: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } کب ({ $size_b } بایت) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } مب ({ $size_b } بایت) -pdfjs-document-properties-title = سەردێڕ: -pdfjs-document-properties-author = نووسەر -pdfjs-document-properties-subject = بابەت: -pdfjs-document-properties-keywords = کلیلەوشە: -pdfjs-document-properties-creation-date = بەرواری درووستکردن: -pdfjs-document-properties-modification-date = بەرواری دەستکاریکردن: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = درووستکەر: -pdfjs-document-properties-producer = بەرهەمهێنەری PDF: -pdfjs-document-properties-version = وەشانی PDF: -pdfjs-document-properties-page-count = ژمارەی پەرەکان: -pdfjs-document-properties-page-size = قەبارەی پەڕە: -pdfjs-document-properties-page-size-unit-inches = ئینچ -pdfjs-document-properties-page-size-unit-millimeters = ملم -pdfjs-document-properties-page-size-orientation-portrait = پۆرترەیت(درێژ) -pdfjs-document-properties-page-size-orientation-landscape = پانیی -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = نامە -pdfjs-document-properties-page-size-name-legal = یاسایی - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = پیشاندانی وێبی خێرا: -pdfjs-document-properties-linearized-yes = بەڵێ -pdfjs-document-properties-linearized-no = نەخێر -pdfjs-document-properties-close-button = داخستن - -## Print - -pdfjs-print-progress-message = بەڵگەنامە ئامادەدەکرێت بۆ چاپکردن... -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = پاشگەزبوونەوە -pdfjs-printing-not-supported = ئاگاداربە: چاپکردن بە تەواوی پشتگیر ناکرێت لەم وێبگەڕە. -pdfjs-printing-not-ready = ئاگاداربە: PDF بە تەواوی بارنەبووە بۆ چاپکردن. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = لاتەنیشت پیشاندان/شاردنەوە -pdfjs-toggle-sidebar-button-label = لاتەنیشت پیشاندان/شاردنەوە -pdfjs-document-outline-button-label = سنووری چوارچێوە -pdfjs-attachments-button = - .title = پاشکۆکان پیشان بدە -pdfjs-attachments-button-label = پاشکۆکان -pdfjs-layers-button-label = چینەکان -pdfjs-thumbs-button = - .title = وێنۆچکە پیشان بدە -pdfjs-thumbs-button-label = وێنۆچکە -pdfjs-findbar-button = - .title = لە بەڵگەنامە بگەرێ -pdfjs-findbar-button-label = دۆزینەوە -pdfjs-additional-layers = چینی زیاتر - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = پەڕەی { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = وێنۆچکەی پەڕەی { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = دۆزینەوە - .placeholder = لە بەڵگەنامە بگەرێ... -pdfjs-find-previous-button = - .title = هەبوونی پێشوو بدۆزرەوە لە ڕستەکەدا -pdfjs-find-previous-button-label = پێشوو -pdfjs-find-next-button = - .title = هەبوونی داهاتوو بدۆزەرەوە لە ڕستەکەدا -pdfjs-find-next-button-label = دوواتر -pdfjs-find-highlight-checkbox = هەمووی نیشانە بکە -pdfjs-find-match-case-checkbox-label = دۆخی لەیەکچوون -pdfjs-find-entire-word-checkbox-label = هەموو وشەکان -pdfjs-find-reached-top = گەشتیتە سەرەوەی بەڵگەنامە، لە خوارەوە دەستت پێکرد -pdfjs-find-reached-bottom = گەشتیتە کۆتایی بەڵگەنامە. لەسەرەوە دەستت پێکرد -pdfjs-find-not-found = نووسین نەدۆزرایەوە - -## Predefined zoom values - -pdfjs-page-scale-width = پانی پەڕە -pdfjs-page-scale-fit = پڕبوونی پەڕە -pdfjs-page-scale-auto = زوومی خۆکار -pdfjs-page-scale-actual = قەبارەی ڕاستی -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = هەڵەیەک ڕوویدا لە کاتی بارکردنی PDF. -pdfjs-invalid-file-error = پەڕگەی pdf تێکچووە یان نەگونجاوە. -pdfjs-missing-file-error = پەڕگەی pdf بوونی نیە. -pdfjs-unexpected-response-error = وەڵامی ڕاژەخوازی نەخوازراو. -pdfjs-rendering-error = هەڵەیەک ڕوویدا لە کاتی پوختەکردنی (ڕێندەر) پەڕە. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } سەرنج] - -## Password - -pdfjs-password-label = وشەی تێپەڕ بنووسە بۆ کردنەوەی پەڕگەی pdf. -pdfjs-password-invalid = وشەی تێپەڕ هەڵەیە. تکایە دووبارە هەوڵ بدەرەوە. -pdfjs-password-ok-button = باشە -pdfjs-password-cancel-button = پاشگەزبوونەوە -pdfjs-web-fonts-disabled = جۆرەپیتی وێب ناچالاکە: نەتوانی جۆرەپیتی تێخراوی ناو pdfـەکە بەکاربێت. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/cs/viewer.ftl b/static/pdf.js/locale/cs/viewer.ftl deleted file mode 100644 index b05761b0..00000000 --- a/static/pdf.js/locale/cs/viewer.ftl +++ /dev/null @@ -1,406 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Přejde na předchozí stránku -pdfjs-previous-button-label = Předchozí -pdfjs-next-button = - .title = Přejde na následující stránku -pdfjs-next-button-label = Další -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Stránka -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = z { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } z { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zmenší velikost -pdfjs-zoom-out-button-label = Zmenšit -pdfjs-zoom-in-button = - .title = Zvětší velikost -pdfjs-zoom-in-button-label = Zvětšit -pdfjs-zoom-select = - .title = Nastaví velikost -pdfjs-presentation-mode-button = - .title = Přepne do režimu prezentace -pdfjs-presentation-mode-button-label = Režim prezentace -pdfjs-open-file-button = - .title = Otevře soubor -pdfjs-open-file-button-label = Otevřít -pdfjs-print-button = - .title = Vytiskne dokument -pdfjs-print-button-label = Vytisknout -pdfjs-save-button = - .title = Uložit -pdfjs-save-button-label = Uložit -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Stáhnout -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Stáhnout -pdfjs-bookmark-button = - .title = Aktuální stránka (zobrazit URL od aktuální stránky) -pdfjs-bookmark-button-label = Aktuální stránka -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Otevřít v aplikaci -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Otevřít v aplikaci - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Nástroje -pdfjs-tools-button-label = Nástroje -pdfjs-first-page-button = - .title = Přejde na první stránku -pdfjs-first-page-button-label = Přejít na první stránku -pdfjs-last-page-button = - .title = Přejde na poslední stránku -pdfjs-last-page-button-label = Přejít na poslední stránku -pdfjs-page-rotate-cw-button = - .title = Otočí po směru hodin -pdfjs-page-rotate-cw-button-label = Otočit po směru hodin -pdfjs-page-rotate-ccw-button = - .title = Otočí proti směru hodin -pdfjs-page-rotate-ccw-button-label = Otočit proti směru hodin -pdfjs-cursor-text-select-tool-button = - .title = Povolí výběr textu -pdfjs-cursor-text-select-tool-button-label = Výběr textu -pdfjs-cursor-hand-tool-button = - .title = Povolí nástroj ručička -pdfjs-cursor-hand-tool-button-label = Nástroj ručička -pdfjs-scroll-page-button = - .title = Posouvat po stránkách -pdfjs-scroll-page-button-label = Posouvání po stránkách -pdfjs-scroll-vertical-button = - .title = Použít svislé posouvání -pdfjs-scroll-vertical-button-label = Svislé posouvání -pdfjs-scroll-horizontal-button = - .title = Použít vodorovné posouvání -pdfjs-scroll-horizontal-button-label = Vodorovné posouvání -pdfjs-scroll-wrapped-button = - .title = Použít postupné posouvání -pdfjs-scroll-wrapped-button-label = Postupné posouvání -pdfjs-spread-none-button = - .title = Nesdružovat stránky -pdfjs-spread-none-button-label = Žádné sdružení -pdfjs-spread-odd-button = - .title = Sdruží stránky s umístěním lichých vlevo -pdfjs-spread-odd-button-label = Sdružení stránek (liché vlevo) -pdfjs-spread-even-button = - .title = Sdruží stránky s umístěním sudých vlevo -pdfjs-spread-even-button-label = Sdružení stránek (sudé vlevo) - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Vlastnosti dokumentu… -pdfjs-document-properties-button-label = Vlastnosti dokumentu… -pdfjs-document-properties-file-name = Název souboru: -pdfjs-document-properties-file-size = Velikost souboru: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bajtů) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bajtů) -pdfjs-document-properties-title = Název stránky: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Předmět: -pdfjs-document-properties-keywords = Klíčová slova: -pdfjs-document-properties-creation-date = Datum vytvoření: -pdfjs-document-properties-modification-date = Datum úpravy: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Vytvořil: -pdfjs-document-properties-producer = Tvůrce PDF: -pdfjs-document-properties-version = Verze PDF: -pdfjs-document-properties-page-count = Počet stránek: -pdfjs-document-properties-page-size = Velikost stránky: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = na výšku -pdfjs-document-properties-page-size-orientation-landscape = na šířku -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Dopis -pdfjs-document-properties-page-size-name-legal = Právní dokument - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Rychlé zobrazování z webu: -pdfjs-document-properties-linearized-yes = Ano -pdfjs-document-properties-linearized-no = Ne -pdfjs-document-properties-close-button = Zavřít - -## Print - -pdfjs-print-progress-message = Příprava dokumentu pro tisk… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress } % -pdfjs-print-progress-close-button = Zrušit -pdfjs-printing-not-supported = Upozornění: Tisk není v tomto prohlížeči plně podporován. -pdfjs-printing-not-ready = Upozornění: Dokument PDF není kompletně načten. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Postranní lišta -pdfjs-toggle-sidebar-notification-button = - .title = Přepnout postranní lištu (dokument obsahuje osnovu/přílohy/vrstvy) -pdfjs-toggle-sidebar-button-label = Postranní lišta -pdfjs-document-outline-button = - .title = Zobrazí osnovu dokumentu (poklepání přepne zobrazení všech položek) -pdfjs-document-outline-button-label = Osnova dokumentu -pdfjs-attachments-button = - .title = Zobrazí přílohy -pdfjs-attachments-button-label = Přílohy -pdfjs-layers-button = - .title = Zobrazit vrstvy (poklepáním obnovíte všechny vrstvy do výchozího stavu) -pdfjs-layers-button-label = Vrstvy -pdfjs-thumbs-button = - .title = Zobrazí náhledy -pdfjs-thumbs-button-label = Náhledy -pdfjs-current-outline-item-button = - .title = Najít aktuální položku v osnově -pdfjs-current-outline-item-button-label = Aktuální položka v osnově -pdfjs-findbar-button = - .title = Najde v dokumentu -pdfjs-findbar-button-label = Najít -pdfjs-additional-layers = Další vrstvy - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Strana { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Náhled strany { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Najít - .placeholder = Najít v dokumentu… -pdfjs-find-previous-button = - .title = Najde předchozí výskyt hledaného textu -pdfjs-find-previous-button-label = Předchozí -pdfjs-find-next-button = - .title = Najde další výskyt hledaného textu -pdfjs-find-next-button-label = Další -pdfjs-find-highlight-checkbox = Zvýraznit -pdfjs-find-match-case-checkbox-label = Rozlišovat velikost -pdfjs-find-match-diacritics-checkbox-label = Rozlišovat diakritiku -pdfjs-find-entire-word-checkbox-label = Celá slova -pdfjs-find-reached-top = Dosažen začátek dokumentu, pokračuje se od konce -pdfjs-find-reached-bottom = Dosažen konec dokumentu, pokračuje se od začátku -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current }. z { $total } výskytu - [few] { $current }. z { $total } výskytů - [many] { $current }. z { $total } výskytů - *[other] { $current }. z { $total } výskytů - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Více než { $limit } výskyt - [few] Více než { $limit } výskyty - [many] Více než { $limit } výskytů - *[other] Více než { $limit } výskytů - } -pdfjs-find-not-found = Hledaný text nenalezen - -## Predefined zoom values - -pdfjs-page-scale-width = Podle šířky -pdfjs-page-scale-fit = Podle výšky -pdfjs-page-scale-auto = Automatická velikost -pdfjs-page-scale-actual = Skutečná velikost -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale } % - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Strana { $page } - -## Loading indicator messages - -pdfjs-loading-error = Při nahrávání PDF nastala chyba. -pdfjs-invalid-file-error = Neplatný nebo chybný soubor PDF. -pdfjs-missing-file-error = Chybí soubor PDF. -pdfjs-unexpected-response-error = Neočekávaná odpověď serveru. -pdfjs-rendering-error = Při vykreslování stránky nastala chyba. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotace typu { $type }] - -## Password - -pdfjs-password-label = Pro otevření PDF souboru vložte heslo. -pdfjs-password-invalid = Neplatné heslo. Zkuste to znovu. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Zrušit -pdfjs-web-fonts-disabled = Webová písma jsou zakázána, proto není možné použít vložená písma PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Kreslení -pdfjs-editor-ink-button-label = Kreslení -pdfjs-editor-stamp-button = - .title = Přidání či úprava obrázků -pdfjs-editor-stamp-button-label = Přidání či úprava obrázků -pdfjs-editor-highlight-button = - .title = Zvýraznění -pdfjs-editor-highlight-button-label = Zvýraznění -pdfjs-highlight-floating-button = - .title = Zvýraznit -pdfjs-highlight-floating-button1 = - .title = Zvýraznit - .aria-label = Zvýraznit -pdfjs-highlight-floating-button-label = Zvýraznit - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Odebrat kresbu -pdfjs-editor-remove-freetext-button = - .title = Odebrat text -pdfjs-editor-remove-stamp-button = - .title = Odebrat obrázek -pdfjs-editor-remove-highlight-button = - .title = Odebrat zvýraznění - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Barva -pdfjs-editor-free-text-size-input = Velikost -pdfjs-editor-ink-color-input = Barva -pdfjs-editor-ink-thickness-input = Tloušťka -pdfjs-editor-ink-opacity-input = Průhlednost -pdfjs-editor-stamp-add-image-button = - .title = Přidat obrázek -pdfjs-editor-stamp-add-image-button-label = Přidat obrázek -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tloušťka -pdfjs-editor-free-highlight-thickness-title = - .title = Změna tloušťky při zvýrazňování jiných položek než textu -pdfjs-free-text = - .aria-label = Textový editor -pdfjs-free-text-default-content = Začněte psát… -pdfjs-ink = - .aria-label = Editor kreslení -pdfjs-ink-canvas = - .aria-label = Uživatelem vytvořený obrázek - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Náhradní popis -pdfjs-editor-alt-text-edit-button-label = Upravit náhradní popis -pdfjs-editor-alt-text-dialog-label = Vyberte možnost -pdfjs-editor-alt-text-dialog-description = Náhradní popis pomáhá, když lidé obrázek nevidí nebo když se nenačítá. -pdfjs-editor-alt-text-add-description-label = Přidat popis -pdfjs-editor-alt-text-add-description-description = Snažte se o 1-2 věty, které popisují předmět, prostředí nebo činnosti. -pdfjs-editor-alt-text-mark-decorative-label = Označit jako dekorativní -pdfjs-editor-alt-text-mark-decorative-description = Používá se pro okrasné obrázky, jako jsou rámečky nebo vodoznaky. -pdfjs-editor-alt-text-cancel-button = Zrušit -pdfjs-editor-alt-text-save-button = Uložit -pdfjs-editor-alt-text-decorative-tooltip = Označen jako dekorativní -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Například: “Mladý muž si sedá ke stolu, aby se najedl.” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Levý horní roh — změna velikosti -pdfjs-editor-resizer-label-top-middle = Horní střed — změna velikosti -pdfjs-editor-resizer-label-top-right = Pravý horní roh — změna velikosti -pdfjs-editor-resizer-label-middle-right = Vpravo uprostřed — změna velikosti -pdfjs-editor-resizer-label-bottom-right = Pravý dolní roh — změna velikosti -pdfjs-editor-resizer-label-bottom-middle = Střed dole — změna velikosti -pdfjs-editor-resizer-label-bottom-left = Levý dolní roh — změna velikosti -pdfjs-editor-resizer-label-middle-left = Vlevo uprostřed — změna velikosti - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Barva zvýraznění -pdfjs-editor-colorpicker-button = - .title = Změna barvy -pdfjs-editor-colorpicker-dropdown = - .aria-label = Výběr barev -pdfjs-editor-colorpicker-yellow = - .title = Žlutá -pdfjs-editor-colorpicker-green = - .title = Zelená -pdfjs-editor-colorpicker-blue = - .title = Modrá -pdfjs-editor-colorpicker-pink = - .title = Růžová -pdfjs-editor-colorpicker-red = - .title = Červená - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Zobrazit vše -pdfjs-editor-highlight-show-all-button = - .title = Zobrazit vše diff --git a/static/pdf.js/locale/cs/viewer.properties b/static/pdf.js/locale/cs/viewer.properties new file mode 100644 index 00000000..b41de1f1 --- /dev/null +++ b/static/pdf.js/locale/cs/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Předchozí stránka +previous_label=Předchozí +next.title=Další stránka +next_label=Další + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Stránka: +page_of=z {{pageCount}} + +zoom_out.title=Zmenší velikost +zoom_out_label=Zmenšit +zoom_in.title=Zvětší velikost +zoom_in_label=Zvětšit +zoom.title=Nastaví velikost +presentation_mode.title=Přepne do režimu prezentace +presentation_mode_label=Režim prezentace +open_file.title=Otevře soubor +open_file_label=Otevřít +print.title=Vytiskne dokument +print_label=Tisk +download.title=Stáhne dokument +download_label=Stáhnout +bookmark.title=Aktuální pohled (kopírovat nebo otevřít v novém okně) +bookmark_label=Aktuální pohled + +# Secondary toolbar and context menu +tools.title=Nástroje +tools_label=Nástroje +first_page.title=Přejde na první stránku +first_page.label=Přejít na první stránku +first_page_label=Přejít na první stránku +last_page.title=Přejde na poslední stránku +last_page.label=Přejít na poslední stránku +last_page_label=Přejít na poslední stránku +page_rotate_cw.title=Otočí po směru hodin +page_rotate_cw.label=Otočit po směru hodin +page_rotate_cw_label=Otočit po směru hodin +page_rotate_ccw.title=Otočí proti směru hodin +page_rotate_ccw.label=Otočit proti směru hodin +page_rotate_ccw_label=Otočit proti směru hodin + +hand_tool_enable.title=Povolit nástroj ručička +hand_tool_enable_label=Povolit nástroj ručička +hand_tool_disable.title=Zakázat nástroj ručička +hand_tool_disable_label=Zakázat nástroj ručička + +# Document properties dialog box +document_properties.title=Vlastnosti dokumentu… +document_properties_label=Vlastnosti dokumentu… +document_properties_file_name=Název souboru: +document_properties_file_size=Velikost souboru: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bajtů) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bajtů) +document_properties_title=Nadpis: +document_properties_author=Autor: +document_properties_subject=Subjekt: +document_properties_keywords=Klíčová slova: +document_properties_creation_date=Datum vytvoření: +document_properties_modification_date=Datum úpravy: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Vytvořil: +document_properties_producer=Tvůrce PDF: +document_properties_version=Verze PDF: +document_properties_page_count=Počet stránek: +document_properties_close=Zavřít + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Postranní lišta +toggle_sidebar_label=Postranní lišta +outline.title=Zobrazí osnovu dokumentu +outline_label=Osnova dokumentu +attachments.title=Zobrazí přílohy +attachments_label=Přílohy +thumbs.title=Zobrazí náhledy +thumbs_label=Náhledy +findbar.title=Najde v dokumentu +findbar_label=Najít + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Strana {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Náhled strany {{page}} + +# Find panel button title and messages +find_label=Najít: +find_previous.title=Najde předchozí výskyt hledaného spojení +find_previous_label=Předchozí +find_next.title=Najde další výskyt hledaného spojení +find_next_label=Další +find_highlight=Zvýraznit +find_match_case_label=Rozlišovat velikost +find_reached_top=Dosažen začátek dokumentu, pokračuje se od konce +find_reached_bottom=Dosažen konec dokumentu, pokračuje se od začátku +find_not_found=Hledané spojení nenalezeno + +# Error panel labels +error_more_info=Více informací +error_less_info=Méně informací +error_close=Zavřít +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (sestavení: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Zpráva: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Zásobník: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Soubor: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Řádka: {{line}} +rendering_error=Při vykreslování stránky nastala chyba. + +# Predefined zoom values +page_scale_width=Podle šířky +page_scale_fit=Podle výšky +page_scale_auto=Automatická velikost +page_scale_actual=Skutečná velikost +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Chyba +loading_error=Při nahrávání PDF nastala chyba. +invalid_file_error=Neplatný nebo chybný soubor PDF. +missing_file_error=Chybí soubor PDF. +unexpected_response_error=Neočekávaná odpověď serveru. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotace typu {{type}}] +password_label=Pro otevření PDF souboru vložte heslo. +password_invalid=Neplatné heslo. Zkuste to znovu. +password_ok=OK +password_cancel=Zrušit + +printing_not_supported=Upozornění: Tisk není v tomto prohlížeči plně podporován. +printing_not_ready=Upozornění: Dokument PDF není kompletně načten. +web_fonts_disabled=Webová písma jsou zakázána, proto není možné použít vložená písma PDF. +document_colors_not_allowed=PDF dokumenty nemají povoleno používat vlastní barvy: volba 'Povolit stránkám používat vlastní barvy' je v prohlížeči deaktivována. diff --git a/static/pdf.js/locale/csb/viewer.properties b/static/pdf.js/locale/csb/viewer.properties new file mode 100644 index 00000000..293a353c --- /dev/null +++ b/static/pdf.js/locale/csb/viewer.properties @@ -0,0 +1,134 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Pòprzédnô strona +previous_label=Pòprzédnô +next.title=Nôslédnô strona +next_label=Nôslédnô + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Strona: +page_of=z {{pageCount}} + +zoom_out.title=Zmniészë +zoom_out_label=Zmniészë +zoom_in.title=Zwikszë +zoom_in_label=Wiôlgòsc +zoom.title=Wiôlgòsc +print.title=Drëkùjë +print_label=Drëkùjë +presentation_mode.title=Przéńdzë w trib prezentacje +presentation_mode_label=Trib prezentacje +open_file.title=Òtemkni lopk +open_file_label=Òtemkni +download.title=Zladënk +download_label=Zladënk +bookmark.title=Spamiãtôj wëzdrzatk (kòpérëje, abò òtemkni w nowim òknnie) +bookmark_label=Aktualny wëzdrzatk + +find_label=Szëkôj: +find_previous.title=Biéj do pòprzédnégò wënikù szëkbë +find_previous_label=Pòprzédny +find_next.title=Biéj do nôslédnégò wënikù szëkbë +find_next_label=Nôslédny +find_highlight=Pòdszkrzëni wszëtczé +find_match_case_label=Rozeznôwôj miarã lëterów +find_not_found=Nie nalôzł tekstu +find_reached_bottom=Doszedł do kùńca dokùmentu, zaczinającë òd górë +find_reached_top=Doszedł do pòczątkù dokùmentu, zaczinającë òd dołù + +toggle_sidebar.title=Pòsuwk wëbiérkù +toggle_sidebar_label=Pòsuwk wëbiérkù + +outline.title=Wëskrzëni òbcéch dokùmentu +outline_label=Òbcéch dokùmentu +thumbs.title=Wëskrzëni miniaturë +thumbs_label=Miniaturë +findbar.title=Przeszëkôj dokùment +findbar_label=Nalezë +tools_label=Nôrzãdła +first_page.title=Biéj do pierszi stronë +first_page.label=Biéj do pierszi stronë +last_page.label=Biéj do òstatny stronë +invalid_file_error=Lëchi ôrt, abò pòpsëti lopk PDF. + + + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Strona {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura stronë {{page}} + +# Error panel labels +error_more_info=Wicy infòrmacje +error_less_info=Mni infòrmacje +error_close=Close +error_version_info=PDF.js v{{version}} (build: {{build}}) + + +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Message: {{wiadło}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stóg}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=File: {{lopk}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Line: {{line}} +rendering_error=Pòkôza sã fela przë renderowanim stronë. + +# Predefined zoom values +page_scale_width=Szérzawa stronë +page_scale_fit=Dopasëje stronã +page_scale_auto=Aùtomatnô wiôlgòsc +page_scale_actual=Naturalnô wiôlgòsc + +# Loading indicator messages +# LOCALIZATION NOTE (error_line): "{{[percent}}" will be replaced with a percentage +loading_error_indicator=Fela +loading_error=Pòkôza sã fela przë wczëtiwanim PDFù. + +# LOCALIZATION NOTE (text_annotation_type): This is used as a tooltip. +# "{{[type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" + +request_password=PDF je zabezpieczony parolą: +printing_not_supported = Òstrzéga: przezérnik nie je do kùńca wspieróny przez drëkôrze + +# Context menu +page_rotate_cw.label=Òbkrãcë w prawò +page_rotate_ccw.label=Òbkrãcë w lewò + + +last_page.title=Biéj do pòprzédny stronë +last_page_label=Biéj do pòprzédny stronë +page_rotate_cw.title=Òbkrãcë w prawò +page_rotate_cw_label=Òbkrãcë w prawò +page_rotate_ccw.title=Òbkrãcë w lewò +page_rotate_ccw_label=Òbkrãcë w lewò + + +web_fonts_disabled=Sécowé czconczi są wëłączoné: włączë je, bë móc ùżiwac òsadzonëch czconków w lopkach PDF. + + +missing_file_error=Felëje lopka PDF. +printing_not_ready = Òstrzéga: lopk mùszi sã do kùńca wczëtac zanim gò mòże drëkòwac + +document_colors_disabled=Dokùmentë PDF nie mògą ù swòjich farwów: \'Pòzwòlë stronóm wëbierac swòje farwë\' je wëłączoné w przezérnikù. +invalid_password=Lëchô parola. +text_annotation_type.alt=[Adnotacjô {{type}}] + +tools.title=Tools +first_page_label=Go to First Page + + diff --git a/static/pdf.js/locale/cy/viewer.ftl b/static/pdf.js/locale/cy/viewer.ftl deleted file mode 100644 index 061237ab..00000000 --- a/static/pdf.js/locale/cy/viewer.ftl +++ /dev/null @@ -1,410 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Tudalen Flaenorol -pdfjs-previous-button-label = Blaenorol -pdfjs-next-button = - .title = Tudalen Nesaf -pdfjs-next-button-label = Nesaf -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Tudalen -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = o { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } o { $pagesCount }) -pdfjs-zoom-out-button = - .title = Lleihau -pdfjs-zoom-out-button-label = Lleihau -pdfjs-zoom-in-button = - .title = Cynyddu -pdfjs-zoom-in-button-label = Cynyddu -pdfjs-zoom-select = - .title = Chwyddo -pdfjs-presentation-mode-button = - .title = Newid i'r Modd Cyflwyno -pdfjs-presentation-mode-button-label = Modd Cyflwyno -pdfjs-open-file-button = - .title = Agor Ffeil -pdfjs-open-file-button-label = Agor -pdfjs-print-button = - .title = Argraffu -pdfjs-print-button-label = Argraffu -pdfjs-save-button = - .title = Cadw -pdfjs-save-button-label = Cadw -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Llwytho i lawr -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Llwytho i lawr -pdfjs-bookmark-button = - .title = Tudalen Gyfredol (Gweld URL o'r Dudalen Gyfredol) -pdfjs-bookmark-button-label = Tudalen Gyfredol -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Agor yn yr ap -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Agor yn yr ap - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Offer -pdfjs-tools-button-label = Offer -pdfjs-first-page-button = - .title = Mynd i'r Dudalen Gyntaf -pdfjs-first-page-button-label = Mynd i'r Dudalen Gyntaf -pdfjs-last-page-button = - .title = Mynd i'r Dudalen Olaf -pdfjs-last-page-button-label = Mynd i'r Dudalen Olaf -pdfjs-page-rotate-cw-button = - .title = Cylchdroi Clocwedd -pdfjs-page-rotate-cw-button-label = Cylchdroi Clocwedd -pdfjs-page-rotate-ccw-button = - .title = Cylchdroi Gwrthglocwedd -pdfjs-page-rotate-ccw-button-label = Cylchdroi Gwrthglocwedd -pdfjs-cursor-text-select-tool-button = - .title = Galluogi Dewis Offeryn Testun -pdfjs-cursor-text-select-tool-button-label = Offeryn Dewis Testun -pdfjs-cursor-hand-tool-button = - .title = Galluogi Offeryn Llaw -pdfjs-cursor-hand-tool-button-label = Offeryn Llaw -pdfjs-scroll-page-button = - .title = Defnyddio Sgrolio Tudalen -pdfjs-scroll-page-button-label = Sgrolio Tudalen -pdfjs-scroll-vertical-button = - .title = Defnyddio Sgrolio Fertigol -pdfjs-scroll-vertical-button-label = Sgrolio Fertigol -pdfjs-scroll-horizontal-button = - .title = Defnyddio Sgrolio Llorweddol -pdfjs-scroll-horizontal-button-label = Sgrolio Llorweddol -pdfjs-scroll-wrapped-button = - .title = Defnyddio Sgrolio Amlapio -pdfjs-scroll-wrapped-button-label = Sgrolio Amlapio -pdfjs-spread-none-button = - .title = Peidio uno trawsdaleniadau -pdfjs-spread-none-button-label = Dim Trawsdaleniadau -pdfjs-spread-odd-button = - .title = Uno trawsdaleniadau gan gychwyn gyda thudalennau odrif -pdfjs-spread-odd-button-label = Trawsdaleniadau Odrif -pdfjs-spread-even-button = - .title = Uno trawsdaleniadau gan gychwyn gyda thudalennau eilrif -pdfjs-spread-even-button-label = Trawsdaleniadau Eilrif - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Priodweddau Dogfen… -pdfjs-document-properties-button-label = Priodweddau Dogfen… -pdfjs-document-properties-file-name = Enw ffeil: -pdfjs-document-properties-file-size = Maint ffeil: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } beit) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } beit) -pdfjs-document-properties-title = Teitl: -pdfjs-document-properties-author = Awdur: -pdfjs-document-properties-subject = Pwnc: -pdfjs-document-properties-keywords = Allweddair: -pdfjs-document-properties-creation-date = Dyddiad Creu: -pdfjs-document-properties-modification-date = Dyddiad Addasu: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Crewr: -pdfjs-document-properties-producer = Cynhyrchydd PDF: -pdfjs-document-properties-version = Fersiwn PDF: -pdfjs-document-properties-page-count = Cyfrif Tudalen: -pdfjs-document-properties-page-size = Maint Tudalen: -pdfjs-document-properties-page-size-unit-inches = o fewn -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portread -pdfjs-document-properties-page-size-orientation-landscape = tirlun -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Llythyr -pdfjs-document-properties-page-size-name-legal = Cyfreithiol - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Golwg Gwe Cyflym: -pdfjs-document-properties-linearized-yes = Iawn -pdfjs-document-properties-linearized-no = Na -pdfjs-document-properties-close-button = Cau - -## Print - -pdfjs-print-progress-message = Paratoi dogfen ar gyfer ei hargraffu… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Diddymu -pdfjs-printing-not-supported = Rhybudd: Nid yw argraffu yn cael ei gynnal yn llawn gan y porwr. -pdfjs-printing-not-ready = Rhybudd: Nid yw'r PDF wedi ei lwytho'n llawn ar gyfer argraffu. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Toglo'r Bar Ochr -pdfjs-toggle-sidebar-notification-button = - .title = Toglo'r Bar Ochr (mae'r ddogfen yn cynnwys amlinelliadau/atodiadau/haenau) -pdfjs-toggle-sidebar-button-label = Toglo'r Bar Ochr -pdfjs-document-outline-button = - .title = Dangos Amlinell Dogfen (clic dwbl i ymestyn/cau pob eitem) -pdfjs-document-outline-button-label = Amlinelliad Dogfen -pdfjs-attachments-button = - .title = Dangos Atodiadau -pdfjs-attachments-button-label = Atodiadau -pdfjs-layers-button = - .title = Dangos Haenau (cliciwch ddwywaith i ailosod yr holl haenau i'r cyflwr rhagosodedig) -pdfjs-layers-button-label = Haenau -pdfjs-thumbs-button = - .title = Dangos Lluniau Bach -pdfjs-thumbs-button-label = Lluniau Bach -pdfjs-current-outline-item-button = - .title = Canfod yr Eitem Amlinellol Gyfredol -pdfjs-current-outline-item-button-label = Yr Eitem Amlinellol Gyfredol -pdfjs-findbar-button = - .title = Canfod yn y Ddogfen -pdfjs-findbar-button-label = Canfod -pdfjs-additional-layers = Haenau Ychwanegol - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Tudalen { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Llun Bach Tudalen { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Canfod - .placeholder = Canfod yn y ddogfen… -pdfjs-find-previous-button = - .title = Canfod enghraifft flaenorol o'r ymadrodd -pdfjs-find-previous-button-label = Blaenorol -pdfjs-find-next-button = - .title = Canfod enghraifft nesaf yr ymadrodd -pdfjs-find-next-button-label = Nesaf -pdfjs-find-highlight-checkbox = Amlygu Popeth -pdfjs-find-match-case-checkbox-label = Cydweddu Maint -pdfjs-find-match-diacritics-checkbox-label = Diacritigau Cyfatebol -pdfjs-find-entire-word-checkbox-label = Geiriau Cyfan -pdfjs-find-reached-top = Wedi cyrraedd brig y dudalen, parhau o'r gwaelod -pdfjs-find-reached-bottom = Wedi cyrraedd diwedd y dudalen, parhau o'r brig -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [zero] { $current } o { $total } cydweddiadau - [one] { $current } o { $total } cydweddiad - [two] { $current } o { $total } gydweddiad - [few] { $current } o { $total } cydweddiad - [many] { $current } o { $total } chydweddiad - *[other] { $current } o { $total } cydweddiad - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [zero] Mwy nag { $limit } cydweddiadau - [one] Mwy nag { $limit } cydweddiad - [two] Mwy nag { $limit } gydweddiad - [few] Mwy nag { $limit } cydweddiad - [many] Mwy nag { $limit } chydweddiad - *[other] Mwy nag { $limit } cydweddiad - } -pdfjs-find-not-found = Heb ganfod ymadrodd - -## Predefined zoom values - -pdfjs-page-scale-width = Lled Tudalen -pdfjs-page-scale-fit = Ffit Tudalen -pdfjs-page-scale-auto = Chwyddo Awtomatig -pdfjs-page-scale-actual = Maint Gwirioneddol -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Tudalen { $page } - -## Loading indicator messages - -pdfjs-loading-error = Digwyddodd gwall wrth lwytho'r PDF. -pdfjs-invalid-file-error = Ffeil PDF annilys neu llwgr. -pdfjs-missing-file-error = Ffeil PDF coll. -pdfjs-unexpected-response-error = Ymateb annisgwyl gan y gweinydd. -pdfjs-rendering-error = Digwyddodd gwall wrth adeiladu'r dudalen. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anodiad { $type } ] - -## Password - -pdfjs-password-label = Rhowch gyfrinair i agor y PDF. -pdfjs-password-invalid = Cyfrinair annilys. Ceisiwch eto. -pdfjs-password-ok-button = Iawn -pdfjs-password-cancel-button = Diddymu -pdfjs-web-fonts-disabled = Ffontiau gwe wedi eu hanalluogi: methu defnyddio ffontiau PDF mewnblanedig. - -## Editing - -pdfjs-editor-free-text-button = - .title = Testun -pdfjs-editor-free-text-button-label = Testun -pdfjs-editor-ink-button = - .title = Lluniadu -pdfjs-editor-ink-button-label = Lluniadu -pdfjs-editor-stamp-button = - .title = Ychwanegu neu olygu delweddau -pdfjs-editor-stamp-button-label = Ychwanegu neu olygu delweddau -pdfjs-editor-highlight-button = - .title = Amlygu -pdfjs-editor-highlight-button-label = Amlygu -pdfjs-highlight-floating-button = - .title = Amlygu -pdfjs-highlight-floating-button1 = - .title = Amlygu - .aria-label = Amlygu -pdfjs-highlight-floating-button-label = Amlygu - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Dileu lluniad -pdfjs-editor-remove-freetext-button = - .title = Dileu testun -pdfjs-editor-remove-stamp-button = - .title = Dileu delwedd -pdfjs-editor-remove-highlight-button = - .title = Tynnu amlygiad - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Lliw -pdfjs-editor-free-text-size-input = Maint -pdfjs-editor-ink-color-input = Lliw -pdfjs-editor-ink-thickness-input = Trwch -pdfjs-editor-ink-opacity-input = Didreiddedd -pdfjs-editor-stamp-add-image-button = - .title = Ychwanegu delwedd -pdfjs-editor-stamp-add-image-button-label = Ychwanegu delwedd -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Trwch -pdfjs-editor-free-highlight-thickness-title = - .title = Newid trwch wrth amlygu eitemau heblaw testun -pdfjs-free-text = - .aria-label = Golygydd Testun -pdfjs-free-text-default-content = Cychwyn teipio… -pdfjs-ink = - .aria-label = Golygydd Lluniadu -pdfjs-ink-canvas = - .aria-label = Delwedd wedi'i chreu gan ddefnyddwyr - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Testun amgen (alt) -pdfjs-editor-alt-text-edit-button-label = Golygu testun amgen -pdfjs-editor-alt-text-dialog-label = Dewisiadau -pdfjs-editor-alt-text-dialog-description = Mae testun amgen (testun alt) yn helpu pan na all pobl weld y ddelwedd neu pan nad yw'n llwytho. -pdfjs-editor-alt-text-add-description-label = Ychwanegu disgrifiad -pdfjs-editor-alt-text-add-description-description = Anelwch at 1-2 frawddeg sy'n disgrifio'r pwnc, y cefndir neu'r gweithredoedd. -pdfjs-editor-alt-text-mark-decorative-label = Marcio fel addurniadol -pdfjs-editor-alt-text-mark-decorative-description = Mae'n cael ei ddefnyddio ar gyfer delweddau addurniadol, fel borderi neu farciau dŵr. -pdfjs-editor-alt-text-cancel-button = Diddymu -pdfjs-editor-alt-text-save-button = Cadw -pdfjs-editor-alt-text-decorative-tooltip = Marcio fel addurniadol -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Er enghraifft, “Mae dyn ifanc yn eistedd wrth fwrdd i fwyta pryd bwyd” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Y gornel chwith uchaf — newid maint -pdfjs-editor-resizer-label-top-middle = Canol uchaf - newid maint -pdfjs-editor-resizer-label-top-right = Y gornel dde uchaf - newid maint -pdfjs-editor-resizer-label-middle-right = De canol - newid maint -pdfjs-editor-resizer-label-bottom-right = Y gornel dde isaf — newid maint -pdfjs-editor-resizer-label-bottom-middle = Canol gwaelod — newid maint -pdfjs-editor-resizer-label-bottom-left = Y gornel chwith isaf — newid maint -pdfjs-editor-resizer-label-middle-left = Chwith canol — newid maint - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Lliw amlygu -pdfjs-editor-colorpicker-button = - .title = Newid lliw -pdfjs-editor-colorpicker-dropdown = - .aria-label = Dewisiadau lliw -pdfjs-editor-colorpicker-yellow = - .title = Melyn -pdfjs-editor-colorpicker-green = - .title = Gwyrdd -pdfjs-editor-colorpicker-blue = - .title = Glas -pdfjs-editor-colorpicker-pink = - .title = Pinc -pdfjs-editor-colorpicker-red = - .title = Coch - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Dangos y cyfan -pdfjs-editor-highlight-show-all-button = - .title = Dangos y cyfan diff --git a/static/pdf.js/locale/cy/viewer.properties b/static/pdf.js/locale/cy/viewer.properties new file mode 100644 index 00000000..47db2183 --- /dev/null +++ b/static/pdf.js/locale/cy/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Tudalen Flaenorol +previous_label=Blaenorol +next.title=Tudalen Nesaf +next_label=Nesaf + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Tudalen: +page_of=o {{pageCount}} + +zoom_out.title=Chwyddo Allan +zoom_out_label=Chwyddo Allan +zoom_in.title=Chwyddo Mewn +zoom_in_label=Chwyddo Mewn +zoom.title=Chwyddo +presentation_mode.title=Newid i'r Modd Cyflwyno +presentation_mode_label=Modd Cyflwyno +open_file.title=Agor Ffeil +open_file_label=Agor +print.title=Argraffu +print_label=Argraffu +download.title=Llwyth +download_label=Llwytho i Lawr +bookmark.title=Golwg cyfredol (copïo neu agor ffenestr newydd) +bookmark_label=Golwg Gyfredol + +# Secondary toolbar and context menu +tools.title=Offer +tools_label=Offer +first_page.title=Mynd i'r Dudalen Gyntaf +first_page.label=Mynd i'r Dudalen Gyntaf +first_page_label=Mynd i'r Dudalen Gyntaf +last_page.title=Mynd i'r Dudalen Olaf +last_page.label=Mynd i'r Dudalen Olaf +last_page_label=Mynd i'r Dudalen Olaf +page_rotate_cw.title=Cylchdroi Clocwedd +page_rotate_cw.label=Cylchdroi Clocwedd +page_rotate_cw_label=Cylchdroi Clocwedd +page_rotate_ccw.title=Cylchdroi Gwrthglocwedd +page_rotate_ccw.label=Cylchdroi Gwrthglocwedd +page_rotate_ccw_label=Cylchdroi Gwrthglocwedd + +hand_tool_enable.title=Galluogi offeryn llaw +hand_tool_enable_label=Galluogi offeryn llaw +hand_tool_disable.title=Analluogi offeryn llaw +hand_tool_disable_label=Analluogi offeryn llaw + +# Document properties dialog box +document_properties.title=Priodweddau Dogfen… +document_properties_label=Priodweddau Dogfen… +document_properties_file_name=Enw ffeil: +document_properties_file_size=Maint ffeil: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} beit) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} beit) +document_properties_title=Teitl: +document_properties_author=Awdur: +document_properties_subject=Pwnc: +document_properties_keywords=Allweddair: +document_properties_creation_date=Dyddiad Creu: +document_properties_modification_date=Dyddiad Addasu: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Crewr: +document_properties_producer=Cynhyrchydd PDF: +document_properties_version=Fersiwn PDF: +document_properties_page_count=Cyfrif Tudalen: +document_properties_close=Cau + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Toglo'r Bar Ochr +toggle_sidebar_label=Toglo'r Bar Ochr +outline.title=Dangos Amlinell Dogfen +outline_label=Amlinelliad Dogfen +attachments.title=Dangos Atodiadau +attachments_label=Atodiadau +thumbs.title=Dangos Lluniau Bach +thumbs_label=Lluniau Bach +findbar.title=Canfod yn y Ddogfen +findbar_label=Canfod + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Tudalen {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Llun Bach Tudalen {{page}} + +# Find panel button title and messages +find_label=Canfod: +find_previous.title=Canfod enghraifft flaenorol o'r ymadrodd +find_previous_label=Blaenorol +find_next.title=Canfod enghraifft nesaf yr ymadrodd +find_next_label=Nesaf +find_highlight=Amlygu popeth +find_match_case_label=Cydweddu maint +find_reached_top=Wedi cyrraedd brig y dudalen, parhau o'r gwaelod +find_reached_bottom=Wedi cyrraedd diwedd y dudalen, parhau o'r brig +find_not_found=Heb ganfod ymadrodd + +# Error panel labels +error_more_info=Rhagor o Wybodaeth +error_less_info=Llai o wybodaeth +error_close=Cau +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Neges: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stac: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Ffeil: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Llinell: {{line}} +rendering_error=Digwyddodd gwall wrth adeiladu'r dudalen. + +# Predefined zoom values +page_scale_width=Lled Tudalen +page_scale_fit=Ffit Tudalen +page_scale_auto=Chwyddo Awtomatig +page_scale_actual=Maint Gwirioneddol +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Gwall +loading_error=Digwyddodd gwall wrth lwytho'r PDF. +invalid_file_error=Ffeil PDF annilys neu llwgr. +missing_file_error=Ffeil PDF coll. +unexpected_response_error=Ymateb annisgwyl gan y gweinydd. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anodiad {{type}} ] +password_label=Rhowch gyfrinair i agor y PDF. +password_invalid=Cyfrinair annilys. Ceisiwch eto. +password_ok=Iawn +password_cancel=Diddymu + +printing_not_supported=Rhybudd: Nid yw argraffu yn cael ei gynnal yn llawn gan y porwr. +printing_not_ready=Rhybudd: Nid yw'r PDF wedi ei lwytho'n llawn ar gyfer argraffu. +web_fonts_disabled=Ffontiau gwe wedi eu hanalluogi: methu defnyddio ffontiau PDF mewnblanedig. +document_colors_not_allowed=Nid oes caniatâd i ddogfennau PDF i ddefnyddio eu lliwiau eu hunain: Mae 'Caniatáu i dudalennau ddefnyddio eu lliwiau eu hunain' wedi ei atal yn y porwr. diff --git a/static/pdf.js/locale/da/viewer.ftl b/static/pdf.js/locale/da/viewer.ftl deleted file mode 100644 index 968b22ff..00000000 --- a/static/pdf.js/locale/da/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Forrige side -pdfjs-previous-button-label = Forrige -pdfjs-next-button = - .title = Næste side -pdfjs-next-button-label = Næste -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Side -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = af { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } af { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom ud -pdfjs-zoom-out-button-label = Zoom ud -pdfjs-zoom-in-button = - .title = Zoom ind -pdfjs-zoom-in-button-label = Zoom ind -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Skift til fuldskærmsvisning -pdfjs-presentation-mode-button-label = Fuldskærmsvisning -pdfjs-open-file-button = - .title = Åbn fil -pdfjs-open-file-button-label = Åbn -pdfjs-print-button = - .title = Udskriv -pdfjs-print-button-label = Udskriv -pdfjs-save-button = - .title = Gem -pdfjs-save-button-label = Gem -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Hent -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Hent -pdfjs-bookmark-button = - .title = Aktuel side (vis URL fra den aktuelle side) -pdfjs-bookmark-button-label = Aktuel side -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Åbn i app -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Åbn i app - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Funktioner -pdfjs-tools-button-label = Funktioner -pdfjs-first-page-button = - .title = Gå til første side -pdfjs-first-page-button-label = Gå til første side -pdfjs-last-page-button = - .title = Gå til sidste side -pdfjs-last-page-button-label = Gå til sidste side -pdfjs-page-rotate-cw-button = - .title = Roter med uret -pdfjs-page-rotate-cw-button-label = Roter med uret -pdfjs-page-rotate-ccw-button = - .title = Roter mod uret -pdfjs-page-rotate-ccw-button-label = Roter mod uret -pdfjs-cursor-text-select-tool-button = - .title = Aktiver markeringsværktøj -pdfjs-cursor-text-select-tool-button-label = Markeringsværktøj -pdfjs-cursor-hand-tool-button = - .title = Aktiver håndværktøj -pdfjs-cursor-hand-tool-button-label = Håndværktøj -pdfjs-scroll-page-button = - .title = Brug sidescrolling -pdfjs-scroll-page-button-label = Sidescrolling -pdfjs-scroll-vertical-button = - .title = Brug vertikal scrolling -pdfjs-scroll-vertical-button-label = Vertikal scrolling -pdfjs-scroll-horizontal-button = - .title = Brug horisontal scrolling -pdfjs-scroll-horizontal-button-label = Horisontal scrolling -pdfjs-scroll-wrapped-button = - .title = Brug ombrudt scrolling -pdfjs-scroll-wrapped-button-label = Ombrudt scrolling -pdfjs-spread-none-button = - .title = Vis enkeltsider -pdfjs-spread-none-button-label = Enkeltsider -pdfjs-spread-odd-button = - .title = Vis opslag med ulige sidenumre til venstre -pdfjs-spread-odd-button-label = Opslag med forside -pdfjs-spread-even-button = - .title = Vis opslag med lige sidenumre til venstre -pdfjs-spread-even-button-label = Opslag uden forside - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumentegenskaber… -pdfjs-document-properties-button-label = Dokumentegenskaber… -pdfjs-document-properties-file-name = Filnavn: -pdfjs-document-properties-file-size = Filstørrelse: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Titel: -pdfjs-document-properties-author = Forfatter: -pdfjs-document-properties-subject = Emne: -pdfjs-document-properties-keywords = Nøgleord: -pdfjs-document-properties-creation-date = Oprettet: -pdfjs-document-properties-modification-date = Redigeret: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Program: -pdfjs-document-properties-producer = PDF-producent: -pdfjs-document-properties-version = PDF-version: -pdfjs-document-properties-page-count = Antal sider: -pdfjs-document-properties-page-size = Sidestørrelse: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = stående -pdfjs-document-properties-page-size-orientation-landscape = liggende -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Hurtig web-visning: -pdfjs-document-properties-linearized-yes = Ja -pdfjs-document-properties-linearized-no = Nej -pdfjs-document-properties-close-button = Luk - -## Print - -pdfjs-print-progress-message = Forbereder dokument til udskrivning… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Annuller -pdfjs-printing-not-supported = Advarsel: Udskrivning er ikke fuldt understøttet af browseren. -pdfjs-printing-not-ready = Advarsel: PDF-filen er ikke fuldt indlæst til udskrivning. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Slå sidepanel til eller fra -pdfjs-toggle-sidebar-notification-button = - .title = Slå sidepanel til eller fra (dokumentet indeholder disposition/vedhæftede filer/lag) -pdfjs-toggle-sidebar-button-label = Slå sidepanel til eller fra -pdfjs-document-outline-button = - .title = Vis dokumentets disposition (dobbeltklik for at vise/skjule alle elementer) -pdfjs-document-outline-button-label = Dokument-disposition -pdfjs-attachments-button = - .title = Vis vedhæftede filer -pdfjs-attachments-button-label = Vedhæftede filer -pdfjs-layers-button = - .title = Vis lag (dobbeltklik for at nulstille alle lag til standard-tilstanden) -pdfjs-layers-button-label = Lag -pdfjs-thumbs-button = - .title = Vis miniaturer -pdfjs-thumbs-button-label = Miniaturer -pdfjs-current-outline-item-button = - .title = Find det aktuelle dispositions-element -pdfjs-current-outline-item-button-label = Aktuelt dispositions-element -pdfjs-findbar-button = - .title = Find i dokument -pdfjs-findbar-button-label = Find -pdfjs-additional-layers = Yderligere lag - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Side { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniature af side { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Find - .placeholder = Find i dokument… -pdfjs-find-previous-button = - .title = Find den forrige forekomst -pdfjs-find-previous-button-label = Forrige -pdfjs-find-next-button = - .title = Find den næste forekomst -pdfjs-find-next-button-label = Næste -pdfjs-find-highlight-checkbox = Fremhæv alle -pdfjs-find-match-case-checkbox-label = Forskel på store og små bogstaver -pdfjs-find-match-diacritics-checkbox-label = Diakritiske tegn -pdfjs-find-entire-word-checkbox-label = Hele ord -pdfjs-find-reached-top = Toppen af siden blev nået, fortsatte fra bunden -pdfjs-find-reached-bottom = Bunden af siden blev nået, fortsatte fra toppen -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } af { $total } forekomst - *[other] { $current } af { $total } forekomster - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Mere end { $limit } forekomst - *[other] Mere end { $limit } forekomster - } -pdfjs-find-not-found = Der blev ikke fundet noget - -## Predefined zoom values - -pdfjs-page-scale-width = Sidebredde -pdfjs-page-scale-fit = Tilpas til side -pdfjs-page-scale-auto = Automatisk zoom -pdfjs-page-scale-actual = Faktisk størrelse -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Side { $page } - -## Loading indicator messages - -pdfjs-loading-error = Der opstod en fejl ved indlæsning af PDF-filen. -pdfjs-invalid-file-error = PDF-filen er ugyldig eller ødelagt. -pdfjs-missing-file-error = Manglende PDF-fil. -pdfjs-unexpected-response-error = Uventet svar fra serveren. -pdfjs-rendering-error = Der opstod en fejl ved generering af siden. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type }kommentar] - -## Password - -pdfjs-password-label = Angiv adgangskode til at åbne denne PDF-fil. -pdfjs-password-invalid = Ugyldig adgangskode. Prøv igen. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Fortryd -pdfjs-web-fonts-disabled = Webskrifttyper er deaktiverede. De indlejrede skrifttyper i PDF-filen kan ikke anvendes. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Tegn -pdfjs-editor-ink-button-label = Tegn -pdfjs-editor-stamp-button = - .title = Tilføj eller rediger billeder -pdfjs-editor-stamp-button-label = Tilføj eller rediger billeder -pdfjs-editor-highlight-button = - .title = Fremhæv -pdfjs-editor-highlight-button-label = Fremhæv -pdfjs-highlight-floating-button = - .title = Fremhæv -pdfjs-highlight-floating-button1 = - .title = Fremhæv - .aria-label = Fremhæv -pdfjs-highlight-floating-button-label = Fremhæv - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Fjern tegning -pdfjs-editor-remove-freetext-button = - .title = Fjern tekst -pdfjs-editor-remove-stamp-button = - .title = Fjern billede -pdfjs-editor-remove-highlight-button = - .title = Fjern fremhævning - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Farve -pdfjs-editor-free-text-size-input = Størrelse -pdfjs-editor-ink-color-input = Farve -pdfjs-editor-ink-thickness-input = Tykkelse -pdfjs-editor-ink-opacity-input = Uigennemsigtighed -pdfjs-editor-stamp-add-image-button = - .title = Tilføj billede -pdfjs-editor-stamp-add-image-button-label = Tilføj billede -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tykkelse -pdfjs-editor-free-highlight-thickness-title = - .title = Ændr tykkelse, når andre elementer end tekst fremhæves -pdfjs-free-text = - .aria-label = Teksteditor -pdfjs-free-text-default-content = Begynd at skrive… -pdfjs-ink = - .aria-label = Tegnings-editor -pdfjs-ink-canvas = - .aria-label = Brugeroprettet billede - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternativ tekst -pdfjs-editor-alt-text-edit-button-label = Rediger alternativ tekst -pdfjs-editor-alt-text-dialog-label = Vælg en indstilling -pdfjs-editor-alt-text-dialog-description = Alternativ tekst hjælper folk, som ikke kan se billedet eller når det ikke indlæses. -pdfjs-editor-alt-text-add-description-label = Tilføj en beskrivelse -pdfjs-editor-alt-text-add-description-description = Sigt efter en eller to sætninger, der beskriver emnet, omgivelserne eller handlinger. -pdfjs-editor-alt-text-mark-decorative-label = Marker som dekorativ -pdfjs-editor-alt-text-mark-decorative-description = Dette bruges for dekorative billeder som rammer eller vandmærker. -pdfjs-editor-alt-text-cancel-button = Annuller -pdfjs-editor-alt-text-save-button = Gem -pdfjs-editor-alt-text-decorative-tooltip = Markeret som dekorativ -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = For eksempel: "En ung mand sætter sig ved et bord for at spise et måltid mad" - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Øverste venstre hjørne — tilpas størrelse -pdfjs-editor-resizer-label-top-middle = Øverste i midten — tilpas størrelse -pdfjs-editor-resizer-label-top-right = Øverste højre hjørne — tilpas størrelse -pdfjs-editor-resizer-label-middle-right = Midten til højre — tilpas størrelse -pdfjs-editor-resizer-label-bottom-right = Nederste højre hjørne - tilpas størrelse -pdfjs-editor-resizer-label-bottom-middle = Nederst i midten - tilpas størrelse -pdfjs-editor-resizer-label-bottom-left = Nederste venstre hjørne - tilpas størrelse -pdfjs-editor-resizer-label-middle-left = Midten til venstre — tilpas størrelse - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Fremhævningsfarve -pdfjs-editor-colorpicker-button = - .title = Skift farve -pdfjs-editor-colorpicker-dropdown = - .aria-label = Farvevalg -pdfjs-editor-colorpicker-yellow = - .title = Gul -pdfjs-editor-colorpicker-green = - .title = Grøn -pdfjs-editor-colorpicker-blue = - .title = Blå -pdfjs-editor-colorpicker-pink = - .title = Lyserød -pdfjs-editor-colorpicker-red = - .title = Rød - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Vis alle -pdfjs-editor-highlight-show-all-button = - .title = Vis alle diff --git a/static/pdf.js/locale/da/viewer.properties b/static/pdf.js/locale/da/viewer.properties new file mode 100644 index 00000000..33a1e1dd --- /dev/null +++ b/static/pdf.js/locale/da/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Forrige side +previous_label=Forrige +next.title=Næste side +next_label=Næste + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Side: +page_of=af {{pageCount}} + +zoom_out.title=Zoom ud +zoom_out_label=Zoom ud +zoom_in.title=Zoom ind +zoom_in_label=Zoom ind +zoom.title=Zoom +print.title=Udskriv +print_label=Udskriv +presentation_mode.title=Skift til fuldskærmsvisning +presentation_mode_label=Fuldskærmsvisning +open_file.title=Åbn fil +open_file_label=Åbn +download.title=Hent +download_label=Hent +bookmark.title=Aktuel visning (kopier eller åbn i et nyt vindue) +bookmark_label=Aktuel visning + +# Secondary toolbar and context menu +tools.title=Funktioner +tools_label=Funktioner +first_page.title=Gå til første side +first_page.label=Gå til første side +first_page_label=Gå til første side +last_page.title=Gå til sidste side +last_page.label=Gå til sidste side +last_page_label=Gå til sidste side +page_rotate_cw.title=Roter med uret +page_rotate_cw.label=Roter med uret +page_rotate_cw_label=Roter med uret +page_rotate_ccw.title=Roter mod uret +page_rotate_ccw.label=Roter mod uret +page_rotate_ccw_label=Roter mod uret + +hand_tool_enable.title=Aktiver håndværktøj +hand_tool_enable_label=Aktiver håndværktøj +hand_tool_disable.title=Deaktiver håndværktøj +hand_tool_disable_label=Deaktiver håndværktøj + +# Document properties dialog box +document_properties.title=Dokumentegenskaber… +document_properties_label=Dokumentegenskaber… +document_properties_file_name=Filnavn: +document_properties_file_size=Filstørrelse: +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Titel: +document_properties_author=Forfatter: +document_properties_subject=Emne: +document_properties_keywords=Nøgleord: +document_properties_creation_date=Oprettet: +document_properties_modification_date=Redigeret: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Program: +document_properties_producer=PDF-producent: +document_properties_version=PDF-version: +document_properties_page_count=Antal sider: +document_properties_close=Luk + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Slå sidepanel til eller fra +toggle_sidebar_label=Slå sidepanel til eller fra +outline.title=Vis dokumentets disposition +outline_label=Dokument-disposition +attachments.title=Vis vedhæftede filer +attachments_label=Vedhæftede filer +thumbs.title=Vis miniaturer +thumbs_label=Miniaturer +findbar.title=Find i dokument +findbar_label=Find + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Side {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniature af side {{page}} + +# Find panel button title and messages +find_label=Find: +find_previous.title=Find den forrige forekomst +find_previous_label=Forrige +find_next.title=Find den næste forekomst +find_next_label=Næste +find_highlight=Fremhæv alle +find_match_case_label=Forskel på store og små bogstaver +find_reached_top=Toppen af siden blev nået, fortsatte fra bunden +find_reached_bottom=Bunden af siden blev nået, fortsatte fra toppen +find_not_found=Der blev ikke fundet noget + +# Error panel labels +error_more_info=Mere information +error_less_info=Mindre information +error_close=Luk +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Fejlmeddelelse: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fil: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linje: {{line}} +rendering_error=Der opstod en fejl ved generering af siden. + +# Predefined zoom values +page_scale_width=Sidebredde +page_scale_fit=Tilpas til side +page_scale_auto=Automatisk zoom +page_scale_actual=Faktisk størrelse +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Fejl +loading_error=Der opstod en fejl ved indlæsning af PDF-filen. +invalid_file_error=PDF-filen er ugyldig eller ødelagt. +missing_file_error=Manglende PDF-fil. +unexpected_response_error=Uventet svar fra serveren. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}}kommentar] +password_label=Angiv adgangskode til at åbne denne PDF-fil. +password_invalid=Ugyldig adgangskode. Prøv igen. +password_ok=OK +password_cancel=Fortryd + +printing_not_supported=Advarsel: Udskrivning er ikke fuldt understøttet af browseren. +printing_not_ready=Advarsel: PDF-filen er ikke fuldt indlæst til udskrivning. +web_fonts_disabled=Webskrifttyper er deaktiverede. De indlejrede skrifttyper i PDF-filen kan ikke anvendes. +document_colors_not_allowed=PDF-dokumenter må ikke bruge deres egne farver: 'Tillad sider at vælge deres egne farver' er deaktiveret i browseren. diff --git a/static/pdf.js/locale/de/viewer.ftl b/static/pdf.js/locale/de/viewer.ftl deleted file mode 100644 index da073aa1..00000000 --- a/static/pdf.js/locale/de/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Eine Seite zurück -pdfjs-previous-button-label = Zurück -pdfjs-next-button = - .title = Eine Seite vor -pdfjs-next-button-label = Vor -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Seite -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = von { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } von { $pagesCount }) -pdfjs-zoom-out-button = - .title = Verkleinern -pdfjs-zoom-out-button-label = Verkleinern -pdfjs-zoom-in-button = - .title = Vergrößern -pdfjs-zoom-in-button-label = Vergrößern -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = In Präsentationsmodus wechseln -pdfjs-presentation-mode-button-label = Präsentationsmodus -pdfjs-open-file-button = - .title = Datei öffnen -pdfjs-open-file-button-label = Öffnen -pdfjs-print-button = - .title = Drucken -pdfjs-print-button-label = Drucken -pdfjs-save-button = - .title = Speichern -pdfjs-save-button-label = Speichern -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Herunterladen -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Herunterladen -pdfjs-bookmark-button = - .title = Aktuelle Seite (URL von aktueller Seite anzeigen) -pdfjs-bookmark-button-label = Aktuelle Seite -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Mit App öffnen -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Mit App öffnen - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Werkzeuge -pdfjs-tools-button-label = Werkzeuge -pdfjs-first-page-button = - .title = Erste Seite anzeigen -pdfjs-first-page-button-label = Erste Seite anzeigen -pdfjs-last-page-button = - .title = Letzte Seite anzeigen -pdfjs-last-page-button-label = Letzte Seite anzeigen -pdfjs-page-rotate-cw-button = - .title = Im Uhrzeigersinn drehen -pdfjs-page-rotate-cw-button-label = Im Uhrzeigersinn drehen -pdfjs-page-rotate-ccw-button = - .title = Gegen Uhrzeigersinn drehen -pdfjs-page-rotate-ccw-button-label = Gegen Uhrzeigersinn drehen -pdfjs-cursor-text-select-tool-button = - .title = Textauswahl-Werkzeug aktivieren -pdfjs-cursor-text-select-tool-button-label = Textauswahl-Werkzeug -pdfjs-cursor-hand-tool-button = - .title = Hand-Werkzeug aktivieren -pdfjs-cursor-hand-tool-button-label = Hand-Werkzeug -pdfjs-scroll-page-button = - .title = Seiten einzeln anordnen -pdfjs-scroll-page-button-label = Einzelseitenanordnung -pdfjs-scroll-vertical-button = - .title = Seiten übereinander anordnen -pdfjs-scroll-vertical-button-label = Vertikale Seitenanordnung -pdfjs-scroll-horizontal-button = - .title = Seiten nebeneinander anordnen -pdfjs-scroll-horizontal-button-label = Horizontale Seitenanordnung -pdfjs-scroll-wrapped-button = - .title = Seiten neben- und übereinander anordnen, abhängig vom Platz -pdfjs-scroll-wrapped-button-label = Kombinierte Seitenanordnung -pdfjs-spread-none-button = - .title = Seiten nicht nebeneinander anzeigen -pdfjs-spread-none-button-label = Einzelne Seiten -pdfjs-spread-odd-button = - .title = Jeweils eine ungerade und eine gerade Seite nebeneinander anzeigen -pdfjs-spread-odd-button-label = Ungerade + gerade Seite -pdfjs-spread-even-button = - .title = Jeweils eine gerade und eine ungerade Seite nebeneinander anzeigen -pdfjs-spread-even-button-label = Gerade + ungerade Seite - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumenteigenschaften -pdfjs-document-properties-button-label = Dokumenteigenschaften… -pdfjs-document-properties-file-name = Dateiname: -pdfjs-document-properties-file-size = Dateigröße: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } Bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } Bytes) -pdfjs-document-properties-title = Titel: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Thema: -pdfjs-document-properties-keywords = Stichwörter: -pdfjs-document-properties-creation-date = Erstelldatum: -pdfjs-document-properties-modification-date = Bearbeitungsdatum: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date } { $time } -pdfjs-document-properties-creator = Anwendung: -pdfjs-document-properties-producer = PDF erstellt mit: -pdfjs-document-properties-version = PDF-Version: -pdfjs-document-properties-page-count = Seitenzahl: -pdfjs-document-properties-page-size = Seitengröße: -pdfjs-document-properties-page-size-unit-inches = Zoll -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = Hochformat -pdfjs-document-properties-page-size-orientation-landscape = Querformat -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Schnelle Webanzeige: -pdfjs-document-properties-linearized-yes = Ja -pdfjs-document-properties-linearized-no = Nein -pdfjs-document-properties-close-button = Schließen - -## Print - -pdfjs-print-progress-message = Dokument wird für Drucken vorbereitet… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress } % -pdfjs-print-progress-close-button = Abbrechen -pdfjs-printing-not-supported = Warnung: Die Drucken-Funktion wird durch diesen Browser nicht vollständig unterstützt. -pdfjs-printing-not-ready = Warnung: Die PDF-Datei ist nicht vollständig geladen, dies ist für das Drucken aber empfohlen. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Sidebar umschalten -pdfjs-toggle-sidebar-notification-button = - .title = Sidebar umschalten (Dokument enthält Dokumentstruktur/Anhänge/Ebenen) -pdfjs-toggle-sidebar-button-label = Sidebar umschalten -pdfjs-document-outline-button = - .title = Dokumentstruktur anzeigen (Doppelklicken, um alle Einträge aus- bzw. einzuklappen) -pdfjs-document-outline-button-label = Dokumentstruktur -pdfjs-attachments-button = - .title = Anhänge anzeigen -pdfjs-attachments-button-label = Anhänge -pdfjs-layers-button = - .title = Ebenen anzeigen (Doppelklicken, um alle Ebenen auf den Standardzustand zurückzusetzen) -pdfjs-layers-button-label = Ebenen -pdfjs-thumbs-button = - .title = Miniaturansichten anzeigen -pdfjs-thumbs-button-label = Miniaturansichten -pdfjs-current-outline-item-button = - .title = Aktuelles Struktur-Element finden -pdfjs-current-outline-item-button-label = Aktuelles Struktur-Element -pdfjs-findbar-button = - .title = Dokument durchsuchen -pdfjs-findbar-button-label = Suchen -pdfjs-additional-layers = Zusätzliche Ebenen - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Seite { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniaturansicht von Seite { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Suchen - .placeholder = Dokument durchsuchen… -pdfjs-find-previous-button = - .title = Vorheriges Vorkommen des Suchbegriffs finden -pdfjs-find-previous-button-label = Zurück -pdfjs-find-next-button = - .title = Nächstes Vorkommen des Suchbegriffs finden -pdfjs-find-next-button-label = Weiter -pdfjs-find-highlight-checkbox = Alle hervorheben -pdfjs-find-match-case-checkbox-label = Groß-/Kleinschreibung beachten -pdfjs-find-match-diacritics-checkbox-label = Akzente -pdfjs-find-entire-word-checkbox-label = Ganze Wörter -pdfjs-find-reached-top = Anfang des Dokuments erreicht, fahre am Ende fort -pdfjs-find-reached-bottom = Ende des Dokuments erreicht, fahre am Anfang fort -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } von { $total } Übereinstimmung - *[other] { $current } von { $total } Übereinstimmungen - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Mehr als { $limit } Übereinstimmung - *[other] Mehr als { $limit } Übereinstimmungen - } -pdfjs-find-not-found = Suchbegriff nicht gefunden - -## Predefined zoom values - -pdfjs-page-scale-width = Seitenbreite -pdfjs-page-scale-fit = Seitengröße -pdfjs-page-scale-auto = Automatischer Zoom -pdfjs-page-scale-actual = Originalgröße -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale } % - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Seite { $page } - -## Loading indicator messages - -pdfjs-loading-error = Beim Laden der PDF-Datei trat ein Fehler auf. -pdfjs-invalid-file-error = Ungültige oder beschädigte PDF-Datei -pdfjs-missing-file-error = Fehlende PDF-Datei -pdfjs-unexpected-response-error = Unerwartete Antwort des Servers -pdfjs-rendering-error = Beim Darstellen der Seite trat ein Fehler auf. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anlage: { $type }] - -## Password - -pdfjs-password-label = Geben Sie zum Öffnen der PDF-Datei deren Passwort ein. -pdfjs-password-invalid = Falsches Passwort. Bitte versuchen Sie es erneut. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Abbrechen -pdfjs-web-fonts-disabled = Web-Schriftarten sind deaktiviert: Eingebettete PDF-Schriftarten konnten nicht geladen werden. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Zeichnen -pdfjs-editor-ink-button-label = Zeichnen -pdfjs-editor-stamp-button = - .title = Grafiken hinzufügen oder bearbeiten -pdfjs-editor-stamp-button-label = Grafiken hinzufügen oder bearbeiten -pdfjs-editor-highlight-button = - .title = Hervorheben -pdfjs-editor-highlight-button-label = Hervorheben -pdfjs-highlight-floating-button = - .title = Hervorheben -pdfjs-highlight-floating-button1 = - .title = Hervorheben - .aria-label = Hervorheben -pdfjs-highlight-floating-button-label = Hervorheben - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Zeichnung entfernen -pdfjs-editor-remove-freetext-button = - .title = Text entfernen -pdfjs-editor-remove-stamp-button = - .title = Grafik entfernen -pdfjs-editor-remove-highlight-button = - .title = Hervorhebung entfernen - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Farbe -pdfjs-editor-free-text-size-input = Größe -pdfjs-editor-ink-color-input = Farbe -pdfjs-editor-ink-thickness-input = Linienstärke -pdfjs-editor-ink-opacity-input = Deckkraft -pdfjs-editor-stamp-add-image-button = - .title = Grafik hinzufügen -pdfjs-editor-stamp-add-image-button-label = Grafik hinzufügen -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Linienstärke -pdfjs-editor-free-highlight-thickness-title = - .title = Linienstärke beim Hervorheben anderer Elemente als Text ändern -pdfjs-free-text = - .aria-label = Texteditor -pdfjs-free-text-default-content = Schreiben beginnen… -pdfjs-ink = - .aria-label = Zeichnungseditor -pdfjs-ink-canvas = - .aria-label = Vom Benutzer erstelltes Bild - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternativ-Text -pdfjs-editor-alt-text-edit-button-label = Alternativ-Text bearbeiten -pdfjs-editor-alt-text-dialog-label = Option wählen -pdfjs-editor-alt-text-dialog-description = Alt-Text (Alternativtext) hilft, wenn Personen die Grafik nicht sehen können oder wenn sie nicht geladen wird. -pdfjs-editor-alt-text-add-description-label = Beschreibung hinzufügen -pdfjs-editor-alt-text-add-description-description = Ziel sind 1-2 Sätze, die das Thema, das Szenario oder Aktionen beschreiben. -pdfjs-editor-alt-text-mark-decorative-label = Als dekorativ markieren -pdfjs-editor-alt-text-mark-decorative-description = Dies wird für Ziergrafiken wie Ränder oder Wasserzeichen verwendet. -pdfjs-editor-alt-text-cancel-button = Abbrechen -pdfjs-editor-alt-text-save-button = Speichern -pdfjs-editor-alt-text-decorative-tooltip = Als dekorativ markiert -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Zum Beispiel: "Ein junger Mann setzt sich an einen Tisch, um zu essen." - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Linke obere Ecke - Größe ändern -pdfjs-editor-resizer-label-top-middle = Oben mittig - Größe ändern -pdfjs-editor-resizer-label-top-right = Rechts oben - Größe ändern -pdfjs-editor-resizer-label-middle-right = Mitte rechts - Größe ändern -pdfjs-editor-resizer-label-bottom-right = Rechte untere Ecke - Größe ändern -pdfjs-editor-resizer-label-bottom-middle = Unten mittig - Größe ändern -pdfjs-editor-resizer-label-bottom-left = Linke untere Ecke - Größe ändern -pdfjs-editor-resizer-label-middle-left = Mitte links - Größe ändern - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Hervorhebungsfarbe -pdfjs-editor-colorpicker-button = - .title = Farbe ändern -pdfjs-editor-colorpicker-dropdown = - .aria-label = Farbauswahl -pdfjs-editor-colorpicker-yellow = - .title = Gelb -pdfjs-editor-colorpicker-green = - .title = Grün -pdfjs-editor-colorpicker-blue = - .title = Blau -pdfjs-editor-colorpicker-pink = - .title = Pink -pdfjs-editor-colorpicker-red = - .title = Rot - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Alle anzeigen -pdfjs-editor-highlight-show-all-button = - .title = Alle anzeigen diff --git a/static/pdf.js/locale/de/viewer.properties b/static/pdf.js/locale/de/viewer.properties new file mode 100644 index 00000000..0e308e9d --- /dev/null +++ b/static/pdf.js/locale/de/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Eine Seite zurück +previous_label=Zurück +next.title=Eine Seite vor +next_label=Vor + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Seite: +page_of=von {{pageCount}} + +zoom_out.title=Verkleinern +zoom_out_label=Verkleinern +zoom_in.title=Vergrößern +zoom_in_label=Vergrößern +zoom.title=Zoom +print.title=Drucken +print_label=Drucken +presentation_mode.title=In Präsentationsmodus wechseln +presentation_mode_label=Präsentationsmodus +open_file.title=Datei öffnen +open_file_label=Öffnen +download.title=Dokument speichern +download_label=Speichern +bookmark.title=Aktuelle Ansicht (zum Kopieren oder Öffnen in einem neuen Fenster) +bookmark_label=Aktuelle Ansicht + +# Secondary toolbar and context menu +tools.title=Werkzeuge +tools_label=Werkzeuge +first_page.title=Erste Seite anzeigen +first_page.label=Erste Seite anzeigen +first_page_label=Erste Seite anzeigen +last_page.title=Letzte Seite anzeigen +last_page.label=Letzte Seite anzeigen +last_page_label=Letzte Seite anzeigen +page_rotate_cw.title=Im Uhrzeigersinn drehen +page_rotate_cw.label=Im Uhrzeigersinn drehen +page_rotate_cw_label=Im Uhrzeigersinn drehen +page_rotate_ccw.title=Gegen Uhrzeigersinn drehen +page_rotate_ccw.label=Gegen Uhrzeigersinn drehen +page_rotate_ccw_label=Gegen Uhrzeigersinn drehen + +hand_tool_enable.title=Hand-Werkzeug aktivieren +hand_tool_enable_label=Hand-Werkzeug aktivieren +hand_tool_disable.title=Hand-Werkzeug deaktivieren +hand_tool_disable_label=Hand-Werkzeug deaktivieren + +# Document properties dialog box +document_properties.title=Dokumenteigenschaften +document_properties_label=Dokumenteigenschaften… +document_properties_file_name=Dateiname: +document_properties_file_size=Dateigröße: +document_properties_kb={{size_kb}} KB ({{size_b}} Bytes) +document_properties_mb={{size_mb}} MB ({{size_b}} Bytes) +document_properties_title=Titel: +document_properties_author=Autor: +document_properties_subject=Thema: +document_properties_keywords=Stichwörter: +document_properties_creation_date=Erstelldatum: +document_properties_modification_date=Bearbeitungsdatum: +document_properties_date_string={{date}} {{time}} +document_properties_creator=Anwendung: +document_properties_producer=PDF erstellt mit: +document_properties_version=PDF-Version: +document_properties_page_count=Seitenzahl: +document_properties_close=Schließen + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Sidebar umschalten +toggle_sidebar_label=Sidebar umschalten +outline.title=Dokumentstruktur anzeigen +outline_label=Dokumentstruktur +attachments.title=Anhänge anzeigen +attachments_label=Anhänge +thumbs.title=Miniaturansichten anzeigen +thumbs_label=Miniaturansichten +findbar.title=Dokument durchsuchen +findbar_label=Suchen + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Seite {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniaturansicht von Seite {{page}} + +# Find panel button title and messages +find_label=Suchen: +find_previous.title=Vorheriges Auftreten des Suchbegriffs finden +find_previous_label=Zurück +find_next.title=Nächstes Auftreten des Suchbegriffs finden +find_next_label=Weiter +find_highlight=Alle hervorheben +find_match_case_label=Groß-/Kleinschreibung beachten +find_reached_top=Anfang des Dokuments erreicht, fahre am Ende fort +find_reached_bottom=Ende des Dokuments erreicht, fahre am Anfang fort +find_not_found=Suchbegriff nicht gefunden + +# Error panel labels +error_more_info=Mehr Informationen +error_less_info=Weniger Informationen +error_close=Schließen +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js Version {{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Nachricht: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Aufrufliste: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Datei: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Zeile: {{line}} +rendering_error=Beim Darstellen der Seite trat ein Fehler auf. + +# Predefined zoom values +page_scale_width=Seitenbreite +page_scale_fit=Seitengröße +page_scale_auto=Automatischer Zoom +page_scale_actual=Originalgröße +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Fehler +loading_error=Beim Laden der PDF-Datei trat ein Fehler auf. +invalid_file_error=Ungültige oder beschädigte PDF-Datei +missing_file_error=Fehlende PDF-Datei +unexpected_response_error=Unerwartete Antwort des Servers + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anlage: {{type}}] +password_label=Geben Sie zum Öffnen der PDF-Datei deren Passwort ein. +password_invalid=Falsches Passwort. Bitte versuchen Sie es erneut. +password_ok=OK +password_cancel=Abbrechen + +printing_not_supported=Warnung: Die Drucken-Funktion wird durch diesen Browser nicht vollständig unterstützt. +printing_not_ready=Warnung: Die PDF-Datei ist nicht vollständig geladen, dies ist für das Drucken aber empfohlen. +web_fonts_disabled=Web-Schriftarten sind deaktiviert: Eingebettete PDF-Schriftarten konnten nicht geladen werden. +document_colors_not_allowed=PDF-Dokumenten ist es nicht erlaubt, ihre eigenen Farben zu verwenden: 'Seiten das Verwenden von eigenen Farben erlauben' ist im Browser deaktiviert. diff --git a/static/pdf.js/locale/dsb/viewer.ftl b/static/pdf.js/locale/dsb/viewer.ftl deleted file mode 100644 index e86f8153..00000000 --- a/static/pdf.js/locale/dsb/viewer.ftl +++ /dev/null @@ -1,406 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pjerwjejšny bok -pdfjs-previous-button-label = Slědk -pdfjs-next-button = - .title = Pśiducy bok -pdfjs-next-button-label = Dalej -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Bok -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = z { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } z { $pagesCount }) -pdfjs-zoom-out-button = - .title = Pómjeńšyś -pdfjs-zoom-out-button-label = Pómjeńšyś -pdfjs-zoom-in-button = - .title = Pówětšyś -pdfjs-zoom-in-button-label = Pówětšyś -pdfjs-zoom-select = - .title = Skalěrowanje -pdfjs-presentation-mode-button = - .title = Do prezentaciskego modusa pśejś -pdfjs-presentation-mode-button-label = Prezentaciski modus -pdfjs-open-file-button = - .title = Dataju wócyniś -pdfjs-open-file-button-label = Wócyniś -pdfjs-print-button = - .title = Śišćaś -pdfjs-print-button-label = Śišćaś -pdfjs-save-button = - .title = Składowaś -pdfjs-save-button-label = Składowaś -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Ześěgnuś -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Ześěgnuś -pdfjs-bookmark-button = - .title = Aktualny bok (URL z aktualnego boka pokazaś) -pdfjs-bookmark-button-label = Aktualny bok -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = W nałoženju wócyniś -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = W nałoženju wócyniś - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Rědy -pdfjs-tools-button-label = Rědy -pdfjs-first-page-button = - .title = K prědnemu bokoju -pdfjs-first-page-button-label = K prědnemu bokoju -pdfjs-last-page-button = - .title = K slědnemu bokoju -pdfjs-last-page-button-label = K slědnemu bokoju -pdfjs-page-rotate-cw-button = - .title = Wobwjertnuś ako špěra źo -pdfjs-page-rotate-cw-button-label = Wobwjertnuś ako špěra źo -pdfjs-page-rotate-ccw-button = - .title = Wobwjertnuś nawopaki ako špěra źo -pdfjs-page-rotate-ccw-button-label = Wobwjertnuś nawopaki ako špěra źo -pdfjs-cursor-text-select-tool-button = - .title = Rěd za wuběranje teksta zmóžniś -pdfjs-cursor-text-select-tool-button-label = Rěd za wuběranje teksta -pdfjs-cursor-hand-tool-button = - .title = Rucny rěd zmóžniś -pdfjs-cursor-hand-tool-button-label = Rucny rěd -pdfjs-scroll-page-button = - .title = Kulanje boka wužywaś -pdfjs-scroll-page-button-label = Kulanje boka -pdfjs-scroll-vertical-button = - .title = Wertikalne suwanje wužywaś -pdfjs-scroll-vertical-button-label = Wertikalne suwanje -pdfjs-scroll-horizontal-button = - .title = Horicontalne suwanje wužywaś -pdfjs-scroll-horizontal-button-label = Horicontalne suwanje -pdfjs-scroll-wrapped-button = - .title = Pózlažke suwanje wužywaś -pdfjs-scroll-wrapped-button-label = Pózlažke suwanje -pdfjs-spread-none-button = - .title = Boki njezwězaś -pdfjs-spread-none-button-label = Žeden dwójny bok -pdfjs-spread-odd-button = - .title = Boki zachopinajucy z njerownymi bokami zwězaś -pdfjs-spread-odd-button-label = Njerowne boki -pdfjs-spread-even-button = - .title = Boki zachopinajucy z rownymi bokami zwězaś -pdfjs-spread-even-button-label = Rowne boki - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumentowe kakosći… -pdfjs-document-properties-button-label = Dokumentowe kakosći… -pdfjs-document-properties-file-name = Mě dataje: -pdfjs-document-properties-file-size = Wjelikosć dataje: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bajtow) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bajtow) -pdfjs-document-properties-title = Titel: -pdfjs-document-properties-author = Awtor: -pdfjs-document-properties-subject = Tema: -pdfjs-document-properties-keywords = Klucowe słowa: -pdfjs-document-properties-creation-date = Datum napóranja: -pdfjs-document-properties-modification-date = Datum změny: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Awtor: -pdfjs-document-properties-producer = PDF-gótowaŕ: -pdfjs-document-properties-version = PDF-wersija: -pdfjs-document-properties-page-count = Licba bokow: -pdfjs-document-properties-page-size = Wjelikosć boka: -pdfjs-document-properties-page-size-unit-inches = col -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = wusoki format -pdfjs-document-properties-page-size-orientation-landscape = prěcny format -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Jo -pdfjs-document-properties-linearized-no = Ně -pdfjs-document-properties-close-button = Zacyniś - -## Print - -pdfjs-print-progress-message = Dokument pśigótujo se za śišćanje… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Pśetergnuś -pdfjs-printing-not-supported = Warnowanje: Śišćanje njepódpěra se połnje pśez toś ten wobglědowak. -pdfjs-printing-not-ready = Warnowanje: PDF njejo se za śišćanje dopołnje zacytał. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Bócnicu pokazaś/schowaś -pdfjs-toggle-sidebar-notification-button = - .title = Bocnicu pśešaltowaś (dokument rozrědowanje/pśipiski/warstwy wopśimujo) -pdfjs-toggle-sidebar-button-label = Bócnicu pokazaś/schowaś -pdfjs-document-outline-button = - .title = Dokumentowe naraźenje pokazaś (dwójne kliknjenje, aby se wšykne zapiski pokazali/schowali) -pdfjs-document-outline-button-label = Dokumentowa struktura -pdfjs-attachments-button = - .title = Pśidanki pokazaś -pdfjs-attachments-button-label = Pśidanki -pdfjs-layers-button = - .title = Warstwy pokazaś (klikniśo dwójcy, aby wšykne warstwy na standardny staw slědk stajił) -pdfjs-layers-button-label = Warstwy -pdfjs-thumbs-button = - .title = Miniatury pokazaś -pdfjs-thumbs-button-label = Miniatury -pdfjs-current-outline-item-button = - .title = Aktualny rozrědowański zapisk pytaś -pdfjs-current-outline-item-button-label = Aktualny rozrědowański zapisk -pdfjs-findbar-button = - .title = W dokumenśe pytaś -pdfjs-findbar-button-label = Pytaś -pdfjs-additional-layers = Dalšne warstwy - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Bok { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura boka { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Pytaś - .placeholder = W dokumenśe pytaś… -pdfjs-find-previous-button = - .title = Pjerwjejšne wustupowanje pytańskego wuraza pytaś -pdfjs-find-previous-button-label = Slědk -pdfjs-find-next-button = - .title = Pśidujuce wustupowanje pytańskego wuraza pytaś -pdfjs-find-next-button-label = Dalej -pdfjs-find-highlight-checkbox = Wšykne wuzwignuś -pdfjs-find-match-case-checkbox-label = Na wjelikopisanje źiwaś -pdfjs-find-match-diacritics-checkbox-label = Diakritiske znamuška wužywaś -pdfjs-find-entire-word-checkbox-label = Cełe słowa -pdfjs-find-reached-top = Zachopjeńk dokumenta dostany, pókšacujo se z kóńcom -pdfjs-find-reached-bottom = Kóńc dokumenta dostany, pókšacujo se ze zachopjeńkom -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } z { $total } wótpowědnika - [two] { $current } z { $total } wótpowědnikowu - [few] { $current } z { $total } wótpowědnikow - *[other] { $current } z { $total } wótpowědnikow - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Wušej { $limit } wótpowědnik - [two] Wušej { $limit } wótpowědnika - [few] Wušej { $limit } wótpowědniki - *[other] Wušej { $limit } wótpowědniki - } -pdfjs-find-not-found = Pytański wuraz njejo se namakał - -## Predefined zoom values - -pdfjs-page-scale-width = Šyrokosć boka -pdfjs-page-scale-fit = Wjelikosć boka -pdfjs-page-scale-auto = Awtomatiske skalěrowanje -pdfjs-page-scale-actual = Aktualna wjelikosć -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Bok { $page } - -## Loading indicator messages - -pdfjs-loading-error = Pśi zacytowanju PDF jo zmólka nastała. -pdfjs-invalid-file-error = Njepłaśiwa abo wobškóźona PDF-dataja. -pdfjs-missing-file-error = Felujuca PDF-dataja. -pdfjs-unexpected-response-error = Njewócakane serwerowe wótegrono. -pdfjs-rendering-error = Pśi zwobraznjanju boka jo zmólka nastała. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Typ pśipiskow: { $type }] - -## Password - -pdfjs-password-label = Zapódajśo gronidło, aby PDF-dataju wócynił. -pdfjs-password-invalid = Njepłaśiwe gronidło. Pšosym wopytajśo hyšći raz. -pdfjs-password-ok-button = W pórěźe -pdfjs-password-cancel-button = Pśetergnuś -pdfjs-web-fonts-disabled = Webpisma su znjemóžnjone: njejo móžno, zasajźone PDF-pisma wužywaś. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Kresliś -pdfjs-editor-ink-button-label = Kresliś -pdfjs-editor-stamp-button = - .title = Wobraze pśidaś abo wobźěłaś -pdfjs-editor-stamp-button-label = Wobraze pśidaś abo wobźěłaś -pdfjs-editor-highlight-button = - .title = Wuzwignuś -pdfjs-editor-highlight-button-label = Wuzwignuś -pdfjs-highlight-floating-button = - .title = Wuzwignjenje -pdfjs-highlight-floating-button1 = - .title = Wuzwignuś - .aria-label = Wuzwignuś -pdfjs-highlight-floating-button-label = Wuzwignuś - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Kreslanku wótwónoźeś -pdfjs-editor-remove-freetext-button = - .title = Tekst wótwónoźeś -pdfjs-editor-remove-stamp-button = - .title = Wobraz wótwónoźeś -pdfjs-editor-remove-highlight-button = - .title = Wuzwignjenje wótpóraś - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Barwa -pdfjs-editor-free-text-size-input = Wjelikosć -pdfjs-editor-ink-color-input = Barwa -pdfjs-editor-ink-thickness-input = Tłustosć -pdfjs-editor-ink-opacity-input = Opacita -pdfjs-editor-stamp-add-image-button = - .title = Wobraz pśidaś -pdfjs-editor-stamp-add-image-button-label = Wobraz pśidaś -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tłustosć -pdfjs-editor-free-highlight-thickness-title = - .title = Tłustosć změniś, gaž se zapiski wuzwiguju, kótarež tekst njejsu -pdfjs-free-text = - .aria-label = Tekstowy editor -pdfjs-free-text-default-content = Zachopśo pisaś… -pdfjs-ink = - .aria-label = Kresleński editor -pdfjs-ink-canvas = - .aria-label = Wobraz napórany wót wužywarja - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternatiwny tekst -pdfjs-editor-alt-text-edit-button-label = Alternatiwny tekst wobźěłaś -pdfjs-editor-alt-text-dialog-label = Nastajenje wubraś -pdfjs-editor-alt-text-dialog-description = Alternatiwny tekst pomaga, gaž luźe njamógu wobraz wiźeś abo gaž se wobraz njezacytajo. -pdfjs-editor-alt-text-add-description-label = Wopisanje pśidaś -pdfjs-editor-alt-text-add-description-description = Pišćo 1 sadu abo 2 saźe, kótarejž temu, nastajenje abo akcije wopisujotej. -pdfjs-editor-alt-text-mark-decorative-label = Ako dekoratiwny markěrowaś -pdfjs-editor-alt-text-mark-decorative-description = To se za pyšnjece wobraze wužywa, na pśikład ramiki abo wódowe znamjenja. -pdfjs-editor-alt-text-cancel-button = Pśetergnuś -pdfjs-editor-alt-text-save-button = Składowaś -pdfjs-editor-alt-text-decorative-tooltip = Ako dekoratiwny markěrowany -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Na pśikład, „Młody muski za blidom sejźi, aby jěź jědł“ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Górjejce nalěwo – wjelikosć změniś -pdfjs-editor-resizer-label-top-middle = Górjejce wesrjejź – wjelikosć změniś -pdfjs-editor-resizer-label-top-right = Górjejce napšawo – wjelikosć změniś -pdfjs-editor-resizer-label-middle-right = Wesrjejź napšawo – wjelikosć změniś -pdfjs-editor-resizer-label-bottom-right = Dołojce napšawo – wjelikosć změniś -pdfjs-editor-resizer-label-bottom-middle = Dołojce wesrjejź – wjelikosć změniś -pdfjs-editor-resizer-label-bottom-left = Dołojce nalěwo – wjelikosć změniś -pdfjs-editor-resizer-label-middle-left = Wesrjejź nalěwo – wjelikosć změniś - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Barwa wuzwignjenja -pdfjs-editor-colorpicker-button = - .title = Barwu změniś -pdfjs-editor-colorpicker-dropdown = - .aria-label = Wuběrk barwow -pdfjs-editor-colorpicker-yellow = - .title = Žołty -pdfjs-editor-colorpicker-green = - .title = Zeleny -pdfjs-editor-colorpicker-blue = - .title = Módry -pdfjs-editor-colorpicker-pink = - .title = Pink -pdfjs-editor-colorpicker-red = - .title = Cerwjeny - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Wšykne pokazaś -pdfjs-editor-highlight-show-all-button = - .title = Wšykne pokazaś diff --git a/static/pdf.js/locale/el/viewer.ftl b/static/pdf.js/locale/el/viewer.ftl deleted file mode 100644 index 96d9dc36..00000000 --- a/static/pdf.js/locale/el/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Προηγούμενη σελίδα -pdfjs-previous-button-label = Προηγούμενη -pdfjs-next-button = - .title = Επόμενη σελίδα -pdfjs-next-button-label = Επόμενη -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Σελίδα -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = από { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } από { $pagesCount }) -pdfjs-zoom-out-button = - .title = Σμίκρυνση -pdfjs-zoom-out-button-label = Σμίκρυνση -pdfjs-zoom-in-button = - .title = Μεγέθυνση -pdfjs-zoom-in-button-label = Μεγέθυνση -pdfjs-zoom-select = - .title = Ζουμ -pdfjs-presentation-mode-button = - .title = Εναλλαγή σε λειτουργία παρουσίασης -pdfjs-presentation-mode-button-label = Λειτουργία παρουσίασης -pdfjs-open-file-button = - .title = Άνοιγμα αρχείου -pdfjs-open-file-button-label = Άνοιγμα -pdfjs-print-button = - .title = Εκτύπωση -pdfjs-print-button-label = Εκτύπωση -pdfjs-save-button = - .title = Αποθήκευση -pdfjs-save-button-label = Αποθήκευση -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Λήψη -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Λήψη -pdfjs-bookmark-button = - .title = Τρέχουσα σελίδα (Προβολή URL από τρέχουσα σελίδα) -pdfjs-bookmark-button-label = Τρέχουσα σελίδα -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Άνοιγμα σε εφαρμογή -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Άνοιγμα σε εφαρμογή - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Εργαλεία -pdfjs-tools-button-label = Εργαλεία -pdfjs-first-page-button = - .title = Μετάβαση στην πρώτη σελίδα -pdfjs-first-page-button-label = Μετάβαση στην πρώτη σελίδα -pdfjs-last-page-button = - .title = Μετάβαση στην τελευταία σελίδα -pdfjs-last-page-button-label = Μετάβαση στην τελευταία σελίδα -pdfjs-page-rotate-cw-button = - .title = Δεξιόστροφη περιστροφή -pdfjs-page-rotate-cw-button-label = Δεξιόστροφη περιστροφή -pdfjs-page-rotate-ccw-button = - .title = Αριστερόστροφη περιστροφή -pdfjs-page-rotate-ccw-button-label = Αριστερόστροφη περιστροφή -pdfjs-cursor-text-select-tool-button = - .title = Ενεργοποίηση εργαλείου επιλογής κειμένου -pdfjs-cursor-text-select-tool-button-label = Εργαλείο επιλογής κειμένου -pdfjs-cursor-hand-tool-button = - .title = Ενεργοποίηση εργαλείου χεριού -pdfjs-cursor-hand-tool-button-label = Εργαλείο χεριού -pdfjs-scroll-page-button = - .title = Χρήση κύλισης σελίδας -pdfjs-scroll-page-button-label = Κύλιση σελίδας -pdfjs-scroll-vertical-button = - .title = Χρήση κάθετης κύλισης -pdfjs-scroll-vertical-button-label = Κάθετη κύλιση -pdfjs-scroll-horizontal-button = - .title = Χρήση οριζόντιας κύλισης -pdfjs-scroll-horizontal-button-label = Οριζόντια κύλιση -pdfjs-scroll-wrapped-button = - .title = Χρήση κυκλικής κύλισης -pdfjs-scroll-wrapped-button-label = Κυκλική κύλιση -pdfjs-spread-none-button = - .title = Να μη γίνει σύνδεση επεκτάσεων σελίδων -pdfjs-spread-none-button-label = Χωρίς επεκτάσεις -pdfjs-spread-odd-button = - .title = Σύνδεση επεκτάσεων σελίδων ξεκινώντας από τις μονές σελίδες -pdfjs-spread-odd-button-label = Μονές επεκτάσεις -pdfjs-spread-even-button = - .title = Σύνδεση επεκτάσεων σελίδων ξεκινώντας από τις ζυγές σελίδες -pdfjs-spread-even-button-label = Ζυγές επεκτάσεις - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Ιδιότητες εγγράφου… -pdfjs-document-properties-button-label = Ιδιότητες εγγράφου… -pdfjs-document-properties-file-name = Όνομα αρχείου: -pdfjs-document-properties-file-size = Μέγεθος αρχείου: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Τίτλος: -pdfjs-document-properties-author = Συγγραφέας: -pdfjs-document-properties-subject = Θέμα: -pdfjs-document-properties-keywords = Λέξεις-κλειδιά: -pdfjs-document-properties-creation-date = Ημερομηνία δημιουργίας: -pdfjs-document-properties-modification-date = Ημερομηνία τροποποίησης: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Δημιουργός: -pdfjs-document-properties-producer = Παραγωγός PDF: -pdfjs-document-properties-version = Έκδοση PDF: -pdfjs-document-properties-page-count = Αριθμός σελίδων: -pdfjs-document-properties-page-size = Μέγεθος σελίδας: -pdfjs-document-properties-page-size-unit-inches = ίντσες -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = κατακόρυφα -pdfjs-document-properties-page-size-orientation-landscape = οριζόντια -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Επιστολή -pdfjs-document-properties-page-size-name-legal = Τύπου Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Ταχεία προβολή ιστού: -pdfjs-document-properties-linearized-yes = Ναι -pdfjs-document-properties-linearized-no = Όχι -pdfjs-document-properties-close-button = Κλείσιμο - -## Print - -pdfjs-print-progress-message = Προετοιμασία του εγγράφου για εκτύπωση… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Ακύρωση -pdfjs-printing-not-supported = Προειδοποίηση: Η εκτύπωση δεν υποστηρίζεται πλήρως από το πρόγραμμα περιήγησης. -pdfjs-printing-not-ready = Προειδοποίηση: Το PDF δεν φορτώθηκε πλήρως για εκτύπωση. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = (Απ)ενεργοποίηση πλαϊνής γραμμής -pdfjs-toggle-sidebar-notification-button = - .title = (Απ)ενεργοποίηση πλαϊνής γραμμής (το έγγραφο περιέχει περίγραμμα/συνημμένα/επίπεδα) -pdfjs-toggle-sidebar-button-label = (Απ)ενεργοποίηση πλαϊνής γραμμής -pdfjs-document-outline-button = - .title = Εμφάνιση διάρθρωσης εγγράφου (διπλό κλικ για ανάπτυξη/σύμπτυξη όλων των στοιχείων) -pdfjs-document-outline-button-label = Διάρθρωση εγγράφου -pdfjs-attachments-button = - .title = Εμφάνιση συνημμένων -pdfjs-attachments-button-label = Συνημμένα -pdfjs-layers-button = - .title = Εμφάνιση επιπέδων (διπλό κλικ για επαναφορά όλων των επιπέδων στην προεπιλεγμένη κατάσταση) -pdfjs-layers-button-label = Επίπεδα -pdfjs-thumbs-button = - .title = Εμφάνιση μικρογραφιών -pdfjs-thumbs-button-label = Μικρογραφίες -pdfjs-current-outline-item-button = - .title = Εύρεση τρέχοντος στοιχείου διάρθρωσης -pdfjs-current-outline-item-button-label = Τρέχον στοιχείο διάρθρωσης -pdfjs-findbar-button = - .title = Εύρεση στο έγγραφο -pdfjs-findbar-button-label = Εύρεση -pdfjs-additional-layers = Επιπρόσθετα επίπεδα - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Σελίδα { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Μικρογραφία σελίδας { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Εύρεση - .placeholder = Εύρεση στο έγγραφο… -pdfjs-find-previous-button = - .title = Εύρεση της προηγούμενης εμφάνισης της φράσης -pdfjs-find-previous-button-label = Προηγούμενο -pdfjs-find-next-button = - .title = Εύρεση της επόμενης εμφάνισης της φράσης -pdfjs-find-next-button-label = Επόμενο -pdfjs-find-highlight-checkbox = Επισήμανση όλων -pdfjs-find-match-case-checkbox-label = Συμφωνία πεζών/κεφαλαίων -pdfjs-find-match-diacritics-checkbox-label = Αντιστοίχιση διακριτικών -pdfjs-find-entire-word-checkbox-label = Ολόκληρες λέξεις -pdfjs-find-reached-top = Φτάσατε στην αρχή του εγγράφου, συνέχεια από το τέλος -pdfjs-find-reached-bottom = Φτάσατε στο τέλος του εγγράφου, συνέχεια από την αρχή -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } από { $total } αντιστοιχία - *[other] { $current } από { $total } αντιστοιχίες - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Περισσότερες από { $limit } αντιστοιχία - *[other] Περισσότερες από { $limit } αντιστοιχίες - } -pdfjs-find-not-found = Η φράση δεν βρέθηκε - -## Predefined zoom values - -pdfjs-page-scale-width = Πλάτος σελίδας -pdfjs-page-scale-fit = Μέγεθος σελίδας -pdfjs-page-scale-auto = Αυτόματο ζουμ -pdfjs-page-scale-actual = Πραγματικό μέγεθος -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Σελίδα { $page } - -## Loading indicator messages - -pdfjs-loading-error = Προέκυψε σφάλμα κατά τη φόρτωση του PDF. -pdfjs-invalid-file-error = Μη έγκυρο ή κατεστραμμένο αρχείο PDF. -pdfjs-missing-file-error = Λείπει αρχείο PDF. -pdfjs-unexpected-response-error = Μη αναμενόμενη απόκριση από το διακομιστή. -pdfjs-rendering-error = Προέκυψε σφάλμα κατά την εμφάνιση της σελίδας. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Σχόλιο «{ $type }»] - -## Password - -pdfjs-password-label = Εισαγάγετε τον κωδικό πρόσβασης για να ανοίξετε αυτό το αρχείο PDF. -pdfjs-password-invalid = Μη έγκυρος κωδικός πρόσβασης. Παρακαλώ δοκιμάστε ξανά. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Ακύρωση -pdfjs-web-fonts-disabled = Οι γραμματοσειρές ιστού είναι ανενεργές: δεν είναι δυνατή η χρήση των ενσωματωμένων γραμματοσειρών PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Κείμενο -pdfjs-editor-free-text-button-label = Κείμενο -pdfjs-editor-ink-button = - .title = Σχέδιο -pdfjs-editor-ink-button-label = Σχέδιο -pdfjs-editor-stamp-button = - .title = Προσθήκη ή επεξεργασία εικόνων -pdfjs-editor-stamp-button-label = Προσθήκη ή επεξεργασία εικόνων -pdfjs-editor-highlight-button = - .title = Επισήμανση -pdfjs-editor-highlight-button-label = Επισήμανση -pdfjs-highlight-floating-button = - .title = Επισήμανση -pdfjs-highlight-floating-button1 = - .title = Επισήμανση - .aria-label = Επισήμανση -pdfjs-highlight-floating-button-label = Επισήμανση - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Αφαίρεση σχεδίου -pdfjs-editor-remove-freetext-button = - .title = Αφαίρεση κειμένου -pdfjs-editor-remove-stamp-button = - .title = Αφαίρεση εικόνας -pdfjs-editor-remove-highlight-button = - .title = Αφαίρεση επισήμανσης - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Χρώμα -pdfjs-editor-free-text-size-input = Μέγεθος -pdfjs-editor-ink-color-input = Χρώμα -pdfjs-editor-ink-thickness-input = Πάχος -pdfjs-editor-ink-opacity-input = Αδιαφάνεια -pdfjs-editor-stamp-add-image-button = - .title = Προσθήκη εικόνας -pdfjs-editor-stamp-add-image-button-label = Προσθήκη εικόνας -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Πάχος -pdfjs-editor-free-highlight-thickness-title = - .title = Αλλαγή πάχους κατά την επισήμανση στοιχείων εκτός κειμένου -pdfjs-free-text = - .aria-label = Επεξεργασία κειμένου -pdfjs-free-text-default-content = Ξεκινήστε να πληκτρολογείτε… -pdfjs-ink = - .aria-label = Επεξεργασία σχεδίων -pdfjs-ink-canvas = - .aria-label = Εικόνα από τον χρήστη - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Εναλλακτικό κείμενο -pdfjs-editor-alt-text-edit-button-label = Επεξεργασία εναλλακτικού κειμένου -pdfjs-editor-alt-text-dialog-label = Διαλέξτε μια επιλογή -pdfjs-editor-alt-text-dialog-description = Το εναλλακτικό κείμενο είναι χρήσιμο όταν οι άνθρωποι δεν μπορούν να δουν την εικόνα ή όταν αυτή δεν φορτώνεται. -pdfjs-editor-alt-text-add-description-label = Προσθήκη περιγραφής -pdfjs-editor-alt-text-add-description-description = Στοχεύστε σε μία ή δύο προτάσεις που περιγράφουν το θέμα, τη ρύθμιση ή τις ενέργειες. -pdfjs-editor-alt-text-mark-decorative-label = Επισήμανση ως διακοσμητικό -pdfjs-editor-alt-text-mark-decorative-description = Χρησιμοποιείται για διακοσμητικές εικόνες, όπως περιγράμματα ή υδατογραφήματα. -pdfjs-editor-alt-text-cancel-button = Ακύρωση -pdfjs-editor-alt-text-save-button = Αποθήκευση -pdfjs-editor-alt-text-decorative-tooltip = Επισημασμένο ως διακοσμητικό -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Για παράδειγμα, «Ένας νεαρός άνδρας κάθεται σε ένα τραπέζι για να φάει ένα γεύμα» - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Επάνω αριστερή γωνία — αλλαγή μεγέθους -pdfjs-editor-resizer-label-top-middle = Μέσο επάνω πλευράς — αλλαγή μεγέθους -pdfjs-editor-resizer-label-top-right = Επάνω δεξιά γωνία — αλλαγή μεγέθους -pdfjs-editor-resizer-label-middle-right = Μέσο δεξιάς πλευράς — αλλαγή μεγέθους -pdfjs-editor-resizer-label-bottom-right = Κάτω δεξιά γωνία — αλλαγή μεγέθους -pdfjs-editor-resizer-label-bottom-middle = Μέσο κάτω πλευράς — αλλαγή μεγέθους -pdfjs-editor-resizer-label-bottom-left = Κάτω αριστερή γωνία — αλλαγή μεγέθους -pdfjs-editor-resizer-label-middle-left = Μέσο αριστερής πλευράς — αλλαγή μεγέθους - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Χρώμα επισήμανσης -pdfjs-editor-colorpicker-button = - .title = Αλλαγή χρώματος -pdfjs-editor-colorpicker-dropdown = - .aria-label = Επιλογές χρωμάτων -pdfjs-editor-colorpicker-yellow = - .title = Κίτρινο -pdfjs-editor-colorpicker-green = - .title = Πράσινο -pdfjs-editor-colorpicker-blue = - .title = Μπλε -pdfjs-editor-colorpicker-pink = - .title = Ροζ -pdfjs-editor-colorpicker-red = - .title = Κόκκινο - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Εμφάνιση όλων -pdfjs-editor-highlight-show-all-button = - .title = Εμφάνιση όλων diff --git a/static/pdf.js/locale/el/viewer.properties b/static/pdf.js/locale/el/viewer.properties new file mode 100644 index 00000000..9d968c9a --- /dev/null +++ b/static/pdf.js/locale/el/viewer.properties @@ -0,0 +1,165 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Προηγούμενη σελίδα +previous_label=Προηγούμενη +next.title=Επόμενη σελίδα +next_label=Επόμενη + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Σελίδα: +page_of=από {{pageCount}} + +zoom_out.title=Σμίκρυνση +zoom_out_label=Σμίκρυνση +zoom_in.title=Μεγέθυνση +zoom_in_label=Μεγέθυνση +zoom.title=Μεγέθυνση +presentation_mode.title=Μετάβαση σε λειτουργία παρουσίασης +presentation_mode_label=Λειτουργία παρουσίασης +open_file.title=Άνοιγμα αρχείου +open_file_label=Άνοιγμα +print.title=Εκτύπωση +print_label=Εκτύπωση +download.title=Λήψη +download_label=Λήψη +bookmark.title=Τρέχουσα προβολή (αντίγραφο ή άνοιγμα σε νέο παράθυρο) +bookmark_label=Τρέχουσα προβολή + +# Secondary toolbar and context menu +tools.title=Εργαλεία +tools_label=Εργαλεία +first_page.title=Μετάβαση στην πρώτη σελίδα +first_page.label=Μετάβαση στην πρώτη σελίδα +first_page_label=Μετάβαση στην πρώτη σελίδα +last_page.title=Μετάβαση στη τελευταία σελίδα +last_page.label=Μετάβαση στη τελευταία σελίδα +last_page_label=Μετάβαση στη τελευταία σελίδα +page_rotate_cw.title=Δεξιόστροφη περιστροφή +page_rotate_cw.label=Δεξιόστροφη περιστροφή +page_rotate_cw_label=Δεξιόστροφη περιστροφή +page_rotate_ccw.title=Αριστερόστροφη περιστροφή +page_rotate_ccw.label=Αριστερόστροφη περιστροφή +page_rotate_ccw_label=Αριστερόστροφη περιστροφή + +hand_tool_enable.title=Ενεργοποίηση εργαλείου χεριού +hand_tool_enable_label=Ενεργοποίηση εργαλείου χεριού +hand_tool_disable.title=Απενεργοποίηση εργαλείου χεριού +hand_tool_disable_label=Απενεργοποίηση εργαλείου χεριού + +# Document properties dialog box +document_properties.title=Ιδιότητες εγγράφου… +document_properties_label=Ιδιότητες εγγράφου… +document_properties_file_name=Όνομα αρχείου: +document_properties_file_size=Μέγεθος αρχείου: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Τίτλος: +document_properties_author=Συγγραφέας: +document_properties_subject=Θέμα: +document_properties_keywords=Λέξεις κλειδιά: +document_properties_creation_date=Ημερομηνία δημιουργίας: +document_properties_modification_date=Ημερομηνία τροποποίησης: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_creator=Δημιουργός: +document_properties_producer=Παραγωγός PDF: +document_properties_version=Έκδοση PDF: +document_properties_page_count=Αριθμός σελίδων: +document_properties_close=Κλείσιμο + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Εναλλαγή προβολής πλευρικής στήλης +toggle_sidebar_label=Εναλλαγή προβολής πλευρικής στήλης +outline.title=Προβολή διάρθρωσης κειμένου +outline_label=Διάρθρωση κειμένου +attachments.title=Προβολή συνημμένου +attachments_label=Συνημμένα +thumbs.title=Προβολή μικρογραφιών +thumbs_label=Μικρογραφίες +findbar.title=Εύρεση στο έγγραφο +findbar_label=Εύρεση + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Σελίδα {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Μικρογραφία της σελίδας {{page}} + +# Find panel button title and messages +find_label=Εύρεση: +find_previous.title=Εύρεση της προηγούμενης εμφάνισης της φράσης +find_previous_label=Προηγούμενο +find_next.title=Εύρεση της επόμενης εμφάνισης της φράσης +find_next_label=Επόμενο +find_highlight=Επισήμανση όλων +find_match_case_label=Ταίριασμα χαρακτήρα +find_reached_top=Έλευση στην αρχή του εγγράφου, συνέχεια από το τέλος +find_reached_bottom=Έλευση στο τέλος του εγγράφου, συνέχεια από την αρχή +find_not_found=Η φράση δεν βρέθηκε + +# Error panel labels +error_more_info=Περισσότερες πληροφορίες +error_less_info=Λιγότερες πληροφορίες +error_close=Κλείσιμο +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Μήνυμα: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Αρχείο: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +rendering_error=Προέκυψε σφάλμα κατά την ανάλυση της σελίδας. + +# Predefined zoom values +page_scale_width=Πλάτος σελίδας +page_scale_fit=Μέγεθος σελίδας +page_scale_auto=Αυτόματη μεγέθυνση +page_scale_actual=Πραγματικό μέγεθος +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Σφάλμα +loading_error=Προέκυψε ένα σφάλμα κατά τη φόρτωση του PDF. +invalid_file_error=Μη έγκυρο ή κατεστραμμένο αρχείο PDF. +missing_file_error=Λείπει αρχείο PDF. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Σχόλιο] +password_label=Εισαγωγή κωδικού για το άνοιγμα του PDF αρχείου. +password_invalid=Μη έγκυρος κωδικός. Προσπαθείστε ξανά. +password_ok=ΟΚ +password_cancel=Ακύρωση + +printing_not_supported=Προειδοποίηση: Η εκτύπωση δεν υποστηρίζεται πλήρως από αυτόν τον περιηγητή. +printing_not_ready=Προειδοποίηση: Το PDF δεν φορτώθηκε πλήρως για εκτύπωση. +web_fonts_disabled=Οι γραμματοσειρές Web απενεργοποιημένες: αδυναμία χρήσης των ενσωματωμένων γραμματοσειρών PDF. +document_colors_disabled=Δεν επιτρέπεται στα έγγραφα PDF να χρησιμοποιούν τα δικά τους χρώματα: Η επιλογή \'Να επιτρέπεται η χρήση χρωμάτων της σελίδας\' δεν είναι ενεργή στην εφαρμογή. diff --git a/static/pdf.js/locale/en-CA/viewer.ftl b/static/pdf.js/locale/en-CA/viewer.ftl deleted file mode 100644 index f87104e7..00000000 --- a/static/pdf.js/locale/en-CA/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Previous Page -pdfjs-previous-button-label = Previous -pdfjs-next-button = - .title = Next Page -pdfjs-next-button-label = Next -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Page -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = of { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } of { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom Out -pdfjs-zoom-out-button-label = Zoom Out -pdfjs-zoom-in-button = - .title = Zoom In -pdfjs-zoom-in-button-label = Zoom In -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Switch to Presentation Mode -pdfjs-presentation-mode-button-label = Presentation Mode -pdfjs-open-file-button = - .title = Open File -pdfjs-open-file-button-label = Open -pdfjs-print-button = - .title = Print -pdfjs-print-button-label = Print -pdfjs-save-button = - .title = Save -pdfjs-save-button-label = Save -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Download -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Download -pdfjs-bookmark-button = - .title = Current Page (View URL from Current Page) -pdfjs-bookmark-button-label = Current Page -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Open in app -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Open in app - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tools -pdfjs-tools-button-label = Tools -pdfjs-first-page-button = - .title = Go to First Page -pdfjs-first-page-button-label = Go to First Page -pdfjs-last-page-button = - .title = Go to Last Page -pdfjs-last-page-button-label = Go to Last Page -pdfjs-page-rotate-cw-button = - .title = Rotate Clockwise -pdfjs-page-rotate-cw-button-label = Rotate Clockwise -pdfjs-page-rotate-ccw-button = - .title = Rotate Counterclockwise -pdfjs-page-rotate-ccw-button-label = Rotate Counterclockwise -pdfjs-cursor-text-select-tool-button = - .title = Enable Text Selection Tool -pdfjs-cursor-text-select-tool-button-label = Text Selection Tool -pdfjs-cursor-hand-tool-button = - .title = Enable Hand Tool -pdfjs-cursor-hand-tool-button-label = Hand Tool -pdfjs-scroll-page-button = - .title = Use Page Scrolling -pdfjs-scroll-page-button-label = Page Scrolling -pdfjs-scroll-vertical-button = - .title = Use Vertical Scrolling -pdfjs-scroll-vertical-button-label = Vertical Scrolling -pdfjs-scroll-horizontal-button = - .title = Use Horizontal Scrolling -pdfjs-scroll-horizontal-button-label = Horizontal Scrolling -pdfjs-scroll-wrapped-button = - .title = Use Wrapped Scrolling -pdfjs-scroll-wrapped-button-label = Wrapped Scrolling -pdfjs-spread-none-button = - .title = Do not join page spreads -pdfjs-spread-none-button-label = No Spreads -pdfjs-spread-odd-button = - .title = Join page spreads starting with odd-numbered pages -pdfjs-spread-odd-button-label = Odd Spreads -pdfjs-spread-even-button = - .title = Join page spreads starting with even-numbered pages -pdfjs-spread-even-button-label = Even Spreads - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Document Properties… -pdfjs-document-properties-button-label = Document Properties… -pdfjs-document-properties-file-name = File name: -pdfjs-document-properties-file-size = File size: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Title: -pdfjs-document-properties-author = Author: -pdfjs-document-properties-subject = Subject: -pdfjs-document-properties-keywords = Keywords: -pdfjs-document-properties-creation-date = Creation Date: -pdfjs-document-properties-modification-date = Modification Date: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creator: -pdfjs-document-properties-producer = PDF Producer: -pdfjs-document-properties-version = PDF Version: -pdfjs-document-properties-page-count = Page Count: -pdfjs-document-properties-page-size = Page Size: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portrait -pdfjs-document-properties-page-size-orientation-landscape = landscape -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Yes -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Close - -## Print - -pdfjs-print-progress-message = Preparing document for printing… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancel -pdfjs-printing-not-supported = Warning: Printing is not fully supported by this browser. -pdfjs-printing-not-ready = Warning: The PDF is not fully loaded for printing. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Toggle Sidebar -pdfjs-toggle-sidebar-notification-button = - .title = Toggle Sidebar (document contains outline/attachments/layers) -pdfjs-toggle-sidebar-button-label = Toggle Sidebar -pdfjs-document-outline-button = - .title = Show Document Outline (double-click to expand/collapse all items) -pdfjs-document-outline-button-label = Document Outline -pdfjs-attachments-button = - .title = Show Attachments -pdfjs-attachments-button-label = Attachments -pdfjs-layers-button = - .title = Show Layers (double-click to reset all layers to the default state) -pdfjs-layers-button-label = Layers -pdfjs-thumbs-button = - .title = Show Thumbnails -pdfjs-thumbs-button-label = Thumbnails -pdfjs-current-outline-item-button = - .title = Find Current Outline Item -pdfjs-current-outline-item-button-label = Current Outline Item -pdfjs-findbar-button = - .title = Find in Document -pdfjs-findbar-button-label = Find -pdfjs-additional-layers = Additional Layers - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Page { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Thumbnail of Page { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Find - .placeholder = Find in document… -pdfjs-find-previous-button = - .title = Find the previous occurrence of the phrase -pdfjs-find-previous-button-label = Previous -pdfjs-find-next-button = - .title = Find the next occurrence of the phrase -pdfjs-find-next-button-label = Next -pdfjs-find-highlight-checkbox = Highlight All -pdfjs-find-match-case-checkbox-label = Match Case -pdfjs-find-match-diacritics-checkbox-label = Match Diacritics -pdfjs-find-entire-word-checkbox-label = Whole Words -pdfjs-find-reached-top = Reached top of document, continued from bottom -pdfjs-find-reached-bottom = Reached end of document, continued from top -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } of { $total } match - *[other] { $current } of { $total } matches - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] More than { $limit } match - *[other] More than { $limit } matches - } -pdfjs-find-not-found = Phrase not found - -## Predefined zoom values - -pdfjs-page-scale-width = Page Width -pdfjs-page-scale-fit = Page Fit -pdfjs-page-scale-auto = Automatic Zoom -pdfjs-page-scale-actual = Actual Size -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Page { $page } - -## Loading indicator messages - -pdfjs-loading-error = An error occurred while loading the PDF. -pdfjs-invalid-file-error = Invalid or corrupted PDF file. -pdfjs-missing-file-error = Missing PDF file. -pdfjs-unexpected-response-error = Unexpected server response. -pdfjs-rendering-error = An error occurred while rendering the page. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Enter the password to open this PDF file. -pdfjs-password-invalid = Invalid password. Please try again. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Cancel -pdfjs-web-fonts-disabled = Web fonts are disabled: unable to use embedded PDF fonts. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Draw -pdfjs-editor-ink-button-label = Draw -pdfjs-editor-stamp-button = - .title = Add or edit images -pdfjs-editor-stamp-button-label = Add or edit images -pdfjs-editor-highlight-button = - .title = Highlight -pdfjs-editor-highlight-button-label = Highlight -pdfjs-highlight-floating-button = - .title = Highlight -pdfjs-highlight-floating-button1 = - .title = Highlight - .aria-label = Highlight -pdfjs-highlight-floating-button-label = Highlight - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Remove drawing -pdfjs-editor-remove-freetext-button = - .title = Remove text -pdfjs-editor-remove-stamp-button = - .title = Remove image -pdfjs-editor-remove-highlight-button = - .title = Remove highlight - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Colour -pdfjs-editor-free-text-size-input = Size -pdfjs-editor-ink-color-input = Colour -pdfjs-editor-ink-thickness-input = Thickness -pdfjs-editor-ink-opacity-input = Opacity -pdfjs-editor-stamp-add-image-button = - .title = Add image -pdfjs-editor-stamp-add-image-button-label = Add image -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Thickness -pdfjs-editor-free-highlight-thickness-title = - .title = Change thickness when highlighting items other than text -pdfjs-free-text = - .aria-label = Text Editor -pdfjs-free-text-default-content = Start typing… -pdfjs-ink = - .aria-label = Draw Editor -pdfjs-ink-canvas = - .aria-label = User-created image - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alt text -pdfjs-editor-alt-text-edit-button-label = Edit alt text -pdfjs-editor-alt-text-dialog-label = Choose an option -pdfjs-editor-alt-text-dialog-description = Alt text (alternative text) helps when people can’t see the image or when it doesn’t load. -pdfjs-editor-alt-text-add-description-label = Add a description -pdfjs-editor-alt-text-add-description-description = Aim for 1-2 sentences that describe the subject, setting, or actions. -pdfjs-editor-alt-text-mark-decorative-label = Mark as decorative -pdfjs-editor-alt-text-mark-decorative-description = This is used for ornamental images, like borders or watermarks. -pdfjs-editor-alt-text-cancel-button = Cancel -pdfjs-editor-alt-text-save-button = Save -pdfjs-editor-alt-text-decorative-tooltip = Marked as decorative -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = For example, “A young man sits down at a table to eat a meal” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Top left corner — resize -pdfjs-editor-resizer-label-top-middle = Top middle — resize -pdfjs-editor-resizer-label-top-right = Top right corner — resize -pdfjs-editor-resizer-label-middle-right = Middle right — resize -pdfjs-editor-resizer-label-bottom-right = Bottom right corner — resize -pdfjs-editor-resizer-label-bottom-middle = Bottom middle — resize -pdfjs-editor-resizer-label-bottom-left = Bottom left corner — resize -pdfjs-editor-resizer-label-middle-left = Middle left — resize - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Highlight colour -pdfjs-editor-colorpicker-button = - .title = Change colour -pdfjs-editor-colorpicker-dropdown = - .aria-label = Colour choices -pdfjs-editor-colorpicker-yellow = - .title = Yellow -pdfjs-editor-colorpicker-green = - .title = Green -pdfjs-editor-colorpicker-blue = - .title = Blue -pdfjs-editor-colorpicker-pink = - .title = Pink -pdfjs-editor-colorpicker-red = - .title = Red - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Show all -pdfjs-editor-highlight-show-all-button = - .title = Show all diff --git a/static/pdf.js/locale/en-GB/viewer.ftl b/static/pdf.js/locale/en-GB/viewer.ftl deleted file mode 100644 index 3b141aee..00000000 --- a/static/pdf.js/locale/en-GB/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Previous Page -pdfjs-previous-button-label = Previous -pdfjs-next-button = - .title = Next Page -pdfjs-next-button-label = Next -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Page -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = of { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } of { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom Out -pdfjs-zoom-out-button-label = Zoom Out -pdfjs-zoom-in-button = - .title = Zoom In -pdfjs-zoom-in-button-label = Zoom In -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Switch to Presentation Mode -pdfjs-presentation-mode-button-label = Presentation Mode -pdfjs-open-file-button = - .title = Open File -pdfjs-open-file-button-label = Open -pdfjs-print-button = - .title = Print -pdfjs-print-button-label = Print -pdfjs-save-button = - .title = Save -pdfjs-save-button-label = Save -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Download -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Download -pdfjs-bookmark-button = - .title = Current Page (View URL from Current Page) -pdfjs-bookmark-button-label = Current Page -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Open in app -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Open in app - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tools -pdfjs-tools-button-label = Tools -pdfjs-first-page-button = - .title = Go to First Page -pdfjs-first-page-button-label = Go to First Page -pdfjs-last-page-button = - .title = Go to Last Page -pdfjs-last-page-button-label = Go to Last Page -pdfjs-page-rotate-cw-button = - .title = Rotate Clockwise -pdfjs-page-rotate-cw-button-label = Rotate Clockwise -pdfjs-page-rotate-ccw-button = - .title = Rotate Anti-Clockwise -pdfjs-page-rotate-ccw-button-label = Rotate Anti-Clockwise -pdfjs-cursor-text-select-tool-button = - .title = Enable Text Selection Tool -pdfjs-cursor-text-select-tool-button-label = Text Selection Tool -pdfjs-cursor-hand-tool-button = - .title = Enable Hand Tool -pdfjs-cursor-hand-tool-button-label = Hand Tool -pdfjs-scroll-page-button = - .title = Use Page Scrolling -pdfjs-scroll-page-button-label = Page Scrolling -pdfjs-scroll-vertical-button = - .title = Use Vertical Scrolling -pdfjs-scroll-vertical-button-label = Vertical Scrolling -pdfjs-scroll-horizontal-button = - .title = Use Horizontal Scrolling -pdfjs-scroll-horizontal-button-label = Horizontal Scrolling -pdfjs-scroll-wrapped-button = - .title = Use Wrapped Scrolling -pdfjs-scroll-wrapped-button-label = Wrapped Scrolling -pdfjs-spread-none-button = - .title = Do not join page spreads -pdfjs-spread-none-button-label = No Spreads -pdfjs-spread-odd-button = - .title = Join page spreads starting with odd-numbered pages -pdfjs-spread-odd-button-label = Odd Spreads -pdfjs-spread-even-button = - .title = Join page spreads starting with even-numbered pages -pdfjs-spread-even-button-label = Even Spreads - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Document Properties… -pdfjs-document-properties-button-label = Document Properties… -pdfjs-document-properties-file-name = File name: -pdfjs-document-properties-file-size = File size: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Title: -pdfjs-document-properties-author = Author: -pdfjs-document-properties-subject = Subject: -pdfjs-document-properties-keywords = Keywords: -pdfjs-document-properties-creation-date = Creation Date: -pdfjs-document-properties-modification-date = Modification Date: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creator: -pdfjs-document-properties-producer = PDF Producer: -pdfjs-document-properties-version = PDF Version: -pdfjs-document-properties-page-count = Page Count: -pdfjs-document-properties-page-size = Page Size: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portrait -pdfjs-document-properties-page-size-orientation-landscape = landscape -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Yes -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Close - -## Print - -pdfjs-print-progress-message = Preparing document for printing… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancel -pdfjs-printing-not-supported = Warning: Printing is not fully supported by this browser. -pdfjs-printing-not-ready = Warning: The PDF is not fully loaded for printing. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Toggle Sidebar -pdfjs-toggle-sidebar-notification-button = - .title = Toggle Sidebar (document contains outline/attachments/layers) -pdfjs-toggle-sidebar-button-label = Toggle Sidebar -pdfjs-document-outline-button = - .title = Show Document Outline (double-click to expand/collapse all items) -pdfjs-document-outline-button-label = Document Outline -pdfjs-attachments-button = - .title = Show Attachments -pdfjs-attachments-button-label = Attachments -pdfjs-layers-button = - .title = Show Layers (double-click to reset all layers to the default state) -pdfjs-layers-button-label = Layers -pdfjs-thumbs-button = - .title = Show Thumbnails -pdfjs-thumbs-button-label = Thumbnails -pdfjs-current-outline-item-button = - .title = Find Current Outline Item -pdfjs-current-outline-item-button-label = Current Outline Item -pdfjs-findbar-button = - .title = Find in Document -pdfjs-findbar-button-label = Find -pdfjs-additional-layers = Additional Layers - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Page { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Thumbnail of Page { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Find - .placeholder = Find in document… -pdfjs-find-previous-button = - .title = Find the previous occurrence of the phrase -pdfjs-find-previous-button-label = Previous -pdfjs-find-next-button = - .title = Find the next occurrence of the phrase -pdfjs-find-next-button-label = Next -pdfjs-find-highlight-checkbox = Highlight All -pdfjs-find-match-case-checkbox-label = Match Case -pdfjs-find-match-diacritics-checkbox-label = Match Diacritics -pdfjs-find-entire-word-checkbox-label = Whole Words -pdfjs-find-reached-top = Reached top of document, continued from bottom -pdfjs-find-reached-bottom = Reached end of document, continued from top -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } of { $total } match - *[other] { $current } of { $total } matches - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] More than { $limit } match - *[other] More than { $limit } matches - } -pdfjs-find-not-found = Phrase not found - -## Predefined zoom values - -pdfjs-page-scale-width = Page Width -pdfjs-page-scale-fit = Page Fit -pdfjs-page-scale-auto = Automatic Zoom -pdfjs-page-scale-actual = Actual Size -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Page { $page } - -## Loading indicator messages - -pdfjs-loading-error = An error occurred while loading the PDF. -pdfjs-invalid-file-error = Invalid or corrupted PDF file. -pdfjs-missing-file-error = Missing PDF file. -pdfjs-unexpected-response-error = Unexpected server response. -pdfjs-rendering-error = An error occurred while rendering the page. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Enter the password to open this PDF file. -pdfjs-password-invalid = Invalid password. Please try again. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Cancel -pdfjs-web-fonts-disabled = Web fonts are disabled: unable to use embedded PDF fonts. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Draw -pdfjs-editor-ink-button-label = Draw -pdfjs-editor-stamp-button = - .title = Add or edit images -pdfjs-editor-stamp-button-label = Add or edit images -pdfjs-editor-highlight-button = - .title = Highlight -pdfjs-editor-highlight-button-label = Highlight -pdfjs-highlight-floating-button = - .title = Highlight -pdfjs-highlight-floating-button1 = - .title = Highlight - .aria-label = Highlight -pdfjs-highlight-floating-button-label = Highlight - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Remove drawing -pdfjs-editor-remove-freetext-button = - .title = Remove text -pdfjs-editor-remove-stamp-button = - .title = Remove image -pdfjs-editor-remove-highlight-button = - .title = Remove highlight - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Colour -pdfjs-editor-free-text-size-input = Size -pdfjs-editor-ink-color-input = Colour -pdfjs-editor-ink-thickness-input = Thickness -pdfjs-editor-ink-opacity-input = Opacity -pdfjs-editor-stamp-add-image-button = - .title = Add image -pdfjs-editor-stamp-add-image-button-label = Add image -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Thickness -pdfjs-editor-free-highlight-thickness-title = - .title = Change thickness when highlighting items other than text -pdfjs-free-text = - .aria-label = Text Editor -pdfjs-free-text-default-content = Start typing… -pdfjs-ink = - .aria-label = Draw Editor -pdfjs-ink-canvas = - .aria-label = User-created image - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alt text -pdfjs-editor-alt-text-edit-button-label = Edit alt text -pdfjs-editor-alt-text-dialog-label = Choose an option -pdfjs-editor-alt-text-dialog-description = Alt text (alternative text) helps when people can’t see the image or when it doesn’t load. -pdfjs-editor-alt-text-add-description-label = Add a description -pdfjs-editor-alt-text-add-description-description = Aim for 1-2 sentences that describe the subject, setting, or actions. -pdfjs-editor-alt-text-mark-decorative-label = Mark as decorative -pdfjs-editor-alt-text-mark-decorative-description = This is used for ornamental images, like borders or watermarks. -pdfjs-editor-alt-text-cancel-button = Cancel -pdfjs-editor-alt-text-save-button = Save -pdfjs-editor-alt-text-decorative-tooltip = Marked as decorative -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = For example, “A young man sits down at a table to eat a meal” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Top left corner — resize -pdfjs-editor-resizer-label-top-middle = Top middle — resize -pdfjs-editor-resizer-label-top-right = Top right corner — resize -pdfjs-editor-resizer-label-middle-right = Middle right — resize -pdfjs-editor-resizer-label-bottom-right = Bottom right corner — resize -pdfjs-editor-resizer-label-bottom-middle = Bottom middle — resize -pdfjs-editor-resizer-label-bottom-left = Bottom left corner — resize -pdfjs-editor-resizer-label-middle-left = Middle left — resize - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Highlight colour -pdfjs-editor-colorpicker-button = - .title = Change colour -pdfjs-editor-colorpicker-dropdown = - .aria-label = Colour choices -pdfjs-editor-colorpicker-yellow = - .title = Yellow -pdfjs-editor-colorpicker-green = - .title = Green -pdfjs-editor-colorpicker-blue = - .title = Blue -pdfjs-editor-colorpicker-pink = - .title = Pink -pdfjs-editor-colorpicker-red = - .title = Red - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Show all -pdfjs-editor-highlight-show-all-button = - .title = Show all diff --git a/static/pdf.js/locale/en-GB/viewer.properties b/static/pdf.js/locale/en-GB/viewer.properties new file mode 100644 index 00000000..d0d1e647 --- /dev/null +++ b/static/pdf.js/locale/en-GB/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Previous Page +previous_label=Previous +next.title=Next Page +next_label=Next + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Page: +page_of=of {{pageCount}} + +zoom_out.title=Zoom Out +zoom_out_label=Zoom Out +zoom_in.title=Zoom In +zoom_in_label=Zoom In +zoom.title=Zoom +presentation_mode.title=Switch to Presentation Mode +presentation_mode_label=Presentation Mode +open_file.title=Open File +open_file_label=Open +print.title=Print +print_label=Print +download.title=Download +download_label=Download +bookmark.title=Current view (copy or open in new window) +bookmark_label=Current View + +# Secondary toolbar and context menu +tools.title=Tools +tools_label=Tools +first_page.title=Go to First Page +first_page.label=Go to First Page +first_page_label=Go to First Page +last_page.title=Go to Last Page +last_page.label=Go to Last Page +last_page_label=Go to Last Page +page_rotate_cw.title=Rotate Clockwise +page_rotate_cw.label=Rotate Clockwise +page_rotate_cw_label=Rotate Clockwise +page_rotate_ccw.title=Rotate Anti-Clockwise +page_rotate_ccw.label=Rotate Anti-Clockwise +page_rotate_ccw_label=Rotate Anti-Clockwise + +hand_tool_enable.title=Enable hand tool +hand_tool_enable_label=Enable hand tool +hand_tool_disable.title=Disable hand tool +hand_tool_disable_label=Disable hand tool + +# Document properties dialog box +document_properties.title=Document Properties… +document_properties_label=Document Properties… +document_properties_file_name=File name: +document_properties_file_size=File size: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} kB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Title: +document_properties_author=Author: +document_properties_subject=Subject: +document_properties_keywords=Keywords: +document_properties_creation_date=Creation Date: +document_properties_modification_date=Modification Date: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creator: +document_properties_producer=PDF Producer: +document_properties_version=PDF Version: +document_properties_page_count=Page Count: +document_properties_close=Close + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Toggle Sidebar +toggle_sidebar_label=Toggle Sidebar +outline.title=Show Document Outline +outline_label=Document Outline +attachments.title=Show Attachments +attachments_label=Attachments +thumbs.title=Show Thumbnails +thumbs_label=Thumbnails +findbar.title=Find in Document +findbar_label=Find + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Page {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Thumbnail of Page {{page}} + +# Find panel button title and messages +find_label=Find: +find_previous.title=Find the previous occurrence of the phrase +find_previous_label=Previous +find_next.title=Find the next occurrence of the phrase +find_next_label=Next +find_highlight=Highlight all +find_match_case_label=Match case +find_reached_top=Reached top of document, continued from bottom +find_reached_bottom=Reached end of document, continued from top +find_not_found=Phrase not found + +# Error panel labels +error_more_info=More Information +error_less_info=Less Information +error_close=Close +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Message: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=File: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Line: {{line}} +rendering_error=An error occurred while rendering the page. + +# Predefined zoom values +page_scale_width=Page Width +page_scale_fit=Page Fit +page_scale_auto=Automatic Zoom +page_scale_actual=Actual Size +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Error +loading_error=An error occurred while loading the PDF. +invalid_file_error=Invalid or corrupted PDF file. +missing_file_error=Missing PDF file. +unexpected_response_error=Unexpected server response. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=Enter the password to open this PDF file. +password_invalid=Invalid password. Please try again. +password_ok=OK +password_cancel=Cancel + +printing_not_supported=Warning: Printing is not fully supported by this browser. +printing_not_ready=Warning: The PDF is not fully loaded for printing. +web_fonts_disabled=Web fonts are disabled: unable to use embedded PDF fonts. +document_colors_not_allowed=PDF documents are not allowed to use their own colours: 'Allow pages to choose their own colours' is deactivated in the browser. diff --git a/static/pdf.js/locale/en-US/viewer.ftl b/static/pdf.js/locale/en-US/viewer.ftl deleted file mode 100644 index 8aea4395..00000000 --- a/static/pdf.js/locale/en-US/viewer.ftl +++ /dev/null @@ -1,418 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Previous Page -pdfjs-previous-button-label = Previous -pdfjs-next-button = - .title = Next Page -pdfjs-next-button-label = Next - -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Page - -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = of { $pagesCount } - -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } of { $pagesCount }) - -pdfjs-zoom-out-button = - .title = Zoom Out -pdfjs-zoom-out-button-label = Zoom Out -pdfjs-zoom-in-button = - .title = Zoom In -pdfjs-zoom-in-button-label = Zoom In -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Switch to Presentation Mode -pdfjs-presentation-mode-button-label = Presentation Mode -pdfjs-open-file-button = - .title = Open File -pdfjs-open-file-button-label = Open -pdfjs-print-button = - .title = Print -pdfjs-print-button-label = Print -pdfjs-save-button = - .title = Save -pdfjs-save-button-label = Save - -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Download - -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Download - -pdfjs-bookmark-button = - .title = Current Page (View URL from Current Page) -pdfjs-bookmark-button-label = Current Page - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tools - -pdfjs-tools-button-label = Tools -pdfjs-first-page-button = - .title = Go to First Page -pdfjs-first-page-button-label = Go to First Page -pdfjs-last-page-button = - .title = Go to Last Page -pdfjs-last-page-button-label = Go to Last Page -pdfjs-page-rotate-cw-button = - .title = Rotate Clockwise -pdfjs-page-rotate-cw-button-label = Rotate Clockwise -pdfjs-page-rotate-ccw-button = - .title = Rotate Counterclockwise -pdfjs-page-rotate-ccw-button-label = Rotate Counterclockwise -pdfjs-cursor-text-select-tool-button = - .title = Enable Text Selection Tool -pdfjs-cursor-text-select-tool-button-label = Text Selection Tool -pdfjs-cursor-hand-tool-button = - .title = Enable Hand Tool -pdfjs-cursor-hand-tool-button-label = Hand Tool -pdfjs-scroll-page-button = - .title = Use Page Scrolling -pdfjs-scroll-page-button-label = Page Scrolling -pdfjs-scroll-vertical-button = - .title = Use Vertical Scrolling -pdfjs-scroll-vertical-button-label = Vertical Scrolling -pdfjs-scroll-horizontal-button = - .title = Use Horizontal Scrolling -pdfjs-scroll-horizontal-button-label = Horizontal Scrolling -pdfjs-scroll-wrapped-button = - .title = Use Wrapped Scrolling -pdfjs-scroll-wrapped-button-label = Wrapped Scrolling -pdfjs-spread-none-button = - .title = Do not join page spreads -pdfjs-spread-none-button-label = No Spreads -pdfjs-spread-odd-button = - .title = Join page spreads starting with odd-numbered pages -pdfjs-spread-odd-button-label = Odd Spreads -pdfjs-spread-even-button = - .title = Join page spreads starting with even-numbered pages -pdfjs-spread-even-button-label = Even Spreads - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Document Properties… -pdfjs-document-properties-button-label = Document Properties… -pdfjs-document-properties-file-name = File name: -pdfjs-document-properties-file-size = File size: - -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) - -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) - -pdfjs-document-properties-title = Title: -pdfjs-document-properties-author = Author: -pdfjs-document-properties-subject = Subject: -pdfjs-document-properties-keywords = Keywords: -pdfjs-document-properties-creation-date = Creation Date: -pdfjs-document-properties-modification-date = Modification Date: - -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } - -pdfjs-document-properties-creator = Creator: -pdfjs-document-properties-producer = PDF Producer: -pdfjs-document-properties-version = PDF Version: -pdfjs-document-properties-page-count = Page Count: -pdfjs-document-properties-page-size = Page Size: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portrait -pdfjs-document-properties-page-size-orientation-landscape = landscape -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Yes -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Close - -## Print - -pdfjs-print-progress-message = Preparing document for printing… - -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% - -pdfjs-print-progress-close-button = Cancel -pdfjs-printing-not-supported = Warning: Printing is not fully supported by this browser. -pdfjs-printing-not-ready = Warning: The PDF is not fully loaded for printing. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Toggle Sidebar -pdfjs-toggle-sidebar-notification-button = - .title = Toggle Sidebar (document contains outline/attachments/layers) -pdfjs-toggle-sidebar-button-label = Toggle Sidebar -pdfjs-document-outline-button = - .title = Show Document Outline (double-click to expand/collapse all items) -pdfjs-document-outline-button-label = Document Outline -pdfjs-attachments-button = - .title = Show Attachments -pdfjs-attachments-button-label = Attachments -pdfjs-layers-button = - .title = Show Layers (double-click to reset all layers to the default state) -pdfjs-layers-button-label = Layers -pdfjs-thumbs-button = - .title = Show Thumbnails -pdfjs-thumbs-button-label = Thumbnails -pdfjs-current-outline-item-button = - .title = Find Current Outline Item -pdfjs-current-outline-item-button-label = Current Outline Item -pdfjs-findbar-button = - .title = Find in Document -pdfjs-findbar-button-label = Find -pdfjs-additional-layers = Additional Layers - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Page { $page } - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Thumbnail of Page { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Find - .placeholder = Find in document… -pdfjs-find-previous-button = - .title = Find the previous occurrence of the phrase -pdfjs-find-previous-button-label = Previous -pdfjs-find-next-button = - .title = Find the next occurrence of the phrase -pdfjs-find-next-button-label = Next -pdfjs-find-highlight-checkbox = Highlight All -pdfjs-find-match-case-checkbox-label = Match Case -pdfjs-find-match-diacritics-checkbox-label = Match Diacritics -pdfjs-find-entire-word-checkbox-label = Whole Words -pdfjs-find-reached-top = Reached top of document, continued from bottom -pdfjs-find-reached-bottom = Reached end of document, continued from top - -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } of { $total } match - *[other] { $current } of { $total } matches - } - -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] More than { $limit } match - *[other] More than { $limit } matches - } - -pdfjs-find-not-found = Phrase not found - -## Predefined zoom values - -pdfjs-page-scale-width = Page Width -pdfjs-page-scale-fit = Page Fit -pdfjs-page-scale-auto = Automatic Zoom -pdfjs-page-scale-actual = Actual Size - -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Page { $page } - -## Loading indicator messages - -pdfjs-loading-error = An error occurred while loading the PDF. -pdfjs-invalid-file-error = Invalid or corrupted PDF file. -pdfjs-missing-file-error = Missing PDF file. -pdfjs-unexpected-response-error = Unexpected server response. -pdfjs-rendering-error = An error occurred while rendering the page. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Enter the password to open this PDF file. -pdfjs-password-invalid = Invalid password. Please try again. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Cancel -pdfjs-web-fonts-disabled = Web fonts are disabled: unable to use embedded PDF fonts. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Draw -pdfjs-editor-ink-button-label = Draw -pdfjs-editor-stamp-button = - .title = Add or edit images -pdfjs-editor-stamp-button-label = Add or edit images -pdfjs-editor-highlight-button = - .title = Highlight -pdfjs-editor-highlight-button-label = Highlight -pdfjs-highlight-floating-button1 = - .title = Highlight - .aria-label = Highlight -pdfjs-highlight-floating-button-label = Highlight - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Remove drawing -pdfjs-editor-remove-freetext-button = - .title = Remove text -pdfjs-editor-remove-stamp-button = - .title = Remove image -pdfjs-editor-remove-highlight-button = - .title = Remove highlight - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Color -pdfjs-editor-free-text-size-input = Size -pdfjs-editor-ink-color-input = Color -pdfjs-editor-ink-thickness-input = Thickness -pdfjs-editor-ink-opacity-input = Opacity -pdfjs-editor-stamp-add-image-button = - .title = Add image -pdfjs-editor-stamp-add-image-button-label = Add image -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Thickness -pdfjs-editor-free-highlight-thickness-title = - .title = Change thickness when highlighting items other than text - -pdfjs-free-text = - .aria-label = Text Editor -pdfjs-free-text-default-content = Start typing… -pdfjs-ink = - .aria-label = Draw Editor -pdfjs-ink-canvas = - .aria-label = User-created image - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alt text - -pdfjs-editor-alt-text-edit-button-label = Edit alt text -pdfjs-editor-alt-text-dialog-label = Choose an option -pdfjs-editor-alt-text-dialog-description = Alt text (alternative text) helps when people can’t see the image or when it doesn’t load. -pdfjs-editor-alt-text-add-description-label = Add a description -pdfjs-editor-alt-text-add-description-description = Aim for 1-2 sentences that describe the subject, setting, or actions. -pdfjs-editor-alt-text-mark-decorative-label = Mark as decorative -pdfjs-editor-alt-text-mark-decorative-description = This is used for ornamental images, like borders or watermarks. -pdfjs-editor-alt-text-cancel-button = Cancel -pdfjs-editor-alt-text-save-button = Save -pdfjs-editor-alt-text-decorative-tooltip = Marked as decorative - -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = For example, “A young man sits down at a table to eat a meal” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Top left corner — resize -pdfjs-editor-resizer-label-top-middle = Top middle — resize -pdfjs-editor-resizer-label-top-right = Top right corner — resize -pdfjs-editor-resizer-label-middle-right = Middle right — resize -pdfjs-editor-resizer-label-bottom-right = Bottom right corner — resize -pdfjs-editor-resizer-label-bottom-middle = Bottom middle — resize -pdfjs-editor-resizer-label-bottom-left = Bottom left corner — resize -pdfjs-editor-resizer-label-middle-left = Middle left — resize - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Highlight color - -pdfjs-editor-colorpicker-button = - .title = Change color -pdfjs-editor-colorpicker-dropdown = - .aria-label = Color choices -pdfjs-editor-colorpicker-yellow = - .title = Yellow -pdfjs-editor-colorpicker-green = - .title = Green -pdfjs-editor-colorpicker-blue = - .title = Blue -pdfjs-editor-colorpicker-pink = - .title = Pink -pdfjs-editor-colorpicker-red = - .title = Red - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Show all -pdfjs-editor-highlight-show-all-button = - .title = Show all diff --git a/static/pdf.js/locale/en-US/viewer.properties b/static/pdf.js/locale/en-US/viewer.properties new file mode 100644 index 00000000..20c91956 --- /dev/null +++ b/static/pdf.js/locale/en-US/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Previous Page +previous_label=Previous +next.title=Next Page +next_label=Next + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Page: +page_of=of {{pageCount}} + +zoom_out.title=Zoom Out +zoom_out_label=Zoom Out +zoom_in.title=Zoom In +zoom_in_label=Zoom In +zoom.title=Zoom +presentation_mode.title=Switch to Presentation Mode +presentation_mode_label=Presentation Mode +open_file.title=Open File +open_file_label=Open +print.title=Print +print_label=Print +download.title=Download +download_label=Download +bookmark.title=Current view (copy or open in new window) +bookmark_label=Current View + +# Secondary toolbar and context menu +tools.title=Tools +tools_label=Tools +first_page.title=Go to First Page +first_page.label=Go to First Page +first_page_label=Go to First Page +last_page.title=Go to Last Page +last_page.label=Go to Last Page +last_page_label=Go to Last Page +page_rotate_cw.title=Rotate Clockwise +page_rotate_cw.label=Rotate Clockwise +page_rotate_cw_label=Rotate Clockwise +page_rotate_ccw.title=Rotate Counterclockwise +page_rotate_ccw.label=Rotate Counterclockwise +page_rotate_ccw_label=Rotate Counterclockwise + +hand_tool_enable.title=Enable hand tool +hand_tool_enable_label=Enable hand tool +hand_tool_disable.title=Disable hand tool +hand_tool_disable_label=Disable hand tool + +# Document properties dialog box +document_properties.title=Document Properties… +document_properties_label=Document Properties… +document_properties_file_name=File name: +document_properties_file_size=File size: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Title: +document_properties_author=Author: +document_properties_subject=Subject: +document_properties_keywords=Keywords: +document_properties_creation_date=Creation Date: +document_properties_modification_date=Modification Date: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creator: +document_properties_producer=PDF Producer: +document_properties_version=PDF Version: +document_properties_page_count=Page Count: +document_properties_close=Close + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Toggle Sidebar +toggle_sidebar_label=Toggle Sidebar +outline.title=Show Document Outline +outline_label=Document Outline +attachments.title=Show Attachments +attachments_label=Attachments +thumbs.title=Show Thumbnails +thumbs_label=Thumbnails +findbar.title=Find in Document +findbar_label=Find + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Page {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Thumbnail of Page {{page}} + +# Find panel button title and messages +find_label=Find: +find_previous.title=Find the previous occurrence of the phrase +find_previous_label=Previous +find_next.title=Find the next occurrence of the phrase +find_next_label=Next +find_highlight=Highlight all +find_match_case_label=Match case +find_reached_top=Reached top of document, continued from bottom +find_reached_bottom=Reached end of document, continued from top +find_not_found=Phrase not found + +# Error panel labels +error_more_info=More Information +error_less_info=Less Information +error_close=Close +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Message: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=File: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Line: {{line}} +rendering_error=An error occurred while rendering the page. + +# Predefined zoom values +page_scale_width=Page Width +page_scale_fit=Page Fit +page_scale_auto=Automatic Zoom +page_scale_actual=Actual Size +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Error +loading_error=An error occurred while loading the PDF. +invalid_file_error=Invalid or corrupted PDF file. +missing_file_error=Missing PDF file. +unexpected_response_error=Unexpected server response. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=Enter the password to open this PDF file. +password_invalid=Invalid password. Please try again. +password_ok=OK +password_cancel=Cancel + +printing_not_supported=Warning: Printing is not fully supported by this browser. +printing_not_ready=Warning: The PDF is not fully loaded for printing. +web_fonts_disabled=Web fonts are disabled: unable to use embedded PDF fonts. +document_colors_not_allowed=PDF documents are not allowed to use their own colors: 'Allow pages to choose their own colors' is deactivated in the browser. diff --git a/static/pdf.js/locale/en-ZA/viewer.properties b/static/pdf.js/locale/en-ZA/viewer.properties new file mode 100644 index 00000000..edb9fd0e --- /dev/null +++ b/static/pdf.js/locale/en-ZA/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Previous Page +previous_label=Previous +next.title=Next Page +next_label=Next + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Page: +page_of=of {{pageCount}} + +zoom_out.title=Zoom Out +zoom_out_label=Zoom Out +zoom_in.title=Zoom In +zoom_in_label=Zoom In +zoom.title=Zoom +presentation_mode.title=Switch to Presentation Mode +presentation_mode_label=Presentation Mode +open_file.title=Open File +open_file_label=Open +print.title=Print +print_label=Print +download.title=Download +download_label=Download +bookmark.title=Current view (copy or open in new window) +bookmark_label=Current View + +# Secondary toolbar and context menu +tools.title=Tools +tools_label=Tools +first_page.title=Go to First Page +first_page.label=Go to First Page +first_page_label=Go to First Page +last_page.title=Go to Last Page +last_page.label=Go to Last Page +last_page_label=Go to Last Page +page_rotate_cw.title=Rotate Clockwise +page_rotate_cw.label=Rotate Clockwise +page_rotate_cw_label=Rotate Clockwise +page_rotate_ccw.title=Rotate Counterclockwise +page_rotate_ccw.label=Rotate Counterclockwise +page_rotate_ccw_label=Rotate Counterclockwise + +hand_tool_enable.title=Enable hand tool +hand_tool_enable_label=Enable hand tool +hand_tool_disable.title=Disable hand tool +hand_tool_disable_label=Disable hand tool + +# Document properties dialog box +document_properties.title=Document Properties… +document_properties_label=Document Properties… +document_properties_file_name=File name: +document_properties_file_size=File size: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Title: +document_properties_author=Author: +document_properties_subject=Subject: +document_properties_keywords=Keywords: +document_properties_creation_date=Creation Date: +document_properties_modification_date=Modification Date: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creator: +document_properties_producer=PDF Producer: +document_properties_version=PDF Version: +document_properties_page_count=Page Count: +document_properties_close=Close + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Toggle Sidebar +toggle_sidebar_label=Toggle Sidebar +outline.title=Show Document Outline +outline_label=Document Outline +attachments.title=Show Attachments +attachments_label=Attachments +thumbs.title=Show Thumbnails +thumbs_label=Thumbnails +findbar.title=Find in Document +findbar_label=Find + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Page {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Thumbnail of Page {{page}} + +# Find panel button title and messages +find_label=Find: +find_previous.title=Find the previous occurrence of the phrase +find_previous_label=Previous +find_next.title=Find the next occurrence of the phrase +find_next_label=Next +find_highlight=Highlight all +find_match_case_label=Match case +find_reached_top=Reached top of document, continued from bottom +find_reached_bottom=Reached end of document, continued from top +find_not_found=Phrase not found + +# Error panel labels +error_more_info=More Information +error_less_info=Less Information +error_close=Close +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Message: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=File: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Line: {{line}} +rendering_error=An error occurred while rendering the page. + +# Predefined zoom values +page_scale_width=Page Width +page_scale_fit=Page Fit +page_scale_auto=Automatic Zoom +page_scale_actual=Actual Size +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Error +loading_error=An error occurred while loading the PDF. +invalid_file_error=Invalid or corrupted PDF file. +missing_file_error=Missing PDF file. +unexpected_response_error=Unexpected server response. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=Enter the password to open this PDF file. +password_invalid=Invalid password. Please try again. +password_ok=OK +password_cancel=Cancel + +printing_not_supported=Warning: Printing is not fully supported by this browser. +printing_not_ready=Warning: The PDF is not fully loaded for printing. +web_fonts_disabled=Web fonts are disabled: unable to use embedded PDF fonts. +document_colors_not_allowed=PDF documents are not allowed to use their own colours: 'Allow pages to choose their own colours' is deactivated in the browser. diff --git a/static/pdf.js/locale/eo/viewer.ftl b/static/pdf.js/locale/eo/viewer.ftl deleted file mode 100644 index 23c2b24f..00000000 --- a/static/pdf.js/locale/eo/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Antaŭa paĝo -pdfjs-previous-button-label = Malantaŭen -pdfjs-next-button = - .title = Venonta paĝo -pdfjs-next-button-label = Antaŭen -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Paĝo -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = el { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } el { $pagesCount }) -pdfjs-zoom-out-button = - .title = Malpligrandigi -pdfjs-zoom-out-button-label = Malpligrandigi -pdfjs-zoom-in-button = - .title = Pligrandigi -pdfjs-zoom-in-button-label = Pligrandigi -pdfjs-zoom-select = - .title = Pligrandigilo -pdfjs-presentation-mode-button = - .title = Iri al prezenta reĝimo -pdfjs-presentation-mode-button-label = Prezenta reĝimo -pdfjs-open-file-button = - .title = Malfermi dosieron -pdfjs-open-file-button-label = Malfermi -pdfjs-print-button = - .title = Presi -pdfjs-print-button-label = Presi -pdfjs-save-button = - .title = Konservi -pdfjs-save-button-label = Konservi -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Elŝuti -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Elŝuti -pdfjs-bookmark-button = - .title = Nuna paĝo (Montri adreson de la nuna paĝo) -pdfjs-bookmark-button-label = Nuna paĝo - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Iloj -pdfjs-tools-button-label = Iloj -pdfjs-first-page-button = - .title = Iri al la unua paĝo -pdfjs-first-page-button-label = Iri al la unua paĝo -pdfjs-last-page-button = - .title = Iri al la lasta paĝo -pdfjs-last-page-button-label = Iri al la lasta paĝo -pdfjs-page-rotate-cw-button = - .title = Rotaciigi dekstrume -pdfjs-page-rotate-cw-button-label = Rotaciigi dekstrume -pdfjs-page-rotate-ccw-button = - .title = Rotaciigi maldekstrume -pdfjs-page-rotate-ccw-button-label = Rotaciigi maldekstrume -pdfjs-cursor-text-select-tool-button = - .title = Aktivigi tekstan elektilon -pdfjs-cursor-text-select-tool-button-label = Teksta elektilo -pdfjs-cursor-hand-tool-button = - .title = Aktivigi ilon de mano -pdfjs-cursor-hand-tool-button-label = Ilo de mano -pdfjs-scroll-page-button = - .title = Uzi rulumon de paĝo -pdfjs-scroll-page-button-label = Rulumo de paĝo -pdfjs-scroll-vertical-button = - .title = Uzi vertikalan rulumon -pdfjs-scroll-vertical-button-label = Vertikala rulumo -pdfjs-scroll-horizontal-button = - .title = Uzi horizontalan rulumon -pdfjs-scroll-horizontal-button-label = Horizontala rulumo -pdfjs-scroll-wrapped-button = - .title = Uzi ambaŭdirektan rulumon -pdfjs-scroll-wrapped-button-label = Ambaŭdirekta rulumo -pdfjs-spread-none-button = - .title = Ne montri paĝojn po du -pdfjs-spread-none-button-label = Unupaĝa vido -pdfjs-spread-odd-button = - .title = Kunigi paĝojn komencante per nepara paĝo -pdfjs-spread-odd-button-label = Po du paĝoj, neparaj maldekstre -pdfjs-spread-even-button = - .title = Kunigi paĝojn komencante per para paĝo -pdfjs-spread-even-button-label = Po du paĝoj, paraj maldekstre - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Atributoj de dokumento… -pdfjs-document-properties-button-label = Atributoj de dokumento… -pdfjs-document-properties-file-name = Nomo de dosiero: -pdfjs-document-properties-file-size = Grando de dosiero: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KO ({ $size_b } oktetoj) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MO ({ $size_b } oktetoj) -pdfjs-document-properties-title = Titolo: -pdfjs-document-properties-author = Aŭtoro: -pdfjs-document-properties-subject = Temo: -pdfjs-document-properties-keywords = Ŝlosilvorto: -pdfjs-document-properties-creation-date = Dato de kreado: -pdfjs-document-properties-modification-date = Dato de modifo: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Kreinto: -pdfjs-document-properties-producer = Produktinto de PDF: -pdfjs-document-properties-version = Versio de PDF: -pdfjs-document-properties-page-count = Nombro de paĝoj: -pdfjs-document-properties-page-size = Grando de paĝo: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertikala -pdfjs-document-properties-page-size-orientation-landscape = horizontala -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letera -pdfjs-document-properties-page-size-name-legal = Jura - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Rapida tekstaĵa vido: -pdfjs-document-properties-linearized-yes = Jes -pdfjs-document-properties-linearized-no = Ne -pdfjs-document-properties-close-button = Fermi - -## Print - -pdfjs-print-progress-message = Preparo de dokumento por presi ĝin … -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Nuligi -pdfjs-printing-not-supported = Averto: tiu ĉi retumilo ne plene subtenas presadon. -pdfjs-printing-not-ready = Averto: la PDF dosiero ne estas plene ŝargita por presado. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Montri/kaŝi flankan strion -pdfjs-toggle-sidebar-notification-button = - .title = Montri/kaŝi flankan strion (la dokumento enhavas konturon/kunsendaĵojn/tavolojn) -pdfjs-toggle-sidebar-button-label = Montri/kaŝi flankan strion -pdfjs-document-outline-button = - .title = Montri la konturon de dokumento (alklaku duoble por faldi/malfaldi ĉiujn elementojn) -pdfjs-document-outline-button-label = Konturo de dokumento -pdfjs-attachments-button = - .title = Montri kunsendaĵojn -pdfjs-attachments-button-label = Kunsendaĵojn -pdfjs-layers-button = - .title = Montri tavolojn (duoble alklaku por remeti ĉiujn tavolojn en la norman staton) -pdfjs-layers-button-label = Tavoloj -pdfjs-thumbs-button = - .title = Montri miniaturojn -pdfjs-thumbs-button-label = Miniaturoj -pdfjs-current-outline-item-button = - .title = Trovi nunan konturan elementon -pdfjs-current-outline-item-button-label = Nuna kontura elemento -pdfjs-findbar-button = - .title = Serĉi en dokumento -pdfjs-findbar-button-label = Serĉi -pdfjs-additional-layers = Aldonaj tavoloj - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Paĝo { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniaturo de paĝo { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Serĉi - .placeholder = Serĉi en dokumento… -pdfjs-find-previous-button = - .title = Serĉi la antaŭan aperon de la frazo -pdfjs-find-previous-button-label = Malantaŭen -pdfjs-find-next-button = - .title = Serĉi la venontan aperon de la frazo -pdfjs-find-next-button-label = Antaŭen -pdfjs-find-highlight-checkbox = Elstarigi ĉiujn -pdfjs-find-match-case-checkbox-label = Distingi inter majuskloj kaj minuskloj -pdfjs-find-match-diacritics-checkbox-label = Respekti supersignojn -pdfjs-find-entire-word-checkbox-label = Tutaj vortoj -pdfjs-find-reached-top = Komenco de la dokumento atingita, daŭrigado ekde la fino -pdfjs-find-reached-bottom = Fino de la dokumento atingita, daŭrigado ekde la komenco -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } el { $total } kongruo - *[other] { $current } el { $total } kongruoj - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Pli ol { $limit } kongruo - *[other] Pli ol { $limit } kongruoj - } -pdfjs-find-not-found = Frazo ne trovita - -## Predefined zoom values - -pdfjs-page-scale-width = Larĝo de paĝo -pdfjs-page-scale-fit = Adapti paĝon -pdfjs-page-scale-auto = Aŭtomata skalo -pdfjs-page-scale-actual = Reala grando -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Paĝo { $page } - -## Loading indicator messages - -pdfjs-loading-error = Okazis eraro dum la ŝargado de la PDF dosiero. -pdfjs-invalid-file-error = Nevalida aŭ difektita PDF dosiero. -pdfjs-missing-file-error = Mankas dosiero PDF. -pdfjs-unexpected-response-error = Neatendita respondo de servilo. -pdfjs-rendering-error = Okazis eraro dum la montro de la paĝo. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Prinoto: { $type }] - -## Password - -pdfjs-password-label = Tajpu pasvorton por malfermi tiun ĉi dosieron PDF. -pdfjs-password-invalid = Nevalida pasvorto. Bonvolu provi denove. -pdfjs-password-ok-button = Akcepti -pdfjs-password-cancel-button = Nuligi -pdfjs-web-fonts-disabled = Neaktivaj teksaĵaj tiparoj: ne elbas uzi enmetitajn tiparojn de PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Teksto -pdfjs-editor-free-text-button-label = Teksto -pdfjs-editor-ink-button = - .title = Desegni -pdfjs-editor-ink-button-label = Desegni -pdfjs-editor-stamp-button = - .title = Aldoni aŭ modifi bildojn -pdfjs-editor-stamp-button-label = Aldoni aŭ modifi bildojn -pdfjs-editor-highlight-button = - .title = Elstarigi -pdfjs-editor-highlight-button-label = Elstarigi -pdfjs-highlight-floating-button = - .title = Elstarigi -pdfjs-highlight-floating-button1 = - .title = Elstarigi - .aria-label = Elstarigi -pdfjs-highlight-floating-button-label = Elstarigi - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Forigi desegnon -pdfjs-editor-remove-freetext-button = - .title = Forigi tekston -pdfjs-editor-remove-stamp-button = - .title = Forigi bildon -pdfjs-editor-remove-highlight-button = - .title = Forigi elstaraĵon - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Koloro -pdfjs-editor-free-text-size-input = Grando -pdfjs-editor-ink-color-input = Koloro -pdfjs-editor-ink-thickness-input = Dikeco -pdfjs-editor-ink-opacity-input = Maldiafaneco -pdfjs-editor-stamp-add-image-button = - .title = Aldoni bildon -pdfjs-editor-stamp-add-image-button-label = Aldoni bildon -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Dikeco -pdfjs-editor-free-highlight-thickness-title = - .title = Ŝanĝi dikecon dum elstarigo de netekstaj elementoj -pdfjs-free-text = - .aria-label = Tekstan redaktilon -pdfjs-free-text-default-content = Ektajpi… -pdfjs-ink = - .aria-label = Desegnan redaktilon -pdfjs-ink-canvas = - .aria-label = Bildo kreita de uzanto - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternativa teksto -pdfjs-editor-alt-text-edit-button-label = Redakti alternativan tekston -pdfjs-editor-alt-text-dialog-label = Elektu eblon -pdfjs-editor-alt-text-dialog-description = Alternativa teksto helpas personojn, en la okazoj kiam ili ne povas vidi aŭ ŝargi la bildon. -pdfjs-editor-alt-text-add-description-label = Aldoni priskribon -pdfjs-editor-alt-text-add-description-description = La celo estas unu aŭ du frazoj, kiuj priskribas la temon, etoson aŭ agojn. -pdfjs-editor-alt-text-mark-decorative-label = Marki kiel ornaman -pdfjs-editor-alt-text-mark-decorative-description = Tio ĉi estas uzita por ornamaj bildoj, kiel randoj aŭ fonaj bildoj. -pdfjs-editor-alt-text-cancel-button = Nuligi -pdfjs-editor-alt-text-save-button = Konservi -pdfjs-editor-alt-text-decorative-tooltip = Markita kiel ornama -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Ekzemple: “Juna persono sidiĝas ĉetable por ekmanĝi” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Supra maldekstra angulo — ŝangi grandon -pdfjs-editor-resizer-label-top-middle = Supra mezo — ŝanĝi grandon -pdfjs-editor-resizer-label-top-right = Supran dekstran angulon — ŝanĝi grandon -pdfjs-editor-resizer-label-middle-right = Dekstra mezo — ŝanĝi grandon -pdfjs-editor-resizer-label-bottom-right = Malsupra deksta angulo — ŝanĝi grandon -pdfjs-editor-resizer-label-bottom-middle = Malsupra mezo — ŝanĝi grandon -pdfjs-editor-resizer-label-bottom-left = Malsupra maldekstra angulo — ŝanĝi grandon -pdfjs-editor-resizer-label-middle-left = Maldekstra mezo — ŝanĝi grandon - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Elstarigi koloron -pdfjs-editor-colorpicker-button = - .title = Ŝanĝi koloron -pdfjs-editor-colorpicker-dropdown = - .aria-label = Elekto de koloroj -pdfjs-editor-colorpicker-yellow = - .title = Flava -pdfjs-editor-colorpicker-green = - .title = Verda -pdfjs-editor-colorpicker-blue = - .title = Blua -pdfjs-editor-colorpicker-pink = - .title = Roza -pdfjs-editor-colorpicker-red = - .title = Ruĝa - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Montri ĉiujn -pdfjs-editor-highlight-show-all-button = - .title = Montri ĉiujn diff --git a/static/pdf.js/locale/eo/viewer.properties b/static/pdf.js/locale/eo/viewer.properties new file mode 100644 index 00000000..7cc95c64 --- /dev/null +++ b/static/pdf.js/locale/eo/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Antaŭa paĝo +previous_label=Malantaŭen +next.title=Venonta paĝo +next_label=Antaŭen + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Paĝo: +page_of=el {{pageCount}} + +zoom_out.title=Malpligrandigi +zoom_out_label=Malpligrandigi +zoom_in.title=Pligrandigi +zoom_in_label=Pligrandigi +zoom.title=Pligrandigilo +presentation_mode.title=Iri al prezenta reĝimo +presentation_mode_label=Prezenta reĝimo +open_file.title=Malfermi dosieron +open_file_label=Malfermi +print.title=Presi +print_label=Presi +download.title=Elŝuti +download_label=Elŝuti +bookmark.title=Nuna vido (kopii aŭ malfermi en nova fenestro) +bookmark_label=Nuna vido + +# Secondary toolbar and context menu +tools.title=Iloj +tools_label=Iloj +first_page.title=Iri al la unua paĝo +first_page.label=Iri al la unua paĝo +first_page_label=Iri al la unua paĝo +last_page.title=Iri al la lasta paĝo +last_page.label=Iri al la lasta paĝo +last_page_label=Iri al la lasta paĝo +page_rotate_cw.title=Rotaciigi dekstrume +page_rotate_cw.label=Rotaciigi dekstrume +page_rotate_cw_label=Rotaciigi dekstrume +page_rotate_ccw.title=Rotaciigi maldekstrume +page_rotate_ccw.label=Rotaciigi maldekstrume +page_rotate_ccw_label=Rotaciigi maldekstrume + +hand_tool_enable.title=Aktivigi manan ilon +hand_tool_enable_label=Aktivigi manan ilon +hand_tool_disable.title=Malaktivigi manan ilon +hand_tool_disable_label=Malaktivigi manan ilon + +# Document properties dialog box +document_properties.title=Atributoj de dokumento… +document_properties_label=Atributoj de dokumento… +document_properties_file_name=Nomo de dosiero: +document_properties_file_size=Grado de dosiero: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KO ({{size_b}} oktetoj) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MO ({{size_b}} oktetoj) +document_properties_title=Titolo: +document_properties_author=Aŭtoro: +document_properties_subject=Temo: +document_properties_keywords=Ŝlosilvorto: +document_properties_creation_date=Dato de kreado: +document_properties_modification_date=Dato de modifo: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Kreinto: +document_properties_producer=Produktinto de PDF: +document_properties_version=Versio de PDF: +document_properties_page_count=Nombro de paĝoj: +document_properties_close=Fermi + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Montri/kaŝi flankan strion +toggle_sidebar_label=Montri/kaŝi flankan strion +outline.title=Montri skemon de dokumento +outline_label=Skemo de dokumento +attachments.title=Montri kunsendaĵojn +attachments_label=Kunsendaĵojn +thumbs.title=Montri miniaturojn +thumbs_label=Miniaturoj +findbar.title=Serĉi en dokumento +findbar_label=Serĉi + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Paĝo {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniaturo de paĝo {{page}} + +# Find panel button title and messages +find_label=Serĉi: +find_previous.title=Serĉi la antaŭan aperon de la frazo +find_previous_label=Malantaŭen +find_next.title=Serĉi la venontan aperon de la frazo +find_next_label=Antaŭen +find_highlight=Elstarigi ĉiujn +find_match_case_label=Distingi inter majuskloj kaj minuskloj +find_reached_top=Komenco de la dokumento atingita, daŭrigado ekde la fino +find_reached_bottom=Fino de la dokumento atingita, daŭrigado ekde la komenco +find_not_found=Frazo ne trovita + +# Error panel labels +error_more_info=Pli da informo +error_less_info=Mapli da informo +error_close=Fermi +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mesaĝo: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stako: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Dosiero: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linio: {{line}} +rendering_error=Okazis eraro dum la montrado de la paĝo. + +# Predefined zoom values +page_scale_width=Larĝo de paĝo +page_scale_fit=Adapti paĝon +page_scale_auto=Aŭtomata skalo +page_scale_actual=Reala gandeco +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Eraro +loading_error=Okazis eraro dum la ŝargado de la PDF dosiero. +invalid_file_error=Nevalida aŭ difektita PDF dosiero. +missing_file_error=Mankas dosiero PDF. +unexpected_response_error=Neatendita respondo de servilo. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Prinoto: {{type}}] +password_label=Tajpu pasvorton por malfermi tiun ĉi dosieron PDF. +password_invalid=Nevalida pasvorto. Bonvolu provi denove. +password_ok=Akcepti +password_cancel=Nuligi + +printing_not_supported=Averto: tiu ĉi retumilo ne plene subtenas presadon. +printing_not_ready=Averto: La PDF dosiero ne estas plene ŝargita por presado. +web_fonts_disabled=Neaktivaj teksaĵaj tiparoj: ne elbas uzi enmetitajn tiparojn de PDF. +document_colors_disabled=Dokumentoj PDF ne rajtas havi siajn proprajn kolorojn: \'Permesi al paĝoj elekti siajn proprajn kolorojn\' estas malaktiva en la retumilo. diff --git a/static/pdf.js/locale/es-AR/viewer.ftl b/static/pdf.js/locale/es-AR/viewer.ftl deleted file mode 100644 index 40610b24..00000000 --- a/static/pdf.js/locale/es-AR/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Página anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Página siguiente -pdfjs-next-button-label = Siguiente -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Página -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ( { $pageNumber } de { $pagesCount } ) -pdfjs-zoom-out-button = - .title = Alejar -pdfjs-zoom-out-button-label = Alejar -pdfjs-zoom-in-button = - .title = Acercar -pdfjs-zoom-in-button-label = Acercar -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Cambiar a modo presentación -pdfjs-presentation-mode-button-label = Modo presentación -pdfjs-open-file-button = - .title = Abrir archivo -pdfjs-open-file-button-label = Abrir -pdfjs-print-button = - .title = Imprimir -pdfjs-print-button-label = Imprimir -pdfjs-save-button = - .title = Guardar -pdfjs-save-button-label = Guardar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Descargar -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Descargar -pdfjs-bookmark-button = - .title = Página actual (Ver URL de la página actual) -pdfjs-bookmark-button-label = Página actual -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Abrir en la aplicación -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Abrir en la aplicación - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Herramientas -pdfjs-tools-button-label = Herramientas -pdfjs-first-page-button = - .title = Ir a primera página -pdfjs-first-page-button-label = Ir a primera página -pdfjs-last-page-button = - .title = Ir a última página -pdfjs-last-page-button-label = Ir a última página -pdfjs-page-rotate-cw-button = - .title = Rotar horario -pdfjs-page-rotate-cw-button-label = Rotar horario -pdfjs-page-rotate-ccw-button = - .title = Rotar antihorario -pdfjs-page-rotate-ccw-button-label = Rotar antihorario -pdfjs-cursor-text-select-tool-button = - .title = Habilitar herramienta de selección de texto -pdfjs-cursor-text-select-tool-button-label = Herramienta de selección de texto -pdfjs-cursor-hand-tool-button = - .title = Habilitar herramienta mano -pdfjs-cursor-hand-tool-button-label = Herramienta mano -pdfjs-scroll-page-button = - .title = Usar desplazamiento de página -pdfjs-scroll-page-button-label = Desplazamiento de página -pdfjs-scroll-vertical-button = - .title = Usar desplazamiento vertical -pdfjs-scroll-vertical-button-label = Desplazamiento vertical -pdfjs-scroll-horizontal-button = - .title = Usar desplazamiento vertical -pdfjs-scroll-horizontal-button-label = Desplazamiento horizontal -pdfjs-scroll-wrapped-button = - .title = Usar desplazamiento encapsulado -pdfjs-scroll-wrapped-button-label = Desplazamiento encapsulado -pdfjs-spread-none-button = - .title = No unir páginas dobles -pdfjs-spread-none-button-label = Sin dobles -pdfjs-spread-odd-button = - .title = Unir páginas dobles comenzando con las impares -pdfjs-spread-odd-button-label = Dobles impares -pdfjs-spread-even-button = - .title = Unir páginas dobles comenzando con las pares -pdfjs-spread-even-button-label = Dobles pares - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propiedades del documento… -pdfjs-document-properties-button-label = Propiedades del documento… -pdfjs-document-properties-file-name = Nombre de archivo: -pdfjs-document-properties-file-size = Tamaño de archovo: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Título: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Asunto: -pdfjs-document-properties-keywords = Palabras clave: -pdfjs-document-properties-creation-date = Fecha de creación: -pdfjs-document-properties-modification-date = Fecha de modificación: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creador: -pdfjs-document-properties-producer = PDF Productor: -pdfjs-document-properties-version = Versión de PDF: -pdfjs-document-properties-page-count = Cantidad de páginas: -pdfjs-document-properties-page-size = Tamaño de página: -pdfjs-document-properties-page-size-unit-inches = en -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = normal -pdfjs-document-properties-page-size-orientation-landscape = apaisado -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista rápida de la Web: -pdfjs-document-properties-linearized-yes = Sí -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Cerrar - -## Print - -pdfjs-print-progress-message = Preparando documento para imprimir… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancelar -pdfjs-printing-not-supported = Advertencia: La impresión no está totalmente soportada por este navegador. -pdfjs-printing-not-ready = Advertencia: El PDF no está completamente cargado para impresión. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Alternar barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Alternar barra lateral (el documento contiene esquemas/adjuntos/capas) -pdfjs-toggle-sidebar-button-label = Alternar barra lateral -pdfjs-document-outline-button = - .title = Mostrar esquema del documento (doble clic para expandir/colapsar todos los ítems) -pdfjs-document-outline-button-label = Esquema del documento -pdfjs-attachments-button = - .title = Mostrar adjuntos -pdfjs-attachments-button-label = Adjuntos -pdfjs-layers-button = - .title = Mostrar capas (doble clic para restablecer todas las capas al estado predeterminado) -pdfjs-layers-button-label = Capas -pdfjs-thumbs-button = - .title = Mostrar miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Buscar elemento de esquema actual -pdfjs-current-outline-item-button-label = Elemento de esquema actual -pdfjs-findbar-button = - .title = Buscar en documento -pdfjs-findbar-button-label = Buscar -pdfjs-additional-layers = Capas adicionales - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Página { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura de página { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Buscar - .placeholder = Buscar en documento… -pdfjs-find-previous-button = - .title = Buscar la aparición anterior de la frase -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button = - .title = Buscar la siguiente aparición de la frase -pdfjs-find-next-button-label = Siguiente -pdfjs-find-highlight-checkbox = Resaltar todo -pdfjs-find-match-case-checkbox-label = Coincidir mayúsculas -pdfjs-find-match-diacritics-checkbox-label = Coincidir diacríticos -pdfjs-find-entire-word-checkbox-label = Palabras completas -pdfjs-find-reached-top = Inicio de documento alcanzado, continuando desde abajo -pdfjs-find-reached-bottom = Fin de documento alcanzando, continuando desde arriba -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } de { $total } coincidencia - *[other] { $current } de { $total } coincidencias - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Más de { $limit } coincidencia - *[other] Más de { $limit } coincidencias - } -pdfjs-find-not-found = Frase no encontrada - -## Predefined zoom values - -pdfjs-page-scale-width = Ancho de página -pdfjs-page-scale-fit = Ajustar página -pdfjs-page-scale-auto = Zoom automático -pdfjs-page-scale-actual = Tamaño real -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Página { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ocurrió un error al cargar el PDF. -pdfjs-invalid-file-error = Archivo PDF no válido o cocrrupto. -pdfjs-missing-file-error = Archivo PDF faltante. -pdfjs-unexpected-response-error = Respuesta del servidor inesperada. -pdfjs-rendering-error = Ocurrió un error al dibujar la página. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Anotación] - -## Password - -pdfjs-password-label = Ingrese la contraseña para abrir este archivo PDF -pdfjs-password-invalid = Contraseña inválida. Intente nuevamente. -pdfjs-password-ok-button = Aceptar -pdfjs-password-cancel-button = Cancelar -pdfjs-web-fonts-disabled = Tipografía web deshabilitada: no se pueden usar tipos incrustados en PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texto -pdfjs-editor-free-text-button-label = Texto -pdfjs-editor-ink-button = - .title = Dibujar -pdfjs-editor-ink-button-label = Dibujar -pdfjs-editor-stamp-button = - .title = Agregar o editar imágenes -pdfjs-editor-stamp-button-label = Agregar o editar imágenes -pdfjs-editor-highlight-button = - .title = Resaltar -pdfjs-editor-highlight-button-label = Resaltar -pdfjs-highlight-floating-button = - .title = Resaltar -pdfjs-highlight-floating-button1 = - .title = Resaltar - .aria-label = Resaltar -pdfjs-highlight-floating-button-label = Resaltar - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Eliminar dibujo -pdfjs-editor-remove-freetext-button = - .title = Eliminar texto -pdfjs-editor-remove-stamp-button = - .title = Eliminar imagen -pdfjs-editor-remove-highlight-button = - .title = Eliminar resaltado - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Color -pdfjs-editor-free-text-size-input = Tamaño -pdfjs-editor-ink-color-input = Color -pdfjs-editor-ink-thickness-input = Espesor -pdfjs-editor-ink-opacity-input = Opacidad -pdfjs-editor-stamp-add-image-button = - .title = Agregar una imagen -pdfjs-editor-stamp-add-image-button-label = Agregar una imagen -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Grosor -pdfjs-editor-free-highlight-thickness-title = - .title = Cambiar el grosor al resaltar elementos que no sean texto -pdfjs-free-text = - .aria-label = Editor de texto -pdfjs-free-text-default-content = Empezar a tipear… -pdfjs-ink = - .aria-label = Editor de dibujos -pdfjs-ink-canvas = - .aria-label = Imagen creada por el usuario - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Texto alternativo -pdfjs-editor-alt-text-edit-button-label = Editar el texto alternativo -pdfjs-editor-alt-text-dialog-label = Eligir una opción -pdfjs-editor-alt-text-dialog-description = El texto alternativo (texto alternativo) ayuda cuando las personas no pueden ver la imagen o cuando no se carga. -pdfjs-editor-alt-text-add-description-label = Agregar una descripción -pdfjs-editor-alt-text-add-description-description = Intente escribir 1 o 2 oraciones que describan el tema, el entorno o las acciones. -pdfjs-editor-alt-text-mark-decorative-label = Marcar como decorativo -pdfjs-editor-alt-text-mark-decorative-description = Esto se usa para imágenes ornamentales, como bordes o marcas de agua. -pdfjs-editor-alt-text-cancel-button = Cancelar -pdfjs-editor-alt-text-save-button = Guardar -pdfjs-editor-alt-text-decorative-tooltip = Marcado como decorativo -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Por ejemplo: “Un joven se sienta a la mesa a comer” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Esquina superior izquierda — cambiar el tamaño -pdfjs-editor-resizer-label-top-middle = Arriba en el medio — cambiar el tamaño -pdfjs-editor-resizer-label-top-right = Esquina superior derecha — cambiar el tamaño -pdfjs-editor-resizer-label-middle-right = Al centro a la derecha — cambiar el tamaño -pdfjs-editor-resizer-label-bottom-right = Esquina inferior derecha — cambiar el tamaño -pdfjs-editor-resizer-label-bottom-middle = Abajo en el medio — cambiar el tamaño -pdfjs-editor-resizer-label-bottom-left = Esquina inferior izquierda — cambiar el tamaño -pdfjs-editor-resizer-label-middle-left = Al centro a la izquierda — cambiar el tamaño - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Color de resaltado -pdfjs-editor-colorpicker-button = - .title = Cambiar el color -pdfjs-editor-colorpicker-dropdown = - .aria-label = Opciones de color -pdfjs-editor-colorpicker-yellow = - .title = Amarillo -pdfjs-editor-colorpicker-green = - .title = Verde -pdfjs-editor-colorpicker-blue = - .title = Azul -pdfjs-editor-colorpicker-pink = - .title = Rosado -pdfjs-editor-colorpicker-red = - .title = Rojo - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Mostrar todo -pdfjs-editor-highlight-show-all-button = - .title = Mostrar todo diff --git a/static/pdf.js/locale/es-AR/viewer.properties b/static/pdf.js/locale/es-AR/viewer.properties new file mode 100644 index 00000000..cbef0669 --- /dev/null +++ b/static/pdf.js/locale/es-AR/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Página anterior +previous_label=Anterior +next.title=Página siguiente +next_label=Siguiente + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Página: +page_of=de {{pageCount}} + +zoom_out.title=Alejar +zoom_out_label=Alejar +zoom_in.title=Acercar +zoom_in_label=Acercar +zoom.title=Zoom +print.title=Imprimir +print_label=Imprimir +presentation_mode.title=Cambiar a modo presentación +presentation_mode_label=Modo presentación +open_file.title=Abrir archivo +open_file_label=Abrir +download.title=Descargar +download_label=Descargar +bookmark.title=Vista actual (copiar o abrir en nueva ventana) +bookmark_label=Vista actual + +# Secondary toolbar and context menu +tools.title=Herramientas +tools_label=Herramientas +first_page.title=Ir a primera página +first_page.label=Ir a primera página +first_page_label=Ir a primera página +last_page.title=Ir a última página +last_page.label=Ir a última página +last_page_label=Ir a última página +page_rotate_cw.title=Rotar horario +page_rotate_cw.label=Rotar horario +page_rotate_cw_label=Rotar horario +page_rotate_ccw.title=Rotar antihorario +page_rotate_ccw.label=Rotar antihorario +page_rotate_ccw_label=Rotar antihorario + +hand_tool_enable.title=Habilitar herramienta mano +hand_tool_enable_label=Habilitar herramienta mano +hand_tool_disable.title=Deshabilitar herramienta mano +hand_tool_disable_label=Deshabilitar herramienta mano + +# Document properties dialog box +document_properties.title=Propiedades del documento… +document_properties_label=Propiedades del documento… +document_properties_file_name=Nombre de archivo: +document_properties_file_size=Tamaño de archovo: +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Título: +document_properties_author=Autor: +document_properties_subject=Asunto: +document_properties_keywords=Palabras clave: +document_properties_creation_date=Fecha de creación: +document_properties_modification_date=Fecha de modificación: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creador: +document_properties_producer=PDF Productor: +document_properties_version=Versión de PDF: +document_properties_page_count=Cantidad de páginas: +document_properties_close=Cerrar + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Alternar barra lateral +toggle_sidebar_label=Alternar barra lateral +outline.title=Mostrar esquema del documento +outline_label=Esquema del documento +attachments.title=Mostrar adjuntos +attachments_label=Adjuntos +thumbs.title=Mostrar miniaturas +thumbs_label=Miniaturas +findbar.title=Buscar en documento +findbar_label=Buscar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Página {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura de página {{page}} + +# Find panel button title and messages +find_label=Buscar: +find_previous.title=Buscar la aparición anterior de la frase +find_previous_label=Anterior +find_next.title=Buscar la siguiente aparición de la frase +find_next_label=Siguiente +find_highlight=Resaltar todo +find_match_case_label=Coincidir mayúsculas +find_reached_top=Inicio de documento alcanzado, continuando desde abajo +find_reached_bottom=Fin de documento alcanzando, continuando desde arriba +find_not_found=Frase no encontrada + +# Error panel labels +error_more_info=Más información +error_less_info=Menos información +error_close=Cerrar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mensaje: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pila: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Archivo: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Línea: {{line}} +rendering_error=Ocurrió un error al dibujar la página. + +# Predefined zoom values +page_scale_width=Ancho de página +page_scale_fit=Ajustar página +page_scale_auto=Zoom automático +page_scale_actual=Tamaño real +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Error +loading_error=Ocurrió un error al cargar el PDF. +invalid_file_error=Archivo PDF no válido o cocrrupto. +missing_file_error=Archivo PDF faltante. +unexpected_response_error=Respuesta del servidor inesperada. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Anotación] +password_label=Ingrese la contraseña para abrir este archivo PDF +password_invalid=Contraseña inválida. Intente nuevamente. +password_ok=Aceptar +password_cancel=Cancelar + +printing_not_supported=Advertencia: La impresión no está totalmente soportada por este navegador. +printing_not_ready=Advertencia: El PDF no está completamente cargado para impresión. +web_fonts_disabled=Tipografía web deshabilitada: no se pueden usar tipos incrustados en PDF. +document_colors_not_allowed=Los documentos PDF no tienen permitido usar sus propios colores: 'Permitir a las páginas elegir sus propios colores' está desactivado en el navegador. diff --git a/static/pdf.js/locale/es-CL/viewer.ftl b/static/pdf.js/locale/es-CL/viewer.ftl deleted file mode 100644 index c4507a3f..00000000 --- a/static/pdf.js/locale/es-CL/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Página anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Página siguiente -pdfjs-next-button-label = Siguiente -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Página -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Alejar -pdfjs-zoom-out-button-label = Alejar -pdfjs-zoom-in-button = - .title = Acercar -pdfjs-zoom-in-button-label = Acercar -pdfjs-zoom-select = - .title = Ampliación -pdfjs-presentation-mode-button = - .title = Cambiar al modo de presentación -pdfjs-presentation-mode-button-label = Modo de presentación -pdfjs-open-file-button = - .title = Abrir archivo -pdfjs-open-file-button-label = Abrir -pdfjs-print-button = - .title = Imprimir -pdfjs-print-button-label = Imprimir -pdfjs-save-button = - .title = Guardar -pdfjs-save-button-label = Guardar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Descargar -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Descargar -pdfjs-bookmark-button = - .title = Página actual (Ver URL de la página actual) -pdfjs-bookmark-button-label = Página actual -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Abrir en una aplicación -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Abrir en una aplicación - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Herramientas -pdfjs-tools-button-label = Herramientas -pdfjs-first-page-button = - .title = Ir a la primera página -pdfjs-first-page-button-label = Ir a la primera página -pdfjs-last-page-button = - .title = Ir a la última página -pdfjs-last-page-button-label = Ir a la última página -pdfjs-page-rotate-cw-button = - .title = Girar a la derecha -pdfjs-page-rotate-cw-button-label = Girar a la derecha -pdfjs-page-rotate-ccw-button = - .title = Girar a la izquierda -pdfjs-page-rotate-ccw-button-label = Girar a la izquierda -pdfjs-cursor-text-select-tool-button = - .title = Activar la herramienta de selección de texto -pdfjs-cursor-text-select-tool-button-label = Herramienta de selección de texto -pdfjs-cursor-hand-tool-button = - .title = Activar la herramienta de mano -pdfjs-cursor-hand-tool-button-label = Herramienta de mano -pdfjs-scroll-page-button = - .title = Usar desplazamiento de página -pdfjs-scroll-page-button-label = Desplazamiento de página -pdfjs-scroll-vertical-button = - .title = Usar desplazamiento vertical -pdfjs-scroll-vertical-button-label = Desplazamiento vertical -pdfjs-scroll-horizontal-button = - .title = Usar desplazamiento horizontal -pdfjs-scroll-horizontal-button-label = Desplazamiento horizontal -pdfjs-scroll-wrapped-button = - .title = Usar desplazamiento en bloque -pdfjs-scroll-wrapped-button-label = Desplazamiento en bloque -pdfjs-spread-none-button = - .title = No juntar páginas a modo de libro -pdfjs-spread-none-button-label = Vista de una página -pdfjs-spread-odd-button = - .title = Junta las páginas partiendo con una de número impar -pdfjs-spread-odd-button-label = Vista de libro impar -pdfjs-spread-even-button = - .title = Junta las páginas partiendo con una de número par -pdfjs-spread-even-button-label = Vista de libro par - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propiedades del documento… -pdfjs-document-properties-button-label = Propiedades del documento… -pdfjs-document-properties-file-name = Nombre de archivo: -pdfjs-document-properties-file-size = Tamaño del archivo: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Título: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Asunto: -pdfjs-document-properties-keywords = Palabras clave: -pdfjs-document-properties-creation-date = Fecha de creación: -pdfjs-document-properties-modification-date = Fecha de modificación: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creador: -pdfjs-document-properties-producer = Productor del PDF: -pdfjs-document-properties-version = Versión de PDF: -pdfjs-document-properties-page-count = Cantidad de páginas: -pdfjs-document-properties-page-size = Tamaño de la página: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = horizontal -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Oficio - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista rápida en Web: -pdfjs-document-properties-linearized-yes = Sí -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Cerrar - -## Print - -pdfjs-print-progress-message = Preparando documento para impresión… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancelar -pdfjs-printing-not-supported = Advertencia: Imprimir no está soportado completamente por este navegador. -pdfjs-printing-not-ready = Advertencia: El PDF no está completamente cargado para ser impreso. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Cambiar barra lateral (índice de contenidos del documento/adjuntos/capas) -pdfjs-toggle-sidebar-button-label = Mostrar u ocultar la barra lateral -pdfjs-document-outline-button = - .title = Mostrar esquema del documento (doble clic para expandir/contraer todos los elementos) -pdfjs-document-outline-button-label = Esquema del documento -pdfjs-attachments-button = - .title = Mostrar adjuntos -pdfjs-attachments-button-label = Adjuntos -pdfjs-layers-button = - .title = Mostrar capas (doble clic para restablecer todas las capas al estado predeterminado) -pdfjs-layers-button-label = Capas -pdfjs-thumbs-button = - .title = Mostrar miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Buscar elemento de esquema actual -pdfjs-current-outline-item-button-label = Elemento de esquema actual -pdfjs-findbar-button = - .title = Buscar en el documento -pdfjs-findbar-button-label = Buscar -pdfjs-additional-layers = Capas adicionales - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Página { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura de la página { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Encontrar - .placeholder = Encontrar en el documento… -pdfjs-find-previous-button = - .title = Buscar la aparición anterior de la frase -pdfjs-find-previous-button-label = Previo -pdfjs-find-next-button = - .title = Buscar la siguiente aparición de la frase -pdfjs-find-next-button-label = Siguiente -pdfjs-find-highlight-checkbox = Destacar todos -pdfjs-find-match-case-checkbox-label = Coincidir mayús./minús. -pdfjs-find-match-diacritics-checkbox-label = Coincidir diacríticos -pdfjs-find-entire-word-checkbox-label = Palabras completas -pdfjs-find-reached-top = Se alcanzó el inicio del documento, continuando desde el final -pdfjs-find-reached-bottom = Se alcanzó el final del documento, continuando desde el inicio -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] Coincidencia { $current } de { $total } - *[other] Coincidencia { $current } de { $total } - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Más de { $limit } coincidencia - *[other] Más de { $limit } coincidencias - } -pdfjs-find-not-found = Frase no encontrada - -## Predefined zoom values - -pdfjs-page-scale-width = Ancho de página -pdfjs-page-scale-fit = Ajuste de página -pdfjs-page-scale-auto = Aumento automático -pdfjs-page-scale-actual = Tamaño actual -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Página { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ocurrió un error al cargar el PDF. -pdfjs-invalid-file-error = Archivo PDF inválido o corrupto. -pdfjs-missing-file-error = Falta el archivo PDF. -pdfjs-unexpected-response-error = Respuesta del servidor inesperada. -pdfjs-rendering-error = Ocurrió un error al renderizar la página. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Anotación] - -## Password - -pdfjs-password-label = Ingrese la contraseña para abrir este archivo PDF. -pdfjs-password-invalid = Contraseña inválida. Por favor, vuelve a intentarlo. -pdfjs-password-ok-button = Aceptar -pdfjs-password-cancel-button = Cancelar -pdfjs-web-fonts-disabled = Las tipografías web están desactivadas: imposible usar las fuentes PDF embebidas. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texto -pdfjs-editor-free-text-button-label = Texto -pdfjs-editor-ink-button = - .title = Dibujar -pdfjs-editor-ink-button-label = Dibujar -pdfjs-editor-stamp-button = - .title = Añadir o editar imágenes -pdfjs-editor-stamp-button-label = Añadir o editar imágenes -pdfjs-editor-highlight-button = - .title = Destacar -pdfjs-editor-highlight-button-label = Destacar -pdfjs-highlight-floating-button = - .title = Destacar -pdfjs-highlight-floating-button1 = - .title = Destacar - .aria-label = Destacar -pdfjs-highlight-floating-button-label = Destacar - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Eliminar dibujo -pdfjs-editor-remove-freetext-button = - .title = Eliminar texto -pdfjs-editor-remove-stamp-button = - .title = Eliminar imagen -pdfjs-editor-remove-highlight-button = - .title = Quitar resaltado - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Color -pdfjs-editor-free-text-size-input = Tamaño -pdfjs-editor-ink-color-input = Color -pdfjs-editor-ink-thickness-input = Grosor -pdfjs-editor-ink-opacity-input = Opacidad -pdfjs-editor-stamp-add-image-button = - .title = Añadir imagen -pdfjs-editor-stamp-add-image-button-label = Añadir imagen -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Grosor -pdfjs-editor-free-highlight-thickness-title = - .title = Cambia el grosor al resaltar elementos que no sean texto -pdfjs-free-text = - .aria-label = Editor de texto -pdfjs-free-text-default-content = Empieza a escribir… -pdfjs-ink = - .aria-label = Editor de dibujos -pdfjs-ink-canvas = - .aria-label = Imagen creada por el usuario - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Texto alternativo -pdfjs-editor-alt-text-edit-button-label = Editar texto alternativo -pdfjs-editor-alt-text-dialog-label = Elige una opción -pdfjs-editor-alt-text-dialog-description = El texto alternativo (alt text) ayuda cuando las personas no pueden ver la imagen o cuando no se carga. -pdfjs-editor-alt-text-add-description-label = Añade una descripción -pdfjs-editor-alt-text-add-description-description = Intenta escribir 1 o 2 oraciones que describan el tema, el ambiente o las acciones. -pdfjs-editor-alt-text-mark-decorative-label = Marcar como decorativa -pdfjs-editor-alt-text-mark-decorative-description = Se utiliza para imágenes ornamentales, como bordes o marcas de agua. -pdfjs-editor-alt-text-cancel-button = Cancelar -pdfjs-editor-alt-text-save-button = Guardar -pdfjs-editor-alt-text-decorative-tooltip = Marcada como decorativa -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Por ejemplo: “Un joven se sienta a la mesa a comer” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Esquina superior izquierda — cambiar el tamaño -pdfjs-editor-resizer-label-top-middle = Borde superior en el medio — cambiar el tamaño -pdfjs-editor-resizer-label-top-right = Esquina superior derecha — cambiar el tamaño -pdfjs-editor-resizer-label-middle-right = Borde derecho en el medio — cambiar el tamaño -pdfjs-editor-resizer-label-bottom-right = Esquina inferior derecha — cambiar el tamaño -pdfjs-editor-resizer-label-bottom-middle = Borde inferior en el medio — cambiar el tamaño -pdfjs-editor-resizer-label-bottom-left = Esquina inferior izquierda — cambiar el tamaño -pdfjs-editor-resizer-label-middle-left = Borde izquierdo en el medio — cambiar el tamaño - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Color de resaltado -pdfjs-editor-colorpicker-button = - .title = Cambiar color -pdfjs-editor-colorpicker-dropdown = - .aria-label = Opciones de color -pdfjs-editor-colorpicker-yellow = - .title = Amarillo -pdfjs-editor-colorpicker-green = - .title = Verde -pdfjs-editor-colorpicker-blue = - .title = Azul -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Rojo - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Mostrar todo -pdfjs-editor-highlight-show-all-button = - .title = Mostrar todo diff --git a/static/pdf.js/locale/es-CL/viewer.properties b/static/pdf.js/locale/es-CL/viewer.properties new file mode 100644 index 00000000..0c610e6d --- /dev/null +++ b/static/pdf.js/locale/es-CL/viewer.properties @@ -0,0 +1,130 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +previous.title = Página anterior +previous_label = Anterior +next.title = Página siguiente +next_label = Siguiente +page_label = Página: +page_of = de {{pageCount}} +zoom_out.title = Alejar +zoom_out_label = Alejar +zoom_in.title = Acercar +zoom_in_label = Acercar +zoom.title = Ampliación +print.title = Imprimir +print_label = Imprimir +presentation_mode.title = Cambiar al modo de presentación +presentation_mode_label = Modo de presentación +open_file.title = Abrir archivo +open_file_label = Abrir +download.title = Descargar +download_label = Descargar +bookmark.title = Vista actual (copiar o abrir en nueva ventana) +bookmark_label = Vista actual +tools.title=Herramientas +tools_label=Herramientas +first_page.title=Ir a la primera página +first_page.label=Ir a la primera página +first_page_label=Ir a la primera página +last_page.title=Ir a la última página +last_page.label=Ir a la última página +last_page_label=Ir a la última página +page_rotate_cw.title=Girar a la derecha +page_rotate_cw.label=Girar a la derecha +page_rotate_cw_label=Girar a la derecha +page_rotate_ccw.title=Girar a la izquierda +page_rotate_ccw.label=Girar a la izquierda +page_rotate_ccw_label=Girar a la izquierda + +hand_tool_enable.title=Activar herramienta de mano +hand_tool_enable_label=Activar herramienta de mano +hand_tool_disable.title=Desactivar herramienta de mano +hand_tool_disable_label=Desactivar herramienta de mano + +document_properties.title=Propiedades del documento… +document_properties_label=Propiedades del documento… +document_properties_file_name=Nombre del archivo: +document_properties_file_size=Tamaño del archivo: +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Título: +document_properties_author=Autor: +document_properties_subject=Asunto: +document_properties_keywords=Palabras clave: +document_properties_creation_date=Fecha de creación: +document_properties_modification_date=Fecha de modificación: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creador: +document_properties_producer=Productor del PDF: +document_properties_version=Versión de PDF: +document_properties_page_count=Cantidad de páginas: +document_properties_close=Cerrar + +toggle_sidebar.title=Barra lateral +toggle_sidebar_label=Mostrar u ocultar la barra lateral +outline.title = Mostrar esquema del documento +outline_label = Esquema del documento +attachments.title=Mostrar adjuntos +attachments_label=Adjuntos +thumbs.title = Mostrar miniaturas +thumbs_label = Miniaturas +findbar.title = Buscar en el documento +findbar_label = Buscar +thumb_page_title = Página {{page}} +thumb_page_canvas = Miniatura de la página {{page}} +first_page.label = Ir a la primera página +last_page.label = Ir a la última página +page_rotate_cw.label = Rotar en sentido de los punteros del reloj +page_rotate_ccw.label = Rotar en sentido contrario a los punteros del reloj +find_label = Buscar: +find_previous.title = Encontrar la aparición anterior de la frase +find_previous_label = Previo +find_next.title = Encontrar la siguiente aparición de la frase +find_next_label = Siguiente +find_highlight = Destacar todos +find_match_case_label = Coincidir mayús./minús. +find_reached_top=Se alcanzó el inicio del documento, continuando desde el final +find_reached_bottom=Se alcanzó el final del documento, continuando desde el inicio +find_not_found = Frase no encontrada +error_more_info = Más información +error_less_info = Menos información +error_close = Cerrar +error_version_info=PDF.js v{{version}} (compilación: {{build}}) +error_message = Mensaje: {{message}} +error_stack = Pila: {{stack}} +error_file = Archivo: {{file}} +error_line = Línea: {{line}} +rendering_error = Ha ocurrido un error al renderizar la página. +page_scale_width = Ancho de página +page_scale_fit = Ajuste de página +page_scale_auto = Aumento automático +page_scale_actual = Tamaño actual +page_scale_percent={{scale}}% +loading_error_indicator = Error +loading_error = Ha ocurrido un error al cargar el PDF. +invalid_file_error = Archivo PDF inválido o corrupto. +missing_file_error=Falta el archivo PDF. +unexpected_response_error=Respuesta del servidor inesperada. + +text_annotation_type.alt=[{{type}} Anotación] +password_label=Ingrese la contraseña para abrir este archivo PDF. +password_invalid=Contraseña inválida. Por favor, vuelva a intentarlo. +password_ok=Aceptar +password_cancel=Cancelar + +printing_not_supported = Advertencia: Imprimir no está soportado completamente por este navegador. +printing_not_ready=Advertencia: El PDF no está completamente cargado para ser impreso. +web_fonts_disabled=Las fuentes web están desactivadas: imposible usar las fuentes PDF embebidas. +document_colors_not_allowed=Los documentos PDF no tienen permitido usar sus propios colores: 'Permitir a las páginas elegir sus propios colores' está desactivado en el navegador. diff --git a/static/pdf.js/locale/es-ES/viewer.ftl b/static/pdf.js/locale/es-ES/viewer.ftl deleted file mode 100644 index e3f87b47..00000000 --- a/static/pdf.js/locale/es-ES/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Página anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Página siguiente -pdfjs-next-button-label = Siguiente -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Página -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Reducir -pdfjs-zoom-out-button-label = Reducir -pdfjs-zoom-in-button = - .title = Aumentar -pdfjs-zoom-in-button-label = Aumentar -pdfjs-zoom-select = - .title = Tamaño -pdfjs-presentation-mode-button = - .title = Cambiar al modo presentación -pdfjs-presentation-mode-button-label = Modo presentación -pdfjs-open-file-button = - .title = Abrir archivo -pdfjs-open-file-button-label = Abrir -pdfjs-print-button = - .title = Imprimir -pdfjs-print-button-label = Imprimir -pdfjs-save-button = - .title = Guardar -pdfjs-save-button-label = Guardar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Descargar -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Descargar -pdfjs-bookmark-button = - .title = Página actual (Ver URL de la página actual) -pdfjs-bookmark-button-label = Página actual -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Abrir en aplicación -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Abrir en aplicación - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Herramientas -pdfjs-tools-button-label = Herramientas -pdfjs-first-page-button = - .title = Ir a la primera página -pdfjs-first-page-button-label = Ir a la primera página -pdfjs-last-page-button = - .title = Ir a la última página -pdfjs-last-page-button-label = Ir a la última página -pdfjs-page-rotate-cw-button = - .title = Rotar en sentido horario -pdfjs-page-rotate-cw-button-label = Rotar en sentido horario -pdfjs-page-rotate-ccw-button = - .title = Rotar en sentido antihorario -pdfjs-page-rotate-ccw-button-label = Rotar en sentido antihorario -pdfjs-cursor-text-select-tool-button = - .title = Activar herramienta de selección de texto -pdfjs-cursor-text-select-tool-button-label = Herramienta de selección de texto -pdfjs-cursor-hand-tool-button = - .title = Activar herramienta de mano -pdfjs-cursor-hand-tool-button-label = Herramienta de mano -pdfjs-scroll-page-button = - .title = Usar desplazamiento de página -pdfjs-scroll-page-button-label = Desplazamiento de página -pdfjs-scroll-vertical-button = - .title = Usar desplazamiento vertical -pdfjs-scroll-vertical-button-label = Desplazamiento vertical -pdfjs-scroll-horizontal-button = - .title = Usar desplazamiento horizontal -pdfjs-scroll-horizontal-button-label = Desplazamiento horizontal -pdfjs-scroll-wrapped-button = - .title = Usar desplazamiento en bloque -pdfjs-scroll-wrapped-button-label = Desplazamiento en bloque -pdfjs-spread-none-button = - .title = No juntar páginas en vista de libro -pdfjs-spread-none-button-label = Vista de libro -pdfjs-spread-odd-button = - .title = Juntar las páginas partiendo de una con número impar -pdfjs-spread-odd-button-label = Vista de libro impar -pdfjs-spread-even-button = - .title = Juntar las páginas partiendo de una con número par -pdfjs-spread-even-button-label = Vista de libro par - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propiedades del documento… -pdfjs-document-properties-button-label = Propiedades del documento… -pdfjs-document-properties-file-name = Nombre de archivo: -pdfjs-document-properties-file-size = Tamaño de archivo: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Título: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Asunto: -pdfjs-document-properties-keywords = Palabras clave: -pdfjs-document-properties-creation-date = Fecha de creación: -pdfjs-document-properties-modification-date = Fecha de modificación: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creador: -pdfjs-document-properties-producer = Productor PDF: -pdfjs-document-properties-version = Versión PDF: -pdfjs-document-properties-page-count = Número de páginas: -pdfjs-document-properties-page-size = Tamaño de la página: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = horizontal -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista rápida de la web: -pdfjs-document-properties-linearized-yes = Sí -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Cerrar - -## Print - -pdfjs-print-progress-message = Preparando documento para impresión… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancelar -pdfjs-printing-not-supported = Advertencia: Imprimir no está totalmente soportado por este navegador. -pdfjs-printing-not-ready = Advertencia: Este PDF no se ha cargado completamente para poder imprimirse. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Cambiar barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Alternar barra lateral (el documento contiene esquemas/adjuntos/capas) -pdfjs-toggle-sidebar-button-label = Cambiar barra lateral -pdfjs-document-outline-button = - .title = Mostrar resumen del documento (doble clic para expandir/contraer todos los elementos) -pdfjs-document-outline-button-label = Resumen de documento -pdfjs-attachments-button = - .title = Mostrar adjuntos -pdfjs-attachments-button-label = Adjuntos -pdfjs-layers-button = - .title = Mostrar capas (doble clic para restablecer todas las capas al estado predeterminado) -pdfjs-layers-button-label = Capas -pdfjs-thumbs-button = - .title = Mostrar miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Encontrar elemento de esquema actual -pdfjs-current-outline-item-button-label = Elemento de esquema actual -pdfjs-findbar-button = - .title = Buscar en el documento -pdfjs-findbar-button-label = Buscar -pdfjs-additional-layers = Capas adicionales - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Página { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura de la página { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Buscar - .placeholder = Buscar en el documento… -pdfjs-find-previous-button = - .title = Encontrar la anterior aparición de la frase -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button = - .title = Encontrar la siguiente aparición de esta frase -pdfjs-find-next-button-label = Siguiente -pdfjs-find-highlight-checkbox = Resaltar todos -pdfjs-find-match-case-checkbox-label = Coincidencia de mayús./minús. -pdfjs-find-match-diacritics-checkbox-label = Coincidir diacríticos -pdfjs-find-entire-word-checkbox-label = Palabras completas -pdfjs-find-reached-top = Se alcanzó el inicio del documento, se continúa desde el final -pdfjs-find-reached-bottom = Se alcanzó el final del documento, se continúa desde el inicio -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } de { $total } coincidencia - *[other] { $current } de { $total } coincidencias - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Más de { $limit } coincidencia - *[other] Más de { $limit } coincidencias - } -pdfjs-find-not-found = Frase no encontrada - -## Predefined zoom values - -pdfjs-page-scale-width = Anchura de la página -pdfjs-page-scale-fit = Ajuste de la página -pdfjs-page-scale-auto = Tamaño automático -pdfjs-page-scale-actual = Tamaño real -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Página { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ocurrió un error al cargar el PDF. -pdfjs-invalid-file-error = Fichero PDF no válido o corrupto. -pdfjs-missing-file-error = No hay fichero PDF. -pdfjs-unexpected-response-error = Respuesta inesperada del servidor. -pdfjs-rendering-error = Ocurrió un error al renderizar la página. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotación { $type }] - -## Password - -pdfjs-password-label = Introduzca la contraseña para abrir este archivo PDF. -pdfjs-password-invalid = Contraseña no válida. Vuelva a intentarlo. -pdfjs-password-ok-button = Aceptar -pdfjs-password-cancel-button = Cancelar -pdfjs-web-fonts-disabled = Las tipografías web están desactivadas: es imposible usar las tipografías PDF embebidas. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texto -pdfjs-editor-free-text-button-label = Texto -pdfjs-editor-ink-button = - .title = Dibujar -pdfjs-editor-ink-button-label = Dibujar -pdfjs-editor-stamp-button = - .title = Añadir o editar imágenes -pdfjs-editor-stamp-button-label = Añadir o editar imágenes -pdfjs-editor-highlight-button = - .title = Resaltar -pdfjs-editor-highlight-button-label = Resaltar -pdfjs-highlight-floating-button = - .title = Resaltar -pdfjs-highlight-floating-button1 = - .title = Resaltar - .aria-label = Resaltar -pdfjs-highlight-floating-button-label = Resaltar - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Eliminar dibujo -pdfjs-editor-remove-freetext-button = - .title = Eliminar texto -pdfjs-editor-remove-stamp-button = - .title = Eliminar imagen -pdfjs-editor-remove-highlight-button = - .title = Quitar resaltado - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Color -pdfjs-editor-free-text-size-input = Tamaño -pdfjs-editor-ink-color-input = Color -pdfjs-editor-ink-thickness-input = Grosor -pdfjs-editor-ink-opacity-input = Opacidad -pdfjs-editor-stamp-add-image-button = - .title = Añadir imagen -pdfjs-editor-stamp-add-image-button-label = Añadir imagen -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Grosor -pdfjs-editor-free-highlight-thickness-title = - .title = Cambiar el grosor al resaltar elementos que no sean texto -pdfjs-free-text = - .aria-label = Editor de texto -pdfjs-free-text-default-content = Empezar a escribir… -pdfjs-ink = - .aria-label = Editor de dibujos -pdfjs-ink-canvas = - .aria-label = Imagen creada por el usuario - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Texto alternativo -pdfjs-editor-alt-text-edit-button-label = Editar el texto alternativo -pdfjs-editor-alt-text-dialog-label = Eligir una opción -pdfjs-editor-alt-text-dialog-description = El texto alternativo (texto alternativo) ayuda cuando las personas no pueden ver la imagen o cuando no se carga. -pdfjs-editor-alt-text-add-description-label = Añadir una descripción -pdfjs-editor-alt-text-add-description-description = Intente escribir 1 o 2 frases que describan el tema, el entorno o las acciones. -pdfjs-editor-alt-text-mark-decorative-label = Marcar como decorativa -pdfjs-editor-alt-text-mark-decorative-description = Se utiliza para imágenes ornamentales, como bordes o marcas de agua. -pdfjs-editor-alt-text-cancel-button = Cancelar -pdfjs-editor-alt-text-save-button = Guardar -pdfjs-editor-alt-text-decorative-tooltip = Marcada como decorativa -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Por ejemplo: “Un joven se sienta a la mesa a comer” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Esquina superior izquierda — redimensionar -pdfjs-editor-resizer-label-top-middle = Borde superior en el medio — redimensionar -pdfjs-editor-resizer-label-top-right = Esquina superior derecha — redimensionar -pdfjs-editor-resizer-label-middle-right = Borde derecho en el medio — redimensionar -pdfjs-editor-resizer-label-bottom-right = Esquina inferior derecha — redimensionar -pdfjs-editor-resizer-label-bottom-middle = Borde inferior en el medio — redimensionar -pdfjs-editor-resizer-label-bottom-left = Esquina inferior izquierda — redimensionar -pdfjs-editor-resizer-label-middle-left = Borde izquierdo en el medio — redimensionar - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Color de resaltado -pdfjs-editor-colorpicker-button = - .title = Cambiar color -pdfjs-editor-colorpicker-dropdown = - .aria-label = Opciones de color -pdfjs-editor-colorpicker-yellow = - .title = Amarillo -pdfjs-editor-colorpicker-green = - .title = Verde -pdfjs-editor-colorpicker-blue = - .title = Azul -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Rojo - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Mostrar todo -pdfjs-editor-highlight-show-all-button = - .title = Mostrar todo diff --git a/static/pdf.js/locale/es-ES/viewer.properties b/static/pdf.js/locale/es-ES/viewer.properties new file mode 100644 index 00000000..54e17d21 --- /dev/null +++ b/static/pdf.js/locale/es-ES/viewer.properties @@ -0,0 +1,111 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +previous.title = Página anterior +previous_label = Anterior +next.title = Página siguiente +next_label = Siguiente +page_label = Página: +page_of = de {{pageCount}} +zoom_out.title = Reducir +zoom_out_label = Reducir +zoom_in.title = Aumentar +zoom_in_label = Aumentar +zoom.title = Tamaño +presentation_mode.title = Cambiar al modo presentación +presentation_mode_label = Modo presentación +open_file.title = Abrir archivo +open_file_label = Abrir +print.title = Imprimir +print_label = Imprimir +download.title = Descargar +download_label = Descargar +bookmark.title = Vista actual (copiar o abrir en una nueva ventana) +bookmark_label = Vista actual +tools.title = Herramientas +tools_label = Herramientas +first_page.title = Ir a la primera página +first_page.label = Ir a la primera página +first_page_label = Ir a la primera página +last_page.title = Ir a la última página +last_page.label = Ir a la última página +last_page_label = Ir a la última página +page_rotate_cw.title = Rotar en sentido horario +page_rotate_cw.label = Rotar en sentido horario +page_rotate_cw_label = Rotar en sentido horario +page_rotate_ccw.title = Rotar en sentido antihorario +page_rotate_ccw.label = Rotar en sentido antihorario +page_rotate_ccw_label = Rotar en sentido antihorario +hand_tool_enable.title = Activar herramienta mano +hand_tool_enable_label = Activar herramienta mano +hand_tool_disable.title = Desactivar herramienta mano +hand_tool_disable_label = Desactivar herramienta mano +document_properties.title = Propiedades del documento… +document_properties_label = Propiedades del documento… +document_properties_file_name = Nombre de archivo: +document_properties_file_size = Tamaño de archivo: +document_properties_kb = {{size_kb}} KB ({{size_b}} bytes) +document_properties_mb = {{size_mb}} MB ({{size_b}} bytes) +document_properties_title = Título: +document_properties_author = Autor: +document_properties_subject = Asunto: +document_properties_keywords = Palabras clave: +document_properties_creation_date = Fecha de creación: +document_properties_modification_date = Fecha de modificación: +document_properties_date_string = {{date}}, {{time}} +document_properties_creator = Creador: +document_properties_producer = Productor PDF: +document_properties_version = Versión PDF: +document_properties_page_count = Número de páginas: +document_properties_close = Cerrar +toggle_sidebar.title = Cambiar barra lateral +toggle_sidebar_label = Cambiar barra lateral +outline.title = Mostrar el esquema del documento +outline_label = Esquema del documento +attachments.title = Mostrar adjuntos +attachments_label = Adjuntos +thumbs.title = Mostrar miniaturas +thumbs_label = Miniaturas +findbar.title = Buscar en el documento +findbar_label = Buscar +thumb_page_title = Página {{page}} +thumb_page_canvas = Miniatura de la página {{page}} +find_label = Buscar: +find_previous.title = Encontrar la anterior aparición de la frase +find_previous_label = Anterior +find_next.title = Encontrar la siguiente aparición de esta frase +find_next_label = Siguiente +find_highlight = Resaltar todos +find_match_case_label = Coincidencia de mayús./minús. +find_reached_top = Se alcanzó el inicio del documento, se continúa desde el final +find_reached_bottom = Se alcanzó el final del documento, se continúa desde el inicio +find_not_found = Frase no encontrada +error_more_info = Más información +error_less_info = Menos información +error_close = Cerrar +error_version_info = PDF.js v{{version}} (build: {{build}}) +error_message = Mensaje: {{message}} +error_stack = Pila: {{stack}} +error_file = Archivo: {{file}} +error_line = Línea: {{line}} +rendering_error = Ocurrió un error al renderizar la página. +page_scale_width = Anchura de la página +page_scale_fit = Ajuste de la página +page_scale_auto = Tamaño automático +page_scale_actual = Tamaño real +page_scale_percent = {{scale}}% +loading_error_indicator = Error +loading_error = Ocurrió un error al cargar el PDF. +invalid_file_error = Fichero PDF no válido o corrupto. +missing_file_error = No hay fichero PDF. +unexpected_response_error = Respuesta inesperada del servidor. +text_annotation_type.alt = [Anotación {{type}}] +password_label = Introduzca la contraseña para abrir este archivo PDF. +password_invalid = Contraseña no válida. Vuelva a intentarlo. +password_ok = Aceptar +password_cancel = Cancelar +printing_not_supported = Advertencia: Imprimir no está totalmente soportado por este navegador. +printing_not_ready = Advertencia: Este PDF no se ha cargado completamente para poder imprimirse. +web_fonts_disabled = Las tipografías web están desactivadas: es imposible usar las tipografías PDF embebidas. +document_colors_not_allowed = Los documentos PDF no tienen permitido usar sus propios colores: 'Permitir a las páginas elegir sus propios colores' está desactivado en el navegador. diff --git a/static/pdf.js/locale/es-MX/viewer.ftl b/static/pdf.js/locale/es-MX/viewer.ftl deleted file mode 100644 index 0069c6eb..00000000 --- a/static/pdf.js/locale/es-MX/viewer.ftl +++ /dev/null @@ -1,299 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Página anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Página siguiente -pdfjs-next-button-label = Siguiente -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Página -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Reducir -pdfjs-zoom-out-button-label = Reducir -pdfjs-zoom-in-button = - .title = Aumentar -pdfjs-zoom-in-button-label = Aumentar -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Cambiar al modo presentación -pdfjs-presentation-mode-button-label = Modo presentación -pdfjs-open-file-button = - .title = Abrir archivo -pdfjs-open-file-button-label = Abrir -pdfjs-print-button = - .title = Imprimir -pdfjs-print-button-label = Imprimir -pdfjs-save-button = - .title = Guardar -pdfjs-save-button-label = Guardar -pdfjs-bookmark-button = - .title = Página actual (Ver URL de la página actual) -pdfjs-bookmark-button-label = Página actual -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Abrir en la aplicación -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Abrir en la aplicación - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Herramientas -pdfjs-tools-button-label = Herramientas -pdfjs-first-page-button = - .title = Ir a la primera página -pdfjs-first-page-button-label = Ir a la primera página -pdfjs-last-page-button = - .title = Ir a la última página -pdfjs-last-page-button-label = Ir a la última página -pdfjs-page-rotate-cw-button = - .title = Girar a la derecha -pdfjs-page-rotate-cw-button-label = Girar a la derecha -pdfjs-page-rotate-ccw-button = - .title = Girar a la izquierda -pdfjs-page-rotate-ccw-button-label = Girar a la izquierda -pdfjs-cursor-text-select-tool-button = - .title = Activar la herramienta de selección de texto -pdfjs-cursor-text-select-tool-button-label = Herramienta de selección de texto -pdfjs-cursor-hand-tool-button = - .title = Activar la herramienta de mano -pdfjs-cursor-hand-tool-button-label = Herramienta de mano -pdfjs-scroll-page-button = - .title = Usar desplazamiento de página -pdfjs-scroll-page-button-label = Desplazamiento de página -pdfjs-scroll-vertical-button = - .title = Usar desplazamiento vertical -pdfjs-scroll-vertical-button-label = Desplazamiento vertical -pdfjs-scroll-horizontal-button = - .title = Usar desplazamiento horizontal -pdfjs-scroll-horizontal-button-label = Desplazamiento horizontal -pdfjs-scroll-wrapped-button = - .title = Usar desplazamiento encapsulado -pdfjs-scroll-wrapped-button-label = Desplazamiento encapsulado -pdfjs-spread-none-button = - .title = No unir páginas separadas -pdfjs-spread-none-button-label = Vista de una página -pdfjs-spread-odd-button = - .title = Unir las páginas partiendo con una de número impar -pdfjs-spread-odd-button-label = Vista de libro impar -pdfjs-spread-even-button = - .title = Juntar las páginas partiendo con una de número par -pdfjs-spread-even-button-label = Vista de libro par - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propiedades del documento… -pdfjs-document-properties-button-label = Propiedades del documento… -pdfjs-document-properties-file-name = Nombre del archivo: -pdfjs-document-properties-file-size = Tamaño del archivo: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Título: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Asunto: -pdfjs-document-properties-keywords = Palabras claves: -pdfjs-document-properties-creation-date = Fecha de creación: -pdfjs-document-properties-modification-date = Fecha de modificación: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creador: -pdfjs-document-properties-producer = Productor PDF: -pdfjs-document-properties-version = Versión PDF: -pdfjs-document-properties-page-count = Número de páginas: -pdfjs-document-properties-page-size = Tamaño de la página: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = horizontal -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Oficio - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista rápida de la web: -pdfjs-document-properties-linearized-yes = Sí -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Cerrar - -## Print - -pdfjs-print-progress-message = Preparando documento para impresión… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancelar -pdfjs-printing-not-supported = Advertencia: La impresión no esta completamente soportada por este navegador. -pdfjs-printing-not-ready = Advertencia: El PDF no cargo completamente para impresión. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Cambiar barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Alternar barra lateral (el documento contiene esquemas/adjuntos/capas) -pdfjs-toggle-sidebar-button-label = Cambiar barra lateral -pdfjs-document-outline-button = - .title = Mostrar esquema del documento (doble clic para expandir/contraer todos los elementos) -pdfjs-document-outline-button-label = Esquema del documento -pdfjs-attachments-button = - .title = Mostrar adjuntos -pdfjs-attachments-button-label = Adjuntos -pdfjs-layers-button = - .title = Mostrar capas (doble clic para restablecer todas las capas al estado predeterminado) -pdfjs-layers-button-label = Capas -pdfjs-thumbs-button = - .title = Mostrar miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Buscar elemento de esquema actual -pdfjs-current-outline-item-button-label = Elemento de esquema actual -pdfjs-findbar-button = - .title = Buscar en el documento -pdfjs-findbar-button-label = Buscar -pdfjs-additional-layers = Capas adicionales - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Página { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura de la página { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Buscar - .placeholder = Buscar en el documento… -pdfjs-find-previous-button = - .title = Ir a la anterior frase encontrada -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button = - .title = Ir a la siguiente frase encontrada -pdfjs-find-next-button-label = Siguiente -pdfjs-find-highlight-checkbox = Resaltar todo -pdfjs-find-match-case-checkbox-label = Coincidir con mayúsculas y minúsculas -pdfjs-find-match-diacritics-checkbox-label = Coincidir diacríticos -pdfjs-find-entire-word-checkbox-label = Palabras completas -pdfjs-find-reached-top = Se alcanzó el inicio del documento, se buscará al final -pdfjs-find-reached-bottom = Se alcanzó el final del documento, se buscará al inicio -pdfjs-find-not-found = No se encontró la frase - -## Predefined zoom values - -pdfjs-page-scale-width = Ancho de página -pdfjs-page-scale-fit = Ajustar página -pdfjs-page-scale-auto = Zoom automático -pdfjs-page-scale-actual = Tamaño real -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Página { $page } - -## Loading indicator messages - -pdfjs-loading-error = Un error ocurrió al cargar el PDF. -pdfjs-invalid-file-error = Archivo PDF invalido o dañado. -pdfjs-missing-file-error = Archivo PDF no encontrado. -pdfjs-unexpected-response-error = Respuesta inesperada del servidor. -pdfjs-rendering-error = Un error ocurrió al renderizar la página. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } anotación] - -## Password - -pdfjs-password-label = Ingresa la contraseña para abrir este archivo PDF. -pdfjs-password-invalid = Contraseña inválida. Por favor intenta de nuevo. -pdfjs-password-ok-button = Aceptar -pdfjs-password-cancel-button = Cancelar -pdfjs-web-fonts-disabled = Las fuentes web están desactivadas: es imposible usar las fuentes PDF embebidas. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texto -pdfjs-editor-free-text-button-label = Texto -pdfjs-editor-ink-button = - .title = Dibujar -pdfjs-editor-ink-button-label = Dibujar -# Editor Parameters -pdfjs-editor-free-text-color-input = Color -pdfjs-editor-free-text-size-input = Tamaño -pdfjs-editor-ink-color-input = Color -pdfjs-editor-ink-thickness-input = Grossor -pdfjs-editor-ink-opacity-input = Opacidad -pdfjs-free-text = - .aria-label = Editor de texto -pdfjs-free-text-default-content = Empieza a escribir… -pdfjs-ink = - .aria-label = Editor de dibujo -pdfjs-ink-canvas = - .aria-label = Imagen creada por el usuario - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/es-MX/viewer.properties b/static/pdf.js/locale/es-MX/viewer.properties new file mode 100644 index 00000000..4b85e8ff --- /dev/null +++ b/static/pdf.js/locale/es-MX/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Página anterior +previous_label=Anterior +next.title=Página siguiente +next_label=Siguiente + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Página: +page_of=de {{pageCount}} + +zoom_out.title=Reducir +zoom_out_label=Reducir +zoom_in.title=Aumentar +zoom_in_label=Aumentar +zoom.title=Zoom +presentation_mode.title=Cambiar al modo presentación +presentation_mode_label=Modo presentación +open_file.title=Abrir archivo +open_file_label=Abrir +print.title=Imprimir +print_label=Imprimir +download.title=Descargar +download_label=Descargar +bookmark.title=Vista actual (copiar o abrir en una nueva ventana) +bookmark_label=Vista actual + +# Secondary toolbar and context menu +tools.title=Herramientas +tools_label=Herramientas +first_page.title=Ir a la primera página +first_page.label=Ir a la primera página +first_page_label=Ir a la primera página +last_page.title=Ir a la última página +last_page.label=Ir a la última página +last_page_label=Ir a la última página +page_rotate_cw.title=Girar a la derecha +page_rotate_cw.label=Girar a la derecha +page_rotate_cw_label=Girar a la derecha +page_rotate_ccw.title=Girar a la izquierda +page_rotate_ccw.label=Girar a la izquierda +page_rotate_ccw_label=Girar a la izquierda + +hand_tool_enable.title=Activar herramienta mano +hand_tool_enable_label=Activar herramienta mano +hand_tool_disable.title=Desactivar herramienta mano +hand_tool_disable_label=Desactivar herramienta mano + +# Document properties dialog box +document_properties.title=Propiedades del documento… +document_properties_label=Propiedades del documento… +document_properties_file_name=Nombre del archivo: +document_properties_file_size=Tamaño del archivo: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Título: +document_properties_author=Autor: +document_properties_subject=Asunto: +document_properties_keywords=Palabras claves: +document_properties_creation_date=Fecha de creación: +document_properties_modification_date=Fecha de modificación: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creador: +document_properties_producer=Productor PDF: +document_properties_version=Versión PDF: +document_properties_page_count=Número de páginas: +document_properties_close=Cerrar + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Cambiar barra lateral +toggle_sidebar_label=Cambiar barra lateral +outline.title=Mostrar esquema del documento +outline_label=Esquema del documento +attachments.title=Mostrar adjuntos +attachments_label=Adjuntos +thumbs.title=Mostrar miniaturas +thumbs_label=Miniaturas +findbar.title=Buscar en el documento +findbar_label=Buscar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Página {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura de la página {{page}} + +# Find panel button title and messages +find_label=Encontrar: +find_previous.title=Ir a la anterior frase encontrada +find_previous_label=Anterior +find_next.title=Ir a la siguiente frase encontrada +find_next_label=Siguiente +find_highlight=Resaltar todo +find_match_case_label=Coincidir con mayúsculas y minúsculas +find_reached_top=Se alcanzó el inicio del documento, se buscará al final +find_reached_bottom=Se alcanzó el final del documento, se buscará al inicio +find_not_found=No se encontró la frase + +# Error panel labels +error_more_info=Más información +error_less_info=Menos información +error_close=Cerrar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mensaje: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pila: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Archivo: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Línea: {{line}} +rendering_error=Un error ocurrió al renderizar la página. + +# Predefined zoom values +page_scale_width=Ancho de página +page_scale_fit=Ajustar página +page_scale_auto=Zoom automático +page_scale_actual=Tamaño real +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Error +loading_error=Un error ocurrió al cargar el PDF. +invalid_file_error=Archivo PDF invalido o dañado. +missing_file_error=Archivo PDF no encontrado. +unexpected_response_error=Respuesta inesperada del servidor. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} anotación] +password_label=Ingresa la contraseña para abrir este archivo PDF. +password_invalid=Contraseña inválida. Por favor intenta de nuevo. +password_ok=Aceptar +password_cancel=Cancelar + +printing_not_supported=Advertencia: La impresión no esta completamente soportada por este navegador. +printing_not_ready=Advertencia: El PDF no cargo completamente para impresión. +web_fonts_disabled=Las fuentes web están desactivadas: es imposible usar las fuentes PDF embebidas. +document_colors_not_allowed=Los documentos PDF no tienen permiso de usar sus propios colores: 'Permitir que las páginas elijan sus propios colores' esta desactivada en el navegador. diff --git a/static/pdf.js/locale/es/viewer.properties b/static/pdf.js/locale/es/viewer.properties new file mode 100644 index 00000000..fc8848f8 --- /dev/null +++ b/static/pdf.js/locale/es/viewer.properties @@ -0,0 +1,141 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Página anterior +previous_label=Anterior +next.title=Página siguiente +next_label=Siguiente + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Página: +page_of=de {{pageCount}} + +zoom_out.title=Reducir +zoom_out_label=Reducir +zoom_in.title=Aumentar +zoom_in_label=Aumentar +zoom.title=Ampliación +presentation_mode.title=Cambiar al modo de presentación +presentation_mode_label=Modo de presentación +open_file.title=Abrir un archivo +open_file_label=Abrir +print.title=Imprimir +print_label=Imprimir +download.title=Descargar +download_label=Descargar +bookmark.title=Vista actual (para copiar o abrir en otra ventana) +bookmark_label=Vista actual + +# Secondary toolbar and context menu +tools.title=Herramientas +tools_label=Herramientas +first_page.title=Ir a la primera página +first_page.label=Ir a la primera página +first_page_label=Ir a la primera página +last_page.title=Ir a la última página +last_page.label=Ir a la última página +last_page_label=Ir a la última página +page_rotate_cw.title=Girar a la derecha +page_rotate_cw.label=Girar a la derecha +page_rotate_cw_label=Girar a la derecha +page_rotate_ccw.title=Girar a la izquierda +page_rotate_ccw.label=Girar a la izquierda +page_rotate_ccw_label=Girar a la izquierda + +hand_tool_enable.title=Activar la herramienta Mano +hand_tool_enable_label=Activar la herramienta Mano +hand_tool_disable.title=Desactivar la herramienta Mano +hand_tool_disable_label=Desactivar la herramienta Mano + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Mostrar u ocultar la barra lateral +toggle_sidebar_label=Conmutar la barra lateral +outline.title=Mostrar el esquema del documento +outline_label=Esquema del documento +thumbs.title=Mostrar las miniaturas +thumbs_label=Miniaturas +findbar.title=Buscar en el documento +findbar_label=Buscar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Página {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura de la página {{page}} + +# Find panel button title and messages +find_label=Buscar: +find_previous.title=Ir a la frase encontrada anterior +find_previous_label=Anterior +find_next.title=Ir a la frase encontrada siguiente +find_next_label=Siguiente +find_highlight=Resaltar todo +find_match_case_label=Coincidir mayúsculas y minúsculas +find_reached_top=Se alcanzó el inicio del documento, se continúa desde el final +find_reached_bottom=Se alcanzó el final del documento, se continúa desde el inicio +find_not_found=No se encontró la frase + +# Error panel labels +error_more_info=Más información +error_less_info=Menos información +error_close=Cerrar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (compilación: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mensaje: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pila: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Archivo: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Línea: {{line}} +rendering_error=Ocurrió un error al renderizar la página. + +# Predefined zoom values +page_scale_width=Anchura de la página +page_scale_fit=Ajustar a la página +page_scale_auto=Ampliación automática +page_scale_actual=Tamaño real + +# Loading indicator messages +loading_error_indicator=Error +loading_error=Ocurrió un error al cargar el PDF. +invalid_file_error=El archivo PDF no es válido o está dañado. +missing_file_error=Falta el archivo PDF. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotación {{type}}] +password_label=Escriba la contraseña para abrir este archivo PDF. +password_invalid=La contraseña no es válida. Inténtelo de nuevo. +password_ok=Aceptar +password_cancel=Cancelar + +printing_not_supported=Aviso: Este navegador no es compatible completamente con la impresión. +printing_not_ready=Aviso: El PDF no se ha cargado completamente para su impresión. +web_fonts_disabled=Se han desactivado los tipos de letra web: no se pueden usar los tipos de letra incrustados en el PDF. +document_colors_disabled=No se permite que los documentos PDF usen sus propios colores: la opción «Permitir que las páginas elijan sus propios colores» está desactivada en el navegador. diff --git a/static/pdf.js/locale/et/viewer.ftl b/static/pdf.js/locale/et/viewer.ftl deleted file mode 100644 index b28c6d50..00000000 --- a/static/pdf.js/locale/et/viewer.ftl +++ /dev/null @@ -1,268 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Eelmine lehekülg -pdfjs-previous-button-label = Eelmine -pdfjs-next-button = - .title = Järgmine lehekülg -pdfjs-next-button-label = Järgmine -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Leht -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = / { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber }/{ $pagesCount }) -pdfjs-zoom-out-button = - .title = Vähenda -pdfjs-zoom-out-button-label = Vähenda -pdfjs-zoom-in-button = - .title = Suurenda -pdfjs-zoom-in-button-label = Suurenda -pdfjs-zoom-select = - .title = Suurendamine -pdfjs-presentation-mode-button = - .title = Lülitu esitlusrežiimi -pdfjs-presentation-mode-button-label = Esitlusrežiim -pdfjs-open-file-button = - .title = Ava fail -pdfjs-open-file-button-label = Ava -pdfjs-print-button = - .title = Prindi -pdfjs-print-button-label = Prindi - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tööriistad -pdfjs-tools-button-label = Tööriistad -pdfjs-first-page-button = - .title = Mine esimesele leheküljele -pdfjs-first-page-button-label = Mine esimesele leheküljele -pdfjs-last-page-button = - .title = Mine viimasele leheküljele -pdfjs-last-page-button-label = Mine viimasele leheküljele -pdfjs-page-rotate-cw-button = - .title = Pööra päripäeva -pdfjs-page-rotate-cw-button-label = Pööra päripäeva -pdfjs-page-rotate-ccw-button = - .title = Pööra vastupäeva -pdfjs-page-rotate-ccw-button-label = Pööra vastupäeva -pdfjs-cursor-text-select-tool-button = - .title = Luba teksti valimise tööriist -pdfjs-cursor-text-select-tool-button-label = Teksti valimise tööriist -pdfjs-cursor-hand-tool-button = - .title = Luba sirvimistööriist -pdfjs-cursor-hand-tool-button-label = Sirvimistööriist -pdfjs-scroll-page-button = - .title = Kasutatakse lehe kaupa kerimist -pdfjs-scroll-page-button-label = Lehe kaupa kerimine -pdfjs-scroll-vertical-button = - .title = Kasuta vertikaalset kerimist -pdfjs-scroll-vertical-button-label = Vertikaalne kerimine -pdfjs-scroll-horizontal-button = - .title = Kasuta horisontaalset kerimist -pdfjs-scroll-horizontal-button-label = Horisontaalne kerimine -pdfjs-scroll-wrapped-button = - .title = Kasuta rohkem mahutavat kerimist -pdfjs-scroll-wrapped-button-label = Rohkem mahutav kerimine -pdfjs-spread-none-button = - .title = Ära kõrvuta lehekülgi -pdfjs-spread-none-button-label = Lehtede kõrvutamine puudub -pdfjs-spread-odd-button = - .title = Kõrvuta leheküljed, alustades paaritute numbritega lehekülgedega -pdfjs-spread-odd-button-label = Kõrvutamine paaritute numbritega alustades -pdfjs-spread-even-button = - .title = Kõrvuta leheküljed, alustades paarisnumbritega lehekülgedega -pdfjs-spread-even-button-label = Kõrvutamine paarisnumbritega alustades - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumendi omadused… -pdfjs-document-properties-button-label = Dokumendi omadused… -pdfjs-document-properties-file-name = Faili nimi: -pdfjs-document-properties-file-size = Faili suurus: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KiB ({ $size_b } baiti) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MiB ({ $size_b } baiti) -pdfjs-document-properties-title = Pealkiri: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Teema: -pdfjs-document-properties-keywords = Märksõnad: -pdfjs-document-properties-creation-date = Loodud: -pdfjs-document-properties-modification-date = Muudetud: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date } { $time } -pdfjs-document-properties-creator = Looja: -pdfjs-document-properties-producer = Generaator: -pdfjs-document-properties-version = Generaatori versioon: -pdfjs-document-properties-page-count = Lehekülgi: -pdfjs-document-properties-page-size = Lehe suurus: -pdfjs-document-properties-page-size-unit-inches = tolli -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertikaalpaigutus -pdfjs-document-properties-page-size-orientation-landscape = rõhtpaigutus -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = "Fast Web View" tugi: -pdfjs-document-properties-linearized-yes = Jah -pdfjs-document-properties-linearized-no = Ei -pdfjs-document-properties-close-button = Sulge - -## Print - -pdfjs-print-progress-message = Dokumendi ettevalmistamine printimiseks… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Loobu -pdfjs-printing-not-supported = Hoiatus: printimine pole selle brauseri poolt täielikult toetatud. -pdfjs-printing-not-ready = Hoiatus: PDF pole printimiseks täielikult laaditud. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Näita külgriba -pdfjs-toggle-sidebar-notification-button = - .title = Näita külgriba (dokument sisaldab sisukorda/manuseid/kihte) -pdfjs-toggle-sidebar-button-label = Näita külgriba -pdfjs-document-outline-button = - .title = Näita sisukorda (kõigi punktide laiendamiseks/ahendamiseks topeltklõpsa) -pdfjs-document-outline-button-label = Näita sisukorda -pdfjs-attachments-button = - .title = Näita manuseid -pdfjs-attachments-button-label = Manused -pdfjs-layers-button = - .title = Näita kihte (kõikide kihtide vaikeolekusse lähtestamiseks topeltklõpsa) -pdfjs-layers-button-label = Kihid -pdfjs-thumbs-button = - .title = Näita pisipilte -pdfjs-thumbs-button-label = Pisipildid -pdfjs-current-outline-item-button = - .title = Otsi üles praegune kontuuriüksus -pdfjs-current-outline-item-button-label = Praegune kontuuriüksus -pdfjs-findbar-button = - .title = Otsi dokumendist -pdfjs-findbar-button-label = Otsi -pdfjs-additional-layers = Täiendavad kihid - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page }. lehekülg -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page }. lehekülje pisipilt - -## Find panel button title and messages - -pdfjs-find-input = - .title = Otsi - .placeholder = Otsi dokumendist… -pdfjs-find-previous-button = - .title = Otsi fraasi eelmine esinemiskoht -pdfjs-find-previous-button-label = Eelmine -pdfjs-find-next-button = - .title = Otsi fraasi järgmine esinemiskoht -pdfjs-find-next-button-label = Järgmine -pdfjs-find-highlight-checkbox = Too kõik esile -pdfjs-find-match-case-checkbox-label = Tõstutundlik -pdfjs-find-match-diacritics-checkbox-label = Otsitakse diakriitiliselt -pdfjs-find-entire-word-checkbox-label = Täissõnad -pdfjs-find-reached-top = Jõuti dokumendi algusesse, jätkati lõpust -pdfjs-find-reached-bottom = Jõuti dokumendi lõppu, jätkati algusest -pdfjs-find-not-found = Fraasi ei leitud - -## Predefined zoom values - -pdfjs-page-scale-width = Mahuta laiusele -pdfjs-page-scale-fit = Mahuta leheküljele -pdfjs-page-scale-auto = Automaatne suurendamine -pdfjs-page-scale-actual = Tegelik suurus -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Lehekülg { $page } - -## Loading indicator messages - -pdfjs-loading-error = PDFi laadimisel esines viga. -pdfjs-invalid-file-error = Vigane või rikutud PDF-fail. -pdfjs-missing-file-error = PDF-fail puudub. -pdfjs-unexpected-response-error = Ootamatu vastus serverilt. -pdfjs-rendering-error = Lehe renderdamisel esines viga. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date } { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = PDF-faili avamiseks sisesta parool. -pdfjs-password-invalid = Vigane parool. Palun proovi uuesti. -pdfjs-password-ok-button = Sobib -pdfjs-password-cancel-button = Loobu -pdfjs-web-fonts-disabled = Veebifondid on keelatud: PDFiga kaasatud fonte pole võimalik kasutada. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/et/viewer.properties b/static/pdf.js/locale/et/viewer.properties new file mode 100644 index 00000000..83da357b --- /dev/null +++ b/static/pdf.js/locale/et/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Eelmine lehekülg +previous_label=Eelmine +next.title=Järgmine lehekülg +next_label=Järgmine + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Lehekülg: +page_of=(kokku {{pageCount}}) + +zoom_out.title=Vähenda +zoom_out_label=Vähenda +zoom_in.title=Suurenda +zoom_in_label=Suurenda +zoom.title=Suurendamine +presentation_mode.title=Lülitu esitlusrežiimi +presentation_mode_label=Esitlusrežiim +open_file.title=Ava fail +open_file_label=Ava +print.title=Prindi +print_label=Prindi +download.title=Laadi alla +download_label=Laadi alla +bookmark.title=Praegune vaade (kopeeri või ava uues aknas) +bookmark_label=Praegune vaade + +# Secondary toolbar and context menu +tools.title=Tööriistad +tools_label=Tööriistad +first_page.title=Mine esimesele leheküljele +first_page.label=Mine esimesele leheküljele +first_page_label=Mine esimesele leheküljele +last_page.title=Mine viimasele leheküljele +last_page.label=Mine viimasele leheküljele +last_page_label=Mine viimasele leheküljele +page_rotate_cw.title=Pööra päripäeva +page_rotate_cw.label=Pööra päripäeva +page_rotate_cw_label=Pööra päripäeva +page_rotate_ccw.title=Pööra vastupäeva +page_rotate_ccw.label=Pööra vastupäeva +page_rotate_ccw_label=Pööra vastupäeva + +hand_tool_enable.title=Luba sirvimine +hand_tool_enable_label=Luba sirvimine +hand_tool_disable.title=Keela sirvimine +hand_tool_disable_label=Keela sirvimine + +# Document properties dialog box +document_properties.title=Dokumendi omadused… +document_properties_label=Dokumendi omadused… +document_properties_file_name=Faili nimi: +document_properties_file_size=Faili suurus: +document_properties_kb={{size_kb}} KiB ({{size_b}} baiti) +document_properties_mb={{size_mb}} MiB ({{size_b}} baiti) +document_properties_title=Pealkiri: +document_properties_author=Autor: +document_properties_subject=Teema: +document_properties_keywords=Märksõnad: +document_properties_creation_date=Loodud: +document_properties_modification_date=Muudetud: +document_properties_date_string={{date}} {{time}} +document_properties_creator=Looja: +document_properties_producer=Generaator: +document_properties_version=Generaatori versioon: +document_properties_page_count=Lehekülgi: +document_properties_close=Sulge + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Näita külgriba +toggle_sidebar_label=Näita külgriba +outline.title=Näita sisukorda +outline_label=Näita sisukorda +attachments.title=Näita manuseid +attachments_label=Manused +thumbs.title=Näita pisipilte +thumbs_label=Pisipildid +findbar.title=Otsi dokumendist +findbar_label=Otsi + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title={{page}}. lehekülg +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}}. lehekülje pisipilt + +# Find panel button title and messages +find_label=Otsi: +find_previous.title=Otsi fraasi eelmine esinemiskoht +find_previous_label=Eelmine +find_next.title=Otsi fraasi järgmine esinemiskoht +find_next_label=Järgmine +find_highlight=Too kõik esile +find_match_case_label=Tõstutundlik +find_reached_top=Jõuti dokumendi algusesse, jätkati lõpust +find_reached_bottom=Jõuti dokumendi lõppu, jätkati algusest +find_not_found=Fraasi ei leitud + +# Error panel labels +error_more_info=Rohkem teavet +error_less_info=Vähem teavet +error_close=Sulge +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Teade: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fail: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rida: {{line}} +rendering_error=Lehe renderdamisel esines viga. + +# Predefined zoom values +page_scale_width=Mahuta laiusele +page_scale_fit=Mahuta leheküljele +page_scale_auto=Automaatne suurendamine +page_scale_actual=Tegelik suurus +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Viga +loading_error=PDFi laadimisel esines viga. +invalid_file_error=Vigane või rikutud PDF-fail. +missing_file_error=PDF-fail puudub. +unexpected_response_error=Ootamatu vastus serverilt. + +# LOCALIZATION NOTE (text_annotation_type): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=PDF-faili avamiseks sisesta parool. +password_invalid=Vigane parool. Palun proovi uuesti. +password_ok=Sobib +password_cancel=Loobu + +printing_not_supported=Hoiatus: printimine pole selle brauseri poolt täielikult toetatud. +printing_not_ready=Hoiatus: PDF pole printimiseks täielikult laaditud. +web_fonts_disabled=Veebifondid on keelatud: PDFiga kaasatud fonte pole võimalik kasutada. +document_colors_disabled=PDF-dokumentidel pole oma värvide kasutamine lubatud: \'Veebilehtedel on lubatud kasutada oma värve\' on brauseris deaktiveeritud. diff --git a/static/pdf.js/locale/eu/viewer.ftl b/static/pdf.js/locale/eu/viewer.ftl deleted file mode 100644 index 1ed37397..00000000 --- a/static/pdf.js/locale/eu/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Aurreko orria -pdfjs-previous-button-label = Aurrekoa -pdfjs-next-button = - .title = Hurrengo orria -pdfjs-next-button-label = Hurrengoa -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Orria -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = / { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = { $pagesCount }/{ $pageNumber } -pdfjs-zoom-out-button = - .title = Urrundu zooma -pdfjs-zoom-out-button-label = Urrundu zooma -pdfjs-zoom-in-button = - .title = Gerturatu zooma -pdfjs-zoom-in-button-label = Gerturatu zooma -pdfjs-zoom-select = - .title = Zooma -pdfjs-presentation-mode-button = - .title = Aldatu aurkezpen modura -pdfjs-presentation-mode-button-label = Arkezpen modua -pdfjs-open-file-button = - .title = Ireki fitxategia -pdfjs-open-file-button-label = Ireki -pdfjs-print-button = - .title = Inprimatu -pdfjs-print-button-label = Inprimatu -pdfjs-save-button = - .title = Gorde -pdfjs-save-button-label = Gorde -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Deskargatu -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Deskargatu -pdfjs-bookmark-button = - .title = Uneko orria (ikusi uneko orriaren URLa) -pdfjs-bookmark-button-label = Uneko orria -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Ireki aplikazioan -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Ireki aplikazioan - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tresnak -pdfjs-tools-button-label = Tresnak -pdfjs-first-page-button = - .title = Joan lehen orrira -pdfjs-first-page-button-label = Joan lehen orrira -pdfjs-last-page-button = - .title = Joan azken orrira -pdfjs-last-page-button-label = Joan azken orrira -pdfjs-page-rotate-cw-button = - .title = Biratu erlojuaren norantzan -pdfjs-page-rotate-cw-button-label = Biratu erlojuaren norantzan -pdfjs-page-rotate-ccw-button = - .title = Biratu erlojuaren aurkako norantzan -pdfjs-page-rotate-ccw-button-label = Biratu erlojuaren aurkako norantzan -pdfjs-cursor-text-select-tool-button = - .title = Gaitu testuaren hautapen tresna -pdfjs-cursor-text-select-tool-button-label = Testuaren hautapen tresna -pdfjs-cursor-hand-tool-button = - .title = Gaitu eskuaren tresna -pdfjs-cursor-hand-tool-button-label = Eskuaren tresna -pdfjs-scroll-page-button = - .title = Erabili orriaren korritzea -pdfjs-scroll-page-button-label = Orriaren korritzea -pdfjs-scroll-vertical-button = - .title = Erabili korritze bertikala -pdfjs-scroll-vertical-button-label = Korritze bertikala -pdfjs-scroll-horizontal-button = - .title = Erabili korritze horizontala -pdfjs-scroll-horizontal-button-label = Korritze horizontala -pdfjs-scroll-wrapped-button = - .title = Erabili korritze egokitua -pdfjs-scroll-wrapped-button-label = Korritze egokitua -pdfjs-spread-none-button = - .title = Ez elkartu barreiatutako orriak -pdfjs-spread-none-button-label = Barreiatzerik ez -pdfjs-spread-odd-button = - .title = Elkartu barreiatutako orriak bakoiti zenbakidunekin hasita -pdfjs-spread-odd-button-label = Barreiatze bakoitia -pdfjs-spread-even-button = - .title = Elkartu barreiatutako orriak bikoiti zenbakidunekin hasita -pdfjs-spread-even-button-label = Barreiatze bikoitia - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumentuaren propietateak… -pdfjs-document-properties-button-label = Dokumentuaren propietateak… -pdfjs-document-properties-file-name = Fitxategi-izena: -pdfjs-document-properties-file-size = Fitxategiaren tamaina: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } byte) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } byte) -pdfjs-document-properties-title = Izenburua: -pdfjs-document-properties-author = Egilea: -pdfjs-document-properties-subject = Gaia: -pdfjs-document-properties-keywords = Gako-hitzak: -pdfjs-document-properties-creation-date = Sortze-data: -pdfjs-document-properties-modification-date = Aldatze-data: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Sortzailea: -pdfjs-document-properties-producer = PDFaren ekoizlea: -pdfjs-document-properties-version = PDF bertsioa: -pdfjs-document-properties-page-count = Orrialde kopurua: -pdfjs-document-properties-page-size = Orriaren tamaina: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = bertikala -pdfjs-document-properties-page-size-orientation-landscape = horizontala -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Gutuna -pdfjs-document-properties-page-size-name-legal = Legala - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Webeko ikuspegi bizkorra: -pdfjs-document-properties-linearized-yes = Bai -pdfjs-document-properties-linearized-no = Ez -pdfjs-document-properties-close-button = Itxi - -## Print - -pdfjs-print-progress-message = Dokumentua inprimatzeko prestatzen… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = %{ $progress } -pdfjs-print-progress-close-button = Utzi -pdfjs-printing-not-supported = Abisua: inprimatzeko euskarria ez da erabatekoa nabigatzaile honetan. -pdfjs-printing-not-ready = Abisua: PDFa ez dago erabat kargatuta inprimatzeko. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Txandakatu alboko barra -pdfjs-toggle-sidebar-notification-button = - .title = Txandakatu alboko barra (dokumentuak eskema/eranskinak/geruzak ditu) -pdfjs-toggle-sidebar-button-label = Txandakatu alboko barra -pdfjs-document-outline-button = - .title = Erakutsi dokumentuaren eskema (klik bikoitza elementu guztiak zabaltzeko/tolesteko) -pdfjs-document-outline-button-label = Dokumentuaren eskema -pdfjs-attachments-button = - .title = Erakutsi eranskinak -pdfjs-attachments-button-label = Eranskinak -pdfjs-layers-button = - .title = Erakutsi geruzak (klik bikoitza geruza guztiak egoera lehenetsira berrezartzeko) -pdfjs-layers-button-label = Geruzak -pdfjs-thumbs-button = - .title = Erakutsi koadro txikiak -pdfjs-thumbs-button-label = Koadro txikiak -pdfjs-current-outline-item-button = - .title = Bilatu uneko eskemaren elementua -pdfjs-current-outline-item-button-label = Uneko eskemaren elementua -pdfjs-findbar-button = - .title = Bilatu dokumentuan -pdfjs-findbar-button-label = Bilatu -pdfjs-additional-layers = Geruza gehigarriak - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page }. orria -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page }. orriaren koadro txikia - -## Find panel button title and messages - -pdfjs-find-input = - .title = Bilatu - .placeholder = Bilatu dokumentuan… -pdfjs-find-previous-button = - .title = Bilatu esaldiaren aurreko parekatzea -pdfjs-find-previous-button-label = Aurrekoa -pdfjs-find-next-button = - .title = Bilatu esaldiaren hurrengo parekatzea -pdfjs-find-next-button-label = Hurrengoa -pdfjs-find-highlight-checkbox = Nabarmendu guztia -pdfjs-find-match-case-checkbox-label = Bat etorri maiuskulekin/minuskulekin -pdfjs-find-match-diacritics-checkbox-label = Bereizi diakritikoak -pdfjs-find-entire-word-checkbox-label = Hitz osoak -pdfjs-find-reached-top = Dokumentuaren hasierara heldu da, bukaeratik jarraitzen -pdfjs-find-reached-bottom = Dokumentuaren bukaerara heldu da, hasieratik jarraitzen -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $total }/{ $current }. bat-etortzea - *[other] { $total }/{ $current }. bat-etortzea - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Bat datorren { $limit } baino gehiago - *[other] Bat datozen { $limit } baino gehiago - } -pdfjs-find-not-found = Esaldia ez da aurkitu - -## Predefined zoom values - -pdfjs-page-scale-width = Orriaren zabalera -pdfjs-page-scale-fit = Doitu orrira -pdfjs-page-scale-auto = Zoom automatikoa -pdfjs-page-scale-actual = Benetako tamaina -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = %{ $scale } - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = { $page }. orria - -## Loading indicator messages - -pdfjs-loading-error = Errorea gertatu da PDFa kargatzean. -pdfjs-invalid-file-error = PDF fitxategi baliogabe edo hondatua. -pdfjs-missing-file-error = PDF fitxategia falta da. -pdfjs-unexpected-response-error = Espero gabeko zerbitzariaren erantzuna. -pdfjs-rendering-error = Errorea gertatu da orria errendatzean. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } ohartarazpena] - -## Password - -pdfjs-password-label = Idatzi PDF fitxategi hau irekitzeko pasahitza. -pdfjs-password-invalid = Pasahitz baliogabea. Saiatu berriro mesedez. -pdfjs-password-ok-button = Ados -pdfjs-password-cancel-button = Utzi -pdfjs-web-fonts-disabled = Webeko letra-tipoak desgaituta daude: ezin dira kapsulatutako PDF letra-tipoak erabili. - -## Editing - -pdfjs-editor-free-text-button = - .title = Testua -pdfjs-editor-free-text-button-label = Testua -pdfjs-editor-ink-button = - .title = Marrazkia -pdfjs-editor-ink-button-label = Marrazkia -pdfjs-editor-stamp-button = - .title = Gehitu edo editatu irudiak -pdfjs-editor-stamp-button-label = Gehitu edo editatu irudiak -pdfjs-editor-highlight-button = - .title = Nabarmendu -pdfjs-editor-highlight-button-label = Nabarmendu -pdfjs-highlight-floating-button = - .title = Nabarmendu -pdfjs-highlight-floating-button1 = - .title = Nabarmendu - .aria-label = Nabarmendu -pdfjs-highlight-floating-button-label = Nabarmendu - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Kendu marrazkia -pdfjs-editor-remove-freetext-button = - .title = Kendu testua -pdfjs-editor-remove-stamp-button = - .title = Kendu irudia -pdfjs-editor-remove-highlight-button = - .title = Kendu nabarmentzea - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Kolorea -pdfjs-editor-free-text-size-input = Tamaina -pdfjs-editor-ink-color-input = Kolorea -pdfjs-editor-ink-thickness-input = Loditasuna -pdfjs-editor-ink-opacity-input = Opakutasuna -pdfjs-editor-stamp-add-image-button = - .title = Gehitu irudia -pdfjs-editor-stamp-add-image-button-label = Gehitu irudia -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Loditasuna -pdfjs-editor-free-highlight-thickness-title = - .title = Aldatu loditasuna testua ez beste elementuak nabarmentzean -pdfjs-free-text = - .aria-label = Testu-editorea -pdfjs-free-text-default-content = Hasi idazten… -pdfjs-ink = - .aria-label = Marrazki-editorea -pdfjs-ink-canvas = - .aria-label = Erabiltzaileak sortutako irudia - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Testu alternatiboa -pdfjs-editor-alt-text-edit-button-label = Editatu testu alternatiboa -pdfjs-editor-alt-text-dialog-label = Aukeratu aukera -pdfjs-editor-alt-text-dialog-description = Testu alternatiboak laguntzen du jendeak ezin duenean irudia ikusi edo ez denean kargatzen. -pdfjs-editor-alt-text-add-description-label = Gehitu azalpena -pdfjs-editor-alt-text-add-description-description = Saiatu idazten gaia, ezarpena edo ekintzak deskribatzen dituen esaldi 1 edo 2. -pdfjs-editor-alt-text-mark-decorative-label = Markatu apaingarri gisa -pdfjs-editor-alt-text-mark-decorative-description = Irudiak apaingarrientzat erabiltzen da, adibidez ertz edo ur-marketarako. -pdfjs-editor-alt-text-cancel-button = Utzi -pdfjs-editor-alt-text-save-button = Gorde -pdfjs-editor-alt-text-decorative-tooltip = Apaingarri gisa markatuta -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Adibidez, "gizon gaztea mahaian eserita dago bazkaltzeko" - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Goiko ezkerreko izkina — aldatu tamaina -pdfjs-editor-resizer-label-top-middle = Goian erdian — aldatu tamaina -pdfjs-editor-resizer-label-top-right = Goiko eskuineko izkina — aldatu tamaina -pdfjs-editor-resizer-label-middle-right = Erdian eskuinean — aldatu tamaina -pdfjs-editor-resizer-label-bottom-right = Beheko eskuineko izkina — aldatu tamaina -pdfjs-editor-resizer-label-bottom-middle = Behean erdian — aldatu tamaina -pdfjs-editor-resizer-label-bottom-left = Beheko ezkerreko izkina — aldatu tamaina -pdfjs-editor-resizer-label-middle-left = Erdian ezkerrean — aldatu tamaina - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Nabarmentze kolorea -pdfjs-editor-colorpicker-button = - .title = Aldatu kolorea -pdfjs-editor-colorpicker-dropdown = - .aria-label = Kolore-aukerak -pdfjs-editor-colorpicker-yellow = - .title = Horia -pdfjs-editor-colorpicker-green = - .title = Berdea -pdfjs-editor-colorpicker-blue = - .title = Urdina -pdfjs-editor-colorpicker-pink = - .title = Arrosa -pdfjs-editor-colorpicker-red = - .title = Gorria - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Erakutsi denak -pdfjs-editor-highlight-show-all-button = - .title = Erakutsi denak diff --git a/static/pdf.js/locale/eu/viewer.properties b/static/pdf.js/locale/eu/viewer.properties new file mode 100644 index 00000000..c3029896 --- /dev/null +++ b/static/pdf.js/locale/eu/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Aurreko orria +previous_label=Aurrekoa +next.title=Hurrengo orria +next_label=Hurrengoa + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Orria: +page_of=/ {{pageCount}} + +zoom_out.title=Urrundu zooma +zoom_out_label=Urrundu zooma +zoom_in.title=Gerturatu zooma +zoom_in_label=Gerturatu zooma +zoom.title=Zooma +presentation_mode.title=Aldatu aurkezpen modura +presentation_mode_label=Arkezpen modua +open_file.title=Ireki fitxategia +open_file_label=Ireki +print.title=Inprimatu +print_label=Inprimatu +download.title=Deskargatu +download_label=Deskargatu +bookmark.title=Uneko ikuspegia (kopiatu edo ireki leiho berrian) +bookmark_label=Uneko ikuspegia + +# Secondary toolbar and context menu +tools.title=Tresnak +tools_label=Tresnak +first_page.title=Joan lehen orrira +first_page.label=Joan lehen orrira +first_page_label=Joan lehen orrira +last_page.title=Joan azken orrira +last_page.label=Joan azken orrira +last_page_label=Joan azken orrira +page_rotate_cw.title=Biratu erlojuaren norantzan +page_rotate_cw.label=Biratu erlojuaren norantzan +page_rotate_cw_label=Biratu erlojuaren norantzan +page_rotate_ccw.title=Biratu erlojuaren aurkako norantzan +page_rotate_ccw.label=Biratu erlojuaren aurkako norantzan +page_rotate_ccw_label=Biratu erlojuaren aurkako norantzan + +hand_tool_enable.title=Gaitu eskuaren tresna +hand_tool_enable_label=Gaitu eskuaren tresna +hand_tool_disable.title=Desgaitu eskuaren tresna +hand_tool_disable_label=Desgaitu eskuaren tresna + +# Document properties dialog box +document_properties.title=Dokumentuaren propietateak… +document_properties_label=Dokumentuaren propietateak… +document_properties_file_name=Fitxategi-izena: +document_properties_file_size=Fitxategiaren tamaina: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} byte) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} byte) +document_properties_title=Izenburua: +document_properties_author=Egilea: +document_properties_subject=Gaia: +document_properties_keywords=Gako-hitzak: +document_properties_creation_date=Sortze-data: +document_properties_modification_date=Aldatze-data: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Sortzailea: +document_properties_producer=PDFaren ekoizlea: +document_properties_version=PDF bertsioa: +document_properties_page_count=Orrialde kopurua: +document_properties_close=Itxi + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Txandakatu alboko barra +toggle_sidebar_label=Txandakatu alboko barra +outline.title=Erakutsi dokumentuaren eskema +outline_label=Dokumentuaren eskema +attachments.title=Erakutsi eranskinak +attachments_label=Eranskinak +thumbs.title=Erakutsi koadro txikiak +thumbs_label=Koadro txikiak +findbar.title=Bilatu dokumentuan +findbar_label=Bilatu + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title={{page}}. orria +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}}. orriaren koadro txikia + +# Find panel button title and messages +find_label=Bilatu: +find_previous.title=Bilatu esaldiaren aurreko parekatzea +find_previous_label=Aurrekoa +find_next.title=Bilatu esaldiaren hurrengo parekatzea +find_next_label=Hurrengoa +find_highlight=Nabarmendu guztia +find_match_case_label=Bat etorri maiuskulekin/minuskulekin +find_reached_top=Dokumentuaren hasierara heldu da, bukaeratik jarraitzen +find_reached_bottom=Dokumentuaren bukaerara heldu da, hasieratik jarraitzen +find_not_found=Esaldia ez da aurkitu + +# Error panel labels +error_more_info=Informazio gehiago +error_less_info=Informazio gutxiago +error_close=Itxi +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (eraikuntza: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mezua: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pila: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fitxategia: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Lerroa: {{line}} +rendering_error=Errorea gertatu da orria errendatzean. + +# Predefined zoom values +page_scale_width=Orriaren zabalera +page_scale_fit=Doitu orrira +page_scale_auto=Zoom automatikoa +page_scale_actual=Benetako tamaina +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent=%{{scale}} + +# Loading indicator messages +loading_error_indicator=Errorea +loading_error=Errorea gertatu da PDFa kargatzean. +invalid_file_error=PDF fitxategi baliogabe edo hondatua. +missing_file_error=PDF fitxategia falta da. +unexpected_response_error=Espero gabeko zerbitzariaren erantzuna. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} ohartarazpena] +password_label=Idatzi PDF fitxategi hau irekitzeko pasahitza. +password_invalid=Pasahitz baliogabea. Saiatu berriro mesedez. +password_ok=Ados +password_cancel=Utzi + +printing_not_supported=Abisua: inprimatzeko euskarria ez da erabatekoa nabigatzaile honetan. +printing_not_ready=Abisua: PDFa ez dago erabat kargatuta inprimatzeko. +web_fonts_disabled=Webeko letra-tipoak desgaituta daude: ezin dira kapsulatutako PDF letra-tipoak erabili. +document_colors_not_allowed=PDF dokumentuek ez dute beraien koloreak erabiltzeko baimenik: 'Baimendu orriak beraien letra-tipoak aukeratzea' desaktibatuta dago nabigatzailean. diff --git a/static/pdf.js/locale/fa/viewer.ftl b/static/pdf.js/locale/fa/viewer.ftl deleted file mode 100644 index f367e3c6..00000000 --- a/static/pdf.js/locale/fa/viewer.ftl +++ /dev/null @@ -1,246 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = صفحهٔ قبلی -pdfjs-previous-button-label = قبلی -pdfjs-next-button = - .title = صفحهٔ بعدی -pdfjs-next-button-label = بعدی -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = صفحه -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = از { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber }از { $pagesCount }) -pdfjs-zoom-out-button = - .title = کوچک‌نمایی -pdfjs-zoom-out-button-label = کوچک‌نمایی -pdfjs-zoom-in-button = - .title = بزرگ‌نمایی -pdfjs-zoom-in-button-label = بزرگ‌نمایی -pdfjs-zoom-select = - .title = زوم -pdfjs-presentation-mode-button = - .title = تغییر به حالت ارائه -pdfjs-presentation-mode-button-label = حالت ارائه -pdfjs-open-file-button = - .title = باز کردن پرونده -pdfjs-open-file-button-label = باز کردن -pdfjs-print-button = - .title = چاپ -pdfjs-print-button-label = چاپ -pdfjs-save-button-label = ذخیره - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ابزارها -pdfjs-tools-button-label = ابزارها -pdfjs-first-page-button = - .title = برو به اولین صفحه -pdfjs-first-page-button-label = برو به اولین صفحه -pdfjs-last-page-button = - .title = برو به آخرین صفحه -pdfjs-last-page-button-label = برو به آخرین صفحه -pdfjs-page-rotate-cw-button = - .title = چرخش ساعتگرد -pdfjs-page-rotate-cw-button-label = چرخش ساعتگرد -pdfjs-page-rotate-ccw-button = - .title = چرخش پاد ساعتگرد -pdfjs-page-rotate-ccw-button-label = چرخش پاد ساعتگرد -pdfjs-cursor-text-select-tool-button = - .title = فعال کردن ابزارِ انتخابِ متن -pdfjs-cursor-text-select-tool-button-label = ابزارِ انتخابِ متن -pdfjs-cursor-hand-tool-button = - .title = فعال کردن ابزارِ دست -pdfjs-cursor-hand-tool-button-label = ابزار دست -pdfjs-scroll-vertical-button = - .title = استفاده از پیمایش عمودی -pdfjs-scroll-vertical-button-label = پیمایش عمودی -pdfjs-scroll-horizontal-button = - .title = استفاده از پیمایش افقی -pdfjs-scroll-horizontal-button-label = پیمایش افقی - -## Document properties dialog - -pdfjs-document-properties-button = - .title = خصوصیات سند... -pdfjs-document-properties-button-label = خصوصیات سند... -pdfjs-document-properties-file-name = نام فایل: -pdfjs-document-properties-file-size = حجم پرونده: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } کیلوبایت ({ $size_b } بایت) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } مگابایت ({ $size_b } بایت) -pdfjs-document-properties-title = عنوان: -pdfjs-document-properties-author = نویسنده: -pdfjs-document-properties-subject = موضوع: -pdfjs-document-properties-keywords = کلیدواژه‌ها: -pdfjs-document-properties-creation-date = تاریخ ایجاد: -pdfjs-document-properties-modification-date = تاریخ ویرایش: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }، { $time } -pdfjs-document-properties-creator = ایجاد کننده: -pdfjs-document-properties-producer = ایجاد کننده PDF: -pdfjs-document-properties-version = نسخه PDF: -pdfjs-document-properties-page-count = تعداد صفحات: -pdfjs-document-properties-page-size = اندازه صفحه: -pdfjs-document-properties-page-size-unit-inches = اینچ -pdfjs-document-properties-page-size-unit-millimeters = میلی‌متر -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = نامه -pdfjs-document-properties-page-size-name-legal = حقوقی - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-linearized-yes = بله -pdfjs-document-properties-linearized-no = خیر -pdfjs-document-properties-close-button = بستن - -## Print - -pdfjs-print-progress-message = آماده سازی مدارک برای چاپ کردن… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = لغو -pdfjs-printing-not-supported = هشدار: قابلیت چاپ به‌طور کامل در این مرورگر پشتیبانی نمی‌شود. -pdfjs-printing-not-ready = اخطار: پرونده PDF بطور کامل بارگیری نشده و امکان چاپ وجود ندارد. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = باز و بسته کردن نوار کناری -pdfjs-toggle-sidebar-button-label = تغییرحالت نوارکناری -pdfjs-document-outline-button = - .title = نمایش رئوس مطالب مدارک(برای بازشدن/جمع شدن همه موارد دوبار کلیک کنید) -pdfjs-document-outline-button-label = طرح نوشتار -pdfjs-attachments-button = - .title = نمایش پیوست‌ها -pdfjs-attachments-button-label = پیوست‌ها -pdfjs-layers-button-label = لایه‌ها -pdfjs-thumbs-button = - .title = نمایش تصاویر بندانگشتی -pdfjs-thumbs-button-label = تصاویر بندانگشتی -pdfjs-findbar-button = - .title = جستجو در سند -pdfjs-findbar-button-label = پیدا کردن - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = صفحه { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = تصویر بند‌ انگشتی صفحه { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = پیدا کردن - .placeholder = پیدا کردن در سند… -pdfjs-find-previous-button = - .title = پیدا کردن رخداد قبلی عبارت -pdfjs-find-previous-button-label = قبلی -pdfjs-find-next-button = - .title = پیدا کردن رخداد بعدی عبارت -pdfjs-find-next-button-label = بعدی -pdfjs-find-highlight-checkbox = برجسته و هایلایت کردن همه موارد -pdfjs-find-match-case-checkbox-label = تطبیق کوچکی و بزرگی حروف -pdfjs-find-entire-word-checkbox-label = تمام کلمه‌ها -pdfjs-find-reached-top = به بالای صفحه رسیدیم، از پایین ادامه می‌دهیم -pdfjs-find-reached-bottom = به آخر صفحه رسیدیم، از بالا ادامه می‌دهیم -pdfjs-find-not-found = عبارت پیدا نشد - -## Predefined zoom values - -pdfjs-page-scale-width = عرض صفحه -pdfjs-page-scale-fit = اندازه کردن صفحه -pdfjs-page-scale-auto = بزرگنمایی خودکار -pdfjs-page-scale-actual = اندازه واقعی‌ -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = صفحهٔ { $page } - -## Loading indicator messages - -pdfjs-loading-error = هنگام بارگیری پرونده PDF خطایی رخ داد. -pdfjs-invalid-file-error = پرونده PDF نامعتبر یامعیوب می‌باشد. -pdfjs-missing-file-error = پرونده PDF یافت نشد. -pdfjs-unexpected-response-error = پاسخ پیش بینی نشده سرور -pdfjs-rendering-error = هنگام بارگیری صفحه خطایی رخ داد. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = جهت باز کردن پرونده PDF گذرواژه را وارد نمائید. -pdfjs-password-invalid = گذرواژه نامعتبر. لطفا مجددا تلاش کنید. -pdfjs-password-ok-button = تأیید -pdfjs-password-cancel-button = لغو -pdfjs-web-fonts-disabled = فونت های تحت وب غیر فعال شده اند: امکان استفاده از نمایش دهنده داخلی PDF وجود ندارد. - -## Editing - -pdfjs-editor-free-text-button = - .title = متن -pdfjs-editor-free-text-button-label = متن -pdfjs-editor-ink-button = - .title = کشیدن -pdfjs-editor-ink-button-label = کشیدن -# Editor Parameters -pdfjs-editor-free-text-color-input = رنگ -pdfjs-editor-free-text-size-input = اندازه -pdfjs-editor-ink-color-input = رنگ - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/fa/viewer.properties b/static/pdf.js/locale/fa/viewer.properties new file mode 100644 index 00000000..28f2cb65 --- /dev/null +++ b/static/pdf.js/locale/fa/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=صفحهٔ قبلی +previous_label=قبلی +next.title=صفحهٔ بعدی +next_label=بعدی + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=صفحه: +page_of=از {{pageCount}} + +zoom_out.title=کوچک‌نمایی +zoom_out_label=کوچک‌نمایی +zoom_in.title=بزرگ‌نمایی +zoom_in_label=بزرگ‌نمایی +zoom.title=زوم +presentation_mode.title=تغییر به حالت ارائه +presentation_mode_label=حالت ارائه +open_file.title=باز کردن پرونده +open_file_label=باز کردن +print.title=چاپ +print_label=چاپ +download.title=بارگیری +download_label=بارگیری +bookmark.title=نمای فعلی (رونوشت و یا نشان دادن در پنجره جدید) +bookmark_label=نمای فعلی + +# Secondary toolbar and context menu +tools.title=ابزارها +tools_label=ابزارها +first_page.title=برو به اولین صفحه +first_page.label=برو یه اولین صفحه +first_page_label=برو به اولین صفحه +last_page.title=برو به آخرین صفحه +last_page.label=برو به آخرین صفحه +last_page_label=برو به آخرین صفحه +page_rotate_cw.title=چرخش ساعتگرد +page_rotate_cw.label=چرخش ساعتگرد +page_rotate_cw_label=چرخش ساعتگرد +page_rotate_ccw.title=چرخش پاد ساعتگرد +page_rotate_ccw.label=چرخش پاد ساعتگرد +page_rotate_ccw_label=چرخش پاد ساعتگرد + +hand_tool_enable.title=فعال سازی ابزار دست +hand_tool_enable_label=فعال سازی ابزار دست +hand_tool_disable.title=غیر‌فعال سازی ابزار دست +hand_tool_disable_label=غیر‌فعال سازی ابزار دست + +# Document properties dialog box +document_properties.title=خصوصیات سند... +document_properties_label=خصوصیات سند... +document_properties_file_name=نام فایل: +document_properties_file_size=حجم پرونده: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} کیلوبایت ({{size_b}} بایت) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} مگابایت ({{size_b}} بایت) +document_properties_title=عنوان: +document_properties_author=نویسنده: +document_properties_subject=موضوع: +document_properties_keywords=کلیدواژه‌ها: +document_properties_creation_date=تاریخ ایجاد: +document_properties_modification_date=تاریخ ویرایش: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}، {{time}} +document_properties_creator=ایجاد کننده: +document_properties_producer=ایجاد کننده PDF: +document_properties_version=نسخه PDF: +document_properties_page_count=تعداد صفحات: +document_properties_close=بستن + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=باز و بسته کردن نوار کناری +toggle_sidebar_label=تغییرحالت نوارکناری +outline.title=نمایش طرح نوشتار +outline_label=طرح نوشتار +attachments.title=نمایش پیوست‌ها +attachments_label=پیوست‌ها +thumbs.title=نمایش تصاویر بندانگشتی +thumbs_label=تصاویر بندانگشتی +findbar.title=جستجو در سند +findbar_label=پیدا کردن + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=صفحه {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=تصویر بند‌ انگشتی صفحه {{page}} + +# Find panel button title and messages +find_label=جستجو: +find_previous.title=پیدا کردن رخداد قبلی عبارت +find_previous_label=قبلی +find_next.title=پیدا کردن رخداد بعدی عبارت +find_next_label=بعدی +find_highlight=برجسته و هایلایت کردن همه موارد +find_match_case_label=تطبیق کوچکی و بزرگی حروف +find_reached_top=به بالای صفحه رسیدیم، از پایین ادامه می‌دهیم +find_reached_bottom=به آخر صفحه رسیدیم، از بالا ادامه می‌دهیم +find_not_found=عبارت پیدا نشد + +# Error panel labels +error_more_info=اطلاعات بیشتر +error_less_info=اطلاعات کمتر +error_close=بستن +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=‏PDF.js ورژن{{version}} ‏(ساخت: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=پیام: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=توده: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=پرونده: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=سطر: {{line}} +rendering_error=هنگام بارگیری صفحه خطایی رخ داد. + +# Predefined zoom values +page_scale_width=عرض صفحه +page_scale_fit=اندازه کردن صفحه +page_scale_auto=بزرگنمایی خودکار +page_scale_actual=اندازه واقعی‌ +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=خطا +loading_error=هنگام بارگیری پرونده PDF خطایی رخ داد. +invalid_file_error=پرونده PDF نامعتبر یامعیوب می‌باشد. +missing_file_error=پرونده PDF یافت نشد. +unexpected_response_error=پاسخ پیش بینی نشده سرور + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=جهت باز کردن پرونده PDF گذرواژه را وارد نمائید. +password_invalid=گذرواژه نامعتبر. لطفا مجددا تلاش کنید. +password_ok=تأیید +password_cancel=انصراف + +printing_not_supported=هشدار: قابلیت چاپ به‌طور کامل در این مرورگر پشتیبانی نمی‌شود. +printing_not_ready=اخطار: پرونده PDF بطور کامل بارگیری نشده و امکان چاپ وجود ندارد. +web_fonts_disabled=فونت های تحت وب غیر فعال شده اند: امکان استفاده از نمایش دهنده داخلی PDF وجود ندارد. +document_colors_not_allowed=فایلهای PDF نمیتوانند که رنگ های خود را داشته باشند. لذا گزینه 'اجازه تغییر رنگ" در مرورگر غیر فعال شده است. diff --git a/static/pdf.js/locale/ff/viewer.ftl b/static/pdf.js/locale/ff/viewer.ftl deleted file mode 100644 index d1419f54..00000000 --- a/static/pdf.js/locale/ff/viewer.ftl +++ /dev/null @@ -1,247 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Hello Ɓennungo -pdfjs-previous-button-label = Ɓennuɗo -pdfjs-next-button = - .title = Hello faango -pdfjs-next-button-label = Yeeso -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Hello -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = e nder { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } of { $pagesCount }) -pdfjs-zoom-out-button = - .title = Lonngo Woɗɗa -pdfjs-zoom-out-button-label = Lonngo Woɗɗa -pdfjs-zoom-in-button = - .title = Lonngo Ara -pdfjs-zoom-in-button-label = Lonngo Ara -pdfjs-zoom-select = - .title = Lonngo -pdfjs-presentation-mode-button = - .title = Faytu to Presentation Mode -pdfjs-presentation-mode-button-label = Presentation Mode -pdfjs-open-file-button = - .title = Uddit Fiilde -pdfjs-open-file-button-label = Uddit -pdfjs-print-button = - .title = Winndito -pdfjs-print-button-label = Winndito - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Kuutorɗe -pdfjs-tools-button-label = Kuutorɗe -pdfjs-first-page-button = - .title = Yah to hello adanngo -pdfjs-first-page-button-label = Yah to hello adanngo -pdfjs-last-page-button = - .title = Yah to hello wattindiingo -pdfjs-last-page-button-label = Yah to hello wattindiingo -pdfjs-page-rotate-cw-button = - .title = Yiiltu Faya Ñaamo -pdfjs-page-rotate-cw-button-label = Yiiltu Faya Ñaamo -pdfjs-page-rotate-ccw-button = - .title = Yiiltu Faya Nano -pdfjs-page-rotate-ccw-button-label = Yiiltu Faya Nano -pdfjs-cursor-text-select-tool-button = - .title = Gollin kaɓirgel cuɓirgel binndi -pdfjs-cursor-text-select-tool-button-label = Kaɓirgel cuɓirgel binndi -pdfjs-cursor-hand-tool-button = - .title = Hurmin kuutorgal junngo -pdfjs-cursor-hand-tool-button-label = Kaɓirgel junngo -pdfjs-scroll-vertical-button = - .title = Huutoro gorwitol daringol -pdfjs-scroll-vertical-button-label = Gorwitol daringol -pdfjs-scroll-horizontal-button = - .title = Huutoro gorwitol lelingol -pdfjs-scroll-horizontal-button-label = Gorwitol daringol -pdfjs-scroll-wrapped-button = - .title = Huutoro gorwitol coomingol -pdfjs-scroll-wrapped-button-label = Gorwitol coomingol -pdfjs-spread-none-button = - .title = Hoto tawtu kelle kelle -pdfjs-spread-none-button-label = Alaa Spreads -pdfjs-spread-odd-button = - .title = Tawtu kelle puɗɗortooɗe kelle teelɗe -pdfjs-spread-odd-button-label = Kelle teelɗe -pdfjs-spread-even-button = - .title = Tawtu ɗereeji kelle puɗɗoriiɗi kelle teeltuɗe -pdfjs-spread-even-button-label = Kelle teeltuɗe - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Keeroraaɗi Winndannde… -pdfjs-document-properties-button-label = Keeroraaɗi Winndannde… -pdfjs-document-properties-file-name = Innde fiilde: -pdfjs-document-properties-file-size = Ɓetol fiilde: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bite) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bite) -pdfjs-document-properties-title = Tiitoonde: -pdfjs-document-properties-author = Binnduɗo: -pdfjs-document-properties-subject = Toɓɓere: -pdfjs-document-properties-keywords = Kelmekele jiytirɗe: -pdfjs-document-properties-creation-date = Ñalnde Sosaa: -pdfjs-document-properties-modification-date = Ñalnde Waylaa: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Cosɗo: -pdfjs-document-properties-producer = Paggiiɗo PDF: -pdfjs-document-properties-version = Yamre PDF: -pdfjs-document-properties-page-count = Limoore Kelle: -pdfjs-document-properties-page-size = Ɓeto Hello: -pdfjs-document-properties-page-size-unit-inches = nder -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = dariingo -pdfjs-document-properties-page-size-orientation-landscape = wertiingo -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Ɓataake -pdfjs-document-properties-page-size-name-legal = Laawol - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Ɗisngo geese yaawngo: -pdfjs-document-properties-linearized-yes = Eey -pdfjs-document-properties-linearized-no = Alaa -pdfjs-document-properties-close-button = Uddu - -## Print - -pdfjs-print-progress-message = Nana heboo winnditaade fiilannde… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Haaytu -pdfjs-printing-not-supported = Reentino: Winnditagol tammbitaaka no feewi e ndee wanngorde. -pdfjs-printing-not-ready = Reentino: PDF oo loowaaki haa timmi ngam winnditagol. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Toggilo Palal Sawndo -pdfjs-toggle-sidebar-button-label = Toggilo Palal Sawndo -pdfjs-document-outline-button = - .title = Hollu Ƴiyal Fiilannde (dobdobo ngam wertude/taggude teme fof) -pdfjs-document-outline-button-label = Toɓɓe Fiilannde -pdfjs-attachments-button = - .title = Hollu Ɗisanɗe -pdfjs-attachments-button-label = Ɗisanɗe -pdfjs-thumbs-button = - .title = Hollu Dooɓe -pdfjs-thumbs-button-label = Dooɓe -pdfjs-findbar-button = - .title = Yiylo e fiilannde -pdfjs-findbar-button-label = Yiytu - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Hello { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Dooɓre Hello { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Yiytu - .placeholder = Yiylo nder dokimaa -pdfjs-find-previous-button = - .title = Yiylo cilol ɓennugol konngol ngol -pdfjs-find-previous-button-label = Ɓennuɗo -pdfjs-find-next-button = - .title = Yiylo cilol garowol konngol ngol -pdfjs-find-next-button-label = Yeeso -pdfjs-find-highlight-checkbox = Jalbin fof -pdfjs-find-match-case-checkbox-label = Jaaɓnu darnde -pdfjs-find-entire-word-checkbox-label = Kelme timmuɗe tan -pdfjs-find-reached-top = Heɓii fuɗɗorde fiilannde, jokku faya les -pdfjs-find-reached-bottom = Heɓii hoore fiilannde, jokku faya les -pdfjs-find-not-found = Konngi njiyataa - -## Predefined zoom values - -pdfjs-page-scale-width = Njaajeendi Hello -pdfjs-page-scale-fit = Keƴeendi Hello -pdfjs-page-scale-auto = Loongorde Jaajol -pdfjs-page-scale-actual = Ɓetol Jaati -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Juumre waɗii tuma nde loowata PDF oo. -pdfjs-invalid-file-error = Fiilde PDF moƴƴaani walla jiibii. -pdfjs-missing-file-error = Fiilde PDF ena ŋakki. -pdfjs-unexpected-response-error = Jaabtol sarworde tijjinooka. -pdfjs-rendering-error = Juumre waɗii tuma nde yoŋkittoo hello. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Siiftannde] - -## Password - -pdfjs-password-label = Naatu finnde ngam uddite ndee fiilde PDF. -pdfjs-password-invalid = Finnde moƴƴaani. Tiiɗno eto kadi. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Haaytu -pdfjs-web-fonts-disabled = Ponte geese ko daaƴaaɗe: horiima huutoraade ponte PDF coomtoraaɗe. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ff/viewer.properties b/static/pdf.js/locale/ff/viewer.properties new file mode 100644 index 00000000..026c4bf2 --- /dev/null +++ b/static/pdf.js/locale/ff/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Hello Ɓennungo +previous_label=Ɓennuɗo +next.title=Hello faango +next_label=Yeeso + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Hello: +page_of=e nder {{pageCount}} + +zoom_out.title=Lonngo Woɗɗa +zoom_out_label=Lonngo Woɗɗa +zoom_in.title=Lonngo Ara +zoom_in_label=Lonngo Ara +zoom.title=Lonngo +presentation_mode.title=Faytu to Presentation Mode +presentation_mode_label=Presentation Mode +open_file.title=Uddit Fiilde +open_file_label=Uddit +print.title=Winndito +print_label=Winndito +download.title=Aawto +download_label=Aawto +bookmark.title=Jiytol gonangol (natto walla uddit e henorde) +bookmark_label=Jiytol Gonangol + +# Secondary toolbar and context menu +tools.title=Kuutorɗe +tools_label=Kuutorɗe +first_page.title=Yah to hello adanngo +first_page.label=Yah to hello adanngo +first_page_label=Yah to hello adanngo +last_page.title=Yah to hello wattindiingo +last_page.label=Yah to hello wattindiingo +last_page_label=Yah to hello wattindiingo +page_rotate_cw.title=Yiiltu Faya Ñaamo +page_rotate_cw.label=Yiiltu Faya Ñaamo +page_rotate_cw_label=Yiiltu Faya Ñaamo +page_rotate_ccw.title=Yiiltu Faya Nano +page_rotate_ccw.label=Yiiltu Faya Nano +page_rotate_ccw_label=Yiiltu Faya Nano + +hand_tool_enable.title=Hurmin kuutorgal junngo +hand_tool_enable_label=Hurmin kuutorgal junngo +hand_tool_disable.title=Daaƴ kuutorgal junngo +hand_tool_disable_label=Daaƴ kuutorgal junngo + +# Document properties dialog box +document_properties.title=Keeroraaɗi Winndannde… +document_properties_label=Keeroraaɗi Winndannde… +document_properties_file_name=Innde fiilde: +document_properties_file_size=Ɓetol fiilde: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bite) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bite) +document_properties_title=Tiitoonde: +document_properties_author=Binnduɗo: +document_properties_subject=Toɓɓere: +document_properties_keywords=Kelmekele jiytirɗe: +document_properties_creation_date=Ñalnde Sosaa: +document_properties_modification_date=Ñalnde Waylaa: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Cosɗo: +document_properties_producer=Paggiiɗo PDF: +document_properties_version=Yamre PDF: +document_properties_page_count=Limoore Kelle: +document_properties_close=Uddu + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Toggilo Palal Sawndo +toggle_sidebar_label=Toggilo Palal Sawndo +outline.title=Hollu Toɓɓe Fiilannde +outline_label=Toɓɓe Fiilannde +attachments.title=Hollu Ɗisanɗe +attachments_label=Ɗisanɗe +thumbs.title=Hollu Dooɓe +thumbs_label=Dooɓe +findbar.title=Yiylo e fiilannde +findbar_label=Yiytu + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Hello {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Dooɓre Hello {{page}} + +# Find panel button title and messages +find_label=Yiytu: +find_previous.title=Yiylo cilol ɓennugol konngol ngol +find_previous_label=Ɓennuɗo +find_next.title=Yiylo cilol garowol konngol ngol +find_next_label=Yeeso +find_highlight=Jalbin fof +find_match_case_label=Jaaɓnu darnde +find_reached_top=Heɓii fuɗɗorde fiilannde, jokku faya les +find_reached_bottom=Heɓii hoore fiilannde, jokku faya les +find_not_found=Konngi njiyataa + +# Error panel labels +error_more_info=Ɓeydu Humpito +error_less_info=Ustu Humpito +error_close=Uddu +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Ɓatakuure: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fiilde: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Gorol: {{line}} +rendering_error=Juumre waɗii tuma nde yoŋkittoo hello. + +# Predefined zoom values +page_scale_width=Njaajeendi Hello +page_scale_fit=Keƴeendi Hello +page_scale_auto=Loongorde Jaajol +page_scale_actual=Ɓetol Jaati +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Juumre +loading_error=Juumre waɗii tuma nde loowata PDF oo. +invalid_file_error=Fiilde PDF moƴƴaani walla jiibii. +missing_file_error=Fiilde PDF ena ŋakki. +unexpected_response_error=Jaabtol sarworde tijjinooka. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Siiftannde] +password_label=Naatu finnde ngam uddite ndee fiilde PDF. +password_invalid=Finnde moƴƴaani. Tiiɗno eto kadi. +password_ok=OK +password_cancel=Haaytu + +printing_not_supported=Reentino: Winnditagol tammbitaaka no feewi e ndee wanngorde. +printing_not_ready=Reentino: PDF oo loowaaki haa timmi ngam winnditagol. +web_fonts_disabled=Ponte geese ko daaƴaaɗe: horiima huutoraade ponte PDF coomtoraaɗe. +document_colors_not_allowed=Piilanɗe PDF njamiraaka yoo kuutoro goobuuji mum'en keeriiɗi: 'Yamir kello yoo kuutoro goobuuki keeriiɗi' koko daaƴaa e wanngorde ndee. diff --git a/static/pdf.js/locale/fi/viewer.ftl b/static/pdf.js/locale/fi/viewer.ftl deleted file mode 100644 index 51667837..00000000 --- a/static/pdf.js/locale/fi/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Edellinen sivu -pdfjs-previous-button-label = Edellinen -pdfjs-next-button = - .title = Seuraava sivu -pdfjs-next-button-label = Seuraava -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Sivu -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = / { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } / { $pagesCount }) -pdfjs-zoom-out-button = - .title = Loitonna -pdfjs-zoom-out-button-label = Loitonna -pdfjs-zoom-in-button = - .title = Lähennä -pdfjs-zoom-in-button-label = Lähennä -pdfjs-zoom-select = - .title = Suurennus -pdfjs-presentation-mode-button = - .title = Siirry esitystilaan -pdfjs-presentation-mode-button-label = Esitystila -pdfjs-open-file-button = - .title = Avaa tiedosto -pdfjs-open-file-button-label = Avaa -pdfjs-print-button = - .title = Tulosta -pdfjs-print-button-label = Tulosta -pdfjs-save-button = - .title = Tallenna -pdfjs-save-button-label = Tallenna -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Lataa -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Lataa -pdfjs-bookmark-button = - .title = Nykyinen sivu (Näytä URL-osoite nykyiseltä sivulta) -pdfjs-bookmark-button-label = Nykyinen sivu -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Avaa sovelluksessa -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Avaa sovelluksessa - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tools -pdfjs-tools-button-label = Tools -pdfjs-first-page-button = - .title = Siirry ensimmäiselle sivulle -pdfjs-first-page-button-label = Siirry ensimmäiselle sivulle -pdfjs-last-page-button = - .title = Siirry viimeiselle sivulle -pdfjs-last-page-button-label = Siirry viimeiselle sivulle -pdfjs-page-rotate-cw-button = - .title = Kierrä oikealle -pdfjs-page-rotate-cw-button-label = Kierrä oikealle -pdfjs-page-rotate-ccw-button = - .title = Kierrä vasemmalle -pdfjs-page-rotate-ccw-button-label = Kierrä vasemmalle -pdfjs-cursor-text-select-tool-button = - .title = Käytä tekstinvalintatyökalua -pdfjs-cursor-text-select-tool-button-label = Tekstinvalintatyökalu -pdfjs-cursor-hand-tool-button = - .title = Käytä käsityökalua -pdfjs-cursor-hand-tool-button-label = Käsityökalu -pdfjs-scroll-page-button = - .title = Käytä sivun vieritystä -pdfjs-scroll-page-button-label = Sivun vieritys -pdfjs-scroll-vertical-button = - .title = Käytä pystysuuntaista vieritystä -pdfjs-scroll-vertical-button-label = Pystysuuntainen vieritys -pdfjs-scroll-horizontal-button = - .title = Käytä vaakasuuntaista vieritystä -pdfjs-scroll-horizontal-button-label = Vaakasuuntainen vieritys -pdfjs-scroll-wrapped-button = - .title = Käytä rivittyvää vieritystä -pdfjs-scroll-wrapped-button-label = Rivittyvä vieritys -pdfjs-spread-none-button = - .title = Älä yhdistä sivuja aukeamiksi -pdfjs-spread-none-button-label = Ei aukeamia -pdfjs-spread-odd-button = - .title = Yhdistä sivut aukeamiksi alkaen parittomalta sivulta -pdfjs-spread-odd-button-label = Parittomalta alkavat aukeamat -pdfjs-spread-even-button = - .title = Yhdistä sivut aukeamiksi alkaen parilliselta sivulta -pdfjs-spread-even-button-label = Parilliselta alkavat aukeamat - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumentin ominaisuudet… -pdfjs-document-properties-button-label = Dokumentin ominaisuudet… -pdfjs-document-properties-file-name = Tiedoston nimi: -pdfjs-document-properties-file-size = Tiedoston koko: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kt ({ $size_b } tavua) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } Mt ({ $size_b } tavua) -pdfjs-document-properties-title = Otsikko: -pdfjs-document-properties-author = Tekijä: -pdfjs-document-properties-subject = Aihe: -pdfjs-document-properties-keywords = Avainsanat: -pdfjs-document-properties-creation-date = Luomispäivämäärä: -pdfjs-document-properties-modification-date = Muokkauspäivämäärä: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Luoja: -pdfjs-document-properties-producer = PDF-tuottaja: -pdfjs-document-properties-version = PDF-versio: -pdfjs-document-properties-page-count = Sivujen määrä: -pdfjs-document-properties-page-size = Sivun koko: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = pysty -pdfjs-document-properties-page-size-orientation-landscape = vaaka -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Nopea web-katselu: -pdfjs-document-properties-linearized-yes = Kyllä -pdfjs-document-properties-linearized-no = Ei -pdfjs-document-properties-close-button = Sulje - -## Print - -pdfjs-print-progress-message = Valmistellaan dokumenttia tulostamista varten… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress } % -pdfjs-print-progress-close-button = Peruuta -pdfjs-printing-not-supported = Varoitus: Selain ei tue kaikkia tulostustapoja. -pdfjs-printing-not-ready = Varoitus: PDF-tiedosto ei ole vielä latautunut kokonaan, eikä sitä voi vielä tulostaa. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Näytä/piilota sivupaneeli -pdfjs-toggle-sidebar-notification-button = - .title = Näytä/piilota sivupaneeli (dokumentissa on sisällys/liitteitä/tasoja) -pdfjs-toggle-sidebar-button-label = Näytä/piilota sivupaneeli -pdfjs-document-outline-button = - .title = Näytä dokumentin sisällys (laajenna tai kutista kohdat kaksoisnapsauttamalla) -pdfjs-document-outline-button-label = Dokumentin sisällys -pdfjs-attachments-button = - .title = Näytä liitteet -pdfjs-attachments-button-label = Liitteet -pdfjs-layers-button = - .title = Näytä tasot (kaksoisnapsauta palauttaaksesi kaikki tasot oletustilaan) -pdfjs-layers-button-label = Tasot -pdfjs-thumbs-button = - .title = Näytä pienoiskuvat -pdfjs-thumbs-button-label = Pienoiskuvat -pdfjs-current-outline-item-button = - .title = Etsi nykyinen sisällyksen kohta -pdfjs-current-outline-item-button-label = Nykyinen sisällyksen kohta -pdfjs-findbar-button = - .title = Etsi dokumentista -pdfjs-findbar-button-label = Etsi -pdfjs-additional-layers = Lisätasot - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Sivu { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Pienoiskuva sivusta { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Etsi - .placeholder = Etsi dokumentista… -pdfjs-find-previous-button = - .title = Etsi hakusanan edellinen osuma -pdfjs-find-previous-button-label = Edellinen -pdfjs-find-next-button = - .title = Etsi hakusanan seuraava osuma -pdfjs-find-next-button-label = Seuraava -pdfjs-find-highlight-checkbox = Korosta kaikki -pdfjs-find-match-case-checkbox-label = Huomioi kirjainkoko -pdfjs-find-match-diacritics-checkbox-label = Erota tarkkeet -pdfjs-find-entire-word-checkbox-label = Kokonaiset sanat -pdfjs-find-reached-top = Päästiin dokumentin alkuun, jatketaan lopusta -pdfjs-find-reached-bottom = Päästiin dokumentin loppuun, jatketaan alusta -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } / { $total } osuma - *[other] { $current } / { $total } osumaa - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Yli { $limit } osuma - *[other] Yli { $limit } osumaa - } -pdfjs-find-not-found = Hakusanaa ei löytynyt - -## Predefined zoom values - -pdfjs-page-scale-width = Sivun leveys -pdfjs-page-scale-fit = Koko sivu -pdfjs-page-scale-auto = Automaattinen suurennus -pdfjs-page-scale-actual = Todellinen koko -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale } % - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Sivu { $page } - -## Loading indicator messages - -pdfjs-loading-error = Tapahtui virhe ladattaessa PDF-tiedostoa. -pdfjs-invalid-file-error = Virheellinen tai vioittunut PDF-tiedosto. -pdfjs-missing-file-error = Puuttuva PDF-tiedosto. -pdfjs-unexpected-response-error = Odottamaton vastaus palvelimelta. -pdfjs-rendering-error = Tapahtui virhe piirrettäessä sivua. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type }-merkintä] - -## Password - -pdfjs-password-label = Kirjoita PDF-tiedoston salasana. -pdfjs-password-invalid = Virheellinen salasana. Yritä uudestaan. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Peruuta -pdfjs-web-fonts-disabled = Verkkosivujen omat kirjasinlajit on estetty: ei voida käyttää upotettuja PDF-kirjasinlajeja. - -## Editing - -pdfjs-editor-free-text-button = - .title = Teksti -pdfjs-editor-free-text-button-label = Teksti -pdfjs-editor-ink-button = - .title = Piirros -pdfjs-editor-ink-button-label = Piirros -pdfjs-editor-stamp-button = - .title = Lisää tai muokkaa kuvia -pdfjs-editor-stamp-button-label = Lisää tai muokkaa kuvia -pdfjs-editor-highlight-button = - .title = Korostus -pdfjs-editor-highlight-button-label = Korostus -pdfjs-highlight-floating-button = - .title = Korostus -pdfjs-highlight-floating-button1 = - .title = Korostus - .aria-label = Korostus -pdfjs-highlight-floating-button-label = Korostus - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Poista piirros -pdfjs-editor-remove-freetext-button = - .title = Poista teksti -pdfjs-editor-remove-stamp-button = - .title = Poista kuva -pdfjs-editor-remove-highlight-button = - .title = Poista korostus - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Väri -pdfjs-editor-free-text-size-input = Koko -pdfjs-editor-ink-color-input = Väri -pdfjs-editor-ink-thickness-input = Paksuus -pdfjs-editor-ink-opacity-input = Peittävyys -pdfjs-editor-stamp-add-image-button = - .title = Lisää kuva -pdfjs-editor-stamp-add-image-button-label = Lisää kuva -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Paksuus -pdfjs-editor-free-highlight-thickness-title = - .title = Muuta paksuutta korostaessasi muita kohteita kuin tekstiä -pdfjs-free-text = - .aria-label = Tekstimuokkain -pdfjs-free-text-default-content = Aloita kirjoittaminen… -pdfjs-ink = - .aria-label = Piirrustusmuokkain -pdfjs-ink-canvas = - .aria-label = Käyttäjän luoma kuva - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Vaihtoehtoinen teksti -pdfjs-editor-alt-text-edit-button-label = Muokkaa vaihtoehtoista tekstiä -pdfjs-editor-alt-text-dialog-label = Valitse vaihtoehto -pdfjs-editor-alt-text-dialog-description = Vaihtoehtoinen teksti ("alt-teksti") auttaa ihmisiä, jotka eivät näe kuvaa tai kun kuva ei lataudu. -pdfjs-editor-alt-text-add-description-label = Lisää kuvaus -pdfjs-editor-alt-text-add-description-description = Pyri 1-2 lauseeseen, jotka kuvaavat aihetta, ympäristöä tai toimintaa. -pdfjs-editor-alt-text-mark-decorative-label = Merkitse koristeelliseksi -pdfjs-editor-alt-text-mark-decorative-description = Tätä käytetään koristekuville, kuten reunuksille tai vesileimoille. -pdfjs-editor-alt-text-cancel-button = Peruuta -pdfjs-editor-alt-text-save-button = Tallenna -pdfjs-editor-alt-text-decorative-tooltip = Merkitty koristeelliseksi -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Esimerkiksi "Nuori mies istuu pöytään syömään aterian" - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Vasen yläkulma - muuta kokoa -pdfjs-editor-resizer-label-top-middle = Ylhäällä keskellä - muuta kokoa -pdfjs-editor-resizer-label-top-right = Oikea yläkulma - muuta kokoa -pdfjs-editor-resizer-label-middle-right = Keskellä oikealla - muuta kokoa -pdfjs-editor-resizer-label-bottom-right = Oikea alakulma - muuta kokoa -pdfjs-editor-resizer-label-bottom-middle = Alhaalla keskellä - muuta kokoa -pdfjs-editor-resizer-label-bottom-left = Vasen alakulma - muuta kokoa -pdfjs-editor-resizer-label-middle-left = Keskellä vasemmalla - muuta kokoa - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Korostusväri -pdfjs-editor-colorpicker-button = - .title = Vaihda väri -pdfjs-editor-colorpicker-dropdown = - .aria-label = Värivalinnat -pdfjs-editor-colorpicker-yellow = - .title = Keltainen -pdfjs-editor-colorpicker-green = - .title = Vihreä -pdfjs-editor-colorpicker-blue = - .title = Sininen -pdfjs-editor-colorpicker-pink = - .title = Pinkki -pdfjs-editor-colorpicker-red = - .title = Punainen - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Näytä kaikki -pdfjs-editor-highlight-show-all-button = - .title = Näytä kaikki diff --git a/static/pdf.js/locale/fi/viewer.properties b/static/pdf.js/locale/fi/viewer.properties new file mode 100644 index 00000000..be543b6a --- /dev/null +++ b/static/pdf.js/locale/fi/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Edellinen sivu +previous_label=Edellinen +next.title=Seuraava sivu +next_label=Seuraava + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Sivu: +page_of=/ {{pageCount}} + +zoom_out.title=Loitonna +zoom_out_label=Loitonna +zoom_in.title=Lähennä +zoom_in_label=Lähennä +zoom.title=Suurennus +presentation_mode.title=Siirry esitystilaan +presentation_mode_label=Esitystila +open_file.title=Avaa tiedosto +open_file_label=Avaa +print.title=Tulosta +print_label=Tulosta +download.title=Lataa +download_label=Lataa +bookmark.title=Avoin ikkuna (kopioi tai avaa uuteen ikkunaan) +bookmark_label=Avoin ikkuna + +# Secondary toolbar and context menu +tools.title=Tools +tools_label=Tools +first_page.title=Siirry ensimmäiselle sivulle +first_page.label=Siirry ensimmäiselle sivulle +first_page_label=Siirry ensimmäiselle sivulle +last_page.title=Siirry viimeiselle sivulle +last_page.label=Siirry viimeiselle sivulle +last_page_label=Siirry viimeiselle sivulle +page_rotate_cw.title=Kierrä oikealle +page_rotate_cw.label=Kierrä oikealle +page_rotate_cw_label=Kierrä oikealle +page_rotate_ccw.title=Kierrä vasemmalle +page_rotate_ccw.label=Kierrä vasemmalle +page_rotate_ccw_label=Kierrä vasemmalle + +hand_tool_enable.title=Käytä käsityökalua +hand_tool_enable_label=Käytä käsityökalua +hand_tool_disable.title=Poista käsityökalu käytöstä +hand_tool_disable_label=Poista käsityökalu käytöstä + +# Document properties dialog box +document_properties.title=Dokumentin ominaisuudet… +document_properties_label=Dokumentin ominaisuudet… +document_properties_file_name=Tiedostonimi: +document_properties_file_size=Tiedoston koko: +document_properties_kb={{size_kb}} kt ({{size_b}} tavua) +document_properties_mb={{size_mb}} Mt ({{size_b}} tavua) +document_properties_title=Otsikko: +document_properties_author=Tekijä: +document_properties_subject=Aihe: +document_properties_keywords=Avainsanat: +document_properties_creation_date=Luomispäivämäärä: +document_properties_modification_date=Muokkauspäivämäärä: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Luoja: +document_properties_producer=PDF-tuottaja: +document_properties_version=PDF-versio: +document_properties_page_count=Sivujen määrä: +document_properties_close=Sulje + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Näytä/piilota sivupaneeli +toggle_sidebar_label=Näytä/piilota sivupaneeli +outline.title=Näytä dokumentin rakenne +outline_label=Dokumentin rakenne +attachments.title=Näytä liitteet +attachments_label=Liitteet +thumbs.title=Näytä pienoiskuvat +thumbs_label=Pienoiskuvat +findbar.title=Etsi dokumentista +findbar_label=Etsi + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Sivu {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Pienoiskuva sivusta {{page}} + +# Find panel button title and messages +find_label=Etsi: +find_previous.title=Etsi hakusanan edellinen osuma +find_previous_label=Edellinen +find_next.title=Etsi hakusanan seuraava osuma +find_next_label=Seuraava +find_highlight=Korosta kaikki +find_match_case_label=Huomioi kirjainkoko +find_reached_top=Päästiin dokumentin alkuun, jatketaan lopusta +find_reached_bottom=Päästiin dokumentin loppuun, continued from top +find_not_found=Hakusanaa ei löytynyt + +# Error panel labels +error_more_info=Lisätietoja +error_less_info=Lisätietoja +error_close=Sulje +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (kooste: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Virheilmoitus: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pino: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Tiedosto: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rivi: {{line}} +rendering_error=Tapahtui virhe piirrettäessä sivua. + +# Predefined zoom values +page_scale_width=Sivun leveys +page_scale_fit=Koko sivu +page_scale_auto=Automaattinen suurennus +page_scale_actual=Todellinen koko +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}} % + +# Loading indicator messages +loading_error_indicator=Virhe +loading_error=Tapahtui virhe ladattaessa PDF-tiedostoa. +invalid_file_error=Virheellinen tai vioittunut PDF-tiedosto. +missing_file_error=Puuttuva PDF-tiedosto. +unexpected_response_error=Odottamaton vastaus palvelimelta. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=Kirjoita PDF-tiedoston salasana. +password_invalid=Virheellinen salasana. Yritä uudestaan. +password_ok=OK +password_cancel=Peruuta + +printing_not_supported=Varoitus: Selain ei tue kaikkia tulostustapoja. +printing_not_ready=Varoitus: PDF-tiedosto ei ole vielä latautunut kokonaan, eikä sitä voi vielä tulostaa. +web_fonts_disabled=Verkkosivujen omat kirjasinlajit on estetty: ei voida käyttää upotettuja PDF-kirjasinlajeja. +document_colors_not_allowed=PDF-dokumenttien ei ole sallittua käyttää omia värejään: Asetusta "Sivut saavat käyttää omia värejään oletusten sijaan" ei ole valittu selaimen asetuksissa. diff --git a/static/pdf.js/locale/fr/viewer.ftl b/static/pdf.js/locale/fr/viewer.ftl deleted file mode 100644 index 54c06c22..00000000 --- a/static/pdf.js/locale/fr/viewer.ftl +++ /dev/null @@ -1,398 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Page précédente -pdfjs-previous-button-label = Précédent -pdfjs-next-button = - .title = Page suivante -pdfjs-next-button-label = Suivant -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Page -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = sur { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } sur { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom arrière -pdfjs-zoom-out-button-label = Zoom arrière -pdfjs-zoom-in-button = - .title = Zoom avant -pdfjs-zoom-in-button-label = Zoom avant -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Basculer en mode présentation -pdfjs-presentation-mode-button-label = Mode présentation -pdfjs-open-file-button = - .title = Ouvrir le fichier -pdfjs-open-file-button-label = Ouvrir le fichier -pdfjs-print-button = - .title = Imprimer -pdfjs-print-button-label = Imprimer -pdfjs-save-button = - .title = Enregistrer -pdfjs-save-button-label = Enregistrer -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Télécharger -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Télécharger -pdfjs-bookmark-button = - .title = Page courante (montrer l’adresse de la page courante) -pdfjs-bookmark-button-label = Page courante -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Ouvrir dans une application -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Ouvrir dans une application - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Outils -pdfjs-tools-button-label = Outils -pdfjs-first-page-button = - .title = Aller à la première page -pdfjs-first-page-button-label = Aller à la première page -pdfjs-last-page-button = - .title = Aller à la dernière page -pdfjs-last-page-button-label = Aller à la dernière page -pdfjs-page-rotate-cw-button = - .title = Rotation horaire -pdfjs-page-rotate-cw-button-label = Rotation horaire -pdfjs-page-rotate-ccw-button = - .title = Rotation antihoraire -pdfjs-page-rotate-ccw-button-label = Rotation antihoraire -pdfjs-cursor-text-select-tool-button = - .title = Activer l’outil de sélection de texte -pdfjs-cursor-text-select-tool-button-label = Outil de sélection de texte -pdfjs-cursor-hand-tool-button = - .title = Activer l’outil main -pdfjs-cursor-hand-tool-button-label = Outil main -pdfjs-scroll-page-button = - .title = Utiliser le défilement par page -pdfjs-scroll-page-button-label = Défilement par page -pdfjs-scroll-vertical-button = - .title = Utiliser le défilement vertical -pdfjs-scroll-vertical-button-label = Défilement vertical -pdfjs-scroll-horizontal-button = - .title = Utiliser le défilement horizontal -pdfjs-scroll-horizontal-button-label = Défilement horizontal -pdfjs-scroll-wrapped-button = - .title = Utiliser le défilement par bloc -pdfjs-scroll-wrapped-button-label = Défilement par bloc -pdfjs-spread-none-button = - .title = Ne pas afficher les pages deux à deux -pdfjs-spread-none-button-label = Pas de double affichage -pdfjs-spread-odd-button = - .title = Afficher les pages par deux, impaires à gauche -pdfjs-spread-odd-button-label = Doubles pages, impaires à gauche -pdfjs-spread-even-button = - .title = Afficher les pages par deux, paires à gauche -pdfjs-spread-even-button-label = Doubles pages, paires à gauche - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propriétés du document… -pdfjs-document-properties-button-label = Propriétés du document… -pdfjs-document-properties-file-name = Nom du fichier : -pdfjs-document-properties-file-size = Taille du fichier : -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } Ko ({ $size_b } octets) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } Mo ({ $size_b } octets) -pdfjs-document-properties-title = Titre : -pdfjs-document-properties-author = Auteur : -pdfjs-document-properties-subject = Sujet : -pdfjs-document-properties-keywords = Mots-clés : -pdfjs-document-properties-creation-date = Date de création : -pdfjs-document-properties-modification-date = Modifié le : -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date } à { $time } -pdfjs-document-properties-creator = Créé par : -pdfjs-document-properties-producer = Outil de conversion PDF : -pdfjs-document-properties-version = Version PDF : -pdfjs-document-properties-page-count = Nombre de pages : -pdfjs-document-properties-page-size = Taille de la page : -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portrait -pdfjs-document-properties-page-size-orientation-landscape = paysage -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = lettre -pdfjs-document-properties-page-size-name-legal = document juridique - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Affichage rapide des pages web : -pdfjs-document-properties-linearized-yes = Oui -pdfjs-document-properties-linearized-no = Non -pdfjs-document-properties-close-button = Fermer - -## Print - -pdfjs-print-progress-message = Préparation du document pour l’impression… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress } % -pdfjs-print-progress-close-button = Annuler -pdfjs-printing-not-supported = Attention : l’impression n’est pas totalement prise en charge par ce navigateur. -pdfjs-printing-not-ready = Attention : le PDF n’est pas entièrement chargé pour pouvoir l’imprimer. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Afficher/Masquer le panneau latéral -pdfjs-toggle-sidebar-notification-button = - .title = Afficher/Masquer le panneau latéral (le document contient des signets/pièces jointes/calques) -pdfjs-toggle-sidebar-button-label = Afficher/Masquer le panneau latéral -pdfjs-document-outline-button = - .title = Afficher les signets du document (double-cliquer pour développer/réduire tous les éléments) -pdfjs-document-outline-button-label = Signets du document -pdfjs-attachments-button = - .title = Afficher les pièces jointes -pdfjs-attachments-button-label = Pièces jointes -pdfjs-layers-button = - .title = Afficher les calques (double-cliquer pour réinitialiser tous les calques à l’état par défaut) -pdfjs-layers-button-label = Calques -pdfjs-thumbs-button = - .title = Afficher les vignettes -pdfjs-thumbs-button-label = Vignettes -pdfjs-current-outline-item-button = - .title = Trouver l’élément de plan actuel -pdfjs-current-outline-item-button-label = Élément de plan actuel -pdfjs-findbar-button = - .title = Rechercher dans le document -pdfjs-findbar-button-label = Rechercher -pdfjs-additional-layers = Calques additionnels - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Page { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Vignette de la page { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Rechercher - .placeholder = Rechercher dans le document… -pdfjs-find-previous-button = - .title = Trouver l’occurrence précédente de l’expression -pdfjs-find-previous-button-label = Précédent -pdfjs-find-next-button = - .title = Trouver la prochaine occurrence de l’expression -pdfjs-find-next-button-label = Suivant -pdfjs-find-highlight-checkbox = Tout surligner -pdfjs-find-match-case-checkbox-label = Respecter la casse -pdfjs-find-match-diacritics-checkbox-label = Respecter les accents et diacritiques -pdfjs-find-entire-word-checkbox-label = Mots entiers -pdfjs-find-reached-top = Haut de la page atteint, poursuite depuis la fin -pdfjs-find-reached-bottom = Bas de la page atteint, poursuite au début -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = Occurrence { $current } sur { $total } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Plus d’{ $limit } occurrence - *[other] Plus de { $limit } occurrences - } -pdfjs-find-not-found = Expression non trouvée - -## Predefined zoom values - -pdfjs-page-scale-width = Pleine largeur -pdfjs-page-scale-fit = Page entière -pdfjs-page-scale-auto = Zoom automatique -pdfjs-page-scale-actual = Taille réelle -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale } % - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Page { $page } - -## Loading indicator messages - -pdfjs-loading-error = Une erreur s’est produite lors du chargement du fichier PDF. -pdfjs-invalid-file-error = Fichier PDF invalide ou corrompu. -pdfjs-missing-file-error = Fichier PDF manquant. -pdfjs-unexpected-response-error = Réponse inattendue du serveur. -pdfjs-rendering-error = Une erreur s’est produite lors de l’affichage de la page. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date } à { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Annotation { $type }] - -## Password - -pdfjs-password-label = Veuillez saisir le mot de passe pour ouvrir ce fichier PDF. -pdfjs-password-invalid = Mot de passe incorrect. Veuillez réessayer. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Annuler -pdfjs-web-fonts-disabled = Les polices web sont désactivées : impossible d’utiliser les polices intégrées au PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texte -pdfjs-editor-free-text-button-label = Texte -pdfjs-editor-ink-button = - .title = Dessiner -pdfjs-editor-ink-button-label = Dessiner -pdfjs-editor-stamp-button = - .title = Ajouter ou modifier des images -pdfjs-editor-stamp-button-label = Ajouter ou modifier des images -pdfjs-editor-highlight-button = - .title = Surligner -pdfjs-editor-highlight-button-label = Surligner -pdfjs-highlight-floating-button = - .title = Surligner -pdfjs-highlight-floating-button1 = - .title = Surligner - .aria-label = Surligner -pdfjs-highlight-floating-button-label = Surligner - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Supprimer le dessin -pdfjs-editor-remove-freetext-button = - .title = Supprimer le texte -pdfjs-editor-remove-stamp-button = - .title = Supprimer l’image -pdfjs-editor-remove-highlight-button = - .title = Supprimer le surlignage - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Couleur -pdfjs-editor-free-text-size-input = Taille -pdfjs-editor-ink-color-input = Couleur -pdfjs-editor-ink-thickness-input = Épaisseur -pdfjs-editor-ink-opacity-input = Opacité -pdfjs-editor-stamp-add-image-button = - .title = Ajouter une image -pdfjs-editor-stamp-add-image-button-label = Ajouter une image -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Épaisseur -pdfjs-editor-free-highlight-thickness-title = - .title = Modifier l’épaisseur pour le surlignage d’éléments non textuels -pdfjs-free-text = - .aria-label = Éditeur de texte -pdfjs-free-text-default-content = Commencer à écrire… -pdfjs-ink = - .aria-label = Éditeur de dessin -pdfjs-ink-canvas = - .aria-label = Image créée par l’utilisateur·trice - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Texte alternatif -pdfjs-editor-alt-text-edit-button-label = Modifier le texte alternatif -pdfjs-editor-alt-text-dialog-label = Sélectionnez une option -pdfjs-editor-alt-text-dialog-description = Le texte alternatif est utile lorsque des personnes ne peuvent pas voir l’image ou que l’image ne se charge pas. -pdfjs-editor-alt-text-add-description-label = Ajouter une description -pdfjs-editor-alt-text-add-description-description = Il est conseillé de rédiger une ou deux phrases décrivant le sujet, le cadre ou les actions. -pdfjs-editor-alt-text-mark-decorative-label = Marquer comme décorative -pdfjs-editor-alt-text-mark-decorative-description = Cette option est utilisée pour les images décoratives, comme les bordures ou les filigranes. -pdfjs-editor-alt-text-cancel-button = Annuler -pdfjs-editor-alt-text-save-button = Enregistrer -pdfjs-editor-alt-text-decorative-tooltip = Marquée comme décorative -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Par exemple, « Un jeune homme est assis à une table pour prendre un repas » - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Coin supérieur gauche — redimensionner -pdfjs-editor-resizer-label-top-middle = Milieu haut — redimensionner -pdfjs-editor-resizer-label-top-right = Coin supérieur droit — redimensionner -pdfjs-editor-resizer-label-middle-right = Milieu droit — redimensionner -pdfjs-editor-resizer-label-bottom-right = Coin inférieur droit — redimensionner -pdfjs-editor-resizer-label-bottom-middle = Centre bas — redimensionner -pdfjs-editor-resizer-label-bottom-left = Coin inférieur gauche — redimensionner -pdfjs-editor-resizer-label-middle-left = Milieu gauche — redimensionner - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Couleur de surlignage -pdfjs-editor-colorpicker-button = - .title = Changer de couleur -pdfjs-editor-colorpicker-dropdown = - .aria-label = Choix de couleurs -pdfjs-editor-colorpicker-yellow = - .title = Jaune -pdfjs-editor-colorpicker-green = - .title = Vert -pdfjs-editor-colorpicker-blue = - .title = Bleu -pdfjs-editor-colorpicker-pink = - .title = Rose -pdfjs-editor-colorpicker-red = - .title = Rouge - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Tout afficher -pdfjs-editor-highlight-show-all-button = - .title = Tout afficher diff --git a/static/pdf.js/locale/fr/viewer.properties b/static/pdf.js/locale/fr/viewer.properties new file mode 100644 index 00000000..4c1ee28b --- /dev/null +++ b/static/pdf.js/locale/fr/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Page précédente +previous_label=Précédent +next.title=Page suivante +next_label=Suivant + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Page : +page_of=sur {{pageCount}} + +zoom_out.title=Zoom arrière +zoom_out_label=Zoom arrière +zoom_in.title=Zoom avant +zoom_in_label=Zoom avant +zoom.title=Zoom +presentation_mode.title=Basculer en mode présentation +presentation_mode_label=Mode présentation +open_file.title=Ouvrir le fichier +open_file_label=Ouvrir le fichier +print.title=Imprimer +print_label=Imprimer +download.title=Télécharger +download_label=Télécharger +bookmark.title=Affichage courant (copier ou ouvrir dans une nouvelle fenêtre) +bookmark_label=Affichage actuel + +# Secondary toolbar and context menu +tools.title=Outils +tools_label=Outils +first_page.title=Aller à la première page +first_page.label=Aller à la première page +first_page_label=Aller à la première page +last_page.title=Aller à la dernière page +last_page.label=Aller à la dernière page +last_page_label=Aller à la dernière page +page_rotate_cw.title=Rotation horaire +page_rotate_cw.label=Rotation horaire +page_rotate_cw_label=Rotation horaire +page_rotate_ccw.title=Rotation anti-horaire +page_rotate_ccw.label=Rotation anti-horaire +page_rotate_ccw_label=Rotation anti-horaire + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Afficher/Masquer le panneau latéral +toggle_sidebar_label=Afficher/Masquer le panneau latéral +outline.title=Afficher les signets +outline_label=Signets du document +attachments.title=Afficher les pièces jointes +attachments_label=Pièces jointes +thumbs.title=Afficher les vignettes +thumbs_label=Vignettes +findbar.title=Rechercher dans le document +findbar_label=Rechercher + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Page {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Vignette de la page {{page}} + +hand_tool_enable.title=Activer l’outil main +hand_tool_enable_label=Activer l’outil main +hand_tool_disable.title=Désactiver l’outil main +hand_tool_disable_label=Désactiver l’outil main + +# Document properties dialog box +document_properties.title=Propriétés du document… +document_properties_label=Propriétés du document… +document_properties_file_name=Nom du fichier : +document_properties_file_size=Taille du fichier : +document_properties_kb={{size_kb}} Ko ({{size_b}} octets) +document_properties_mb={{size_mb}} Mo ({{size_b}} octets) +document_properties_title=Titre : +document_properties_author=Auteur : +document_properties_subject=Sujet : +document_properties_keywords=Mots-clés : +document_properties_creation_date=Date de création : +document_properties_modification_date=Modifié le : +document_properties_date_string={{date}} à {{time}} +document_properties_creator=Créé par : +document_properties_producer=Outil de conversion PDF : +document_properties_version=Version PDF : +document_properties_page_count=Nombre de pages : +document_properties_close=Fermer + +# Find panel button title and messages +find_label=Rechercher : +find_previous.title=Trouver l’occurrence précédente de la phrase +find_previous_label=Précédent +find_next.title=Trouver la prochaine occurrence de la phrase +find_next_label=Suivant +find_highlight=Tout surligner +find_match_case_label=Respecter la casse +find_reached_top=Haut de la page atteint, poursuite depuis la fin +find_reached_bottom=Bas de la page atteint, poursuite au début +find_not_found=Phrase introuvable + +# Error panel labels +error_more_info=Plus d’informations +error_less_info=Moins d’informations +error_close=Fermer +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (identifiant de compilation : {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Message : {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pile : {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fichier : {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Ligne : {{line}} +rendering_error=Une erreur s’est produite lors de l’affichage de la page. + +# Predefined zoom values +page_scale_width=Pleine largeur +page_scale_fit=Page entière +page_scale_auto=Zoom automatique +page_scale_actual=Taille réelle +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}} % + +# Loading indicator messages +loading_error_indicator=Erreur +loading_error=Une erreur s’est produite lors du chargement du fichier PDF. +invalid_file_error=Fichier PDF invalide ou corrompu. +missing_file_error=Fichier PDF manquant. +unexpected_response_error=Réponse inattendue du serveur. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Annotation {{type}}] +password_label=Veuillez saisir le mot de passe pour ouvrir ce fichier PDF. +password_invalid=Mot de passe incorrect. Veuillez réessayer. +password_ok=OK +password_cancel=Annuler + +printing_not_supported=Attention : l’impression n’est pas totalement prise en charge par ce navigateur. +printing_not_ready=Attention : le PDF n’est pas entièrement chargé pour pouvoir l’imprimer. +web_fonts_disabled=Les polices web sont désactivées : impossible d’utiliser les polices intégrées au PDF. +document_colors_not_allowed=Les documents PDF ne peuvent pas utiliser leurs propres couleurs : « Autoriser les pages web à utiliser leurs propres couleurs » est désactivé dans le navigateur. diff --git a/static/pdf.js/locale/fur/viewer.ftl b/static/pdf.js/locale/fur/viewer.ftl deleted file mode 100644 index 8e8c8a01..00000000 --- a/static/pdf.js/locale/fur/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pagjine precedente -pdfjs-previous-button-label = Indaûr -pdfjs-next-button = - .title = Prossime pagjine -pdfjs-next-button-label = Indevant -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pagjine -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = di { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } di { $pagesCount }) -pdfjs-zoom-out-button = - .title = Impiçulìs -pdfjs-zoom-out-button-label = Impiçulìs -pdfjs-zoom-in-button = - .title = Ingrandìs -pdfjs-zoom-in-button-label = Ingrandìs -pdfjs-zoom-select = - .title = Ingrandiment -pdfjs-presentation-mode-button = - .title = Passe ae modalitât presentazion -pdfjs-presentation-mode-button-label = Modalitât presentazion -pdfjs-open-file-button = - .title = Vierç un file -pdfjs-open-file-button-label = Vierç -pdfjs-print-button = - .title = Stampe -pdfjs-print-button-label = Stampe -pdfjs-save-button = - .title = Salve -pdfjs-save-button-label = Salve -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Discjame -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Discjame -pdfjs-bookmark-button = - .title = Pagjine corinte (mostre URL de pagjine atuâl) -pdfjs-bookmark-button-label = Pagjine corinte -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Vierç te aplicazion -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Vierç te aplicazion - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Struments -pdfjs-tools-button-label = Struments -pdfjs-first-page-button = - .title = Va ae prime pagjine -pdfjs-first-page-button-label = Va ae prime pagjine -pdfjs-last-page-button = - .title = Va ae ultime pagjine -pdfjs-last-page-button-label = Va ae ultime pagjine -pdfjs-page-rotate-cw-button = - .title = Zire in sens orari -pdfjs-page-rotate-cw-button-label = Zire in sens orari -pdfjs-page-rotate-ccw-button = - .title = Zire in sens antiorari -pdfjs-page-rotate-ccw-button-label = Zire in sens antiorari -pdfjs-cursor-text-select-tool-button = - .title = Ative il strument di selezion dal test -pdfjs-cursor-text-select-tool-button-label = Strument di selezion dal test -pdfjs-cursor-hand-tool-button = - .title = Ative il strument manute -pdfjs-cursor-hand-tool-button-label = Strument manute -pdfjs-scroll-page-button = - .title = Dopre il scoriment des pagjinis -pdfjs-scroll-page-button-label = Scoriment pagjinis -pdfjs-scroll-vertical-button = - .title = Dopre scoriment verticâl -pdfjs-scroll-vertical-button-label = Scoriment verticâl -pdfjs-scroll-horizontal-button = - .title = Dopre scoriment orizontâl -pdfjs-scroll-horizontal-button-label = Scoriment orizontâl -pdfjs-scroll-wrapped-button = - .title = Dopre scoriment par blocs -pdfjs-scroll-wrapped-button-label = Scoriment par blocs -pdfjs-spread-none-button = - .title = No sta meti dongje pagjinis in cubie -pdfjs-spread-none-button-label = No cubiis di pagjinis -pdfjs-spread-odd-button = - .title = Met dongje cubiis di pagjinis scomençant des pagjinis dispar -pdfjs-spread-odd-button-label = Cubiis di pagjinis, dispar a çampe -pdfjs-spread-even-button = - .title = Met dongje cubiis di pagjinis scomençant des pagjinis pâr -pdfjs-spread-even-button-label = Cubiis di pagjinis, pâr a çampe - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Proprietâts dal document… -pdfjs-document-properties-button-label = Proprietâts dal document… -pdfjs-document-properties-file-name = Non dal file: -pdfjs-document-properties-file-size = Dimension dal file: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Titul: -pdfjs-document-properties-author = Autôr: -pdfjs-document-properties-subject = Ogjet: -pdfjs-document-properties-keywords = Peraulis clâf: -pdfjs-document-properties-creation-date = Date di creazion: -pdfjs-document-properties-modification-date = Date di modifiche: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creatôr -pdfjs-document-properties-producer = Gjeneradôr PDF: -pdfjs-document-properties-version = Version PDF: -pdfjs-document-properties-page-count = Numar di pagjinis: -pdfjs-document-properties-page-size = Dimension de pagjine: -pdfjs-document-properties-page-size-unit-inches = oncis -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = verticâl -pdfjs-document-properties-page-size-orientation-landscape = orizontâl -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letare -pdfjs-document-properties-page-size-name-legal = Legâl - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Visualizazion web svelte: -pdfjs-document-properties-linearized-yes = Sì -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Siere - -## Print - -pdfjs-print-progress-message = Daûr a prontâ il document pe stampe… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Anule -pdfjs-printing-not-supported = Atenzion: la stampe no je supuartade ad implen di chest navigadôr. -pdfjs-printing-not-ready = Atenzion: il PDF nol è stât cjamât dal dut pe stampe. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Ative/Disative sbare laterâl -pdfjs-toggle-sidebar-notification-button = - .title = Ative/Disative sbare laterâl (il document al conten struture/zontis/strâts) -pdfjs-toggle-sidebar-button-label = Ative/Disative sbare laterâl -pdfjs-document-outline-button = - .title = Mostre la struture dal document (dopli clic par slargjâ/strenzi ducj i elements) -pdfjs-document-outline-button-label = Struture dal document -pdfjs-attachments-button = - .title = Mostre lis zontis -pdfjs-attachments-button-label = Zontis -pdfjs-layers-button = - .title = Mostre i strâts (dopli clic par ristabilî ducj i strâts al stât predefinît) -pdfjs-layers-button-label = Strâts -pdfjs-thumbs-button = - .title = Mostre miniaturis -pdfjs-thumbs-button-label = Miniaturis -pdfjs-current-outline-item-button = - .title = Cjate l'element de struture atuâl -pdfjs-current-outline-item-button-label = Element de struture atuâl -pdfjs-findbar-button = - .title = Cjate tal document -pdfjs-findbar-button-label = Cjate -pdfjs-additional-layers = Strâts adizionâi - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pagjine { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniature de pagjine { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Cjate - .placeholder = Cjate tal document… -pdfjs-find-previous-button = - .title = Cjate il câs precedent dal test -pdfjs-find-previous-button-label = Precedent -pdfjs-find-next-button = - .title = Cjate il câs sucessîf dal test -pdfjs-find-next-button-label = Sucessîf -pdfjs-find-highlight-checkbox = Evidenzie dut -pdfjs-find-match-case-checkbox-label = Fâs distinzion tra maiusculis e minusculis -pdfjs-find-match-diacritics-checkbox-label = Corispondence diacritiche -pdfjs-find-entire-word-checkbox-label = Peraulis interiis -pdfjs-find-reached-top = Si è rivâts al inizi dal document e si à continuât de fin -pdfjs-find-reached-bottom = Si è rivât ae fin dal document e si à continuât dal inizi -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } di { $total } corispondence - *[other] { $current } di { $total } corispondencis - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Plui di { $limit } corispondence - *[other] Plui di { $limit } corispondencis - } -pdfjs-find-not-found = Test no cjatât - -## Predefined zoom values - -pdfjs-page-scale-width = Largjece de pagjine -pdfjs-page-scale-fit = Pagjine interie -pdfjs-page-scale-auto = Ingrandiment automatic -pdfjs-page-scale-actual = Dimension reâl -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pagjine { $page } - -## Loading indicator messages - -pdfjs-loading-error = Al è vignût fûr un erôr intant che si cjariave il PDF. -pdfjs-invalid-file-error = File PDF no valit o ruvinât. -pdfjs-missing-file-error = Al mancje il file PDF. -pdfjs-unexpected-response-error = Rispueste dal servidôr inspietade. -pdfjs-rendering-error = Al è vignût fûr un erôr tal realizâ la visualizazion de pagjine. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotazion { $type }] - -## Password - -pdfjs-password-label = Inserìs la password par vierzi chest file PDF. -pdfjs-password-invalid = Password no valide. Par plasê torne prove. -pdfjs-password-ok-button = Va ben -pdfjs-password-cancel-button = Anule -pdfjs-web-fonts-disabled = I caratars dal Web a son disativâts: Impussibil doprâ i caratars PDF incorporâts. - -## Editing - -pdfjs-editor-free-text-button = - .title = Test -pdfjs-editor-free-text-button-label = Test -pdfjs-editor-ink-button = - .title = Dissen -pdfjs-editor-ink-button-label = Dissen -pdfjs-editor-stamp-button = - .title = Zonte o modifiche imagjins -pdfjs-editor-stamp-button-label = Zonte o modifiche imagjins -pdfjs-editor-highlight-button = - .title = Evidenzie -pdfjs-editor-highlight-button-label = Evidenzie -pdfjs-highlight-floating-button = - .title = Evidenzie -pdfjs-highlight-floating-button1 = - .title = Evidenzie - .aria-label = Evidenzie -pdfjs-highlight-floating-button-label = Evidenzie - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Gjave dissen -pdfjs-editor-remove-freetext-button = - .title = Gjave test -pdfjs-editor-remove-stamp-button = - .title = Gjave imagjin -pdfjs-editor-remove-highlight-button = - .title = Gjave evidenziazion - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Colôr -pdfjs-editor-free-text-size-input = Dimension -pdfjs-editor-ink-color-input = Colôr -pdfjs-editor-ink-thickness-input = Spessôr -pdfjs-editor-ink-opacity-input = Opacitât -pdfjs-editor-stamp-add-image-button = - .title = Zonte imagjin -pdfjs-editor-stamp-add-image-button-label = Zonte imagjin -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Spessôr -pdfjs-editor-free-highlight-thickness-title = - .title = Modifiche il spessôr de selezion pai elements che no son testuâi -pdfjs-free-text = - .aria-label = Editôr di test -pdfjs-free-text-default-content = Scomence a scrivi… -pdfjs-ink = - .aria-label = Editôr dissens -pdfjs-ink-canvas = - .aria-label = Imagjin creade dal utent - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Test alternatîf -pdfjs-editor-alt-text-edit-button-label = Modifiche test alternatîf -pdfjs-editor-alt-text-dialog-label = Sielç une opzion -pdfjs-editor-alt-text-dialog-description = Il test alternatîf (“alt text”) al jude cuant che lis personis no puedin viodi la imagjin o cuant che la imagjine no ven cjariade. -pdfjs-editor-alt-text-add-description-label = Zonte une descrizion -pdfjs-editor-alt-text-add-description-description = Ponte a une o dôs frasis che a descrivin l’argoment, la ambientazion o lis azions. -pdfjs-editor-alt-text-mark-decorative-label = Segne come decorative -pdfjs-editor-alt-text-mark-decorative-description = Chest al ven doprât pes imagjins ornamentâls, come i ôrs o lis filigranis. -pdfjs-editor-alt-text-cancel-button = Anule -pdfjs-editor-alt-text-save-button = Salve -pdfjs-editor-alt-text-decorative-tooltip = Segnade come decorative -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Par esempli, “Un zovin si sente a taule par mangjâ” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Cjanton in alt a çampe — ridimensione -pdfjs-editor-resizer-label-top-middle = Bande superiôr tal mieç — ridimensione -pdfjs-editor-resizer-label-top-right = Cjanton in alt a diestre — ridimensione -pdfjs-editor-resizer-label-middle-right = Bande diestre tal mieç — ridimensione -pdfjs-editor-resizer-label-bottom-right = Cjanton in bas a diestre — ridimensione -pdfjs-editor-resizer-label-bottom-middle = Bande inferiôr tal mieç — ridimensione -pdfjs-editor-resizer-label-bottom-left = Cjanton in bas a çampe — ridimensione -pdfjs-editor-resizer-label-middle-left = Bande di çampe tal mieç — ridimensione - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Colôr par evidenziâ -pdfjs-editor-colorpicker-button = - .title = Cambie colôr -pdfjs-editor-colorpicker-dropdown = - .aria-label = Sieltis di colôr -pdfjs-editor-colorpicker-yellow = - .title = Zâl -pdfjs-editor-colorpicker-green = - .title = Vert -pdfjs-editor-colorpicker-blue = - .title = Blu -pdfjs-editor-colorpicker-pink = - .title = Rose -pdfjs-editor-colorpicker-red = - .title = Ros - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Mostre dut -pdfjs-editor-highlight-show-all-button = - .title = Mostre dut diff --git a/static/pdf.js/locale/fy-NL/viewer.ftl b/static/pdf.js/locale/fy-NL/viewer.ftl deleted file mode 100644 index a67f9b9d..00000000 --- a/static/pdf.js/locale/fy-NL/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Foarige side -pdfjs-previous-button-label = Foarige -pdfjs-next-button = - .title = Folgjende side -pdfjs-next-button-label = Folgjende -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Side -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = fan { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } fan { $pagesCount }) -pdfjs-zoom-out-button = - .title = Utzoome -pdfjs-zoom-out-button-label = Utzoome -pdfjs-zoom-in-button = - .title = Ynzoome -pdfjs-zoom-in-button-label = Ynzoome -pdfjs-zoom-select = - .title = Zoome -pdfjs-presentation-mode-button = - .title = Wikselje nei presintaasjemodus -pdfjs-presentation-mode-button-label = Presintaasjemodus -pdfjs-open-file-button = - .title = Bestân iepenje -pdfjs-open-file-button-label = Iepenje -pdfjs-print-button = - .title = Ofdrukke -pdfjs-print-button-label = Ofdrukke -pdfjs-save-button = - .title = Bewarje -pdfjs-save-button-label = Bewarje -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Downloade -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Downloade -pdfjs-bookmark-button = - .title = Aktuele side (URL fan aktuele side besjen) -pdfjs-bookmark-button-label = Aktuele side -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Iepenje yn app -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Iepenje yn app - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Ark -pdfjs-tools-button-label = Ark -pdfjs-first-page-button = - .title = Gean nei earste side -pdfjs-first-page-button-label = Gean nei earste side -pdfjs-last-page-button = - .title = Gean nei lêste side -pdfjs-last-page-button-label = Gean nei lêste side -pdfjs-page-rotate-cw-button = - .title = Rjochtsom draaie -pdfjs-page-rotate-cw-button-label = Rjochtsom draaie -pdfjs-page-rotate-ccw-button = - .title = Linksom draaie -pdfjs-page-rotate-ccw-button-label = Linksom draaie -pdfjs-cursor-text-select-tool-button = - .title = Tekstseleksjehelpmiddel ynskeakelje -pdfjs-cursor-text-select-tool-button-label = Tekstseleksjehelpmiddel -pdfjs-cursor-hand-tool-button = - .title = Hânhelpmiddel ynskeakelje -pdfjs-cursor-hand-tool-button-label = Hânhelpmiddel -pdfjs-scroll-page-button = - .title = Sideskowen brûke -pdfjs-scroll-page-button-label = Sideskowen -pdfjs-scroll-vertical-button = - .title = Fertikaal skowe brûke -pdfjs-scroll-vertical-button-label = Fertikaal skowe -pdfjs-scroll-horizontal-button = - .title = Horizontaal skowe brûke -pdfjs-scroll-horizontal-button-label = Horizontaal skowe -pdfjs-scroll-wrapped-button = - .title = Skowe mei oersjoch brûke -pdfjs-scroll-wrapped-button-label = Skowe mei oersjoch -pdfjs-spread-none-button = - .title = Sidesprieding net gearfetsje -pdfjs-spread-none-button-label = Gjin sprieding -pdfjs-spread-odd-button = - .title = Sidesprieding gearfetsje te starten mei ûneven nûmers -pdfjs-spread-odd-button-label = Uneven sprieding -pdfjs-spread-even-button = - .title = Sidesprieding gearfetsje te starten mei even nûmers -pdfjs-spread-even-button-label = Even sprieding - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokuminteigenskippen… -pdfjs-document-properties-button-label = Dokuminteigenskippen… -pdfjs-document-properties-file-name = Bestânsnamme: -pdfjs-document-properties-file-size = Bestânsgrutte: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Titel: -pdfjs-document-properties-author = Auteur: -pdfjs-document-properties-subject = Underwerp: -pdfjs-document-properties-keywords = Kaaiwurden: -pdfjs-document-properties-creation-date = Oanmaakdatum: -pdfjs-document-properties-modification-date = Bewurkingsdatum: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Makker: -pdfjs-document-properties-producer = PDF-makker: -pdfjs-document-properties-version = PDF-ferzje: -pdfjs-document-properties-page-count = Siden: -pdfjs-document-properties-page-size = Sideformaat: -pdfjs-document-properties-page-size-unit-inches = yn -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = steand -pdfjs-document-properties-page-size-orientation-landscape = lizzend -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Juridysk - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Flugge webwerjefte: -pdfjs-document-properties-linearized-yes = Ja -pdfjs-document-properties-linearized-no = Nee -pdfjs-document-properties-close-button = Slute - -## Print - -pdfjs-print-progress-message = Dokumint tariede oar ôfdrukken… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Annulearje -pdfjs-printing-not-supported = Warning: Printen is net folslein stipe troch dizze browser. -pdfjs-printing-not-ready = Warning: PDF is net folslein laden om ôf te drukken. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Sidebalke yn-/útskeakelje -pdfjs-toggle-sidebar-notification-button = - .title = Sidebalke yn-/útskeakelje (dokumint befettet oersjoch/bylagen/lagen) -pdfjs-toggle-sidebar-button-label = Sidebalke yn-/útskeakelje -pdfjs-document-outline-button = - .title = Dokumintoersjoch toane (dûbelklik om alle items út/yn te klappen) -pdfjs-document-outline-button-label = Dokumintoersjoch -pdfjs-attachments-button = - .title = Bylagen toane -pdfjs-attachments-button-label = Bylagen -pdfjs-layers-button = - .title = Lagen toane (dûbelklik om alle lagen nei de standertsteat werom te setten) -pdfjs-layers-button-label = Lagen -pdfjs-thumbs-button = - .title = Foarbylden toane -pdfjs-thumbs-button-label = Foarbylden -pdfjs-current-outline-item-button = - .title = Aktueel item yn ynhâldsopjefte sykje -pdfjs-current-outline-item-button-label = Aktueel item yn ynhâldsopjefte -pdfjs-findbar-button = - .title = Sykje yn dokumint -pdfjs-findbar-button-label = Sykje -pdfjs-additional-layers = Oanfoljende lagen - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Side { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Foarbyld fan side { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Sykje - .placeholder = Sykje yn dokumint… -pdfjs-find-previous-button = - .title = It foarige foarkommen fan de tekst sykje -pdfjs-find-previous-button-label = Foarige -pdfjs-find-next-button = - .title = It folgjende foarkommen fan de tekst sykje -pdfjs-find-next-button-label = Folgjende -pdfjs-find-highlight-checkbox = Alles markearje -pdfjs-find-match-case-checkbox-label = Haadlettergefoelich -pdfjs-find-match-diacritics-checkbox-label = Diakrityske tekens brûke -pdfjs-find-entire-word-checkbox-label = Hiele wurden -pdfjs-find-reached-top = Boppekant fan dokumint berikt, trochgien fan ûnder ôf -pdfjs-find-reached-bottom = Ein fan dokumint berikt, trochgien fan boppe ôf -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } fan { $total } oerienkomst - *[other] { $current } fan { $total } oerienkomsten - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Mear as { $limit } oerienkomst - *[other] Mear as { $limit } oerienkomsten - } -pdfjs-find-not-found = Tekst net fûn - -## Predefined zoom values - -pdfjs-page-scale-width = Sidebreedte -pdfjs-page-scale-fit = Hiele side -pdfjs-page-scale-auto = Automatysk zoome -pdfjs-page-scale-actual = Werklike grutte -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Side { $page } - -## Loading indicator messages - -pdfjs-loading-error = Der is in flater bard by it laden fan de PDF. -pdfjs-invalid-file-error = Ynfalide of korruptearre PDF-bestân. -pdfjs-missing-file-error = PDF-bestân ûntbrekt. -pdfjs-unexpected-response-error = Unferwacht serverantwurd. -pdfjs-rendering-error = Der is in flater bard by it renderjen fan de side. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type }-annotaasje] - -## Password - -pdfjs-password-label = Jou it wachtwurd om dit PDF-bestân te iepenjen. -pdfjs-password-invalid = Ferkeard wachtwurd. Probearje opnij. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Annulearje -pdfjs-web-fonts-disabled = Weblettertypen binne útskeakele: gebrûk fan ynsluten PDF-lettertypen is net mooglik. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Tekenje -pdfjs-editor-ink-button-label = Tekenje -pdfjs-editor-stamp-button = - .title = Ofbyldingen tafoegje of bewurkje -pdfjs-editor-stamp-button-label = Ofbyldingen tafoegje of bewurkje -pdfjs-editor-highlight-button = - .title = Markearje -pdfjs-editor-highlight-button-label = Markearje -pdfjs-highlight-floating-button = - .title = Markearje -pdfjs-highlight-floating-button1 = - .title = Markearje - .aria-label = Markearje -pdfjs-highlight-floating-button-label = Markearje - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Tekening fuortsmite -pdfjs-editor-remove-freetext-button = - .title = Tekst fuortsmite -pdfjs-editor-remove-stamp-button = - .title = Ofbylding fuortsmite -pdfjs-editor-remove-highlight-button = - .title = Markearring fuortsmite - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Kleur -pdfjs-editor-free-text-size-input = Grutte -pdfjs-editor-ink-color-input = Kleur -pdfjs-editor-ink-thickness-input = Tsjokte -pdfjs-editor-ink-opacity-input = Transparânsje -pdfjs-editor-stamp-add-image-button = - .title = Ofbylding tafoegje -pdfjs-editor-stamp-add-image-button-label = Ofbylding tafoegje -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tsjokte -pdfjs-editor-free-highlight-thickness-title = - .title = Tsjokte wizigje by aksintuearring fan oare items as tekst -pdfjs-free-text = - .aria-label = Tekstbewurker -pdfjs-free-text-default-content = Begjin mei typen… -pdfjs-ink = - .aria-label = Tekeningbewurker -pdfjs-ink-canvas = - .aria-label = Troch brûker makke ôfbylding - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternative tekst -pdfjs-editor-alt-text-edit-button-label = Alternative tekst bewurkje -pdfjs-editor-alt-text-dialog-label = Kies in opsje -pdfjs-editor-alt-text-dialog-description = Alternative tekst helpt wannear’t minsken de ôfbylding net sjen kinne of wannear’t dizze net laden wurdt. -pdfjs-editor-alt-text-add-description-label = Foegje in beskriuwing ta -pdfjs-editor-alt-text-add-description-description = Stribje nei 1-2 sinnen dy’t it ûnderwerp, de omjouwing of de aksjes beskriuwe. -pdfjs-editor-alt-text-mark-decorative-label = As dekoratyf markearje -pdfjs-editor-alt-text-mark-decorative-description = Dit wurdt brûkt foar sierlike ôfbyldingen, lykas rânen of wettermerken. -pdfjs-editor-alt-text-cancel-button = Annulearje -pdfjs-editor-alt-text-save-button = Bewarje -pdfjs-editor-alt-text-decorative-tooltip = As dekoratyf markearre -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Bygelyks, ‘In jonge man sit oan in tafel om te iten’ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Linkerboppehoek – formaat wizigje -pdfjs-editor-resizer-label-top-middle = Midden boppe – formaat wizigje -pdfjs-editor-resizer-label-top-right = Rjochterboppehoek – formaat wizigje -pdfjs-editor-resizer-label-middle-right = Midden rjochts – formaat wizigje -pdfjs-editor-resizer-label-bottom-right = Rjochterûnderhoek – formaat wizigje -pdfjs-editor-resizer-label-bottom-middle = Midden ûnder – formaat wizigje -pdfjs-editor-resizer-label-bottom-left = Linkerûnderhoek – formaat wizigje -pdfjs-editor-resizer-label-middle-left = Links midden – formaat wizigje - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Markearringskleur -pdfjs-editor-colorpicker-button = - .title = Kleur wizigje -pdfjs-editor-colorpicker-dropdown = - .aria-label = Kleurkarren -pdfjs-editor-colorpicker-yellow = - .title = Giel -pdfjs-editor-colorpicker-green = - .title = Grien -pdfjs-editor-colorpicker-blue = - .title = Blau -pdfjs-editor-colorpicker-pink = - .title = Roze -pdfjs-editor-colorpicker-red = - .title = Read - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Alles toane -pdfjs-editor-highlight-show-all-button = - .title = Alles toane diff --git a/static/pdf.js/locale/fy-NL/viewer.properties b/static/pdf.js/locale/fy-NL/viewer.properties new file mode 100644 index 00000000..d195428c --- /dev/null +++ b/static/pdf.js/locale/fy-NL/viewer.properties @@ -0,0 +1,180 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Foarige side +previous_label=Foarige +next.title=Folgjende side +next_label=Folgjende + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=side: +page_of=fan {{pageCount}} + +zoom_out.title=Utzoome +zoom_out_label=Utzoome +zoom_in.title=Ynzoome +zoom_in_label=Ynzoome +zoom.title=Zoome +print.title=Ofdrukke +print_label=Ofdrukke +presentation_mode.title=Wikselje nei presintaasjemoadus +presentation_mode_label=Presintaasjemoadus +open_file.title=Bestân iepenje +open_file_label=Iepenje +download.title=Ynlade +download_label=Ynlade +bookmark.title=Aktuele finster (kopiearje of iepenje yn nij finster) +bookmark_label=Aktuele finster + +# Secondary toolbar and context menu +tools.title=Ark +tools_label=Ark +first_page.title=Gean nei earste side +first_page.label=Gean nei earste side +first_page_label=Gean nei earste side +last_page.title=Gean nei lêste side +last_page.label=Gean nei lêste side +last_page_label=Gean nei lêste side +page_rotate_cw.title=Rjochtsom draaie +page_rotate_cw.label=Rjochtsom draaie +page_rotate_cw_label=Rjochtsom draaie +page_rotate_ccw.title=Linksom draaie +page_rotate_ccw.label=Linksom draaie +page_rotate_ccw_label=Linksom draaie + +hand_tool_enable.title=Hânark ynskeakelje +hand_tool_enable_label=Hânark ynskeakelje +hand_tool_disable.title=Hânark úyskeakelje +hand_tool_disable_label=Hânark úyskeakelje + +# Document properties dialog box +document_properties.title=Dokuminteigenskippen… +document_properties_label=Dokuminteigenskippen… +document_properties_file_name=Bestânsnamme: +document_properties_file_size=Bestânsgrutte: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Titel: +document_properties_author=Auteur: +document_properties_subject=Underwerp: +document_properties_keywords=Kaaiwurden: +document_properties_creation_date=Oanmaakdatum: +document_properties_modification_date=Bewurkingsdatum: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Makker: +document_properties_producer=PDF-makker: +document_properties_version=PDF-ferzje: +document_properties_page_count=Siden: +document_properties_close=Slute + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Sidebalke yn-/útskeakelje +toggle_sidebar_label=Sidebalke yn-/útskeakelje +outline.title=Dokumint ynhâldsopjefte toane +outline_label=Dokumint ynhâldsopjefte +attachments.title=Bylagen toane +attachments_label=Bylagen +thumbs.title=Foarbylden toane +thumbs_label=Foarbylden +findbar.title=Sykje yn dokumint +findbar_label=Sykje + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Side {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Foarbyld fan side {{page}} + +# Context menu +first_page.label=Nei earste side gean +last_page.label=Nei lêste side gean +page_rotate_cw.label=Rjochtsom draaie +page_rotate_ccw.label=Linksom draaie + +# Find panel button title and messages +find_label=Sykje: +find_previous.title=It foarige foarkommen fan de tekst sykje +find_previous_label=Foarige +find_next.title=It folgjende foarkommen fan de tekst sykje +find_next_label=Folgjende +find_highlight=Alles markearje +find_match_case_label=Haadlettergefoelich +find_reached_top=Boppekant fan dokumint berikt, trochgien fanôf ûnder +find_reached_bottom=Ein fan dokumint berikt, trochgien fanôf boppe +find_not_found=Tekst net fûn + +# Error panel labels +error_more_info=Mear ynformaasje +error_less_info=Minder ynformaasje +error_close=Slute +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js f{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Berjocht: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Bestân: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rigel: {{line}} +rendering_error=Der is in flater bard by it renderjen fan de side. + +# Predefined zoom values +page_scale_width=Sidebreedte +page_scale_fit=Hiele side +page_scale_auto=Automatysk zoome +page_scale_actual=Wurklike grutte +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Flater +loading_error=Der is in flater bard by it laden fan de PDF. +invalid_file_error=Ynfalide of korruptearre PDF-bestân. +missing_file_error=PDF-bestân ûntbrekt. +unexpected_response_error=Unferwacht tsjinnerantwurd. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}}-annotaasje] +password_label=Jou it wachtwurd om dit PDF-bestân te iepenjen. +password_invalid=Ferkeard wachtwurd. Probearje opnij. +password_ok=OK +password_cancel=Annulearje + +printing_not_supported=Warning: Printen is net folslein stipe troch dizze browser. +printing_not_ready=Warning: PDF is net folslein laden om ôf te drukken. +web_fonts_disabled=Weblettertypen binne útskeakele: gebrûk fan ynsluten PDF-lettertypen is net mooglik. +document_colors_not_allowed=PDF-dokuminten meie harren eigen kleuren net brûike: ‘Siden tastean om harren eigen kleuren te kiezen’ is útskeakele yn de browser. + diff --git a/static/pdf.js/locale/ga-IE/viewer.ftl b/static/pdf.js/locale/ga-IE/viewer.ftl deleted file mode 100644 index cb593089..00000000 --- a/static/pdf.js/locale/ga-IE/viewer.ftl +++ /dev/null @@ -1,213 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = An Leathanach Roimhe Seo -pdfjs-previous-button-label = Roimhe Seo -pdfjs-next-button = - .title = An Chéad Leathanach Eile -pdfjs-next-button-label = Ar Aghaidh -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Leathanach -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = as { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } as { $pagesCount }) -pdfjs-zoom-out-button = - .title = Súmáil Amach -pdfjs-zoom-out-button-label = Súmáil Amach -pdfjs-zoom-in-button = - .title = Súmáil Isteach -pdfjs-zoom-in-button-label = Súmáil Isteach -pdfjs-zoom-select = - .title = Súmáil -pdfjs-presentation-mode-button = - .title = Úsáid an Mód Láithreoireachta -pdfjs-presentation-mode-button-label = Mód Láithreoireachta -pdfjs-open-file-button = - .title = Oscail Comhad -pdfjs-open-file-button-label = Oscail -pdfjs-print-button = - .title = Priontáil -pdfjs-print-button-label = Priontáil - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Uirlisí -pdfjs-tools-button-label = Uirlisí -pdfjs-first-page-button = - .title = Go dtí an chéad leathanach -pdfjs-first-page-button-label = Go dtí an chéad leathanach -pdfjs-last-page-button = - .title = Go dtí an leathanach deiridh -pdfjs-last-page-button-label = Go dtí an leathanach deiridh -pdfjs-page-rotate-cw-button = - .title = Rothlaigh ar deiseal -pdfjs-page-rotate-cw-button-label = Rothlaigh ar deiseal -pdfjs-page-rotate-ccw-button = - .title = Rothlaigh ar tuathal -pdfjs-page-rotate-ccw-button-label = Rothlaigh ar tuathal -pdfjs-cursor-text-select-tool-button = - .title = Cumasaigh an Uirlis Roghnaithe Téacs -pdfjs-cursor-text-select-tool-button-label = Uirlis Roghnaithe Téacs -pdfjs-cursor-hand-tool-button = - .title = Cumasaigh an Uirlis Láimhe -pdfjs-cursor-hand-tool-button-label = Uirlis Láimhe - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Airíonna na Cáipéise… -pdfjs-document-properties-button-label = Airíonna na Cáipéise… -pdfjs-document-properties-file-name = Ainm an chomhaid: -pdfjs-document-properties-file-size = Méid an chomhaid: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kB ({ $size_b } beart) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } beart) -pdfjs-document-properties-title = Teideal: -pdfjs-document-properties-author = Údar: -pdfjs-document-properties-subject = Ábhar: -pdfjs-document-properties-keywords = Eochairfhocail: -pdfjs-document-properties-creation-date = Dáta Cruthaithe: -pdfjs-document-properties-modification-date = Dáta Athraithe: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Cruthaitheoir: -pdfjs-document-properties-producer = Cruthaitheoir an PDF: -pdfjs-document-properties-version = Leagan PDF: -pdfjs-document-properties-page-count = Líon Leathanach: - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -pdfjs-document-properties-close-button = Dún - -## Print - -pdfjs-print-progress-message = Cáipéis á hullmhú le priontáil… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cealaigh -pdfjs-printing-not-supported = Rabhadh: Ní thacaíonn an brabhsálaí le priontáil go hiomlán. -pdfjs-printing-not-ready = Rabhadh: Ní féidir an PDF a phriontáil go dtí go mbeidh an cháipéis iomlán lódáilte. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Scoránaigh an Barra Taoibh -pdfjs-toggle-sidebar-button-label = Scoránaigh an Barra Taoibh -pdfjs-document-outline-button = - .title = Taispeáin Imlíne na Cáipéise (déchliceáil chun chuile rud a leathnú nó a laghdú) -pdfjs-document-outline-button-label = Creatlach na Cáipéise -pdfjs-attachments-button = - .title = Taispeáin Iatáin -pdfjs-attachments-button-label = Iatáin -pdfjs-thumbs-button = - .title = Taispeáin Mionsamhlacha -pdfjs-thumbs-button-label = Mionsamhlacha -pdfjs-findbar-button = - .title = Aimsigh sa Cháipéis -pdfjs-findbar-button-label = Aimsigh - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Leathanach { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Mionsamhail Leathanaigh { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Aimsigh - .placeholder = Aimsigh sa cháipéis… -pdfjs-find-previous-button = - .title = Aimsigh an sampla roimhe seo den nath seo -pdfjs-find-previous-button-label = Roimhe seo -pdfjs-find-next-button = - .title = Aimsigh an chéad sampla eile den nath sin -pdfjs-find-next-button-label = Ar aghaidh -pdfjs-find-highlight-checkbox = Aibhsigh uile -pdfjs-find-match-case-checkbox-label = Cásíogair -pdfjs-find-entire-word-checkbox-label = Focail iomlána -pdfjs-find-reached-top = Ag barr na cáipéise, ag leanúint ón mbun -pdfjs-find-reached-bottom = Ag bun na cáipéise, ag leanúint ón mbarr -pdfjs-find-not-found = Frása gan aimsiú - -## Predefined zoom values - -pdfjs-page-scale-width = Leithead Leathanaigh -pdfjs-page-scale-fit = Laghdaigh go dtí an Leathanach -pdfjs-page-scale-auto = Súmáil Uathoibríoch -pdfjs-page-scale-actual = Fíormhéid -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Tharla earráid agus an cháipéis PDF á lódáil. -pdfjs-invalid-file-error = Comhad neamhbhailí nó truaillithe PDF. -pdfjs-missing-file-error = Comhad PDF ar iarraidh. -pdfjs-unexpected-response-error = Freagra ón bhfreastalaí nach rabhthas ag súil leis. -pdfjs-rendering-error = Tharla earráid agus an leathanach á leagan amach. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anótáil { $type }] - -## Password - -pdfjs-password-label = Cuir an focal faire isteach chun an comhad PDF seo a oscailt. -pdfjs-password-invalid = Focal faire mícheart. Déan iarracht eile. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Cealaigh -pdfjs-web-fonts-disabled = Tá clófhoirne Gréasáin díchumasaithe: ní féidir clófhoirne leabaithe PDF a úsáid. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ga-IE/viewer.properties b/static/pdf.js/locale/ga-IE/viewer.properties new file mode 100644 index 00000000..7fa5076f --- /dev/null +++ b/static/pdf.js/locale/ga-IE/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=An Leathanach Roimhe Seo +previous_label=Roimhe Seo +next.title=An Chéad Leathanach Eile +next_label=Ar Aghaidh + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Leathanach: +page_of=as {{pageCount}} + +zoom_out.title=Súmáil Amach +zoom_out_label=Súmáil Amach +zoom_in.title=Súmáil Isteach +zoom_in_label=Súmáil Isteach +zoom.title=Súmáil +presentation_mode.title=Úsáid an Mód Láithreoireachta +presentation_mode_label=Mód Láithreoireachta +open_file.title=Oscail Comhad +open_file_label=Oscail +print.title=Priontáil +print_label=Priontáil +download.title=Íosluchtaigh +download_label=Íosluchtaigh +bookmark.title=An t-amharc reatha (cóipeáil nó oscail i bhfuinneog nua) +bookmark_label=An tAmharc Reatha + +# Secondary toolbar and context menu +tools.title=Uirlisí +tools_label=Uirlisí +first_page.title=Go dtí an chéad leathanach +first_page.label=Go dtí an chéad leathanach +first_page_label=Go dtí an chéad leathanach +last_page.title=Go dtí an leathanach deiridh +last_page.label=Go dtí an leathanach deiridh +last_page_label=Go dtí an leathanach deiridh +page_rotate_cw.title=Rothlaigh ar deiseal +page_rotate_cw.label=Rothlaigh ar deiseal +page_rotate_cw_label=Rothlaigh ar deiseal +page_rotate_ccw.title=Rothlaigh ar tuathal +page_rotate_ccw.label=Rothlaigh ar tuathal +page_rotate_ccw_label=Rothlaigh ar tuathal + +hand_tool_enable.title=Cumasaigh uirlis láimhe +hand_tool_enable_label=Cumasaigh uirlis láimhe +hand_tool_disable.title=Díchumasaigh uirlis láimhe +hand_tool_disable_label=Díchumasaigh uirlis láimhe + +# Document properties dialog box +document_properties.title=Airíonna na Cáipéise… +document_properties_label=Airíonna na Cáipéise… +document_properties_file_name=Ainm an chomhaid: +document_properties_file_size=Méid an chomhaid: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} kB ({{size_b}} beart) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} beart) +document_properties_title=Teideal: +document_properties_author=Údar: +document_properties_subject=Ábhar: +document_properties_keywords=Eochairfhocail: +document_properties_creation_date=Dáta Cruthaithe: +document_properties_modification_date=Dáta Athraithe: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Cruthaitheoir: +document_properties_producer=Cruthaitheoir an PDF: +document_properties_version=Leagan PDF: +document_properties_page_count=Líon Leathanach: +document_properties_close=Dún + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Scoránaigh an Barra Taoibh +toggle_sidebar_label=Scoránaigh an Barra Taoibh +outline.title=Taispeáin Creatlach na Cáipéise +outline_label=Creatlach na Cáipéise +attachments.title=Taispeáin Iatáin +attachments_label=Iatáin +thumbs.title=Taispeáin Mionsamhlacha +thumbs_label=Mionsamhlacha +findbar.title=Aimsigh sa Cháipéis +findbar_label=Aimsigh + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Leathanach {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Mionsamhail Leathanaigh {{page}} + +# Find panel button title and messages +find_label=Aimsigh: +find_previous.title=Aimsigh an sampla roimhe seo den nath seo +find_previous_label=Roimhe seo +find_next.title=Aimsigh an chéad sampla eile den nath sin +find_next_label=Ar aghaidh +find_highlight=Aibhsigh uile +find_match_case_label=Cásíogair +find_reached_top=Ag barr na cáipéise, ag leanúint ón mbun +find_reached_bottom=Ag bun na cáipéise, ag leanúint ón mbarr +find_not_found=Abairtín gan aimsiú + +# Error panel labels +error_more_info=Tuilleadh Eolais +error_less_info=Níos Lú Eolais +error_close=Dún +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Teachtaireacht: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Cruach: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Comhad: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Líne: {{line}} +rendering_error=Tharla earráid agus an leathanach á leagan amach. + +# Predefined zoom values +page_scale_width=Leithead Leathanaigh +page_scale_fit=Laghdaigh go dtí an Leathanach +page_scale_auto=Súmáil Uathoibríoch +page_scale_actual=Fíormhéid +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Earráid +loading_error=Tharla earráid agus an cháipéis PDF á luchtú. +invalid_file_error=Comhad neamhbhailí nó truaillithe PDF. +missing_file_error=Comhad PDF ar iarraidh. +unexpected_response_error=Freagra ón bhfreastalaí gan súil leis. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anótáil {{type}}] +password_label=Cuir an focal faire isteach chun an comhad PDF seo a oscailt. +password_invalid=Focal faire mícheart. Déan iarracht eile. +password_ok=OK +password_cancel=Cealaigh + +printing_not_supported=Rabhadh: Ní thacaíonn an brabhsálaí le priontáil go hiomlán. +printing_not_ready=Rabhadh: Ní féidir an PDF a phriontáil go dtí go mbeidh an cháipéis iomlán luchtaithe. +web_fonts_disabled=Tá clófhoirne Gréasáin díchumasaithe: ní féidir clófhoirne leabaithe PDF a úsáid. +document_colors_not_allowed=Níl cead ag cáipéisí PDF a ndathanna féin a roghnú; tá 'Tabhair cead do leathanaigh a ndathanna féin a roghnú' díchumasaithe sa mbrabhsálaí. diff --git a/static/pdf.js/locale/gd/viewer.ftl b/static/pdf.js/locale/gd/viewer.ftl deleted file mode 100644 index cc67391a..00000000 --- a/static/pdf.js/locale/gd/viewer.ftl +++ /dev/null @@ -1,299 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = An duilleag roimhe -pdfjs-previous-button-label = Air ais -pdfjs-next-button = - .title = An ath-dhuilleag -pdfjs-next-button-label = Air adhart -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Duilleag -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = à { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } à { $pagesCount }) -pdfjs-zoom-out-button = - .title = Sùm a-mach -pdfjs-zoom-out-button-label = Sùm a-mach -pdfjs-zoom-in-button = - .title = Sùm a-steach -pdfjs-zoom-in-button-label = Sùm a-steach -pdfjs-zoom-select = - .title = Sùm -pdfjs-presentation-mode-button = - .title = Gearr leum dhan mhodh taisbeanaidh -pdfjs-presentation-mode-button-label = Am modh taisbeanaidh -pdfjs-open-file-button = - .title = Fosgail faidhle -pdfjs-open-file-button-label = Fosgail -pdfjs-print-button = - .title = Clò-bhuail -pdfjs-print-button-label = Clò-bhuail -pdfjs-save-button = - .title = Sàbhail -pdfjs-save-button-label = Sàbhail -pdfjs-bookmark-button = - .title = An duilleag làithreach (Seall an URL on duilleag làithreach) -pdfjs-bookmark-button-label = An duilleag làithreach -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Fosgail san aplacaid -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Fosgail san aplacaid - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Innealan -pdfjs-tools-button-label = Innealan -pdfjs-first-page-button = - .title = Rach gun chiad duilleag -pdfjs-first-page-button-label = Rach gun chiad duilleag -pdfjs-last-page-button = - .title = Rach gun duilleag mu dheireadh -pdfjs-last-page-button-label = Rach gun duilleag mu dheireadh -pdfjs-page-rotate-cw-button = - .title = Cuairtich gu deiseil -pdfjs-page-rotate-cw-button-label = Cuairtich gu deiseil -pdfjs-page-rotate-ccw-button = - .title = Cuairtich gu tuathail -pdfjs-page-rotate-ccw-button-label = Cuairtich gu tuathail -pdfjs-cursor-text-select-tool-button = - .title = Cuir an comas inneal taghadh an teacsa -pdfjs-cursor-text-select-tool-button-label = Inneal taghadh an teacsa -pdfjs-cursor-hand-tool-button = - .title = Cuir inneal na làimhe an comas -pdfjs-cursor-hand-tool-button-label = Inneal na làimhe -pdfjs-scroll-page-button = - .title = Cleachd sgroladh duilleige -pdfjs-scroll-page-button-label = Sgroladh duilleige -pdfjs-scroll-vertical-button = - .title = Cleachd sgroladh inghearach -pdfjs-scroll-vertical-button-label = Sgroladh inghearach -pdfjs-scroll-horizontal-button = - .title = Cleachd sgroladh còmhnard -pdfjs-scroll-horizontal-button-label = Sgroladh còmhnard -pdfjs-scroll-wrapped-button = - .title = Cleachd sgroladh paisgte -pdfjs-scroll-wrapped-button-label = Sgroladh paisgte -pdfjs-spread-none-button = - .title = Na cuir còmhla sgoileadh dhuilleagan -pdfjs-spread-none-button-label = Gun sgaoileadh dhuilleagan -pdfjs-spread-odd-button = - .title = Cuir còmhla duilleagan sgaoilte a thòisicheas le duilleagan aig a bheil àireamh chorr -pdfjs-spread-odd-button-label = Sgaoileadh dhuilleagan corra -pdfjs-spread-even-button = - .title = Cuir còmhla duilleagan sgaoilte a thòisicheas le duilleagan aig a bheil àireamh chothrom -pdfjs-spread-even-button-label = Sgaoileadh dhuilleagan cothrom - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Roghainnean na sgrìobhainne… -pdfjs-document-properties-button-label = Roghainnean na sgrìobhainne… -pdfjs-document-properties-file-name = Ainm an fhaidhle: -pdfjs-document-properties-file-size = Meud an fhaidhle: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Tiotal: -pdfjs-document-properties-author = Ùghdar: -pdfjs-document-properties-subject = Cuspair: -pdfjs-document-properties-keywords = Faclan-luirg: -pdfjs-document-properties-creation-date = Latha a chruthachaidh: -pdfjs-document-properties-modification-date = Latha atharrachaidh: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Cruthadair: -pdfjs-document-properties-producer = Saothraiche a' PDF: -pdfjs-document-properties-version = Tionndadh a' PDF: -pdfjs-document-properties-page-count = Àireamh de dhuilleagan: -pdfjs-document-properties-page-size = Meud na duilleige: -pdfjs-document-properties-page-size-unit-inches = ann an -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portraid -pdfjs-document-properties-page-size-orientation-landscape = dreach-tìre -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Litir -pdfjs-document-properties-page-size-name-legal = Laghail - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Grad shealladh-lìn: -pdfjs-document-properties-linearized-yes = Tha -pdfjs-document-properties-linearized-no = Chan eil -pdfjs-document-properties-close-button = Dùin - -## Print - -pdfjs-print-progress-message = Ag ullachadh na sgrìobhainn airson clò-bhualadh… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Sguir dheth -pdfjs-printing-not-supported = Rabhadh: Chan eil am brabhsair seo a' cur làn-taic ri clò-bhualadh. -pdfjs-printing-not-ready = Rabhadh: Cha deach am PDF a luchdadh gu tur airson clò-bhualadh. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Toglaich am bàr-taoibh -pdfjs-toggle-sidebar-notification-button = - .title = Toglaich am bàr-taoibh (tha oir-loidhne/ceanglachain/breathan aig an sgrìobhainn) -pdfjs-toggle-sidebar-button-label = Toglaich am bàr-taoibh -pdfjs-document-outline-button = - .title = Seall oir-loidhne na sgrìobhainn (dèan briogadh dùbailte airson a h-uile nì a leudachadh/a cho-theannadh) -pdfjs-document-outline-button-label = Oir-loidhne na sgrìobhainne -pdfjs-attachments-button = - .title = Seall na ceanglachain -pdfjs-attachments-button-label = Ceanglachain -pdfjs-layers-button = - .title = Seall na breathan (dèan briogadh dùbailte airson a h-uile breath ath-shuidheachadh dhan staid bhunaiteach) -pdfjs-layers-button-label = Breathan -pdfjs-thumbs-button = - .title = Seall na dealbhagan -pdfjs-thumbs-button-label = Dealbhagan -pdfjs-current-outline-item-button = - .title = Lorg nì làithreach na h-oir-loidhne -pdfjs-current-outline-item-button-label = Nì làithreach na h-oir-loidhne -pdfjs-findbar-button = - .title = Lorg san sgrìobhainn -pdfjs-findbar-button-label = Lorg -pdfjs-additional-layers = Barrachd breathan - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Duilleag a { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Dealbhag duilleag a { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Lorg - .placeholder = Lorg san sgrìobhainn... -pdfjs-find-previous-button = - .title = Lorg làthair roimhe na h-abairt seo -pdfjs-find-previous-button-label = Air ais -pdfjs-find-next-button = - .title = Lorg ath-làthair na h-abairt seo -pdfjs-find-next-button-label = Air adhart -pdfjs-find-highlight-checkbox = Soillsich a h-uile -pdfjs-find-match-case-checkbox-label = Aire do litrichean mòra is beaga -pdfjs-find-match-diacritics-checkbox-label = Aire do stràcan -pdfjs-find-entire-word-checkbox-label = Faclan-slàna -pdfjs-find-reached-top = Ràinig sinn barr na duilleige, a' leantainn air adhart o bhonn na duilleige -pdfjs-find-reached-bottom = Ràinig sinn bonn na duilleige, a' leantainn air adhart o bharr na duilleige -pdfjs-find-not-found = Cha deach an abairt a lorg - -## Predefined zoom values - -pdfjs-page-scale-width = Leud na duilleige -pdfjs-page-scale-fit = Freagair ri meud na duilleige -pdfjs-page-scale-auto = Sùm fèin-obrachail -pdfjs-page-scale-actual = Am fìor-mheud -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Duilleag { $page } - -## Loading indicator messages - -pdfjs-loading-error = Thachair mearachd rè luchdadh a' PDF. -pdfjs-invalid-file-error = Faidhle PDF a tha mì-dhligheach no coirbte. -pdfjs-missing-file-error = Faidhle PDF a tha a dhìth. -pdfjs-unexpected-response-error = Freagairt on fhrithealaiche ris nach robh dùil. -pdfjs-rendering-error = Thachair mearachd rè reandaradh na duilleige. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Nòtachadh { $type }] - -## Password - -pdfjs-password-label = Cuir a-steach am facal-faire gus am faidhle PDF seo fhosgladh. -pdfjs-password-invalid = Tha am facal-faire cearr. Nach fheuch thu ris a-rithist? -pdfjs-password-ok-button = Ceart ma-thà -pdfjs-password-cancel-button = Sguir dheth -pdfjs-web-fonts-disabled = Tha cruthan-clò lìn à comas: Chan urrainn dhuinn cruthan-clò PDF leabaichte a chleachdadh. - -## Editing - -pdfjs-editor-free-text-button = - .title = Teacsa -pdfjs-editor-free-text-button-label = Teacsa -pdfjs-editor-ink-button = - .title = Tarraing -pdfjs-editor-ink-button-label = Tarraing -# Editor Parameters -pdfjs-editor-free-text-color-input = Dath -pdfjs-editor-free-text-size-input = Meud -pdfjs-editor-ink-color-input = Dath -pdfjs-editor-ink-thickness-input = Tighead -pdfjs-editor-ink-opacity-input = Trìd-dhoilleireachd -pdfjs-free-text = - .aria-label = An deasaiche teacsa -pdfjs-free-text-default-content = Tòisich air sgrìobhadh… -pdfjs-ink = - .aria-label = An deasaiche tharraingean -pdfjs-ink-canvas = - .aria-label = Dealbh a chruthaich cleachdaiche - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/gd/viewer.properties b/static/pdf.js/locale/gd/viewer.properties new file mode 100644 index 00000000..509b71b2 --- /dev/null +++ b/static/pdf.js/locale/gd/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=An duilleag roimhe +previous_label=Air ais +next.title=An ath-dhuilleag +next_label=Air adhart + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Duilleag: +page_of=à {{pageCount}} + +zoom_out.title=Sùm a-mach +zoom_out_label=Sùm a-mach +zoom_in.title=Sùm a-steach +zoom_in_label=Sùm a-steach +zoom.title=Sùm +presentation_mode.title=Gearr leum dhan mhodh taisbeanaidh +presentation_mode_label=Am modh taisbeanaidh +open_file.title=Fosgail faidhle +open_file_label=Fosgail +print.title=Clò-bhuail +print_label=Clò-bhuail +download.title=Luchdaich a-nuas +download_label=Luchdaich a-nuas +bookmark.title=An sealladh làithreach (dèan lethbhreac no fosgail e ann an uinneag ùr) +bookmark_label=An sealladh làithreach + +# Secondary toolbar and context menu +tools.title=Innealan +tools_label=Innealan +first_page.title=Rach gun chiad duilleag +first_page.label=Rach gun chiad duilleag +first_page_label=Rach gun chiad duilleag +last_page.title=Rach gun duilleag mu dheireadh +last_page.label=Rach gun duilleag mu dheireadh +last_page_label=Rach gun duilleag mu dheireadh +page_rotate_cw.title=Cuairtich gu deiseil +page_rotate_cw.label=Cuairtich gu deiseil +page_rotate_cw_label=Cuairtich gu deiseil +page_rotate_ccw.title=Cuairtich gu tuathail +page_rotate_ccw.label=Cuairtich gu tuathail +page_rotate_ccw_label=Cuairtich gu tuathail + +hand_tool_enable.title=Cuir inneal na làimhe an comas +hand_tool_enable_label=Cuir inneal na làimhe an comas +hand_tool_disable.title=Cuir inneal na làimhe à comas +hand_tool_disable_label=Cuir à comas inneal na làimhe + +# Document properties dialog box +document_properties.title=Roghainnean na sgrìobhainne… +document_properties_label=Roghainnean na sgrìobhainne… +document_properties_file_name=Ainm an fhaidhle: +document_properties_file_size=Meud an fhaidhle: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Tiotal: +document_properties_author=Ùghdar: +document_properties_subject=Cuspair: +document_properties_keywords=Faclan-luirg: +document_properties_creation_date=Latha a chruthachaidh: +document_properties_modification_date=Latha atharrachaidh: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Cruthadair: +document_properties_producer=Saothraiche a' PDF: +document_properties_version=Tionndadh a' PDF: +document_properties_page_count=Àireamh de dhuilleagan: +document_properties_close=Dùin + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Toglaich am bàr-taoibh +toggle_sidebar_label=Toglaich am bàr-taoibh +outline.title=Seall an sgrìobhainn far loidhne +outline_label=Oir-loidhne na sgrìobhainne +attachments.title=Seall na ceanglachain +attachments_label=Ceanglachain +thumbs.title=Seall na dealbhagan +thumbs_label=Dealbhagan +findbar.title=Lorg san sgrìobhainn +findbar_label=Lorg + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Duilleag a {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Dealbhag duilleag a {{page}} + +# Find panel button title and messages +find_label=Lorg: +find_previous.title=Lorg làthair roimhe na h-abairt seo +find_previous_label=Air ais +find_next.title=Lorg ath-làthair na h-abairt seo +find_next_label=Air adhart +find_highlight=Soillsich a h-uile +find_match_case_label=Aire do litrichean mòra is beaga +find_reached_top=Ràinig sinn barr na duilleige, a' leantainn air adhart o bhonn na duilleige +find_reached_bottom=Ràinig sinn bonn na duilleige, a' leantainn air adhart o bharr na duilleige +find_not_found=Cha deach an abairt a lorg + +# Error panel labels +error_more_info=Barrachd fiosrachaidh +error_less_info=Nas lugha de dh'fhiosrachadh +error_close=Dùin +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Teachdaireachd: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stac: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Faidhle: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Loidhne: {{line}} +rendering_error=Thachair mearachd rè reandaradh na duilleige. + +# Predefined zoom values +page_scale_width=Leud na duilleige +page_scale_fit=Freagair ri meud na duilleige +page_scale_auto=Sùm fèin-obrachail +page_scale_actual=Am fìor-mheud +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Mearachd +loading_error=Thachair mearachd rè luchdadh a' PDF. +invalid_file_error=Faidhle PDF a tha mì-dhligheach no coirbte. +missing_file_error=Faidhle PDF a tha a dhìth. +unexpected_response_error=Freagairt on fhrithealaiche ris nach robh dùil. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Nòtachadh {{type}}] +password_label=Cuir a-steach am facal-faire gus am faidhle PDF seo fhosgladh. +password_invalid=Tha am facal-faire cearr. Nach fheuch thu ris a-rithist? +password_ok=Ceart ma-tha +password_cancel=Sguir dheth + +printing_not_supported=Rabhadh: Chan eil am brabhsair seo a' cur làn-taic ri clò-bhualadh. +printing_not_ready=Rabhadh: Cha deach am PDF a luchdadh gu tur airson clò-bhualadh. +web_fonts_disabled=Tha cruthan-clò lìn à comas: Chan urrainn dhuinn cruthan-clò PDF leabaichte a chleachdadh. +document_colors_not_allowed=Chan fhaod sgrìobhainnean PDF na dathan aca fhèin a chleachdadh: Tha "Leig le duilleagan na dathan aca fhèin a chleachdadh" à comas sa bhrabhsair. diff --git a/static/pdf.js/locale/gl/viewer.ftl b/static/pdf.js/locale/gl/viewer.ftl deleted file mode 100644 index a08fb1a3..00000000 --- a/static/pdf.js/locale/gl/viewer.ftl +++ /dev/null @@ -1,364 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Páxina anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Seguinte páxina -pdfjs-next-button-label = Seguinte -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Páxina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Reducir -pdfjs-zoom-out-button-label = Reducir -pdfjs-zoom-in-button = - .title = Ampliar -pdfjs-zoom-in-button-label = Ampliar -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Cambiar ao modo presentación -pdfjs-presentation-mode-button-label = Modo presentación -pdfjs-open-file-button = - .title = Abrir ficheiro -pdfjs-open-file-button-label = Abrir -pdfjs-print-button = - .title = Imprimir -pdfjs-print-button-label = Imprimir -pdfjs-save-button = - .title = Gardar -pdfjs-save-button-label = Gardar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Descargar -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Descargar -pdfjs-bookmark-button = - .title = Páxina actual (ver o URL da páxina actual) -pdfjs-bookmark-button-label = Páxina actual -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Abrir cunha aplicación -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Abrir cunha aplicación - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Ferramentas -pdfjs-tools-button-label = Ferramentas -pdfjs-first-page-button = - .title = Ir á primeira páxina -pdfjs-first-page-button-label = Ir á primeira páxina -pdfjs-last-page-button = - .title = Ir á última páxina -pdfjs-last-page-button-label = Ir á última páxina -pdfjs-page-rotate-cw-button = - .title = Rotar no sentido das agullas do reloxo -pdfjs-page-rotate-cw-button-label = Rotar no sentido das agullas do reloxo -pdfjs-page-rotate-ccw-button = - .title = Rotar no sentido contrario ás agullas do reloxo -pdfjs-page-rotate-ccw-button-label = Rotar no sentido contrario ás agullas do reloxo -pdfjs-cursor-text-select-tool-button = - .title = Activar a ferramenta de selección de texto -pdfjs-cursor-text-select-tool-button-label = Ferramenta de selección de texto -pdfjs-cursor-hand-tool-button = - .title = Activar a ferramenta de man -pdfjs-cursor-hand-tool-button-label = Ferramenta de man -pdfjs-scroll-page-button = - .title = Usar o desprazamento da páxina -pdfjs-scroll-page-button-label = Desprazamento da páxina -pdfjs-scroll-vertical-button = - .title = Usar o desprazamento vertical -pdfjs-scroll-vertical-button-label = Desprazamento vertical -pdfjs-scroll-horizontal-button = - .title = Usar o desprazamento horizontal -pdfjs-scroll-horizontal-button-label = Desprazamento horizontal -pdfjs-scroll-wrapped-button = - .title = Usar o desprazamento en bloque -pdfjs-scroll-wrapped-button-label = Desprazamento por bloque -pdfjs-spread-none-button = - .title = Non agrupar páxinas -pdfjs-spread-none-button-label = Ningún agrupamento -pdfjs-spread-odd-button = - .title = Crea grupo de páxinas que comezan con números de páxina impares -pdfjs-spread-odd-button-label = Agrupamento impar -pdfjs-spread-even-button = - .title = Crea grupo de páxinas que comezan con números de páxina pares -pdfjs-spread-even-button-label = Agrupamento par - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propiedades do documento… -pdfjs-document-properties-button-label = Propiedades do documento… -pdfjs-document-properties-file-name = Nome do ficheiro: -pdfjs-document-properties-file-size = Tamaño do ficheiro: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Título: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Asunto: -pdfjs-document-properties-keywords = Palabras clave: -pdfjs-document-properties-creation-date = Data de creación: -pdfjs-document-properties-modification-date = Data de modificación: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creado por: -pdfjs-document-properties-producer = Xenerador do PDF: -pdfjs-document-properties-version = Versión de PDF: -pdfjs-document-properties-page-count = Número de páxinas: -pdfjs-document-properties-page-size = Tamaño da páxina: -pdfjs-document-properties-page-size-unit-inches = pol -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = horizontal -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Visualización rápida das páxinas web: -pdfjs-document-properties-linearized-yes = Si -pdfjs-document-properties-linearized-no = Non -pdfjs-document-properties-close-button = Pechar - -## Print - -pdfjs-print-progress-message = Preparando o documento para imprimir… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancelar -pdfjs-printing-not-supported = Aviso: A impresión non é compatíbel de todo con este navegador. -pdfjs-printing-not-ready = Aviso: O PDF non se cargou completamente para imprimirse. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Amosar/agochar a barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Alternar barra lateral (o documento contén esquema/anexos/capas) -pdfjs-toggle-sidebar-button-label = Amosar/agochar a barra lateral -pdfjs-document-outline-button = - .title = Amosar a estrutura do documento (dobre clic para expandir/contraer todos os elementos) -pdfjs-document-outline-button-label = Estrutura do documento -pdfjs-attachments-button = - .title = Amosar anexos -pdfjs-attachments-button-label = Anexos -pdfjs-layers-button = - .title = Mostrar capas (prema dúas veces para restaurar todas as capas o estado predeterminado) -pdfjs-layers-button-label = Capas -pdfjs-thumbs-button = - .title = Amosar miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Atopar o elemento delimitado actualmente -pdfjs-current-outline-item-button-label = Elemento delimitado actualmente -pdfjs-findbar-button = - .title = Atopar no documento -pdfjs-findbar-button-label = Atopar -pdfjs-additional-layers = Capas adicionais - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Páxina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura da páxina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Atopar - .placeholder = Atopar no documento… -pdfjs-find-previous-button = - .title = Atopar a anterior aparición da frase -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button = - .title = Atopar a seguinte aparición da frase -pdfjs-find-next-button-label = Seguinte -pdfjs-find-highlight-checkbox = Realzar todo -pdfjs-find-match-case-checkbox-label = Diferenciar maiúsculas de minúsculas -pdfjs-find-match-diacritics-checkbox-label = Distinguir os diacríticos -pdfjs-find-entire-word-checkbox-label = Palabras completas -pdfjs-find-reached-top = Chegouse ao inicio do documento, continuar desde o final -pdfjs-find-reached-bottom = Chegouse ao final do documento, continuar desde o inicio -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] Coincidencia { $current } de { $total } - *[other] Coincidencia { $current } de { $total } - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Máis de { $limit } coincidencia - *[other] Máis de { $limit } coincidencias - } -pdfjs-find-not-found = Non se atopou a frase - -## Predefined zoom values - -pdfjs-page-scale-width = Largura da páxina -pdfjs-page-scale-fit = Axuste de páxina -pdfjs-page-scale-auto = Zoom automático -pdfjs-page-scale-actual = Tamaño actual -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Páxina { $page } - -## Loading indicator messages - -pdfjs-loading-error = Produciuse un erro ao cargar o PDF. -pdfjs-invalid-file-error = Ficheiro PDF danado ou non válido. -pdfjs-missing-file-error = Falta o ficheiro PDF. -pdfjs-unexpected-response-error = Resposta inesperada do servidor. -pdfjs-rendering-error = Produciuse un erro ao representar a páxina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotación { $type }] - -## Password - -pdfjs-password-label = Escriba o contrasinal para abrir este ficheiro PDF. -pdfjs-password-invalid = Contrasinal incorrecto. Tente de novo. -pdfjs-password-ok-button = Aceptar -pdfjs-password-cancel-button = Cancelar -pdfjs-web-fonts-disabled = Desactiváronse as fontes web: foi imposíbel usar as fontes incrustadas no PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texto -pdfjs-editor-free-text-button-label = Texto -pdfjs-editor-ink-button = - .title = Debuxo -pdfjs-editor-ink-button-label = Debuxo -pdfjs-editor-stamp-button = - .title = Engadir ou editar imaxes -pdfjs-editor-stamp-button-label = Engadir ou editar imaxes - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-freetext-button = - .title = Eliminar o texto -pdfjs-editor-remove-stamp-button = - .title = Eliminar a imaxe -pdfjs-editor-remove-highlight-button = - .title = Eliminar o resaltado - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Cor -pdfjs-editor-free-text-size-input = Tamaño -pdfjs-editor-ink-color-input = Cor -pdfjs-editor-ink-thickness-input = Grosor -pdfjs-editor-ink-opacity-input = Opacidade -pdfjs-editor-stamp-add-image-button = - .title = Engadir imaxe -pdfjs-editor-stamp-add-image-button-label = Engadir imaxe -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Grosor -pdfjs-free-text = - .aria-label = Editor de texto -pdfjs-free-text-default-content = Comezar a teclear… -pdfjs-ink = - .aria-label = Editor de debuxos -pdfjs-ink-canvas = - .aria-label = Imaxe creada por unha usuaria - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Texto alternativo -pdfjs-editor-alt-text-edit-button-label = Editar o texto alternativo -pdfjs-editor-alt-text-dialog-label = Escoller unha opción -pdfjs-editor-alt-text-add-description-label = Engadir unha descrición -pdfjs-editor-alt-text-mark-decorative-label = Marcar como decorativo -pdfjs-editor-alt-text-mark-decorative-description = Utilízase para imaxes ornamentais, como bordos ou marcas de auga. -pdfjs-editor-alt-text-cancel-button = Cancelar -pdfjs-editor-alt-text-save-button = Gardar -pdfjs-editor-alt-text-decorative-tooltip = Marcado como decorativo -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Por exemplo, «Un mozo séntase á mesa para comer» - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Esquina superior esquerda: cambia o tamaño -pdfjs-editor-resizer-label-top-middle = Medio superior: cambia o tamaño -pdfjs-editor-resizer-label-top-right = Esquina superior dereita: cambia o tamaño -pdfjs-editor-resizer-label-middle-right = Medio dereito: cambia o tamaño -pdfjs-editor-resizer-label-bottom-right = Esquina inferior dereita: cambia o tamaño -pdfjs-editor-resizer-label-bottom-middle = Abaixo medio: cambia o tamaño -pdfjs-editor-resizer-label-bottom-left = Esquina inferior esquerda: cambia o tamaño -pdfjs-editor-resizer-label-middle-left = Medio esquerdo: cambia o tamaño - -## Color picker - diff --git a/static/pdf.js/locale/gl/viewer.properties b/static/pdf.js/locale/gl/viewer.properties new file mode 100644 index 00000000..0acc4f78 --- /dev/null +++ b/static/pdf.js/locale/gl/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Páxina anterior +previous_label=Anterior +next.title=Seguinte páxina +next_label=Seguinte + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Páxina: +page_of=de {{pageCount}} + +zoom_out.title=Reducir +zoom_out_label=Reducir +zoom_in.title=Ampliar +zoom_in_label=Ampliar +zoom.title=Zoom +presentation_mode.title=Cambiar ao modo presentación +presentation_mode_label=Modo presentación +open_file.title=Abrir ficheiro +open_file_label=Abrir +print.title=Imprimir +print_label=Imprimir +download.title=Descargar +download_label=Descargar +bookmark.title=Vista actual (copiar ou abrir nunha nova xanela) +bookmark_label=Vista actual + +# Secondary toolbar and context menu +tools.title=Ferramentas +tools_label=Ferramentas +first_page.title=Ir á primeira páxina +first_page.label=Ir á primeira páxina +first_page_label=Ir á primeira páxina +last_page.title=Ir á última páxina +last_page.label=Ir á última páxina +last_page_label=Ir á última páxina +page_rotate_cw.title=Rotar no sentido das agullas do reloxo +page_rotate_cw.label=Rotar no sentido das agullas do reloxo +page_rotate_cw_label=Rotar no sentido das agullas do reloxo +page_rotate_ccw.title=Rotar no sentido contrario ás agullas do reloxo +page_rotate_ccw.label=Rotar no sentido contrario ás agullas do reloxo +page_rotate_ccw_label=Rotar no sentido contrario ás agullas do reloxo + +hand_tool_enable.title=Activar ferramenta man +hand_tool_enable_label=Activar ferramenta man +hand_tool_disable.title=Desactivar ferramenta man +hand_tool_disable_label=Desactivar ferramenta man + +# Document properties dialog box +document_properties.title=Propiedades do documento… +document_properties_label=Propiedades do documento… +document_properties_file_name=Nome do ficheiro: +document_properties_file_size=Tamaño do ficheiro: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Título: +document_properties_author=Autor: +document_properties_subject=Asunto: +document_properties_keywords=Palabras clave: +document_properties_creation_date=Data de creación: +document_properties_modification_date=Data de modificación: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creado por: +document_properties_producer=Xenerador do PDF: +document_properties_version=Versión de PDF: +document_properties_page_count=Número de páxinas: +document_properties_close=Pechar + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Amosar/agochar a barra lateral +toggle_sidebar_label=Amosar/agochar a barra lateral +outline.title=Amosar esquema do documento +outline_label=Esquema do documento +attachments.title=Amosar anexos +attachments_label=Anexos +thumbs.title=Amosar miniaturas +thumbs_label=Miniaturas +findbar.title=Atopar no documento +findbar_label=Atopar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Páxina {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura da páxina {{page}} + +# Find panel button title and messages +find_label=Atopar: +find_previous.title=Atopar a anterior aparición da frase +find_previous_label=Anterior +find_next.title=Atopar a seguinte aparición da frase +find_next_label=Seguinte +find_highlight=Realzar todo +find_match_case_label=Diferenciar maiúsculas de minúsculas +find_reached_top=Chegouse ao inicio do documento, continuar desde o final +find_reached_bottom=Chegouse ao final do documento, continuar desde o inicio +find_not_found=Non se atopou a frase + +# Error panel labels +error_more_info=Máis información +error_less_info=Menos información +error_close=Pechar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (Identificador da compilación: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mensaxe: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pila: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Ficheiro: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Liña: {{line}} +rendering_error=Produciuse un erro ao representar a páxina. + +# Predefined zoom values +page_scale_width=Largura da páxina +page_scale_fit=Axuste de páxina +page_scale_auto=Zoom automático +page_scale_actual=Tamaño actual +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Erro +loading_error=Produciuse un erro ao cargar o PDF. +invalid_file_error=Ficheiro PDF danado ou incorrecto. +missing_file_error=Falta o ficheiro PDF. +unexpected_response_error=Resposta inesperada do servidor. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotación {{type}}] +password_label=Escriba o contrasinal para abrir este ficheiro PDF. +password_invalid=Contrasinal incorrecto. Tente de novo. +password_ok=Aceptar +password_cancel=Cancelar + +printing_not_supported=Aviso: A impresión non é compatíbel de todo con este navegador. +printing_not_ready=Aviso: O PDF non se cargou completamente para imprimirse. +web_fonts_disabled=Desactiváronse as fontes web: foi imposíbel usar as fontes incrustadas no PDF. +document_colors_disabled=Non se permite que os documentos PDF usen as súas propias cores: «Permitir que as páxinas escollan as súas propias cores» está desactivado no navegador. diff --git a/static/pdf.js/locale/gn/viewer.ftl b/static/pdf.js/locale/gn/viewer.ftl deleted file mode 100644 index 29ec18ae..00000000 --- a/static/pdf.js/locale/gn/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Kuatiarogue mboyvegua -pdfjs-previous-button-label = Mboyvegua -pdfjs-next-button = - .title = Kuatiarogue upeigua -pdfjs-next-button-label = Upeigua -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Kuatiarogue -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } gui -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } of { $pagesCount }) -pdfjs-zoom-out-button = - .title = Momichĩ -pdfjs-zoom-out-button-label = Momichĩ -pdfjs-zoom-in-button = - .title = Mbotuicha -pdfjs-zoom-in-button-label = Mbotuicha -pdfjs-zoom-select = - .title = Tuichakue -pdfjs-presentation-mode-button = - .title = Jehechauka reko moambue -pdfjs-presentation-mode-button-label = Jehechauka reko -pdfjs-open-file-button = - .title = Marandurendápe jeike -pdfjs-open-file-button-label = Jeike -pdfjs-print-button = - .title = Monguatia -pdfjs-print-button-label = Monguatia -pdfjs-save-button = - .title = Ñongatu -pdfjs-save-button-label = Ñongatu -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Mboguejy -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Mboguejy -pdfjs-bookmark-button = - .title = Kuatiarogue ag̃agua (Ehecha URL kuatiarogue ag̃agua) -pdfjs-bookmark-button-label = Kuatiarogue Ag̃agua -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Embojuruja tembiporu’ípe -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Embojuruja tembiporu’ípe - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tembiporu -pdfjs-tools-button-label = Tembiporu -pdfjs-first-page-button = - .title = Kuatiarogue ñepyrũme jeho -pdfjs-first-page-button-label = Kuatiarogue ñepyrũme jeho -pdfjs-last-page-button = - .title = Kuatiarogue pahápe jeho -pdfjs-last-page-button-label = Kuatiarogue pahápe jeho -pdfjs-page-rotate-cw-button = - .title = Aravóicha mbojere -pdfjs-page-rotate-cw-button-label = Aravóicha mbojere -pdfjs-page-rotate-ccw-button = - .title = Aravo rapykue gotyo mbojere -pdfjs-page-rotate-ccw-button-label = Aravo rapykue gotyo mbojere -pdfjs-cursor-text-select-tool-button = - .title = Emyandy moñe’ẽrã jeporavo rembiporu -pdfjs-cursor-text-select-tool-button-label = Moñe’ẽrã jeporavo rembiporu -pdfjs-cursor-hand-tool-button = - .title = Tembiporu po pegua myandy -pdfjs-cursor-hand-tool-button-label = Tembiporu po pegua -pdfjs-scroll-page-button = - .title = Eiporu kuatiarogue jeku’e -pdfjs-scroll-page-button-label = Kuatiarogue jeku’e -pdfjs-scroll-vertical-button = - .title = Eiporu jeku’e ykeguáva -pdfjs-scroll-vertical-button-label = Jeku’e ykeguáva -pdfjs-scroll-horizontal-button = - .title = Eiporu jeku’e yvate gotyo -pdfjs-scroll-horizontal-button-label = Jeku’e yvate gotyo -pdfjs-scroll-wrapped-button = - .title = Eiporu jeku’e mbohyrupyre -pdfjs-scroll-wrapped-button-label = Jeku’e mbohyrupyre -pdfjs-spread-none-button = - .title = Ani ejuaju spreads kuatiarogue ndive -pdfjs-spread-none-button-label = Spreads ỹre -pdfjs-spread-odd-button = - .title = Embojuaju kuatiarogue jepysokue eñepyrũvo kuatiarogue impar-vagui -pdfjs-spread-odd-button-label = Spreads impar -pdfjs-spread-even-button = - .title = Embojuaju kuatiarogue jepysokue eñepyrũvo kuatiarogue par-vagui -pdfjs-spread-even-button-label = Ipukuve uvei - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Kuatia mba’etee… -pdfjs-document-properties-button-label = Kuatia mba’etee… -pdfjs-document-properties-file-name = Marandurenda réra: -pdfjs-document-properties-file-size = Marandurenda tuichakue: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Teratee: -pdfjs-document-properties-author = Apohára: -pdfjs-document-properties-subject = Mba’egua: -pdfjs-document-properties-keywords = Jehero: -pdfjs-document-properties-creation-date = Teñoihague arange: -pdfjs-document-properties-modification-date = Iñambue hague arange: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Apo’ypyha: -pdfjs-document-properties-producer = PDF mbosako’iha: -pdfjs-document-properties-version = PDF mbojuehegua: -pdfjs-document-properties-page-count = Kuatiarogue papapy: -pdfjs-document-properties-page-size = Kuatiarogue tuichakue: -pdfjs-document-properties-page-size-unit-inches = Amo -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = Oĩháicha -pdfjs-document-properties-page-size-orientation-landscape = apaisado -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Kuatiañe’ẽ -pdfjs-document-properties-page-size-name-legal = Tee - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Ñanduti jahecha pya’e: -pdfjs-document-properties-linearized-yes = Añete -pdfjs-document-properties-linearized-no = Ahániri -pdfjs-document-properties-close-button = Mboty - -## Print - -pdfjs-print-progress-message = Embosako’i kuatia emonguatia hag̃ua… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Heja -pdfjs-printing-not-supported = Kyhyjerã: Ñembokuatia ndojokupytypái ko kundahára ndive. -pdfjs-printing-not-ready = Kyhyjerã: Ko PDF nahenyhẽmbái oñembokuatia hag̃uáicha. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Tenda yke moambue -pdfjs-toggle-sidebar-notification-button = - .title = Embojopyru tenda ykegua (kuatia oguereko kuaakaha/moirũha/ñuãha) -pdfjs-toggle-sidebar-button-label = Tenda yke moambue -pdfjs-document-outline-button = - .title = Ehechauka kuatia rape (eikutu mokõi jey embotuicha/emomichĩ hag̃ua opavavete mba’eporu) -pdfjs-document-outline-button-label = Kuatia apopyre -pdfjs-attachments-button = - .title = Moirũha jehechauka -pdfjs-attachments-button-label = Moirũha -pdfjs-layers-button = - .title = Ehechauka ñuãha (eikutu jo’a emomba’apo hag̃ua opaite ñuãha tekoypýpe) -pdfjs-layers-button-label = Ñuãha -pdfjs-thumbs-button = - .title = Mba’emirĩ jehechauka -pdfjs-thumbs-button-label = Mba’emirĩ -pdfjs-current-outline-item-button = - .title = Eheka mba’eporu ag̃aguaitéva -pdfjs-current-outline-item-button-label = Mba’eporu ag̃aguaitéva -pdfjs-findbar-button = - .title = Kuatiápe jeheka -pdfjs-findbar-button-label = Juhu -pdfjs-additional-layers = Ñuãha moirũguáva - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Kuatiarogue { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Kuatiarogue mba’emirĩ { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Juhu - .placeholder = Kuatiápe jejuhu… -pdfjs-find-previous-button = - .title = Ejuhu ñe’ẽrysýi osẽ’ypy hague -pdfjs-find-previous-button-label = Mboyvegua -pdfjs-find-next-button = - .title = Eho ñe’ẽ juhupyre upeiguávape -pdfjs-find-next-button-label = Upeigua -pdfjs-find-highlight-checkbox = Embojekuaavepa -pdfjs-find-match-case-checkbox-label = Ejesareko taiguasu/taimichĩre -pdfjs-find-match-diacritics-checkbox-label = Diacrítico moñondive -pdfjs-find-entire-word-checkbox-label = Ñe’ẽ oĩmbáva -pdfjs-find-reached-top = Ojehupyty kuatia ñepyrũ, oku’ejeýta kuatia paha guive -pdfjs-find-reached-bottom = Ojehupyty kuatia paha, oku’ejeýta kuatia ñepyrũ guive -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } ha { $total } ojueheguáva - *[other] { $current } ha { $total } ojueheguáva - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Hetave { $limit } ojueheguáva - *[other] Hetave { $limit } ojueheguáva - } -pdfjs-find-not-found = Ñe’ẽrysýi ojejuhu’ỹva - -## Predefined zoom values - -pdfjs-page-scale-width = Kuatiarogue pekue -pdfjs-page-scale-fit = Kuatiarogue ñemoĩporã -pdfjs-page-scale-auto = Tuichakue ijeheguíva -pdfjs-page-scale-actual = Tuichakue ag̃agua -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Kuatiarogue { $page } - -## Loading indicator messages - -pdfjs-loading-error = Oiko jejavy PDF oñemyeñyhẽnguévo. -pdfjs-invalid-file-error = PDF marandurenda ndoikóiva térã ivaipyréva. -pdfjs-missing-file-error = Ndaipóri PDF marandurenda -pdfjs-unexpected-response-error = Mohendahavusu mbohovái eha’ãrõ’ỹva. -pdfjs-rendering-error = Oiko jejavy ehechaukasévo kuatiarogue. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Jehaipy { $type }] - -## Password - -pdfjs-password-label = Emoinge ñe’ẽñemi eipe’a hag̃ua ko marandurenda PDF. -pdfjs-password-invalid = Ñe’ẽñemi ndoikóiva. Eha’ã jey. -pdfjs-password-ok-button = MONEĨ -pdfjs-password-cancel-button = Heja -pdfjs-web-fonts-disabled = Ñanduti taity oñemongéma: ndaikatumo’ãi eiporu PDF jehai’íva taity. - -## Editing - -pdfjs-editor-free-text-button = - .title = Moñe’ẽrã -pdfjs-editor-free-text-button-label = Moñe’ẽrã -pdfjs-editor-ink-button = - .title = Moha’ãnga -pdfjs-editor-ink-button-label = Moha’ãnga -pdfjs-editor-stamp-button = - .title = Embojuaju térã embosako’i ta’ãnga -pdfjs-editor-stamp-button-label = Embojuaju térã embosako’i ta’ãnga -pdfjs-editor-highlight-button = - .title = Mbosa’y -pdfjs-editor-highlight-button-label = Mbosa’y -pdfjs-highlight-floating-button = - .title = Mbosa’y -pdfjs-highlight-floating-button1 = - .title = Mbosa’y - .aria-label = Mbosa’y -pdfjs-highlight-floating-button-label = Mbosa’y - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Emboguete ta’ãnga -pdfjs-editor-remove-freetext-button = - .title = Emboguete moñe’ẽrã -pdfjs-editor-remove-stamp-button = - .title = Emboguete ta’ãnga -pdfjs-editor-remove-highlight-button = - .title = Eipe’a jehechaveha - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Sa’y -pdfjs-editor-free-text-size-input = Tuichakue -pdfjs-editor-ink-color-input = Sa’y -pdfjs-editor-ink-thickness-input = Anambusu -pdfjs-editor-ink-opacity-input = Pytũngy -pdfjs-editor-stamp-add-image-button = - .title = Embojuaju ta’ãnga -pdfjs-editor-stamp-add-image-button-label = Embojuaju ta’ãnga -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Anambusu -pdfjs-editor-free-highlight-thickness-title = - .title = Emoambue anambusukue embosa’ývo mba’eporu ha’e’ỹva moñe’ẽrã -pdfjs-free-text = - .aria-label = Moñe’ẽrã moheñoiha -pdfjs-free-text-default-content = Ehai ñepyrũ… -pdfjs-ink = - .aria-label = Ta’ãnga moheñoiha -pdfjs-ink-canvas = - .aria-label = Ta’ãnga omoheñóiva poruhára - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Moñe’ẽrã mokõiháva -pdfjs-editor-alt-text-edit-button-label = Embojuruja moñe’ẽrã mokõiháva -pdfjs-editor-alt-text-dialog-label = Eiporavo poravorã -pdfjs-editor-alt-text-dialog-description = Moñe’ẽrã ykepegua (moñe’ẽrã ykepegua) nepytyvõ nderehecháiramo ta’ãnga térã nahenyhẽiramo. -pdfjs-editor-alt-text-add-description-label = Embojuaju ñemoha’ãnga -pdfjs-editor-alt-text-add-description-description = Ehaimi 1 térã 2 ñe’ẽjuaju oñe’ẽva pe téma rehe, ijere térã mba’eapóre. -pdfjs-editor-alt-text-mark-decorative-label = Emongurusu jeguakárõ -pdfjs-editor-alt-text-mark-decorative-description = Ojeporu ta’ãnga jeguakarã, tembe’y térã ta’ãnga ruguarãramo. -pdfjs-editor-alt-text-cancel-button = Heja -pdfjs-editor-alt-text-save-button = Ñongatu -pdfjs-editor-alt-text-decorative-tooltip = Jeguakárõ mongurusupyre -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Techapyrã: “Peteĩ mitãrusu oguapy mesápe okaru hag̃ua” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Yvate asu gotyo — emoambue tuichakue -pdfjs-editor-resizer-label-top-middle = Yvate mbytépe — emoambue tuichakue -pdfjs-editor-resizer-label-top-right = Yvate akatúape — emoambue tuichakue -pdfjs-editor-resizer-label-middle-right = Mbyte akatúape — emoambue tuichakue -pdfjs-editor-resizer-label-bottom-right = Yvy gotyo akatúape — emoambue tuichakue -pdfjs-editor-resizer-label-bottom-middle = Yvy gotyo mbytépe — emoambue tuichakue -pdfjs-editor-resizer-label-bottom-left = Iguýpe asu gotyo — emoambue tuichakue -pdfjs-editor-resizer-label-middle-left = Mbyte asu gotyo — emoambue tuichakue - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Jehechaveha sa’y -pdfjs-editor-colorpicker-button = - .title = Emoambue sa’y -pdfjs-editor-colorpicker-dropdown = - .aria-label = Sa’y poravopyrã -pdfjs-editor-colorpicker-yellow = - .title = Sa’yju -pdfjs-editor-colorpicker-green = - .title = Hovyũ -pdfjs-editor-colorpicker-blue = - .title = Hovy -pdfjs-editor-colorpicker-pink = - .title = Pytãngy -pdfjs-editor-colorpicker-red = - .title = Pyha - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Techaukapa -pdfjs-editor-highlight-show-all-button = - .title = Techaukapa diff --git a/static/pdf.js/locale/gu-IN/viewer.ftl b/static/pdf.js/locale/gu-IN/viewer.ftl deleted file mode 100644 index 5d8bb549..00000000 --- a/static/pdf.js/locale/gu-IN/viewer.ftl +++ /dev/null @@ -1,247 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = પહેલાનુ પાનું -pdfjs-previous-button-label = પહેલાનુ -pdfjs-next-button = - .title = આગળનુ પાનું -pdfjs-next-button-label = આગળનું -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = પાનું -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = નો { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } નો { $pagesCount }) -pdfjs-zoom-out-button = - .title = મોટુ કરો -pdfjs-zoom-out-button-label = મોટુ કરો -pdfjs-zoom-in-button = - .title = નાનું કરો -pdfjs-zoom-in-button-label = નાનું કરો -pdfjs-zoom-select = - .title = નાનું મોટુ કરો -pdfjs-presentation-mode-button = - .title = રજૂઆત સ્થિતિમાં જાવ -pdfjs-presentation-mode-button-label = રજૂઆત સ્થિતિ -pdfjs-open-file-button = - .title = ફાઇલ ખોલો -pdfjs-open-file-button-label = ખોલો -pdfjs-print-button = - .title = છાપો -pdfjs-print-button-label = છારો - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = સાધનો -pdfjs-tools-button-label = સાધનો -pdfjs-first-page-button = - .title = પહેલાં પાનામાં જાવ -pdfjs-first-page-button-label = પ્રથમ પાનાં પર જાવ -pdfjs-last-page-button = - .title = છેલ્લા પાનાં પર જાવ -pdfjs-last-page-button-label = છેલ્લા પાનાં પર જાવ -pdfjs-page-rotate-cw-button = - .title = ઘડિયાળનાં કાંટા તરફ ફેરવો -pdfjs-page-rotate-cw-button-label = ઘડિયાળનાં કાંટા તરફ ફેરવો -pdfjs-page-rotate-ccw-button = - .title = ઘડિયાળનાં કાંટાની ઉલટી દિશામાં ફેરવો -pdfjs-page-rotate-ccw-button-label = ઘડિયાળનાં કાંટાની વિરુદ્દ ફેરવો -pdfjs-cursor-text-select-tool-button = - .title = ટેક્સ્ટ પસંદગી ટૂલ સક્ષમ કરો -pdfjs-cursor-text-select-tool-button-label = ટેક્સ્ટ પસંદગી ટૂલ -pdfjs-cursor-hand-tool-button = - .title = હાથનાં સાધનને સક્રિય કરો -pdfjs-cursor-hand-tool-button-label = હેન્ડ ટૂલ -pdfjs-scroll-vertical-button = - .title = ઊભી સ્ક્રોલિંગનો ઉપયોગ કરો -pdfjs-scroll-vertical-button-label = ઊભી સ્ક્રોલિંગ -pdfjs-scroll-horizontal-button = - .title = આડી સ્ક્રોલિંગનો ઉપયોગ કરો -pdfjs-scroll-horizontal-button-label = આડી સ્ક્રોલિંગ -pdfjs-scroll-wrapped-button = - .title = આવરિત સ્ક્રોલિંગનો ઉપયોગ કરો -pdfjs-scroll-wrapped-button-label = આવરિત સ્ક્રોલિંગ -pdfjs-spread-none-button = - .title = પૃષ્ઠ સ્પ્રેડમાં જોડાવશો નહીં -pdfjs-spread-none-button-label = કોઈ સ્પ્રેડ નથી -pdfjs-spread-odd-button = - .title = એકી-ક્રમાંકિત પૃષ્ઠો સાથે પ્રારંભ થતાં પૃષ્ઠ સ્પ્રેડમાં જોડાઓ -pdfjs-spread-odd-button-label = એકી સ્પ્રેડ્સ -pdfjs-spread-even-button = - .title = નંબર-ક્રમાંકિત પૃષ્ઠોથી શરૂ થતાં પૃષ્ઠ સ્પ્રેડમાં જોડાઓ -pdfjs-spread-even-button-label = સરખું ફેલાવવું - -## Document properties dialog - -pdfjs-document-properties-button = - .title = દસ્તાવેજ ગુણધર્મો… -pdfjs-document-properties-button-label = દસ્તાવેજ ગુણધર્મો… -pdfjs-document-properties-file-name = ફાઇલ નામ: -pdfjs-document-properties-file-size = ફાઇલ માપ: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } બાઇટ) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } બાઇટ) -pdfjs-document-properties-title = શીર્ષક: -pdfjs-document-properties-author = લેખક: -pdfjs-document-properties-subject = વિષય: -pdfjs-document-properties-keywords = કિવર્ડ: -pdfjs-document-properties-creation-date = નિર્માણ તારીખ: -pdfjs-document-properties-modification-date = ફેરફાર તારીખ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = નિર્માતા: -pdfjs-document-properties-producer = PDF નિર્માતા: -pdfjs-document-properties-version = PDF આવૃત્તિ: -pdfjs-document-properties-page-count = પાનાં ગણતરી: -pdfjs-document-properties-page-size = પૃષ્ઠનું કદ: -pdfjs-document-properties-page-size-unit-inches = ઇંચ -pdfjs-document-properties-page-size-unit-millimeters = મીમી -pdfjs-document-properties-page-size-orientation-portrait = ઉભું -pdfjs-document-properties-page-size-orientation-landscape = આડુ -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = પત્ર -pdfjs-document-properties-page-size-name-legal = કાયદાકીય - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = ઝડપી વૅબ દૃશ્ય: -pdfjs-document-properties-linearized-yes = હા -pdfjs-document-properties-linearized-no = ના -pdfjs-document-properties-close-button = બંધ કરો - -## Print - -pdfjs-print-progress-message = છાપકામ માટે દસ્તાવેજ તૈયાર કરી રહ્યા છે… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = રદ કરો -pdfjs-printing-not-supported = ચેતવણી: છાપવાનું આ બ્રાઉઝર દ્દારા સંપૂર્ણપણે આધારભૂત નથી. -pdfjs-printing-not-ready = Warning: PDF એ છાપવા માટે સંપૂર્ણપણે લાવેલ છે. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = ટૉગલ બાજુપટ્ટી -pdfjs-toggle-sidebar-button-label = ટૉગલ બાજુપટ્ટી -pdfjs-document-outline-button = - .title = દસ્તાવેજની રૂપરેખા બતાવો(બધી આઇટમ્સને વિસ્તૃત/સંકુચિત કરવા માટે ડબલ-ક્લિક કરો) -pdfjs-document-outline-button-label = દસ્તાવેજ રૂપરેખા -pdfjs-attachments-button = - .title = જોડાણોને બતાવો -pdfjs-attachments-button-label = જોડાણો -pdfjs-thumbs-button = - .title = થંબનેલ્સ બતાવો -pdfjs-thumbs-button-label = થંબનેલ્સ -pdfjs-findbar-button = - .title = દસ્તાવેજમાં શોધો -pdfjs-findbar-button-label = શોધો - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = પાનું { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = પાનાં { $page } નું થંબનેલ્સ - -## Find panel button title and messages - -pdfjs-find-input = - .title = શોધો - .placeholder = દસ્તાવેજમાં શોધો… -pdfjs-find-previous-button = - .title = શબ્દસમૂહની પાછલી ઘટનાને શોધો -pdfjs-find-previous-button-label = પહેલાંનુ -pdfjs-find-next-button = - .title = શબ્દસમૂહની આગળની ઘટનાને શોધો -pdfjs-find-next-button-label = આગળનું -pdfjs-find-highlight-checkbox = બધુ પ્રકાશિત કરો -pdfjs-find-match-case-checkbox-label = કેસ બંધબેસાડો -pdfjs-find-entire-word-checkbox-label = સંપૂર્ણ શબ્દો -pdfjs-find-reached-top = દસ્તાવેજનાં ટોચે પહોંચી ગયા, તળિયેથી ચાલુ કરેલ હતુ -pdfjs-find-reached-bottom = દસ્તાવેજનાં અંતે પહોંચી ગયા, ઉપરથી ચાલુ કરેલ હતુ -pdfjs-find-not-found = શબ્દસમૂહ મળ્યુ નથી - -## Predefined zoom values - -pdfjs-page-scale-width = પાનાની પહોળાઇ -pdfjs-page-scale-fit = પાનું બંધબેસતુ -pdfjs-page-scale-auto = આપમેળે નાનુંમોટુ કરો -pdfjs-page-scale-actual = ચોક્કસ માપ -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = ભૂલ ઉદ્ભવી જ્યારે PDF ને લાવી રહ્યા હોય. -pdfjs-invalid-file-error = અયોગ્ય અથવા ભાંગેલ PDF ફાઇલ. -pdfjs-missing-file-error = ગુમ થયેલ PDF ફાઇલ. -pdfjs-unexpected-response-error = અનપેક્ષિત સર્વર પ્રતિસાદ. -pdfjs-rendering-error = ભૂલ ઉદ્ભવી જ્યારે પાનાંનુ રેન્ડ કરી રહ્યા હોય. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = આ PDF ફાઇલને ખોલવા પાસવર્ડને દાખલ કરો. -pdfjs-password-invalid = અયોગ્ય પાસવર્ડ. મહેરબાની કરીને ફરી પ્રયત્ન કરો. -pdfjs-password-ok-button = બરાબર -pdfjs-password-cancel-button = રદ કરો -pdfjs-web-fonts-disabled = વેબ ફોન્ટ નિષ્ક્રિય થયેલ છે: ઍમ્બેડ થયેલ PDF ફોન્ટને વાપરવાનું અસમર્થ. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/gu-IN/viewer.properties b/static/pdf.js/locale/gu-IN/viewer.properties new file mode 100644 index 00000000..df6bb15b --- /dev/null +++ b/static/pdf.js/locale/gu-IN/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=પહેલાનુ પાનું +previous_label=પહેલાનુ +next.title=આગળનુ પાનું +next_label=આગળનું + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=પાનું: +page_of={{pageCount}} નું + +zoom_out.title=મોટુ કરો +zoom_out_label=મોટુ કરો +zoom_in.title=નાનું કરો +zoom_in_label=નાનું કરો +zoom.title=નાનું મોટુ કરો +presentation_mode.title=રજૂઆત સ્થિતિમાં જાવ +presentation_mode_label=રજૂઆત સ્થિતિ +open_file.title=ફાઇલ ખોલો +open_file_label=ખોલો +print.title=છાપો +print_label=છારો +download.title=ડાઉનલોડ +download_label=ડાઉનલોડ +bookmark.title=વર્તમાન દૃશ્ય (નવી વિન્ડોમાં નકલ કરો અથવા ખોલો) +bookmark_label=વર્તમાન દૃશ્ય + +# Secondary toolbar and context menu +tools.title=સાધનો +tools_label=સાધનો +first_page.label=પહેલાં પાનામાં જાવ +first_page_label=પ્રથમ પાનાં પર જાવ +last_page.label=છેલ્લા પાનામાં જાવ +last_page_label=છેલ્લા પાનાં પર જાવ +page_rotate_cw.label=ઘડિયાળનાં કાંટાની જેમ ફેરવો +page_rotate_cw_label=ઘડિયાળનાં કાંટા તરફ ફેરવો +page_rotate_ccw.label=ઘડિયાળનાં કાંટાની ઉલટી દિશામાં ફેરવો +page_rotate_ccw_label=ઘડિયાળનાં કાંટાની વિરુદ્દ ફેરવો + +hand_tool_enable.title=હાથનાં સાધનને સક્રિય કરો +hand_tool_enable_label=હાથનાં સાધનને સક્રિય કરો +hand_tool_disable.title=હાથનાં સાધનને નિષ્ક્રિય કરો +hand_tool_disable_label=હાથનાં સાધનને નિષ્ક્રિય કરો + +# Document properties dialog box +document_properties.title=દસ્તાવેજ ગુણધર્મો… +document_properties_label=દસ્તાવેજ ગુણધર્મો… +document_properties_file_name=ફાઇલ નામ: +document_properties_file_size=ફાઇલ માપ: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} બાઇટ) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} બાઇટ) +document_properties_title=શીર્ષક: +document_properties_author=લેખક: +document_properties_subject=વિષય: +document_properties_keywords=કિવર્ડ: +document_properties_creation_date=નિર્માણ તારીખ: +document_properties_modification_date=ફેરફાર તારીખ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=નિર્માતા: +document_properties_producer=PDF નિર્માતા: +document_properties_version=PDF આવૃત્તિ: +document_properties_page_count=પાનાં ગણતરી: +document_properties_close=બંધ કરો + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=ટૉગલ બાજુપટ્ટી +toggle_sidebar_label=ટૉગલ બાજુપટ્ટી +outline.title=દસ્તાવેજ રૂપરેખા બતાવો +outline_label=દસ્તાવેજ રૂપરેખા +attachments.title=જોડાણોને બતાવો +attachments_label=જોડાણો +thumbs.title=થંબનેલ્સ બતાવો +thumbs_label=થંબનેલ્સ +findbar.title=દસ્તાવેજમાં શોધો +findbar_label=શોધો + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=પાનું {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=પાનાં {{page}} નું થંબનેલ્સ + +# Find panel button title and messages +find_label=શોધો: +find_previous.title=શબ્દસમૂહની પાછલી ઘટનાને શોધો +find_previous_label=પહેલાંનુ +find_next.title=શબ્દસમૂહની આગળની ઘટનાને શોધો +find_next_label=આગળનું +find_highlight=બધુ પ્રકાશિત કરો +find_match_case_label=કેસ બંધબેસાડો +find_reached_top=દસ્તાવેજનાં ટોચે પહોંચી ગયા, તળિયેથી ચાલુ કરેલ હતુ +find_reached_bottom=દસ્તાવેજનાં અંતે પહોંચી ગયા, ઉપરથી ચાલુ કરેલ હતુ +find_not_found=શબ્દસમૂહ મળ્યુ નથી + +# Error panel labels +error_more_info=વધારે જાણકારી +error_less_info=ઓછી જાણકારી +error_close=બંધ કરો +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=સંદેશો: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=સ્ટેક: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ફાઇલ: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=વાક્ય: {{line}} +rendering_error=ભૂલ ઉદ્ભવી જ્યારે પાનાંનુ રેન્ડ કરી રહ્યા હોય. + +# Predefined zoom values +page_scale_width=પાનાની પહોળાઇ +page_scale_fit=પાનું બંધબેસતુ +page_scale_auto=આપમેળે નાનુંમોટુ કરો +page_scale_actual=ચોક્કસ માપ +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=ભૂલ +loading_error=ભૂલ ઉદ્ભવી જ્યારે PDF ને લાવી રહ્યા હોય. +invalid_file_error=અયોગ્ય અથવા ભાંગેલ PDF ફાઇલ. +missing_file_error=ગુમ થયેલ PDF ફાઇલ. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=આ PDF ફાઇલને ખોલવા પાસવર્ડને દાખલ કરો. +password_invalid=અયોગ્ય પાસવર્ડ. મહેરબાની કરીને ફરી પ્રયત્ન કરો. +password_ok=બરાબર +password_cancel=રદ કરો + +printing_not_supported=ચેતવણી: છાપવાનું આ બ્રાઉઝર દ્દારા સંપૂર્ણપણે આધારભૂત નથી. +printing_not_ready=Warning: PDF એ છાપવા માટે સંપૂર્ણપણે લાવેલ છે. +web_fonts_disabled=વેબ ફોન્ટ નિષ્ક્રિય થયેલ છે: ઍમ્બેડ થયેલ PDF ફોન્ટને વાપરવાનું અસમર્થ. +document_colors_not_allowed=PDF દસ્તાવેજો તેનાં પોતાના રંગોને વાપરવા પરવાનગી આપતા નથી: 'તેનાં પોતાનાં રંગોને પસંદ કરવા માટે પાનાંને પરવાનગી આપો' બ્રાઉઝરમાં નિષ્ક્રિય થયેલ છે. diff --git a/static/pdf.js/locale/he/viewer.ftl b/static/pdf.js/locale/he/viewer.ftl deleted file mode 100644 index 624d2083..00000000 --- a/static/pdf.js/locale/he/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = דף קודם -pdfjs-previous-button-label = קודם -pdfjs-next-button = - .title = דף הבא -pdfjs-next-button-label = הבא -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = דף -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = מתוך { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } מתוך { $pagesCount }) -pdfjs-zoom-out-button = - .title = התרחקות -pdfjs-zoom-out-button-label = התרחקות -pdfjs-zoom-in-button = - .title = התקרבות -pdfjs-zoom-in-button-label = התקרבות -pdfjs-zoom-select = - .title = מרחק מתצוגה -pdfjs-presentation-mode-button = - .title = מעבר למצב מצגת -pdfjs-presentation-mode-button-label = מצב מצגת -pdfjs-open-file-button = - .title = פתיחת קובץ -pdfjs-open-file-button-label = פתיחה -pdfjs-print-button = - .title = הדפסה -pdfjs-print-button-label = הדפסה -pdfjs-save-button = - .title = שמירה -pdfjs-save-button-label = שמירה -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = הורדה -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = הורדה -pdfjs-bookmark-button = - .title = עמוד נוכחי (הצגת כתובת האתר מהעמוד הנוכחי) -pdfjs-bookmark-button-label = עמוד נוכחי -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = פתיחה ביישום -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = פתיחה ביישום - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = כלים -pdfjs-tools-button-label = כלים -pdfjs-first-page-button = - .title = מעבר לעמוד הראשון -pdfjs-first-page-button-label = מעבר לעמוד הראשון -pdfjs-last-page-button = - .title = מעבר לעמוד האחרון -pdfjs-last-page-button-label = מעבר לעמוד האחרון -pdfjs-page-rotate-cw-button = - .title = הטיה עם כיוון השעון -pdfjs-page-rotate-cw-button-label = הטיה עם כיוון השעון -pdfjs-page-rotate-ccw-button = - .title = הטיה כנגד כיוון השעון -pdfjs-page-rotate-ccw-button-label = הטיה כנגד כיוון השעון -pdfjs-cursor-text-select-tool-button = - .title = הפעלת כלי בחירת טקסט -pdfjs-cursor-text-select-tool-button-label = כלי בחירת טקסט -pdfjs-cursor-hand-tool-button = - .title = הפעלת כלי היד -pdfjs-cursor-hand-tool-button-label = כלי יד -pdfjs-scroll-page-button = - .title = שימוש בגלילת עמוד -pdfjs-scroll-page-button-label = גלילת עמוד -pdfjs-scroll-vertical-button = - .title = שימוש בגלילה אנכית -pdfjs-scroll-vertical-button-label = גלילה אנכית -pdfjs-scroll-horizontal-button = - .title = שימוש בגלילה אופקית -pdfjs-scroll-horizontal-button-label = גלילה אופקית -pdfjs-scroll-wrapped-button = - .title = שימוש בגלילה רציפה -pdfjs-scroll-wrapped-button-label = גלילה רציפה -pdfjs-spread-none-button = - .title = לא לצרף מפתחי עמודים -pdfjs-spread-none-button-label = ללא מפתחים -pdfjs-spread-odd-button = - .title = צירוף מפתחי עמודים שמתחילים בדפים עם מספרים אי־זוגיים -pdfjs-spread-odd-button-label = מפתחים אי־זוגיים -pdfjs-spread-even-button = - .title = צירוף מפתחי עמודים שמתחילים בדפים עם מספרים זוגיים -pdfjs-spread-even-button-label = מפתחים זוגיים - -## Document properties dialog - -pdfjs-document-properties-button = - .title = מאפייני מסמך… -pdfjs-document-properties-button-label = מאפייני מסמך… -pdfjs-document-properties-file-name = שם קובץ: -pdfjs-document-properties-file-size = גודל הקובץ: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } ק״ב ({ $size_b } בתים) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } מ״ב ({ $size_b } בתים) -pdfjs-document-properties-title = כותרת: -pdfjs-document-properties-author = מחבר: -pdfjs-document-properties-subject = נושא: -pdfjs-document-properties-keywords = מילות מפתח: -pdfjs-document-properties-creation-date = תאריך יצירה: -pdfjs-document-properties-modification-date = תאריך שינוי: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = יוצר: -pdfjs-document-properties-producer = יצרן PDF: -pdfjs-document-properties-version = גרסת PDF: -pdfjs-document-properties-page-count = מספר דפים: -pdfjs-document-properties-page-size = גודל העמוד: -pdfjs-document-properties-page-size-unit-inches = אינ׳ -pdfjs-document-properties-page-size-unit-millimeters = מ״מ -pdfjs-document-properties-page-size-orientation-portrait = לאורך -pdfjs-document-properties-page-size-orientation-landscape = לרוחב -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = מכתב -pdfjs-document-properties-page-size-name-legal = דף משפטי - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = תצוגת דף מהירה: -pdfjs-document-properties-linearized-yes = כן -pdfjs-document-properties-linearized-no = לא -pdfjs-document-properties-close-button = סגירה - -## Print - -pdfjs-print-progress-message = מסמך בהכנה להדפסה… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = ביטול -pdfjs-printing-not-supported = אזהרה: הדפסה אינה נתמכת במלואה בדפדפן זה. -pdfjs-printing-not-ready = אזהרה: מסמך ה־PDF לא נטען לחלוטין עד מצב שמאפשר הדפסה. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = הצגה/הסתרה של סרגל הצד -pdfjs-toggle-sidebar-notification-button = - .title = החלפת תצוגת סרגל צד (מסמך שמכיל תוכן עניינים/קבצים מצורפים/שכבות) -pdfjs-toggle-sidebar-button-label = הצגה/הסתרה של סרגל הצד -pdfjs-document-outline-button = - .title = הצגת תוכן העניינים של המסמך (לחיצה כפולה כדי להרחיב או לצמצם את כל הפריטים) -pdfjs-document-outline-button-label = תוכן העניינים של המסמך -pdfjs-attachments-button = - .title = הצגת צרופות -pdfjs-attachments-button-label = צרופות -pdfjs-layers-button = - .title = הצגת שכבות (יש ללחוץ לחיצה כפולה כדי לאפס את כל השכבות למצב ברירת המחדל) -pdfjs-layers-button-label = שכבות -pdfjs-thumbs-button = - .title = הצגת תצוגה מקדימה -pdfjs-thumbs-button-label = תצוגה מקדימה -pdfjs-current-outline-item-button = - .title = מציאת פריט תוכן העניינים הנוכחי -pdfjs-current-outline-item-button-label = פריט תוכן העניינים הנוכחי -pdfjs-findbar-button = - .title = חיפוש במסמך -pdfjs-findbar-button-label = חיפוש -pdfjs-additional-layers = שכבות נוספות - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = עמוד { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = תצוגה מקדימה של עמוד { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = חיפוש - .placeholder = חיפוש במסמך… -pdfjs-find-previous-button = - .title = מציאת המופע הקודם של הביטוי -pdfjs-find-previous-button-label = קודם -pdfjs-find-next-button = - .title = מציאת המופע הבא של הביטוי -pdfjs-find-next-button-label = הבא -pdfjs-find-highlight-checkbox = הדגשת הכול -pdfjs-find-match-case-checkbox-label = התאמת אותיות -pdfjs-find-match-diacritics-checkbox-label = התאמה דיאקריטית -pdfjs-find-entire-word-checkbox-label = מילים שלמות -pdfjs-find-reached-top = הגיע לראש הדף, ממשיך מלמטה -pdfjs-find-reached-bottom = הגיע לסוף הדף, ממשיך מלמעלה -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } מתוך { $total } תוצאות - *[other] { $current } מתוך { $total } תוצאות - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] יותר מתוצאה אחת - *[other] יותר מ־{ $limit } תוצאות - } -pdfjs-find-not-found = הביטוי לא נמצא - -## Predefined zoom values - -pdfjs-page-scale-width = רוחב העמוד -pdfjs-page-scale-fit = התאמה לעמוד -pdfjs-page-scale-auto = מרחק מתצוגה אוטומטי -pdfjs-page-scale-actual = גודל אמיתי -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = עמוד { $page } - -## Loading indicator messages - -pdfjs-loading-error = אירעה שגיאה בעת טעינת ה־PDF. -pdfjs-invalid-file-error = קובץ PDF פגום או לא תקין. -pdfjs-missing-file-error = קובץ PDF חסר. -pdfjs-unexpected-response-error = תגובת שרת לא צפויה. -pdfjs-rendering-error = אירעה שגיאה בעת עיבוד הדף. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [הערת { $type }] - -## Password - -pdfjs-password-label = נא להכניס את הססמה לפתיחת קובץ PDF זה. -pdfjs-password-invalid = ססמה שגויה. נא לנסות שנית. -pdfjs-password-ok-button = אישור -pdfjs-password-cancel-button = ביטול -pdfjs-web-fonts-disabled = גופני רשת מנוטרלים: לא ניתן להשתמש בגופני PDF מוטבעים. - -## Editing - -pdfjs-editor-free-text-button = - .title = טקסט -pdfjs-editor-free-text-button-label = טקסט -pdfjs-editor-ink-button = - .title = ציור -pdfjs-editor-ink-button-label = ציור -pdfjs-editor-stamp-button = - .title = הוספה או עריכת תמונות -pdfjs-editor-stamp-button-label = הוספה או עריכת תמונות -pdfjs-editor-highlight-button = - .title = סימון -pdfjs-editor-highlight-button-label = סימון -pdfjs-highlight-floating-button = - .title = סימון -pdfjs-highlight-floating-button1 = - .title = סימון - .aria-label = סימון -pdfjs-highlight-floating-button-label = סימון - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = הסרת ציור -pdfjs-editor-remove-freetext-button = - .title = הסרת טקסט -pdfjs-editor-remove-stamp-button = - .title = הסרת תמונה -pdfjs-editor-remove-highlight-button = - .title = הסרת הדגשה - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = צבע -pdfjs-editor-free-text-size-input = גודל -pdfjs-editor-ink-color-input = צבע -pdfjs-editor-ink-thickness-input = עובי -pdfjs-editor-ink-opacity-input = אטימות -pdfjs-editor-stamp-add-image-button = - .title = הוספת תמונה -pdfjs-editor-stamp-add-image-button-label = הוספת תמונה -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = עובי -pdfjs-editor-free-highlight-thickness-title = - .title = שינוי עובי בעת הדגשת פריטים שאינם טקסט -pdfjs-free-text = - .aria-label = עורך טקסט -pdfjs-free-text-default-content = להתחיל להקליד… -pdfjs-ink = - .aria-label = עורך ציור -pdfjs-ink-canvas = - .aria-label = תמונה שנוצרה על־ידי משתמש - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = טקסט חלופי -pdfjs-editor-alt-text-edit-button-label = עריכת טקסט חלופי -pdfjs-editor-alt-text-dialog-label = בחירת אפשרות -pdfjs-editor-alt-text-dialog-description = טקסט חלופי עוזר כשאנשים לא יכולים לראות את התמונה או כשהיא לא נטענת. -pdfjs-editor-alt-text-add-description-label = הוספת תיאור -pdfjs-editor-alt-text-add-description-description = כדאי לתאר במשפט אחד או שניים את הנושא, התפאורה או הפעולות. -pdfjs-editor-alt-text-mark-decorative-label = סימון כדקורטיבי -pdfjs-editor-alt-text-mark-decorative-description = זה משמש לתמונות נוי, כמו גבולות או סימני מים. -pdfjs-editor-alt-text-cancel-button = ביטול -pdfjs-editor-alt-text-save-button = שמירה -pdfjs-editor-alt-text-decorative-tooltip = מסומן כדקורטיבי -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = לדוגמה, ״גבר צעיר מתיישב ליד שולחן לאכול ארוחה״ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = פינה שמאלית עליונה - שינוי גודל -pdfjs-editor-resizer-label-top-middle = למעלה באמצע - שינוי גודל -pdfjs-editor-resizer-label-top-right = פינה ימנית עליונה - שינוי גודל -pdfjs-editor-resizer-label-middle-right = ימינה באמצע - שינוי גודל -pdfjs-editor-resizer-label-bottom-right = פינה ימנית תחתונה - שינוי גודל -pdfjs-editor-resizer-label-bottom-middle = למטה באמצע - שינוי גודל -pdfjs-editor-resizer-label-bottom-left = פינה שמאלית תחתונה - שינוי גודל -pdfjs-editor-resizer-label-middle-left = שמאלה באמצע - שינוי גודל - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = צבע הדגשה -pdfjs-editor-colorpicker-button = - .title = שינוי צבע -pdfjs-editor-colorpicker-dropdown = - .aria-label = בחירת צבע -pdfjs-editor-colorpicker-yellow = - .title = צהוב -pdfjs-editor-colorpicker-green = - .title = ירוק -pdfjs-editor-colorpicker-blue = - .title = כחול -pdfjs-editor-colorpicker-pink = - .title = ורוד -pdfjs-editor-colorpicker-red = - .title = אדום - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = הצגת הכול -pdfjs-editor-highlight-show-all-button = - .title = הצגת הכול diff --git a/static/pdf.js/locale/he/viewer.properties b/static/pdf.js/locale/he/viewer.properties new file mode 100644 index 00000000..10f1177e --- /dev/null +++ b/static/pdf.js/locale/he/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=דף קודם +previous_label=קודם +next.title=דף הבא +next_label=הבא + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=עמוד: +page_of=מתוך {{pageCount}} + +zoom_out.title=התרחקות +zoom_out_label=התרחקות +zoom_in.title=התקרבות +zoom_in_label=התקרבות +zoom.title=מרחק מתצוגה +presentation_mode.title=מעבר למצב מצגת +presentation_mode_label=מצב מצגת +open_file.title=פתיחת קובץ +open_file_label=פתיחה +print.title=הדפסה +print_label=הדפסה +download.title=הורדה +download_label=הורדה +bookmark.title=תצוגה נוכחית (העתקה או פתיחה בחלון חדש) +bookmark_label=תצוגה נוכחית + +# Secondary toolbar and context menu +tools.title=כלים +tools_label=כלים +first_page.title=מעבר לעמוד הראשון +first_page.label=מעבר לעמוד הראשון +first_page_label=מעבר לעמוד הראשון +last_page.title=מעבר לעמוד האחרון +last_page.label=מעבר לעמוד האחרון +last_page_label=מעבר לעמוד האחרון +page_rotate_cw.title=הטיה עם כיוון השעון +page_rotate_cw.label=הטיה עם כיוון השעון +page_rotate_cw_label=הטיה עם כיוון השעון +page_rotate_ccw.title=הטיה כנגד כיוון השעון +page_rotate_ccw.label=הטיה כנגד כיוון השעון +page_rotate_ccw_label=הטיה כנגד כיוון השעון + +hand_tool_enable.title=הפעלת כלי היד +hand_tool_enable_label=הפעלת כלי היד +hand_tool_disable.title=נטרול כלי היד +hand_tool_disable_label=נטרול כלי היד + +# Document properties dialog box +document_properties.title=מאפייני מסמך… +document_properties_label=מאפייני מסמך… +document_properties_file_name=שם קובץ: +document_properties_file_size=גודל הקובץ: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} ק״ב ({{size_b}} בתים) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} מ״ב ({{size_b}} בתים) +document_properties_title=כותרת: +document_properties_author=מחבר: +document_properties_subject=נושא: +document_properties_keywords=מילות מפתח: +document_properties_creation_date=תאריך יצירה: +document_properties_modification_date=תאריך שינוי: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=יוצר: +document_properties_producer=יצרן PDF: +document_properties_version=גרסת PDF: +document_properties_page_count=מספר דפים: +document_properties_close=סגירה + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=הצגה/הסתרה של סרגל הצד +toggle_sidebar_label=הצגה/הסתרה של סרגל הצד +outline.title=הצגת מתאר מסמך +outline_label=מתאר מסמך +attachments.title=הצגת צרופות +attachments_label=צרופות +thumbs.title=הצגת תצוגה מקדימה +thumbs_label=תצוגה מקדימה +findbar.title=חיפוש במסמך +findbar_label=חיפוש + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=עמוד {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=תצוגה מקדימה של עמוד {{page}} + +# Find panel button title and messages +find_label=חיפוש: +find_previous.title=חיפוש מופע קודם של הביטוי +find_previous_label=קודם +find_next.title=חיפוש המופע הבא של הביטוי +find_next_label=הבא +find_highlight=הדגשת הכול +find_match_case_label=התאמת אותיות +find_reached_top=הגיע לראש הדף, ממשיך מלמטה +find_reached_bottom=הגיע לסוף הדף, ממשיך מלמעלה +find_not_found=ביטוי לא נמצא + +# Error panel labels +error_more_info=מידע נוסף +error_less_info=פחות מידע +error_close=סגירה +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js גרסה {{version}} (בנייה: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=הודעה: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=תוכן מחסנית: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=קובץ: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=שורה: {{line}} +rendering_error=אירעה שגיאה בעת עיבוד הדף. + +# Predefined zoom values +page_scale_width=רוחב העמוד +page_scale_fit=התאמה לעמוד +page_scale_auto=מרחק מתצוגה אוטומטי +page_scale_actual=גודל אמתי +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=שגיאה +loading_error=אירעה שגיאה בעת טעינת ה־PDF. +invalid_file_error=קובץ PDF פגום או לא תקין. +missing_file_error=קובץ PDF חסר. +unexpected_response_error=תגובת שרת לא צפויה. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[הערת {{type}}] +password_label=נא להכניס את הססמה לפתיחת קובץ PDF זה. +password_invalid=ססמה שגויה. נא לנסות שנית. +password_ok=אישור +password_cancel=ביטול + +printing_not_supported=אזהרה: הדפסה אינה נתמכת במלואה בדפדפן זה. +printing_not_ready=אזהרה: ה־PDF לא ניתן לחלוטין עד מצב שמאפשר הדפסה. +web_fonts_disabled=גופני רשת מנוטרלים: לא ניתן להשתמש בגופני PDF מוטבעים. +document_colors_disabled=מסמכי PDF לא יכולים להשתמש בצבעים משלהם: האפשרות \\'לאפשר לעמודים לבחור צבעים משלהם\\' אינה פעילה בדפדפן. diff --git a/static/pdf.js/locale/hi-IN/viewer.ftl b/static/pdf.js/locale/hi-IN/viewer.ftl deleted file mode 100644 index 1ead5930..00000000 --- a/static/pdf.js/locale/hi-IN/viewer.ftl +++ /dev/null @@ -1,253 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = पिछला पृष्ठ -pdfjs-previous-button-label = पिछला -pdfjs-next-button = - .title = अगला पृष्ठ -pdfjs-next-button-label = आगे -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = पृष्ठ: -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } का -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } of { $pagesCount }) -pdfjs-zoom-out-button = - .title = छोटा करें -pdfjs-zoom-out-button-label = छोटा करें -pdfjs-zoom-in-button = - .title = बड़ा करें -pdfjs-zoom-in-button-label = बड़ा करें -pdfjs-zoom-select = - .title = बड़ा-छोटा करें -pdfjs-presentation-mode-button = - .title = प्रस्तुति अवस्था में जाएँ -pdfjs-presentation-mode-button-label = प्रस्तुति अवस्था -pdfjs-open-file-button = - .title = फ़ाइल खोलें -pdfjs-open-file-button-label = खोलें -pdfjs-print-button = - .title = छापें -pdfjs-print-button-label = छापें -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = ऐप में खोलें -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = ऐप में खोलें - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = औज़ार -pdfjs-tools-button-label = औज़ार -pdfjs-first-page-button = - .title = प्रथम पृष्ठ पर जाएँ -pdfjs-first-page-button-label = प्रथम पृष्ठ पर जाएँ -pdfjs-last-page-button = - .title = अंतिम पृष्ठ पर जाएँ -pdfjs-last-page-button-label = अंतिम पृष्ठ पर जाएँ -pdfjs-page-rotate-cw-button = - .title = घड़ी की दिशा में घुमाएँ -pdfjs-page-rotate-cw-button-label = घड़ी की दिशा में घुमाएँ -pdfjs-page-rotate-ccw-button = - .title = घड़ी की दिशा से उल्टा घुमाएँ -pdfjs-page-rotate-ccw-button-label = घड़ी की दिशा से उल्टा घुमाएँ -pdfjs-cursor-text-select-tool-button = - .title = पाठ चयन उपकरण सक्षम करें -pdfjs-cursor-text-select-tool-button-label = पाठ चयन उपकरण -pdfjs-cursor-hand-tool-button = - .title = हस्त उपकरण सक्षम करें -pdfjs-cursor-hand-tool-button-label = हस्त उपकरण -pdfjs-scroll-vertical-button = - .title = लंबवत स्क्रॉलिंग का उपयोग करें -pdfjs-scroll-vertical-button-label = लंबवत स्क्रॉलिंग -pdfjs-scroll-horizontal-button = - .title = क्षितिजिय स्क्रॉलिंग का उपयोग करें -pdfjs-scroll-horizontal-button-label = क्षितिजिय स्क्रॉलिंग -pdfjs-scroll-wrapped-button = - .title = व्राप्पेड स्क्रॉलिंग का उपयोग करें -pdfjs-spread-none-button-label = कोई स्प्रेड उपलब्ध नहीं -pdfjs-spread-odd-button = - .title = विषम-क्रमांकित पृष्ठों से प्रारंभ होने वाले पृष्ठ स्प्रेड में शामिल हों -pdfjs-spread-odd-button-label = विषम फैलाव - -## Document properties dialog - -pdfjs-document-properties-button = - .title = दस्तावेज़ विशेषता... -pdfjs-document-properties-button-label = दस्तावेज़ विशेषता... -pdfjs-document-properties-file-name = फ़ाइल नाम: -pdfjs-document-properties-file-size = फाइल आकारः -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = शीर्षक: -pdfjs-document-properties-author = लेखकः -pdfjs-document-properties-subject = विषय: -pdfjs-document-properties-keywords = कुंजी-शब्द: -pdfjs-document-properties-creation-date = निर्माण दिनांक: -pdfjs-document-properties-modification-date = संशोधन दिनांक: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = निर्माता: -pdfjs-document-properties-producer = PDF उत्पादक: -pdfjs-document-properties-version = PDF संस्करण: -pdfjs-document-properties-page-count = पृष्ठ गिनती: -pdfjs-document-properties-page-size = पृष्ठ आकार: -pdfjs-document-properties-page-size-unit-inches = इंच -pdfjs-document-properties-page-size-unit-millimeters = मिमी -pdfjs-document-properties-page-size-orientation-portrait = पोर्ट्रेट -pdfjs-document-properties-page-size-orientation-landscape = लैंडस्केप -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = पत्र -pdfjs-document-properties-page-size-name-legal = क़ानूनी - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = तीव्र वेब व्यू: -pdfjs-document-properties-linearized-yes = हाँ -pdfjs-document-properties-linearized-no = नहीं -pdfjs-document-properties-close-button = बंद करें - -## Print - -pdfjs-print-progress-message = छपाई के लिए दस्तावेज़ को तैयार किया जा रहा है... -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = रद्द करें -pdfjs-printing-not-supported = चेतावनी: इस ब्राउज़र पर छपाई पूरी तरह से समर्थित नहीं है. -pdfjs-printing-not-ready = चेतावनी: PDF छपाई के लिए पूरी तरह से लोड नहीं है. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = स्लाइडर टॉगल करें -pdfjs-toggle-sidebar-button-label = स्लाइडर टॉगल करें -pdfjs-document-outline-button = - .title = दस्तावेज़ की रूपरेखा दिखाइए (सारी वस्तुओं को फलने अथवा समेटने के लिए दो बार क्लिक करें) -pdfjs-document-outline-button-label = दस्तावेज़ आउटलाइन -pdfjs-attachments-button = - .title = संलग्नक दिखायें -pdfjs-attachments-button-label = संलग्नक -pdfjs-thumbs-button = - .title = लघुछवियाँ दिखाएँ -pdfjs-thumbs-button-label = लघु छवि -pdfjs-findbar-button = - .title = दस्तावेज़ में ढूँढ़ें -pdfjs-findbar-button-label = ढूँढें - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = पृष्ठ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = पृष्ठ { $page } की लघु-छवि - -## Find panel button title and messages - -pdfjs-find-input = - .title = ढूँढें - .placeholder = दस्तावेज़ में खोजें... -pdfjs-find-previous-button = - .title = वाक्यांश की पिछली उपस्थिति ढूँढ़ें -pdfjs-find-previous-button-label = पिछला -pdfjs-find-next-button = - .title = वाक्यांश की अगली उपस्थिति ढूँढ़ें -pdfjs-find-next-button-label = अगला -pdfjs-find-highlight-checkbox = सभी आलोकित करें -pdfjs-find-match-case-checkbox-label = मिलान स्थिति -pdfjs-find-entire-word-checkbox-label = संपूर्ण शब्द -pdfjs-find-reached-top = पृष्ठ के ऊपर पहुंच गया, नीचे से जारी रखें -pdfjs-find-reached-bottom = पृष्ठ के नीचे में जा पहुँचा, ऊपर से जारी -pdfjs-find-not-found = वाक्यांश नहीं मिला - -## Predefined zoom values - -pdfjs-page-scale-width = पृष्ठ चौड़ाई -pdfjs-page-scale-fit = पृष्ठ फिट -pdfjs-page-scale-auto = स्वचालित जूम -pdfjs-page-scale-actual = वास्तविक आकार -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF लोड करते समय एक त्रुटि हुई. -pdfjs-invalid-file-error = अमान्य या भ्रष्ट PDF फ़ाइल. -pdfjs-missing-file-error = अनुपस्थित PDF फ़ाइल. -pdfjs-unexpected-response-error = अप्रत्याशित सर्वर प्रतिक्रिया. -pdfjs-rendering-error = पृष्ठ रेंडरिंग के दौरान त्रुटि आई. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = इस PDF फ़ाइल को खोलने के लिए कृपया कूटशब्द भरें. -pdfjs-password-invalid = अवैध कूटशब्द, कृपया फिर कोशिश करें. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = रद्द करें -pdfjs-web-fonts-disabled = वेब फॉन्ट्स निष्क्रिय हैं: अंतःस्थापित PDF फॉन्टस के उपयोग में असमर्थ. - -## Editing - -# Editor Parameters -pdfjs-editor-free-text-color-input = रंग - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/hi-IN/viewer.properties b/static/pdf.js/locale/hi-IN/viewer.properties new file mode 100644 index 00000000..d65eb921 --- /dev/null +++ b/static/pdf.js/locale/hi-IN/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=पिछला पृष्ठ +previous_label=पिछला +next.title=अगला पृष्ठ +next_label=आगे + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=पृष्ठ: +page_of={{pageCount}} का + +zoom_out.title=\u0020छोटा करें +zoom_out_label=\u0020छोटा करें +zoom_in.title=बड़ा करें +zoom_in_label=बड़ा करें +zoom.title=बड़ा-छोटा करें +presentation_mode.title=प्रस्तुति अवस्था में जाएँ +presentation_mode_label=\u0020प्रस्तुति अवस्था +open_file.title=फ़ाइल खोलें +open_file_label=\u0020खोलें +print.title=छापें +print_label=\u0020छापें +download.title=डाउनलोड +download_label=डाउनलोड +bookmark.title=मौजूदा दृश्य (नए विंडो में नक़ल लें या खोलें) +bookmark_label=\u0020मौजूदा दृश्य + +# Secondary toolbar and context menu +tools.title=औज़ार +tools_label=औज़ार +first_page.title=प्रथम पृष्ठ पर जाएँ +first_page.label=\u0020प्रथम पृष्ठ पर जाएँ +first_page_label=प्रथम पृष्ठ पर जाएँ +last_page.title=अंतिम पृष्ठ पर जाएँ +last_page.label=\u0020अंतिम पृष्ठ पर जाएँ +last_page_label=\u0020अंतिम पृष्ठ पर जाएँ +page_rotate_cw.title=घड़ी की दिशा में घुमाएँ +page_rotate_cw.label=घड़ी की दिशा में घुमाएँ +page_rotate_cw_label=घड़ी की दिशा में घुमाएँ +page_rotate_ccw.title=घड़ी की दिशा से उल्टा घुमाएँ +page_rotate_ccw.label=घड़ी की दिशा से उल्टा घुमाएँ +page_rotate_ccw_label=\u0020घड़ी की दिशा से उल्टा घुमाएँ + +hand_tool_enable.title=हाथ औजार सक्रिय करें +hand_tool_enable_label=हाथ औजार सक्रिय करें +hand_tool_disable.title=हाथ औजार निष्क्रिय करना +hand_tool_disable_label=हाथ औजार निष्क्रिय करना + +# Document properties dialog box +document_properties.title=दस्तावेज़ विशेषता... +document_properties_label=दस्तावेज़ विशेषता... +document_properties_file_name=फ़ाइल नाम: +document_properties_file_size=फाइल आकारः +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} बाइट) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} बाइट) +document_properties_title=शीर्षक: +document_properties_author=लेखकः +document_properties_subject=विषय: +document_properties_keywords=कुंजी-शब्द: +document_properties_creation_date=निर्माण दिनांक: +document_properties_modification_date=संशोधन दिनांक: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=निर्माता: +document_properties_producer=PDF उत्पादक: +document_properties_version=PDF संस्करण: +document_properties_page_count=पृष्ठ गिनती: +document_properties_close=बंद करें + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=\u0020स्लाइडर टॉगल करें +toggle_sidebar_label=स्लाइडर टॉगल करें +outline.title=\u0020दस्तावेज़ आउटलाइन दिखाएँ +outline_label=दस्तावेज़ आउटलाइन +attachments.title=संलग्नक दिखायें +attachments_label=संलग्नक +thumbs.title=लघुछवियाँ दिखाएँ +thumbs_label=लघु छवि +findbar.title=\u0020दस्तावेज़ में ढूँढ़ें +findbar_label=ढूँढ़ें + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=पृष्ठ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=पृष्ठ {{page}} की लघु-छवि + +# Find panel button title and messages +find_label=ढूंढें: +find_previous.title=वाक्यांश की पिछली उपस्थिति ढूँढ़ें +find_previous_label=पिछला +find_next.title=वाक्यांश की अगली उपस्थिति ढूँढ़ें +find_next_label=आगे +find_highlight=\u0020सभी आलोकित करें +find_match_case_label=मिलान स्थिति +find_reached_top=पृष्ठ के ऊपर पहुंच गया, नीचे से जारी रखें +find_reached_bottom=पृष्ठ के नीचे में जा पहुँचा, ऊपर से जारी +find_not_found=वाक्यांश नहीं मिला + +# Error panel labels +error_more_info=अधिक सूचना +error_less_info=कम सूचना +error_close=बंद करें +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=\u0020संदेश: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=स्टैक: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=फ़ाइल: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=पंक्ति: {{line}} +rendering_error=पृष्ठ रेंडरिंग के दौरान त्रुटि आई. + +# Predefined zoom values +page_scale_width=\u0020पृष्ठ चौड़ाई +page_scale_fit=पृष्ठ फिट +page_scale_auto=स्वचालित जूम +page_scale_actual=वास्तविक आकार +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=त्रुटि +loading_error=पीडीएफ लोड करते समय एक त्रुटि हुई. +invalid_file_error=अमान्य या भ्रष्ट PDF फ़ाइल. +missing_file_error=\u0020अनुपस्थित PDF फ़ाइल. +unexpected_response_error=अप्रत्याशित सर्वर प्रतिक्रिया. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=\u0020[{{type}} Annotation] +password_label=इस पीडीएफ फ़ाइल को खोलने के लिए कृपया कूटशब्द भरें. +password_invalid=अवैध कूटशब्द, कृपया फिर कोशिश करें. +password_ok=ठीक +password_cancel=रद्द करें + +printing_not_supported=चेतावनी: इस ब्राउज़र पर छपाई पूरी तरह से समर्थित नहीं है. +printing_not_ready=\u0020चेतावनी: पीडीएफ छपाई के लिए पूरी तरह से लोड नहीं है. +web_fonts_disabled=वेब फॉन्ट्स निष्क्रिय हैं: अंतःस्थापित PDF फॉन्टस के उपयोग में असमर्थ. +document_colors_not_allowed=PDF दस्तावेज़ उनके अपने रंग को उपयोग करने के लिए अनुमति प्राप्त नहीं है: 'पृष्ठों को उनके अपने रंग को चुनने के लिए स्वीकृति दें कि वह उस ब्राउज़र में निष्क्रिय है. diff --git a/static/pdf.js/locale/hr/viewer.ftl b/static/pdf.js/locale/hr/viewer.ftl deleted file mode 100644 index 23d88e76..00000000 --- a/static/pdf.js/locale/hr/viewer.ftl +++ /dev/null @@ -1,279 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Prethodna stranica -pdfjs-previous-button-label = Prethodna -pdfjs-next-button = - .title = Sljedeća stranica -pdfjs-next-button-label = Sljedeća -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Stranica -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = od { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } od { $pagesCount }) -pdfjs-zoom-out-button = - .title = Umanji -pdfjs-zoom-out-button-label = Umanji -pdfjs-zoom-in-button = - .title = Uvećaj -pdfjs-zoom-in-button-label = Uvećaj -pdfjs-zoom-select = - .title = Zumiranje -pdfjs-presentation-mode-button = - .title = Prebaci u prezentacijski način rada -pdfjs-presentation-mode-button-label = Prezentacijski način rada -pdfjs-open-file-button = - .title = Otvori datoteku -pdfjs-open-file-button-label = Otvori -pdfjs-print-button = - .title = Ispiši -pdfjs-print-button-label = Ispiši -pdfjs-save-button = - .title = Spremi -pdfjs-save-button-label = Spremi - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Alati -pdfjs-tools-button-label = Alati -pdfjs-first-page-button = - .title = Idi na prvu stranicu -pdfjs-first-page-button-label = Idi na prvu stranicu -pdfjs-last-page-button = - .title = Idi na posljednju stranicu -pdfjs-last-page-button-label = Idi na posljednju stranicu -pdfjs-page-rotate-cw-button = - .title = Rotiraj u smjeru kazaljke na satu -pdfjs-page-rotate-cw-button-label = Rotiraj u smjeru kazaljke na satu -pdfjs-page-rotate-ccw-button = - .title = Rotiraj obrnutno od smjera kazaljke na satu -pdfjs-page-rotate-ccw-button-label = Rotiraj obrnutno od smjera kazaljke na satu -pdfjs-cursor-text-select-tool-button = - .title = Omogući alat za označavanje teksta -pdfjs-cursor-text-select-tool-button-label = Alat za označavanje teksta -pdfjs-cursor-hand-tool-button = - .title = Omogući ručni alat -pdfjs-cursor-hand-tool-button-label = Ručni alat -pdfjs-scroll-vertical-button = - .title = Koristi okomito pomicanje -pdfjs-scroll-vertical-button-label = Okomito pomicanje -pdfjs-scroll-horizontal-button = - .title = Koristi vodoravno pomicanje -pdfjs-scroll-horizontal-button-label = Vodoravno pomicanje -pdfjs-scroll-wrapped-button = - .title = Koristi kontinuirani raspored stranica -pdfjs-scroll-wrapped-button-label = Kontinuirani raspored stranica -pdfjs-spread-none-button = - .title = Ne izrađuj duplerice -pdfjs-spread-none-button-label = Pojedinačne stranice -pdfjs-spread-odd-button = - .title = Izradi duplerice koje počinju s neparnim stranicama -pdfjs-spread-odd-button-label = Neparne duplerice -pdfjs-spread-even-button = - .title = Izradi duplerice koje počinju s parnim stranicama -pdfjs-spread-even-button-label = Parne duplerice - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Svojstva dokumenta … -pdfjs-document-properties-button-label = Svojstva dokumenta … -pdfjs-document-properties-file-name = Naziv datoteke: -pdfjs-document-properties-file-size = Veličina datoteke: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bajtova) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bajtova) -pdfjs-document-properties-title = Naslov: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Predmet: -pdfjs-document-properties-keywords = Ključne riječi: -pdfjs-document-properties-creation-date = Datum stvaranja: -pdfjs-document-properties-modification-date = Datum promjene: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Stvaratelj: -pdfjs-document-properties-producer = PDF stvaratelj: -pdfjs-document-properties-version = PDF verzija: -pdfjs-document-properties-page-count = Broj stranica: -pdfjs-document-properties-page-size = Dimenzije stranice: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = uspravno -pdfjs-document-properties-page-size-orientation-landscape = položeno -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Brzi web pregled: -pdfjs-document-properties-linearized-yes = Da -pdfjs-document-properties-linearized-no = Ne -pdfjs-document-properties-close-button = Zatvori - -## Print - -pdfjs-print-progress-message = Pripremanje dokumenta za ispis… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Odustani -pdfjs-printing-not-supported = Upozorenje: Ovaj preglednik ne podržava u potpunosti ispisivanje. -pdfjs-printing-not-ready = Upozorenje: PDF nije u potpunosti učitan za ispis. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Prikaži/sakrij bočnu traku -pdfjs-toggle-sidebar-notification-button = - .title = Prikazivanje i sklanjanje bočne trake (dokument sadrži strukturu/privitke/slojeve) -pdfjs-toggle-sidebar-button-label = Prikaži/sakrij bočnu traku -pdfjs-document-outline-button = - .title = Prikaži strukturu dokumenta (dvostruki klik za rasklapanje/sklapanje svih stavki) -pdfjs-document-outline-button-label = Struktura dokumenta -pdfjs-attachments-button = - .title = Prikaži privitke -pdfjs-attachments-button-label = Privitci -pdfjs-layers-button = - .title = Prikaži slojeve (dvoklik za vraćanje svih slojeva u zadano stanje) -pdfjs-layers-button-label = Slojevi -pdfjs-thumbs-button = - .title = Prikaži minijature -pdfjs-thumbs-button-label = Minijature -pdfjs-current-outline-item-button = - .title = Pronađi trenutačni element strukture -pdfjs-current-outline-item-button-label = Trenutačni element strukture -pdfjs-findbar-button = - .title = Pronađi u dokumentu -pdfjs-findbar-button-label = Pronađi -pdfjs-additional-layers = Dodatni slojevi - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Stranica { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Minijatura stranice { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Pronađi - .placeholder = Pronađi u dokumentu … -pdfjs-find-previous-button = - .title = Pronađi prethodno pojavljivanje ovog izraza -pdfjs-find-previous-button-label = Prethodno -pdfjs-find-next-button = - .title = Pronađi sljedeće pojavljivanje ovog izraza -pdfjs-find-next-button-label = Sljedeće -pdfjs-find-highlight-checkbox = Istankni sve -pdfjs-find-match-case-checkbox-label = Razlikovanje velikih i malih slova -pdfjs-find-entire-word-checkbox-label = Cijele riječi -pdfjs-find-reached-top = Dosegnut početak dokumenta, nastavak s kraja -pdfjs-find-reached-bottom = Dosegnut kraj dokumenta, nastavak s početka -pdfjs-find-not-found = Izraz nije pronađen - -## Predefined zoom values - -pdfjs-page-scale-width = Prilagodi širini prozora -pdfjs-page-scale-fit = Prilagodi veličini prozora -pdfjs-page-scale-auto = Automatsko zumiranje -pdfjs-page-scale-actual = Stvarna veličina -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale } % - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Stranica { $page } - -## Loading indicator messages - -pdfjs-loading-error = Došlo je do greške pri učitavanju PDF-a. -pdfjs-invalid-file-error = Neispravna ili oštećena PDF datoteka. -pdfjs-missing-file-error = Nedostaje PDF datoteka. -pdfjs-unexpected-response-error = Neočekivani odgovor poslužitelja. -pdfjs-rendering-error = Došlo je do greške prilikom iscrtavanja stranice. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Bilješka] - -## Password - -pdfjs-password-label = Za otvoranje ove PDF datoteku upiši lozinku. -pdfjs-password-invalid = Neispravna lozinka. Pokušaj ponovo. -pdfjs-password-ok-button = U redu -pdfjs-password-cancel-button = Odustani -pdfjs-web-fonts-disabled = Web fontovi su deaktivirani: nije moguće koristiti ugrađene PDF fontove. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -# Editor Parameters -pdfjs-editor-free-text-color-input = Boja -pdfjs-editor-free-text-size-input = Veličina -pdfjs-editor-ink-color-input = Boja -pdfjs-editor-ink-thickness-input = Debljina -pdfjs-editor-ink-opacity-input = Neprozirnost -pdfjs-free-text = - .aria-label = Uređivač teksta -pdfjs-free-text-default-content = Počni tipkati … - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/hr/viewer.properties b/static/pdf.js/locale/hr/viewer.properties new file mode 100644 index 00000000..83cc5d9b --- /dev/null +++ b/static/pdf.js/locale/hr/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Prethodna stranica +previous_label=Prethodna +next.title=Sljedeća stranica +next_label=Sljedeća + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Stranica: +page_of=od {{pageCount}} + +zoom_out.title=Uvećaj +zoom_out_label=Smanji +zoom_in.title=Uvećaj +zoom_in_label=Smanji +zoom.title=Uvećanje +presentation_mode.title=Prebaci u prezentacijski način rada +presentation_mode_label=Prezentacijski način rada +open_file.title=Otvori datoteku +open_file_label=Otvori +print.title=Ispis +print_label=Ispis +download.title=Preuzmi +download_label=Preuzmi +bookmark.title=Trenutni prikaz (kopiraj ili otvori u novom prozoru) +bookmark_label=Trenutni prikaz + +# Secondary toolbar and context menu +tools.title=Alati +tools_label=Alati +first_page.title=Idi na prvu stranicu +first_page.label=Idi na prvu stranicu +first_page_label=Idi na prvu stranicu +last_page.title=Idi na posljednju stranicu +last_page.label=Idi na posljednju stranicu +last_page_label=Idi na posljednju stranicu +page_rotate_cw.title=Rotiraj u smjeru kazaljke na satu +page_rotate_cw.label=Rotiraj u smjeru kazaljke na satu +page_rotate_cw_label=Rotiraj u smjeru kazaljke na satu +page_rotate_ccw.title=Rotiraj obrnutno od smjera kazaljke na satu +page_rotate_ccw.label=Rotiraj obrnutno od smjera kazaljke na satu +page_rotate_ccw_label=Rotiraj obrnutno od smjera kazaljke na satu + +hand_tool_enable.title=Omogući ručni alat +hand_tool_enable_label=Omogući ručni alat +hand_tool_disable.title=Onemogući ručni alat +hand_tool_disable_label=Onemogući ručni alat + +# Document properties dialog box +document_properties.title=Svojstva dokumenta... +document_properties_label=Svojstva dokumenta... +document_properties_file_name=Naziv datoteke: +document_properties_file_size=Veličina datoteke: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bajtova) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bajtova) +document_properties_title=Naslov: +document_properties_author=Autor: +document_properties_subject=Predmet: +document_properties_keywords=Ključne riječi: +document_properties_creation_date=Datum stvaranja: +document_properties_modification_date=Datum promjene: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Stvaratelj: +document_properties_producer=PDF stvaratelj: +document_properties_version=PDF inačica: +document_properties_page_count=Broj stranica: +document_properties_close=Zatvori + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Prikaži/sakrij bočnu traku +toggle_sidebar_label=Prikaži/sakrij bočnu traku +outline.title=Prikaži obris dokumenta +outline_label=Obris dokumenta +attachments.title=Prikaži privitke +attachments_label=Privitci +thumbs.title=Prikaži sličice +thumbs_label=Sličice +findbar.title=Traži u dokumentu +findbar_label=Traži + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Stranica {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Sličica stranice {{page}} + +# Find panel button title and messages +find_label=Traži: +find_previous.title=Pronađi prethodno javljanje ovog izraza +find_previous_label=Prethodno +find_next.title=Pronađi iduće javljanje ovog izraza +find_next_label=Sljedeće +find_highlight=Istankni sve +find_match_case_label=Slučaj podudaranja +find_reached_top=Dosegnut vrh dokumenta, nastavak od dna +find_reached_bottom=Dosegnut vrh dokumenta, nastavak od vrha +find_not_found=Izraz nije pronađen + +# Error panel labels +error_more_info=Više informacija +error_less_info=Manje informacija +error_close=Zatvori +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Poruka: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stog: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Datoteka: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Redak: {{line}} +rendering_error=Došlo je do greške prilikom iscrtavanja stranice. + +# Predefined zoom values +page_scale_width=Širina stranice +page_scale_fit=Pristajanje stranici +page_scale_auto=Automatsko uvećanje +page_scale_actual=Prava veličina +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Greška +loading_error=Došlo je do greške pri učitavanju PDF-a. +invalid_file_error=Kriva ili oštećena PDF datoteka. +missing_file_error=Nedostaje PDF datoteka. +unexpected_response_error=Neočekivani odgovor poslužitelja. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Bilješka] +password_label=Upišite lozinku da biste otvorili ovu PDF datoteku. +password_invalid=Neispravna lozinka. Pokušajte ponovo. +password_ok=U redu +password_cancel=Odustani + +printing_not_supported=Upozorenje: Ispisivanje nije potpuno podržano u ovom pregledniku. +printing_not_ready=Upozorenje: PDF nije u potpunosti učitan za ispis. +web_fonts_disabled=Web fontovi su onemogućeni: nije moguće koristiti umetnute PDF fontove. +document_colors_not_allowed=PDF dokumenti nemaju dopuštene koristiti vlastite boje: opcija 'Dopusti stranicama da koriste vlastite boje' je deaktivirana. diff --git a/static/pdf.js/locale/hsb/viewer.ftl b/static/pdf.js/locale/hsb/viewer.ftl deleted file mode 100644 index 46feaf1b..00000000 --- a/static/pdf.js/locale/hsb/viewer.ftl +++ /dev/null @@ -1,406 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Předchadna strona -pdfjs-previous-button-label = Wróćo -pdfjs-next-button = - .title = Přichodna strona -pdfjs-next-button-label = Dale -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Strona -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = z { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } z { $pagesCount }) -pdfjs-zoom-out-button = - .title = Pomjeńšić -pdfjs-zoom-out-button-label = Pomjeńšić -pdfjs-zoom-in-button = - .title = Powjetšić -pdfjs-zoom-in-button-label = Powjetšić -pdfjs-zoom-select = - .title = Skalowanje -pdfjs-presentation-mode-button = - .title = Do prezentaciskeho modusa přeńć -pdfjs-presentation-mode-button-label = Prezentaciski modus -pdfjs-open-file-button = - .title = Dataju wočinić -pdfjs-open-file-button-label = Wočinić -pdfjs-print-button = - .title = Ćišćeć -pdfjs-print-button-label = Ćišćeć -pdfjs-save-button = - .title = Składować -pdfjs-save-button-label = Składować -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Sćahnyć -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Sćahnyć -pdfjs-bookmark-button = - .title = Aktualna strona (URL z aktualneje strony pokazać) -pdfjs-bookmark-button-label = Aktualna strona -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = W nałoženju wočinić -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = W nałoženju wočinić - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Nastroje -pdfjs-tools-button-label = Nastroje -pdfjs-first-page-button = - .title = K prěnjej stronje -pdfjs-first-page-button-label = K prěnjej stronje -pdfjs-last-page-button = - .title = K poslednjej stronje -pdfjs-last-page-button-label = K poslednjej stronje -pdfjs-page-rotate-cw-button = - .title = K směrej časnika wjerćeć -pdfjs-page-rotate-cw-button-label = K směrej časnika wjerćeć -pdfjs-page-rotate-ccw-button = - .title = Přećiwo směrej časnika wjerćeć -pdfjs-page-rotate-ccw-button-label = Přećiwo směrej časnika wjerćeć -pdfjs-cursor-text-select-tool-button = - .title = Nastroj za wuběranje teksta zmóžnić -pdfjs-cursor-text-select-tool-button-label = Nastroj za wuběranje teksta -pdfjs-cursor-hand-tool-button = - .title = Ručny nastroj zmóžnić -pdfjs-cursor-hand-tool-button-label = Ručny nastroj -pdfjs-scroll-page-button = - .title = Kulenje strony wužiwać -pdfjs-scroll-page-button-label = Kulenje strony -pdfjs-scroll-vertical-button = - .title = Wertikalne suwanje wužiwać -pdfjs-scroll-vertical-button-label = Wertikalne suwanje -pdfjs-scroll-horizontal-button = - .title = Horicontalne suwanje wužiwać -pdfjs-scroll-horizontal-button-label = Horicontalne suwanje -pdfjs-scroll-wrapped-button = - .title = Postupne suwanje wužiwać -pdfjs-scroll-wrapped-button-label = Postupne suwanje -pdfjs-spread-none-button = - .title = Strony njezwjazać -pdfjs-spread-none-button-label = Žana dwójna strona -pdfjs-spread-odd-button = - .title = Strony započinajo z njerunymi stronami zwjazać -pdfjs-spread-odd-button-label = Njerune strony -pdfjs-spread-even-button = - .title = Strony započinajo z runymi stronami zwjazać -pdfjs-spread-even-button-label = Rune strony - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumentowe kajkosće… -pdfjs-document-properties-button-label = Dokumentowe kajkosće… -pdfjs-document-properties-file-name = Mjeno dataje: -pdfjs-document-properties-file-size = Wulkosć dataje: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bajtow) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bajtow) -pdfjs-document-properties-title = Titul: -pdfjs-document-properties-author = Awtor: -pdfjs-document-properties-subject = Předmjet: -pdfjs-document-properties-keywords = Klučowe słowa: -pdfjs-document-properties-creation-date = Datum wutworjenja: -pdfjs-document-properties-modification-date = Datum změny: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Awtor: -pdfjs-document-properties-producer = PDF-zhotowjer: -pdfjs-document-properties-version = PDF-wersija: -pdfjs-document-properties-page-count = Ličba stronow: -pdfjs-document-properties-page-size = Wulkosć strony: -pdfjs-document-properties-page-size-unit-inches = cól -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = wysoki format -pdfjs-document-properties-page-size-orientation-landscape = prěčny format -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Haj -pdfjs-document-properties-linearized-no = Ně -pdfjs-document-properties-close-button = Začinić - -## Print - -pdfjs-print-progress-message = Dokument so za ćišćenje přihotuje… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Přetorhnyć -pdfjs-printing-not-supported = Warnowanje: Ćišćenje so přez tutón wobhladowak połnje njepodpěruje. -pdfjs-printing-not-ready = Warnowanje: PDF njeje so za ćišćenje dospołnje začitał. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Bóčnicu pokazać/schować -pdfjs-toggle-sidebar-notification-button = - .title = Bóčnicu přepinać (dokument rozrjad/přiwěški/woršty wobsahuje) -pdfjs-toggle-sidebar-button-label = Bóčnicu pokazać/schować -pdfjs-document-outline-button = - .title = Dokumentowy naćisk pokazać (dwójne kliknjenje, zo bychu so wšě zapiski pokazali/schowali) -pdfjs-document-outline-button-label = Dokumentowa struktura -pdfjs-attachments-button = - .title = Přiwěški pokazać -pdfjs-attachments-button-label = Přiwěški -pdfjs-layers-button = - .title = Woršty pokazać (klikńće dwójce, zo byšće wšě woršty na standardny staw wróćo stajił) -pdfjs-layers-button-label = Woršty -pdfjs-thumbs-button = - .title = Miniatury pokazać -pdfjs-thumbs-button-label = Miniatury -pdfjs-current-outline-item-button = - .title = Aktualny rozrjadowy zapisk pytać -pdfjs-current-outline-item-button-label = Aktualny rozrjadowy zapisk -pdfjs-findbar-button = - .title = W dokumenće pytać -pdfjs-findbar-button-label = Pytać -pdfjs-additional-layers = Dalše woršty - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Strona { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura strony { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Pytać - .placeholder = W dokumenće pytać… -pdfjs-find-previous-button = - .title = Předchadne wustupowanje pytanskeho wuraza pytać -pdfjs-find-previous-button-label = Wróćo -pdfjs-find-next-button = - .title = Přichodne wustupowanje pytanskeho wuraza pytać -pdfjs-find-next-button-label = Dale -pdfjs-find-highlight-checkbox = Wšě wuzběhnyć -pdfjs-find-match-case-checkbox-label = Wulkopisanje wobkedźbować -pdfjs-find-match-diacritics-checkbox-label = Diakritiske znamješka wužiwać -pdfjs-find-entire-word-checkbox-label = Cyłe słowa -pdfjs-find-reached-top = Spočatk dokumenta docpěty, pokročuje so z kóncom -pdfjs-find-reached-bottom = Kónc dokument docpěty, pokročuje so ze spočatkom -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } z { $total } wotpowědnika - [two] { $current } z { $total } wotpowědnikow - [few] { $current } z { $total } wotpowědnikow - *[other] { $current } z { $total } wotpowědnikow - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Wyše { $limit } wotpowědnik - [two] Wyše { $limit } wotpowědnikaj - [few] Wyše { $limit } wotpowědniki - *[other] Wyše { $limit } wotpowědnikow - } -pdfjs-find-not-found = Pytanski wuraz njeje so namakał - -## Predefined zoom values - -pdfjs-page-scale-width = Šěrokosć strony -pdfjs-page-scale-fit = Wulkosć strony -pdfjs-page-scale-auto = Awtomatiske skalowanje -pdfjs-page-scale-actual = Aktualna wulkosć -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Strona { $page } - -## Loading indicator messages - -pdfjs-loading-error = Při začitowanju PDF je zmylk wustupił. -pdfjs-invalid-file-error = Njepłaćiwa abo wobškodźena PDF-dataja. -pdfjs-missing-file-error = Falowaca PDF-dataja. -pdfjs-unexpected-response-error = Njewočakowana serwerowa wotmołwa. -pdfjs-rendering-error = Při zwobraznjenju strony je zmylk wustupił. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Typ přispomnjenki: { $type }] - -## Password - -pdfjs-password-label = Zapodajće hesło, zo byšće PDF-dataju wočinił. -pdfjs-password-invalid = Njepłaćiwe hesło. Prošu spytajće hišće raz. -pdfjs-password-ok-button = W porjadku -pdfjs-password-cancel-button = Přetorhnyć -pdfjs-web-fonts-disabled = Webpisma su znjemóžnjene: njeje móžno, zasadźene PDF-pisma wužiwać. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Rysować -pdfjs-editor-ink-button-label = Rysować -pdfjs-editor-stamp-button = - .title = Wobrazy přidać abo wobdźěłać -pdfjs-editor-stamp-button-label = Wobrazy přidać abo wobdźěłać -pdfjs-editor-highlight-button = - .title = Wuzběhnyć -pdfjs-editor-highlight-button-label = Wuzběhnyć -pdfjs-highlight-floating-button = - .title = Wuzběhnyć -pdfjs-highlight-floating-button1 = - .title = Wuzběhnjenje - .aria-label = Wuzběhnjenje -pdfjs-highlight-floating-button-label = Wuzběhnjenje - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Rysowanku wotstronić -pdfjs-editor-remove-freetext-button = - .title = Tekst wotstronić -pdfjs-editor-remove-stamp-button = - .title = Wobraz wotstronić -pdfjs-editor-remove-highlight-button = - .title = Wuzběhnjenje wotstronić - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Barba -pdfjs-editor-free-text-size-input = Wulkosć -pdfjs-editor-ink-color-input = Barba -pdfjs-editor-ink-thickness-input = Tołstosć -pdfjs-editor-ink-opacity-input = Opacita -pdfjs-editor-stamp-add-image-button = - .title = Wobraz přidać -pdfjs-editor-stamp-add-image-button-label = Wobraz přidać -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tołstosć -pdfjs-editor-free-highlight-thickness-title = - .title = Tołstosć změnić, hdyž so zapiski wuzběhuja, kotrež tekst njejsu -pdfjs-free-text = - .aria-label = Tekstowy editor -pdfjs-free-text-default-content = Započńće pisać… -pdfjs-ink = - .aria-label = Rysowanski editor -pdfjs-ink-canvas = - .aria-label = Wobraz wutworjeny wot wužiwarja - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternatiwny tekst -pdfjs-editor-alt-text-edit-button-label = Alternatiwny tekst wobdźěłać -pdfjs-editor-alt-text-dialog-label = Nastajenje wubrać -pdfjs-editor-alt-text-dialog-description = Alternatiwny tekst pomha, hdyž ludźo njemóža wobraz widźeć abo hdyž so wobraz njezačita. -pdfjs-editor-alt-text-add-description-label = Wopisanje přidać -pdfjs-editor-alt-text-add-description-description = Pisajće 1 sadu abo 2 sadźe, kotrejž temu, nastajenje abo akcije wopisujetej. -pdfjs-editor-alt-text-mark-decorative-label = Jako dekoratiwny markěrować -pdfjs-editor-alt-text-mark-decorative-description = To so za pyšace wobrazy wužiwa, na přikład ramiki abo wodowe znamjenja. -pdfjs-editor-alt-text-cancel-button = Přetorhnyć -pdfjs-editor-alt-text-save-button = Składować -pdfjs-editor-alt-text-decorative-tooltip = Jako dekoratiwny markěrowany -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Na přikład, „Młody muž za blidom sedźi, zo by jědź jědł“ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Horjeka nalěwo – wulkosć změnić -pdfjs-editor-resizer-label-top-middle = Horjeka wosrjedź – wulkosć změnić -pdfjs-editor-resizer-label-top-right = Horjeka naprawo – wulkosć změnić -pdfjs-editor-resizer-label-middle-right = Wosrjedź naprawo – wulkosć změnić -pdfjs-editor-resizer-label-bottom-right = Deleka naprawo – wulkosć změnić -pdfjs-editor-resizer-label-bottom-middle = Deleka wosrjedź – wulkosć změnić -pdfjs-editor-resizer-label-bottom-left = Deleka nalěwo – wulkosć změnić -pdfjs-editor-resizer-label-middle-left = Wosrjedź nalěwo – wulkosć změnić - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Barba wuzběhnjenja -pdfjs-editor-colorpicker-button = - .title = Barbu změnić -pdfjs-editor-colorpicker-dropdown = - .aria-label = Wuběr barbow -pdfjs-editor-colorpicker-yellow = - .title = Žołty -pdfjs-editor-colorpicker-green = - .title = Zeleny -pdfjs-editor-colorpicker-blue = - .title = Módry -pdfjs-editor-colorpicker-pink = - .title = Pink -pdfjs-editor-colorpicker-red = - .title = Čerwjeny - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Wšě pokazać -pdfjs-editor-highlight-show-all-button = - .title = Wšě pokazać diff --git a/static/pdf.js/locale/hu/viewer.ftl b/static/pdf.js/locale/hu/viewer.ftl deleted file mode 100644 index 0c33e51b..00000000 --- a/static/pdf.js/locale/hu/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Előző oldal -pdfjs-previous-button-label = Előző -pdfjs-next-button = - .title = Következő oldal -pdfjs-next-button-label = Tovább -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Oldal -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = összesen: { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } / { $pagesCount }) -pdfjs-zoom-out-button = - .title = Kicsinyítés -pdfjs-zoom-out-button-label = Kicsinyítés -pdfjs-zoom-in-button = - .title = Nagyítás -pdfjs-zoom-in-button-label = Nagyítás -pdfjs-zoom-select = - .title = Nagyítás -pdfjs-presentation-mode-button = - .title = Váltás bemutató módba -pdfjs-presentation-mode-button-label = Bemutató mód -pdfjs-open-file-button = - .title = Fájl megnyitása -pdfjs-open-file-button-label = Megnyitás -pdfjs-print-button = - .title = Nyomtatás -pdfjs-print-button-label = Nyomtatás -pdfjs-save-button = - .title = Mentés -pdfjs-save-button-label = Mentés -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Letöltés -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Letöltés -pdfjs-bookmark-button = - .title = Jelenlegi oldal (webcím megtekintése a jelenlegi oldalról) -pdfjs-bookmark-button-label = Jelenlegi oldal - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Eszközök -pdfjs-tools-button-label = Eszközök -pdfjs-first-page-button = - .title = Ugrás az első oldalra -pdfjs-first-page-button-label = Ugrás az első oldalra -pdfjs-last-page-button = - .title = Ugrás az utolsó oldalra -pdfjs-last-page-button-label = Ugrás az utolsó oldalra -pdfjs-page-rotate-cw-button = - .title = Forgatás az óramutató járásával egyezően -pdfjs-page-rotate-cw-button-label = Forgatás az óramutató járásával egyezően -pdfjs-page-rotate-ccw-button = - .title = Forgatás az óramutató járásával ellentétesen -pdfjs-page-rotate-ccw-button-label = Forgatás az óramutató járásával ellentétesen -pdfjs-cursor-text-select-tool-button = - .title = Szövegkijelölő eszköz bekapcsolása -pdfjs-cursor-text-select-tool-button-label = Szövegkijelölő eszköz -pdfjs-cursor-hand-tool-button = - .title = Kéz eszköz bekapcsolása -pdfjs-cursor-hand-tool-button-label = Kéz eszköz -pdfjs-scroll-page-button = - .title = Oldalgörgetés használata -pdfjs-scroll-page-button-label = Oldalgörgetés -pdfjs-scroll-vertical-button = - .title = Függőleges görgetés használata -pdfjs-scroll-vertical-button-label = Függőleges görgetés -pdfjs-scroll-horizontal-button = - .title = Vízszintes görgetés használata -pdfjs-scroll-horizontal-button-label = Vízszintes görgetés -pdfjs-scroll-wrapped-button = - .title = Rácsos elrendezés használata -pdfjs-scroll-wrapped-button-label = Rácsos elrendezés -pdfjs-spread-none-button = - .title = Ne tapassza össze az oldalakat -pdfjs-spread-none-button-label = Nincs összetapasztás -pdfjs-spread-odd-button = - .title = Lapok összetapasztása, a páratlan számú oldalakkal kezdve -pdfjs-spread-odd-button-label = Összetapasztás: páratlan -pdfjs-spread-even-button = - .title = Lapok összetapasztása, a páros számú oldalakkal kezdve -pdfjs-spread-even-button-label = Összetapasztás: páros - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumentum tulajdonságai… -pdfjs-document-properties-button-label = Dokumentum tulajdonságai… -pdfjs-document-properties-file-name = Fájlnév: -pdfjs-document-properties-file-size = Fájlméret: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bájt) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bájt) -pdfjs-document-properties-title = Cím: -pdfjs-document-properties-author = Szerző: -pdfjs-document-properties-subject = Tárgy: -pdfjs-document-properties-keywords = Kulcsszavak: -pdfjs-document-properties-creation-date = Létrehozás dátuma: -pdfjs-document-properties-modification-date = Módosítás dátuma: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Létrehozta: -pdfjs-document-properties-producer = PDF előállító: -pdfjs-document-properties-version = PDF verzió: -pdfjs-document-properties-page-count = Oldalszám: -pdfjs-document-properties-page-size = Lapméret: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = álló -pdfjs-document-properties-page-size-orientation-landscape = fekvő -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Jogi információk - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Gyors webes nézet: -pdfjs-document-properties-linearized-yes = Igen -pdfjs-document-properties-linearized-no = Nem -pdfjs-document-properties-close-button = Bezárás - -## Print - -pdfjs-print-progress-message = Dokumentum előkészítése nyomtatáshoz… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Mégse -pdfjs-printing-not-supported = Figyelmeztetés: Ez a böngésző nem teljesen támogatja a nyomtatást. -pdfjs-printing-not-ready = Figyelmeztetés: A PDF nincs teljesen betöltve a nyomtatáshoz. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Oldalsáv be/ki -pdfjs-toggle-sidebar-notification-button = - .title = Oldalsáv be/ki (a dokumentum vázlatot/mellékleteket/rétegeket tartalmaz) -pdfjs-toggle-sidebar-button-label = Oldalsáv be/ki -pdfjs-document-outline-button = - .title = Dokumentum megjelenítése online (dupla kattintás minden elem kinyitásához/összecsukásához) -pdfjs-document-outline-button-label = Dokumentumvázlat -pdfjs-attachments-button = - .title = Mellékletek megjelenítése -pdfjs-attachments-button-label = Van melléklet -pdfjs-layers-button = - .title = Rétegek megjelenítése (dupla kattintás az összes réteg alapértelmezett állapotra visszaállításához) -pdfjs-layers-button-label = Rétegek -pdfjs-thumbs-button = - .title = Bélyegképek megjelenítése -pdfjs-thumbs-button-label = Bélyegképek -pdfjs-current-outline-item-button = - .title = Jelenlegi vázlatelem megkeresése -pdfjs-current-outline-item-button-label = Jelenlegi vázlatelem -pdfjs-findbar-button = - .title = Keresés a dokumentumban -pdfjs-findbar-button-label = Keresés -pdfjs-additional-layers = További rétegek - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page }. oldal -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page }. oldal bélyegképe - -## Find panel button title and messages - -pdfjs-find-input = - .title = Keresés - .placeholder = Keresés a dokumentumban… -pdfjs-find-previous-button = - .title = A kifejezés előző előfordulásának keresése -pdfjs-find-previous-button-label = Előző -pdfjs-find-next-button = - .title = A kifejezés következő előfordulásának keresése -pdfjs-find-next-button-label = Tovább -pdfjs-find-highlight-checkbox = Összes kiemelése -pdfjs-find-match-case-checkbox-label = Kis- és nagybetűk megkülönböztetése -pdfjs-find-match-diacritics-checkbox-label = Diakritikus jelek -pdfjs-find-entire-word-checkbox-label = Teljes szavak -pdfjs-find-reached-top = A dokumentum eleje elérve, folytatás a végétől -pdfjs-find-reached-bottom = A dokumentum vége elérve, folytatás az elejétől -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } / { $total } találat - *[other] { $current } / { $total } találat - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Több mint { $limit } találat - *[other] Több mint { $limit } találat - } -pdfjs-find-not-found = A kifejezés nem található - -## Predefined zoom values - -pdfjs-page-scale-width = Oldalszélesség -pdfjs-page-scale-fit = Teljes oldal -pdfjs-page-scale-auto = Automatikus nagyítás -pdfjs-page-scale-actual = Valódi méret -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = { $page }. oldal - -## Loading indicator messages - -pdfjs-loading-error = Hiba történt a PDF betöltésekor. -pdfjs-invalid-file-error = Érvénytelen vagy sérült PDF fájl. -pdfjs-missing-file-error = Hiányzó PDF fájl. -pdfjs-unexpected-response-error = Váratlan kiszolgálóválasz. -pdfjs-rendering-error = Hiba történt az oldal feldolgozása közben. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } megjegyzés] - -## Password - -pdfjs-password-label = Adja meg a jelszót a PDF fájl megnyitásához. -pdfjs-password-invalid = Helytelen jelszó. Próbálja újra. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Mégse -pdfjs-web-fonts-disabled = Webes betűkészletek letiltva: nem használhatók a beágyazott PDF betűkészletek. - -## Editing - -pdfjs-editor-free-text-button = - .title = Szöveg -pdfjs-editor-free-text-button-label = Szöveg -pdfjs-editor-ink-button = - .title = Rajzolás -pdfjs-editor-ink-button-label = Rajzolás -pdfjs-editor-stamp-button = - .title = Képek hozzáadása vagy szerkesztése -pdfjs-editor-stamp-button-label = Képek hozzáadása vagy szerkesztése -pdfjs-editor-highlight-button = - .title = Kiemelés -pdfjs-editor-highlight-button-label = Kiemelés -pdfjs-highlight-floating-button = - .title = Kiemelés -pdfjs-highlight-floating-button1 = - .title = Kiemelés - .aria-label = Kiemelés -pdfjs-highlight-floating-button-label = Kiemelés - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Rajz eltávolítása -pdfjs-editor-remove-freetext-button = - .title = Szöveg eltávolítása -pdfjs-editor-remove-stamp-button = - .title = Kép eltávolítása -pdfjs-editor-remove-highlight-button = - .title = Kiemelés eltávolítása - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Szín -pdfjs-editor-free-text-size-input = Méret -pdfjs-editor-ink-color-input = Szín -pdfjs-editor-ink-thickness-input = Vastagság -pdfjs-editor-ink-opacity-input = Átlátszatlanság -pdfjs-editor-stamp-add-image-button = - .title = Kép hozzáadása -pdfjs-editor-stamp-add-image-button-label = Kép hozzáadása -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Vastagság -pdfjs-editor-free-highlight-thickness-title = - .title = Vastagság módosítása, ha nem szöveges elemeket emel ki -pdfjs-free-text = - .aria-label = Szövegszerkesztő -pdfjs-free-text-default-content = Kezdjen el gépelni… -pdfjs-ink = - .aria-label = Rajzszerkesztő -pdfjs-ink-canvas = - .aria-label = Felhasználó által készített kép - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternatív szöveg -pdfjs-editor-alt-text-edit-button-label = Alternatív szöveg szerkesztése -pdfjs-editor-alt-text-dialog-label = Válasszon egy lehetőséget -pdfjs-editor-alt-text-dialog-description = Az alternatív szöveg segít, ha az emberek nem látják a képet, vagy ha az nem töltődik be. -pdfjs-editor-alt-text-add-description-label = Leírás hozzáadása -pdfjs-editor-alt-text-add-description-description = Törekedjen 1-2 mondatra, amely jellemzi a témát, környezetet vagy cselekvést. -pdfjs-editor-alt-text-mark-decorative-label = Megjelölés dekoratívként -pdfjs-editor-alt-text-mark-decorative-description = Ez a díszítőképeknél használatos, mint a szegélyek vagy a vízjelek. -pdfjs-editor-alt-text-cancel-button = Mégse -pdfjs-editor-alt-text-save-button = Mentés -pdfjs-editor-alt-text-decorative-tooltip = Megjelölve dekoratívként -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Például: „Egy fiatal férfi leül enni egy asztalhoz” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Bal felső sarok – átméretezés -pdfjs-editor-resizer-label-top-middle = Felül középen – átméretezés -pdfjs-editor-resizer-label-top-right = Jobb felső sarok – átméretezés -pdfjs-editor-resizer-label-middle-right = Jobbra középen – átméretezés -pdfjs-editor-resizer-label-bottom-right = Jobb alsó sarok – átméretezés -pdfjs-editor-resizer-label-bottom-middle = Alul középen – átméretezés -pdfjs-editor-resizer-label-bottom-left = Bal alsó sarok – átméretezés -pdfjs-editor-resizer-label-middle-left = Balra középen – átméretezés - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Kiemelés színe -pdfjs-editor-colorpicker-button = - .title = Szín módosítása -pdfjs-editor-colorpicker-dropdown = - .aria-label = Színválasztások -pdfjs-editor-colorpicker-yellow = - .title = Sárga -pdfjs-editor-colorpicker-green = - .title = Zöld -pdfjs-editor-colorpicker-blue = - .title = Kék -pdfjs-editor-colorpicker-pink = - .title = Rózsaszín -pdfjs-editor-colorpicker-red = - .title = Vörös - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Összes megjelenítése -pdfjs-editor-highlight-show-all-button = - .title = Összes megjelenítése diff --git a/static/pdf.js/locale/hu/viewer.properties b/static/pdf.js/locale/hu/viewer.properties new file mode 100644 index 00000000..549137ce --- /dev/null +++ b/static/pdf.js/locale/hu/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Előző oldal +previous_label=Előző +next.title=Következő oldal +next_label=Tovább + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Oldal: +page_of=összesen: {{pageCount}} + +zoom_out.title=Kicsinyítés +zoom_out_label=Kicsinyítés +zoom_in.title=Nagyítás +zoom_in_label=Nagyítás +zoom.title=Nagyítás +presentation_mode.title=Váltás bemutató módba +presentation_mode_label=Bemutató mód +open_file.title=Fájl megnyitása +open_file_label=Megnyitás +print.title=Nyomtatás +print_label=Nyomtatás +download.title=Letöltés +download_label=Letöltés +bookmark.title=Jelenlegi nézet (másolás vagy megnyitás új ablakban) +bookmark_label=Aktuális nézet + +# Secondary toolbar and context menu +tools.title=Eszközök +tools_label=Eszközök +first_page.title=Ugrás az első oldalra +first_page.label=Ugrás az első oldalra +first_page_label=Ugrás az első oldalra +last_page.title=Ugrás az utolsó oldalra +last_page.label=Ugrás az utolsó oldalra +last_page_label=Ugrás az utolsó oldalra +page_rotate_cw.title=Forgatás az óramutató járásával egyezően +page_rotate_cw.label=Forgatás az óramutató járásával egyezően +page_rotate_cw_label=Forgatás az óramutató járásával egyezően +page_rotate_ccw.title=Forgatás az óramutató járásával ellentétesen +page_rotate_ccw.label=Forgatás az óramutató járásával ellentétesen +page_rotate_ccw_label=Forgatás az óramutató járásával ellentétesen + +hand_tool_enable.title=Kéz eszköz bekapcsolása +hand_tool_enable_label=Kéz eszköz bekapcsolása +hand_tool_disable.title=Kéz eszköz kikapcsolása +hand_tool_disable_label=Kéz eszköz kikapcsolása + +# Document properties dialog box +document_properties.title=Dokumentum tulajdonságai… +document_properties_label=Dokumentum tulajdonságai… +document_properties_file_name=Fájlnév: +document_properties_file_size=Fájlméret: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bájt) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bájt) +document_properties_title=Cím: +document_properties_author=Szerző: +document_properties_subject=Tárgy: +document_properties_keywords=Kulcsszavak: +document_properties_creation_date=Létrehozás dátuma: +document_properties_modification_date=Módosítás dátuma: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Létrehozta: +document_properties_producer=PDF előállító: +document_properties_version=PDF verzió: +document_properties_page_count=Oldalszám: +document_properties_close=Bezárás + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Oldalsáv be/ki +toggle_sidebar_label=Oldalsáv be/ki +outline.title=Dokumentumvázlat megjelenítése +outline_label=Dokumentumvázlat +attachments.title=Mellékletek megjelenítése +attachments_label=Van melléklet +thumbs.title=Bélyegképek megjelenítése +thumbs_label=Bélyegképek +findbar.title=Keresés a dokumentumban +findbar_label=Keresés + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title={{page}}. oldal +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}}. oldal bélyegképe + +# Find panel button title and messages +find_label=Keresés: +find_previous.title=A kifejezés előző előfordulásának keresése +find_previous_label=Előző +find_next.title=A kifejezés következő előfordulásának keresése +find_next_label=Tovább +find_highlight=Összes kiemelése +find_match_case_label=Kis- és nagybetűk megkülönböztetése +find_reached_top=A dokumentum eleje elérve, folytatás a végétől +find_reached_bottom=A dokumentum vége elérve, folytatás az elejétől +find_not_found=A kifejezés nem található + +# Error panel labels +error_more_info=További tudnivalók +error_less_info=Kevesebb információ +error_close=Bezárás +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Üzenet: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Nyomkövetés: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fájl: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Sor: {{line}} +rendering_error=Hiba történt az oldal feldolgozása közben. + +# Predefined zoom values +page_scale_width=Oldalszélesség +page_scale_fit=Teljes oldal +page_scale_auto=Automatikus nagyítás +page_scale_actual=Valódi méret +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Hiba +loading_error=Hiba történt a PDF betöltésekor. +invalid_file_error=Érvénytelen vagy sérült PDF fájl. +missing_file_error=Hiányzó PDF fájl. +unexpected_response_error=Váratlan kiszolgálóválasz. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} megjegyzés] +password_label=Adja meg a jelszót a PDF fájl megnyitásához. +password_invalid=Helytelen jelszó. Próbálja újra. +password_ok=OK +password_cancel=Mégse + +printing_not_supported=Figyelmeztetés: Ez a böngésző nem teljesen támogatja a nyomtatást. +printing_not_ready=Figyelmeztetés: A PDF nincs teljesen betöltve a nyomtatáshoz. +web_fonts_disabled=Webes betűkészletek letiltva: nem használhatók a beágyazott PDF betűkészletek. +document_colors_not_allowed=A PDF dokumentumok nem használhatják saját színeiket: „Az oldalak a saját maguk által kiválasztott színeket használhatják” beállítás ki van kapcsolva a böngészőben. diff --git a/static/pdf.js/locale/hy-AM/viewer.ftl b/static/pdf.js/locale/hy-AM/viewer.ftl deleted file mode 100644 index 5c9dd27b..00000000 --- a/static/pdf.js/locale/hy-AM/viewer.ftl +++ /dev/null @@ -1,272 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Նախորդ էջը -pdfjs-previous-button-label = Նախորդը -pdfjs-next-button = - .title = Հաջորդ էջը -pdfjs-next-button-label = Հաջորդը -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Էջ. -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = -ը՝ { $pagesCount }-ից -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber }-ը { $pagesCount })-ից -pdfjs-zoom-out-button = - .title = Փոքրացնել -pdfjs-zoom-out-button-label = Փոքրացնել -pdfjs-zoom-in-button = - .title = Խոշորացնել -pdfjs-zoom-in-button-label = Խոշորացնել -pdfjs-zoom-select = - .title = Դիտափոխում -pdfjs-presentation-mode-button = - .title = Անցնել Ներկայացման եղանակին -pdfjs-presentation-mode-button-label = Ներկայացման եղանակ -pdfjs-open-file-button = - .title = Բացել նիշք -pdfjs-open-file-button-label = Բացել -pdfjs-print-button = - .title = Տպել -pdfjs-print-button-label = Տպել -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Ներբեռնել -pdfjs-bookmark-button-label = Ընթացիկ էջ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Գործիքներ -pdfjs-tools-button-label = Գործիքներ -pdfjs-first-page-button = - .title = Անցնել առաջին էջին -pdfjs-first-page-button-label = Անցնել առաջին էջին -pdfjs-last-page-button = - .title = Անցնել վերջին էջին -pdfjs-last-page-button-label = Անցնել վերջին էջին -pdfjs-page-rotate-cw-button = - .title = Պտտել ըստ ժամացույցի սլաքի -pdfjs-page-rotate-cw-button-label = Պտտել ըստ ժամացույցի սլաքի -pdfjs-page-rotate-ccw-button = - .title = Պտտել հակառակ ժամացույցի սլաքի -pdfjs-page-rotate-ccw-button-label = Պտտել հակառակ ժամացույցի սլաքի -pdfjs-cursor-text-select-tool-button = - .title = Միացնել գրույթ ընտրելու գործիքը -pdfjs-cursor-text-select-tool-button-label = Գրույթը ընտրելու գործիք -pdfjs-cursor-hand-tool-button = - .title = Միացնել Ձեռքի գործիքը -pdfjs-cursor-hand-tool-button-label = Ձեռքի գործիք -pdfjs-scroll-vertical-button = - .title = Օգտագործել ուղղահայաց ոլորում -pdfjs-scroll-vertical-button-label = Ուղղահայաց ոլորում -pdfjs-scroll-horizontal-button = - .title = Օգտագործել հորիզոնական ոլորում -pdfjs-scroll-horizontal-button-label = Հորիզոնական ոլորում -pdfjs-scroll-wrapped-button = - .title = Օգտագործել փաթաթված ոլորում -pdfjs-scroll-wrapped-button-label = Փաթաթված ոլորում -pdfjs-spread-none-button = - .title = Մի միացեք էջի վերածածկերին -pdfjs-spread-none-button-label = Չկա վերածածկեր -pdfjs-spread-odd-button = - .title = Միացեք էջի վերածածկերին սկսելով՝ կենտ համարակալված էջերով -pdfjs-spread-odd-button-label = Կենտ վերածածկեր -pdfjs-spread-even-button = - .title = Միացեք էջի վերածածկերին սկսելով՝ զույգ համարակալված էջերով -pdfjs-spread-even-button-label = Զույգ վերածածկեր - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Փաստաթղթի հատկությունները… -pdfjs-document-properties-button-label = Փաստաթղթի հատկությունները… -pdfjs-document-properties-file-name = Նիշքի անունը. -pdfjs-document-properties-file-size = Նիշք չափը. -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } ԿԲ ({ $size_b } բայթ) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } ՄԲ ({ $size_b } բայթ) -pdfjs-document-properties-title = Վերնագիր. -pdfjs-document-properties-author = Հեղինակ․ -pdfjs-document-properties-subject = Վերնագիր. -pdfjs-document-properties-keywords = Հիմնաբառ. -pdfjs-document-properties-creation-date = Ստեղծելու ամսաթիվը. -pdfjs-document-properties-modification-date = Փոփոխելու ամսաթիվը. -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Ստեղծող. -pdfjs-document-properties-producer = PDF-ի հեղինակը. -pdfjs-document-properties-version = PDF-ի տարբերակը. -pdfjs-document-properties-page-count = Էջերի քանակը. -pdfjs-document-properties-page-size = Էջի չափը. -pdfjs-document-properties-page-size-unit-inches = ում -pdfjs-document-properties-page-size-unit-millimeters = մմ -pdfjs-document-properties-page-size-orientation-portrait = ուղղաձիգ -pdfjs-document-properties-page-size-orientation-landscape = հորիզոնական -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Նամակ -pdfjs-document-properties-page-size-name-legal = Օրինական - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Արագ վեբ դիտում․ -pdfjs-document-properties-linearized-yes = Այո -pdfjs-document-properties-linearized-no = Ոչ -pdfjs-document-properties-close-button = Փակել - -## Print - -pdfjs-print-progress-message = Նախապատրաստում է փաստաթուղթը տպելուն... -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Չեղարկել -pdfjs-printing-not-supported = Զգուշացում. Տպելը ամբողջությամբ չի աջակցվում դիտարկիչի կողմից։ -pdfjs-printing-not-ready = Զգուշացում. PDF-ը ամբողջությամբ չի բեռնավորվել տպելու համար: - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Բացել/Փակել Կողային վահանակը -pdfjs-toggle-sidebar-button-label = Բացել/Փակել Կողային վահանակը -pdfjs-document-outline-button = - .title = Ցուցադրել փաստաթղթի ուրվագիծը (կրկնակի սեղմեք՝ միավորները ընդարձակելու/կոծկելու համար) -pdfjs-document-outline-button-label = Փաստաթղթի բովանդակությունը -pdfjs-attachments-button = - .title = Ցուցադրել կցորդները -pdfjs-attachments-button-label = Կցորդներ -pdfjs-thumbs-button = - .title = Ցուցադրել Մանրապատկերը -pdfjs-thumbs-button-label = Մանրապատկերը -pdfjs-findbar-button = - .title = Գտնել փաստաթղթում -pdfjs-findbar-button-label = Որոնում - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Էջը { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Էջի մանրապատկերը { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Որոնում - .placeholder = Գտնել փաստաթղթում... -pdfjs-find-previous-button = - .title = Գտնել անրահայտության նախորդ հանդիպումը -pdfjs-find-previous-button-label = Նախորդը -pdfjs-find-next-button = - .title = Գտիր արտահայտության հաջորդ հանդիպումը -pdfjs-find-next-button-label = Հաջորդը -pdfjs-find-highlight-checkbox = Գունանշել բոլորը -pdfjs-find-match-case-checkbox-label = Մեծ(փոքր)ատառ հաշվի առնել -pdfjs-find-entire-word-checkbox-label = Ամբողջ բառերը -pdfjs-find-reached-top = Հասել եք փաստաթղթի վերևին, կշարունակվի ներքևից -pdfjs-find-reached-bottom = Հասել եք փաստաթղթի վերջին, կշարունակվի վերևից -pdfjs-find-not-found = Արտահայտությունը չգտնվեց - -## Predefined zoom values - -pdfjs-page-scale-width = Էջի լայնքը -pdfjs-page-scale-fit = Ձգել էջը -pdfjs-page-scale-auto = Ինքնաշխատ -pdfjs-page-scale-actual = Իրական չափը -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Սխալ՝ PDF ֆայլը բացելիս։ -pdfjs-invalid-file-error = Սխալ կամ վնասված PDF ֆայլ: -pdfjs-missing-file-error = PDF ֆայլը բացակայում է: -pdfjs-unexpected-response-error = Սպասարկիչի անսպասելի պատասխան: -pdfjs-rendering-error = Սխալ՝ էջը ստեղծելիս: - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Ծանոթություն] - -## Password - -pdfjs-password-label = Մուտքագրեք PDF-ի գաղտնաբառը: -pdfjs-password-invalid = Գաղտնաբառը սխալ է: Կրկին փորձեք: -pdfjs-password-ok-button = Լավ -pdfjs-password-cancel-button = Չեղարկել -pdfjs-web-fonts-disabled = Վեբ-տառատեսակները անջատված են. հնարավոր չէ օգտագործել ներկառուցված PDF տառատեսակները: - -## Editing - - -## Remove button for the various kind of editor. - - -## - -pdfjs-free-text-default-content = Սկսել մուտքագրումը… - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - - -## Color picker - - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Ցուցադրել բոլորը -pdfjs-editor-highlight-show-all-button = - .title = Ցուցադրել բոլորը diff --git a/static/pdf.js/locale/hy-AM/viewer.properties b/static/pdf.js/locale/hy-AM/viewer.properties new file mode 100644 index 00000000..d4905171 --- /dev/null +++ b/static/pdf.js/locale/hy-AM/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Նախորդ էջը +previous_label=Նախորդը +next.title=Հաջորդ էջը +next_label=Հաջորդը + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Էջ. +page_of={{pageCount}}-ից + +zoom_out.title=Փոքրացնել +zoom_out_label=Փոքրացնել +zoom_in.title=Խոշորացնել +zoom_in_label=Խոշորացնել +zoom.title=Մասշտաբը\u0020 +presentation_mode.title=Անցնել Ներկայացման եղանակին +presentation_mode_label=Ներկայացման եղանակ +open_file.title=Բացել Ֆայլ +open_file_label=Բացել +print.title=Տպել +print_label=Տպել +download.title=Բեռնել +download_label=Բեռնել +bookmark.title=Ընթացիկ տեսքով (պատճենել կամ բացել նոր պատուհանում) +bookmark_label=Ընթացիկ տեսքը + +# Secondary toolbar and context menu +tools.title=Գործիքներ +tools_label=Գործիքներ +first_page.title=Անցնել առաջին էջին +first_page.label=Անցնել առաջին էջին +first_page_label=Անցնել առաջին էջին +last_page.title=Անցնել վերջին էջին +last_page.label=Անցնել վերջին էջին +last_page_label=Անցնել վերջին էջին +page_rotate_cw.title=Պտտել ըստ ժամացույցի սլաքի +page_rotate_cw.label=Պտտել ըստ ժամացույցի սլաքի +page_rotate_cw_label=Պտտել ըստ ժամացույցի սլաքի +page_rotate_ccw.title=Պտտել հակառակ ժամացույցի սլաքի +page_rotate_ccw.label=Պտտել հակառակ ժամացույցի սլաքի +page_rotate_ccw_label=Պտտել հակառակ ժամացույցի սլաքի + +hand_tool_enable.title=Միացնել ձեռքի գործիքը +hand_tool_enable_label=Միացնել ձեռքի գործիքը +hand_tool_disable.title=Անջատել ձեռքի գործիքը +hand_tool_disable_label=ԱՆջատել ձեռքի գործիքը + +# Document properties dialog box +document_properties.title=Փաստաթղթի հատկությունները... +document_properties_label=Փաստաթղթի հատկությունները... +document_properties_file_name=Ֆայլի անունը. +document_properties_file_size=Ֆայլի չափը. +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} ԿԲ ({{size_b}} բայթ) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} ՄԲ ({{size_b}} բայթ) +document_properties_title=Վերնագիր. +document_properties_author=Հեղինակ․ +document_properties_subject=Վերնագիր. +document_properties_keywords=Հիմնաբառ. +document_properties_creation_date=Ստեղծելու ամսաթիվը. +document_properties_modification_date=Փոփոխելու ամսաթիվը. +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Ստեղծող. +document_properties_producer=PDF-ի հեղինակը. +document_properties_version=PDF-ի տարբերակը. +document_properties_page_count=Էջերի քանակը. +document_properties_close=Փակել + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Բացել/Փակել Կողային վահանակը +toggle_sidebar_label=Բացել/Փակել Կողային վահանակը +outline.title=Ցուցադրել փաստաթղթի բովանդակությունը +outline_label=Փաստաթղթի բովանդակությունը +attachments.title=Ցուցադրել կցորդները +attachments_label=Կցորդներ +thumbs.title=Ցուցադրել Մանրապատկերը +thumbs_label=Մանրապատկերը +findbar.title=Գտնել փաստաթղթում +findbar_label=Որոնում + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Էջը {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Էջի մանրապատկերը {{page}} + +# Find panel button title and messages +find_label=Գտնել` +find_previous.title=Գտնել անրահայտության նախորդ հանդիպումը +find_previous_label=Նախորդը +find_next.title=Գտիր արտահայտության հաջորդ հանդիպումը +find_next_label=Հաջորդը +find_highlight=Գունանշել բոլորը +find_match_case_label=Մեծ(փոքր)ատառ հաշվի առնել +find_reached_top=Հասել եք փաստաթղթի վերևին, կշարունակվի ներքևից +find_reached_bottom=Հասել եք փաստաթղթի վերջին, կշարունակվի վերևից +find_not_found=Արտահայտությունը չգտնվեց + +# Error panel labels +error_more_info=Ավելի շատ տեղեկություն +error_less_info=Քիչ տեղեկություն +error_close=Փակել +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (կառուցումը. {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Գրությունը. {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Շեղջ. {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Ֆայլ. {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Տողը. {{line}} +rendering_error=Սխալ՝ էջը ստեղծելիս: + +# Predefined zoom values +page_scale_width=Էջի լայնքը +page_scale_fit=Ձգել էջը +page_scale_auto=Ինքնաշխատ +page_scale_actual=Իրական չափը +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Սխալ +loading_error=Սխալ՝ PDF ֆայլը բացելիս։ +invalid_file_error=Սխալ կամ բնասված PDF ֆայլ: +missing_file_error=PDF ֆայլը բացակայում է: +unexpected_response_error=Սպասարկիչի անսպասելի պատասխան: + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Ծանոթություն] +password_label=Մուտքագրեք PDF-ի գաղտնաբառը: +password_invalid=Գաղտնաբառը սխալ է: Կրկին փորձեք: +password_ok=ԼԱՎ +password_cancel=Չեղարկել + +printing_not_supported=Զգուշացում. Տպելը ամբողջությամբ չի աջակցվում դիտարկիչի կողմից։ +printing_not_ready=Զգուշացում. PDF-ը ամբողջությամբ չի բեռնավորվել տպելու համար: +web_fonts_disabled=Վեբ-տառատեսակները անջատված են. հնարավոր չէ օգտագործել ներկառուցված PDF տառատեսակները: +document_colors_not_allowed=PDF փաստաթղթերին թույլատրված չէ օգտագործել իրենց սեփական գույները: 'Թույլատրել էջերին ընտրել իրենց սեփական գույները' ընտրանքը անջատված է դիտարկիչում: diff --git a/static/pdf.js/locale/hye/viewer.ftl b/static/pdf.js/locale/hye/viewer.ftl deleted file mode 100644 index 75cdc064..00000000 --- a/static/pdf.js/locale/hye/viewer.ftl +++ /dev/null @@ -1,268 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Նախորդ էջ -pdfjs-previous-button-label = Նախորդը -pdfjs-next-button = - .title = Յաջորդ էջ -pdfjs-next-button-label = Յաջորդը -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = էջ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount }-ից -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber }-ը { $pagesCount })-ից -pdfjs-zoom-out-button = - .title = Փոքրացնել -pdfjs-zoom-out-button-label = Փոքրացնել -pdfjs-zoom-in-button = - .title = Խոշորացնել -pdfjs-zoom-in-button-label = Խոշորացնել -pdfjs-zoom-select = - .title = Խոշորացում -pdfjs-presentation-mode-button = - .title = Անցնել ներկայացման եղանակին -pdfjs-presentation-mode-button-label = Ներկայացման եղանակ -pdfjs-open-file-button = - .title = Բացել նիշքը -pdfjs-open-file-button-label = Բացել -pdfjs-print-button = - .title = Տպել -pdfjs-print-button-label = Տպել - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Գործիքներ -pdfjs-tools-button-label = Գործիքներ -pdfjs-first-page-button = - .title = Գնալ դէպի առաջին էջ -pdfjs-first-page-button-label = Գնալ դէպի առաջին էջ -pdfjs-last-page-button = - .title = Գնալ դէպի վերջին էջ -pdfjs-last-page-button-label = Գնալ դէպի վերջին էջ -pdfjs-page-rotate-cw-button = - .title = Պտտել ժամացոյցի սլաքի ուղղութեամբ -pdfjs-page-rotate-cw-button-label = Պտտել ժամացոյցի սլաքի ուղղութեամբ -pdfjs-page-rotate-ccw-button = - .title = Պտտել ժամացոյցի սլաքի հակառակ ուղղութեամբ -pdfjs-page-rotate-ccw-button-label = Պտտել ժամացոյցի սլաքի հակառակ ուղղութեամբ -pdfjs-cursor-text-select-tool-button = - .title = Միացնել գրոյթ ընտրելու գործիքը -pdfjs-cursor-text-select-tool-button-label = Գրուածք ընտրելու գործիք -pdfjs-cursor-hand-tool-button = - .title = Միացնել ձեռքի գործիքը -pdfjs-cursor-hand-tool-button-label = Ձեռքի գործիք -pdfjs-scroll-page-button = - .title = Աւգտագործել էջի ոլորում -pdfjs-scroll-page-button-label = Էջի ոլորում -pdfjs-scroll-vertical-button = - .title = Աւգտագործել ուղղահայեաց ոլորում -pdfjs-scroll-vertical-button-label = Ուղղահայեաց ոլորում -pdfjs-scroll-horizontal-button = - .title = Աւգտագործել հորիզոնական ոլորում -pdfjs-scroll-horizontal-button-label = Հորիզոնական ոլորում -pdfjs-scroll-wrapped-button = - .title = Աւգտագործել փաթաթուած ոլորում -pdfjs-scroll-wrapped-button-label = Փաթաթուած ոլորում -pdfjs-spread-none-button = - .title = Մի միացէք էջի կոնտեքստում -pdfjs-spread-none-button-label = Չկայ կոնտեքստ -pdfjs-spread-odd-button = - .title = Միացէք էջի կոնտեքստին սկսելով՝ կենտ համարակալուած էջերով -pdfjs-spread-odd-button-label = Տարաւրինակ կոնտեքստ -pdfjs-spread-even-button = - .title = Միացէք էջի կոնտեքստին սկսելով՝ զոյգ համարակալուած էջերով -pdfjs-spread-even-button-label = Հաւասար վերածածկեր - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Փաստաթղթի հատկութիւնները… -pdfjs-document-properties-button-label = Փաստաթղթի յատկութիւնները… -pdfjs-document-properties-file-name = Նիշքի անունը․ -pdfjs-document-properties-file-size = Նիշք չափը. -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } ԿԲ ({ $size_b } բայթ) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } ՄԲ ({ $size_b } բայթ) -pdfjs-document-properties-title = Վերնագիր -pdfjs-document-properties-author = Հեղինակ․ -pdfjs-document-properties-subject = առարկայ -pdfjs-document-properties-keywords = Հիմնաբառեր -pdfjs-document-properties-creation-date = Ստեղծման ամսաթիւ -pdfjs-document-properties-modification-date = Փոփոխութեան ամսաթիւ. -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Ստեղծող -pdfjs-document-properties-producer = PDF-ի Արտադրողը. -pdfjs-document-properties-version = PDF-ի տարբերակը. -pdfjs-document-properties-page-count = Էջերի քանակը. -pdfjs-document-properties-page-size = Էջի չափը. -pdfjs-document-properties-page-size-unit-inches = ում -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = ուղղաձիգ -pdfjs-document-properties-page-size-orientation-landscape = հորիզոնական -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Նամակ -pdfjs-document-properties-page-size-name-legal = Աւրինական - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Արագ վեբ դիտում․ -pdfjs-document-properties-linearized-yes = Այո -pdfjs-document-properties-linearized-no = Ոչ -pdfjs-document-properties-close-button = Փակել - -## Print - -pdfjs-print-progress-message = Նախապատրաստում է փաստաթուղթը տպելուն… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Չեղարկել -pdfjs-printing-not-supported = Զգուշացում. Տպելը ամբողջութեամբ չի աջակցուում զննարկիչի կողմից։ -pdfjs-printing-not-ready = Զգուշացում. PDF֊ը ամբողջութեամբ չի բեռնաւորուել տպելու համար։ - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Փոխարկել կողային վահանակը -pdfjs-toggle-sidebar-notification-button = - .title = Փոխանջատել կողմնասիւնը (փաստաթուղթը պարունակում է ուրուագիծ/կցորդներ/շերտեր) -pdfjs-toggle-sidebar-button-label = Փոխարկել կողային վահանակը -pdfjs-document-outline-button = - .title = Ցուցադրել փաստաթղթի ուրուագիծը (կրկնակի սեղմէք՝ միաւորները ընդարձակելու/կոծկելու համար) -pdfjs-document-outline-button-label = Փաստաթղթի ուրուագիծ -pdfjs-attachments-button = - .title = Ցուցադրել կցորդները -pdfjs-attachments-button-label = Կցորդներ -pdfjs-layers-button = - .title = Ցուցադրել շերտերը (կրկնահպել վերակայելու բոլոր շերտերը սկզբնադիր վիճակի) -pdfjs-layers-button-label = Շերտեր -pdfjs-thumbs-button = - .title = Ցուցադրել մանրապատկերը -pdfjs-thumbs-button-label = Մանրապատկեր -pdfjs-current-outline-item-button = - .title = Գտէք ընթացիկ գծագրման տարրը -pdfjs-current-outline-item-button-label = Ընթացիկ գծագրման տարր -pdfjs-findbar-button = - .title = Գտնել փաստաթղթում -pdfjs-findbar-button-label = Որոնում -pdfjs-additional-layers = Լրացուցիչ շերտեր - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Էջը { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Էջի մանրապատկերը { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Որոնում - .placeholder = Գտնել փաստաթղթում… -pdfjs-find-previous-button = - .title = Գտնել արտայայտութեան նախորդ արտայայտութիւնը -pdfjs-find-previous-button-label = Նախորդը -pdfjs-find-next-button = - .title = Գտիր արտայայտութեան յաջորդ արտայայտութիւնը -pdfjs-find-next-button-label = Հաջորդը -pdfjs-find-highlight-checkbox = Գունանշել բոլորը -pdfjs-find-match-case-checkbox-label = Հաշուի առնել հանգամանքը -pdfjs-find-match-diacritics-checkbox-label = Հնչիւնատարբերիչ նշանների համապատասխանեցում -pdfjs-find-entire-word-checkbox-label = Ամբողջ բառերը -pdfjs-find-reached-top = Հասել եք փաստաթղթի վերեւին,շարունակել ներքեւից -pdfjs-find-reached-bottom = Հասել էք փաստաթղթի վերջին, շարունակել վերեւից -pdfjs-find-not-found = Արտայայտութիւնը չգտնուեց - -## Predefined zoom values - -pdfjs-page-scale-width = Էջի լայնութիւն -pdfjs-page-scale-fit = Հարմարեցնել էջը -pdfjs-page-scale-auto = Ինքնաշխատ խոշորացում -pdfjs-page-scale-actual = Իրական չափը -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Էջ { $page } - -## Loading indicator messages - -pdfjs-loading-error = PDF նիշքը բացելիս սխալ է տեղի ունեցել։ -pdfjs-invalid-file-error = Սխալ կամ վնասուած PDF նիշք։ -pdfjs-missing-file-error = PDF նիշքը բացակաիւմ է։ -pdfjs-unexpected-response-error = Սպասարկիչի անսպասելի պատասխան։ -pdfjs-rendering-error = Սխալ է տեղի ունեցել էջի մեկնաբանման ժամանակ - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Ծանոթութիւն] - -## Password - -pdfjs-password-label = Մուտքագրէք գաղտնաբառը այս PDF նիշքը բացելու համար -pdfjs-password-invalid = Գաղտնաբառը սխալ է: Կրկին փորձէք: -pdfjs-password-ok-button = Լաւ -pdfjs-password-cancel-button = Չեղարկել -pdfjs-web-fonts-disabled = Վեբ-տառատեսակները անջատուած են. հնարաւոր չէ աւգտագործել ներկառուցուած PDF տառատեսակները։ - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ia/viewer.ftl b/static/pdf.js/locale/ia/viewer.ftl deleted file mode 100644 index 4cddfa28..00000000 --- a/static/pdf.js/locale/ia/viewer.ftl +++ /dev/null @@ -1,394 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pagina previe -pdfjs-previous-button-label = Previe -pdfjs-next-button = - .title = Pagina sequente -pdfjs-next-button-label = Sequente -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pagina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Distantiar -pdfjs-zoom-out-button-label = Distantiar -pdfjs-zoom-in-button = - .title = Approximar -pdfjs-zoom-in-button-label = Approximar -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Excambiar a modo presentation -pdfjs-presentation-mode-button-label = Modo presentation -pdfjs-open-file-button = - .title = Aperir le file -pdfjs-open-file-button-label = Aperir -pdfjs-print-button = - .title = Imprimer -pdfjs-print-button-label = Imprimer -pdfjs-save-button = - .title = Salvar -pdfjs-save-button-label = Salvar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Discargar -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Discargar -pdfjs-bookmark-button = - .title = Pagina actual (vide le URL del pagina actual) -pdfjs-bookmark-button-label = Pagina actual - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Instrumentos -pdfjs-tools-button-label = Instrumentos -pdfjs-first-page-button = - .title = Ir al prime pagina -pdfjs-first-page-button-label = Ir al prime pagina -pdfjs-last-page-button = - .title = Ir al ultime pagina -pdfjs-last-page-button-label = Ir al ultime pagina -pdfjs-page-rotate-cw-button = - .title = Rotar in senso horari -pdfjs-page-rotate-cw-button-label = Rotar in senso horari -pdfjs-page-rotate-ccw-button = - .title = Rotar in senso antihorari -pdfjs-page-rotate-ccw-button-label = Rotar in senso antihorari -pdfjs-cursor-text-select-tool-button = - .title = Activar le instrumento de selection de texto -pdfjs-cursor-text-select-tool-button-label = Instrumento de selection de texto -pdfjs-cursor-hand-tool-button = - .title = Activar le instrumento mano -pdfjs-cursor-hand-tool-button-label = Instrumento mano -pdfjs-scroll-page-button = - .title = Usar rolamento de pagina -pdfjs-scroll-page-button-label = Rolamento de pagina -pdfjs-scroll-vertical-button = - .title = Usar rolamento vertical -pdfjs-scroll-vertical-button-label = Rolamento vertical -pdfjs-scroll-horizontal-button = - .title = Usar rolamento horizontal -pdfjs-scroll-horizontal-button-label = Rolamento horizontal -pdfjs-scroll-wrapped-button = - .title = Usar rolamento incapsulate -pdfjs-scroll-wrapped-button-label = Rolamento incapsulate -pdfjs-spread-none-button = - .title = Non junger paginas dual -pdfjs-spread-none-button-label = Sin paginas dual -pdfjs-spread-odd-button = - .title = Junger paginas dual a partir de paginas con numeros impar -pdfjs-spread-odd-button-label = Paginas dual impar -pdfjs-spread-even-button = - .title = Junger paginas dual a partir de paginas con numeros par -pdfjs-spread-even-button-label = Paginas dual par - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Proprietates del documento… -pdfjs-document-properties-button-label = Proprietates del documento… -pdfjs-document-properties-file-name = Nomine del file: -pdfjs-document-properties-file-size = Dimension de file: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Titulo: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Subjecto: -pdfjs-document-properties-keywords = Parolas clave: -pdfjs-document-properties-creation-date = Data de creation: -pdfjs-document-properties-modification-date = Data de modification: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creator: -pdfjs-document-properties-producer = Productor PDF: -pdfjs-document-properties-version = Version PDF: -pdfjs-document-properties-page-count = Numero de paginas: -pdfjs-document-properties-page-size = Dimension del pagina: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = horizontal -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Littera -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista web rapide: -pdfjs-document-properties-linearized-yes = Si -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Clauder - -## Print - -pdfjs-print-progress-message = Preparation del documento pro le impression… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancellar -pdfjs-printing-not-supported = Attention : le impression non es totalmente supportate per ce navigator. -pdfjs-printing-not-ready = Attention: le file PDF non es integremente cargate pro lo poter imprimer. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Monstrar/celar le barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Monstrar/celar le barra lateral (le documento contine structura/attachamentos/stratos) -pdfjs-toggle-sidebar-button-label = Monstrar/celar le barra lateral -pdfjs-document-outline-button = - .title = Monstrar le schema del documento (clic duple pro expander/contraher tote le elementos) -pdfjs-document-outline-button-label = Schema del documento -pdfjs-attachments-button = - .title = Monstrar le annexos -pdfjs-attachments-button-label = Annexos -pdfjs-layers-button = - .title = Monstrar stratos (clicca duple pro remontar tote le stratos al stato predefinite) -pdfjs-layers-button-label = Stratos -pdfjs-thumbs-button = - .title = Monstrar le vignettes -pdfjs-thumbs-button-label = Vignettes -pdfjs-current-outline-item-button = - .title = Trovar le elemento de structura actual -pdfjs-current-outline-item-button-label = Elemento de structura actual -pdfjs-findbar-button = - .title = Cercar in le documento -pdfjs-findbar-button-label = Cercar -pdfjs-additional-layers = Altere stratos - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pagina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Vignette del pagina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Cercar - .placeholder = Cercar in le documento… -pdfjs-find-previous-button = - .title = Trovar le previe occurrentia del phrase -pdfjs-find-previous-button-label = Previe -pdfjs-find-next-button = - .title = Trovar le successive occurrentia del phrase -pdfjs-find-next-button-label = Sequente -pdfjs-find-highlight-checkbox = Evidentiar toto -pdfjs-find-match-case-checkbox-label = Distinguer majusculas/minusculas -pdfjs-find-match-diacritics-checkbox-label = Differentiar diacriticos -pdfjs-find-entire-word-checkbox-label = Parolas integre -pdfjs-find-reached-top = Initio del documento attingite, continuation ab fin -pdfjs-find-reached-bottom = Fin del documento attingite, continuation ab initio -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } de { $total } correspondentia - *[other] { $current } de { $total } correspondentias - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Plus de { $limit } correspondentia - *[other] Plus de { $limit } correspondentias - } -pdfjs-find-not-found = Phrase non trovate - -## Predefined zoom values - -pdfjs-page-scale-width = Plen largor del pagina -pdfjs-page-scale-fit = Pagina integre -pdfjs-page-scale-auto = Zoom automatic -pdfjs-page-scale-actual = Dimension real -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pagina { $page } - -## Loading indicator messages - -pdfjs-loading-error = Un error occurreva durante que on cargava le file PDF. -pdfjs-invalid-file-error = File PDF corrumpite o non valide. -pdfjs-missing-file-error = File PDF mancante. -pdfjs-unexpected-response-error = Responsa del servitor inexpectate. -pdfjs-rendering-error = Un error occurreva durante que on processava le pagina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Insere le contrasigno pro aperir iste file PDF. -pdfjs-password-invalid = Contrasigno invalide. Per favor retenta. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Cancellar -pdfjs-web-fonts-disabled = Le typos de litteras web es disactivate: impossibile usar le typos de litteras PDF incorporate. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texto -pdfjs-editor-free-text-button-label = Texto -pdfjs-editor-ink-button = - .title = Designar -pdfjs-editor-ink-button-label = Designar -pdfjs-editor-stamp-button = - .title = Adder o rediger imagines -pdfjs-editor-stamp-button-label = Adder o rediger imagines -pdfjs-editor-highlight-button = - .title = Evidentia -pdfjs-editor-highlight-button-label = Evidentia -pdfjs-highlight-floating-button1 = - .title = Evidentiar - .aria-label = Evidentiar -pdfjs-highlight-floating-button-label = Evidentiar - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Remover le designo -pdfjs-editor-remove-freetext-button = - .title = Remover texto -pdfjs-editor-remove-stamp-button = - .title = Remover imagine -pdfjs-editor-remove-highlight-button = - .title = Remover evidentia - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Color -pdfjs-editor-free-text-size-input = Dimension -pdfjs-editor-ink-color-input = Color -pdfjs-editor-ink-thickness-input = Spissor -pdfjs-editor-ink-opacity-input = Opacitate -pdfjs-editor-stamp-add-image-button = - .title = Adder imagine -pdfjs-editor-stamp-add-image-button-label = Adder imagine -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Spissor -pdfjs-editor-free-highlight-thickness-title = - .title = Cambiar spissor evidentiante elementos differente de texto -pdfjs-free-text = - .aria-label = Editor de texto -pdfjs-free-text-default-content = Comenciar a scriber… -pdfjs-ink = - .aria-label = Editor de designos -pdfjs-ink-canvas = - .aria-label = Imagine create per le usator - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Texto alternative -pdfjs-editor-alt-text-edit-button-label = Rediger texto alternative -pdfjs-editor-alt-text-dialog-label = Elige un option -pdfjs-editor-alt-text-dialog-description = Le texto alternative (alt text) adjuta quando le personas non pote vider le imagine o quando illo non carga. -pdfjs-editor-alt-text-add-description-label = Adder un description -pdfjs-editor-alt-text-add-description-description = Mira a 1-2 phrases que describe le subjecto, parametro, o actiones. -pdfjs-editor-alt-text-mark-decorative-label = Marcar como decorative -pdfjs-editor-alt-text-mark-decorative-description = Isto es usate pro imagines ornamental, como bordaturas o filigranas. -pdfjs-editor-alt-text-cancel-button = Cancellar -pdfjs-editor-alt-text-save-button = Salvar -pdfjs-editor-alt-text-decorative-tooltip = Marcate como decorative -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Per exemplo, “Un juvene sede a un tabula pro mangiar un repasto” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Angulo superior sinistre — redimensionar -pdfjs-editor-resizer-label-top-middle = Medio superior — redimensionar -pdfjs-editor-resizer-label-top-right = Angulo superior dextre — redimensionar -pdfjs-editor-resizer-label-middle-right = Medio dextre — redimensionar -pdfjs-editor-resizer-label-bottom-right = Angulo inferior dextre — redimensionar -pdfjs-editor-resizer-label-bottom-middle = Medio inferior — redimensionar -pdfjs-editor-resizer-label-bottom-left = Angulo inferior sinistre — redimensionar -pdfjs-editor-resizer-label-middle-left = Medio sinistre — redimensionar - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Color pro evidentiar -pdfjs-editor-colorpicker-button = - .title = Cambiar color -pdfjs-editor-colorpicker-dropdown = - .aria-label = Electiones del color -pdfjs-editor-colorpicker-yellow = - .title = Jalne -pdfjs-editor-colorpicker-green = - .title = Verde -pdfjs-editor-colorpicker-blue = - .title = Blau -pdfjs-editor-colorpicker-pink = - .title = Rosate -pdfjs-editor-colorpicker-red = - .title = Rubie - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Monstrar toto -pdfjs-editor-highlight-show-all-button = - .title = Monstrar toto diff --git a/static/pdf.js/locale/id/viewer.ftl b/static/pdf.js/locale/id/viewer.ftl deleted file mode 100644 index fee8d18b..00000000 --- a/static/pdf.js/locale/id/viewer.ftl +++ /dev/null @@ -1,293 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Laman Sebelumnya -pdfjs-previous-button-label = Sebelumnya -pdfjs-next-button = - .title = Laman Selanjutnya -pdfjs-next-button-label = Selanjutnya -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Halaman -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = dari { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } dari { $pagesCount }) -pdfjs-zoom-out-button = - .title = Perkecil -pdfjs-zoom-out-button-label = Perkecil -pdfjs-zoom-in-button = - .title = Perbesar -pdfjs-zoom-in-button-label = Perbesar -pdfjs-zoom-select = - .title = Perbesaran -pdfjs-presentation-mode-button = - .title = Ganti ke Mode Presentasi -pdfjs-presentation-mode-button-label = Mode Presentasi -pdfjs-open-file-button = - .title = Buka Berkas -pdfjs-open-file-button-label = Buka -pdfjs-print-button = - .title = Cetak -pdfjs-print-button-label = Cetak -pdfjs-save-button = - .title = Simpan -pdfjs-save-button-label = Simpan -pdfjs-bookmark-button = - .title = Laman Saat Ini (Lihat URL dari Laman Sekarang) -pdfjs-bookmark-button-label = Laman Saat Ini - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Alat -pdfjs-tools-button-label = Alat -pdfjs-first-page-button = - .title = Buka Halaman Pertama -pdfjs-first-page-button-label = Buka Halaman Pertama -pdfjs-last-page-button = - .title = Buka Halaman Terakhir -pdfjs-last-page-button-label = Buka Halaman Terakhir -pdfjs-page-rotate-cw-button = - .title = Putar Searah Jarum Jam -pdfjs-page-rotate-cw-button-label = Putar Searah Jarum Jam -pdfjs-page-rotate-ccw-button = - .title = Putar Berlawanan Arah Jarum Jam -pdfjs-page-rotate-ccw-button-label = Putar Berlawanan Arah Jarum Jam -pdfjs-cursor-text-select-tool-button = - .title = Aktifkan Alat Seleksi Teks -pdfjs-cursor-text-select-tool-button-label = Alat Seleksi Teks -pdfjs-cursor-hand-tool-button = - .title = Aktifkan Alat Tangan -pdfjs-cursor-hand-tool-button-label = Alat Tangan -pdfjs-scroll-page-button = - .title = Gunakan Pengguliran Laman -pdfjs-scroll-page-button-label = Pengguliran Laman -pdfjs-scroll-vertical-button = - .title = Gunakan Penggeseran Vertikal -pdfjs-scroll-vertical-button-label = Penggeseran Vertikal -pdfjs-scroll-horizontal-button = - .title = Gunakan Penggeseran Horizontal -pdfjs-scroll-horizontal-button-label = Penggeseran Horizontal -pdfjs-scroll-wrapped-button = - .title = Gunakan Penggeseran Terapit -pdfjs-scroll-wrapped-button-label = Penggeseran Terapit -pdfjs-spread-none-button = - .title = Jangan gabungkan lembar halaman -pdfjs-spread-none-button-label = Tidak Ada Lembaran -pdfjs-spread-odd-button = - .title = Gabungkan lembar lamanan mulai dengan halaman ganjil -pdfjs-spread-odd-button-label = Lembaran Ganjil -pdfjs-spread-even-button = - .title = Gabungkan lembar halaman dimulai dengan halaman genap -pdfjs-spread-even-button-label = Lembaran Genap - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Properti Dokumen… -pdfjs-document-properties-button-label = Properti Dokumen… -pdfjs-document-properties-file-name = Nama berkas: -pdfjs-document-properties-file-size = Ukuran berkas: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } byte) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } byte) -pdfjs-document-properties-title = Judul: -pdfjs-document-properties-author = Penyusun: -pdfjs-document-properties-subject = Subjek: -pdfjs-document-properties-keywords = Kata Kunci: -pdfjs-document-properties-creation-date = Tanggal Dibuat: -pdfjs-document-properties-modification-date = Tanggal Dimodifikasi: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Pembuat: -pdfjs-document-properties-producer = Pemroduksi PDF: -pdfjs-document-properties-version = Versi PDF: -pdfjs-document-properties-page-count = Jumlah Halaman: -pdfjs-document-properties-page-size = Ukuran Laman: -pdfjs-document-properties-page-size-unit-inches = inci -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = tegak -pdfjs-document-properties-page-size-orientation-landscape = mendatar -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Tampilan Web Kilat: -pdfjs-document-properties-linearized-yes = Ya -pdfjs-document-properties-linearized-no = Tidak -pdfjs-document-properties-close-button = Tutup - -## Print - -pdfjs-print-progress-message = Menyiapkan dokumen untuk pencetakan… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Batalkan -pdfjs-printing-not-supported = Peringatan: Pencetakan tidak didukung secara lengkap pada peramban ini. -pdfjs-printing-not-ready = Peringatan: Berkas PDF masih belum dimuat secara lengkap untuk dapat dicetak. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Aktif/Nonaktifkan Bilah Samping -pdfjs-toggle-sidebar-notification-button = - .title = Aktif/Nonaktifkan Bilah Samping (dokumen berisi kerangka/lampiran/lapisan) -pdfjs-toggle-sidebar-button-label = Aktif/Nonaktifkan Bilah Samping -pdfjs-document-outline-button = - .title = Tampilkan Kerangka Dokumen (klik ganda untuk membentangkan/menciutkan semua item) -pdfjs-document-outline-button-label = Kerangka Dokumen -pdfjs-attachments-button = - .title = Tampilkan Lampiran -pdfjs-attachments-button-label = Lampiran -pdfjs-layers-button = - .title = Tampilkan Lapisan (klik ganda untuk mengatur ulang semua lapisan ke keadaan baku) -pdfjs-layers-button-label = Lapisan -pdfjs-thumbs-button = - .title = Tampilkan Miniatur -pdfjs-thumbs-button-label = Miniatur -pdfjs-current-outline-item-button = - .title = Cari Butir Ikhtisar Saat Ini -pdfjs-current-outline-item-button-label = Butir Ikhtisar Saat Ini -pdfjs-findbar-button = - .title = Temukan di Dokumen -pdfjs-findbar-button-label = Temukan -pdfjs-additional-layers = Lapisan Tambahan - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Laman { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatur Laman { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Temukan - .placeholder = Temukan di dokumen… -pdfjs-find-previous-button = - .title = Temukan kata sebelumnya -pdfjs-find-previous-button-label = Sebelumnya -pdfjs-find-next-button = - .title = Temukan lebih lanjut -pdfjs-find-next-button-label = Selanjutnya -pdfjs-find-highlight-checkbox = Sorot semuanya -pdfjs-find-match-case-checkbox-label = Cocokkan BESAR/kecil -pdfjs-find-match-diacritics-checkbox-label = Pencocokan Diakritik -pdfjs-find-entire-word-checkbox-label = Seluruh teks -pdfjs-find-reached-top = Sampai di awal dokumen, dilanjutkan dari bawah -pdfjs-find-reached-bottom = Sampai di akhir dokumen, dilanjutkan dari atas -pdfjs-find-not-found = Frasa tidak ditemukan - -## Predefined zoom values - -pdfjs-page-scale-width = Lebar Laman -pdfjs-page-scale-fit = Muat Laman -pdfjs-page-scale-auto = Perbesaran Otomatis -pdfjs-page-scale-actual = Ukuran Asli -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Halaman { $page } - -## Loading indicator messages - -pdfjs-loading-error = Galat terjadi saat memuat PDF. -pdfjs-invalid-file-error = Berkas PDF tidak valid atau rusak. -pdfjs-missing-file-error = Berkas PDF tidak ada. -pdfjs-unexpected-response-error = Balasan server yang tidak diharapkan. -pdfjs-rendering-error = Galat terjadi saat merender laman. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotasi { $type }] - -## Password - -pdfjs-password-label = Masukkan sandi untuk membuka berkas PDF ini. -pdfjs-password-invalid = Sandi tidak valid. Silakan coba lagi. -pdfjs-password-ok-button = Oke -pdfjs-password-cancel-button = Batal -pdfjs-web-fonts-disabled = Font web dinonaktifkan: tidak dapat menggunakan font PDF yang tersemat. - -## Editing - -pdfjs-editor-free-text-button = - .title = Teks -pdfjs-editor-free-text-button-label = Teks -pdfjs-editor-ink-button = - .title = Gambar -pdfjs-editor-ink-button-label = Gambar -# Editor Parameters -pdfjs-editor-free-text-color-input = Warna -pdfjs-editor-free-text-size-input = Ukuran -pdfjs-editor-ink-color-input = Warna -pdfjs-editor-ink-thickness-input = Ketebalan -pdfjs-editor-ink-opacity-input = Opasitas -pdfjs-free-text = - .aria-label = Editor Teks -pdfjs-free-text-default-content = Mulai mengetik… -pdfjs-ink = - .aria-label = Editor Gambar -pdfjs-ink-canvas = - .aria-label = Gambar yang dibuat pengguna - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/id/viewer.properties b/static/pdf.js/locale/id/viewer.properties new file mode 100644 index 00000000..762a472e --- /dev/null +++ b/static/pdf.js/locale/id/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Laman Sebelumnya +previous_label=Sebelumnya +next.title=Laman Selanjutnya +next_label=Selanjutnya + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Laman: +page_of=dari {{pageCount}} + +zoom_out.title=Perkecil +zoom_out_label=Perkecil +zoom_in.title=Perbesar +zoom_in_label=Perbesar +zoom.title=Perbesaran +presentation_mode.title=Ganti ke Mode Presentasi +presentation_mode_label=Mode Presentasi +open_file.title=Buka Berkas +open_file_label=Buka +print.title=Cetak +print_label=Cetak +download.title=Unduh +download_label=Unduh +bookmark.title=Tampilan Sekarang (salin atau buka di jendela baru) +bookmark_label=Tampilan Sekarang + +# Secondary toolbar and context menu +tools.title=Alat +tools_label=Alat +first_page.title=Buka Halaman Pertama +first_page.label=Ke Halaman Pertama +first_page_label=Buka Halaman Pertama +last_page.title=Buka Halaman Terakhir +last_page.label=Ke Halaman Terakhir +last_page_label=Buka Halaman Terakhir +page_rotate_cw.title=Putar Searah Jarum Jam +page_rotate_cw.label=Putar Searah Jarum Jam +page_rotate_cw_label=Putar Searah Jarum Jam +page_rotate_ccw.title=Putar Berlawanan Arah Jarum Jam +page_rotate_ccw.label=Putar Berlawanan Arah Jarum Jam +page_rotate_ccw_label=Putar Berlawanan Arah Jarum Jam + +hand_tool_enable.title=Aktifkan alat tangan +hand_tool_enable_label=Aktifkan alat tangan +hand_tool_disable.title=Nonaktifkan alat tangan +hand_tool_disable_label=Nonaktifkan alat tangan + +# Document properties dialog box +document_properties.title=Properti Dokumen… +document_properties_label=Properti Dokumen… +document_properties_file_name=Nama berkas: +document_properties_file_size=Ukuran berkas: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} byte) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} byte) +document_properties_title=Judul: +document_properties_author=Penyusun: +document_properties_subject=Subjek: +document_properties_keywords=Kata Kunci: +document_properties_creation_date=Tanggal Dibuat: +document_properties_modification_date=Tanggal Dimodifikasi: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Pembuat: +document_properties_producer=Pemroduksi PDF: +document_properties_version=Versi PDF: +document_properties_page_count=Jumlah Halaman: +document_properties_close=Tutup + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Aktif/Nonaktifkan Bilah Samping +toggle_sidebar_label=Aktif/Nonaktifkan Bilah Samping +outline.title=Buka Kerangka Dokumen +outline_label=Kerangka Dokumen +attachments.title=Tampilkan Lampiran +attachments_label=Lampiran +thumbs.title=Tampilkan Miniatur +thumbs_label=Miniatur +findbar.title=Temukan di Dokumen +findbar_label=Temukan + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Laman {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatur Laman {{page}} + +# Find panel button title and messages +find_label=Temukan: +find_previous.title=Temukan kata sebelumnya +find_previous_label=Sebelumnya +find_next.title=Temukan lebih lanjut +find_next_label=Selanjutnya +find_highlight=Sorot semuanya +find_match_case_label=Cocokkan BESAR/kecil +find_reached_top=Sampai di awal dokumen, dilanjutkan dari bawah +find_reached_bottom=Sampai di akhir dokumen, dilanjutkan dari atas +find_not_found=Frasa tidak ditemukan + +# Error panel labels +error_more_info=Lebih Banyak Informasi +error_less_info=Lebih Sedikit Informasi +error_close=Tutup +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Pesan: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Berkas: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Baris: {{line}} +rendering_error=Galat terjadi saat merender laman. + +# Predefined zoom values +page_scale_width=Lebar Laman +page_scale_fit=Muat Laman +page_scale_auto=Perbesaran Otomatis +page_scale_actual=Ukuran Asli +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Galat +loading_error=Galat terjadi saat memuat PDF. +invalid_file_error=Berkas PDF tidak valid atau rusak. +missing_file_error=Berkas PDF tidak ada. +unexpected_response_error=Balasan server yang tidak diharapkan. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotasi {{type}}] +password_label=Masukkan sandi untuk membuka berkas PDF ini. +password_invalid=Sandi tidak valid. Silakan coba lagi. +password_ok=Oke +password_cancel=Batal + +printing_not_supported=Peringatan: Pencetakan tidak didukung secara lengkap pada peramban ini. +printing_not_ready=Peringatan: Berkas PDF masih belum dimuat secara lengkap untuk dapat dicetak. +web_fonts_disabled=Font web dinonaktifkan: tidak dapat menggunakan font PDF yang tersemat. +document_colors_not_allowed=Dokumen PDF tidak diizinkan untuk menggunakan warnanya sendiri karena setelan 'Izinkan laman memilih warna sendiri' dinonaktifkan pada pengaturan. diff --git a/static/pdf.js/locale/is/viewer.ftl b/static/pdf.js/locale/is/viewer.ftl deleted file mode 100644 index d3afef3e..00000000 --- a/static/pdf.js/locale/is/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Fyrri síða -pdfjs-previous-button-label = Fyrri -pdfjs-next-button = - .title = Næsta síða -pdfjs-next-button-label = Næsti -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Síða -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = af { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } af { $pagesCount }) -pdfjs-zoom-out-button = - .title = Minnka aðdrátt -pdfjs-zoom-out-button-label = Minnka aðdrátt -pdfjs-zoom-in-button = - .title = Auka aðdrátt -pdfjs-zoom-in-button-label = Auka aðdrátt -pdfjs-zoom-select = - .title = Aðdráttur -pdfjs-presentation-mode-button = - .title = Skipta yfir á kynningarham -pdfjs-presentation-mode-button-label = Kynningarhamur -pdfjs-open-file-button = - .title = Opna skrá -pdfjs-open-file-button-label = Opna -pdfjs-print-button = - .title = Prenta -pdfjs-print-button-label = Prenta -pdfjs-save-button = - .title = Vista -pdfjs-save-button-label = Vista -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Sækja -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Sækja -pdfjs-bookmark-button = - .title = Núverandi síða (Skoða vefslóð frá núverandi síðu) -pdfjs-bookmark-button-label = Núverandi síða -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Opna í smáforriti -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Opna í smáforriti - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Verkfæri -pdfjs-tools-button-label = Verkfæri -pdfjs-first-page-button = - .title = Fara á fyrstu síðu -pdfjs-first-page-button-label = Fara á fyrstu síðu -pdfjs-last-page-button = - .title = Fara á síðustu síðu -pdfjs-last-page-button-label = Fara á síðustu síðu -pdfjs-page-rotate-cw-button = - .title = Snúa réttsælis -pdfjs-page-rotate-cw-button-label = Snúa réttsælis -pdfjs-page-rotate-ccw-button = - .title = Snúa rangsælis -pdfjs-page-rotate-ccw-button-label = Snúa rangsælis -pdfjs-cursor-text-select-tool-button = - .title = Virkja textavalsáhald -pdfjs-cursor-text-select-tool-button-label = Textavalsáhald -pdfjs-cursor-hand-tool-button = - .title = Virkja handarverkfæri -pdfjs-cursor-hand-tool-button-label = Handarverkfæri -pdfjs-scroll-page-button = - .title = Nota síðuskrun -pdfjs-scroll-page-button-label = Síðuskrun -pdfjs-scroll-vertical-button = - .title = Nota lóðrétt skrun -pdfjs-scroll-vertical-button-label = Lóðrétt skrun -pdfjs-scroll-horizontal-button = - .title = Nota lárétt skrun -pdfjs-scroll-horizontal-button-label = Lárétt skrun -pdfjs-scroll-wrapped-button = - .title = Nota línuskipt síðuskrun -pdfjs-scroll-wrapped-button-label = Línuskipt síðuskrun -pdfjs-spread-none-button = - .title = Ekki taka þátt í dreifingu síðna -pdfjs-spread-none-button-label = Engin dreifing -pdfjs-spread-odd-button = - .title = Taka þátt í dreifingu síðna með oddatölum -pdfjs-spread-odd-button-label = Oddatöludreifing -pdfjs-spread-even-button = - .title = Taktu þátt í dreifingu síðna með jöfnuntölum -pdfjs-spread-even-button-label = Jafnatöludreifing - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Eiginleikar skjals… -pdfjs-document-properties-button-label = Eiginleikar skjals… -pdfjs-document-properties-file-name = Skráarnafn: -pdfjs-document-properties-file-size = Skrárstærð: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Titill: -pdfjs-document-properties-author = Hönnuður: -pdfjs-document-properties-subject = Efni: -pdfjs-document-properties-keywords = Stikkorð: -pdfjs-document-properties-creation-date = Búið til: -pdfjs-document-properties-modification-date = Dags breytingar: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Höfundur: -pdfjs-document-properties-producer = PDF framleiðandi: -pdfjs-document-properties-version = PDF útgáfa: -pdfjs-document-properties-page-count = Blaðsíðufjöldi: -pdfjs-document-properties-page-size = Stærð síðu: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = skammsnið -pdfjs-document-properties-page-size-orientation-landscape = langsnið -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fljótleg vefskoðun: -pdfjs-document-properties-linearized-yes = Já -pdfjs-document-properties-linearized-no = Nei -pdfjs-document-properties-close-button = Loka - -## Print - -pdfjs-print-progress-message = Undirbý skjal fyrir prentun… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Hætta við -pdfjs-printing-not-supported = Aðvörun: Prentun er ekki með fyllilegan stuðning á þessum vafra. -pdfjs-printing-not-ready = Aðvörun: Ekki er búið að hlaða inn allri PDF skránni fyrir prentun. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Víxla hliðarspjaldi af/á -pdfjs-toggle-sidebar-notification-button = - .title = Víxla hliðarslá (skjal inniheldur yfirlit/viðhengi/lög) -pdfjs-toggle-sidebar-button-label = Víxla hliðarspjaldi af/á -pdfjs-document-outline-button = - .title = Sýna yfirlit skjals (tvísmelltu til að opna/loka öllum hlutum) -pdfjs-document-outline-button-label = Efnisskipan skjals -pdfjs-attachments-button = - .title = Sýna viðhengi -pdfjs-attachments-button-label = Viðhengi -pdfjs-layers-button = - .title = Birta lög (tvísmelltu til að endurstilla öll lög í sjálfgefna stöðu) -pdfjs-layers-button-label = Lög -pdfjs-thumbs-button = - .title = Sýna smámyndir -pdfjs-thumbs-button-label = Smámyndir -pdfjs-current-outline-item-button = - .title = Finna núverandi atriði efnisskipunar -pdfjs-current-outline-item-button-label = Núverandi atriði efnisskipunar -pdfjs-findbar-button = - .title = Leita í skjali -pdfjs-findbar-button-label = Leita -pdfjs-additional-layers = Viðbótarlög - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Síða { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Smámynd af síðu { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Leita - .placeholder = Leita í skjali… -pdfjs-find-previous-button = - .title = Leita að fyrra tilfelli þessara orða -pdfjs-find-previous-button-label = Fyrri -pdfjs-find-next-button = - .title = Leita að næsta tilfelli þessara orða -pdfjs-find-next-button-label = Næsti -pdfjs-find-highlight-checkbox = Lita allt -pdfjs-find-match-case-checkbox-label = Passa við stafstöðu -pdfjs-find-match-diacritics-checkbox-label = Passa við broddstafi -pdfjs-find-entire-word-checkbox-label = Heil orð -pdfjs-find-reached-top = Náði efst í skjal, held áfram neðst -pdfjs-find-reached-bottom = Náði enda skjals, held áfram efst -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } af { $total } passar við - *[other] { $current } af { $total } passa við - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Fleiri en { $limit } passar við - *[other] Fleiri en { $limit } passa við - } -pdfjs-find-not-found = Fann ekki orðið - -## Predefined zoom values - -pdfjs-page-scale-width = Síðubreidd -pdfjs-page-scale-fit = Passa á síðu -pdfjs-page-scale-auto = Sjálfvirkur aðdráttur -pdfjs-page-scale-actual = Raunstærð -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Síða { $page } - -## Loading indicator messages - -pdfjs-loading-error = Villa kom upp við að hlaða inn PDF. -pdfjs-invalid-file-error = Ógild eða skemmd PDF skrá. -pdfjs-missing-file-error = Vantar PDF skrá. -pdfjs-unexpected-response-error = Óvænt svar frá netþjóni. -pdfjs-rendering-error = Upp kom villa við að birta síðuna. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Skýring] - -## Password - -pdfjs-password-label = Sláðu inn lykilorð til að opna þessa PDF skrá. -pdfjs-password-invalid = Ógilt lykilorð. Reyndu aftur. -pdfjs-password-ok-button = Í lagi -pdfjs-password-cancel-button = Hætta við -pdfjs-web-fonts-disabled = Vef leturgerðir eru óvirkar: get ekki notað innbyggðar PDF leturgerðir. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texti -pdfjs-editor-free-text-button-label = Texti -pdfjs-editor-ink-button = - .title = Teikna -pdfjs-editor-ink-button-label = Teikna -pdfjs-editor-stamp-button = - .title = Bæta við eða breyta myndum -pdfjs-editor-stamp-button-label = Bæta við eða breyta myndum -pdfjs-editor-highlight-button = - .title = Áherslulita -pdfjs-editor-highlight-button-label = Áherslulita -pdfjs-highlight-floating-button = - .title = Áherslulita -pdfjs-highlight-floating-button1 = - .title = Áherslulita - .aria-label = Áherslulita -pdfjs-highlight-floating-button-label = Áherslulita - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Fjarlægja teikningu -pdfjs-editor-remove-freetext-button = - .title = Fjarlægja texta -pdfjs-editor-remove-stamp-button = - .title = Fjarlægja mynd -pdfjs-editor-remove-highlight-button = - .title = Fjarlægja áherslulit - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Litur -pdfjs-editor-free-text-size-input = Stærð -pdfjs-editor-ink-color-input = Litur -pdfjs-editor-ink-thickness-input = Þykkt -pdfjs-editor-ink-opacity-input = Ógegnsæi -pdfjs-editor-stamp-add-image-button = - .title = Bæta við mynd -pdfjs-editor-stamp-add-image-button-label = Bæta við mynd -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Þykkt -pdfjs-editor-free-highlight-thickness-title = - .title = Breyta þykkt við áherslulitun annarra atriða en texta -pdfjs-free-text = - .aria-label = Textaritill -pdfjs-free-text-default-content = Byrjaðu að skrifa… -pdfjs-ink = - .aria-label = Teikniritill -pdfjs-ink-canvas = - .aria-label = Mynd gerð af notanda - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alt-varatexti -pdfjs-editor-alt-text-edit-button-label = Breyta alt-varatexta -pdfjs-editor-alt-text-dialog-label = Veldu valkost -pdfjs-editor-alt-text-dialog-description = Alt-varatexti (auka-myndatexti) hjálpar þegar fólk getur ekki séð myndina eða þegar hún hleðst ekki inn. -pdfjs-editor-alt-text-add-description-label = Bættu við lýsingu -pdfjs-editor-alt-text-add-description-description = Reyndu að takmarka þetta við 1-2 setningar sem lýsa efninu, umhverfi eða aðgerðum. -pdfjs-editor-alt-text-mark-decorative-label = Merkja sem skraut -pdfjs-editor-alt-text-mark-decorative-description = Þetta er notað fyrir skrautmyndir, eins og borða eða vatnsmerki. -pdfjs-editor-alt-text-cancel-button = Hætta við -pdfjs-editor-alt-text-save-button = Vista -pdfjs-editor-alt-text-decorative-tooltip = Merkt sem skraut -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Til dæmis: „Ungur maður sest við borð til að snæða máltíð“ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Efst í vinstra horni - breyta stærð -pdfjs-editor-resizer-label-top-middle = Efst á miðju - breyta stærð -pdfjs-editor-resizer-label-top-right = Efst í hægra horni - breyta stærð -pdfjs-editor-resizer-label-middle-right = Miðja til hægri - breyta stærð -pdfjs-editor-resizer-label-bottom-right = Neðst í hægra horni - breyta stærð -pdfjs-editor-resizer-label-bottom-middle = Neðst á miðju - breyta stærð -pdfjs-editor-resizer-label-bottom-left = Neðst í vinstra horni - breyta stærð -pdfjs-editor-resizer-label-middle-left = Miðja til vinstri - breyta stærð - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Áherslulitur -pdfjs-editor-colorpicker-button = - .title = Skipta um lit -pdfjs-editor-colorpicker-dropdown = - .aria-label = Val lita -pdfjs-editor-colorpicker-yellow = - .title = Gult -pdfjs-editor-colorpicker-green = - .title = Grænt -pdfjs-editor-colorpicker-blue = - .title = Blátt -pdfjs-editor-colorpicker-pink = - .title = Bleikt -pdfjs-editor-colorpicker-red = - .title = Rautt - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Birta allt -pdfjs-editor-highlight-show-all-button = - .title = Birta allt diff --git a/static/pdf.js/locale/is/viewer.properties b/static/pdf.js/locale/is/viewer.properties new file mode 100644 index 00000000..e969f4eb --- /dev/null +++ b/static/pdf.js/locale/is/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Fyrri síða +previous_label=Fyrri +next.title=Næsta síða +next_label=Næsti + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Síða: +page_of=af {{pageCount}} + +zoom_out.title=Minnka +zoom_out_label=Minnka +zoom_in.title=Stækka +zoom_in_label=Stækka +zoom.title=Aðdráttur +presentation_mode.title=Skipta yfir á kynningarham +presentation_mode_label=Kynningarhamur +open_file.title=Opna skrá +open_file_label=Opna +print.title=Prenta +print_label=Prenta +download.title=Hala niður +download_label=Hala niður +bookmark.title=Núverandi sýn (afritaðu eða opnaðu í nýjum glugga) +bookmark_label=Núverandi sýn + +# Secondary toolbar and context menu +tools.title=Verkfæri +tools_label=Verkfæri +first_page.title=Fara á fyrstu síðu +first_page.label=Fara á fyrstu síðu +first_page_label=Fara á fyrstu síðu +last_page.title=Fara á síðustu síðu +last_page.label=Fara á síðustu síðu +last_page_label=Fara á síðustu síðu +page_rotate_cw.title=Snúa réttsælis +page_rotate_cw.label=Snúa réttsælis +page_rotate_cw_label=Snúa réttsælis +page_rotate_ccw.title=Snúa rangsælis +page_rotate_ccw.label=Snúa rangsælis +page_rotate_ccw_label=Snúa rangsælis + +hand_tool_enable.title=Virkja handarverkfæri +hand_tool_enable_label=Virkja handarverkfæri +hand_tool_disable.title=Gera handarverkfæri óvirkt +hand_tool_disable_label=Gera handarverkfæri óvirkt + +# Document properties dialog box +document_properties.title=Eiginleikar skjals… +document_properties_label=Eiginleikar skjals… +document_properties_file_name=Skráarnafn: +document_properties_file_size=Skrárstærð: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Titill: +document_properties_author=Hönnuður: +document_properties_subject=Efni: +document_properties_keywords=Stikkorð: +document_properties_creation_date=Búið til: +document_properties_modification_date=Dags breytingar: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Höfundur: +document_properties_producer=PDF framleiðandi: +document_properties_version=PDF útgáfa: +document_properties_page_count=Blaðsíðufjöldi: +document_properties_close=Loka + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Víxla hliðslá +toggle_sidebar_label=Víxla hliðslá +outline.title=Sýna efniskipan skjals +outline_label=Efnisskipan skjals +attachments.title=Sýna viðhengi +attachments_label=Viðhengi +thumbs.title=Sýna smámyndir +thumbs_label=Smámyndir +findbar.title=Leita í skjali +findbar_label=Leita + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Síða {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Smámynd af síðu {{page}} + +# Find panel button title and messages +find_label=Leita: +find_previous.title=Leita að fyrra tilfelli þessara orða +find_previous_label=Fyrri +find_next.title=Leita að næsta tilfelli þessara orða +find_next_label=Næsti +find_highlight=Lita allt +find_match_case_label=Passa við stafstöðu +find_reached_top=Náði efst í skjal, held áfram neðst +find_reached_bottom=Náði enda skjals, held áfram efst +find_not_found=Fann ekki orðið + +# Error panel labels +error_more_info=Meiri upplýsingar +error_less_info=Minni upplýsingar +error_close=Loka +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Skilaboð: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stafli: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Skrá: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Lína: {{line}} +rendering_error=Upp kom villa við að birta síðuna. + +# Predefined zoom values +page_scale_width=Síðubreidd +page_scale_fit=Passa á síðu +page_scale_auto=Sjálfvirkur aðdráttur +page_scale_actual=Raunstærð +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Villa +loading_error=Villa kom upp við að hlaða inn PDF. +invalid_file_error=Ógild eða skemmd PDF skrá. +missing_file_error=Vantar PDF skrá. +unexpected_response_error=Óvænt svar frá netþjóni. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Skýring] +password_label=Sláðu inn lykilorð til að opna þessa PDF skrá. +password_invalid=Ógilt lykilorð. Reyndu aftur. +password_ok=Í lagi +password_cancel=Hætta við + +printing_not_supported=Aðvörun: Prentun er ekki með fyllilegan stuðning á þessum vafra. +printing_not_ready=Aðvörun: Ekki er búið að hlaða inn allri PDF skránni fyrir prentun. +web_fonts_disabled=Vef leturgerðir eru óvirkar: get ekki notað innbyggðar PDF leturgerðir. +document_colors_not_allowed=PDF skjöl hafa ekki leyfi til að nota sína eigin liti: 'Leyfa síðum að velja eigin liti' er óvirkt í vafranum. diff --git a/static/pdf.js/locale/it/viewer.ftl b/static/pdf.js/locale/it/viewer.ftl deleted file mode 100644 index fcdab36a..00000000 --- a/static/pdf.js/locale/it/viewer.ftl +++ /dev/null @@ -1,399 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pagina precedente -pdfjs-previous-button-label = Precedente -pdfjs-next-button = - .title = Pagina successiva -pdfjs-next-button-label = Successiva -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pagina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = di { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } di { $pagesCount }) -pdfjs-zoom-out-button = - .title = Riduci zoom -pdfjs-zoom-out-button-label = Riduci zoom -pdfjs-zoom-in-button = - .title = Aumenta zoom -pdfjs-zoom-in-button-label = Aumenta zoom -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Passa alla modalità presentazione -pdfjs-presentation-mode-button-label = Modalità presentazione -pdfjs-open-file-button = - .title = Apri file -pdfjs-open-file-button-label = Apri -pdfjs-print-button = - .title = Stampa -pdfjs-print-button-label = Stampa -pdfjs-save-button = - .title = Salva -pdfjs-save-button-label = Salva -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Scarica -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Scarica -pdfjs-bookmark-button = - .title = Pagina corrente (mostra URL della pagina corrente) -pdfjs-bookmark-button-label = Pagina corrente - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Strumenti -pdfjs-tools-button-label = Strumenti -pdfjs-first-page-button = - .title = Vai alla prima pagina -pdfjs-first-page-button-label = Vai alla prima pagina -pdfjs-last-page-button = - .title = Vai all’ultima pagina -pdfjs-last-page-button-label = Vai all’ultima pagina -pdfjs-page-rotate-cw-button = - .title = Ruota in senso orario -pdfjs-page-rotate-cw-button-label = Ruota in senso orario -pdfjs-page-rotate-ccw-button = - .title = Ruota in senso antiorario -pdfjs-page-rotate-ccw-button-label = Ruota in senso antiorario -pdfjs-cursor-text-select-tool-button = - .title = Attiva strumento di selezione testo -pdfjs-cursor-text-select-tool-button-label = Strumento di selezione testo -pdfjs-cursor-hand-tool-button = - .title = Attiva strumento mano -pdfjs-cursor-hand-tool-button-label = Strumento mano -pdfjs-scroll-page-button = - .title = Utilizza scorrimento pagine -pdfjs-scroll-page-button-label = Scorrimento pagine -pdfjs-scroll-vertical-button = - .title = Scorri le pagine in verticale -pdfjs-scroll-vertical-button-label = Scorrimento verticale -pdfjs-scroll-horizontal-button = - .title = Scorri le pagine in orizzontale -pdfjs-scroll-horizontal-button-label = Scorrimento orizzontale -pdfjs-scroll-wrapped-button = - .title = Scorri le pagine in verticale, disponendole da sinistra a destra e andando a capo automaticamente -pdfjs-scroll-wrapped-button-label = Scorrimento con a capo automatico -pdfjs-spread-none-button = - .title = Non raggruppare pagine -pdfjs-spread-none-button-label = Nessun raggruppamento -pdfjs-spread-odd-button = - .title = Crea gruppi di pagine che iniziano con numeri di pagina dispari -pdfjs-spread-odd-button-label = Raggruppamento dispari -pdfjs-spread-even-button = - .title = Crea gruppi di pagine che iniziano con numeri di pagina pari -pdfjs-spread-even-button-label = Raggruppamento pari - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Proprietà del documento… -pdfjs-document-properties-button-label = Proprietà del documento… -pdfjs-document-properties-file-name = Nome file: -pdfjs-document-properties-file-size = Dimensione file: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kB ({ $size_b } byte) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } byte) -pdfjs-document-properties-title = Titolo: -pdfjs-document-properties-author = Autore: -pdfjs-document-properties-subject = Oggetto: -pdfjs-document-properties-keywords = Parole chiave: -pdfjs-document-properties-creation-date = Data creazione: -pdfjs-document-properties-modification-date = Data modifica: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Autore originale: -pdfjs-document-properties-producer = Produttore PDF: -pdfjs-document-properties-version = Versione PDF: -pdfjs-document-properties-page-count = Conteggio pagine: -pdfjs-document-properties-page-size = Dimensioni pagina: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = verticale -pdfjs-document-properties-page-size-orientation-landscape = orizzontale -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Lettera -pdfjs-document-properties-page-size-name-legal = Legale - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Visualizzazione web veloce: -pdfjs-document-properties-linearized-yes = Sì -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Chiudi - -## Print - -pdfjs-print-progress-message = Preparazione documento per la stampa… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Annulla -pdfjs-printing-not-supported = Attenzione: la stampa non è completamente supportata da questo browser. -pdfjs-printing-not-ready = Attenzione: il PDF non è ancora stato caricato completamente per la stampa. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Attiva/disattiva barra laterale -pdfjs-toggle-sidebar-notification-button = - .title = Attiva/disattiva barra laterale (il documento contiene struttura/allegati/livelli) -pdfjs-toggle-sidebar-button-label = Attiva/disattiva barra laterale -pdfjs-document-outline-button = - .title = Visualizza la struttura del documento (doppio clic per visualizzare/comprimere tutti gli elementi) -pdfjs-document-outline-button-label = Struttura documento -pdfjs-attachments-button = - .title = Visualizza allegati -pdfjs-attachments-button-label = Allegati -pdfjs-layers-button = - .title = Visualizza livelli (doppio clic per ripristinare tutti i livelli allo stato predefinito) -pdfjs-layers-button-label = Livelli -pdfjs-thumbs-button = - .title = Mostra le miniature -pdfjs-thumbs-button-label = Miniature -pdfjs-current-outline-item-button = - .title = Trova elemento struttura corrente -pdfjs-current-outline-item-button-label = Elemento struttura corrente -pdfjs-findbar-button = - .title = Trova nel documento -pdfjs-findbar-button-label = Trova -pdfjs-additional-layers = Livelli aggiuntivi - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pagina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura della pagina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Trova - .placeholder = Trova nel documento… -pdfjs-find-previous-button = - .title = Trova l’occorrenza precedente del testo da cercare -pdfjs-find-previous-button-label = Precedente -pdfjs-find-next-button = - .title = Trova l’occorrenza successiva del testo da cercare -pdfjs-find-next-button-label = Successivo -pdfjs-find-highlight-checkbox = Evidenzia -pdfjs-find-match-case-checkbox-label = Maiuscole/minuscole -pdfjs-find-match-diacritics-checkbox-label = Segni diacritici -pdfjs-find-entire-word-checkbox-label = Parole intere -pdfjs-find-reached-top = Raggiunto l’inizio della pagina, continua dalla fine -pdfjs-find-reached-bottom = Raggiunta la fine della pagina, continua dall’inizio - -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } di { $total } corrispondenza - *[other] { $current } di { $total } corrispondenze - } - -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Più di una { $limit } corrispondenza - *[other] Più di { $limit } corrispondenze - } - -pdfjs-find-not-found = Testo non trovato - -## Predefined zoom values - -pdfjs-page-scale-width = Larghezza pagina -pdfjs-page-scale-fit = Adatta a una pagina -pdfjs-page-scale-auto = Zoom automatico -pdfjs-page-scale-actual = Dimensioni effettive -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pagina { $page } - -## Loading indicator messages - -pdfjs-loading-error = Si è verificato un errore durante il caricamento del PDF. -pdfjs-invalid-file-error = File PDF non valido o danneggiato. -pdfjs-missing-file-error = File PDF non disponibile. -pdfjs-unexpected-response-error = Risposta imprevista del server -pdfjs-rendering-error = Si è verificato un errore durante il rendering della pagina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Annotazione: { $type }] - -## Password - -pdfjs-password-label = Inserire la password per aprire questo file PDF. -pdfjs-password-invalid = Password non corretta. Riprovare. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Annulla -pdfjs-web-fonts-disabled = I web font risultano disattivati: impossibile utilizzare i caratteri incorporati nel PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Testo -pdfjs-editor-free-text-button-label = Testo -pdfjs-editor-ink-button = - .title = Disegno -pdfjs-editor-ink-button-label = Disegno -pdfjs-editor-stamp-button = - .title = Aggiungi o rimuovi immagine -pdfjs-editor-stamp-button-label = Aggiungi o rimuovi immagine -pdfjs-editor-highlight-button = - .title = Evidenzia -pdfjs-editor-highlight-button-label = Evidenzia -pdfjs-highlight-floating-button1 = - .title = Evidenzia - .aria-label = Evidenzia -pdfjs-highlight-floating-button-label = Evidenzia - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Rimuovi disegno -pdfjs-editor-remove-freetext-button = - .title = Rimuovi testo -pdfjs-editor-remove-stamp-button = - .title = Rimuovi immagine -pdfjs-editor-remove-highlight-button = - .title = Rimuovi evidenziazione - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Colore -pdfjs-editor-free-text-size-input = Dimensione -pdfjs-editor-ink-color-input = Colore -pdfjs-editor-ink-thickness-input = Spessore -pdfjs-editor-ink-opacity-input = Opacità -pdfjs-editor-stamp-add-image-button = - .title = Aggiungi immagine -pdfjs-editor-stamp-add-image-button-label = Aggiungi immagine -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Spessore -pdfjs-editor-free-highlight-thickness-title = - .title = Modifica lo spessore della selezione per elementi non testuali - -pdfjs-free-text = - .aria-label = Editor di testo -pdfjs-free-text-default-content = Inizia a digitare… -pdfjs-ink = - .aria-label = Editor disegni -pdfjs-ink-canvas = - .aria-label = Immagine creata dall’utente - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Testo alternativo -pdfjs-editor-alt-text-edit-button-label = Modifica testo alternativo -pdfjs-editor-alt-text-dialog-label = Scegli un’opzione -pdfjs-editor-alt-text-dialog-description = Il testo alternativo (“alt text”) aiuta quando le persone non possono vedere l’immagine o quando l’immagine non viene caricata. -pdfjs-editor-alt-text-add-description-label = Aggiungi una descrizione -pdfjs-editor-alt-text-add-description-description = Punta a una o due frasi che descrivono l’argomento, l’ambientazione o le azioni. -pdfjs-editor-alt-text-mark-decorative-label = Contrassegna come decorativa -pdfjs-editor-alt-text-mark-decorative-description = Viene utilizzato per immagini ornamentali, come bordi o filigrane. -pdfjs-editor-alt-text-cancel-button = Annulla -pdfjs-editor-alt-text-save-button = Salva -pdfjs-editor-alt-text-decorative-tooltip = Contrassegnata come decorativa -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Ad esempio, “Un giovane si siede a tavola per mangiare” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Angolo in alto a sinistra — ridimensiona -pdfjs-editor-resizer-label-top-middle = Lato superiore nel mezzo — ridimensiona -pdfjs-editor-resizer-label-top-right = Angolo in alto a destra — ridimensiona -pdfjs-editor-resizer-label-middle-right = Lato destro nel mezzo — ridimensiona -pdfjs-editor-resizer-label-bottom-right = Angolo in basso a destra — ridimensiona -pdfjs-editor-resizer-label-bottom-middle = Lato inferiore nel mezzo — ridimensiona -pdfjs-editor-resizer-label-bottom-left = Angolo in basso a sinistra — ridimensiona -pdfjs-editor-resizer-label-middle-left = Lato sinistro nel mezzo — ridimensiona - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Colore evidenziatore - -pdfjs-editor-colorpicker-button = - .title = Cambia colore -pdfjs-editor-colorpicker-dropdown = - .aria-label = Colori disponibili -pdfjs-editor-colorpicker-yellow = - .title = Giallo -pdfjs-editor-colorpicker-green = - .title = Verde -pdfjs-editor-colorpicker-blue = - .title = Blu -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Rosso - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Mostra tutto -pdfjs-editor-highlight-show-all-button = - .title = Mostra tutto diff --git a/static/pdf.js/locale/it/viewer.properties b/static/pdf.js/locale/it/viewer.properties new file mode 100644 index 00000000..9ddd35b4 --- /dev/null +++ b/static/pdf.js/locale/it/viewer.properties @@ -0,0 +1,111 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +previous.title = Pagina precedente +previous_label = Precedente +next.title = Pagina successiva +next_label = Successiva +page_label = Pagina: +page_of = di {{pageCount}} +zoom_out.title = Riduci zoom +zoom_out_label = Riduci zoom +zoom_in.title = Aumenta zoom +zoom_in_label = Aumenta zoom +zoom.title = Zoom +presentation_mode.title = Passa alla modalità presentazione +presentation_mode_label = Modalità presentazione +open_file.title = Apri file +open_file_label = Apri +print.title = Stampa +print_label = Stampa +download.title = Scarica questo documento +download_label = Download +bookmark.title = Visualizzazione corrente (copia o apri in una nuova finestra) +bookmark_label = Visualizzazione corrente +tools.title = Strumenti +tools_label = Strumenti +first_page.title = Vai alla prima pagina +first_page.label = Vai alla prima pagina +first_page_label = Vai alla prima pagina +last_page.title = Vai all’ultima pagina +last_page.label = Vai all’ultima pagina +last_page_label = Vai all’ultima pagina +page_rotate_cw.title = Ruota in senso orario +page_rotate_cw.label = Ruota in senso orario +page_rotate_cw_label = Ruota in senso orario +page_rotate_ccw.title = Ruota in senso antiorario +page_rotate_ccw.label = Ruota in senso antiorario +page_rotate_ccw_label = Ruota in senso antiorario +hand_tool_enable.title = Attiva strumento mano +hand_tool_enable_label = Attiva strumento mano +hand_tool_disable.title = Disattiva strumento mano +hand_tool_disable_label = Disattiva strumento mano +document_properties.title = Proprietà del documento… +document_properties_label = Proprietà del documento… +document_properties_file_name = Nome file: +document_properties_file_size = Dimensione file: +document_properties_kb = {{size_kb}} kB ({{size_b}} byte) +document_properties_mb = {{size_mb}} MB ({{size_b}} byte) +document_properties_title = Titolo: +document_properties_author = Autore: +document_properties_subject = Oggetto: +document_properties_keywords = Parole chiave: +document_properties_creation_date = Data creazione: +document_properties_modification_date = Data modifica: +document_properties_date_string = {{date}}, {{time}} +document_properties_creator = Autore originale: +document_properties_producer = Produttore PDF: +document_properties_version = Versione PDF: +document_properties_page_count = Conteggio pagine: +document_properties_close = Chiudi +toggle_sidebar.title = Attiva/disattiva barra laterale +toggle_sidebar_label = Attiva/disattiva barra laterale +outline.title = Visualizza la struttura del documento +outline_label = Struttura documento +attachments.title = Visualizza allegati +attachments_label = Allegati +thumbs.title = Mostra le miniature +thumbs_label = Miniature +findbar.title = Trova nel documento +findbar_label = Trova +thumb_page_title = Pagina {{page}} +thumb_page_canvas = Miniatura della pagina {{page}} +find_label = Trova: +find_previous.title = Trova l’occorrenza precedente del testo da cercare +find_previous_label = Precedente +find_next.title = Trova l’occorrenza successiva del testo da cercare +find_next_label = Successivo +find_highlight = Evidenzia +find_match_case_label = Maiuscole/minuscole +find_reached_top = Raggiunto l’inizio della pagina, continua dalla fine +find_reached_bottom = Raggiunta la fine della pagina, continua dall’inizio +find_not_found = Testo non trovato +error_more_info = Ulteriori informazioni +error_less_info = Nascondi dettagli +error_close = Chiudi +error_version_info = PDF.js v{{version}} (build: {{build}}) +error_message = Messaggio: {{message}} +error_stack = Stack: {{stack}} +error_file = File: {{file}} +error_line = Riga: {{line}} +rendering_error = Si è verificato un errore durante il rendering della pagina. +page_scale_width = Larghezza pagina +page_scale_fit = Adatta a una pagina +page_scale_auto = Zoom automatico +page_scale_actual = Dimensioni effettive +page_scale_percent = {{scale}}% +loading_error_indicator = Errore +loading_error = Si è verificato un errore durante il caricamento del PDF. +invalid_file_error = File PDF non valido o danneggiato. +missing_file_error = File PDF non disponibile. +unexpected_response_error = Risposta imprevista del server +text_annotation_type.alt = [Annotazione: {{type}}] +password_label = Inserire la password per aprire questo file PDF. +password_invalid = Password non corretta. Riprovare. +password_ok = OK +password_cancel = Annulla +printing_not_supported = Attenzione: la stampa non è completamente supportata da questo browser. +printing_not_ready = Attenzione: il PDF non è ancora stato caricato completamente per la stampa. +web_fonts_disabled = I web font risultano disattivati: impossibile utilizzare i caratteri inclusi nel PDF. +document_colors_not_allowed = Non è possibile visualizzare i colori originali definiti nel file PDF: l’opzione del browser “Consenti alle pagine di scegliere i propri colori invece di quelli impostati” è disattivata. diff --git a/static/pdf.js/locale/ja/viewer.ftl b/static/pdf.js/locale/ja/viewer.ftl deleted file mode 100644 index 9fd0d5b0..00000000 --- a/static/pdf.js/locale/ja/viewer.ftl +++ /dev/null @@ -1,394 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = 前のページへ戻ります -pdfjs-previous-button-label = 前へ -pdfjs-next-button = - .title = 次のページへ進みます -pdfjs-next-button-label = 次へ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = ページ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = / { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } / { $pagesCount }) -pdfjs-zoom-out-button = - .title = 表示を縮小します -pdfjs-zoom-out-button-label = 縮小 -pdfjs-zoom-in-button = - .title = 表示を拡大します -pdfjs-zoom-in-button-label = 拡大 -pdfjs-zoom-select = - .title = 拡大/縮小 -pdfjs-presentation-mode-button = - .title = プレゼンテーションモードに切り替えます -pdfjs-presentation-mode-button-label = プレゼンテーションモード -pdfjs-open-file-button = - .title = ファイルを開きます -pdfjs-open-file-button-label = 開く -pdfjs-print-button = - .title = 印刷します -pdfjs-print-button-label = 印刷 -pdfjs-save-button = - .title = 保存します -pdfjs-save-button-label = 保存 -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = ダウンロードします -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = ダウンロード -pdfjs-bookmark-button = - .title = 現在のページの URL です (現在のページを表示する URL) -pdfjs-bookmark-button-label = 現在のページ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ツール -pdfjs-tools-button-label = ツール -pdfjs-first-page-button = - .title = 最初のページへ移動します -pdfjs-first-page-button-label = 最初のページへ移動 -pdfjs-last-page-button = - .title = 最後のページへ移動します -pdfjs-last-page-button-label = 最後のページへ移動 -pdfjs-page-rotate-cw-button = - .title = ページを右へ回転します -pdfjs-page-rotate-cw-button-label = 右回転 -pdfjs-page-rotate-ccw-button = - .title = ページを左へ回転します -pdfjs-page-rotate-ccw-button-label = 左回転 -pdfjs-cursor-text-select-tool-button = - .title = テキスト選択ツールを有効にします -pdfjs-cursor-text-select-tool-button-label = テキスト選択ツール -pdfjs-cursor-hand-tool-button = - .title = 手のひらツールを有効にします -pdfjs-cursor-hand-tool-button-label = 手のひらツール -pdfjs-scroll-page-button = - .title = ページ単位でスクロールします -pdfjs-scroll-page-button-label = ページ単位でスクロール -pdfjs-scroll-vertical-button = - .title = 縦スクロールにします -pdfjs-scroll-vertical-button-label = 縦スクロール -pdfjs-scroll-horizontal-button = - .title = 横スクロールにします -pdfjs-scroll-horizontal-button-label = 横スクロール -pdfjs-scroll-wrapped-button = - .title = 折り返しスクロールにします -pdfjs-scroll-wrapped-button-label = 折り返しスクロール -pdfjs-spread-none-button = - .title = 見開きにしません -pdfjs-spread-none-button-label = 見開きにしない -pdfjs-spread-odd-button = - .title = 奇数ページ開始で見開きにします -pdfjs-spread-odd-button-label = 奇数ページ見開き -pdfjs-spread-even-button = - .title = 偶数ページ開始で見開きにします -pdfjs-spread-even-button-label = 偶数ページ見開き - -## Document properties dialog - -pdfjs-document-properties-button = - .title = 文書のプロパティ... -pdfjs-document-properties-button-label = 文書のプロパティ... -pdfjs-document-properties-file-name = ファイル名: -pdfjs-document-properties-file-size = ファイルサイズ: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } バイト) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } バイト) -pdfjs-document-properties-title = タイトル: -pdfjs-document-properties-author = 作成者: -pdfjs-document-properties-subject = 件名: -pdfjs-document-properties-keywords = キーワード: -pdfjs-document-properties-creation-date = 作成日: -pdfjs-document-properties-modification-date = 更新日: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = アプリケーション: -pdfjs-document-properties-producer = PDF 作成: -pdfjs-document-properties-version = PDF のバージョン: -pdfjs-document-properties-page-count = ページ数: -pdfjs-document-properties-page-size = ページサイズ: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = 縦 -pdfjs-document-properties-page-size-orientation-landscape = 横 -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = レター -pdfjs-document-properties-page-size-name-legal = リーガル - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = ウェブ表示用に最適化: -pdfjs-document-properties-linearized-yes = はい -pdfjs-document-properties-linearized-no = いいえ -pdfjs-document-properties-close-button = 閉じる - -## Print - -pdfjs-print-progress-message = 文書の印刷を準備しています... -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = キャンセル -pdfjs-printing-not-supported = 警告: このブラウザーでは印刷が完全にサポートされていません。 -pdfjs-printing-not-ready = 警告: PDF を印刷するための読み込みが終了していません。 - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = サイドバー表示を切り替えます -pdfjs-toggle-sidebar-notification-button = - .title = サイドバー表示を切り替えます (文書に含まれるアウトライン / 添付 / レイヤー) -pdfjs-toggle-sidebar-button-label = サイドバーの切り替え -pdfjs-document-outline-button = - .title = 文書の目次を表示します (ダブルクリックで項目を開閉します) -pdfjs-document-outline-button-label = 文書の目次 -pdfjs-attachments-button = - .title = 添付ファイルを表示します -pdfjs-attachments-button-label = 添付ファイル -pdfjs-layers-button = - .title = レイヤーを表示します (ダブルクリックですべてのレイヤーが初期状態に戻ります) -pdfjs-layers-button-label = レイヤー -pdfjs-thumbs-button = - .title = 縮小版を表示します -pdfjs-thumbs-button-label = 縮小版 -pdfjs-current-outline-item-button = - .title = 現在のアウトライン項目を検索 -pdfjs-current-outline-item-button-label = 現在のアウトライン項目 -pdfjs-findbar-button = - .title = 文書内を検索します -pdfjs-findbar-button-label = 検索 -pdfjs-additional-layers = 追加レイヤー - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page } ページ -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } ページの縮小版 - -## Find panel button title and messages - -pdfjs-find-input = - .title = 検索 - .placeholder = 文書内を検索... -pdfjs-find-previous-button = - .title = 現在より前の位置で指定文字列が現れる部分を検索します -pdfjs-find-previous-button-label = 前へ -pdfjs-find-next-button = - .title = 現在より後の位置で指定文字列が現れる部分を検索します -pdfjs-find-next-button-label = 次へ -pdfjs-find-highlight-checkbox = すべて強調表示 -pdfjs-find-match-case-checkbox-label = 大文字/小文字を区別 -pdfjs-find-match-diacritics-checkbox-label = 発音区別符号を区別 -pdfjs-find-entire-word-checkbox-label = 単語一致 -pdfjs-find-reached-top = 文書先頭に到達したので末尾から続けて検索します -pdfjs-find-reached-bottom = 文書末尾に到達したので先頭から続けて検索します -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $total } 件中 { $current } 件目 - *[other] { $total } 件中 { $current } 件目 - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] { $limit } 件以上一致 - *[other] { $limit } 件以上一致 - } -pdfjs-find-not-found = 見つかりませんでした - -## Predefined zoom values - -pdfjs-page-scale-width = 幅に合わせる -pdfjs-page-scale-fit = ページのサイズに合わせる -pdfjs-page-scale-auto = 自動ズーム -pdfjs-page-scale-actual = 実際のサイズ -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = { $page } ページ - -## Loading indicator messages - -pdfjs-loading-error = PDF の読み込み中にエラーが発生しました。 -pdfjs-invalid-file-error = 無効または破損した PDF ファイル。 -pdfjs-missing-file-error = PDF ファイルが見つかりません。 -pdfjs-unexpected-response-error = サーバーから予期せぬ応答がありました。 -pdfjs-rendering-error = ページのレンダリング中にエラーが発生しました。 - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } 注釈] - -## Password - -pdfjs-password-label = この PDF ファイルを開くためのパスワードを入力してください。 -pdfjs-password-invalid = 無効なパスワードです。もう一度やり直してください。 -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = キャンセル -pdfjs-web-fonts-disabled = ウェブフォントが無効になっています: 埋め込まれた PDF のフォントを使用できません。 - -## Editing - -pdfjs-editor-free-text-button = - .title = フリーテキスト注釈を追加します -pdfjs-editor-free-text-button-label = フリーテキスト注釈 -pdfjs-editor-ink-button = - .title = インク注釈を追加します -pdfjs-editor-ink-button-label = インク注釈 -pdfjs-editor-stamp-button = - .title = 画像を追加または編集します -pdfjs-editor-stamp-button-label = 画像を追加または編集 -pdfjs-editor-highlight-button = - .title = 強調します -pdfjs-editor-highlight-button-label = 強調 -pdfjs-highlight-floating-button1 = - .title = 強調 - .aria-label = 強調します -pdfjs-highlight-floating-button-label = 強調 - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = インク注釈を削除します -pdfjs-editor-remove-freetext-button = - .title = テキストを削除します -pdfjs-editor-remove-stamp-button = - .title = 画像を削除します -pdfjs-editor-remove-highlight-button = - .title = 強調を削除します - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = 色 -pdfjs-editor-free-text-size-input = サイズ -pdfjs-editor-ink-color-input = 色 -pdfjs-editor-ink-thickness-input = 太さ -pdfjs-editor-ink-opacity-input = 不透明度 -pdfjs-editor-stamp-add-image-button = - .title = 画像を追加します -pdfjs-editor-stamp-add-image-button-label = 画像を追加 -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = 太さ -pdfjs-editor-free-highlight-thickness-title = - .title = テキスト以外のアイテムを強調する時の太さを変更します -pdfjs-free-text = - .aria-label = フリーテキスト注釈エディター -pdfjs-free-text-default-content = テキストを入力してください... -pdfjs-ink = - .aria-label = インク注釈エディター -pdfjs-ink-canvas = - .aria-label = ユーザー作成画像 - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = 代替テキスト -pdfjs-editor-alt-text-edit-button-label = 代替テキストを編集 -pdfjs-editor-alt-text-dialog-label = オプションの選択 -pdfjs-editor-alt-text-dialog-description = 代替テキストは画像が表示されない場合や読み込まれない場合にユーザーの助けになります。 -pdfjs-editor-alt-text-add-description-label = 説明を追加 -pdfjs-editor-alt-text-add-description-description = 対象や設定、動作を説明する短い文章を記入してください。 -pdfjs-editor-alt-text-mark-decorative-label = 装飾マークを付ける -pdfjs-editor-alt-text-mark-decorative-description = これは区切り線やウォーターマークなどの装飾画像に使用されます。 -pdfjs-editor-alt-text-cancel-button = キャンセル -pdfjs-editor-alt-text-save-button = 保存 -pdfjs-editor-alt-text-decorative-tooltip = 装飾マークが付いています -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = 例:「若い人がテーブルの席について食事をしています」 - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = 左上隅 — サイズ変更 -pdfjs-editor-resizer-label-top-middle = 上中央 — サイズ変更 -pdfjs-editor-resizer-label-top-right = 右上隅 — サイズ変更 -pdfjs-editor-resizer-label-middle-right = 右中央 — サイズ変更 -pdfjs-editor-resizer-label-bottom-right = 右下隅 — サイズ変更 -pdfjs-editor-resizer-label-bottom-middle = 下中央 — サイズ変更 -pdfjs-editor-resizer-label-bottom-left = 左下隅 — サイズ変更 -pdfjs-editor-resizer-label-middle-left = 左中央 — サイズ変更 - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = 強調色 -pdfjs-editor-colorpicker-button = - .title = 色を変更します -pdfjs-editor-colorpicker-dropdown = - .aria-label = 色の選択 -pdfjs-editor-colorpicker-yellow = - .title = 黄色 -pdfjs-editor-colorpicker-green = - .title = 緑色 -pdfjs-editor-colorpicker-blue = - .title = 青色 -pdfjs-editor-colorpicker-pink = - .title = ピンク色 -pdfjs-editor-colorpicker-red = - .title = 赤色 - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = すべて表示 -pdfjs-editor-highlight-show-all-button = - .title = 強調の表示を切り替えます diff --git a/static/pdf.js/locale/ja/viewer.properties b/static/pdf.js/locale/ja/viewer.properties new file mode 100644 index 00000000..4a499715 --- /dev/null +++ b/static/pdf.js/locale/ja/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=前のページへ戻ります +previous_label=前へ +next.title=次のページへ進みます +next_label=次へ + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=ページ: +page_of=/ {{pageCount}} + +zoom_out.title=表示を縮小します +zoom_out_label=縮小 +zoom_in.title=表示を拡大します +zoom_in_label=拡大 +zoom.title=拡大/縮小 +presentation_mode.title=プレゼンテーションモードに切り替えます +presentation_mode_label=プレゼンテーションモード +open_file.title=ファイルを指定して開きます +open_file_label=開く +print.title=印刷します +print_label=印刷 +download.title=ダウンロードします +download_label=ダウンロード +bookmark.title=現在のビューの URL です (コピーまたは新しいウィンドウに開く) +bookmark_label=現在のビュー + +# Secondary toolbar and context menu +tools.title=ツール +tools_label=ツール +first_page.title=最初のページへ移動します +first_page.label=最初のページへ移動 +first_page_label=最初のページへ移動 +last_page.title=最後のページへ移動します +last_page.label=最後のページへ移動 +last_page_label=最後のページへ移動 +page_rotate_cw.title=ページを右へ回転します +page_rotate_cw.label=右回転 +page_rotate_cw_label=右回転 +page_rotate_ccw.title=ページを左へ回転します +page_rotate_ccw.label=左回転 +page_rotate_ccw_label=左回転 + +hand_tool_enable.title=手のひらツールを有効にします +hand_tool_enable_label=手のひらツールを有効にする +hand_tool_disable.title=手のひらツールを無効にします +hand_tool_disable_label=手のひらツールを無効にする + +# Document properties dialog box +document_properties.title=文書のプロパティ... +document_properties_label=文書のプロパティ... +document_properties_file_name=ファイル名: +document_properties_file_size=ファイルサイズ: +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=タイトル: +document_properties_author=作成者: +document_properties_subject=件名: +document_properties_keywords=キーワード: +document_properties_creation_date=作成日: +document_properties_modification_date=更新日: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=アプリケーション: +document_properties_producer=PDF 作成: +document_properties_version=PDF のバージョン: +document_properties_page_count=ページ数: +document_properties_close=閉じる + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=サイドバー表示を切り替えます +toggle_sidebar_label=サイドバーの切り替え +outline.title=文書の目次を表示します +outline_label=文書の目次 +attachments.title=添付ファイルを表示します +attachments_label=添付ファイル +thumbs.title=縮小版を表示します +thumbs_label=縮小版 +findbar.title=文書内を検索します +findbar_label=検索 + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title={{page}} ページ +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=ページの縮小版 {{page}} + +# Find panel button title and messages +find_label=検索: +find_previous.title=指定文字列に一致する 1 つ前の部分を検索します +find_previous_label=前へ +find_next.title=指定文字列に一致する次の部分を検索します +find_next_label=次へ +find_highlight=すべて強調表示 +find_match_case_label=大文字/小文字を区別 +find_reached_top=文書先頭に到達したので末尾に戻って検索しました。 +find_reached_bottom=文書末尾に到達したので先頭に戻って検索しました。 +find_not_found=見つかりませんでした。 + +# Error panel labels +error_more_info=詳細情報 +error_less_info=詳細情報の非表示 +error_close=閉じる +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (ビルド: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=メッセージ: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=スタック: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ファイル: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=行: {{line}} +rendering_error=ページのレンダリング中にエラーが発生しました + +# Predefined zoom values +page_scale_width=幅に合わせる +page_scale_fit=ページのサイズに合わせる +page_scale_auto=自動ズーム +page_scale_actual=実際のサイズ +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=エラー +loading_error=PDF の読み込み中にエラーが発生しました +invalid_file_error=無効または破損した PDF ファイル +missing_file_error=PDF ファイルが見つかりません。 +unexpected_response_error=サーバから予期せぬ応答がありました。 + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} 注釈] +password_label=この PDF ファイルを開くためのパスワードを入力してください。 +password_invalid=無効なパスワードです。もう一度やり直してください。 +password_ok=OK +password_cancel=キャンセル + +printing_not_supported=警告: このブラウザでは印刷が完全にサポートされていません +printing_not_ready=警告: PDF を印刷するための読み込みが終了していません +web_fonts_disabled=Web フォントが無効になっています: 埋め込まれた PDF のフォントを使用できません +document_colors_not_allowed=PDF 文書は、Web ページが指定した配色を使用することができません: 'Web ページが指定した配色' はブラウザで無効になっています。 diff --git a/static/pdf.js/locale/ka/viewer.ftl b/static/pdf.js/locale/ka/viewer.ftl deleted file mode 100644 index f31898fa..00000000 --- a/static/pdf.js/locale/ka/viewer.ftl +++ /dev/null @@ -1,387 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = წინა გვერდი -pdfjs-previous-button-label = წინა -pdfjs-next-button = - .title = შემდეგი გვერდი -pdfjs-next-button-label = შემდეგი -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = გვერდი -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount }-დან -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } { $pagesCount }-დან) -pdfjs-zoom-out-button = - .title = ზომის შემცირება -pdfjs-zoom-out-button-label = დაშორება -pdfjs-zoom-in-button = - .title = ზომის გაზრდა -pdfjs-zoom-in-button-label = მოახლოება -pdfjs-zoom-select = - .title = ზომა -pdfjs-presentation-mode-button = - .title = ჩვენების რეჟიმზე გადართვა -pdfjs-presentation-mode-button-label = ჩვენების რეჟიმი -pdfjs-open-file-button = - .title = ფაილის გახსნა -pdfjs-open-file-button-label = გახსნა -pdfjs-print-button = - .title = ამობეჭდვა -pdfjs-print-button-label = ამობეჭდვა -pdfjs-save-button = - .title = შენახვა -pdfjs-save-button-label = შენახვა -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = ჩამოტვირთვა -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = ჩამოტვირთვა -pdfjs-bookmark-button = - .title = მიმდინარე გვერდი (ბმული ამ გვერდისთვის) -pdfjs-bookmark-button-label = მიმდინარე გვერდი -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = გახსნა პროგრამით -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = გახსნა პროგრამით - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ხელსაწყოები -pdfjs-tools-button-label = ხელსაწყოები -pdfjs-first-page-button = - .title = პირველ გვერდზე გადასვლა -pdfjs-first-page-button-label = პირველ გვერდზე გადასვლა -pdfjs-last-page-button = - .title = ბოლო გვერდზე გადასვლა -pdfjs-last-page-button-label = ბოლო გვერდზე გადასვლა -pdfjs-page-rotate-cw-button = - .title = საათის ისრის მიმართულებით შებრუნება -pdfjs-page-rotate-cw-button-label = მარჯვნივ გადაბრუნება -pdfjs-page-rotate-ccw-button = - .title = საათის ისრის საპირისპიროდ შებრუნება -pdfjs-page-rotate-ccw-button-label = მარცხნივ გადაბრუნება -pdfjs-cursor-text-select-tool-button = - .title = მოსანიშნი მაჩვენებლის გამოყენება -pdfjs-cursor-text-select-tool-button-label = მოსანიშნი მაჩვენებელი -pdfjs-cursor-hand-tool-button = - .title = გადასაადგილებელი მაჩვენებლის გამოყენება -pdfjs-cursor-hand-tool-button-label = გადასაადგილებელი -pdfjs-scroll-page-button = - .title = გვერდზე გადაადგილების გამოყენება -pdfjs-scroll-page-button-label = გვერდშივე გადაადგილება -pdfjs-scroll-vertical-button = - .title = გვერდების შვეულად ჩვენება -pdfjs-scroll-vertical-button-label = შვეული გადაადგილება -pdfjs-scroll-horizontal-button = - .title = გვერდების თარაზულად ჩვენება -pdfjs-scroll-horizontal-button-label = განივი გადაადგილება -pdfjs-scroll-wrapped-button = - .title = გვერდების ცხრილურად ჩვენება -pdfjs-scroll-wrapped-button-label = ცხრილური გადაადგილება -pdfjs-spread-none-button = - .title = ორ გვერდზე გაშლის გარეშე -pdfjs-spread-none-button-label = ცალგვერდიანი ჩვენება -pdfjs-spread-odd-button = - .title = ორ გვერდზე გაშლა კენტი გვერდიდან -pdfjs-spread-odd-button-label = ორ გვერდზე კენტიდან -pdfjs-spread-even-button = - .title = ორ გვერდზე გაშლა ლუწი გვერდიდან -pdfjs-spread-even-button-label = ორ გვერდზე ლუწიდან - -## Document properties dialog - -pdfjs-document-properties-button = - .title = დოკუმენტის შესახებ… -pdfjs-document-properties-button-label = დოკუმენტის შესახებ… -pdfjs-document-properties-file-name = ფაილის სახელი: -pdfjs-document-properties-file-size = ფაილის მოცულობა: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } კბ ({ $size_b } ბაიტი) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } მბ ({ $size_b } ბაიტი) -pdfjs-document-properties-title = სათაური: -pdfjs-document-properties-author = შემქმნელი: -pdfjs-document-properties-subject = თემა: -pdfjs-document-properties-keywords = საკვანძო სიტყვები: -pdfjs-document-properties-creation-date = შექმნის დრო: -pdfjs-document-properties-modification-date = ჩასწორების დრო: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = შემდგენელი: -pdfjs-document-properties-producer = PDF-შემდგენელი: -pdfjs-document-properties-version = PDF-ვერსია: -pdfjs-document-properties-page-count = გვერდები: -pdfjs-document-properties-page-size = გვერდის ზომა: -pdfjs-document-properties-page-size-unit-inches = დუიმი -pdfjs-document-properties-page-size-unit-millimeters = მმ -pdfjs-document-properties-page-size-orientation-portrait = შვეულად -pdfjs-document-properties-page-size-orientation-landscape = თარაზულად -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = მსუბუქი ვებჩვენება: -pdfjs-document-properties-linearized-yes = დიახ -pdfjs-document-properties-linearized-no = არა -pdfjs-document-properties-close-button = დახურვა - -## Print - -pdfjs-print-progress-message = დოკუმენტი მზადდება ამოსაბეჭდად… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = გაუქმება -pdfjs-printing-not-supported = გაფრთხილება: ამობეჭდვა ამ ბრაუზერში არაა სრულად მხარდაჭერილი. -pdfjs-printing-not-ready = გაფრთხილება: PDF სრულად ჩატვირთული არაა, ამობეჭდვის დასაწყებად. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = გვერდითა ზოლის გამოჩენა/დამალვა -pdfjs-toggle-sidebar-notification-button = - .title = გვერდითი ზოლის გამოჩენა (შეიცავს სარჩევს/დანართს/ფენებს) -pdfjs-toggle-sidebar-button-label = გვერდითა ზოლის გამოჩენა/დამალვა -pdfjs-document-outline-button = - .title = დოკუმენტის სარჩევის ჩვენება (ორმაგი წკაპით თითოეულის ჩამოშლა/აკეცვა) -pdfjs-document-outline-button-label = დოკუმენტის სარჩევი -pdfjs-attachments-button = - .title = დანართების ჩვენება -pdfjs-attachments-button-label = დანართები -pdfjs-layers-button = - .title = ფენების გამოჩენა (ორმაგი წკაპით ყველა ფენის ნაგულისხმევზე დაბრუნება) -pdfjs-layers-button-label = ფენები -pdfjs-thumbs-button = - .title = შეთვალიერება -pdfjs-thumbs-button-label = ესკიზები -pdfjs-current-outline-item-button = - .title = მიმდინარე გვერდის მონახვა სარჩევში -pdfjs-current-outline-item-button-label = მიმდინარე გვერდი სარჩევში -pdfjs-findbar-button = - .title = პოვნა დოკუმენტში -pdfjs-findbar-button-label = ძიება -pdfjs-additional-layers = დამატებითი ფენები - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = გვერდი { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = გვერდის შეთვალიერება { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = ძიება - .placeholder = პოვნა დოკუმენტში… -pdfjs-find-previous-button = - .title = ფრაზის წინა კონტექსტის პოვნა -pdfjs-find-previous-button-label = წინა -pdfjs-find-next-button = - .title = ფრაზის შემდეგი კონტექსტის პოვნა -pdfjs-find-next-button-label = შემდეგი -pdfjs-find-highlight-checkbox = ყველაფრის მონიშვნა -pdfjs-find-match-case-checkbox-label = მთავრულით -pdfjs-find-match-diacritics-checkbox-label = ნიშნებით -pdfjs-find-entire-word-checkbox-label = მთლიანი სიტყვები -pdfjs-find-reached-top = მიღწეულია დოკუმენტის დასაწყისი, გრძელდება ბოლოდან -pdfjs-find-reached-bottom = მიღწეულია დოკუმენტის ბოლო, გრძელდება დასაწყისიდან -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] თანხვედრა { $current }, სულ { $total } - *[other] თანხვედრა { $current }, სულ { $total } - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] არანაკლებ { $limit } თანხვედრა - *[other] არანაკლებ { $limit } თანხვედრა - } -pdfjs-find-not-found = ფრაზა ვერ მოიძებნა - -## Predefined zoom values - -pdfjs-page-scale-width = გვერდის სიგანეზე -pdfjs-page-scale-fit = მთლიანი გვერდი -pdfjs-page-scale-auto = ავტომატური -pdfjs-page-scale-actual = საწყისი ზომა -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = გვერდი { $page } - -## Loading indicator messages - -pdfjs-loading-error = შეცდომა, PDF-ფაილის ჩატვირთვისას. -pdfjs-invalid-file-error = არამართებული ან დაზიანებული PDF-ფაილი. -pdfjs-missing-file-error = ნაკლული PDF-ფაილი. -pdfjs-unexpected-response-error = სერვერის მოულოდნელი პასუხი. -pdfjs-rendering-error = შეცდომა, გვერდის ჩვენებისას. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } შენიშვნა] - -## Password - -pdfjs-password-label = შეიყვანეთ პაროლი PDF-ფაილის გასახსნელად. -pdfjs-password-invalid = არასწორი პაროლი. გთხოვთ, სცადოთ ხელახლა. -pdfjs-password-ok-button = კარგი -pdfjs-password-cancel-button = გაუქმება -pdfjs-web-fonts-disabled = ვებშრიფტები გამორთულია: ჩაშენებული PDF-შრიფტების გამოყენება ვერ ხერხდება. - -## Editing - -pdfjs-editor-free-text-button = - .title = წარწერა -pdfjs-editor-free-text-button-label = ტექსტი -pdfjs-editor-ink-button = - .title = ხაზვა -pdfjs-editor-ink-button-label = ხაზვა -pdfjs-editor-stamp-button = - .title = სურათების დართვა ან ჩასწორება -pdfjs-editor-stamp-button-label = სურათების დართვა ან ჩასწორება -pdfjs-editor-remove-button = - .title = მოცილება -pdfjs-editor-highlight-button = - .title = მონიშვნა -pdfjs-editor-highlight-button-label = მონიშვნა - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = დახაზულის მოცილება -pdfjs-editor-remove-freetext-button = - .title = წარწერის მოცილება -pdfjs-editor-remove-stamp-button = - .title = სურათის მოცილება -pdfjs-editor-remove-highlight-button = - .title = მონიშვნის მოცილება - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = ფერი -pdfjs-editor-free-text-size-input = ზომა -pdfjs-editor-ink-color-input = ფერი -pdfjs-editor-ink-thickness-input = სისქე -pdfjs-editor-ink-opacity-input = გაუმჭვირვალობა -pdfjs-editor-stamp-add-image-button = - .title = სურათის დამატება -pdfjs-editor-stamp-add-image-button-label = სურათის დამატება -pdfjs-free-text = - .aria-label = ნაწერის ჩასწორება -pdfjs-free-text-default-content = აკრიფეთ… -pdfjs-ink = - .aria-label = დახაზულის შესწორება -pdfjs-ink-canvas = - .aria-label = მომხმარებლის შექმნილი სურათი - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = თანდართული წარწერა -pdfjs-editor-alt-text-edit-button-label = თანდართული წარწერის ჩასწორება -pdfjs-editor-alt-text-dialog-label = არჩევა -pdfjs-editor-alt-text-dialog-description = თანდართული (შემნაცვლებელი) წარწერა გამოსადეგია მათთვის, ვინც ვერ ხედავს სურათებს ან გამოისახება მაშინ, როცა სურათი ვერ ჩაიტვირთება. -pdfjs-editor-alt-text-add-description-label = აღწერილობის მითითება -pdfjs-editor-alt-text-add-description-description = განკუთვნილია 1-2 წინადადებით საგნის, მახასიათებლის ან მოქმედების აღსაწერად. -pdfjs-editor-alt-text-mark-decorative-label = მოინიშნოს მორთულობად -pdfjs-editor-alt-text-mark-decorative-description = განკუთვნილია შესამკობი სურათებისთვის, გარსშემოსავლები ჩარჩოებისა და ჭვირნიშნებისთვის. -pdfjs-editor-alt-text-cancel-button = გაუქმება -pdfjs-editor-alt-text-save-button = შენახვა -pdfjs-editor-alt-text-decorative-tooltip = მოინიშნოს მორთულობად -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = მაგალითად, „ახალგაზრდა მამაკაცი მაგიდასთან ზის და სადილობს“ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = ზევით მარცხნივ — ზომაცვლა -pdfjs-editor-resizer-label-top-middle = ზევით შუაში — ზომაცვლა -pdfjs-editor-resizer-label-top-right = ზევით მარჯვნივ — ზომაცვლა -pdfjs-editor-resizer-label-middle-right = შუაში მარჯვნივ — ზომაცვლა -pdfjs-editor-resizer-label-bottom-right = ქვევით მარჯვნივ — ზომაცვლა -pdfjs-editor-resizer-label-bottom-middle = ქვევით შუაში — ზომაცვლა -pdfjs-editor-resizer-label-bottom-left = ზვევით მარცხნივ — ზომაცვლა -pdfjs-editor-resizer-label-middle-left = შუაში მარცხნივ — ზომაცვლა - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = მოსანიშნი ფერი -pdfjs-editor-colorpicker-button = - .title = ფერის შეცვლა -pdfjs-editor-colorpicker-dropdown = - .aria-label = ფერის არჩევა -pdfjs-editor-colorpicker-yellow = - .title = ყვითელი -pdfjs-editor-colorpicker-green = - .title = მწვანე -pdfjs-editor-colorpicker-blue = - .title = ლურჯი -pdfjs-editor-colorpicker-pink = - .title = ვარდისფერი -pdfjs-editor-colorpicker-red = - .title = წითელი diff --git a/static/pdf.js/locale/ka/viewer.properties b/static/pdf.js/locale/ka/viewer.properties new file mode 100644 index 00000000..84bdd525 --- /dev/null +++ b/static/pdf.js/locale/ka/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=წინა გვერდი +previous_label=წინა +next.title=შემდეგი გვერდი +next_label=შემდეგი + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=გვერდი: +page_of=/ {{pageCount}} + +zoom_out.title=დაშორება +zoom_out_label=დაშორება +zoom_in.title=მიახლოება +zoom_in_label=მიახლოება +zoom.title=მასშტაბი +presentation_mode.title=პრეზენტაციის რეჟიმზე გადართვა +presentation_mode_label=პრეზენტაციის რეჟიმი +open_file.title=ფაილის გახსნა +open_file_label=გახსნა +print.title=დაბეჭდვა +print_label=დაბეჭდვა +download.title=ჩამოტვირთვა +download_label=ჩამოტვირთვა +bookmark.title=მიმდინარე ხედი (კოპირება ან გახსნა ახალ ფანჯარაში) +bookmark_label=მიმდინარე ხედი + +# Secondary toolbar and context menu +tools.title=ხელსაწყოები +tools_label=ხელსაწყოები +first_page.title=პირველ გვერდზე გადასვლა +first_page.label=პირველ გვერდზე გადასვლა +first_page_label=პირველ გვერდზე გადასვლა +last_page.title=ბოლო გვერდზე გადასვლა +last_page.label=ბოლო გვერდზე გადასვლა +last_page_label=ბოლო გვერდზე გადასვლა +page_rotate_cw.title=ისრის მიმართულებით შებრუნება +page_rotate_cw.label=ისრის მიმართულებით შებრუნება +page_rotate_cw_label=ისრის მიმართულებით შებრუნება +page_rotate_ccw.title=ისრის საპირისპიროდ შებრუნება +page_rotate_ccw.label=ისრის საპირისპიროდ შებრუნება +page_rotate_ccw_label=ისრის საპირისპიროდ შებრუნება + +hand_tool_enable.title=ხელის ხელსაწყოს ჩართვა +hand_tool_enable_label=ხელის ხელსაწყოს ჩართვა +hand_tool_disable.title=ხელის ხელსაწყოს გამორთვა +hand_tool_disable_label=ხელის ხელსაწყოს გამორთვა + +# Document properties dialog box +document_properties.title=დოკუმენტის თვისებები… +document_properties_label=დოკუმენტის თვისებები… +document_properties_file_name=ფაილის სახელი: +document_properties_file_size=ფაილის ზომა: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} ბაიტი) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} ბაიტი) +document_properties_title=სათაური: +document_properties_author=ავტორი: +document_properties_subject=თემა: +document_properties_keywords=საკვანძო სიტყვები: +document_properties_creation_date=შექმნის თარიღი: +document_properties_modification_date=სახეცვალების თარიღი: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=შემქმნელი: +document_properties_producer=PDF მწარმოებელი: +document_properties_version=PDF ვერსია: +document_properties_page_count=გვერდების რაოდენობა: +document_properties_close=დახურვა + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=გვერდითა ზოლის ბერკეტი +toggle_sidebar_label=გვერდითა ზოლის ბერკეტი +outline.title=დოკუმენტის კონტურის ჩვენება +outline_label=დოკუმენტის კონტური +attachments.title=დანართების ჩვენება +attachments_label=დანართები +thumbs.title=ესკიზების ჩვენება +thumbs_label=ესკიზები +findbar.title=პოვნა დოკუმენტში +findbar_label=პოვნა + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=გვერდი {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=გვერდის ესკიზი {{page}} + +# Find panel button title and messages +find_label=პოვნა: +find_previous.title=ფრაზის წინა კონტექსტის პოვნა +find_previous_label=წინა +find_next.title=ფრაზის შემდეგი კონტექსტის პოვნა +find_next_label=შემდეგი +find_highlight=ყველას მონიშვნა +find_match_case_label=მთავრულის გათვალისწინება +find_reached_top=მიღწეულია დოკუმენტის უმაღლესი წერტილი, გრძელდება ქვემოდან +find_reached_bottom=მიღწეულია დოკუმენტის ბოლი, გრძელდება ზემოდან +find_not_found=კონტექსტი ვერ მოიძებნა + +# Error panel labels +error_more_info=დამატებითი ინფორმაცია +error_less_info=ნაკლები ინფორმაცია +error_close=დახურვა +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=შეტყობინება: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=სტეკი: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ფაილი: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=ხაზი: {{line}} +rendering_error=გვერდის რენდერისას დაფიქსირდა შეცდომა. + +# Predefined zoom values +page_scale_width=გვერდის სიგანე +page_scale_fit=გვერდის მორგება +page_scale_auto=ავტომატური მასშტაბი +page_scale_actual=აქტუალური ზომა +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=შეცდომა +loading_error=PDF-ის ჩატვირთვისას დაფიქსირდა შეცდომა. +invalid_file_error=არამართებული ან დაზიანებული PDF ფაილი. +missing_file_error=ნაკლული PDF ფაილი. +unexpected_response_error=სერვერის მოულოდნელი პასუხი. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} ანოტაცია] +password_label=შეიყვანეთ პაროლი, რათა გახსნათ ეს PDF ფაილი. +password_invalid=არასწორი პაროლი. გთხოვთ, სცადეთ ხელახლა. +password_ok=დიახ +password_cancel=გაუქმება + +printing_not_supported=გაფრთხილება: ამ ბრაუზერის მიერ დაბეჭდვა ბოლომდე მხარდაჭერილი არაა. +printing_not_ready=გაფრთხილება: PDF ამობეჭდვისთვის ბოლომდე ჩატვირთული არაა. +web_fonts_disabled=ვებ-შრიფტები გამორთულია: ჩაშენებული PDF შრიფტების გამოყენება ვერ ხერხდება. +document_colors_not_allowed=PDF დოკუმენტებს არ აქვთ საკუთარი ფერების გამოყენების უფლება: ბრაუზერში გამორთულია "გვერდებისთვის საკუთარი ფერების გამოყენების უფლება". diff --git a/static/pdf.js/locale/kab/viewer.ftl b/static/pdf.js/locale/kab/viewer.ftl deleted file mode 100644 index cfe0ba33..00000000 --- a/static/pdf.js/locale/kab/viewer.ftl +++ /dev/null @@ -1,386 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Asebter azewwar -pdfjs-previous-button-label = Azewwar -pdfjs-next-button = - .title = Asebter d-iteddun -pdfjs-next-button-label = Ddu ɣer zdat -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Asebter -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = ɣef { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } n { $pagesCount }) -pdfjs-zoom-out-button = - .title = Semẓi -pdfjs-zoom-out-button-label = Semẓi -pdfjs-zoom-in-button = - .title = Semɣeṛ -pdfjs-zoom-in-button-label = Semɣeṛ -pdfjs-zoom-select = - .title = Semɣeṛ/Semẓi -pdfjs-presentation-mode-button = - .title = Uɣal ɣer Uskar Tihawt -pdfjs-presentation-mode-button-label = Askar Tihawt -pdfjs-open-file-button = - .title = Ldi Afaylu -pdfjs-open-file-button-label = Ldi -pdfjs-print-button = - .title = Siggez -pdfjs-print-button-label = Siggez -pdfjs-save-button = - .title = Sekles -pdfjs-save-button-label = Sekles -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Sader -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Sader -pdfjs-bookmark-button = - .title = Asebter amiran (Sken-d tansa URL seg usebter amiran) -pdfjs-bookmark-button-label = Asebter amiran - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Ifecka -pdfjs-tools-button-label = Ifecka -pdfjs-first-page-button = - .title = Ddu ɣer usebter amezwaru -pdfjs-first-page-button-label = Ddu ɣer usebter amezwaru -pdfjs-last-page-button = - .title = Ddu ɣer usebter aneggaru -pdfjs-last-page-button-label = Ddu ɣer usebter aneggaru -pdfjs-page-rotate-cw-button = - .title = Tuzzya tusrigt -pdfjs-page-rotate-cw-button-label = Tuzzya tusrigt -pdfjs-page-rotate-ccw-button = - .title = Tuzzya amgal-usrig -pdfjs-page-rotate-ccw-button-label = Tuzzya amgal-usrig -pdfjs-cursor-text-select-tool-button = - .title = Rmed afecku n tefrant n uḍris -pdfjs-cursor-text-select-tool-button-label = Afecku n tefrant n uḍris -pdfjs-cursor-hand-tool-button = - .title = Rmed afecku afus -pdfjs-cursor-hand-tool-button-label = Afecku afus -pdfjs-scroll-page-button = - .title = Seqdec adrurem n usebter -pdfjs-scroll-page-button-label = Adrurem n usebter -pdfjs-scroll-vertical-button = - .title = Seqdec adrurem ubdid -pdfjs-scroll-vertical-button-label = Adrurem ubdid -pdfjs-scroll-horizontal-button = - .title = Seqdec adrurem aglawan -pdfjs-scroll-horizontal-button-label = Adrurem aglawan -pdfjs-scroll-wrapped-button = - .title = Seqdec adrurem yuẓen -pdfjs-scroll-wrapped-button-label = Adrurem yuẓen -pdfjs-spread-none-button = - .title = Ur sedday ara isiɣzaf n usebter -pdfjs-spread-none-button-label = Ulac isiɣzaf -pdfjs-spread-odd-button = - .title = Seddu isiɣzaf n usebter ibeddun s yisebtar irayuganen -pdfjs-spread-odd-button-label = Isiɣzaf irayuganen -pdfjs-spread-even-button = - .title = Seddu isiɣzaf n usebter ibeddun s yisebtar iyuganen -pdfjs-spread-even-button-label = Isiɣzaf iyuganen - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Taɣaṛa n isemli… -pdfjs-document-properties-button-label = Taɣaṛa n isemli… -pdfjs-document-properties-file-name = Isem n ufaylu: -pdfjs-document-properties-file-size = Teɣzi n ufaylu: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KAṬ ({ $size_b } ibiten) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MAṬ ({ $size_b } iṭamḍanen) -pdfjs-document-properties-title = Azwel: -pdfjs-document-properties-author = Ameskar: -pdfjs-document-properties-subject = Amgay: -pdfjs-document-properties-keywords = Awalen n tsaruţ -pdfjs-document-properties-creation-date = Azemz n tmerna: -pdfjs-document-properties-modification-date = Azemz n usnifel: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Yerna-t: -pdfjs-document-properties-producer = Afecku n uselket PDF: -pdfjs-document-properties-version = Lqem PDF: -pdfjs-document-properties-page-count = Amḍan n yisebtar: -pdfjs-document-properties-page-size = Tuγzi n usebter: -pdfjs-document-properties-page-size-unit-inches = deg -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = s teɣzi -pdfjs-document-properties-page-size-orientation-landscape = s tehri -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Asekkil -pdfjs-document-properties-page-size-name-legal = Usḍif - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Taskant Web taruradt: -pdfjs-document-properties-linearized-yes = Ih -pdfjs-document-properties-linearized-no = Ala -pdfjs-document-properties-close-button = Mdel - -## Print - -pdfjs-print-progress-message = Aheggi i usiggez n isemli… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Sefsex -pdfjs-printing-not-supported = Ɣuṛ-k: Asiggez ur ittusefrak ara yakan imaṛṛa deg iminig-a. -pdfjs-printing-not-ready = Ɣuṛ-k: Afaylu PDF ur d-yuli ara imeṛṛa akken ad ittusiggez. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Sken/Fer agalis adisan -pdfjs-toggle-sidebar-notification-button = - .title = Ffer/Sekn agalis adisan (isemli yegber aɣawas/ticeqqufin yeddan/tissiwin) -pdfjs-toggle-sidebar-button-label = Sken/Fer agalis adisan -pdfjs-document-outline-button = - .title = Sken isemli (Senned snat tikal i wesemɣer/Afneẓ n iferdisen meṛṛa) -pdfjs-document-outline-button-label = Isɣalen n isebtar -pdfjs-attachments-button = - .title = Sken ticeqqufin yeddan -pdfjs-attachments-button-label = Ticeqqufin yeddan -pdfjs-layers-button = - .title = Skeen tissiwin (sit sin yiberdan i uwennez n meṛṛa tissiwin ɣer waddad amezwer) -pdfjs-layers-button-label = Tissiwin -pdfjs-thumbs-button = - .title = Sken tanfult. -pdfjs-thumbs-button-label = Tinfulin -pdfjs-current-outline-item-button = - .title = Af-d aferdis n uɣawas amiran -pdfjs-current-outline-item-button-label = Aferdis n uɣawas amiran -pdfjs-findbar-button = - .title = Nadi deg isemli -pdfjs-findbar-button-label = Nadi -pdfjs-additional-layers = Tissiwin-nniḍen - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Asebter { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Tanfult n usebter { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Nadi - .placeholder = Nadi deg isemli… -pdfjs-find-previous-button = - .title = Aff-d tamseḍriwt n twinest n deffir -pdfjs-find-previous-button-label = Azewwar -pdfjs-find-next-button = - .title = Aff-d timseḍriwt n twinest d-iteddun -pdfjs-find-next-button-label = Ddu ɣer zdat -pdfjs-find-highlight-checkbox = Err izirig imaṛṛa -pdfjs-find-match-case-checkbox-label = Qadeṛ amasal n isekkilen -pdfjs-find-match-diacritics-checkbox-label = Qadeṛ ifeskilen -pdfjs-find-entire-word-checkbox-label = Awalen iččuranen -pdfjs-find-reached-top = Yabbeḍ s afella n usebter, tuɣalin s wadda -pdfjs-find-reached-bottom = Tebḍeḍ s adda n usebter, tuɣalin s afella -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] Timeḍriwt { $current } ɣef { $total } - *[other] Timeḍriwin { $current } ɣef { $total } - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Ugar n { $limit } umṣada - *[other] Ugar n { $limit } yimṣadayen - } -pdfjs-find-not-found = Ulac tawinest - -## Predefined zoom values - -pdfjs-page-scale-width = Tehri n usebter -pdfjs-page-scale-fit = Asebter imaṛṛa -pdfjs-page-scale-auto = Asemɣeṛ/Asemẓi awurman -pdfjs-page-scale-actual = Teɣzi tilawt -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Asebter { $page } - -## Loading indicator messages - -pdfjs-loading-error = Teḍra-d tuccḍa deg alluy n PDF: -pdfjs-invalid-file-error = Afaylu PDF arameɣtu neɣ yexṣeṛ. -pdfjs-missing-file-error = Ulac afaylu PDF. -pdfjs-unexpected-response-error = Aqeddac yerra-d yir tiririt ur nettwaṛǧi ara. -pdfjs-rendering-error = Teḍra-d tuccḍa deg uskan n usebter. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Tabzimt { $type }] - -## Password - -pdfjs-password-label = Sekcem awal uffir akken ad ldiḍ afaylu-yagi PDF -pdfjs-password-invalid = Awal uffir mačči d ameɣtu, Ɛreḍ tikelt-nniḍen. -pdfjs-password-ok-button = IH -pdfjs-password-cancel-button = Sefsex -pdfjs-web-fonts-disabled = Tisefsiyin web ttwassensent; D awezɣi useqdec n tsefsiyin yettwarnan ɣer PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Aḍris -pdfjs-editor-free-text-button-label = Aḍris -pdfjs-editor-ink-button = - .title = Suneɣ -pdfjs-editor-ink-button-label = Suneɣ -pdfjs-editor-stamp-button = - .title = Rnu neɣ ẓreg tugniwin -pdfjs-editor-stamp-button-label = Rnu neɣ ẓreg tugniwin -pdfjs-editor-highlight-button = - .title = Derrer -pdfjs-editor-highlight-button-label = Derrer -pdfjs-highlight-floating-button1 = - .title = Derrer - .aria-label = Derrer -pdfjs-highlight-floating-button-label = Derrer - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Kkes asuneɣ -pdfjs-editor-remove-freetext-button = - .title = Kkes aḍris -pdfjs-editor-remove-stamp-button = - .title = Kkes tugna -pdfjs-editor-remove-highlight-button = - .title = Kkes aderrer - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Initen -pdfjs-editor-free-text-size-input = Teɣzi -pdfjs-editor-ink-color-input = Ini -pdfjs-editor-ink-thickness-input = Tuzert -pdfjs-editor-ink-opacity-input = Tebrek -pdfjs-editor-stamp-add-image-button = - .title = Rnu tawlaft -pdfjs-editor-stamp-add-image-button-label = Rnu tawlaft -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tuzert -pdfjs-free-text = - .aria-label = Amaẓrag n uḍris -pdfjs-free-text-default-content = Bdu tira... -pdfjs-ink = - .aria-label = Amaẓrag n usuneɣ -pdfjs-ink-canvas = - .aria-label = Tugna yettwarnan sɣur useqdac - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Aḍris amaskal -pdfjs-editor-alt-text-edit-button-label = Ẓreg aḍris amaskal -pdfjs-editor-alt-text-dialog-label = Fren taxtirt -pdfjs-editor-alt-text-add-description-label = Rnu aglam -pdfjs-editor-alt-text-mark-decorative-label = Creḍ d adlag -pdfjs-editor-alt-text-cancel-button = Sefsex -pdfjs-editor-alt-text-save-button = Sekles -pdfjs-editor-alt-text-decorative-tooltip = Yettwacreḍ d adlag - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Tiɣmert n ufella n zelmeḍ — semsawi teɣzi -pdfjs-editor-resizer-label-top-middle = Talemmat n ufella — semsawi teɣzi -pdfjs-editor-resizer-label-top-right = Tiɣmert n ufella n yeffus — semsawi teɣzi -pdfjs-editor-resizer-label-middle-right = Talemmast tayeffust — semsawi teɣzi -pdfjs-editor-resizer-label-bottom-right = Tiɣmert n wadda n yeffus — semsawi teɣzi -pdfjs-editor-resizer-label-bottom-middle = Talemmat n wadda — semsawi teɣzi -pdfjs-editor-resizer-label-bottom-left = Tiɣmert n wadda n zelmeḍ — semsawi teɣzi -pdfjs-editor-resizer-label-middle-left = Talemmast tazelmdaḍt — semsawi teɣzi - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Ini n uderrer -pdfjs-editor-colorpicker-button = - .title = Senfel ini -pdfjs-editor-colorpicker-dropdown = - .aria-label = Afran n yiniten -pdfjs-editor-colorpicker-yellow = - .title = Awraɣ -pdfjs-editor-colorpicker-green = - .title = Azegzaw -pdfjs-editor-colorpicker-blue = - .title = Amidadi -pdfjs-editor-colorpicker-pink = - .title = Axuxi -pdfjs-editor-colorpicker-red = - .title = Azggaɣ - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Sken akk -pdfjs-editor-highlight-show-all-button = - .title = Sken akk diff --git a/static/pdf.js/locale/kk/viewer.ftl b/static/pdf.js/locale/kk/viewer.ftl deleted file mode 100644 index 57260a2d..00000000 --- a/static/pdf.js/locale/kk/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Алдыңғы парақ -pdfjs-previous-button-label = Алдыңғысы -pdfjs-next-button = - .title = Келесі парақ -pdfjs-next-button-label = Келесі -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Парақ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } ішінен -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = (парақ { $pageNumber }, { $pagesCount } ішінен) -pdfjs-zoom-out-button = - .title = Кішірейту -pdfjs-zoom-out-button-label = Кішірейту -pdfjs-zoom-in-button = - .title = Үлкейту -pdfjs-zoom-in-button-label = Үлкейту -pdfjs-zoom-select = - .title = Масштаб -pdfjs-presentation-mode-button = - .title = Презентация режиміне ауысу -pdfjs-presentation-mode-button-label = Презентация режимі -pdfjs-open-file-button = - .title = Файлды ашу -pdfjs-open-file-button-label = Ашу -pdfjs-print-button = - .title = Баспаға шығару -pdfjs-print-button-label = Баспаға шығару -pdfjs-save-button = - .title = Сақтау -pdfjs-save-button-label = Сақтау -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Жүктеп алу -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Жүктеп алу -pdfjs-bookmark-button = - .title = Ағымдағы бет (Ағымдағы беттен URL адресін көру) -pdfjs-bookmark-button-label = Ағымдағы бет -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Қолданбада ашу -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Қолданбада ашу - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Құралдар -pdfjs-tools-button-label = Құралдар -pdfjs-first-page-button = - .title = Алғашқы параққа өту -pdfjs-first-page-button-label = Алғашқы параққа өту -pdfjs-last-page-button = - .title = Соңғы параққа өту -pdfjs-last-page-button-label = Соңғы параққа өту -pdfjs-page-rotate-cw-button = - .title = Сағат тілі бағытымен айналдыру -pdfjs-page-rotate-cw-button-label = Сағат тілі бағытымен бұру -pdfjs-page-rotate-ccw-button = - .title = Сағат тілі бағытына қарсы бұру -pdfjs-page-rotate-ccw-button-label = Сағат тілі бағытына қарсы бұру -pdfjs-cursor-text-select-tool-button = - .title = Мәтінді таңдау құралын іске қосу -pdfjs-cursor-text-select-tool-button-label = Мәтінді таңдау құралы -pdfjs-cursor-hand-tool-button = - .title = Қол құралын іске қосу -pdfjs-cursor-hand-tool-button-label = Қол құралы -pdfjs-scroll-page-button = - .title = Беттерді айналдыруды пайдалану -pdfjs-scroll-page-button-label = Беттерді айналдыру -pdfjs-scroll-vertical-button = - .title = Вертикалды айналдыруды қолдану -pdfjs-scroll-vertical-button-label = Вертикалды айналдыру -pdfjs-scroll-horizontal-button = - .title = Горизонталды айналдыруды қолдану -pdfjs-scroll-horizontal-button-label = Горизонталды айналдыру -pdfjs-scroll-wrapped-button = - .title = Масштабталатын айналдыруды қолдану -pdfjs-scroll-wrapped-button-label = Масштабталатын айналдыру -pdfjs-spread-none-button = - .title = Жазық беттер режимін қолданбау -pdfjs-spread-none-button-label = Жазық беттер режимсіз -pdfjs-spread-odd-button = - .title = Жазық беттер тақ нөмірлі беттерден басталады -pdfjs-spread-odd-button-label = Тақ нөмірлі беттер сол жақтан -pdfjs-spread-even-button = - .title = Жазық беттер жұп нөмірлі беттерден басталады -pdfjs-spread-even-button-label = Жұп нөмірлі беттер сол жақтан - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Құжат қасиеттері… -pdfjs-document-properties-button-label = Құжат қасиеттері… -pdfjs-document-properties-file-name = Файл аты: -pdfjs-document-properties-file-size = Файл өлшемі: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } КБ ({ $size_b } байт) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } МБ ({ $size_b } байт) -pdfjs-document-properties-title = Тақырыбы: -pdfjs-document-properties-author = Авторы: -pdfjs-document-properties-subject = Тақырыбы: -pdfjs-document-properties-keywords = Кілт сөздер: -pdfjs-document-properties-creation-date = Жасалған күні: -pdfjs-document-properties-modification-date = Түзету күні: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Жасаған: -pdfjs-document-properties-producer = PDF өндірген: -pdfjs-document-properties-version = PDF нұсқасы: -pdfjs-document-properties-page-count = Беттер саны: -pdfjs-document-properties-page-size = Бет өлшемі: -pdfjs-document-properties-page-size-unit-inches = дюйм -pdfjs-document-properties-page-size-unit-millimeters = мм -pdfjs-document-properties-page-size-orientation-portrait = тік -pdfjs-document-properties-page-size-orientation-landscape = жатық -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Жылдам Web көрінісі: -pdfjs-document-properties-linearized-yes = Иә -pdfjs-document-properties-linearized-no = Жоқ -pdfjs-document-properties-close-button = Жабу - -## Print - -pdfjs-print-progress-message = Құжатты баспаға шығару үшін дайындау… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Бас тарту -pdfjs-printing-not-supported = Ескерту: Баспаға шығаруды бұл браузер толығымен қолдамайды. -pdfjs-printing-not-ready = Ескерту: Баспаға шығару үшін, бұл PDF толығымен жүктеліп алынбады. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Бүйір панелін көрсету/жасыру -pdfjs-toggle-sidebar-notification-button = - .title = Бүйір панелін көрсету/жасыру (құжатта құрылымы/салынымдар/қабаттар бар) -pdfjs-toggle-sidebar-button-label = Бүйір панелін көрсету/жасыру -pdfjs-document-outline-button = - .title = Құжат құрылымын көрсету (барлық нәрселерді жазық қылу/жинау үшін қос шерту керек) -pdfjs-document-outline-button-label = Құжат құрамасы -pdfjs-attachments-button = - .title = Салынымдарды көрсету -pdfjs-attachments-button-label = Салынымдар -pdfjs-layers-button = - .title = Қабаттарды көрсету (барлық қабаттарды бастапқы күйге келтіру үшін екі рет шертіңіз) -pdfjs-layers-button-label = Қабаттар -pdfjs-thumbs-button = - .title = Кіші көріністерді көрсету -pdfjs-thumbs-button-label = Кіші көріністер -pdfjs-current-outline-item-button = - .title = Құрылымның ағымдағы элементін табу -pdfjs-current-outline-item-button-label = Құрылымның ағымдағы элементі -pdfjs-findbar-button = - .title = Құжаттан табу -pdfjs-findbar-button-label = Табу -pdfjs-additional-layers = Қосымша қабаттар - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page } парағы -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } парағы үшін кіші көрінісі - -## Find panel button title and messages - -pdfjs-find-input = - .title = Табу - .placeholder = Құжаттан табу… -pdfjs-find-previous-button = - .title = Осы сөздердің мәтіннен алдыңғы кездесуін табу -pdfjs-find-previous-button-label = Алдыңғысы -pdfjs-find-next-button = - .title = Осы сөздердің мәтіннен келесі кездесуін табу -pdfjs-find-next-button-label = Келесі -pdfjs-find-highlight-checkbox = Барлығын түспен ерекшелеу -pdfjs-find-match-case-checkbox-label = Регистрді ескеру -pdfjs-find-match-diacritics-checkbox-label = Диакритиканы ескеру -pdfjs-find-entire-word-checkbox-label = Сөздер толығымен -pdfjs-find-reached-top = Құжаттың басына жеттік, соңынан бастап жалғастырамыз -pdfjs-find-reached-bottom = Құжаттың соңына жеттік, басынан бастап жалғастырамыз -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } сәйкестік, барлығы { $total } - *[other] { $current } сәйкестік, барлығы { $total } - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] { $limit } сәйкестіктен көп - *[other] { $limit } сәйкестіктен көп - } -pdfjs-find-not-found = Сөз(дер) табылмады - -## Predefined zoom values - -pdfjs-page-scale-width = Парақ ені -pdfjs-page-scale-fit = Парақты сыйдыру -pdfjs-page-scale-auto = Автомасштабтау -pdfjs-page-scale-actual = Нақты өлшемі -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Бет { $page } - -## Loading indicator messages - -pdfjs-loading-error = PDF жүктеу кезінде қате кетті. -pdfjs-invalid-file-error = Зақымдалған немесе қате PDF файл. -pdfjs-missing-file-error = PDF файлы жоқ. -pdfjs-unexpected-response-error = Сервердің күтпеген жауабы. -pdfjs-rendering-error = Парақты өңдеу кезінде қате кетті. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } аңдатпасы] - -## Password - -pdfjs-password-label = Бұл PDF файлын ашу үшін парольді енгізіңіз. -pdfjs-password-invalid = Пароль дұрыс емес. Қайталап көріңіз. -pdfjs-password-ok-button = ОК -pdfjs-password-cancel-button = Бас тарту -pdfjs-web-fonts-disabled = Веб қаріптері сөндірілген: құрамына енгізілген PDF қаріптерін қолдану мүмкін емес. - -## Editing - -pdfjs-editor-free-text-button = - .title = Мәтін -pdfjs-editor-free-text-button-label = Мәтін -pdfjs-editor-ink-button = - .title = Сурет салу -pdfjs-editor-ink-button-label = Сурет салу -pdfjs-editor-stamp-button = - .title = Суреттерді қосу немесе түзету -pdfjs-editor-stamp-button-label = Суреттерді қосу немесе түзету -pdfjs-editor-highlight-button = - .title = Ерекшелеу -pdfjs-editor-highlight-button-label = Ерекшелеу -pdfjs-highlight-floating-button = - .title = Ерекшелеу -pdfjs-highlight-floating-button1 = - .title = Ерекшелеу - .aria-label = Ерекшелеу -pdfjs-highlight-floating-button-label = Ерекшелеу - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Сызбаны өшіру -pdfjs-editor-remove-freetext-button = - .title = Мәтінді өшіру -pdfjs-editor-remove-stamp-button = - .title = Суретті өшіру -pdfjs-editor-remove-highlight-button = - .title = Түспен ерекшелеуді өшіру - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Түс -pdfjs-editor-free-text-size-input = Өлшемі -pdfjs-editor-ink-color-input = Түс -pdfjs-editor-ink-thickness-input = Қалыңдығы -pdfjs-editor-ink-opacity-input = Мөлдірсіздігі -pdfjs-editor-stamp-add-image-button = - .title = Суретті қосу -pdfjs-editor-stamp-add-image-button-label = Суретті қосу -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Қалыңдығы -pdfjs-editor-free-highlight-thickness-title = - .title = Мәтіннен басқа элементтерді ерекшелеу кезінде қалыңдықты өзгерту -pdfjs-free-text = - .aria-label = Мәтін түзеткіші -pdfjs-free-text-default-content = Теруді бастау… -pdfjs-ink = - .aria-label = Сурет түзеткіші -pdfjs-ink-canvas = - .aria-label = Пайдаланушы жасаған сурет - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Балама мәтін -pdfjs-editor-alt-text-edit-button-label = Балама мәтінді өңдеу -pdfjs-editor-alt-text-dialog-label = Опцияны таңдау -pdfjs-editor-alt-text-dialog-description = Балама мәтін адамдар суретті көре алмағанда немесе ол жүктелмегенде көмектеседі. -pdfjs-editor-alt-text-add-description-label = Сипаттаманы қосу -pdfjs-editor-alt-text-add-description-description = Тақырыпты, баптауды немесе әрекетті сипаттайтын 1-2 сөйлемді қолдануға тырысыңыз. -pdfjs-editor-alt-text-mark-decorative-label = Декоративті деп белгілеу -pdfjs-editor-alt-text-mark-decorative-description = Бұл жиектер немесе су белгілері сияқты оюлық суреттер үшін пайдаланылады. -pdfjs-editor-alt-text-cancel-button = Бас тарту -pdfjs-editor-alt-text-save-button = Сақтау -pdfjs-editor-alt-text-decorative-tooltip = Декоративті деп белгіленген -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Мысалы, "Жас жігіт тамақ ішу үшін үстел басына отырады" - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Жоғарғы сол жақ бұрыш — өлшемін өзгерту -pdfjs-editor-resizer-label-top-middle = Жоғарғы ортасы — өлшемін өзгерту -pdfjs-editor-resizer-label-top-right = Жоғарғы оң жақ бұрыш — өлшемін өзгерту -pdfjs-editor-resizer-label-middle-right = Ортаңғы оң жақ — өлшемін өзгерту -pdfjs-editor-resizer-label-bottom-right = Төменгі оң жақ бұрыш — өлшемін өзгерту -pdfjs-editor-resizer-label-bottom-middle = Төменгі ортасы — өлшемін өзгерту -pdfjs-editor-resizer-label-bottom-left = Төменгі сол жақ бұрыш — өлшемін өзгерту -pdfjs-editor-resizer-label-middle-left = Ортаңғы сол жақ — өлшемін өзгерту - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Ерекшелеу түсі -pdfjs-editor-colorpicker-button = - .title = Түсті өзгерту -pdfjs-editor-colorpicker-dropdown = - .aria-label = Түс таңдаулары -pdfjs-editor-colorpicker-yellow = - .title = Сары -pdfjs-editor-colorpicker-green = - .title = Жасыл -pdfjs-editor-colorpicker-blue = - .title = Көк -pdfjs-editor-colorpicker-pink = - .title = Қызғылт -pdfjs-editor-colorpicker-red = - .title = Қызыл - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Барлығын көрсету -pdfjs-editor-highlight-show-all-button = - .title = Барлығын көрсету diff --git a/static/pdf.js/locale/kk/viewer.properties b/static/pdf.js/locale/kk/viewer.properties new file mode 100644 index 00000000..39e7118b --- /dev/null +++ b/static/pdf.js/locale/kk/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Алдыңғы парақ +previous_label=Алдыңғысы +next.title=Келесі парақ +next_label=Келесі + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Парақ: +page_of={{pageCount}} ішінен + +zoom_out.title=Кішірейту +zoom_out_label=Кішірейту +zoom_in.title=Үлкейту +zoom_in_label=Үлкейту +zoom.title=Масштаб +presentation_mode.title=Презентация режиміне ауысу +presentation_mode_label=Презентация режимі +open_file.title=Файлды ашу +open_file_label=Ашу +print.title=Баспаға шығару +print_label=Баспаға шығару +download.title=Жүктеп алу +download_label=Жүктеп алу +bookmark.title=Ағымдағы көрініс (көшіру не жаңа терезеде ашу) +bookmark_label=Ағымдағы көрініс + +# Secondary toolbar and context menu +tools.title=Саймандар +tools_label=Саймандар +first_page.title=Алғашқы параққа өту +first_page.label=Алғашқы параққа өту +first_page_label=Алғашқы параққа өту +last_page.title=Соңғы параққа өту +last_page.label=Соңғы параққа өту +last_page_label=Соңғы параққа өту +page_rotate_cw.title=Сағат тілі бағытымен айналдыру +page_rotate_cw.label=Сағат тілі бағытымен бұру +page_rotate_cw_label=Сағат тілі бағытымен бұру +page_rotate_ccw.title=Сағат тілі бағытына қарсы бұру +page_rotate_ccw.label=Сағат тілі бағытына қарсы бұру +page_rotate_ccw_label=Сағат тілі бағытына қарсы бұру + +hand_tool_enable.title=Қол сайманын іске қосу +hand_tool_enable_label=Қол сайманын іске қосу +hand_tool_disable.title=Қол сайманын сөндіру +hand_tool_disable_label=Қол сайманын сөндіру + +# Document properties dialog box +document_properties.title=Құжат қасиеттері… +document_properties_label=Құжат қасиеттері… +document_properties_file_name=Файл аты: +document_properties_file_size=Файл өлшемі: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} КБ ({{size_b}} байт) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} МБ ({{size_b}} байт) +document_properties_title=Тақырыбы... +document_properties_author=Авторы: +document_properties_subject=Тақырыбы: +document_properties_keywords=Кілт сөздер: +document_properties_creation_date=Жасалған күні: +document_properties_modification_date=Түзету күні: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Жасаған: +document_properties_producer=PDF өндірген: +document_properties_version=PDF нұсқасы: +document_properties_page_count=Беттер саны: +document_properties_close=Жабу + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Бүйір панелін көрсету/жасыру +toggle_sidebar_label=Бүйір панелін көрсету/жасыру +outline.title=Құжат құрамасын көрсету +outline_label=Құжат құрамасы +attachments.title=Салынымдарды көрсету +attachments_label=Салынымдар +thumbs.title=Кіші көріністерді көрсету +thumbs_label=Кіші көріністер +findbar.title=Құжаттан табу +findbar_label=Табу + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title={{page}} парағы +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}} парағы үшін кіші көрінісі + +# Find panel button title and messages +find_label=Табу: +find_previous.title=Осы сөздердің мәтіннен алдыңғы кездесуін табу +find_previous_label=Алдыңғысы +find_next.title=Осы сөздердің мәтіннен келесі кездесуін табу +find_next_label=Келесі +find_highlight=Барлығын түспен ерекшелеу +find_match_case_label=Регистрді ескеру +find_reached_top=Құжаттың басына жеттік, соңынан бастап жалғастырамыз +find_reached_bottom=Құжаттың соңына жеттік, басынан бастап жалғастырамыз +find_not_found=Сөз(дер) табылмады + +# Error panel labels +error_more_info=Көбірек ақпарат +error_less_info=Азырақ ақпарат +error_close=Жабу +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (жинақ: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Хабарлама: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Стек: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Файл: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Жол: {{line}} +rendering_error=Парақты өңдеу кезінде қате кетті. + +# Predefined zoom values +page_scale_width=Парақ ені +page_scale_fit=Парақты сыйдыру +page_scale_auto=Автомасштабтау +page_scale_actual=Нақты өлшемі +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Қате +loading_error=PDF жүктеу кезінде қате кетті. +invalid_file_error=Зақымдалған немесе қате PDF файл. +missing_file_error=PDF файлы жоқ. +unexpected_response_error=Сервердің күтпеген жауабы. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} аңдатпасы] +password_label=Бұл PDF файлын ашу үшін парольді енгізіңіз. +password_invalid=Пароль дұрыс емес. Қайталап көріңіз. +password_ok=ОК +password_cancel=Бас тарту + +printing_not_supported=Ескерту: Баспаға шығаруды бұл браузер толығымен қолдамайды. +printing_not_ready=Ескерту: Баспаға шығару үшін, бұл PDF толығымен жүктеліп алынбады. +web_fonts_disabled=Веб қаріптері сөндірілген: құрамына енгізілген PDF қаріптерін қолдану мүмкін емес. +document_colors_not_allowed=PDF құжаттарына өздік түстерді қолдану рұқсат етілмеген: бұл браузерде 'Веб-сайттарға өздерінің түстерін қолдануға рұқсат беру' мүмкіндігі сөндірулі тұр. diff --git a/static/pdf.js/locale/km/viewer.ftl b/static/pdf.js/locale/km/viewer.ftl deleted file mode 100644 index 6efd1054..00000000 --- a/static/pdf.js/locale/km/viewer.ftl +++ /dev/null @@ -1,223 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = ទំព័រ​មុន -pdfjs-previous-button-label = មុន -pdfjs-next-button = - .title = ទំព័រ​បន្ទាប់ -pdfjs-next-button-label = បន្ទាប់ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = ទំព័រ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = នៃ { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } នៃ { $pagesCount }) -pdfjs-zoom-out-button = - .title = ​បង្រួម -pdfjs-zoom-out-button-label = ​បង្រួម -pdfjs-zoom-in-button = - .title = ​ពង្រីក -pdfjs-zoom-in-button-label = ​ពង្រីក -pdfjs-zoom-select = - .title = ពង្រីក -pdfjs-presentation-mode-button = - .title = ប្ដូរ​ទៅ​របៀប​បទ​បង្ហាញ -pdfjs-presentation-mode-button-label = របៀប​បទ​បង្ហាញ -pdfjs-open-file-button = - .title = បើក​ឯកសារ -pdfjs-open-file-button-label = បើក -pdfjs-print-button = - .title = បោះពុម្ព -pdfjs-print-button-label = បោះពុម្ព - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ឧបករណ៍ -pdfjs-tools-button-label = ឧបករណ៍ -pdfjs-first-page-button = - .title = ទៅកាន់​ទំព័រ​ដំបូង​ -pdfjs-first-page-button-label = ទៅកាន់​ទំព័រ​ដំបូង​ -pdfjs-last-page-button = - .title = ទៅកាន់​ទំព័រ​ចុងក្រោយ​ -pdfjs-last-page-button-label = ទៅកាន់​ទំព័រ​ចុងក្រោយ -pdfjs-page-rotate-cw-button = - .title = បង្វិល​ស្រប​ទ្រនិច​នាឡិកា -pdfjs-page-rotate-cw-button-label = បង្វិល​ស្រប​ទ្រនិច​នាឡិកា -pdfjs-page-rotate-ccw-button = - .title = បង្វិល​ច្រាស​ទ្រនិច​នាឡិកា​​ -pdfjs-page-rotate-ccw-button-label = បង្វិល​ច្រាស​ទ្រនិច​នាឡិកា​​ -pdfjs-cursor-text-select-tool-button = - .title = បើក​ឧបករណ៍​ជ្រើស​អត្ថបទ -pdfjs-cursor-text-select-tool-button-label = ឧបករណ៍​ជ្រើស​អត្ថបទ -pdfjs-cursor-hand-tool-button = - .title = បើក​ឧបករណ៍​ដៃ -pdfjs-cursor-hand-tool-button-label = ឧបករណ៍​ដៃ - -## Document properties dialog - -pdfjs-document-properties-button = - .title = លក្ខណ​សម្បត្តិ​ឯកសារ… -pdfjs-document-properties-button-label = លក្ខណ​សម្បត្តិ​ឯកសារ… -pdfjs-document-properties-file-name = ឈ្មោះ​ឯកសារ៖ -pdfjs-document-properties-file-size = ទំហំ​ឯកសារ៖ -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } បៃ) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } បៃ) -pdfjs-document-properties-title = ចំណងជើង៖ -pdfjs-document-properties-author = អ្នក​និពន្ធ៖ -pdfjs-document-properties-subject = ប្រធានបទ៖ -pdfjs-document-properties-keywords = ពាក្យ​គន្លឹះ៖ -pdfjs-document-properties-creation-date = កាលបរិច្ឆេទ​បង្កើត៖ -pdfjs-document-properties-modification-date = កាលបរិច្ឆេទ​កែប្រែ៖ -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = អ្នក​បង្កើត៖ -pdfjs-document-properties-producer = កម្មវិធី​បង្កើត PDF ៖ -pdfjs-document-properties-version = កំណែ PDF ៖ -pdfjs-document-properties-page-count = ចំនួន​ទំព័រ៖ -pdfjs-document-properties-page-size-unit-inches = អ៊ីញ -pdfjs-document-properties-page-size-unit-millimeters = មម -pdfjs-document-properties-page-size-orientation-portrait = បញ្ឈរ -pdfjs-document-properties-page-size-orientation-landscape = ផ្តេក -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = សំបុត្រ - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-linearized-yes = បាទ/ចាស -pdfjs-document-properties-linearized-no = ទេ -pdfjs-document-properties-close-button = បិទ - -## Print - -pdfjs-print-progress-message = កំពុង​រៀបចំ​ឯកសារ​សម្រាប់​បោះពុម្ព… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = បោះបង់ -pdfjs-printing-not-supported = ការ​ព្រមាន ៖ កា​រ​បោះពុម្ព​មិន​ត្រូវ​បាន​គាំទ្រ​ពេញលេញ​ដោយ​កម្មវិធី​រុករក​នេះ​ទេ ។ -pdfjs-printing-not-ready = ព្រមាន៖ PDF មិន​ត្រូវ​បាន​ផ្ទុក​ទាំងស្រុង​ដើម្បី​បោះពុម្ព​ទេ។ - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = បិទ/បើក​គ្រាប់​រំកិល -pdfjs-toggle-sidebar-button-label = បិទ/បើក​គ្រាប់​រំកិល -pdfjs-document-outline-button = - .title = បង្ហាញ​គ្រោង​ឯកសារ (ចុច​ទ្វេ​ដង​ដើម្បី​ពង្រីក/បង្រួម​ធាតុ​ទាំងអស់) -pdfjs-document-outline-button-label = គ្រោង​ឯកសារ -pdfjs-attachments-button = - .title = បង្ហាញ​ឯកសារ​ភ្ជាប់ -pdfjs-attachments-button-label = ឯកសារ​ភ្ជាប់ -pdfjs-thumbs-button = - .title = បង្ហាញ​រូបភាព​តូចៗ -pdfjs-thumbs-button-label = រួបភាព​តូចៗ -pdfjs-findbar-button = - .title = រក​នៅ​ក្នុង​ឯកសារ -pdfjs-findbar-button-label = រក - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = ទំព័រ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = រូបភាព​តូច​របស់​ទំព័រ { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = រក - .placeholder = រក​នៅ​ក្នុង​ឯកសារ... -pdfjs-find-previous-button = - .title = រក​ពាក្យ ឬ​ឃ្លា​ដែល​បាន​ជួប​មុន -pdfjs-find-previous-button-label = មុន -pdfjs-find-next-button = - .title = រក​ពាក្យ ឬ​ឃ្លា​ដែល​បាន​ជួប​បន្ទាប់ -pdfjs-find-next-button-label = បន្ទាប់ -pdfjs-find-highlight-checkbox = បន្លិច​ទាំងអស់ -pdfjs-find-match-case-checkbox-label = ករណី​ដំណូច -pdfjs-find-reached-top = បាន​បន្ត​ពី​ខាង​ក្រោម ទៅ​ដល់​ខាង​​លើ​នៃ​ឯកសារ -pdfjs-find-reached-bottom = បាន​បន្ត​ពី​ខាងលើ ទៅដល់​ចុង​​នៃ​ឯកសារ -pdfjs-find-not-found = រក​មិន​ឃើញ​ពាក្យ ឬ​ឃ្លា - -## Predefined zoom values - -pdfjs-page-scale-width = ទទឹង​ទំព័រ -pdfjs-page-scale-fit = សម​ទំព័រ -pdfjs-page-scale-auto = ពង្រីក​ស្វ័យប្រវត្តិ -pdfjs-page-scale-actual = ទំហំ​ជាក់ស្ដែង -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = មាន​កំហុស​បាន​កើតឡើង​ពេល​កំពុង​ផ្ទុក PDF ។ -pdfjs-invalid-file-error = ឯកសារ PDF ខូច ឬ​មិន​ត្រឹមត្រូវ ។ -pdfjs-missing-file-error = បាត់​ឯកសារ PDF -pdfjs-unexpected-response-error = ការ​ឆ្លើយ​តម​ម៉ាស៊ីន​មេ​ដែល​មិន​បាន​រំពឹង។ -pdfjs-rendering-error = មាន​កំហុស​បាន​កើតឡើង​ពេល​បង្ហាញ​ទំព័រ ។ - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } ចំណារ​ពន្យល់] - -## Password - -pdfjs-password-label = បញ្ចូល​ពាក្យសម្ងាត់​ដើម្បី​បើក​ឯកសារ PDF នេះ។ -pdfjs-password-invalid = ពាក្យសម្ងាត់​មិន​ត្រឹមត្រូវ។ សូម​ព្យាយាម​ម្ដងទៀត។ -pdfjs-password-ok-button = យល់​ព្រម -pdfjs-password-cancel-button = បោះបង់ -pdfjs-web-fonts-disabled = បាន​បិទ​ពុម្ពអក្សរ​បណ្ដាញ ៖ មិន​អាច​ប្រើ​ពុម្ពអក្សរ PDF ដែល​បាន​បង្កប់​បាន​ទេ ។ - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/km/viewer.properties b/static/pdf.js/locale/km/viewer.properties new file mode 100644 index 00000000..87f700e6 --- /dev/null +++ b/static/pdf.js/locale/km/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=ទំព័រ​មុន +previous_label=មុន +next.title=ទំព័រ​បន្ទាប់ +next_label=បន្ទាប់ + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=ទំព័រ ៖ +page_of=នៃ {{pageCount}} + +zoom_out.title=​បង្រួម +zoom_out_label=​បង្រួម +zoom_in.title=​ពង្រីក +zoom_in_label=​ពង្រីក +zoom.title=ពង្រីក +presentation_mode.title=ប្ដូរ​ទៅ​របៀប​បទ​បង្ហាញ +presentation_mode_label=របៀប​បទ​បង្ហាញ +open_file.title=បើក​ឯកសារ +open_file_label=បើក +print.title=បោះពុម្ព +print_label=បោះពុម្ព +download.title=ទាញ​យក +download_label=ទាញ​យក +bookmark.title=ទិដ្ឋភាព​បច្ចុប្បន្ន (ចម្លង ឬ​បើក​នៅ​ក្នុង​បង្អួច​ថ្មី) +bookmark_label=ទិដ្ឋភាព​បច្ចុប្បន្ន + +# Secondary toolbar and context menu +tools.title=ឧបករណ៍ +tools_label=ឧបករណ៍ +first_page.title=ទៅកាន់​ទំព័រ​ដំបូង​ +first_page.label=ទៅកាន់​ទំព័រ​ដំបូង​ +first_page_label=ទៅកាន់​ទំព័រ​ដំបូង​ +last_page.title=ទៅកាន់​ទំព័រ​ចុងក្រោយ​ +last_page.label=ទៅកាន់​ទំព័រ​ចុងក្រោយ​ +last_page_label=ទៅកាន់​ទំព័រ​ចុងក្រោយ +page_rotate_cw.title=បង្វិល​ស្រប​ទ្រនិច​នាឡិកា +page_rotate_cw.label=បង្វិល​ស្រប​ទ្រនិច​នាឡិកា +page_rotate_cw_label=បង្វិល​ស្រប​ទ្រនិច​នាឡិកា +page_rotate_ccw.title=បង្វិល​ច្រាស​ទ្រនិច​នាឡិកា​​ +page_rotate_ccw.label=បង្វិល​ច្រាស​ទ្រនិច​នាឡិកា​​ +page_rotate_ccw_label=បង្វិល​ច្រាស​ទ្រនិច​នាឡិកា​​ + +hand_tool_enable.title=បើក​ឧបករណ៍​ដោយ​ដៃ +hand_tool_enable_label=បើក​ឧបករណ៍​ដោយ​ដៃ +hand_tool_disable.title=បិទ​ឧបករណ៍​ប្រើ​ដៃ +hand_tool_disable_label=បិទ​ឧបករណ៍​ប្រើ​ដៃ + +# Document properties dialog box +document_properties.title=លក្ខណ​សម្បត្តិ​ឯកសារ… +document_properties_label=លក្ខណ​សម្បត្តិ​ឯកសារ… +document_properties_file_name=ឈ្មោះ​ឯកសារ៖ +document_properties_file_size=ទំហំ​ឯកសារ៖ +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=ចំណងជើង ៖ +document_properties_author=អ្នក​និពន្ធ៖ +document_properties_subject=ប្រធានបទ៖ +document_properties_keywords=ពាក្យ​គន្លឹះ៖ +document_properties_creation_date=កាលបរិច្ឆេទ​បង្កើត៖ +document_properties_modification_date=កាលបរិច្ឆេទ​កែប្រែ៖ +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=អ្នក​បង្កើត៖ +document_properties_producer=កម្មវិធី​បង្កើត PDF ៖ +document_properties_version=កំណែ PDF ៖ +document_properties_page_count=ចំនួន​ទំព័រ៖ +document_properties_close=បិទ + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=បិទ/បើក​គ្រាប់​រំកិល +toggle_sidebar_label=បិទ/បើក​គ្រាប់​រំកិល +outline.title=បង្ហាញ​គ្រោង​ឯកសារ +outline_label=គ្រោង​ឯកសារ +attachments.title=បង្ហាញ​ឯកសារ​ភ្ជាប់ +attachments_label=ឯកសារ​ភ្ជាប់ +thumbs.title=បង្ហាញ​រូបភាព​តូចៗ +thumbs_label=រួបភាព​តូចៗ +findbar.title=រក​នៅ​ក្នុង​ឯកសារ +findbar_label=រក + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=ទំព័រ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=រូបភាព​តូច​របស់​ទំព័រ {{page}} + +# Find panel button title and messages +find_label=រក ៖ +find_previous.title=រក​ពាក្យ ឬ​ឃ្លា​ដែល​បាន​ជួប​មុន +find_previous_label=មុន +find_next.title=រក​ពាក្យ ឬ​ឃ្លា​ដែល​បាន​ជួប​បន្ទាប់ +find_next_label=បន្ទាប់ +find_highlight=បន្លិច​ទាំងអស់ +find_match_case_label=ករណី​ដំណូច +find_reached_top=បាន​បន្ត​ពី​ខាង​ក្រោម ទៅ​ដល់​ខាង​​លើ​នៃ​ឯកសារ +find_reached_bottom=បាន​បន្ត​ពី​ខាងលើ ទៅដល់​ចុង​​នៃ​ឯកសារ +find_not_found=រក​មិន​ឃើញ​ពាក្យ ឬ​ឃ្លា + +# Error panel labels +error_more_info=ព័ត៌មាន​បន្ថែម +error_less_info=ព័ត៌មាន​តិចតួច +error_close=បិទ +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=សារ ៖ {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=ជង់ ៖ {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ឯកសារ ៖ {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=ជួរ ៖ {{line}} +rendering_error=មាន​កំហុស​បាន​កើតឡើង​ពេល​បង្ហាញ​ទំព័រ ។ + +# Predefined zoom values +page_scale_width=ទទឹង​ទំព័រ +page_scale_fit=សម​ទំព័រ +page_scale_auto=ពង្រីក​ស្វ័យប្រវត្តិ +page_scale_actual=ទំហំ​ជាក់ស្ដែង +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=កំហុស +loading_error=មាន​កំហុស​បាន​កើតឡើង​ពេល​កំពុង​ផ្ទុក PDF ។ +invalid_file_error=ឯកសារ PDF ខូច ឬ​មិន​ត្រឹមត្រូវ ។ +missing_file_error=បាត់​ឯកសារ PDF +unexpected_response_error=ការ​ឆ្លើយ​តម​ម៉ាស៊ីន​មេ​ដែល​មិន​បាន​រំពឹង។ + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} ចំណារ​ពន្យល់] +password_label=បញ្ចូល​ពាក្យសម្ងាត់​ដើម្បី​បើក​ឯកសារ PDF នេះ។ +password_invalid=ពាក្យសម្ងាត់​មិន​ត្រឹមត្រូវ។ សូម​ព្យាយាម​ម្ដងទៀត។ +password_ok=យល់​ព្រម +password_cancel=បោះបង់ + +printing_not_supported=ការ​ព្រមាន ៖ កា​រ​បោះពុម្ព​មិន​ត្រូវ​បាន​គាំទ្រ​ពេញលេញ​ដោយ​កម្មវិធី​រុករក​នេះ​ទេ ។ +printing_not_ready=ព្រមាន៖ PDF មិន​ត្រូវ​បាន​ផ្ទុក​ទាំងស្រុង​ដើម្បី​បោះពុម្ព​ទេ។ +web_fonts_disabled=បាន​បិទ​ពុម្ពអក្សរ​បណ្ដាញ ៖ មិន​អាច​ប្រើ​ពុម្ពអក្សរ PDF ដែល​បាន​បង្កប់​បាន​ទេ ។ +document_colors_not_allowed=ឯកសារ PDF មិន​ត្រូវ​បាន​អនុញ្ញាត​ឲ្យ​ប្រើ​ពណ៌​ផ្ទាល់​របស់​វា​ទេ៖ 'អនុញ្ញាត​​ឲ្យ​ទំព័រ​ជ្រើស​ពណ៌​ផ្ទាល់​ខ្លួន' ត្រូវ​បាន​ធ្វើ​ឲ្យ​អសកម្ម​ក្នុង​​កម្មវិធី​រុករក។ diff --git a/static/pdf.js/locale/kn/viewer.ftl b/static/pdf.js/locale/kn/viewer.ftl deleted file mode 100644 index 03322555..00000000 --- a/static/pdf.js/locale/kn/viewer.ftl +++ /dev/null @@ -1,213 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = ಹಿಂದಿನ ಪುಟ -pdfjs-previous-button-label = ಹಿಂದಿನ -pdfjs-next-button = - .title = ಮುಂದಿನ ಪುಟ -pdfjs-next-button-label = ಮುಂದಿನ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = ಪುಟ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } ರಲ್ಲಿ -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pagesCount } ರಲ್ಲಿ { $pageNumber }) -pdfjs-zoom-out-button = - .title = ಕಿರಿದಾಗಿಸು -pdfjs-zoom-out-button-label = ಕಿರಿದಾಗಿಸಿ -pdfjs-zoom-in-button = - .title = ಹಿರಿದಾಗಿಸು -pdfjs-zoom-in-button-label = ಹಿರಿದಾಗಿಸಿ -pdfjs-zoom-select = - .title = ಗಾತ್ರಬದಲಿಸು -pdfjs-presentation-mode-button = - .title = ಪ್ರಸ್ತುತಿ (ಪ್ರಸೆಂಟೇಶನ್) ಕ್ರಮಕ್ಕೆ ಬದಲಾಯಿಸು -pdfjs-presentation-mode-button-label = ಪ್ರಸ್ತುತಿ (ಪ್ರಸೆಂಟೇಶನ್) ಕ್ರಮ -pdfjs-open-file-button = - .title = ಕಡತವನ್ನು ತೆರೆ -pdfjs-open-file-button-label = ತೆರೆಯಿರಿ -pdfjs-print-button = - .title = ಮುದ್ರಿಸು -pdfjs-print-button-label = ಮುದ್ರಿಸಿ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ಉಪಕರಣಗಳು -pdfjs-tools-button-label = ಉಪಕರಣಗಳು -pdfjs-first-page-button = - .title = ಮೊದಲ ಪುಟಕ್ಕೆ ತೆರಳು -pdfjs-first-page-button-label = ಮೊದಲ ಪುಟಕ್ಕೆ ತೆರಳು -pdfjs-last-page-button = - .title = ಕೊನೆಯ ಪುಟಕ್ಕೆ ತೆರಳು -pdfjs-last-page-button-label = ಕೊನೆಯ ಪುಟಕ್ಕೆ ತೆರಳು -pdfjs-page-rotate-cw-button = - .title = ಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು -pdfjs-page-rotate-cw-button-label = ಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು -pdfjs-page-rotate-ccw-button = - .title = ಅಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು -pdfjs-page-rotate-ccw-button-label = ಅಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು -pdfjs-cursor-text-select-tool-button = - .title = ಪಠ್ಯ ಆಯ್ಕೆ ಉಪಕರಣವನ್ನು ಸಕ್ರಿಯಗೊಳಿಸಿ -pdfjs-cursor-text-select-tool-button-label = ಪಠ್ಯ ಆಯ್ಕೆಯ ಉಪಕರಣ -pdfjs-cursor-hand-tool-button = - .title = ಕೈ ಉಪಕರಣವನ್ನು ಸಕ್ರಿಯಗೊಳಿಸಿ -pdfjs-cursor-hand-tool-button-label = ಕೈ ಉಪಕರಣ - -## Document properties dialog - -pdfjs-document-properties-button = - .title = ಡಾಕ್ಯುಮೆಂಟ್‌ ಗುಣಗಳು... -pdfjs-document-properties-button-label = ಡಾಕ್ಯುಮೆಂಟ್‌ ಗುಣಗಳು... -pdfjs-document-properties-file-name = ಕಡತದ ಹೆಸರು: -pdfjs-document-properties-file-size = ಕಡತದ ಗಾತ್ರ: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } ಬೈಟ್‍ಗಳು) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } ಬೈಟ್‍ಗಳು) -pdfjs-document-properties-title = ಶೀರ್ಷಿಕೆ: -pdfjs-document-properties-author = ಕರ್ತೃ: -pdfjs-document-properties-subject = ವಿಷಯ: -pdfjs-document-properties-keywords = ಮುಖ್ಯಪದಗಳು: -pdfjs-document-properties-creation-date = ರಚಿಸಿದ ದಿನಾಂಕ: -pdfjs-document-properties-modification-date = ಮಾರ್ಪಡಿಸಲಾದ ದಿನಾಂಕ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = ರಚಿಸಿದವರು: -pdfjs-document-properties-producer = PDF ಉತ್ಪಾದಕ: -pdfjs-document-properties-version = PDF ಆವೃತ್ತಿ: -pdfjs-document-properties-page-count = ಪುಟದ ಎಣಿಕೆ: -pdfjs-document-properties-page-size-unit-inches = ಇದರಲ್ಲಿ -pdfjs-document-properties-page-size-orientation-portrait = ಭಾವಚಿತ್ರ -pdfjs-document-properties-page-size-orientation-landscape = ಪ್ರಕೃತಿ ಚಿತ್ರ - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -pdfjs-document-properties-close-button = ಮುಚ್ಚು - -## Print - -pdfjs-print-progress-message = ಮುದ್ರಿಸುವುದಕ್ಕಾಗಿ ದಸ್ತಾವೇಜನ್ನು ಸಿದ್ಧಗೊಳಿಸಲಾಗುತ್ತಿದೆ… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = ರದ್ದು ಮಾಡು -pdfjs-printing-not-supported = ಎಚ್ಚರಿಕೆ: ಈ ಜಾಲವೀಕ್ಷಕದಲ್ಲಿ ಮುದ್ರಣಕ್ಕೆ ಸಂಪೂರ್ಣ ಬೆಂಬಲವಿಲ್ಲ. -pdfjs-printing-not-ready = ಎಚ್ಚರಿಕೆ: PDF ಕಡತವು ಮುದ್ರಿಸಲು ಸಂಪೂರ್ಣವಾಗಿ ಲೋಡ್ ಆಗಿಲ್ಲ. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = ಬದಿಪಟ್ಟಿಯನ್ನು ಹೊರಳಿಸು -pdfjs-toggle-sidebar-button-label = ಬದಿಪಟ್ಟಿಯನ್ನು ಹೊರಳಿಸು -pdfjs-document-outline-button-label = ದಸ್ತಾವೇಜಿನ ಹೊರರೇಖೆ -pdfjs-attachments-button = - .title = ಲಗತ್ತುಗಳನ್ನು ತೋರಿಸು -pdfjs-attachments-button-label = ಲಗತ್ತುಗಳು -pdfjs-thumbs-button = - .title = ಚಿಕ್ಕಚಿತ್ರದಂತೆ ತೋರಿಸು -pdfjs-thumbs-button-label = ಚಿಕ್ಕಚಿತ್ರಗಳು -pdfjs-findbar-button = - .title = ದಸ್ತಾವೇಜಿನಲ್ಲಿ ಹುಡುಕು -pdfjs-findbar-button-label = ಹುಡುಕು - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = ಪುಟ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = ಪುಟವನ್ನು ಚಿಕ್ಕಚಿತ್ರದಂತೆ ತೋರಿಸು { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = ಹುಡುಕು - .placeholder = ದಸ್ತಾವೇಜಿನಲ್ಲಿ ಹುಡುಕು… -pdfjs-find-previous-button = - .title = ವಾಕ್ಯದ ಹಿಂದಿನ ಇರುವಿಕೆಯನ್ನು ಹುಡುಕು -pdfjs-find-previous-button-label = ಹಿಂದಿನ -pdfjs-find-next-button = - .title = ವಾಕ್ಯದ ಮುಂದಿನ ಇರುವಿಕೆಯನ್ನು ಹುಡುಕು -pdfjs-find-next-button-label = ಮುಂದಿನ -pdfjs-find-highlight-checkbox = ಎಲ್ಲವನ್ನು ಹೈಲೈಟ್ ಮಾಡು -pdfjs-find-match-case-checkbox-label = ಕೇಸನ್ನು ಹೊಂದಿಸು -pdfjs-find-reached-top = ದಸ್ತಾವೇಜಿನ ಮೇಲ್ಭಾಗವನ್ನು ತಲುಪಿದೆ, ಕೆಳಗಿನಿಂದ ಆರಂಭಿಸು -pdfjs-find-reached-bottom = ದಸ್ತಾವೇಜಿನ ಕೊನೆಯನ್ನು ತಲುಪಿದೆ, ಮೇಲಿನಿಂದ ಆರಂಭಿಸು -pdfjs-find-not-found = ವಾಕ್ಯವು ಕಂಡು ಬಂದಿಲ್ಲ - -## Predefined zoom values - -pdfjs-page-scale-width = ಪುಟದ ಅಗಲ -pdfjs-page-scale-fit = ಪುಟದ ಸರಿಹೊಂದಿಕೆ -pdfjs-page-scale-auto = ಸ್ವಯಂಚಾಲಿತ ಗಾತ್ರಬದಲಾವಣೆ -pdfjs-page-scale-actual = ನಿಜವಾದ ಗಾತ್ರ -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF ಅನ್ನು ಲೋಡ್ ಮಾಡುವಾಗ ಒಂದು ದೋಷ ಎದುರಾಗಿದೆ. -pdfjs-invalid-file-error = ಅಮಾನ್ಯವಾದ ಅಥವ ಹಾಳಾದ PDF ಕಡತ. -pdfjs-missing-file-error = PDF ಕಡತ ಇಲ್ಲ. -pdfjs-unexpected-response-error = ಅನಿರೀಕ್ಷಿತವಾದ ಪೂರೈಕೆಗಣಕದ ಪ್ರತಿಕ್ರಿಯೆ. -pdfjs-rendering-error = ಪುಟವನ್ನು ನಿರೂಪಿಸುವಾಗ ಒಂದು ದೋಷ ಎದುರಾಗಿದೆ. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } ಟಿಪ್ಪಣಿ] - -## Password - -pdfjs-password-label = PDF ಅನ್ನು ತೆರೆಯಲು ಗುಪ್ತಪದವನ್ನು ನಮೂದಿಸಿ. -pdfjs-password-invalid = ಅಮಾನ್ಯವಾದ ಗುಪ್ತಪದ, ದಯವಿಟ್ಟು ಇನ್ನೊಮ್ಮೆ ಪ್ರಯತ್ನಿಸಿ. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = ರದ್ದು ಮಾಡು -pdfjs-web-fonts-disabled = ಜಾಲ ಅಕ್ಷರಶೈಲಿಯನ್ನು ನಿಷ್ಕ್ರಿಯಗೊಳಿಸಲಾಗಿದೆ: ಅಡಕಗೊಳಿಸಿದ PDF ಅಕ್ಷರಶೈಲಿಗಳನ್ನು ಬಳಸಲು ಸಾಧ್ಯವಾಗಿಲ್ಲ. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/kn/viewer.properties b/static/pdf.js/locale/kn/viewer.properties new file mode 100644 index 00000000..f206717d --- /dev/null +++ b/static/pdf.js/locale/kn/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=ಹಿಂದಿನ ಪುಟ +previous_label=ಹಿಂದಿನ +next.title=ಮುಂದಿನ ಪುಟ +next_label=ಮುಂದಿನ + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=ಪುಟ: +page_of={{pageCount}} ರಲ್ಲಿ + +zoom_out.title=ಕಿರಿದಾಗಿಸು +zoom_out_label=ಕಿರಿದಾಗಿಸಿ +zoom_in.title=ಹಿರಿದಾಗಿಸು +zoom_in_label=ಹಿರಿದಾಗಿಸಿ +zoom.title=ಗಾತ್ರಬದಲಿಸು +presentation_mode.title=ಪ್ರಸ್ತುತಿ (ಪ್ರಸೆಂಟೇಶನ್) ಕ್ರಮಕ್ಕೆ ಬದಲಾಯಿಸು +presentation_mode_label=ಪ್ರಸ್ತುತಿ (ಪ್ರಸೆಂಟೇಶನ್) ಕ್ರಮ +open_file.title=ಕಡತವನ್ನು ತೆರೆ +open_file_label=ತೆರೆಯಿರಿ +print.title=ಮುದ್ರಿಸು +print_label=ಮುದ್ರಿಸಿ +download.title=ಇಳಿಸು +download_label=ಇಳಿಸಿಕೊಳ್ಳಿ +bookmark.title=ಪ್ರಸಕ್ತ ನೋಟ (ಪ್ರತಿ ಮಾಡು ಅಥವ ಹೊಸ ಕಿಟಕಿಯಲ್ಲಿ ತೆರೆ) +bookmark_label=ಪ್ರಸಕ್ತ ನೋಟ + +# Secondary toolbar and context menu +tools.title=ಉಪಕರಣಗಳು +tools_label=ಉಪಕರಣಗಳು +first_page.title=ಮೊದಲ ಪುಟಕ್ಕೆ ತೆರಳು +first_page.label=ಮೊದಲ ಪುಟಕ್ಕೆ ತೆರಳು +first_page_label=ಮೊದಲ ಪುಟಕ್ಕೆ ತೆರಳು +last_page.title=ಕೊನೆಯ ಪುಟಕ್ಕೆ ತೆರಳು +last_page.label=ಕೊನೆಯ ಪುಟಕ್ಕೆ ತೆರಳು +last_page_label=ಕೊನೆಯ ಪುಟಕ್ಕೆ ತೆರಳು +page_rotate_cw.title=ಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು +page_rotate_cw.label=ಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು +page_rotate_cw_label=ಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು +page_rotate_ccw.title=ಅಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು +page_rotate_ccw.label=ಅಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು +page_rotate_ccw_label=ಅಪ್ರದಕ್ಷಿಣೆಯಲ್ಲಿ ತಿರುಗಿಸು + +hand_tool_enable.title=ಕೈ ಉಪಕರಣವನ್ನು ಸಕ್ರಿಯಗೊಳಿಸು +hand_tool_enable_label=ಕೈ ಉಪಕರಣವನ್ನು ಸಕ್ರಿಯಗೊಳಿಸು +hand_tool_disable.title=ಕೈ ಉಪಕರಣವನ್ನು ನಿಷ್ಕ್ರಿಯಗೊಳಿಸು +hand_tool_disable_label=ಕೈ ಉಪಕರಣವನ್ನು ನಿಷ್ಕ್ರಿಯಗೊಳಿಸು + +# Document properties dialog box +document_properties.title=ಡಾಕ್ಯುಮೆಂಟ್‌ ಗುಣಗಳು... +document_properties_label=ಡಾಕ್ಯುಮೆಂಟ್‌ ಗುಣಗಳು... +document_properties_file_name=ಕಡತದ ಹೆಸರು: +document_properties_file_size=ಕಡತದ ಗಾತ್ರ: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} ಬೈಟ್‍ಗಳು) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} ಬೈಟ್‍ಗಳು) +document_properties_title=ಶೀರ್ಷಿಕೆ: +document_properties_author=ಕರ್ತೃ: +document_properties_subject=ವಿಷಯ: +document_properties_keywords=ಮುಖ್ಯಪದಗಳು: +document_properties_creation_date=ರಚಿಸಿದ ದಿನಾಂಕ: +document_properties_modification_date=ಮಾರ್ಪಡಿಸಲಾದ ದಿನಾಂಕ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=ರಚಿಸಿದವರು: +document_properties_producer=PDF ಉತ್ಪಾದಕ: +document_properties_version=PDF ಆವೃತ್ತಿ: +document_properties_page_count=ಪುಟದ ಎಣಿಕೆ: +document_properties_close=ಮುಚ್ಚು + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=ಬದಿಪಟ್ಟಿಯನ್ನು ಹೊರಳಿಸು +toggle_sidebar_label=ಬದಿಪಟ್ಟಿಯನ್ನು ಹೊರಳಿಸು +outline.title=ದಸ್ತಾವೇಜಿನ ಹೊರರೇಖೆಯನ್ನು ತೋರಿಸು +outline_label=ದಸ್ತಾವೇಜಿನ ಹೊರರೇಖೆ +attachments.title=ಲಗತ್ತುಗಳನ್ನು ತೋರಿಸು +attachments_label=ಲಗತ್ತುಗಳು +thumbs.title=ಚಿಕ್ಕಚಿತ್ರದಂತೆ ತೋರಿಸು +thumbs_label=ಚಿಕ್ಕಚಿತ್ರಗಳು +findbar.title=ದಸ್ತಾವೇಜಿನಲ್ಲಿ ಹುಡುಕು +findbar_label=ಹುಡುಕು + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=ಪುಟ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=ಪುಟವನ್ನು ಚಿಕ್ಕಚಿತ್ರದಂತೆ ತೋರಿಸು {{page}} + +# Find panel button title and messages +find_label=ಹುಡುಕು: +find_previous.title=ವಾಕ್ಯದ ಹಿಂದಿನ ಇರುವಿಕೆಯನ್ನು ಹುಡುಕು +find_previous_label=ಹಿಂದಿನ +find_next.title=ವಾಕ್ಯದ ಮುಂದಿನ ಇರುವಿಕೆಯನ್ನು ಹುಡುಕು +find_next_label=ಮುಂದಿನ +find_highlight=ಎಲ್ಲವನ್ನು ಹೈಲೈಟ್ ಮಾಡು +find_match_case_label=ಕೇಸನ್ನು ಹೊಂದಿಸು +find_reached_top=ದಸ್ತಾವೇಜಿನ ಮೇಲ್ಭಾಗವನ್ನು ತಲುಪಿದೆ, ಕೆಳಗಿನಿಂದ ಆರಂಭಿಸು +find_reached_bottom=ದಸ್ತಾವೇಜಿನ ಕೊನೆಯನ್ನು ತಲುಪಿದೆ, ಮೇಲಿನಿಂದ ಆರಂಭಿಸು +find_not_found=ವಾಕ್ಯವು ಕಂಡು ಬಂದಿಲ್ಲ + +# Error panel labels +error_more_info=ಹೆಚ್ಚಿನ ಮಾಹಿತಿ +error_less_info=ಕಡಿಮೆ ಮಾಹಿತಿ +error_close=ಮುಚ್ಚು +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=ಸಂದೇಶ: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=ರಾಶಿ: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ಕಡತ: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=ಸಾಲು: {{line}} +rendering_error=ಪುಟವನ್ನು ನಿರೂಪಿಸುವಾಗ ಒಂದು ದೋಷ ಎದುರಾಗಿದೆ. + +# Predefined zoom values +page_scale_width=ಪುಟದ ಅಗಲ +page_scale_fit=ಪುಟದ ಸರಿಹೊಂದಿಕೆ +page_scale_auto=ಸ್ವಯಂಚಾಲಿತ ಗಾತ್ರಬದಲಾವಣೆ +page_scale_actual=ನಿಜವಾದ ಗಾತ್ರ +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=ದೋಷ +loading_error=PDF ಅನ್ನು ಲೋಡ್ ಮಾಡುವಾಗ ಒಂದು ದೋಷ ಎದುರಾಗಿದೆ. +invalid_file_error=ಅಮಾನ್ಯವಾದ ಅಥವ ಹಾಳಾದ PDF ಕಡತ. +missing_file_error=PDF ಕಡತ ಇಲ್ಲ. +unexpected_response_error=ಅನಿರೀಕ್ಷಿತವಾದ ಪೂರೈಕೆಗಣಕದ ಪ್ರತಿಕ್ರಿಯೆ. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} ಟಿಪ್ಪಣಿ] +password_label=PDF ಅನ್ನು ತೆರೆಯಲು ಗುಪ್ತಪದವನ್ನು ನಮೂದಿಸಿ. +password_invalid=ಅಮಾನ್ಯವಾದ ಗುಪ್ತಪದ, ದಯವಿಟ್ಟು ಇನ್ನೊಮ್ಮೆ ಪ್ರಯತ್ನಿಸಿ. +password_ok=OK +password_cancel=ರದ್ದು ಮಾಡು + +printing_not_supported=ಎಚ್ಚರಿಕೆ: ಈ ಜಾಲವೀಕ್ಷಕದಲ್ಲಿ ಮುದ್ರಣಕ್ಕೆ ಸಂಪೂರ್ಣ ಬೆಂಬಲವಿಲ್ಲ. +printing_not_ready=ಎಚ್ಚರಿಕೆ: PDF ಕಡತವು ಮುದ್ರಿಸಲು ಸಂಪೂರ್ಣವಾಗಿ ಲೋಡ್ ಆಗಿಲ್ಲ. +web_fonts_disabled=ಜಾಲ ಅಕ್ಷರಶೈಲಿಯನ್ನು ನಿಷ್ಕ್ರಿಯಗೊಳಿಸಲಾಗಿದೆ: ಅಡಕಗೊಳಿಸಿದ PDF ಅಕ್ಷರಶೈಲಿಗಳನ್ನು ಬಳಸಲು ಸಾಧ್ಯವಾಗಿಲ್ಲ. +document_colors_not_allowed=PDF ದಸ್ತಾವೇಜುಗಳು ತಮ್ಮದೆ ಆದ ಬಣ್ಣಗಳನ್ನು ಬಳಸಲು ಅನುಮತಿ ಇರುವುದಿಲ್ಲ: 'ಪುಟಗಳು ತಮ್ಮದೆ ಆದ ಬಣ್ಣವನ್ನು ಆಯ್ಕೆ ಮಾಡಲು ಅನುಮತಿಸು' ಅನ್ನು ಜಾಲವೀಕ್ಷಕದಲ್ಲಿ ನಿಷ್ಕ್ರಿಯಗೊಳಿಸಲಾಗಿರುತ್ತದೆ. diff --git a/static/pdf.js/locale/ko/viewer.ftl b/static/pdf.js/locale/ko/viewer.ftl deleted file mode 100644 index 2afce144..00000000 --- a/static/pdf.js/locale/ko/viewer.ftl +++ /dev/null @@ -1,394 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = 이전 페이지 -pdfjs-previous-button-label = 이전 -pdfjs-next-button = - .title = 다음 페이지 -pdfjs-next-button-label = 다음 -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = 페이지 -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = / { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } / { $pagesCount }) -pdfjs-zoom-out-button = - .title = 축소 -pdfjs-zoom-out-button-label = 축소 -pdfjs-zoom-in-button = - .title = 확대 -pdfjs-zoom-in-button-label = 확대 -pdfjs-zoom-select = - .title = 확대/축소 -pdfjs-presentation-mode-button = - .title = 프레젠테이션 모드로 전환 -pdfjs-presentation-mode-button-label = 프레젠테이션 모드 -pdfjs-open-file-button = - .title = 파일 열기 -pdfjs-open-file-button-label = 열기 -pdfjs-print-button = - .title = 인쇄 -pdfjs-print-button-label = 인쇄 -pdfjs-save-button = - .title = 저장 -pdfjs-save-button-label = 저장 -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = 다운로드 -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = 다운로드 -pdfjs-bookmark-button = - .title = 현재 페이지 (현재 페이지에서 URL 보기) -pdfjs-bookmark-button-label = 현재 페이지 -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = 앱에서 열기 -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = 앱에서 열기 - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = 도구 -pdfjs-tools-button-label = 도구 -pdfjs-first-page-button = - .title = 첫 페이지로 이동 -pdfjs-first-page-button-label = 첫 페이지로 이동 -pdfjs-last-page-button = - .title = 마지막 페이지로 이동 -pdfjs-last-page-button-label = 마지막 페이지로 이동 -pdfjs-page-rotate-cw-button = - .title = 시계방향으로 회전 -pdfjs-page-rotate-cw-button-label = 시계방향으로 회전 -pdfjs-page-rotate-ccw-button = - .title = 시계 반대방향으로 회전 -pdfjs-page-rotate-ccw-button-label = 시계 반대방향으로 회전 -pdfjs-cursor-text-select-tool-button = - .title = 텍스트 선택 도구 활성화 -pdfjs-cursor-text-select-tool-button-label = 텍스트 선택 도구 -pdfjs-cursor-hand-tool-button = - .title = 손 도구 활성화 -pdfjs-cursor-hand-tool-button-label = 손 도구 -pdfjs-scroll-page-button = - .title = 페이지 스크롤 사용 -pdfjs-scroll-page-button-label = 페이지 스크롤 -pdfjs-scroll-vertical-button = - .title = 세로 스크롤 사용 -pdfjs-scroll-vertical-button-label = 세로 스크롤 -pdfjs-scroll-horizontal-button = - .title = 가로 스크롤 사용 -pdfjs-scroll-horizontal-button-label = 가로 스크롤 -pdfjs-scroll-wrapped-button = - .title = 래핑(자동 줄 바꿈) 스크롤 사용 -pdfjs-scroll-wrapped-button-label = 래핑 스크롤 -pdfjs-spread-none-button = - .title = 한 페이지 보기 -pdfjs-spread-none-button-label = 펼침 없음 -pdfjs-spread-odd-button = - .title = 홀수 페이지로 시작하는 두 페이지 보기 -pdfjs-spread-odd-button-label = 홀수 펼침 -pdfjs-spread-even-button = - .title = 짝수 페이지로 시작하는 두 페이지 보기 -pdfjs-spread-even-button-label = 짝수 펼침 - -## Document properties dialog - -pdfjs-document-properties-button = - .title = 문서 속성… -pdfjs-document-properties-button-label = 문서 속성… -pdfjs-document-properties-file-name = 파일 이름: -pdfjs-document-properties-file-size = 파일 크기: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b }바이트) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b }바이트) -pdfjs-document-properties-title = 제목: -pdfjs-document-properties-author = 작성자: -pdfjs-document-properties-subject = 주제: -pdfjs-document-properties-keywords = 키워드: -pdfjs-document-properties-creation-date = 작성 날짜: -pdfjs-document-properties-modification-date = 수정 날짜: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = 작성 프로그램: -pdfjs-document-properties-producer = PDF 변환 소프트웨어: -pdfjs-document-properties-version = PDF 버전: -pdfjs-document-properties-page-count = 페이지 수: -pdfjs-document-properties-page-size = 페이지 크기: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = 세로 방향 -pdfjs-document-properties-page-size-orientation-landscape = 가로 방향 -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = 레터 -pdfjs-document-properties-page-size-name-legal = 리걸 - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = 빠른 웹 보기: -pdfjs-document-properties-linearized-yes = 예 -pdfjs-document-properties-linearized-no = 아니요 -pdfjs-document-properties-close-button = 닫기 - -## Print - -pdfjs-print-progress-message = 인쇄 문서 준비 중… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = 취소 -pdfjs-printing-not-supported = 경고: 이 브라우저는 인쇄를 완전히 지원하지 않습니다. -pdfjs-printing-not-ready = 경고: 이 PDF를 인쇄를 할 수 있을 정도로 읽어들이지 못했습니다. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = 사이드바 표시/숨기기 -pdfjs-toggle-sidebar-notification-button = - .title = 사이드바 표시/숨기기 (문서에 아웃라인/첨부파일/레이어 포함됨) -pdfjs-toggle-sidebar-button-label = 사이드바 표시/숨기기 -pdfjs-document-outline-button = - .title = 문서 아웃라인 보기 (더블 클릭해서 모든 항목 펼치기/접기) -pdfjs-document-outline-button-label = 문서 아웃라인 -pdfjs-attachments-button = - .title = 첨부파일 보기 -pdfjs-attachments-button-label = 첨부파일 -pdfjs-layers-button = - .title = 레이어 보기 (더블 클릭해서 모든 레이어를 기본 상태로 재설정) -pdfjs-layers-button-label = 레이어 -pdfjs-thumbs-button = - .title = 미리보기 -pdfjs-thumbs-button-label = 미리보기 -pdfjs-current-outline-item-button = - .title = 현재 아웃라인 항목 찾기 -pdfjs-current-outline-item-button-label = 현재 아웃라인 항목 -pdfjs-findbar-button = - .title = 검색 -pdfjs-findbar-button-label = 검색 -pdfjs-additional-layers = 추가 레이어 - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page } 페이지 -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } 페이지 미리보기 - -## Find panel button title and messages - -pdfjs-find-input = - .title = 찾기 - .placeholder = 문서에서 찾기… -pdfjs-find-previous-button = - .title = 지정 문자열에 일치하는 1개 부분을 검색 -pdfjs-find-previous-button-label = 이전 -pdfjs-find-next-button = - .title = 지정 문자열에 일치하는 다음 부분을 검색 -pdfjs-find-next-button-label = 다음 -pdfjs-find-highlight-checkbox = 모두 강조 표시 -pdfjs-find-match-case-checkbox-label = 대/소문자 구분 -pdfjs-find-match-diacritics-checkbox-label = 분음 부호 일치 -pdfjs-find-entire-word-checkbox-label = 단어 단위로 -pdfjs-find-reached-top = 문서 처음까지 검색하고 끝으로 돌아와 검색했습니다. -pdfjs-find-reached-bottom = 문서 끝까지 검색하고 앞으로 돌아와 검색했습니다. -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = { $current } / { $total } 일치 -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = { $limit }개 이상 일치 -pdfjs-find-not-found = 검색 결과 없음 - -## Predefined zoom values - -pdfjs-page-scale-width = 페이지 너비에 맞추기 -pdfjs-page-scale-fit = 페이지에 맞추기 -pdfjs-page-scale-auto = 자동 -pdfjs-page-scale-actual = 실제 크기 -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = { $page } 페이지 - -## Loading indicator messages - -pdfjs-loading-error = PDF를 로드하는 동안 오류가 발생했습니다. -pdfjs-invalid-file-error = 잘못되었거나 손상된 PDF 파일. -pdfjs-missing-file-error = PDF 파일 없음. -pdfjs-unexpected-response-error = 예기치 않은 서버 응답입니다. -pdfjs-rendering-error = 페이지를 렌더링하는 동안 오류가 발생했습니다. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date } { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } 주석] - -## Password - -pdfjs-password-label = 이 PDF 파일을 열 수 있는 비밀번호를 입력하세요. -pdfjs-password-invalid = 잘못된 비밀번호입니다. 다시 시도하세요. -pdfjs-password-ok-button = 확인 -pdfjs-password-cancel-button = 취소 -pdfjs-web-fonts-disabled = 웹 폰트가 비활성화됨: 내장된 PDF 글꼴을 사용할 수 없습니다. - -## Editing - -pdfjs-editor-free-text-button = - .title = 텍스트 -pdfjs-editor-free-text-button-label = 텍스트 -pdfjs-editor-ink-button = - .title = 그리기 -pdfjs-editor-ink-button-label = 그리기 -pdfjs-editor-stamp-button = - .title = 이미지 추가 또는 편집 -pdfjs-editor-stamp-button-label = 이미지 추가 또는 편집 -pdfjs-editor-highlight-button = - .title = 강조 표시 -pdfjs-editor-highlight-button-label = 강조 표시 -pdfjs-highlight-floating-button = - .title = 강조 표시 -pdfjs-highlight-floating-button1 = - .title = 강조 표시 - .aria-label = 강조 표시 -pdfjs-highlight-floating-button-label = 강조 표시 - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = 그리기 제거 -pdfjs-editor-remove-freetext-button = - .title = 텍스트 제거 -pdfjs-editor-remove-stamp-button = - .title = 이미지 제거 -pdfjs-editor-remove-highlight-button = - .title = 강조 표시 제거 - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = 색상 -pdfjs-editor-free-text-size-input = 크기 -pdfjs-editor-ink-color-input = 색상 -pdfjs-editor-ink-thickness-input = 두께 -pdfjs-editor-ink-opacity-input = 불투명도 -pdfjs-editor-stamp-add-image-button = - .title = 이미지 추가 -pdfjs-editor-stamp-add-image-button-label = 이미지 추가 -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = 두께 -pdfjs-editor-free-highlight-thickness-title = - .title = 텍스트 이외의 항목을 강조 표시할 때 두께 변경 -pdfjs-free-text = - .aria-label = 텍스트 편집기 -pdfjs-free-text-default-content = 입력하세요… -pdfjs-ink = - .aria-label = 그리기 편집기 -pdfjs-ink-canvas = - .aria-label = 사용자 생성 이미지 - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = 대체 텍스트 -pdfjs-editor-alt-text-edit-button-label = 대체 텍스트 편집 -pdfjs-editor-alt-text-dialog-label = 옵션을 선택하세요 -pdfjs-editor-alt-text-dialog-description = 대체 텍스트는 사람들이 이미지를 볼 수 없거나 이미지가 로드되지 않을 때 도움이 됩니다. -pdfjs-editor-alt-text-add-description-label = 설명 추가 -pdfjs-editor-alt-text-add-description-description = 주제, 설정, 동작을 설명하는 1~2개의 문장을 목표로 하세요. -pdfjs-editor-alt-text-mark-decorative-label = 장식용으로 표시 -pdfjs-editor-alt-text-mark-decorative-description = 테두리나 워터마크와 같은 장식적인 이미지에 사용됩니다. -pdfjs-editor-alt-text-cancel-button = 취소 -pdfjs-editor-alt-text-save-button = 저장 -pdfjs-editor-alt-text-decorative-tooltip = 장식용으로 표시됨 -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = 예를 들어, “한 청년이 식탁에 앉아 식사를 하고 있습니다.” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = 왼쪽 위 — 크기 조정 -pdfjs-editor-resizer-label-top-middle = 가운데 위 - 크기 조정 -pdfjs-editor-resizer-label-top-right = 오른쪽 위 — 크기 조정 -pdfjs-editor-resizer-label-middle-right = 오른쪽 가운데 — 크기 조정 -pdfjs-editor-resizer-label-bottom-right = 오른쪽 아래 - 크기 조정 -pdfjs-editor-resizer-label-bottom-middle = 가운데 아래 — 크기 조정 -pdfjs-editor-resizer-label-bottom-left = 왼쪽 아래 - 크기 조정 -pdfjs-editor-resizer-label-middle-left = 왼쪽 가운데 — 크기 조정 - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = 색상 -pdfjs-editor-colorpicker-button = - .title = 색상 변경 -pdfjs-editor-colorpicker-dropdown = - .aria-label = 색상 선택 -pdfjs-editor-colorpicker-yellow = - .title = 노란색 -pdfjs-editor-colorpicker-green = - .title = 녹색 -pdfjs-editor-colorpicker-blue = - .title = 파란색 -pdfjs-editor-colorpicker-pink = - .title = 분홍색 -pdfjs-editor-colorpicker-red = - .title = 빨간색 - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = 모두 보기 -pdfjs-editor-highlight-show-all-button = - .title = 모두 보기 diff --git a/static/pdf.js/locale/ko/viewer.properties b/static/pdf.js/locale/ko/viewer.properties new file mode 100644 index 00000000..132a5f7c --- /dev/null +++ b/static/pdf.js/locale/ko/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=이전 페이지 +previous_label=이전 +next.title=다음 페이지 +next_label=다음 + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=페이지: +page_of=/{{pageCount}} + +zoom_out.title=축소 +zoom_out_label=축소 +zoom_in.title=확대 +zoom_in_label=확대 +zoom.title=크기 +presentation_mode.title=발표 모드로 전환 +presentation_mode_label=발표 모드 +open_file.title=파일 열기 +open_file_label=열기 +print.title=인쇄 +print_label=인쇄 +download.title=다운로드 +download_label=다운로드 +bookmark.title=지금 보이는 그대로 (복사하거나 새 창에 열기) +bookmark_label=지금 보이는 그대로 + +# Secondary toolbar and context menu +tools.title=도구 +tools_label=도구 +first_page.title=첫 페이지로 이동 +first_page.label=첫 페이지로 이동 +first_page_label=첫 페이지로 이동 +last_page.title=마지막 페이지로 이동 +last_page.label=마지막 페이지로 이동 +last_page_label=마지막 페이지로 이동 +page_rotate_cw.title=시계방향으로 회전 +page_rotate_cw.label=시계방향으로 회전 +page_rotate_cw_label=시계방향으로 회전 +page_rotate_ccw.title=시계 반대방향으로 회전 +page_rotate_ccw.label=시계 반대방향으로 회전 +page_rotate_ccw_label=시계 반대방향으로 회전 + +hand_tool_enable.title=손 도구 켜기 +hand_tool_enable_label=손 도구 켜기 +hand_tool_disable.title=손 도구 끄기 +hand_tool_disable_label=손 도구 끄기 + +# Document properties dialog box +document_properties.title=문서 속성… +document_properties_label=문서 속성… +document_properties_file_name=파일 이름: +document_properties_file_size=파일 사이즈: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}}바이트) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}}바이트) +document_properties_title=제목: +document_properties_author=저자: +document_properties_subject=주제: +document_properties_keywords=키워드: +document_properties_creation_date=생성일: +document_properties_modification_date=수정일: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=생성자: +document_properties_producer=PDF 생성기: +document_properties_version=PDF 버전: +document_properties_page_count=총 페이지: +document_properties_close=닫기 + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=탐색창 열고 닫기 +toggle_sidebar_label=탐색창 열고 닫기 +outline.title=문서 개요 보기 +outline_label=문서 개요 +attachments.title=첨부파일 보기 +attachments_label=첨부파일 +thumbs.title=미리보기 +thumbs_label=미리보기 +findbar.title=검색 +findbar_label=검색 + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title={{page}}쪽 +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}}쪽 미리보기 + +# Find panel button title and messages +find_label=검색: +find_previous.title=지정 문자열에 일치하는 1개 부분을 검색 +find_previous_label=이전 +find_next.title=지정 문자열에 일치하는 다음 부분을 검색 +find_next_label=다음 +find_highlight=모두 강조 표시 +find_match_case_label=대문자/소문자 구별 +find_reached_top=문서 처음까지 검색하고 끝으로 돌아와 검색했습니다. +find_reached_bottom=문서 끝까지 검색하고 앞으로 돌아와 검색했습니다. +find_not_found=검색 결과 없음 + +# Error panel labels +error_more_info=정보 더 보기 +error_less_info=정보 간단히 보기 +error_close=닫기 +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (빌드: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=메시지: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=스택: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=파일: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=줄 번호: {{line}} +rendering_error=페이지를 렌더링하다 오류가 났습니다. + +# Predefined zoom values +page_scale_width=페이지 너비에 맞춤 +page_scale_fit=페이지에 맞춤 +page_scale_auto=알아서 맞춤 +page_scale_actual=실제 크기에 맞춤 +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=오류 +loading_error=PDF를 읽는 중 오류가 생겼습니다. +invalid_file_error=유효하지 않거나 파손된 PDF 파일 +missing_file_error=PDF 파일이 없습니다. +unexpected_response_error=알 수 없는 서버 응답입니다. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} 주석] +password_label=이 PDF 파일을 열 수 있는 암호를 입력하십시오. +password_invalid=잘못된 암호입니다. 다시 시도해 주십시오. +password_ok=확인 +password_cancel=취소 + +printing_not_supported=경고: 이 브라우저는 인쇄를 완전히 지원하지 않습니다. +printing_not_ready=경고: 이 PDF를 인쇄를 할 수 있을 정도로 읽어들이지 못했습니다. +web_fonts_disabled=웹 폰트가 꺼져있음: 내장된 PDF 글꼴을 쓸 수 없습니다. +document_colors_not_allowed=PDF 문서의 색상을 쓰지 못하게 되어 있음: '웹 페이지 자체 색상 사용 허용'이 브라우저에서 꺼져 있습니다. diff --git a/static/pdf.js/locale/ku/viewer.properties b/static/pdf.js/locale/ku/viewer.properties new file mode 100644 index 00000000..8f40dbac --- /dev/null +++ b/static/pdf.js/locale/ku/viewer.properties @@ -0,0 +1,147 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Rûpela berê +previous_label=Paşve +next.title=Rûpela pêş +next_label=Pêş + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Rûpel: +page_of=/ {{pageCount}} + +zoom_out.title=Dûr bike +zoom_out_label=Dûr bike +zoom_in.title=Nêzîk bike +zoom_in_label=Nêzîk bike +zoom.title=Nêzîk Bike +presentation_mode.title=Derbasî mûda pêşkêşkariyê bibe +presentation_mode_label=Moda Pêşkêşkariyê +open_file.title=Pelî veke +open_file_label=Veke +print.title=Çap bike +print_label=Çap bike +download.title=Jêbar bike +download_label=Jêbar bike +bookmark.title=Xuyakirina niha (kopî yan jî di pencereyeke nû de veke) +bookmark_label=Xuyakirina niha + +# Secondary toolbar and context menu +tools.title=Amûr +tools_label=Amûr +first_page.title=Here rûpela yekemîn +first_page.label=Here rûpela yekemîn +first_page_label=Here rûpela yekemîn +last_page.title=Here rûpela dawîn +last_page.label=Here rûpela dawîn +last_page_label=Here rûpela dawîn +page_rotate_cw.title=Bi aliyê saetê ve bizivirîne +page_rotate_cw.label=Bi aliyê saetê ve bizivirîne +page_rotate_cw_label=Bi aliyê saetê ve bizivirîne +page_rotate_ccw.title=Berevajî aliyê saetê ve bizivirîne +page_rotate_ccw.label=Berevajî aliyê saetê ve bizivirîne +page_rotate_ccw_label=Berevajî aliyê saetê ve bizivirîne + + +# Document properties dialog box +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Sernav: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Darikê kêlekê veke/bigire +toggle_sidebar_label=Darikê kêlekê veke/bigire +outline.title=Şemaya belgeyê nîşan bide +outline_label=Şemaya belgeyê +thumbs.title=Wênekokan nîşan bide +thumbs_label=Wênekok +findbar.title=Di belgeyê de bibîne +findbar_label=Bibîne + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Rûpel {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Wênekoka rûpelê {{page}} + +# Find panel button title and messages +find_label=Bibîne: +find_previous.title=Peyva berê bibîne +find_previous_label=Paşve +find_next.title=Peyya pêş bibîne +find_next_label=Pêşve +find_highlight=Tevî beloq bike +find_match_case_label=Ji bo tîpên hûrdek-girdek bihîstyar +find_reached_top=Gihîşt serê rûpelê, ji dawiya rûpelê bidomîne +find_reached_bottom=Gihîşt dawiya rûpelê, ji serê rûpelê bidomîne +find_not_found=Peyv nehat dîtin + +# Error panel labels +error_more_info=Zêdetir agahî +error_less_info=Zêdetir agahî +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js versiyon {{version}} (avanî: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Peyam: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Komik: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Pel: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rêzik: {{line}} +rendering_error=Di vehûrandina rûpelê de çewtî çêbû. + +# Predefined zoom values +page_scale_width=Firehiya rûpelê +page_scale_fit=Di rûpelê de bicî bike +page_scale_auto=Xweber nêzîk bike +page_scale_actual=Mezinahiya rastîn +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Xeletî +loading_error=Dema ku PDF dihat barkirin çewtiyek çêbû. +invalid_file_error=Pelê PDFê nederbasdar yan jî xirabe ye. +missing_file_error=Pelê PDFê kêm e. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Nîşaneya {{type}}ê] +password_label=Ji bo PDFê vekî şîfreyê binivîse. +password_invalid=Şîfre çewt e. Tika ye dîsa biceribîne. +password_ok=Temam +password_cancel=Betal + +printing_not_supported=Hişyarî: Çapkirin ji hêla vê gerokê ve bi temamî nayê destekirin. +printing_not_ready=Hişyarî: PDF bi temamî nehat barkirin û ji bo çapê ne amade ye. +web_fonts_disabled=Fontên Webê neçalak in: Fontên PDFê yên veşartî nayên bikaranîn. +document_colors_not_allowed=Destûr tune ye ku belgeyên PDFê rengên xwe bi kar bînin: Di gerokê de 'destûrê bide rûpelan ku rengên xwe bi kar bînin' nehatiye çalakirin. diff --git a/static/pdf.js/locale/lg/viewer.properties b/static/pdf.js/locale/lg/viewer.properties new file mode 100644 index 00000000..3cac56e0 --- /dev/null +++ b/static/pdf.js/locale/lg/viewer.properties @@ -0,0 +1,111 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Omuko Ogubadewo +next.title=Omuko Oguddako + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Omuko: +page_of=ku {{pageCount}} + +zoom_out.title=Zimbulukusa +zoom_out_label=Zimbulukusa +zoom_in.title=Funza Munda +zoom_in_label=Funza Munda +zoom.title=Gezzamu +open_file.title=Bikula Fayiro +open_file_label=Ggulawo +print.title=Fulumya +print_label=Fulumya +download.title=Tikula +download_label=Tikula +bookmark.title=Endabika eriwo (koppa oba gulawo mu diriisa epya) +bookmark_label=Endabika Eriwo + +# Secondary toolbar and context menu + + +# Document properties dialog box +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +outline.title=Laga Ensalo ze Kiwandiko +outline_label=Ensalo ze Ekiwandiko +thumbs.title=Laga Ekifanyi Mubufunze +thumbs_label=Ekifanyi Mubufunze +findbar_label=Zuula + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Omuko {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Ekifananyi kyo Omuko Mubufunze {{page}} + +# Find panel button title and messages +find_previous.title=Zuula awayise mukweddamu mumiteddera +find_next.title=Zuula ekidako mukweddamu mumiteddera +find_highlight=Londa byonna +find_not_found=Emiteddera tezuuliddwa + +# Error panel labels +error_more_info=Ebisingawo +error_less_info=Mubumpimpi +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Obubaaka: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Ebipangiddwa: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fayiro {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Layini: {{line}} +rendering_error=Wabadewo ensobi muku tekawo omuko. + +# Predefined zoom values +page_scale_width=Obugazi bwo Omuko +page_scale_fit=Okutuka kwo Omuko +page_scale_auto=Okwefunza no Kwegeza +page_scale_actual=Obunene Obutufu +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Ensobi +loading_error=Wabadewo ensobi mukutika PDF. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Enyonyola] +password_ok=OK +password_cancel=Sazaamu + +printing_not_supported=Okulaabula: Okulumya empapula tekuwagirwa enonyeso enno. diff --git a/static/pdf.js/locale/lij/viewer.ftl b/static/pdf.js/locale/lij/viewer.ftl deleted file mode 100644 index b2941f9f..00000000 --- a/static/pdf.js/locale/lij/viewer.ftl +++ /dev/null @@ -1,247 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pagina primma -pdfjs-previous-button-label = Precedente -pdfjs-next-button = - .title = Pagina dòppo -pdfjs-next-button-label = Pròscima -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pagina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Diminoisci zoom -pdfjs-zoom-out-button-label = Diminoisci zoom -pdfjs-zoom-in-button = - .title = Aomenta zoom -pdfjs-zoom-in-button-label = Aomenta zoom -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Vanni into mòddo de prezentaçion -pdfjs-presentation-mode-button-label = Mòddo de prezentaçion -pdfjs-open-file-button = - .title = Arvi file -pdfjs-open-file-button-label = Arvi -pdfjs-print-button = - .title = Stanpa -pdfjs-print-button-label = Stanpa - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Atressi -pdfjs-tools-button-label = Atressi -pdfjs-first-page-button = - .title = Vanni a-a primma pagina -pdfjs-first-page-button-label = Vanni a-a primma pagina -pdfjs-last-page-button = - .title = Vanni a l'urtima pagina -pdfjs-last-page-button-label = Vanni a l'urtima pagina -pdfjs-page-rotate-cw-button = - .title = Gia into verso oraio -pdfjs-page-rotate-cw-button-label = Gia into verso oraio -pdfjs-page-rotate-ccw-button = - .title = Gia into verso antioraio -pdfjs-page-rotate-ccw-button-label = Gia into verso antioraio -pdfjs-cursor-text-select-tool-button = - .title = Abilita strumento de seleçion do testo -pdfjs-cursor-text-select-tool-button-label = Strumento de seleçion do testo -pdfjs-cursor-hand-tool-button = - .title = Abilita strumento man -pdfjs-cursor-hand-tool-button-label = Strumento man -pdfjs-scroll-vertical-button = - .title = Deuvia rebelamento verticale -pdfjs-scroll-vertical-button-label = Rebelamento verticale -pdfjs-scroll-horizontal-button = - .title = Deuvia rebelamento orizontâ -pdfjs-scroll-horizontal-button-label = Rebelamento orizontâ -pdfjs-scroll-wrapped-button = - .title = Deuvia rebelamento incapsolou -pdfjs-scroll-wrapped-button-label = Rebelamento incapsolou -pdfjs-spread-none-button = - .title = No unite a-a difuxon de pagina -pdfjs-spread-none-button-label = No difuxon -pdfjs-spread-odd-button = - .title = Uniscite a-a difuxon de pagina co-o numero dèspa -pdfjs-spread-odd-button-label = Difuxon dèspa -pdfjs-spread-even-button = - .title = Uniscite a-a difuxon de pagina co-o numero pari -pdfjs-spread-even-button-label = Difuxon pari - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propietæ do documento… -pdfjs-document-properties-button-label = Propietæ do documento… -pdfjs-document-properties-file-name = Nomme schedaio: -pdfjs-document-properties-file-size = Dimenscion schedaio: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kB ({ $size_b } byte) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } byte) -pdfjs-document-properties-title = Titolo: -pdfjs-document-properties-author = Aoto: -pdfjs-document-properties-subject = Ogetto: -pdfjs-document-properties-keywords = Paròlle ciave: -pdfjs-document-properties-creation-date = Dæta creaçion: -pdfjs-document-properties-modification-date = Dæta cangiamento: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Aotô originale: -pdfjs-document-properties-producer = Produtô PDF: -pdfjs-document-properties-version = Verscion PDF: -pdfjs-document-properties-page-count = Contezzo pagine: -pdfjs-document-properties-page-size = Dimenscion da pagina: -pdfjs-document-properties-page-size-unit-inches = dii gròsci -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = drito -pdfjs-document-properties-page-size-orientation-landscape = desteizo -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letia -pdfjs-document-properties-page-size-name-legal = Lezze - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista veloce do Web: -pdfjs-document-properties-linearized-yes = Sci -pdfjs-document-properties-linearized-no = No -pdfjs-document-properties-close-button = Særa - -## Print - -pdfjs-print-progress-message = Praparo o documento pe-a stanpa… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Anulla -pdfjs-printing-not-supported = Atençion: a stanpa a no l'é conpletamente soportâ da sto navegatô. -pdfjs-printing-not-ready = Atençion: o PDF o no l'é ancon caregou conpletamente pe-a stanpa. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Ativa/dizativa bara de scianco -pdfjs-toggle-sidebar-button-label = Ativa/dizativa bara de scianco -pdfjs-document-outline-button = - .title = Fanni vedde o contorno do documento (scicca doggio pe espande/ridue tutti i elementi) -pdfjs-document-outline-button-label = Contorno do documento -pdfjs-attachments-button = - .title = Fanni vedde alegæ -pdfjs-attachments-button-label = Alegæ -pdfjs-thumbs-button = - .title = Mostra miniatue -pdfjs-thumbs-button-label = Miniatue -pdfjs-findbar-button = - .title = Treuva into documento -pdfjs-findbar-button-label = Treuva - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pagina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatua da pagina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Treuva - .placeholder = Treuva into documento… -pdfjs-find-previous-button = - .title = Treuva a ripetiçion precedente do testo da çercâ -pdfjs-find-previous-button-label = Precedente -pdfjs-find-next-button = - .title = Treuva a ripetiçion dòppo do testo da çercâ -pdfjs-find-next-button-label = Segoente -pdfjs-find-highlight-checkbox = Evidençia -pdfjs-find-match-case-checkbox-label = Maioscole/minoscole -pdfjs-find-entire-word-checkbox-label = Poula intrega -pdfjs-find-reached-top = Razonto a fin da pagina, continoa da l'iniçio -pdfjs-find-reached-bottom = Razonto l'iniçio da pagina, continoa da-a fin -pdfjs-find-not-found = Testo no trovou - -## Predefined zoom values - -pdfjs-page-scale-width = Larghessa pagina -pdfjs-page-scale-fit = Adatta a una pagina -pdfjs-page-scale-auto = Zoom aotomatico -pdfjs-page-scale-actual = Dimenscioin efetive -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = S'é verificou 'n'erô itno caregamento do PDF. -pdfjs-invalid-file-error = O schedaio PDF o l'é no valido ò aroinou. -pdfjs-missing-file-error = O schedaio PDF o no gh'é. -pdfjs-unexpected-response-error = Risposta inprevista do-u server -pdfjs-rendering-error = Gh'é stæto 'n'erô itno rendering da pagina. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotaçion: { $type }] - -## Password - -pdfjs-password-label = Dimme a paròlla segreta pe arvî sto schedaio PDF. -pdfjs-password-invalid = Paròlla segreta sbalia. Preuva torna. -pdfjs-password-ok-button = Va ben -pdfjs-password-cancel-button = Anulla -pdfjs-web-fonts-disabled = I font do web en dizativæ: inposcibile adeuviâ i carateri do PDF. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/lij/viewer.properties b/static/pdf.js/locale/lij/viewer.properties new file mode 100644 index 00000000..04445c0e --- /dev/null +++ b/static/pdf.js/locale/lij/viewer.properties @@ -0,0 +1,124 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +previous.title = Pagina precedente +previous_label = Precedente +next.title = Pagina dòppo +next_label = Pròscima +page_label = Pagina: +page_of = de {{pageCount}} +zoom_out.title = Diminoisci zoom +zoom_out_label = Diminoisci zoom +zoom_in.title = Aomenta zoom +zoom_in_label = Aomenta zoom +zoom.title = Zoom +print.title = Stanpa +print_label = Stanpa +open_file.title = Arvi file +open_file_label = Arvi +download.title = Descaregamento +download_label = Descaregamento +bookmark.title = Vixon corente (còpia ò arvi inte 'n neuvo barcon) +bookmark_label = Vixon corente +outline.title = Veddi strutua documento +outline_label = Strutua documento +thumbs.title = Mostra miniatue +thumbs_label = Miniatue +thumb_page_title = Pagina {{page}} +thumb_page_canvas = Miniatua da pagina {{page}} +error_more_info = Ciù informaçioin +error_less_info = Meno informaçioin +error_version_info = PDF.js v{{version}} (build: {{build}}) +error_close = Særa +missing_file_error = O file PDF o no gh'é. +toggle_sidebar.title = Ativa/dizativa bara de scianco +toggle_sidebar_label = Ativa/dizativa bara de scianco +error_message = Mesaggio: {{message}} +error_stack = Stack: {{stack}} +error_file = File: {{file}} +error_line = Linia: {{line}} +rendering_error = Gh'é stæto 'n'erô itno rendering da pagina. +page_scale_width = Larghessa pagina +page_scale_fit = Adatta a una pagina +page_scale_auto = Zoom aotomatico +page_scale_actual = Dimenscioin efetive +loading_error_indicator = Erô +loading_error = S'é verificou 'n'erô itno caregamento do PDF. +printing_not_supported = Atençion: a stanpa a no l'é conpletamente soportâ da sto navegatô. + +# Context menu +page_rotate_cw.label=Gia in senso do releuio +page_rotate_ccw.label=Gia in senso do releuio a-a reversa + +presentation_mode.title=Vanni into mòddo de prezentaçion +presentation_mode_label=Mòddo de prezentaçion + +find_label = Treuva: +find_previous.title = Treuva a ripetiçion precedente do testo da çercâ +find_previous_label = Precedente +find_next.title = Treuva a ripetiçion dòppo do testo da çercâ +find_next_label = Segoente +find_highlight = Evidençia +find_match_case_label = Maioscole/minoscole +find_reached_bottom = Razonto l'iniçio da pagina, continoa da-a fin +find_reached_top = Razonto a fin da pagina, continoa da l'iniçio +find_not_found = Testo no trovou +findbar.title = Treuva into documento +findbar_label = Treuva +first_page.label = Vanni a-a primma pagina +last_page.label = Vanni a l'urtima pagina +invalid_file_error = O file PDF o l'é no valido ò aroinou. + +web_fonts_disabled = I font do web en dizativæ: inposcibile adeuviâ i carateri do PDF. +printing_not_ready = Atençion: o PDF o no l'é ancon caregou conpletamente pe-a stanpa. + +document_colors_not_allowed = No l'é poscibile adeuviâ i pròpi coî pe-i documenti PDF: l'opçion do navegatô “Permetti a-e pagine de çerne i pròpi coî in cangio de quelli inpostæ” a l'é dizativâ. +text_annotation_type.alt = [Anotaçion: {{type}}] + +first_page.title = Vanni a-a primma pagina +first_page_label = Vanni a-a primma pagina +last_page.title = Vanni a l'urtima pagina +last_page_label = Vanni a l'urtima pagina +page_rotate_ccw.title = Gia into verso antioraio +page_rotate_ccw_label = Gia into verso antioraio +page_rotate_cw.title = Gia into verso oraio +page_rotate_cw_label = Gia into verso oraio +tools.title = Strumenti +tools_label = Strumenti +password_label = Dimme a paròlla segreta pe arvî sto file PDF. +password_invalid = Paròlla segreta sbalia. Preuva torna. +password_ok = Va ben +password_cancel = Anulla + +document_properties.title = Propietæ do documento… +document_properties_label = Propietæ do documento… +document_properties_file_name = Nomme file: +document_properties_file_size = Dimenscion file: +document_properties_kb = {{size_kb}} kB ({{size_b}} byte) +document_properties_mb = {{size_kb}} MB ({{size_b}} byte) +document_properties_title = Titolo: +document_properties_author = Aoto: +document_properties_subject = Ogetto: +document_properties_keywords = Paròlle ciave: +document_properties_creation_date = Dæta creaçion: +document_properties_modification_date = Dæta cangiamento: +document_properties_date_string = {{date}}, {{time}} +document_properties_creator = Aotô originale: +document_properties_producer = Produtô PDF: +document_properties_version = Verscion PDF: +document_properties_page_count = Contezzo pagine: +document_properties_close = Særa + +hand_tool_enable.title = Ativa strumento man +hand_tool_enable_label = Ativa strumento man +hand_tool_disable.title = Dizativa strumento man +hand_tool_disable_label = Dizativa strumento man +attachments.title = Fanni vedde alegæ +attachments_label = Alegæ +page_scale_percent = {{scale}}% +unexpected_response_error = Risposta inprevista do-u server + + + + diff --git a/static/pdf.js/locale/lo/viewer.ftl b/static/pdf.js/locale/lo/viewer.ftl deleted file mode 100644 index fdad16ad..00000000 --- a/static/pdf.js/locale/lo/viewer.ftl +++ /dev/null @@ -1,299 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = ຫນ້າກ່ອນຫນ້າ -pdfjs-previous-button-label = ກ່ອນຫນ້າ -pdfjs-next-button = - .title = ຫນ້າຖັດໄປ -pdfjs-next-button-label = ຖັດໄປ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = ຫນ້າ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = ຈາກ { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } ຈາກ { $pagesCount }) -pdfjs-zoom-out-button = - .title = ຂະຫຍາຍອອກ -pdfjs-zoom-out-button-label = ຂະຫຍາຍອອກ -pdfjs-zoom-in-button = - .title = ຂະຫຍາຍເຂົ້າ -pdfjs-zoom-in-button-label = ຂະຫຍາຍເຂົ້າ -pdfjs-zoom-select = - .title = ຂະຫຍາຍ -pdfjs-presentation-mode-button = - .title = ສັບປ່ຽນເປັນໂຫມດການນຳສະເຫນີ -pdfjs-presentation-mode-button-label = ໂຫມດການນຳສະເຫນີ -pdfjs-open-file-button = - .title = ເປີດໄຟລ໌ -pdfjs-open-file-button-label = ເປີດ -pdfjs-print-button = - .title = ພິມ -pdfjs-print-button-label = ພິມ -pdfjs-save-button = - .title = ບັນທຶກ -pdfjs-save-button-label = ບັນທຶກ -pdfjs-bookmark-button = - .title = ໜ້າປັດຈຸບັນ (ເບິ່ງ URL ຈາກໜ້າປັດຈຸບັນ) -pdfjs-bookmark-button-label = ຫນ້າ​ປັດ​ຈຸ​ບັນ -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = ເປີດໃນ App -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = ເປີດໃນ App - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ເຄື່ອງມື -pdfjs-tools-button-label = ເຄື່ອງມື -pdfjs-first-page-button = - .title = ໄປທີ່ຫນ້າທຳອິດ -pdfjs-first-page-button-label = ໄປທີ່ຫນ້າທຳອິດ -pdfjs-last-page-button = - .title = ໄປທີ່ຫນ້າສຸດທ້າຍ -pdfjs-last-page-button-label = ໄປທີ່ຫນ້າສຸດທ້າຍ -pdfjs-page-rotate-cw-button = - .title = ຫມູນຕາມເຂັມໂມງ -pdfjs-page-rotate-cw-button-label = ຫມູນຕາມເຂັມໂມງ -pdfjs-page-rotate-ccw-button = - .title = ຫມູນທວນເຂັມໂມງ -pdfjs-page-rotate-ccw-button-label = ຫມູນທວນເຂັມໂມງ -pdfjs-cursor-text-select-tool-button = - .title = ເປີດໃຊ້ເຄື່ອງມືການເລືອກຂໍ້ຄວາມ -pdfjs-cursor-text-select-tool-button-label = ເຄື່ອງມືເລືອກຂໍ້ຄວາມ -pdfjs-cursor-hand-tool-button = - .title = ເປີດໃຊ້ເຄື່ອງມືມື -pdfjs-cursor-hand-tool-button-label = ເຄື່ອງມືມື -pdfjs-scroll-page-button = - .title = ໃຊ້ການເລື່ອນໜ້າ -pdfjs-scroll-page-button-label = ເລື່ອນໜ້າ -pdfjs-scroll-vertical-button = - .title = ໃຊ້ການເລື່ອນແນວຕັ້ງ -pdfjs-scroll-vertical-button-label = ເລື່ອນແນວຕັ້ງ -pdfjs-scroll-horizontal-button = - .title = ໃຊ້ການເລື່ອນແນວນອນ -pdfjs-scroll-horizontal-button-label = ເລື່ອນແນວນອນ -pdfjs-scroll-wrapped-button = - .title = ໃຊ້ Wrapped Scrolling -pdfjs-scroll-wrapped-button-label = Wrapped Scrolling -pdfjs-spread-none-button = - .title = ບໍ່ຕ້ອງຮ່ວມການແຜ່ກະຈາຍຫນ້າ -pdfjs-spread-none-button-label = ບໍ່ມີການແຜ່ກະຈາຍ -pdfjs-spread-odd-button = - .title = ເຂົ້າຮ່ວມການແຜ່ກະຈາຍຫນ້າເລີ່ມຕົ້ນດ້ວຍຫນ້າເລກຄີກ -pdfjs-spread-odd-button-label = ການແຜ່ກະຈາຍຄີກ -pdfjs-spread-even-button = - .title = ເຂົ້າຮ່ວມການແຜ່ກະຈາຍຂອງຫນ້າເລີ່ມຕົ້ນດ້ວຍຫນ້າເລກຄູ່ -pdfjs-spread-even-button-label = ການແຜ່ກະຈາຍຄູ່ - -## Document properties dialog - -pdfjs-document-properties-button = - .title = ຄຸນສົມບັດເອກະສານ... -pdfjs-document-properties-button-label = ຄຸນສົມບັດເອກະສານ... -pdfjs-document-properties-file-name = ຊື່ໄຟລ໌: -pdfjs-document-properties-file-size = ຂະຫນາດໄຟລ໌: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } ໄບຕ໌) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } ໄບຕ໌) -pdfjs-document-properties-title = ຫົວຂໍ້: -pdfjs-document-properties-author = ຜູ້ຂຽນ: -pdfjs-document-properties-subject = ຫົວຂໍ້: -pdfjs-document-properties-keywords = ຄໍາທີ່ຕ້ອງການຄົ້ນຫາ: -pdfjs-document-properties-creation-date = ວັນທີສ້າງ: -pdfjs-document-properties-modification-date = ວັນທີແກ້ໄຂ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = ຜູ້ສ້າງ: -pdfjs-document-properties-producer = ຜູ້ຜະລິດ PDF: -pdfjs-document-properties-version = ເວີຊັ່ນ PDF: -pdfjs-document-properties-page-count = ຈຳນວນໜ້າ: -pdfjs-document-properties-page-size = ຂະໜາດໜ້າ: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = ລວງຕັ້ງ -pdfjs-document-properties-page-size-orientation-landscape = ລວງນອນ -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = ຈົດໝາຍ -pdfjs-document-properties-page-size-name-legal = ຂໍ້ກົດຫມາຍ - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = ມຸມມອງເວັບທີ່ໄວ: -pdfjs-document-properties-linearized-yes = ແມ່ນ -pdfjs-document-properties-linearized-no = ບໍ່ -pdfjs-document-properties-close-button = ປິດ - -## Print - -pdfjs-print-progress-message = ກຳລັງກະກຽມເອກະສານສຳລັບການພິມ... -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = ຍົກເລີກ -pdfjs-printing-not-supported = ຄຳເຕືອນ: ບຼາວເຊີນີ້ບໍ່ຮອງຮັບການພິມຢ່າງເຕັມທີ່. -pdfjs-printing-not-ready = ຄໍາ​ເຕືອນ​: PDF ບໍ່​ໄດ້​ຖືກ​ໂຫຼດ​ຢ່າງ​ເຕັມ​ທີ່​ສໍາ​ລັບ​ການ​ພິມ​. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = ເປີດ/ປິດແຖບຂ້າງ -pdfjs-toggle-sidebar-notification-button = - .title = ສະຫຼັບແຖບດ້ານຂ້າງ (ເອກະສານປະກອບມີໂຄງຮ່າງ/ໄຟລ໌ແນບ/ຊັ້ນຂໍ້ມູນ) -pdfjs-toggle-sidebar-button-label = ເປີດ/ປິດແຖບຂ້າງ -pdfjs-document-outline-button = - .title = ສະ​ແດງ​ໂຄງ​ຮ່າງ​ເອ​ກະ​ສານ (ກົດ​ສອງ​ຄັ້ງ​ເພື່ອ​ຂະ​ຫຍາຍ / ຫຍໍ້​ລາຍ​ການ​ທັງ​ຫມົດ​) -pdfjs-document-outline-button-label = ເຄົ້າຮ່າງເອກະສານ -pdfjs-attachments-button = - .title = ສະແດງໄຟລ໌ແນບ -pdfjs-attachments-button-label = ໄຟລ໌ແນບ -pdfjs-layers-button = - .title = ສະແດງຊັ້ນຂໍ້ມູນ (ຄລິກສອງເທື່ອເພື່ອຣີເຊັດຊັ້ນຂໍ້ມູນທັງໝົດໃຫ້ເປັນສະຖານະເລີ່ມຕົ້ນ) -pdfjs-layers-button-label = ຊັ້ນ -pdfjs-thumbs-button = - .title = ສະແດງຮູບຫຍໍ້ -pdfjs-thumbs-button-label = ຮູບຕົວຢ່າງ -pdfjs-current-outline-item-button = - .title = ຊອກຫາລາຍການໂຄງຮ່າງປະຈຸບັນ -pdfjs-current-outline-item-button-label = ລາຍການໂຄງຮ່າງປະຈຸບັນ -pdfjs-findbar-button = - .title = ຊອກຫາໃນເອກະສານ -pdfjs-findbar-button-label = ຄົ້ນຫາ -pdfjs-additional-layers = ຊັ້ນຂໍ້ມູນເພີ່ມເຕີມ - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = ໜ້າ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = ຮູບຕົວຢ່າງຂອງໜ້າ { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = ຄົ້ນຫາ - .placeholder = ຊອກຫາໃນເອກະສານ... -pdfjs-find-previous-button = - .title = ຊອກຫາການປະກົດຕົວທີ່ຜ່ານມາຂອງປະໂຫຍກ -pdfjs-find-previous-button-label = ກ່ອນຫນ້ານີ້ -pdfjs-find-next-button = - .title = ຊອກຫາຕຳແຫນ່ງຖັດໄປຂອງວະລີ -pdfjs-find-next-button-label = ຕໍ່ໄປ -pdfjs-find-highlight-checkbox = ໄຮໄລທ໌ທັງຫມົດ -pdfjs-find-match-case-checkbox-label = ກໍລະນີທີ່ກົງກັນ -pdfjs-find-match-diacritics-checkbox-label = ເຄື່ອງໝາຍກຳກັບການອອກສຽງກົງກັນ -pdfjs-find-entire-word-checkbox-label = ກົງກັນທຸກຄຳ -pdfjs-find-reached-top = ມາຮອດເທິງຂອງເອກະສານ, ສືບຕໍ່ຈາກລຸ່ມ -pdfjs-find-reached-bottom = ຮອດຕອນທ້າຍຂອງເອກະສານ, ສືບຕໍ່ຈາກເທິງ -pdfjs-find-not-found = ບໍ່ພົບວະລີທີ່ຕ້ອງການ - -## Predefined zoom values - -pdfjs-page-scale-width = ຄວາມກວ້າງໜ້າ -pdfjs-page-scale-fit = ໜ້າພໍດີ -pdfjs-page-scale-auto = ຊູມອັດຕະໂນມັດ -pdfjs-page-scale-actual = ຂະໜາດຕົວຈິງ -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = ໜ້າ { $page } - -## Loading indicator messages - -pdfjs-loading-error = ມີຂໍ້ຜິດພາດເກີດຂື້ນຂະນະທີ່ກຳລັງໂຫລດ PDF. -pdfjs-invalid-file-error = ໄຟລ໌ PDF ບໍ່ຖືກຕ້ອງຫລືເສຍຫາຍ. -pdfjs-missing-file-error = ບໍ່ມີໄຟລ໌ PDF. -pdfjs-unexpected-response-error = ການຕອບສະໜອງຂອງເຊີບເວີທີ່ບໍ່ຄາດຄິດ. -pdfjs-rendering-error = ມີຂໍ້ຜິດພາດເກີດຂື້ນຂະນະທີ່ກຳລັງເຣັນເດີຫນ້າ. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } ຄຳບັນຍາຍ] - -## Password - -pdfjs-password-label = ໃສ່ລະຫັດຜ່ານເພື່ອເປີດໄຟລ໌ PDF ນີ້. -pdfjs-password-invalid = ລະຫັດຜ່ານບໍ່ຖືກຕ້ອງ. ກະລຸນາລອງອີກຄັ້ງ. -pdfjs-password-ok-button = ຕົກລົງ -pdfjs-password-cancel-button = ຍົກເລີກ -pdfjs-web-fonts-disabled = ຟອນເວັບຖືກປິດໃຊ້ງານ: ບໍ່ສາມາດໃຊ້ຟອນ PDF ທີ່ຝັງໄວ້ໄດ້. - -## Editing - -pdfjs-editor-free-text-button = - .title = ຂໍ້ຄວາມ -pdfjs-editor-free-text-button-label = ຂໍ້ຄວາມ -pdfjs-editor-ink-button = - .title = ແຕ້ມ -pdfjs-editor-ink-button-label = ແຕ້ມ -# Editor Parameters -pdfjs-editor-free-text-color-input = ສີ -pdfjs-editor-free-text-size-input = ຂະຫນາດ -pdfjs-editor-ink-color-input = ສີ -pdfjs-editor-ink-thickness-input = ຄວາມຫນາ -pdfjs-editor-ink-opacity-input = ຄວາມໂປ່ງໃສ -pdfjs-free-text = - .aria-label = ຕົວແກ້ໄຂຂໍ້ຄວາມ -pdfjs-free-text-default-content = ເລີ່ມພິມ... -pdfjs-ink = - .aria-label = ຕົວແກ້ໄຂຮູບແຕ້ມ -pdfjs-ink-canvas = - .aria-label = ຮູບພາບທີ່ຜູ້ໃຊ້ສ້າງ - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/locale.json b/static/pdf.js/locale/locale.json deleted file mode 100644 index 20122111..00000000 --- a/static/pdf.js/locale/locale.json +++ /dev/null @@ -1 +0,0 @@ -{"ach":"ach/viewer.ftl","af":"af/viewer.ftl","an":"an/viewer.ftl","ar":"ar/viewer.ftl","ast":"ast/viewer.ftl","az":"az/viewer.ftl","be":"be/viewer.ftl","bg":"bg/viewer.ftl","bn":"bn/viewer.ftl","bo":"bo/viewer.ftl","br":"br/viewer.ftl","brx":"brx/viewer.ftl","bs":"bs/viewer.ftl","ca":"ca/viewer.ftl","cak":"cak/viewer.ftl","ckb":"ckb/viewer.ftl","cs":"cs/viewer.ftl","cy":"cy/viewer.ftl","da":"da/viewer.ftl","de":"de/viewer.ftl","dsb":"dsb/viewer.ftl","el":"el/viewer.ftl","en-ca":"en-CA/viewer.ftl","en-gb":"en-GB/viewer.ftl","en-us":"en-US/viewer.ftl","eo":"eo/viewer.ftl","es-ar":"es-AR/viewer.ftl","es-cl":"es-CL/viewer.ftl","es-es":"es-ES/viewer.ftl","es-mx":"es-MX/viewer.ftl","et":"et/viewer.ftl","eu":"eu/viewer.ftl","fa":"fa/viewer.ftl","ff":"ff/viewer.ftl","fi":"fi/viewer.ftl","fr":"fr/viewer.ftl","fur":"fur/viewer.ftl","fy-nl":"fy-NL/viewer.ftl","ga-ie":"ga-IE/viewer.ftl","gd":"gd/viewer.ftl","gl":"gl/viewer.ftl","gn":"gn/viewer.ftl","gu-in":"gu-IN/viewer.ftl","he":"he/viewer.ftl","hi-in":"hi-IN/viewer.ftl","hr":"hr/viewer.ftl","hsb":"hsb/viewer.ftl","hu":"hu/viewer.ftl","hy-am":"hy-AM/viewer.ftl","hye":"hye/viewer.ftl","ia":"ia/viewer.ftl","id":"id/viewer.ftl","is":"is/viewer.ftl","it":"it/viewer.ftl","ja":"ja/viewer.ftl","ka":"ka/viewer.ftl","kab":"kab/viewer.ftl","kk":"kk/viewer.ftl","km":"km/viewer.ftl","kn":"kn/viewer.ftl","ko":"ko/viewer.ftl","lij":"lij/viewer.ftl","lo":"lo/viewer.ftl","lt":"lt/viewer.ftl","ltg":"ltg/viewer.ftl","lv":"lv/viewer.ftl","meh":"meh/viewer.ftl","mk":"mk/viewer.ftl","mr":"mr/viewer.ftl","ms":"ms/viewer.ftl","my":"my/viewer.ftl","nb-no":"nb-NO/viewer.ftl","ne-np":"ne-NP/viewer.ftl","nl":"nl/viewer.ftl","nn-no":"nn-NO/viewer.ftl","oc":"oc/viewer.ftl","pa-in":"pa-IN/viewer.ftl","pl":"pl/viewer.ftl","pt-br":"pt-BR/viewer.ftl","pt-pt":"pt-PT/viewer.ftl","rm":"rm/viewer.ftl","ro":"ro/viewer.ftl","ru":"ru/viewer.ftl","sat":"sat/viewer.ftl","sc":"sc/viewer.ftl","scn":"scn/viewer.ftl","sco":"sco/viewer.ftl","si":"si/viewer.ftl","sk":"sk/viewer.ftl","skr":"skr/viewer.ftl","sl":"sl/viewer.ftl","son":"son/viewer.ftl","sq":"sq/viewer.ftl","sr":"sr/viewer.ftl","sv-se":"sv-SE/viewer.ftl","szl":"szl/viewer.ftl","ta":"ta/viewer.ftl","te":"te/viewer.ftl","tg":"tg/viewer.ftl","th":"th/viewer.ftl","tl":"tl/viewer.ftl","tr":"tr/viewer.ftl","trs":"trs/viewer.ftl","uk":"uk/viewer.ftl","ur":"ur/viewer.ftl","uz":"uz/viewer.ftl","vi":"vi/viewer.ftl","wo":"wo/viewer.ftl","xh":"xh/viewer.ftl","zh-cn":"zh-CN/viewer.ftl","zh-tw":"zh-TW/viewer.ftl"} \ No newline at end of file diff --git a/static/pdf.js/locale/locale.properties b/static/pdf.js/locale/locale.properties new file mode 100644 index 00000000..9aded1b5 --- /dev/null +++ b/static/pdf.js/locale/locale.properties @@ -0,0 +1,312 @@ +[ach] +@import url(ach/viewer.properties) + +[af] +@import url(af/viewer.properties) + +[ak] +@import url(ak/viewer.properties) + +[an] +@import url(an/viewer.properties) + +[ar] +@import url(ar/viewer.properties) + +[as] +@import url(as/viewer.properties) + +[ast] +@import url(ast/viewer.properties) + +[az] +@import url(az/viewer.properties) + +[be] +@import url(be/viewer.properties) + +[bg] +@import url(bg/viewer.properties) + +[bn-BD] +@import url(bn-BD/viewer.properties) + +[bn-IN] +@import url(bn-IN/viewer.properties) + +[br] +@import url(br/viewer.properties) + +[bs] +@import url(bs/viewer.properties) + +[ca] +@import url(ca/viewer.properties) + +[cs] +@import url(cs/viewer.properties) + +[csb] +@import url(csb/viewer.properties) + +[cy] +@import url(cy/viewer.properties) + +[da] +@import url(da/viewer.properties) + +[de] +@import url(de/viewer.properties) + +[el] +@import url(el/viewer.properties) + +[en-GB] +@import url(en-GB/viewer.properties) + +[en-US] +@import url(en-US/viewer.properties) + +[en-ZA] +@import url(en-ZA/viewer.properties) + +[eo] +@import url(eo/viewer.properties) + +[es-AR] +@import url(es-AR/viewer.properties) + +[es-CL] +@import url(es-CL/viewer.properties) + +[es-ES] +@import url(es-ES/viewer.properties) + +[es-MX] +@import url(es-MX/viewer.properties) + +[et] +@import url(et/viewer.properties) + +[eu] +@import url(eu/viewer.properties) + +[fa] +@import url(fa/viewer.properties) + +[ff] +@import url(ff/viewer.properties) + +[fi] +@import url(fi/viewer.properties) + +[fr] +@import url(fr/viewer.properties) + +[fy-NL] +@import url(fy-NL/viewer.properties) + +[ga-IE] +@import url(ga-IE/viewer.properties) + +[gd] +@import url(gd/viewer.properties) + +[gl] +@import url(gl/viewer.properties) + +[gu-IN] +@import url(gu-IN/viewer.properties) + +[he] +@import url(he/viewer.properties) + +[hi-IN] +@import url(hi-IN/viewer.properties) + +[hr] +@import url(hr/viewer.properties) + +[hu] +@import url(hu/viewer.properties) + +[hy-AM] +@import url(hy-AM/viewer.properties) + +[id] +@import url(id/viewer.properties) + +[is] +@import url(is/viewer.properties) + +[it] +@import url(it/viewer.properties) + +[ja] +@import url(ja/viewer.properties) + +[ka] +@import url(ka/viewer.properties) + +[kk] +@import url(kk/viewer.properties) + +[km] +@import url(km/viewer.properties) + +[kn] +@import url(kn/viewer.properties) + +[ko] +@import url(ko/viewer.properties) + +[ku] +@import url(ku/viewer.properties) + +[lg] +@import url(lg/viewer.properties) + +[lij] +@import url(lij/viewer.properties) + +[lt] +@import url(lt/viewer.properties) + +[lv] +@import url(lv/viewer.properties) + +[mai] +@import url(mai/viewer.properties) + +[mk] +@import url(mk/viewer.properties) + +[ml] +@import url(ml/viewer.properties) + +[mn] +@import url(mn/viewer.properties) + +[mr] +@import url(mr/viewer.properties) + +[ms] +@import url(ms/viewer.properties) + +[my] +@import url(my/viewer.properties) + +[nb-NO] +@import url(nb-NO/viewer.properties) + +[nl] +@import url(nl/viewer.properties) + +[nn-NO] +@import url(nn-NO/viewer.properties) + +[nso] +@import url(nso/viewer.properties) + +[oc] +@import url(oc/viewer.properties) + +[or] +@import url(or/viewer.properties) + +[pa-IN] +@import url(pa-IN/viewer.properties) + +[pl] +@import url(pl/viewer.properties) + +[pt-BR] +@import url(pt-BR/viewer.properties) + +[pt-PT] +@import url(pt-PT/viewer.properties) + +[rm] +@import url(rm/viewer.properties) + +[ro] +@import url(ro/viewer.properties) + +[ru] +@import url(ru/viewer.properties) + +[rw] +@import url(rw/viewer.properties) + +[sah] +@import url(sah/viewer.properties) + +[si] +@import url(si/viewer.properties) + +[sk] +@import url(sk/viewer.properties) + +[sl] +@import url(sl/viewer.properties) + +[son] +@import url(son/viewer.properties) + +[sq] +@import url(sq/viewer.properties) + +[sr] +@import url(sr/viewer.properties) + +[sv-SE] +@import url(sv-SE/viewer.properties) + +[sw] +@import url(sw/viewer.properties) + +[ta] +@import url(ta/viewer.properties) + +[ta-LK] +@import url(ta-LK/viewer.properties) + +[te] +@import url(te/viewer.properties) + +[th] +@import url(th/viewer.properties) + +[tl] +@import url(tl/viewer.properties) + +[tn] +@import url(tn/viewer.properties) + +[tr] +@import url(tr/viewer.properties) + +[uk] +@import url(uk/viewer.properties) + +[ur] +@import url(ur/viewer.properties) + +[vi] +@import url(vi/viewer.properties) + +[wo] +@import url(wo/viewer.properties) + +[xh] +@import url(xh/viewer.properties) + +[zh-CN] +@import url(zh-CN/viewer.properties) + +[zh-TW] +@import url(zh-TW/viewer.properties) + +[zu] +@import url(zu/viewer.properties) + diff --git a/static/pdf.js/locale/lt/viewer.ftl b/static/pdf.js/locale/lt/viewer.ftl deleted file mode 100644 index a8ee7a08..00000000 --- a/static/pdf.js/locale/lt/viewer.ftl +++ /dev/null @@ -1,268 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Ankstesnis puslapis -pdfjs-previous-button-label = Ankstesnis -pdfjs-next-button = - .title = Kitas puslapis -pdfjs-next-button-label = Kitas -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Puslapis -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = iš { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } iš { $pagesCount }) -pdfjs-zoom-out-button = - .title = Sumažinti -pdfjs-zoom-out-button-label = Sumažinti -pdfjs-zoom-in-button = - .title = Padidinti -pdfjs-zoom-in-button-label = Padidinti -pdfjs-zoom-select = - .title = Mastelis -pdfjs-presentation-mode-button = - .title = Pereiti į pateikties veikseną -pdfjs-presentation-mode-button-label = Pateikties veiksena -pdfjs-open-file-button = - .title = Atverti failą -pdfjs-open-file-button-label = Atverti -pdfjs-print-button = - .title = Spausdinti -pdfjs-print-button-label = Spausdinti - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Priemonės -pdfjs-tools-button-label = Priemonės -pdfjs-first-page-button = - .title = Eiti į pirmą puslapį -pdfjs-first-page-button-label = Eiti į pirmą puslapį -pdfjs-last-page-button = - .title = Eiti į paskutinį puslapį -pdfjs-last-page-button-label = Eiti į paskutinį puslapį -pdfjs-page-rotate-cw-button = - .title = Pasukti pagal laikrodžio rodyklę -pdfjs-page-rotate-cw-button-label = Pasukti pagal laikrodžio rodyklę -pdfjs-page-rotate-ccw-button = - .title = Pasukti prieš laikrodžio rodyklę -pdfjs-page-rotate-ccw-button-label = Pasukti prieš laikrodžio rodyklę -pdfjs-cursor-text-select-tool-button = - .title = Įjungti teksto žymėjimo įrankį -pdfjs-cursor-text-select-tool-button-label = Teksto žymėjimo įrankis -pdfjs-cursor-hand-tool-button = - .title = Įjungti vilkimo įrankį -pdfjs-cursor-hand-tool-button-label = Vilkimo įrankis -pdfjs-scroll-page-button = - .title = Naudoti puslapio slinkimą -pdfjs-scroll-page-button-label = Puslapio slinkimas -pdfjs-scroll-vertical-button = - .title = Naudoti vertikalų slinkimą -pdfjs-scroll-vertical-button-label = Vertikalus slinkimas -pdfjs-scroll-horizontal-button = - .title = Naudoti horizontalų slinkimą -pdfjs-scroll-horizontal-button-label = Horizontalus slinkimas -pdfjs-scroll-wrapped-button = - .title = Naudoti išklotą slinkimą -pdfjs-scroll-wrapped-button-label = Išklotas slinkimas -pdfjs-spread-none-button = - .title = Nejungti puslapių į dvilapius -pdfjs-spread-none-button-label = Be dvilapių -pdfjs-spread-odd-button = - .title = Sujungti į dvilapius pradedant nelyginiais puslapiais -pdfjs-spread-odd-button-label = Nelyginiai dvilapiai -pdfjs-spread-even-button = - .title = Sujungti į dvilapius pradedant lyginiais puslapiais -pdfjs-spread-even-button-label = Lyginiai dvilapiai - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumento savybės… -pdfjs-document-properties-button-label = Dokumento savybės… -pdfjs-document-properties-file-name = Failo vardas: -pdfjs-document-properties-file-size = Failo dydis: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } B) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } B) -pdfjs-document-properties-title = Antraštė: -pdfjs-document-properties-author = Autorius: -pdfjs-document-properties-subject = Tema: -pdfjs-document-properties-keywords = Reikšminiai žodžiai: -pdfjs-document-properties-creation-date = Sukūrimo data: -pdfjs-document-properties-modification-date = Modifikavimo data: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Kūrėjas: -pdfjs-document-properties-producer = PDF generatorius: -pdfjs-document-properties-version = PDF versija: -pdfjs-document-properties-page-count = Puslapių skaičius: -pdfjs-document-properties-page-size = Puslapio dydis: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = stačias -pdfjs-document-properties-page-size-orientation-landscape = gulsčias -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Laiškas -pdfjs-document-properties-page-size-name-legal = Dokumentas - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Spartus žiniatinklio rodinys: -pdfjs-document-properties-linearized-yes = Taip -pdfjs-document-properties-linearized-no = Ne -pdfjs-document-properties-close-button = Užverti - -## Print - -pdfjs-print-progress-message = Dokumentas ruošiamas spausdinimui… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Atsisakyti -pdfjs-printing-not-supported = Dėmesio! Spausdinimas šioje naršyklėje nėra pilnai realizuotas. -pdfjs-printing-not-ready = Dėmesio! PDF failas dar nėra pilnai įkeltas spausdinimui. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Rodyti / slėpti šoninį polangį -pdfjs-toggle-sidebar-notification-button = - .title = Parankinė (dokumentas turi struktūrą / priedų / sluoksnių) -pdfjs-toggle-sidebar-button-label = Šoninis polangis -pdfjs-document-outline-button = - .title = Rodyti dokumento struktūrą (spustelėkite dukart norėdami išplėsti/suskleisti visus elementus) -pdfjs-document-outline-button-label = Dokumento struktūra -pdfjs-attachments-button = - .title = Rodyti priedus -pdfjs-attachments-button-label = Priedai -pdfjs-layers-button = - .title = Rodyti sluoksnius (spustelėkite dukart, norėdami atstatyti visus sluoksnius į numatytąją būseną) -pdfjs-layers-button-label = Sluoksniai -pdfjs-thumbs-button = - .title = Rodyti puslapių miniatiūras -pdfjs-thumbs-button-label = Miniatiūros -pdfjs-current-outline-item-button = - .title = Rasti dabartinį struktūros elementą -pdfjs-current-outline-item-button-label = Dabartinis struktūros elementas -pdfjs-findbar-button = - .title = Ieškoti dokumente -pdfjs-findbar-button-label = Rasti -pdfjs-additional-layers = Papildomi sluoksniai - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page } puslapis -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } puslapio miniatiūra - -## Find panel button title and messages - -pdfjs-find-input = - .title = Rasti - .placeholder = Rasti dokumente… -pdfjs-find-previous-button = - .title = Ieškoti ankstesnio frazės egzemplioriaus -pdfjs-find-previous-button-label = Ankstesnis -pdfjs-find-next-button = - .title = Ieškoti tolesnio frazės egzemplioriaus -pdfjs-find-next-button-label = Tolesnis -pdfjs-find-highlight-checkbox = Viską paryškinti -pdfjs-find-match-case-checkbox-label = Skirti didžiąsias ir mažąsias raides -pdfjs-find-match-diacritics-checkbox-label = Skirti diakritinius ženklus -pdfjs-find-entire-word-checkbox-label = Ištisi žodžiai -pdfjs-find-reached-top = Pasiekus dokumento pradžią, paieška pratęsta nuo pabaigos -pdfjs-find-reached-bottom = Pasiekus dokumento pabaigą, paieška pratęsta nuo pradžios -pdfjs-find-not-found = Ieškoma frazė nerasta - -## Predefined zoom values - -pdfjs-page-scale-width = Priderinti prie lapo pločio -pdfjs-page-scale-fit = Pritaikyti prie lapo dydžio -pdfjs-page-scale-auto = Automatinis mastelis -pdfjs-page-scale-actual = Tikras dydis -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = { $page } puslapis - -## Loading indicator messages - -pdfjs-loading-error = Įkeliant PDF failą įvyko klaida. -pdfjs-invalid-file-error = Tai nėra PDF failas arba jis yra sugadintas. -pdfjs-missing-file-error = PDF failas nerastas. -pdfjs-unexpected-response-error = Netikėtas serverio atsakas. -pdfjs-rendering-error = Atvaizduojant puslapį įvyko klaida. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [„{ $type }“ tipo anotacija] - -## Password - -pdfjs-password-label = Įveskite slaptažodį šiam PDF failui atverti. -pdfjs-password-invalid = Slaptažodis neteisingas. Bandykite dar kartą. -pdfjs-password-ok-button = Gerai -pdfjs-password-cancel-button = Atsisakyti -pdfjs-web-fonts-disabled = Saityno šriftai išjungti – PDF faile esančių šriftų naudoti negalima. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/lt/viewer.properties b/static/pdf.js/locale/lt/viewer.properties new file mode 100644 index 00000000..e2f50b9c --- /dev/null +++ b/static/pdf.js/locale/lt/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Ankstesnis puslapis +previous_label=Ankstesnis +next.title=Kitas puslapis +next_label=Kitas + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Puslapis: +page_of=iš {{pageCount}} + +zoom_out.title=Sumažinti +zoom_out_label=Sumažinti +zoom_in.title=Padidinti +zoom_in_label=Padidinti +zoom.title=Mastelis +presentation_mode.title=Pereiti į pateikties veikseną +presentation_mode_label=Pateikties veiksena +open_file.title=Atverti failą +open_file_label=Atverti +print.title=Spausdinti +print_label=Spausdinti +download.title=Parsiųsti +download_label=Parsiųsti +bookmark.title=Esamojo rodinio saitas (kopijavimui ar atvėrimui kitame lange) +bookmark_label=Esamasis rodinys + +# Secondary toolbar and context menu +tools.title=Priemonės +tools_label=Priemonės +first_page.title=Eiti į pirmą puslapį +first_page.label=Eiti į pirmą puslapį +first_page_label=Eiti į pirmą puslapį +last_page.title=Eiti į paskutinį puslapį +last_page.label=Eiti į paskutinį puslapį +last_page_label=Eiti į paskutinį puslapį +page_rotate_cw.title=Pasukti pagal laikrodžio rodyklę +page_rotate_cw.label=Pasukti pagal laikrodžio rodyklę +page_rotate_cw_label=Pasukti pagal laikrodžio rodyklę +page_rotate_ccw.title=Pasukti prieš laikrodžio rodyklę +page_rotate_ccw.label=Pasukti prieš laikrodžio rodyklę +page_rotate_ccw_label=Pasukti prieš laikrodžio rodyklę + +hand_tool_enable.title=Įgalinti vilkimo veikseną +hand_tool_enable_label=Įgalinti vilkimo veikseną +hand_tool_disable.title=Išjungti vilkimo veikseną +hand_tool_disable_label=Išjungti vilkimo veikseną + +# Document properties dialog box +document_properties.title=Dokumento savybės… +document_properties_label=Dokumento savybės… +document_properties_file_name=Failo vardas: +document_properties_file_size=Failo dydis: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} B) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} B) +document_properties_title=Antraštė: +document_properties_author=Autorius: +document_properties_subject=Tema: +document_properties_keywords=Reikšminiai žodžiai: +document_properties_creation_date=Sukūrimo data: +document_properties_modification_date=Modifikavimo data: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Kūrėjas: +document_properties_producer=PDF generatorius: +document_properties_version=PDF versija: +document_properties_page_count=Puslapių skaičius: +document_properties_close=Užverti + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Rodyti / slėpti šoninį polangį +toggle_sidebar_label=Šoninis polangis +outline.title=Rodyti dokumento metmenis +outline_label=Dokumento metmenys +attachments.title=Rodyti priedus +attachments_label=Priedai +thumbs.title=Rodyti puslapių miniatiūras +thumbs_label=Miniatiūros +findbar.title=Ieškoti dokumente +findbar_label=Ieškoti + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title={{page}} puslapis +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}} puslapio miniatiūra + +# Find panel button title and messages +find_label=Ieškoti: +find_previous.title=Ieškoti ankstesnio frazės egzemplioriaus +find_previous_label=Ankstesnis +find_next.title=Ieškoti tolesnio frazės egzemplioriaus +find_next_label=Tolesnis +find_highlight=Viską paryškinti +find_match_case_label=Skirti didžiąsias ir mažąsias raides +find_reached_top=Pasiekus dokumento pradžią, paieška pratęsta nuo pabaigos +find_reached_bottom=Pasiekus dokumento pabaigą, paieška pratęsta nuo pradžios +find_not_found=Ieškoma frazė nerasta + +# Error panel labels +error_more_info=Išsamiau +error_less_info=Glausčiau +error_close=Užverti +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v. {{version}} (darinys: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Pranešimas: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Dėklas: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Failas: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Eilutė: {{line}} +rendering_error=Atvaizduojant puslapį, įvyko klaida. + +# Predefined zoom values +page_scale_width=Priderinti prie lapo pločio +page_scale_fit=Pritaikyti prie lapo dydžio +page_scale_auto=Automatinis mastelis +page_scale_actual=Tikras dydis +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Klaida +loading_error=Įkeliant PDF failą, įvyko klaida. +invalid_file_error=Tai nėra PDF failas arba jis yra sugadintas. +missing_file_error=PDF failas nerastas. +unexpected_response_error=Netikėtas serverio atsakas. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[„{{type}}“ tipo anotacija] +password_label=Įveskite slaptažodį šiam PDF failui atverti. +password_invalid=Slaptažodis neteisingas. Bandykite dar kartą. +password_ok=Gerai +password_cancel=Atsisakyti + +printing_not_supported=Dėmesio! Spausdinimas šioje naršyklėje nėra pilnai realizuotas. +printing_not_ready=Dėmesio! PDF failas dar nėra pilnai įkeltas spausdinimui. +web_fonts_disabled=Neįgalinti saityno šriftai – šiame PDF faile esančių šriftų naudoti negalima. +document_colors_not_allowed=PDF dokumentams neleidžiama nurodyti savo spalvų, nes išjungta naršyklės nuostata „Leisti tinklalapiams nurodyti spalvas“. diff --git a/static/pdf.js/locale/ltg/viewer.ftl b/static/pdf.js/locale/ltg/viewer.ftl deleted file mode 100644 index d2621654..00000000 --- a/static/pdf.js/locale/ltg/viewer.ftl +++ /dev/null @@ -1,246 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Īprīkšejā lopa -pdfjs-previous-button-label = Īprīkšejā -pdfjs-next-button = - .title = Nuokomuo lopa -pdfjs-next-button-label = Nuokomuo -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Lopa -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = nu { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } nu { $pagesCount }) -pdfjs-zoom-out-button = - .title = Attuolynuot -pdfjs-zoom-out-button-label = Attuolynuot -pdfjs-zoom-in-button = - .title = Pītuvynuot -pdfjs-zoom-in-button-label = Pītuvynuot -pdfjs-zoom-select = - .title = Palelynuojums -pdfjs-presentation-mode-button = - .title = Puorslēgtīs iz Prezentacejis režymu -pdfjs-presentation-mode-button-label = Prezentacejis režyms -pdfjs-open-file-button = - .title = Attaiseit failu -pdfjs-open-file-button-label = Attaiseit -pdfjs-print-button = - .title = Drukuošona -pdfjs-print-button-label = Drukōt - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Reiki -pdfjs-tools-button-label = Reiki -pdfjs-first-page-button = - .title = Īt iz pyrmū lopu -pdfjs-first-page-button-label = Īt iz pyrmū lopu -pdfjs-last-page-button = - .title = Īt iz piedejū lopu -pdfjs-last-page-button-label = Īt iz piedejū lopu -pdfjs-page-rotate-cw-button = - .title = Pagrīzt pa pulksteni -pdfjs-page-rotate-cw-button-label = Pagrīzt pa pulksteni -pdfjs-page-rotate-ccw-button = - .title = Pagrīzt pret pulksteni -pdfjs-page-rotate-ccw-button-label = Pagrīzt pret pulksteni -pdfjs-cursor-text-select-tool-button = - .title = Aktivizēt teksta izvieles reiku -pdfjs-cursor-text-select-tool-button-label = Teksta izvieles reiks -pdfjs-cursor-hand-tool-button = - .title = Aktivēt rūkys reiku -pdfjs-cursor-hand-tool-button-label = Rūkys reiks -pdfjs-scroll-vertical-button = - .title = Izmontōt vertikalū ritinōšonu -pdfjs-scroll-vertical-button-label = Vertikalō ritinōšona -pdfjs-scroll-horizontal-button = - .title = Izmontōt horizontalū ritinōšonu -pdfjs-scroll-horizontal-button-label = Horizontalō ritinōšona -pdfjs-scroll-wrapped-button = - .title = Izmontōt mārūgojamū ritinōšonu -pdfjs-scroll-wrapped-button-label = Mārūgojamō ritinōšona -pdfjs-spread-none-button = - .title = Naizmontōt lopu atvāruma režimu -pdfjs-spread-none-button-label = Bez atvārumim -pdfjs-spread-odd-button = - .title = Izmontōt lopu atvārumus sōkut nu napōra numeru lopom -pdfjs-spread-odd-button-label = Napōra lopys pa kreisi -pdfjs-spread-even-button = - .title = Izmontōt lopu atvārumus sōkut nu pōra numeru lopom -pdfjs-spread-even-button-label = Pōra lopys pa kreisi - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumenta īstatiejumi… -pdfjs-document-properties-button-label = Dokumenta īstatiejumi… -pdfjs-document-properties-file-name = Faila nūsaukums: -pdfjs-document-properties-file-size = Faila izmārs: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } biti) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } biti) -pdfjs-document-properties-title = Nūsaukums: -pdfjs-document-properties-author = Autors: -pdfjs-document-properties-subject = Tema: -pdfjs-document-properties-keywords = Atslāgi vuordi: -pdfjs-document-properties-creation-date = Izveides datums: -pdfjs-document-properties-modification-date = lobuošonys datums: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Radeituojs: -pdfjs-document-properties-producer = PDF producents: -pdfjs-document-properties-version = PDF verseja: -pdfjs-document-properties-page-count = Lopu skaits: -pdfjs-document-properties-page-size = Lopas izmārs: -pdfjs-document-properties-page-size-unit-inches = collas -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portreta orientaceja -pdfjs-document-properties-page-size-orientation-landscape = ainovys orientaceja -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Jā -pdfjs-document-properties-linearized-no = Nā -pdfjs-document-properties-close-button = Aiztaiseit - -## Print - -pdfjs-print-progress-message = Preparing document for printing… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Atceļt -pdfjs-printing-not-supported = Uzmaneibu: Drukuošona nu itei puorlūka dorbojās tikai daleji. -pdfjs-printing-not-ready = Uzmaneibu: PDF nav pilneibā īluodeits drukuošonai. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Puorslēgt suonu jūslu -pdfjs-toggle-sidebar-button-label = Puorslēgt suonu jūslu -pdfjs-document-outline-button = - .title = Show Document Outline (double-click to expand/collapse all items) -pdfjs-document-outline-button-label = Dokumenta saturs -pdfjs-attachments-button = - .title = Show Attachments -pdfjs-attachments-button-label = Attachments -pdfjs-thumbs-button = - .title = Paruodeit seiktālus -pdfjs-thumbs-button-label = Seiktāli -pdfjs-findbar-button = - .title = Mekleit dokumentā -pdfjs-findbar-button-label = Mekleit - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Lopa { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Lopys { $page } seiktāls - -## Find panel button title and messages - -pdfjs-find-input = - .title = Mekleit - .placeholder = Mekleit dokumentā… -pdfjs-find-previous-button = - .title = Atrast īprīkšejū -pdfjs-find-previous-button-label = Īprīkšejā -pdfjs-find-next-button = - .title = Atrast nuokamū -pdfjs-find-next-button-label = Nuokomuo -pdfjs-find-highlight-checkbox = Īkruosuot vysys -pdfjs-find-match-case-checkbox-label = Lelū, mozū burtu jiuteigs -pdfjs-find-reached-top = Sasnīgts dokumenta suokums, turpynojom nu beigom -pdfjs-find-reached-bottom = Sasnīgtys dokumenta beigys, turpynojom nu suokuma -pdfjs-find-not-found = Frāze nav atrosta - -## Predefined zoom values - -pdfjs-page-scale-width = Lopys plotumā -pdfjs-page-scale-fit = Ītylpynūt lopu -pdfjs-page-scale-auto = Automatiskais izmārs -pdfjs-page-scale-actual = Patīsais izmārs -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Īluodejūt PDF nūtyka klaida. -pdfjs-invalid-file-error = Nadereigs voi būjuots PDF fails. -pdfjs-missing-file-error = PDF fails nav atrosts. -pdfjs-unexpected-response-error = Unexpected server response. -pdfjs-rendering-error = Attālojūt lopu rodās klaida - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Īvodit paroli, kab attaiseitu PDF failu. -pdfjs-password-invalid = Napareiza parole, raugit vēļreiz. -pdfjs-password-ok-button = Labi -pdfjs-password-cancel-button = Atceļt -pdfjs-web-fonts-disabled = Šķārsteikla fonti nav aktivizāti: Navar īgult PDF fontus. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/lv/viewer.ftl b/static/pdf.js/locale/lv/viewer.ftl deleted file mode 100644 index 067dc105..00000000 --- a/static/pdf.js/locale/lv/viewer.ftl +++ /dev/null @@ -1,247 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Iepriekšējā lapa -pdfjs-previous-button-label = Iepriekšējā -pdfjs-next-button = - .title = Nākamā lapa -pdfjs-next-button-label = Nākamā -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Lapa -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = no { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } no { $pagesCount }) -pdfjs-zoom-out-button = - .title = Attālināt -pdfjs-zoom-out-button-label = Attālināt -pdfjs-zoom-in-button = - .title = Pietuvināt -pdfjs-zoom-in-button-label = Pietuvināt -pdfjs-zoom-select = - .title = Palielinājums -pdfjs-presentation-mode-button = - .title = Pārslēgties uz Prezentācijas režīmu -pdfjs-presentation-mode-button-label = Prezentācijas režīms -pdfjs-open-file-button = - .title = Atvērt failu -pdfjs-open-file-button-label = Atvērt -pdfjs-print-button = - .title = Drukāšana -pdfjs-print-button-label = Drukāt - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Rīki -pdfjs-tools-button-label = Rīki -pdfjs-first-page-button = - .title = Iet uz pirmo lapu -pdfjs-first-page-button-label = Iet uz pirmo lapu -pdfjs-last-page-button = - .title = Iet uz pēdējo lapu -pdfjs-last-page-button-label = Iet uz pēdējo lapu -pdfjs-page-rotate-cw-button = - .title = Pagriezt pa pulksteni -pdfjs-page-rotate-cw-button-label = Pagriezt pa pulksteni -pdfjs-page-rotate-ccw-button = - .title = Pagriezt pret pulksteni -pdfjs-page-rotate-ccw-button-label = Pagriezt pret pulksteni -pdfjs-cursor-text-select-tool-button = - .title = Aktivizēt teksta izvēles rīku -pdfjs-cursor-text-select-tool-button-label = Teksta izvēles rīks -pdfjs-cursor-hand-tool-button = - .title = Aktivēt rokas rīku -pdfjs-cursor-hand-tool-button-label = Rokas rīks -pdfjs-scroll-vertical-button = - .title = Izmantot vertikālo ritināšanu -pdfjs-scroll-vertical-button-label = Vertikālā ritināšana -pdfjs-scroll-horizontal-button = - .title = Izmantot horizontālo ritināšanu -pdfjs-scroll-horizontal-button-label = Horizontālā ritināšana -pdfjs-scroll-wrapped-button = - .title = Izmantot apkļauto ritināšanu -pdfjs-scroll-wrapped-button-label = Apkļautā ritināšana -pdfjs-spread-none-button = - .title = Nepievienoties lapu izpletumiem -pdfjs-spread-none-button-label = Neizmantot izpletumus -pdfjs-spread-odd-button = - .title = Izmantot lapu izpletumus sākot ar nepāra numuru lapām -pdfjs-spread-odd-button-label = Nepāra izpletumi -pdfjs-spread-even-button = - .title = Izmantot lapu izpletumus sākot ar pāra numuru lapām -pdfjs-spread-even-button-label = Pāra izpletumi - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumenta iestatījumi… -pdfjs-document-properties-button-label = Dokumenta iestatījumi… -pdfjs-document-properties-file-name = Faila nosaukums: -pdfjs-document-properties-file-size = Faila izmērs: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } biti) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } biti) -pdfjs-document-properties-title = Nosaukums: -pdfjs-document-properties-author = Autors: -pdfjs-document-properties-subject = Tēma: -pdfjs-document-properties-keywords = Atslēgas vārdi: -pdfjs-document-properties-creation-date = Izveides datums: -pdfjs-document-properties-modification-date = LAbošanas datums: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Radītājs: -pdfjs-document-properties-producer = PDF producents: -pdfjs-document-properties-version = PDF versija: -pdfjs-document-properties-page-count = Lapu skaits: -pdfjs-document-properties-page-size = Papīra izmērs: -pdfjs-document-properties-page-size-unit-inches = collas -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portretorientācija -pdfjs-document-properties-page-size-orientation-landscape = ainavorientācija -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Vēstule -pdfjs-document-properties-page-size-name-legal = Juridiskie teksti - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Ātrā tīmekļa skats: -pdfjs-document-properties-linearized-yes = Jā -pdfjs-document-properties-linearized-no = Nē -pdfjs-document-properties-close-button = Aizvērt - -## Print - -pdfjs-print-progress-message = Gatavo dokumentu drukāšanai... -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Atcelt -pdfjs-printing-not-supported = Uzmanību: Drukāšana no šī pārlūka darbojas tikai daļēji. -pdfjs-printing-not-ready = Uzmanību: PDF nav pilnībā ielādēts drukāšanai. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Pārslēgt sānu joslu -pdfjs-toggle-sidebar-button-label = Pārslēgt sānu joslu -pdfjs-document-outline-button = - .title = Rādīt dokumenta struktūru (veiciet dubultklikšķi lai izvērstu/sakļautu visus vienumus) -pdfjs-document-outline-button-label = Dokumenta saturs -pdfjs-attachments-button = - .title = Rādīt pielikumus -pdfjs-attachments-button-label = Pielikumi -pdfjs-thumbs-button = - .title = Parādīt sīktēlus -pdfjs-thumbs-button-label = Sīktēli -pdfjs-findbar-button = - .title = Meklēt dokumentā -pdfjs-findbar-button-label = Meklēt - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Lapa { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Lapas { $page } sīktēls - -## Find panel button title and messages - -pdfjs-find-input = - .title = Meklēt - .placeholder = Meklēt dokumentā… -pdfjs-find-previous-button = - .title = Atrast iepriekšējo -pdfjs-find-previous-button-label = Iepriekšējā -pdfjs-find-next-button = - .title = Atrast nākamo -pdfjs-find-next-button-label = Nākamā -pdfjs-find-highlight-checkbox = Iekrāsot visas -pdfjs-find-match-case-checkbox-label = Lielo, mazo burtu jutīgs -pdfjs-find-entire-word-checkbox-label = Veselus vārdus -pdfjs-find-reached-top = Sasniegts dokumenta sākums, turpinām no beigām -pdfjs-find-reached-bottom = Sasniegtas dokumenta beigas, turpinām no sākuma -pdfjs-find-not-found = Frāze nav atrasta - -## Predefined zoom values - -pdfjs-page-scale-width = Lapas platumā -pdfjs-page-scale-fit = Ietilpinot lapu -pdfjs-page-scale-auto = Automātiskais izmērs -pdfjs-page-scale-actual = Patiesais izmērs -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Ielādējot PDF notika kļūda. -pdfjs-invalid-file-error = Nederīgs vai bojāts PDF fails. -pdfjs-missing-file-error = PDF fails nav atrasts. -pdfjs-unexpected-response-error = Negaidīa servera atbilde. -pdfjs-rendering-error = Attēlojot lapu radās kļūda - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } anotācija] - -## Password - -pdfjs-password-label = Ievadiet paroli, lai atvērtu PDF failu. -pdfjs-password-invalid = Nepareiza parole, mēģiniet vēlreiz. -pdfjs-password-ok-button = Labi -pdfjs-password-cancel-button = Atcelt -pdfjs-web-fonts-disabled = Tīmekļa fonti nav aktivizēti: Nevar iegult PDF fontus. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/lv/viewer.properties b/static/pdf.js/locale/lv/viewer.properties new file mode 100644 index 00000000..58aa9532 --- /dev/null +++ b/static/pdf.js/locale/lv/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Iepriekšējā lapa +previous_label=Iepriekšējā +next.title=Nākamā lapa +next_label=Nākamā + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Lapa: +page_of=no {{pageCount}} + +zoom_out.title=Attālināt\u0020 +zoom_out_label=Attālināt +zoom_in.title=Pietuvināt +zoom_in_label=Pietuvināt +zoom.title=Palielinājums +presentation_mode.title=Pārslēgties uz Prezentācijas režīmu +presentation_mode_label=Prezentācijas režīms +open_file.title=Atvērt failu +open_file_label=Atvērt +print.title=Drukāšana +print_label=Drukāt +download.title=Lejupielāde +download_label=Lejupielādēt +bookmark.title=Pašreizējais skats (kopēt vai atvērt jaunā logā) +bookmark_label=Pašreizējais skats + +# Secondary toolbar and context menu +tools.title=Rīki +tools_label=Rīki +first_page.title=Iet uz pirmo lapu +first_page.label=Iet uz pirmo lapu +first_page_label=Iet uz pirmo lapu +last_page.title=Iet uz pēdējo lapu +last_page.label=Iet uz pēdējo lapu +last_page_label=Iet uz pēdējo lapu +page_rotate_cw.title=Pagriezt pa pulksteni +page_rotate_cw.label=Pagriezt pa pulksteni +page_rotate_cw_label=Pagriezt pa pulksteni +page_rotate_ccw.title=Pagriezt pret pulksteni +page_rotate_ccw.label=Pagriezt pret pulksteni +page_rotate_ccw_label=Pagriezt pret pulksteni + +hand_tool_enable.title=Aktivēt rokas rīku +hand_tool_enable_label=Aktivēt rokas rīku +hand_tool_disable.title=Deaktivēt rokas rīku +hand_tool_disable_label=Deaktivēt rokas rīku + +# Document properties dialog box +document_properties.title=Dokumenta iestatījumi… +document_properties_label=Dokumenta iestatījumi… +document_properties_file_name=Faila nosaukums: +document_properties_file_size=Faila izmērs: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} biti) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} biti) +document_properties_title=Nosaukums: +document_properties_author=Autors: +document_properties_subject=Tēma: +document_properties_keywords=Atslēgas vārdi: +document_properties_creation_date=Izveides datums: +document_properties_modification_date=LAbošanas datums: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Radītājs: +document_properties_producer=PDF producents: +document_properties_version=PDF versija: +document_properties_page_count=Lapu skaits: +document_properties_close=Aizvērt + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Pārslēgt sānu joslu +toggle_sidebar_label=Pārslēgt sānu joslu +outline.title=Parādīt dokumenta saturu +outline_label=Dokumenta saturs +attachments.title=Rādīt pielikumus +attachments_label=Pielikumi +thumbs.title=Parādīt sīktēlus +thumbs_label=Sīktēli +findbar.title=Meklēt dokumentā +findbar_label=Meklēt + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Lapa {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Lapas {{page}} sīktēls + +# Find panel button title and messages +find_label=Meklēt: +find_previous.title=Atrast iepriekšējo +find_previous_label=Iepriekšējā +find_next.title=Atrast nākamo +find_next_label=Nākamā +find_highlight=Iekrāsot visas +find_match_case_label=Lielo, mazo burtu jutīgs +find_reached_top=Sasniegts dokumenta sākums, turpinām no beigām +find_reached_bottom=Sasniegtas dokumenta beigas, turpinām no sākuma +find_not_found=Frāze nav atrasta + +# Error panel labels +error_more_info=Vairāk informācijas +error_less_info=MAzāk informācijas +error_close=Close +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Ziņojums: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Steks: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=File: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rindiņa: {{line}} +rendering_error=Attēlojot lapu radās kļūda + +# Predefined zoom values +page_scale_width=Lapas platumā +page_scale_fit=Ietilpinot lapu +page_scale_auto=Automātiskais izmērs +page_scale_actual=Patiesais izmērs +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Kļūda +loading_error=Ielādējot PDF notika kļūda. +invalid_file_error=Nederīgs vai bojāts PDF fails. +missing_file_error=PDF fails nav atrasts. +unexpected_response_error=Negaidīa servera atbilde. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} anotācija] +password_label=Ievadiet paroli, lai atvērtu PDF failu. +password_invalid=Nepareiza parole, mēģiniet vēlreiz. +password_ok=Labi +password_cancel=Atcelt + +printing_not_supported=Uzmanību: Drukāšana no šī pārlūka darbojas tikai daļēji. +printing_not_ready=Uzmanību: PDF nav pilnībā ielādēts drukāšanai. +web_fonts_disabled=Tīmekļa fonti nav aktivizēti: Nevar iegult PDF fontus. +document_colors_not_allowed=PDF dokumentiem nav atļauts izmantot pašiem savas krāsas: „Atļaut lapām izvēlēties pašām savas krāsas“ ir deaktivēts pārlūkā. diff --git a/static/pdf.js/locale/mai/viewer.properties b/static/pdf.js/locale/mai/viewer.properties new file mode 100644 index 00000000..4eb0b17a --- /dev/null +++ b/static/pdf.js/locale/mai/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=पछिला पृष्ठ +previous_label=पछिला +next.title=अगिला पृष्ठ +next_label=आगाँ + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=पृष्ठ: +page_of={{pageCount}} क + +zoom_out.title=छोट करू +zoom_out_label=छोट करू +zoom_in.title=पैघ करू +zoom_in_label=जूम इन +zoom.title=छोट-पैघ करू\u0020 +presentation_mode.title=प्रस्तुति अवस्थामे जाउ +presentation_mode_label=प्रस्तुति अवस्था +open_file.title=फाइल खोलू +open_file_label=खोलू +print.title=छापू +print_label=छापू +download.title=डाउनलोड +download_label=डाउनलोड +bookmark.title=मोजुदा दृश्य (नव विंडोमे नकल लिअ अथवा खोलू) +bookmark_label=वर्तमान दृश्य + +# Secondary toolbar and context menu +tools.title=अओजार +tools_label=अओजार +first_page.title=प्रथम पृष्ठ पर जाउ +first_page.label=प्रथम पृष्ठ पर जाउ +first_page_label=प्रथम पृष्ठ पर जाउ +last_page.title=अंतिम पृष्ठ पर जाउ +last_page.label=अंतिम पृष्ठ पर जाउ +last_page_label=अंतिम पृष्ठ पर जाउ +page_rotate_cw.title=घड़ीक दिशा मे घुमाउ +page_rotate_cw.label=घड़ीक दिशा मे घुमाउ +page_rotate_cw_label=घड़ीक दिशा मे घुमाउ +page_rotate_ccw.title=घड़ीक दिशा सँ उनटा घुमाउ +page_rotate_ccw.label=घड़ीक दिशा सँ उनटा घुमाउ +page_rotate_ccw_label=घड़ीक दिशा सँ उनटा घुमाउ + +hand_tool_enable.title=हाथ अओजार सक्रिय करू +hand_tool_enable_label=हाथ अओजार सक्रिय करू +hand_tool_disable.title=हाथ अओजार निष्क्रिय कएनाइ +hand_tool_disable_label=हाथ अओजार निष्क्रिय कएनाइ + +# Document properties dialog box +document_properties.title=दस्तावेज़ विशेषता... +document_properties_label=दस्तावेज़ विशेषता... +document_properties_file_name=फाइल नाम: +document_properties_file_size=फ़ाइल आकार: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} बाइट) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} बाइट) +document_properties_title=शीर्षक: +document_properties_author=लेखकः +document_properties_subject=विषय +document_properties_keywords=बीजशब्द +document_properties_creation_date=निर्माण तिथि: +document_properties_modification_date=संशोधन दिनांक: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=सृजक: +document_properties_producer=PDF उत्पादक: +document_properties_version=PDF संस्करण: +document_properties_page_count=पृष्ठ गिनती: +document_properties_close=बन्न करू + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=स्लाइडर टागल +toggle_sidebar_label=स्लाइडर टागल +outline.title=दस्तावेज आउटलाइन देखाउ +outline_label=दस्तावेज खाका +attachments.title=संलग्नक देखाबू +attachments_label=संलग्नक +thumbs.title=लघु-छवि देखाउ +thumbs_label=लघु छवि +findbar.title=दस्तावेजमे ढूँढू +findbar_label=ताकू + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=पृष्ठ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=पृष्ठ {{page}} का लघु-चित्र + +# Find panel button title and messages +find_label=ताकू: +find_previous.title=खोजक पछिला उपस्थिति ताकू +find_previous_label=पछिला +find_next.title=खोजक अगिला उपस्थिति ताकू +find_next_label=आगाँ +find_highlight=सभटा आलोकित करू +find_match_case_label=मिलान स्थिति +find_reached_top=पृष्ठक शीर्ष जाए पहुँचल, तल सँ जारी +find_reached_bottom=पृष्ठक तल मे जाए पहुँचल, शीर्ष सँ जारी +find_not_found=वाकींश नहि भेटल + +# Error panel labels +error_more_info=बेसी सूचना +error_less_info=कम सूचना +error_close=बन्न करू +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=संदेश: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=स्टैक: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=फ़ाइल: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=पंक्ति: {{line}} +rendering_error=पृष्ठ रेंडरिंगक समय त्रुटि आएल. + +# Predefined zoom values +page_scale_width=पृष्ठ चओड़ाइ +page_scale_fit=पृष्ठ फिट +page_scale_auto=स्वचालित जूम +page_scale_actual=सही आकार +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=त्रुटि +loading_error=पीडीएफ लोड करैत समय एकटा त्रुटि भेल. +invalid_file_error=अमान्य अथवा भ्रष्ट PDF फाइल. +missing_file_error=अनुपस्थित PDF फाइल. +unexpected_response_error=सर्वर सँ अप्रत्याशित प्रतिक्रिया. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=एहि पीडीएफ फ़ाइल केँ खोलबाक लेल कृपया कूटशब्द भरू. +password_invalid=अवैध कूटशब्द, कृपया फिनु कोशिश करू. +password_ok=बेस +password_cancel=रद्द करू\u0020 + +printing_not_supported=चेतावनी: ई ब्राउजर पर छपाइ पूर्ण तरह सँ समर्थित नहि अछि. +printing_not_ready=चेतावनी: पीडीएफ छपाइक लेल पूर्ण तरह सँ लोड नहि अछि. +web_fonts_disabled=वेब फॉन्ट्स निष्क्रिय अछि: अंतःस्थापित PDF फान्टसक उपयोगमे असमर्थ. +document_colors_not_allowed=PDF दस्तावेज़ हुकर अपन रंग केँ उपयोग करबाक लेल अनुमति प्राप्त नहि अछि: 'पृष्ठ केँ हुकर अपन रंग केँ चुनबाक लेल स्वीकृति दिअ जे ओ ओहि ब्राउज़र मे निष्क्रिय अछि. diff --git a/static/pdf.js/locale/meh/viewer.ftl b/static/pdf.js/locale/meh/viewer.ftl deleted file mode 100644 index d8bddc9d..00000000 --- a/static/pdf.js/locale/meh/viewer.ftl +++ /dev/null @@ -1,87 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Página yata -pdfjs-zoom-select = - .title = Nasa´a ka´nu/Nasa´a luli -pdfjs-open-file-button-label = Síne - -## Secondary toolbar and context menu - - -## Document properties dialog - -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-linearized-yes = Kuvi -pdfjs-document-properties-close-button = Nakasɨ - -## Print - -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Nkuvi-ka - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-findbar-button-label = Nánuku - -## Thumbnails panel item (tooltip and alt text for images) - - -## Find panel button title and messages - - -## Predefined zoom values - -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } - -## Password - -pdfjs-password-cancel-button = Nkuvi-ka - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/mk/viewer.ftl b/static/pdf.js/locale/mk/viewer.ftl deleted file mode 100644 index 47d24b24..00000000 --- a/static/pdf.js/locale/mk/viewer.ftl +++ /dev/null @@ -1,215 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Претходна страница -pdfjs-previous-button-label = Претходна -pdfjs-next-button = - .title = Следна страница -pdfjs-next-button-label = Следна -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Страница -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = од { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } од { $pagesCount }) -pdfjs-zoom-out-button = - .title = Намалување -pdfjs-zoom-out-button-label = Намали -pdfjs-zoom-in-button = - .title = Зголемување -pdfjs-zoom-in-button-label = Зголеми -pdfjs-zoom-select = - .title = Променување на големина -pdfjs-presentation-mode-button = - .title = Премини во презентациски режим -pdfjs-presentation-mode-button-label = Презентациски режим -pdfjs-open-file-button = - .title = Отворање датотека -pdfjs-open-file-button-label = Отвори -pdfjs-print-button = - .title = Печатење -pdfjs-print-button-label = Печати - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Алатки -pdfjs-tools-button-label = Алатки -pdfjs-first-page-button = - .title = Оди до првата страница -pdfjs-first-page-button-label = Оди до првата страница -pdfjs-last-page-button = - .title = Оди до последната страница -pdfjs-last-page-button-label = Оди до последната страница -pdfjs-page-rotate-cw-button = - .title = Ротирај по стрелките на часовникот -pdfjs-page-rotate-cw-button-label = Ротирај по стрелките на часовникот -pdfjs-page-rotate-ccw-button = - .title = Ротирај спротивно од стрелките на часовникот -pdfjs-page-rotate-ccw-button-label = Ротирај спротивно од стрелките на часовникот -pdfjs-cursor-text-select-tool-button = - .title = Овозможи алатка за избор на текст -pdfjs-cursor-text-select-tool-button-label = Алатка за избор на текст - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Својства на документот… -pdfjs-document-properties-button-label = Својства на документот… -pdfjs-document-properties-file-name = Име на датотека: -pdfjs-document-properties-file-size = Големина на датотеката: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } КБ ({ $size_b } бајти) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } МБ ({ $size_b } бајти) -pdfjs-document-properties-title = Наслов: -pdfjs-document-properties-author = Автор: -pdfjs-document-properties-subject = Тема: -pdfjs-document-properties-keywords = Клучни зборови: -pdfjs-document-properties-creation-date = Датум на создавање: -pdfjs-document-properties-modification-date = Датум на промена: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Креатор: -pdfjs-document-properties-version = Верзија на PDF: -pdfjs-document-properties-page-count = Број на страници: -pdfjs-document-properties-page-size = Големина на страница: -pdfjs-document-properties-page-size-unit-inches = инч -pdfjs-document-properties-page-size-unit-millimeters = мм -pdfjs-document-properties-page-size-orientation-portrait = портрет -pdfjs-document-properties-page-size-orientation-landscape = пејзаж -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Писмо - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-linearized-yes = Да -pdfjs-document-properties-linearized-no = Не -pdfjs-document-properties-close-button = Затвори - -## Print - -pdfjs-print-progress-message = Документ се подготвува за печатење… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Откажи -pdfjs-printing-not-supported = Предупредување: Печатењето не е целосно поддржано во овој прелистувач. -pdfjs-printing-not-ready = Предупредување: PDF документот не е целосно вчитан за печатење. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Вклучи странична лента -pdfjs-toggle-sidebar-button-label = Вклучи странична лента -pdfjs-document-outline-button-label = Содржина на документот -pdfjs-attachments-button = - .title = Прикажи додатоци -pdfjs-thumbs-button = - .title = Прикажување на икони -pdfjs-thumbs-button-label = Икони -pdfjs-findbar-button = - .title = Најди во документот -pdfjs-findbar-button-label = Најди - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Страница { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Икона од страница { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Пронајди - .placeholder = Пронајди во документот… -pdfjs-find-previous-button = - .title = Најди ја предходната појава на фразата -pdfjs-find-previous-button-label = Претходно -pdfjs-find-next-button = - .title = Најди ја следната појава на фразата -pdfjs-find-next-button-label = Следно -pdfjs-find-highlight-checkbox = Означи сѐ -pdfjs-find-match-case-checkbox-label = Токму така -pdfjs-find-entire-word-checkbox-label = Цели зборови -pdfjs-find-reached-top = Барањето стигна до почетокот на документот и почнува од крајот -pdfjs-find-reached-bottom = Барањето стигна до крајот на документот и почнува од почеток -pdfjs-find-not-found = Фразата не е пронајдена - -## Predefined zoom values - -pdfjs-page-scale-width = Ширина на страница -pdfjs-page-scale-fit = Цела страница -pdfjs-page-scale-auto = Автоматска големина -pdfjs-page-scale-actual = Вистинска големина -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Настана грешка при вчитувањето на PDF-от. -pdfjs-invalid-file-error = Невалидна или корумпирана PDF датотека. -pdfjs-missing-file-error = Недостасува PDF документ. -pdfjs-unexpected-response-error = Неочекуван одговор од серверот. -pdfjs-rendering-error = Настана грешка при прикажувањето на страницата. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } - -## Password - -pdfjs-password-label = Внесете ја лозинката за да ја отворите оваа датотека. -pdfjs-password-invalid = Невалидна лозинка. Обидете се повторно. -pdfjs-password-ok-button = Во ред -pdfjs-password-cancel-button = Откажи -pdfjs-web-fonts-disabled = Интернет фонтовите се оневозможени: не може да се користат вградените PDF фонтови. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/mk/viewer.properties b/static/pdf.js/locale/mk/viewer.properties new file mode 100644 index 00000000..18ded891 --- /dev/null +++ b/static/pdf.js/locale/mk/viewer.properties @@ -0,0 +1,126 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Претходна страница +previous_label=Претходна +next.title=Следна страница +next_label=Следна + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Страница: +page_of=од {{pageCount}} + +zoom_out.title=Намалување +zoom_out_label=Намали +zoom_in.title=Зголемување +zoom_in_label=Зголеми +zoom.title=Променување на големина +print.title=Печатење +print_label=Печати +open_file.title=Отварање датотека +open_file_label=Отвори +download.title=Преземање +download_label=Преземи +bookmark.title=Овој преглед (копирај или отвори во нов прозорец) +bookmark_label=Овој преглед + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_slider.title=Вклучување на лизгач +toggle_slider_label=Вклучи лизгач +outline.title=Прикажување на содржина на документот +outline_label=Содржина на документот +thumbs.title=Прикажување на икони +thumbs_label=Икони + +# Document outline messages +no_outline=Нема содржина + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Страница {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Икона од страница {{page}} + +# Error panel labels +error_more_info=Повеќе информации +error_less_info=Помалку информации +error_close=Затвори +# LOCALIZATION NOTE (error_build): "{{build}}" will be replaced by the PDF.JS +# build ID. +error_build=PDF.JS Build: {{build}} +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Порака: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Датотека: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Линија: {{line}} +rendering_error=Настана грешка при прикажувањето на страницата. + +# Predefined zoom values +page_scale_width=Ширина на страница +page_scale_fit=Цела страница +page_scale_auto=Автоматска големина +page_scale_actual=Вистинска големина + +loading_error_indicator=Грешка +loading_error=Настана грешка при вчитувањето на PDF-от. + +# LOCALIZATION NOTE (text_annotation_type): This is used as a tooltip. +# "{{[type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type=[{{type}} Забелешка] +request_password=PDF-от е заштитен со лозинка: + + +printing_not_supported=Предупредување: Печатењето не е целосно поддржано во овој прелистувач. + +find_highlight=Означи сѐ + +# Find panel button title and messages +find_label=Најди: +find_match_case_label=Токму така +find_next.title=Најди ја следната појава на фразата +find_next_label=Следно +find_not_found=Фразата не е пронајдена +find_previous.title=Најди ја предходната појава на фразата +find_previous_label=Претходно +find_reached_bottom=Барањето стигна до крајот на документот и почнува од почеток +find_reached_top=Барањето стигна до почетокот на документот и почнува од крајот +findbar.title=Најди во документот +findbar_label=Најди + +# Context menu +first_page.label=Оди до првата страница +invalid_file_error=Невалидна или корумпирана PDF датотека. +last_page.label=Оди до последната страница +page_rotate_ccw.label=Ротирај спротивно од стрелките на часовникот +page_rotate_cw.label=Ротирај по стрелките на часовникот +presentation_mode.title=Премини во презентациски режим +presentation_mode_label=Презентациски режим + +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +missing_file_error=Недостасува PDF документ. +printing_not_ready=Предупредување: PDF документот не е целосно вчитан за печатење. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Вклучи странична лента +toggle_sidebar_label=Вклучи странична лента +web_fonts_disabled=Интернет фонтовите се оневозможени: не може да се користат вградените PDF фонтови. diff --git a/static/pdf.js/locale/ml/viewer.properties b/static/pdf.js/locale/ml/viewer.properties new file mode 100644 index 00000000..084d8772 --- /dev/null +++ b/static/pdf.js/locale/ml/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=മുമ്പുള്ള താള്‍ +previous_label=മുമ്പു് +next.title=അടുത്ത താള്‍ +next_label=അടുത്തതു് + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=താള്‍: +page_of={{pageCount}} + +zoom_out.title=ചെറുതാക്കുക +zoom_out_label=ചെറുതാക്കുക +zoom_in.title=വലുതാക്കുക +zoom_in_label=വലുതാക്കുക +zoom.title=വ്യാപ്തി മാറ്റുക +presentation_mode.title=പ്രസന്റേഷന്‍ രീതിയിലേക്കു് മാറ്റുക +presentation_mode_label=പ്രസന്റേഷന്‍ രീതി +open_file.title=ഫയല്‍ തുറക്കുക +open_file_label=തുറക്കുക +print.title=പ്രിന്റ് ചെയ്യുക +print_label=പ്രിന്റ് ചെയ്യുക +download.title=ഡൌണ്‍ലോഡ് ചെയ്യുക +download_label=ഡൌണ്‍ലോഡ് ചെയ്യുക +bookmark.title=നിലവിലുള്ള കാഴ്ച (പുതിയ ജാലകത്തില്‍ പകര്‍ത്തുക അല്ലെങ്കില്‍ തുറക്കുക) +bookmark_label=നിലവിലുള്ള കാഴ്ച + +# Secondary toolbar and context menu +tools.title=ഉപകരണങ്ങള്‍ +tools_label=ഉപകരണങ്ങള്‍ +first_page.title=ആദ്യത്തെ താളിലേയ്ക്കു് പോകുക +first_page.label=ആദ്യത്തെ താളിലേയ്ക്കു് പോകുക +first_page_label=ആദ്യത്തെ താളിലേയ്ക്കു് പോകുക +last_page.title=അവസാന താളിലേയ്ക്കു് പോകുക +last_page.label=അവസാന താളിലേയ്ക്കു് പോകുക +last_page_label=അവസാന താളിലേയ്ക്കു് പോകുക +page_rotate_cw.title=ഘടികാരദിശയില്‍ കറക്കുക +page_rotate_cw.label=ഘടികാരദിശയില്‍ കറക്കുക +page_rotate_cw_label=ഘടികാരദിശയില്‍ കറക്കുക +page_rotate_ccw.title=ഘടികാര ദിശയ്ക്കു് വിപരീതമായി കറക്കുക +page_rotate_ccw.label=ഘടികാര ദിശയ്ക്കു് വിപരീതമായി കറക്കുക +page_rotate_ccw_label=ഘടികാര ദിശയ്ക്കു് വിപരീതമായി കറക്കുക + +hand_tool_enable.title=ഹാന്‍ഡ് ടൂള്‍ പ്രവര്‍ത്തന സജ്ജമാക്കുക +hand_tool_enable_label=ഹാന്‍ഡ് ടൂള്‍ പ്രവര്‍ത്തന സജ്ജമാക്കുക +hand_tool_disable.title=ഹാന്‍ഡ് ടൂള്‍ പ്രവര്‍ത്തന രഹിതമാക്കുക +hand_tool_disable_label=ഹാന്‍ഡ് ടൂള്‍ പ്രവര്‍ത്തന രഹിതമാക്കുക + +# Document properties dialog box +document_properties.title=രേഖയുടെ വിശേഷതകള്‍... +document_properties_label=രേഖയുടെ വിശേഷതകള്‍... +document_properties_file_name=ഫയലിന്റെ പേര്‌: +document_properties_file_size=ഫയലിന്റെ വലിപ്പം:‌‌ +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} കെബി ({{size_b}} ബൈറ്റുകള്‍) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} എംബി ({{size_b}} ബൈറ്റുകള്‍) +document_properties_title=തലക്കെട്ട്‌\u0020 +document_properties_author=രചയിതാവ്: +document_properties_subject=വിഷയം: +document_properties_keywords=കീവേര്‍ഡുകള്‍: +document_properties_creation_date=പൂര്‍ത്തിയാകുന്ന തീയതി: +document_properties_modification_date=മാറ്റം വരുത്തിയ തീയതി: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=സൃഷ്ടികര്‍ത്താവ്: +document_properties_producer=പിഡിഎഫ് പ്രൊഡ്യൂസര്‍: +document_properties_version=പിഡിഎഫ് പതിപ്പ്: +document_properties_page_count=താളിന്റെ എണ്ണം: +document_properties_close=അടയ്ക്കുക + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=സൈഡ് ബാറിലേക്കു് മാറ്റുക +toggle_sidebar_label=സൈഡ് ബാറിലേക്കു് മാറ്റുക +outline.title=രേഖയുടെ ഔട്ട്ലൈന്‍ കാണിയ്ക്കുക +outline_label=രേഖയുടെ ഔട്ട്ലൈന്‍ +attachments.title=അറ്റാച്മെന്റുകള്‍ കാണിയ്ക്കുക +attachments_label=അറ്റാച്മെന്റുകള്‍ +thumbs.title=തംബ്നെയിലുകള്‍ കാണിയ്ക്കുക +thumbs_label=തംബ്നെയിലുകള്‍ +findbar.title=രേഖയില്‍ കണ്ടുപിടിയ്ക്കുക +findbar_label=കണ്ടെത്തുക\u0020 + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=താള്‍ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}} താളിനുള്ള തംബ്നെയില്‍ + +# Find panel button title and messages +find_label=കണ്ടെത്തുക +find_previous.title=വാചകം ഇതിനു മുന്‍പ്‌ ആവര്‍ത്തിച്ചത്‌ കണ്ടെത്തുക\u0020 +find_previous_label=മുമ്പു് +find_next.title=വാചകം വീണ്ടും ആവര്‍ത്തിക്കുന്നത്‌ കണ്ടെത്തുക\u0020 +find_next_label=അടുത്തതു് +find_highlight=എല്ലാം എടുത്തുകാണിയ്ക്കുക +find_match_case_label=അക്ഷരങ്ങള്‍ ഒത്തുനോക്കുക +find_reached_top=രേഖയുടെ മുകളില്‍ എത്തിയിരിക്കുന്നു, താഴെ നിന്നും തുടരുന്നു +find_reached_bottom=രേഖയുടെ അവസാനം വരെ എത്തിയിരിക്കുന്നു, മുകളില്‍ നിന്നും തുടരുന്നു\u0020 +find_not_found=വാചകം കണ്ടെത്താനായില്ല\u0020 + +# Error panel labels +error_more_info=കൂടുതല്‍ വിവരം +error_less_info=കുറച്ച് വിവരം +error_close=അടയ്ക്കുക +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=സന്ദേശം: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=സ്റ്റാക്ക്: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ഫയല്‍: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=വരി: {{line}} +rendering_error=താള്‍ റെണ്ടര്‍ ചെയ്യുമ്പോള്‍‌ പിശകുണ്ടായിരിയ്ക്കുന്നു. + +# Predefined zoom values +page_scale_width=താളിന്റെ വീതി +page_scale_fit=താള്‍ പാകത്തിനാക്കുക +page_scale_auto=സ്വയമായി വലുതാക്കുക +page_scale_actual=യഥാര്‍ത്ഥ വ്യാപ്തി +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=പിശക് +loading_error=പിഡിഎഫ് ലഭ്യമാക്കുമ്പോള്‍ പിശക് ഉണ്ടായിരിയ്ക്കുന്നു. +invalid_file_error=തെറ്റായ അല്ലെങ്കില്‍ തകരാറുള്ള പിഡിഎഫ് ഫയല്‍. +missing_file_error=പിഡിഎഫ് ഫയല്‍ ലഭ്യമല്ല. +unexpected_response_error=പ്രതീക്ഷിക്കാത്ത സെര്‍വര്‍ മറുപടി. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=ഈ പിഡിഎഫ് ഫയല്‍ തുറക്കുന്നതിനു് രഹസ്യവാക്ക് നല്‍കുക. +password_invalid=തെറ്റായ രഹസ്യവാക്ക്, ദയവായി വീണ്ടും ശ്രമിയ്ക്കുക. +password_ok=ശരി +password_cancel=റദ്ദാക്കുക + +printing_not_supported=മുന്നറിയിപ്പു്: ഈ ബ്രൌസര്‍ പൂര്‍ണ്ണമായി പ്രിന്റിങ് പിന്തുണയ്ക്കുന്നില്ല. +printing_not_ready=മുന്നറിയിപ്പു്: പ്രിന്റ് ചെയ്യുന്നതിനു് പിഡിഎഫ് പൂര്‍ണ്ണമായി ലഭ്യമല്ല. +web_fonts_disabled=വെബിനുള്ള അക്ഷരസഞ്ചയങ്ങള്‍ പ്രവര്‍ത്തന രഹിതം: എംബഡ്ഡ് ചെയ്ത പിഡിഎഫ് അക്ഷരസഞ്ചയങ്ങള്‍ ഉപയോഗിയ്ക്കുവാന്‍ സാധ്യമല്ല. +document_colors_not_allowed=സ്വന്തം നിറങ്ങള്‍ ഉപയോഗിയ്ക്കുവാന്‍ പിഡിഎഫ് രേഖകള്‍ക്കു് അനുവാദമില്ല: 'സ്വന്തം നിറങ്ങള്‍ ഉപയോഗിയ്ക്കുവാന്‍ താളുകളെ അനുവദിയ്ക്കുക' എന്നതു് ബ്രൌസറില്‍ നിര്‍ജീവമാണു്. diff --git a/static/pdf.js/locale/mn/viewer.properties b/static/pdf.js/locale/mn/viewer.properties new file mode 100644 index 00000000..dfa1d6dd --- /dev/null +++ b/static/pdf.js/locale/mn/viewer.properties @@ -0,0 +1,79 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. + +zoom.title=Тэлэлт +open_file.title=Файл нээ +open_file_label=Нээ + +# Secondary toolbar and context menu + + +# Document properties dialog box +document_properties_file_name=Файлын нэр: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Гарчиг: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +findbar_label=Ол + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. + +# Find panel button title and messages +find_previous.title=Хайлтын өмнөх олдцыг харуулна +find_next.title=Хайлтын дараагийн олдцыг харуулна +find_not_found=Олдсонгүй + +# Error panel labels +error_more_info=Нэмэлт мэдээлэл +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number + +# Predefined zoom values +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Алдаа + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +password_ok=OK +password_cancel=Цуцал + diff --git a/static/pdf.js/locale/mr/viewer.ftl b/static/pdf.js/locale/mr/viewer.ftl deleted file mode 100644 index 49948b19..00000000 --- a/static/pdf.js/locale/mr/viewer.ftl +++ /dev/null @@ -1,239 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = मागील पृष्ठ -pdfjs-previous-button-label = मागील -pdfjs-next-button = - .title = पुढील पृष्ठ -pdfjs-next-button-label = पुढील -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = पृष्ठ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount }पैकी -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pagesCount } पैकी { $pageNumber }) -pdfjs-zoom-out-button = - .title = छोटे करा -pdfjs-zoom-out-button-label = छोटे करा -pdfjs-zoom-in-button = - .title = मोठे करा -pdfjs-zoom-in-button-label = मोठे करा -pdfjs-zoom-select = - .title = लहान किंवा मोठे करा -pdfjs-presentation-mode-button = - .title = प्रस्तुतिकरण मोडचा वापर करा -pdfjs-presentation-mode-button-label = प्रस्तुतिकरण मोड -pdfjs-open-file-button = - .title = फाइल उघडा -pdfjs-open-file-button-label = उघडा -pdfjs-print-button = - .title = छपाई करा -pdfjs-print-button-label = छपाई करा - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = साधने -pdfjs-tools-button-label = साधने -pdfjs-first-page-button = - .title = पहिल्या पृष्ठावर जा -pdfjs-first-page-button-label = पहिल्या पृष्ठावर जा -pdfjs-last-page-button = - .title = शेवटच्या पृष्ठावर जा -pdfjs-last-page-button-label = शेवटच्या पृष्ठावर जा -pdfjs-page-rotate-cw-button = - .title = घड्याळाच्या काट्याच्या दिशेने फिरवा -pdfjs-page-rotate-cw-button-label = घड्याळाच्या काट्याच्या दिशेने फिरवा -pdfjs-page-rotate-ccw-button = - .title = घड्याळाच्या काट्याच्या उलट दिशेने फिरवा -pdfjs-page-rotate-ccw-button-label = घड्याळाच्या काट्याच्या उलट दिशेने फिरवा -pdfjs-cursor-text-select-tool-button = - .title = मजकूर निवड साधन कार्यान्वयीत करा -pdfjs-cursor-text-select-tool-button-label = मजकूर निवड साधन -pdfjs-cursor-hand-tool-button = - .title = हात साधन कार्यान्वित करा -pdfjs-cursor-hand-tool-button-label = हस्त साधन -pdfjs-scroll-vertical-button = - .title = अनुलंब स्क्रोलिंग वापरा -pdfjs-scroll-vertical-button-label = अनुलंब स्क्रोलिंग -pdfjs-scroll-horizontal-button = - .title = क्षैतिज स्क्रोलिंग वापरा -pdfjs-scroll-horizontal-button-label = क्षैतिज स्क्रोलिंग - -## Document properties dialog - -pdfjs-document-properties-button = - .title = दस्तऐवज गुणधर्म… -pdfjs-document-properties-button-label = दस्तऐवज गुणधर्म… -pdfjs-document-properties-file-name = फाइलचे नाव: -pdfjs-document-properties-file-size = फाइल आकार: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } बाइट्स) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } बाइट्स) -pdfjs-document-properties-title = शिर्षक: -pdfjs-document-properties-author = लेखक: -pdfjs-document-properties-subject = विषय: -pdfjs-document-properties-keywords = मुख्यशब्द: -pdfjs-document-properties-creation-date = निर्माण दिनांक: -pdfjs-document-properties-modification-date = दुरूस्ती दिनांक: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = निर्माता: -pdfjs-document-properties-producer = PDF निर्माता: -pdfjs-document-properties-version = PDF आवृत्ती: -pdfjs-document-properties-page-count = पृष्ठ संख्या: -pdfjs-document-properties-page-size = पृष्ठ आकार: -pdfjs-document-properties-page-size-unit-inches = इंच -pdfjs-document-properties-page-size-unit-millimeters = मीमी -pdfjs-document-properties-page-size-orientation-portrait = उभी मांडणी -pdfjs-document-properties-page-size-orientation-landscape = आडवे -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = जलद वेब दृष्य: -pdfjs-document-properties-linearized-yes = हो -pdfjs-document-properties-linearized-no = नाही -pdfjs-document-properties-close-button = बंद करा - -## Print - -pdfjs-print-progress-message = छपाई करीता पृष्ठ तयार करीत आहे… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = रद्द करा -pdfjs-printing-not-supported = सावधानता: या ब्राउझरतर्फे छपाइ पूर्णपणे समर्थीत नाही. -pdfjs-printing-not-ready = सावधानता: छपाईकरिता PDF पूर्णतया लोड झाले नाही. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = बाजूचीपट्टी टॉगल करा -pdfjs-toggle-sidebar-button-label = बाजूचीपट्टी टॉगल करा -pdfjs-document-outline-button = - .title = दस्तऐवज बाह्यरेखा दर्शवा (विस्तृत करण्यासाठी दोनवेळा क्लिक करा /सर्व घटक दाखवा) -pdfjs-document-outline-button-label = दस्तऐवज रूपरेषा -pdfjs-attachments-button = - .title = जोडपत्र दाखवा -pdfjs-attachments-button-label = जोडपत्र -pdfjs-thumbs-button = - .title = थंबनेल्स् दाखवा -pdfjs-thumbs-button-label = थंबनेल्स् -pdfjs-findbar-button = - .title = दस्तऐवजात शोधा -pdfjs-findbar-button-label = शोधा - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = पृष्ठ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = पृष्ठाचे थंबनेल { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = शोधा - .placeholder = दस्तऐवजात शोधा… -pdfjs-find-previous-button = - .title = वाकप्रयोगची मागील घटना शोधा -pdfjs-find-previous-button-label = मागील -pdfjs-find-next-button = - .title = वाकप्रयोगची पुढील घटना शोधा -pdfjs-find-next-button-label = पुढील -pdfjs-find-highlight-checkbox = सर्व ठळक करा -pdfjs-find-match-case-checkbox-label = आकार जुळवा -pdfjs-find-entire-word-checkbox-label = संपूर्ण शब्द -pdfjs-find-reached-top = दस्तऐवजाच्या शीर्षकास पोहचले, तळपासून पुढे -pdfjs-find-reached-bottom = दस्तऐवजाच्या तळाला पोहचले, शीर्षकापासून पुढे -pdfjs-find-not-found = वाकप्रयोग आढळले नाही - -## Predefined zoom values - -pdfjs-page-scale-width = पृष्ठाची रूंदी -pdfjs-page-scale-fit = पृष्ठ बसवा -pdfjs-page-scale-auto = स्वयं लाहन किंवा मोठे करणे -pdfjs-page-scale-actual = प्रत्यक्ष आकार -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF लोड करतेवेळी त्रुटी आढळली. -pdfjs-invalid-file-error = अवैध किंवा दोषीत PDF फाइल. -pdfjs-missing-file-error = न आढळणारी PDF फाइल. -pdfjs-unexpected-response-error = अनपेक्षित सर्व्हर प्रतिसाद. -pdfjs-rendering-error = पृष्ठ दाखवतेवेळी त्रुटी आढळली. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } टिपण्णी] - -## Password - -pdfjs-password-label = ही PDF फाइल उघडण्याकरिता पासवर्ड द्या. -pdfjs-password-invalid = अवैध पासवर्ड. कृपया पुन्हा प्रयत्न करा. -pdfjs-password-ok-button = ठीक आहे -pdfjs-password-cancel-button = रद्द करा -pdfjs-web-fonts-disabled = वेब टंक असमर्थीत आहेत: एम्बेडेड PDF टंक वापर अशक्य. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/mr/viewer.properties b/static/pdf.js/locale/mr/viewer.properties new file mode 100644 index 00000000..f9d1ef70 --- /dev/null +++ b/static/pdf.js/locale/mr/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=मागील पृष्ठ +previous_label=मागील +next.title=पुढील पृष्ठ +next_label=पुढील + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=पृष्ठ: +page_of=पैकी {{pageCount}} + +zoom_out.title=छोटे करा +zoom_out_label=छोटे करा +zoom_in.title=मोठे करा +zoom_in_label=मोठे करा +zoom.title=लहान किंवा मोठे करा +presentation_mode.title=प्रस्तुतिकरण मोडचा वापर करा +presentation_mode_label=प्रस्तुतिकरण मोड +open_file.title=फाइल उघडा +open_file_label=उघडा +print.title=छपाई करा +print_label=छपाई करा +download.title=डाउनलोड करा +download_label=डाउनलोड करा +bookmark.title=सध्याचे अवलोकन (नवीन पटलात प्रत बनवा किंवा उघडा) +bookmark_label=सध्याचे अवलोकन + +# Secondary toolbar and context menu +tools.title=साधने +tools_label=साधने +first_page.title=पहिल्या पानावर जा +first_page.label=पहिल्या पानावर जा +first_page_label=पहिल्या पानावर जा +last_page.title=शेवटच्या पानावर जा +last_page.label=शेवटच्या पानावर जा +last_page_label=शेवटच्या पानावर जा +page_rotate_cw.title=घड्याळाच्या काट्याच्या दिशेने फिरवा +page_rotate_cw.label=घड्याळाच्या काट्याच्या दिशेने फिरवा +page_rotate_cw_label=घड्याळाच्या काट्याच्या दिशेने फिरवा +page_rotate_ccw.title=घड्याळाच्या काट्याच्या उलट दिशेने फिरवा +page_rotate_ccw.label=घड्याळाच्या काट्याच्या उलट दिशेने फिरवा +page_rotate_ccw_label=घड्याळाच्या काट्याच्या उलट दिशेने फिरवा + +hand_tool_enable.title=हात साधन सुरू करा +hand_tool_enable_label=हात साधन सुरू करा +hand_tool_disable.title=हात साधन बंद करा +hand_tool_disable_label=हात साधन बंद करा + +# Document properties dialog box +document_properties.title=दस्तऐवज गुणधर्म… +document_properties_label=दस्तऐवज गुणधर्म… +document_properties_file_name=फाइलचे नाव: +document_properties_file_size=फाइल आकार: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} बाइट्स) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} बाइट्स) +document_properties_title=शिर्षक: +document_properties_author=लेखक: +document_properties_subject=विषय: +document_properties_keywords=मुख्यशब्द: +document_properties_creation_date=निर्माण दिनांक: +document_properties_modification_date=दुरूस्ती दिनांक: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=निर्माता: +document_properties_producer=PDF निर्माता: +document_properties_version=PDF आवृत्ती: +document_properties_page_count=पृष्ठ संख्या: +document_properties_close=बंद करा + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=बाजूचीपट्टी टॉगल करा +toggle_sidebar_label=बाजूचीपट्टी टॉगल करा +outline.title=दस्तऐवज रूपरेषा दाखवा +outline_label=दस्तऐवज रूपरेषा +attachments.title=जोडपत्र दाखवा +attachments_label=जोडपत्र +thumbs.title=थंबनेल्स् दाखवा +thumbs_label=थंबनेल्स् +findbar.title=दस्तऐवजात शोधा +findbar_label=शोधा + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=पृष्ठ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=पृष्ठाचे थंबनेल {{page}} + +# Find panel button title and messages +find_label=शोधा: +find_previous.title=वाकप्रयोगची मागील घटना शोधा +find_previous_label=मागील +find_next.title=वाकप्रयोगची पुढील घटना शोधा +find_next_label=पुढील +find_highlight=सर्व ठळक करा +find_match_case_label=आकार जुळवा +find_reached_top=दस्तऐवजाच्या शीर्षकास पोहचले, तळपासून पुढे +find_reached_bottom=दस्तऐवजाच्या तळाला पोहचले, शीर्षकापासून पुढे +find_not_found=वाकप्रयोग आढळले नाही + +# Error panel labels +error_more_info=आणखी माहिती +error_less_info=कमी माहिती +error_close=बंद करा +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=संदेश: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=स्टॅक: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=फाइल: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=रेष: {{line}} +rendering_error=पृष्ठ दाखवतेवेळी त्रुटी आढळली. + +# Predefined zoom values +page_scale_width=पृष्ठाची रूंदी +page_scale_fit=पृष्ठ बसवा +page_scale_auto=स्वयं लाहन किंवा मोठे करणे +page_scale_actual=प्रत्यक्ष आकार +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=त्रुटी +loading_error=PDF लोड करतेवेळी त्रुटी आढळली. +invalid_file_error=अवैध किंवा दोषीत PDF फाइल. +missing_file_error=न आढळणारी PDF फाइल. +unexpected_response_error=अनपेक्षित सर्व्हर प्रतिसाद. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} टिपण्णी] +password_label=ही PDF फाइल उघडण्याकरिता पासवर्ड द्या. +password_invalid=अवैध पासवर्ड. कृपया पुन्हा प्रयत्न करा. +password_ok=ठीक आहे +password_cancel=रद्द करा + +printing_not_supported=सावधानता: या ब्राउजरतर्फे छपाइ पूर्णपणे समर्थीत नाही. +printing_not_ready=सावधानता: छपाईकरिता PDF पूर्णतया लोड झाले नाही. +web_fonts_disabled=वेब फाँट्स असमर्थीत आहेत: एम्बेडेड PDF फाँट्स्चा वापर अशक्य. +document_colors_not_allowed=PDF दस्ताएवजांना त्यांचे रंग वापरण्यास अनुमती नाही: ब्राउजरमध्ये ' पानांना त्यांचे रंग निवडण्यास अनुमती द्या' बंद केले आहे. diff --git a/static/pdf.js/locale/ms/viewer.ftl b/static/pdf.js/locale/ms/viewer.ftl deleted file mode 100644 index 11b86651..00000000 --- a/static/pdf.js/locale/ms/viewer.ftl +++ /dev/null @@ -1,247 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Halaman Dahulu -pdfjs-previous-button-label = Dahulu -pdfjs-next-button = - .title = Halaman Berikut -pdfjs-next-button-label = Berikut -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Halaman -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = daripada { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } daripada { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zum Keluar -pdfjs-zoom-out-button-label = Zum Keluar -pdfjs-zoom-in-button = - .title = Zum Masuk -pdfjs-zoom-in-button-label = Zum Masuk -pdfjs-zoom-select = - .title = Zum -pdfjs-presentation-mode-button = - .title = Tukar ke Mod Persembahan -pdfjs-presentation-mode-button-label = Mod Persembahan -pdfjs-open-file-button = - .title = Buka Fail -pdfjs-open-file-button-label = Buka -pdfjs-print-button = - .title = Cetak -pdfjs-print-button-label = Cetak - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Alatan -pdfjs-tools-button-label = Alatan -pdfjs-first-page-button = - .title = Pergi ke Halaman Pertama -pdfjs-first-page-button-label = Pergi ke Halaman Pertama -pdfjs-last-page-button = - .title = Pergi ke Halaman Terakhir -pdfjs-last-page-button-label = Pergi ke Halaman Terakhir -pdfjs-page-rotate-cw-button = - .title = Berputar ikut arah Jam -pdfjs-page-rotate-cw-button-label = Berputar ikut arah Jam -pdfjs-page-rotate-ccw-button = - .title = Pusing berlawan arah jam -pdfjs-page-rotate-ccw-button-label = Pusing berlawan arah jam -pdfjs-cursor-text-select-tool-button = - .title = Dayakan Alatan Pilihan Teks -pdfjs-cursor-text-select-tool-button-label = Alatan Pilihan Teks -pdfjs-cursor-hand-tool-button = - .title = Dayakan Alatan Tangan -pdfjs-cursor-hand-tool-button-label = Alatan Tangan -pdfjs-scroll-vertical-button = - .title = Guna Skrol Menegak -pdfjs-scroll-vertical-button-label = Skrol Menegak -pdfjs-scroll-horizontal-button = - .title = Guna Skrol Mengufuk -pdfjs-scroll-horizontal-button-label = Skrol Mengufuk -pdfjs-scroll-wrapped-button = - .title = Guna Skrol Berbalut -pdfjs-scroll-wrapped-button-label = Skrol Berbalut -pdfjs-spread-none-button = - .title = Jangan hubungkan hamparan halaman -pdfjs-spread-none-button-label = Tanpa Hamparan -pdfjs-spread-odd-button = - .title = Hubungkan hamparan halaman dengan halaman nombor ganjil -pdfjs-spread-odd-button-label = Hamparan Ganjil -pdfjs-spread-even-button = - .title = Hubungkan hamparan halaman dengan halaman nombor genap -pdfjs-spread-even-button-label = Hamparan Seimbang - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Sifat Dokumen… -pdfjs-document-properties-button-label = Sifat Dokumen… -pdfjs-document-properties-file-name = Nama fail: -pdfjs-document-properties-file-size = Saiz fail: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bait) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bait) -pdfjs-document-properties-title = Tajuk: -pdfjs-document-properties-author = Pengarang: -pdfjs-document-properties-subject = Subjek: -pdfjs-document-properties-keywords = Kata kunci: -pdfjs-document-properties-creation-date = Masa Dicipta: -pdfjs-document-properties-modification-date = Tarikh Ubahsuai: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Pencipta: -pdfjs-document-properties-producer = Pengeluar PDF: -pdfjs-document-properties-version = Versi PDF: -pdfjs-document-properties-page-count = Kiraan Laman: -pdfjs-document-properties-page-size = Saiz Halaman: -pdfjs-document-properties-page-size-unit-inches = dalam -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = potret -pdfjs-document-properties-page-size-orientation-landscape = landskap -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Paparan Web Pantas: -pdfjs-document-properties-linearized-yes = Ya -pdfjs-document-properties-linearized-no = Tidak -pdfjs-document-properties-close-button = Tutup - -## Print - -pdfjs-print-progress-message = Menyediakan dokumen untuk dicetak… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Batal -pdfjs-printing-not-supported = Amaran: Cetakan ini tidak sepenuhnya disokong oleh pelayar ini. -pdfjs-printing-not-ready = Amaran: PDF tidak sepenuhnya dimuatkan untuk dicetak. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Togol Bar Sisi -pdfjs-toggle-sidebar-button-label = Togol Bar Sisi -pdfjs-document-outline-button = - .title = Papar Rangka Dokumen (klik-dua-kali untuk kembangkan/kolaps semua item) -pdfjs-document-outline-button-label = Rangka Dokumen -pdfjs-attachments-button = - .title = Papar Lampiran -pdfjs-attachments-button-label = Lampiran -pdfjs-thumbs-button = - .title = Papar Thumbnails -pdfjs-thumbs-button-label = Imej kecil -pdfjs-findbar-button = - .title = Cari didalam Dokumen -pdfjs-findbar-button-label = Cari - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Halaman { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Halaman Imej kecil { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Cari - .placeholder = Cari dalam dokumen… -pdfjs-find-previous-button = - .title = Cari teks frasa berkenaan yang terdahulu -pdfjs-find-previous-button-label = Dahulu -pdfjs-find-next-button = - .title = Cari teks frasa berkenaan yang berikut -pdfjs-find-next-button-label = Berikut -pdfjs-find-highlight-checkbox = Serlahkan semua -pdfjs-find-match-case-checkbox-label = Huruf sepadan -pdfjs-find-entire-word-checkbox-label = Seluruh perkataan -pdfjs-find-reached-top = Mencapai teratas daripada dokumen, sambungan daripada bawah -pdfjs-find-reached-bottom = Mencapai terakhir daripada dokumen, sambungan daripada atas -pdfjs-find-not-found = Frasa tidak ditemui - -## Predefined zoom values - -pdfjs-page-scale-width = Lebar Halaman -pdfjs-page-scale-fit = Muat Halaman -pdfjs-page-scale-auto = Zoom Automatik -pdfjs-page-scale-actual = Saiz Sebenar -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Masalah berlaku semasa menuatkan sebuah PDF. -pdfjs-invalid-file-error = Tidak sah atau fail PDF rosak. -pdfjs-missing-file-error = Fail PDF Hilang. -pdfjs-unexpected-response-error = Respon pelayan yang tidak dijangka. -pdfjs-rendering-error = Ralat berlaku ketika memberikan halaman. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Anotasi] - -## Password - -pdfjs-password-label = Masukan kata kunci untuk membuka fail PDF ini. -pdfjs-password-invalid = Kata laluan salah. Cuba lagi. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Batal -pdfjs-web-fonts-disabled = Fon web dinyahdayakan: tidak dapat menggunakan fon terbenam PDF. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ms/viewer.properties b/static/pdf.js/locale/ms/viewer.properties new file mode 100644 index 00000000..cc6b70b0 --- /dev/null +++ b/static/pdf.js/locale/ms/viewer.properties @@ -0,0 +1,171 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Laman Sebelumnya +previous_label=Terdahulu +next.title=Laman seterusnya +next_label=Berikut + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Laman: +page_of=daripada {{pageCount}} + +zoom_out.title=Zum Keluar +zoom_out_label=Zum Keluar +zoom_in.title=Zum Masuk +zoom_in_label=Zum Masuk +zoom.title=Zum +presentation_mode.title=Bertukar ke Mod Persembahan +presentation_mode_label=Mod Persembahan +open_file.title=Buka Fail +open_file_label=Buka +print.title=Cetak +print_label=Cetak +download.title=Muat turun +download_label=Muat turun +bookmark.title=Pandangan semasa (salinan atau dibuka dalam tetingkap baru) +bookmark_label=Lihat semasa + +# Secondary toolbar and context menu +tools.title=Alatan +tools_label=Alatan +first_page.title=Pergi ke Halaman Pertama +first_page.label=Pergi ke Halaman Pertama +first_page_label=Pergi ke Halaman Pertama +last_page.title=Pergi ke Halaman Terakhir +last_page.label=Pergi ke Halaman Terakhir +last_page_label=Pergi ke Halaman Terakhir +page_rotate_cw.title=Berputar ikut arah Jam +page_rotate_cw.label=Berputar ikut arah Jam +page_rotate_cw_label=Berputar ikut arah Jam +page_rotate_ccw.title=Pusing berlawan arah jam +page_rotate_ccw.label=Pusing berlawan arah jam +page_rotate_ccw_label=Pusing berlawan arah jam + +hand_tool_enable.title=Bolehkan alatan tangan +hand_tool_enable_label=Bolehkan alatan tangan +hand_tool_disable.title=Lumpuhkan alatan tangan +hand_tool_disable_label=Lumpuhkan alatan tangan + +# Document properties dialog box +document_properties.title=Ciri Dokumen… +document_properties_label=Ciri Dokumen… +document_properties_file_name=Nama fail: +document_properties_file_size=Saiz fail: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bait) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bait) +document_properties_title=Tajuk: +document_properties_author=Pengarang: +document_properties_subject=Subjek: +document_properties_keywords=Kata kunci: +document_properties_creation_date=Masa Dicipta: +document_properties_modification_date=Tarikh Ubahsuai: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Pencipta: +document_properties_producer=Pengeluar PDF: +document_properties_version=Versi PDF: +document_properties_page_count=Kiraan Laman: +document_properties_close=Tutup + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Togol Bar Sisi +toggle_sidebar_label=Togol Bar Sisi +outline.title=Tunjuk Rangka Dokumen +outline_label=Rangka Dokument +attachments.title=Tunjuk Lampiran +attachments_label=Lampiran +thumbs.title=Tunjuk Imej kecil +thumbs_label=Imej kecil +findbar.title=Cari didalam Dokumen +findbar_label=Cari + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Halaman {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Halaman Imej kecil {{page}} + +# Find panel button title and messages +find_label=Cari: +find_previous.title=Cari teks frasa berkenaan yang terdahulu +find_previous_label=Sebelumnya +find_next.title=Cari teks frasa berkenaan yang berikut +find_next_label=Berikut +find_highlight=Serlahkan semua +find_match_case_label=Kes Sepadan +find_reached_top=Mencapai teratas daripada dokumen, sambungan daripada bawah +find_reached_bottom=Mencapai terakhir daripada dokumen, sambungan daripada atas +find_not_found=Frasa tidak ditemui + +# Error panel labels +error_more_info=Maklumat lanjut +error_less_info=Kurang Informasi +error_close=Tutup +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mesej: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Timbun: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fail: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Garis: {{line}} +rendering_error=Ralat berlaku ketika memberikan halaman. + +# Predefined zoom values +page_scale_width=Lebar Halaman +page_scale_fit=Muat Halaman +page_scale_auto=Zoom Automatik +page_scale_actual=Saiz Sebenar +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Ralat +loading_error=Masalah berlaku semasa menuatkan sebuah PDF. +invalid_file_error=Tidak sah atau fail PDF rosak. +missing_file_error=Fail PDF Hilang. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Anotasi] +password_label=Masukan kata kunci untuk membuka fail PDF ini. +password_invalid=Kata laluan salah. Cuba lagi. +password_ok=OK +password_cancel=Batal + +printing_not_supported=Amaran: Cetakan ini tidak sepenuhnya disokong oleh pelayar ini. +printing_not_ready=Amaran: PDF tidak sepenuhnya dimuatkan untuk dicetak. +web_fonts_disabled=Fon web dilumpuhkan: tidak dapat fon PDF terbenam. +document_colors_not_allowed=Dokumen PDF tidak dibenarkan untuk menggunakan warna sendiri: 'Benarkan muka surat untuk memilih warna sendiri' telah dinyahaktif dalam pelayar. diff --git a/static/pdf.js/locale/my/viewer.ftl b/static/pdf.js/locale/my/viewer.ftl deleted file mode 100644 index d3b973d8..00000000 --- a/static/pdf.js/locale/my/viewer.ftl +++ /dev/null @@ -1,206 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = အရင် စာမျက်နှာ -pdfjs-previous-button-label = အရင်နေရာ -pdfjs-next-button = - .title = ရှေ့ စာမျက်နှာ -pdfjs-next-button-label = နောက်တခု -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = စာမျက်နှာ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } ၏ -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pagesCount } ၏ { $pageNumber }) -pdfjs-zoom-out-button = - .title = ချုံ့ပါ -pdfjs-zoom-out-button-label = ချုံ့ပါ -pdfjs-zoom-in-button = - .title = ချဲ့ပါ -pdfjs-zoom-in-button-label = ချဲ့ပါ -pdfjs-zoom-select = - .title = ချုံ့/ချဲ့ပါ -pdfjs-presentation-mode-button = - .title = ဆွေးနွေးတင်ပြစနစ်သို့ ကူးပြောင်းပါ -pdfjs-presentation-mode-button-label = ဆွေးနွေးတင်ပြစနစ် -pdfjs-open-file-button = - .title = ဖိုင်အားဖွင့်ပါ။ -pdfjs-open-file-button-label = ဖွင့်ပါ -pdfjs-print-button = - .title = ပုံနှိုပ်ပါ -pdfjs-print-button-label = ပုံနှိုပ်ပါ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ကိရိယာများ -pdfjs-tools-button-label = ကိရိယာများ -pdfjs-first-page-button = - .title = ပထမ စာမျက်နှာသို့ -pdfjs-first-page-button-label = ပထမ စာမျက်နှာသို့ -pdfjs-last-page-button = - .title = နောက်ဆုံး စာမျက်နှာသို့ -pdfjs-last-page-button-label = နောက်ဆုံး စာမျက်နှာသို့ -pdfjs-page-rotate-cw-button = - .title = နာရီလက်တံ အတိုင်း -pdfjs-page-rotate-cw-button-label = နာရီလက်တံ အတိုင်း -pdfjs-page-rotate-ccw-button = - .title = နာရီလက်တံ ပြောင်းပြန် -pdfjs-page-rotate-ccw-button-label = နာရီလက်တံ ပြောင်းပြန် - -## Document properties dialog - -pdfjs-document-properties-button = - .title = မှတ်တမ်းမှတ်ရာ ဂုဏ်သတ္တိများ -pdfjs-document-properties-button-label = မှတ်တမ်းမှတ်ရာ ဂုဏ်သတ္တိများ -pdfjs-document-properties-file-name = ဖိုင် : -pdfjs-document-properties-file-size = ဖိုင်ဆိုဒ် : -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } ကီလိုဘိုတ် ({ $size_b }ဘိုတ်) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = ခေါင်းစဉ်‌ - -pdfjs-document-properties-author = ရေးသားသူ: -pdfjs-document-properties-subject = အကြောင်းအရာ: -pdfjs-document-properties-keywords = သော့ချက် စာလုံး: -pdfjs-document-properties-creation-date = ထုတ်လုပ်ရက်စွဲ: -pdfjs-document-properties-modification-date = ပြင်ဆင်ရက်စွဲ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = ဖန်တီးသူ: -pdfjs-document-properties-producer = PDF ထုတ်လုပ်သူ: -pdfjs-document-properties-version = PDF ဗားရှင်း: -pdfjs-document-properties-page-count = စာမျက်နှာအရေအတွက်: - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -pdfjs-document-properties-close-button = ပိတ် - -## Print - -pdfjs-print-progress-message = Preparing document for printing… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = ပယ်​ဖျက်ပါ -pdfjs-printing-not-supported = သတိပေးချက်၊ပရင့်ထုတ်ခြင်းကိုဤဘယောက်ဆာသည် ပြည့်ဝစွာထောက်ပံ့မထားပါ ။ -pdfjs-printing-not-ready = သတိပေးချက်: ယခု PDF ဖိုင်သည် ပုံနှိပ်ရန် မပြည့်စုံပါ - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = ဘေးတန်းဖွင့်ပိတ် -pdfjs-toggle-sidebar-button-label = ဖွင့်ပိတ် ဆလိုက်ဒါ -pdfjs-document-outline-button = - .title = စာတမ်းအကျဉ်းချုပ်ကို ပြပါ (စာရင်းအားလုံးကို ချုံ့/ချဲ့ရန် ကလစ်နှစ်ချက်နှိပ်ပါ) -pdfjs-document-outline-button-label = စာတမ်းအကျဉ်းချုပ် -pdfjs-attachments-button = - .title = တွဲချက်များ ပြပါ -pdfjs-attachments-button-label = တွဲထားချက်များ -pdfjs-thumbs-button = - .title = ပုံရိပ်ငယ်များကို ပြပါ -pdfjs-thumbs-button-label = ပုံရိပ်ငယ်များ -pdfjs-findbar-button = - .title = Find in Document -pdfjs-findbar-button-label = ရှာဖွေပါ - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = စာမျက်နှာ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = စာမျက်နှာရဲ့ ပုံရိပ်ငယ် { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = ရှာဖွေပါ - .placeholder = စာတမ်းထဲတွင် ရှာဖွေရန်… -pdfjs-find-previous-button = - .title = စကားစုရဲ့ အရင် ​ဖြစ်ပွားမှုကို ရှာဖွေပါ -pdfjs-find-previous-button-label = နောက်သို့ -pdfjs-find-next-button = - .title = စကားစုရဲ့ နောက်ထပ် ​ဖြစ်ပွားမှုကို ရှာဖွေပါ -pdfjs-find-next-button-label = ရှေ့သို့ -pdfjs-find-highlight-checkbox = အားလုံးကို မျဉ်းသားပါ -pdfjs-find-match-case-checkbox-label = စာလုံး တိုက်ဆိုင်ပါ -pdfjs-find-reached-top = စာမျက်နှာထိပ် ရောက်နေပြီ၊ အဆုံးကနေ ပြန်စပါ -pdfjs-find-reached-bottom = စာမျက်နှာအဆုံး ရောက်နေပြီ၊ ထိပ်ကနေ ပြန်စပါ -pdfjs-find-not-found = စကားစု မတွေ့ရဘူး - -## Predefined zoom values - -pdfjs-page-scale-width = စာမျက်နှာ အကျယ် -pdfjs-page-scale-fit = စာမျက်နှာ ကွက်တိ -pdfjs-page-scale-auto = အလိုအလျောက် ချုံ့ချဲ့ -pdfjs-page-scale-actual = အမှန်တကယ်ရှိတဲ့ အရွယ် -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF ဖိုင် ကိုဆွဲတင်နေချိန်မှာ အမှားတစ်ခုတွေ့ရပါတယ်။ -pdfjs-invalid-file-error = မရသော သို့ ပျက်နေသော PDF ဖိုင် -pdfjs-missing-file-error = PDF ပျောက်ဆုံး -pdfjs-unexpected-response-error = မမျှော်လင့်ထားသော ဆာဗာမှ ပြန်ကြားချက် -pdfjs-rendering-error = စာမျက်နှာကို ပုံဖော်နေချိန်မှာ အမှားတစ်ခုတွေ့ရပါတယ်။ - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } အဓိပ္ပာယ်ဖွင့်ဆိုချက်] - -## Password - -pdfjs-password-label = ယခု PDF ကို ဖွင့်ရန် စကားဝှက်ကို ရိုက်ပါ။ -pdfjs-password-invalid = စာဝှက် မှားသည်။ ထပ်ကြိုးစားကြည့်ပါ။ -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = ပယ်​ဖျက်ပါ -pdfjs-web-fonts-disabled = Web fonts are disabled: unable to use embedded PDF fonts. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/my/viewer.properties b/static/pdf.js/locale/my/viewer.properties new file mode 100644 index 00000000..303a9db8 --- /dev/null +++ b/static/pdf.js/locale/my/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=အရင် စာမျက်နှာ +previous_label=အရင်နေရာ +next.title=ရှေ့ စာမျက်နှာ +next_label=နောက်တခု + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=စာမျက်နှာ - +page_of=၏ {{pageCount}} + +zoom_out.title=ချုံ့ပါ +zoom_out_label=ချုံ့ပါ +zoom_in.title=ချဲ့ပါ +zoom_in_label=ချဲ့ပါ +zoom.title=ချုံ့/ချဲ့ပါ +presentation_mode.title=Switch to Presentation Mode +presentation_mode_label=Presentation Mode +open_file.title=ဖိုင်အားဖွင့်ပါ။ +open_file_label=ဖွင့်ပါ +print.title=ပုံနှိုပ်ပါ +print_label=ပုံနှိုပ်ပါ +download.title=ကူးဆွဲ +download_label=ကူးဆွဲ +bookmark.title=လက်ရှိ မြင်ကွင်း (ဝင်းဒိုးအသစ်မှာ ကူးပါ သို့မဟုတ် ဖွင့်ပါ) +bookmark_label=လက်ရှိ မြင်ကွင်း + +# Secondary toolbar and context menu +tools.title=ကိရိယာများ +tools_label=ကိရိယာများ +first_page.title=ပထမ စာမျက်နှာသို့ +first_page.label=ပထမ စာမျက်နှာသို့ +first_page_label=ပထမ စာမျက်နှာသို့ +last_page.title=နောက်ဆုံး စာမျက်နှာသို့ +last_page.label=နောက်ဆုံး စာမျက်နှာသို့ +last_page_label=နောက်ဆုံး စာမျက်နှာသို့ +page_rotate_cw.title=နာရီလက်တံ အတိုင်း +page_rotate_cw.label=နာရီလက်တံ အတိုင်း +page_rotate_cw_label=နာရီလက်တံ အတိုင်း +page_rotate_ccw.title=နာရီလက်တံ ပြောင်းပြန် +page_rotate_ccw.label=နာရီလက်တံ ပြောင်းပြန် +page_rotate_ccw_label=နာရီလက်တံ ပြောင်းပြန် + +hand_tool_enable.title=လက်ကိုင် ကိရိယာအားသုံး +hand_tool_enable_label=လက်ကိုင် ကိရိယာဖွင့် +hand_tool_disable.title=လက်ကိုင် ကိရိယာအားပိတ် +hand_tool_disable_label=လက်ကိုင်ကိရိယာ အားပိတ် + +# Document properties dialog box +document_properties.title=မှတ်တမ်းမှတ်ရာ ဂုဏ်သတ္တိများ +document_properties_label=မှတ်တမ်းမှတ်ရာ ဂုဏ်သတ္တိများ +document_properties_file_name=ဖိုင် : +document_properties_file_size=ဖိုင်ဆိုဒ် : +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} ကီလိုဘိုတ် ({size_kb}}ဘိုတ်) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=ခေါင်းစဉ်‌ - +document_properties_author=ရေးသားသူ: +document_properties_subject=အကြောင်းအရာ:\u0020 +document_properties_keywords=သော့ချက် စာလုံး: +document_properties_creation_date=ထုတ်လုပ်ရက်စွဲ: +document_properties_modification_date=ပြင်ဆင်ရက်စွဲ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=ဖန်တီးသူ: +document_properties_producer=PDF ထုတ်လုပ်သူ: +document_properties_version=PDF ဗားရှင်း: +document_properties_page_count=စာမျက်နှာအရေအတွက်: +document_properties_close=ပိတ် + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=ဘေးတန်းဖွင့်ပိတ် +toggle_sidebar_label=ဖွင့်ပိတ် ဆလိုက်ဒါ +outline.title=စာတမ်း မူကြမ်း ကိုပြပါ +outline_label=စာတမ်း မူကြမ်း +attachments.title=တွဲချက်များ ပြပါ +attachments_label=တွဲထားချက်များ +thumbs.title=ပုံရိပ်ငယ်များကို ပြပါ +thumbs_label=ပုံရိပ်ငယ်များ +findbar.title=Find in Document +findbar_label=ရှာဖွေပါ + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=စာမျက်နှာ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=စာမျက်နှာရဲ့ ပုံရိပ်ငယ် {{page}} + +# Find panel button title and messages +find_label=ရှာဖွေပါ - +find_previous.title=စကားစုရဲ့ အရင် ​ဖြစ်ပွားမှုကို ရှာဖွေပါ +find_previous_label=နောက်သို့ +find_next.title=စကားစုရဲ့ နောက်ထပ် ​ဖြစ်ပွားမှုကို ရှာဖွေပါ +find_next_label=ရှေ့သို့ +find_highlight=အားလုံးကို မျဉ်းသားပါ +find_match_case_label=စာလုံး တိုက်ဆိုင်ပါ +find_reached_top=စာမျက်နှာထိပ် ရောက်နေပြီ၊ အဆုံးကနေ ပြန်စပါ +find_reached_bottom=စာမျက်နှာအဆုံး ရောက်နေပြီ၊ ထိပ်ကနေ ပြန်စပါ +find_not_found=စကားစု မတွေ့ရဘူး + +# Error panel labels +error_more_info=နောက်ထပ်အချက်အလက်များ +error_less_info=အနည်းငယ်မျှသော သတင်းအချက်အလက် +error_close=ပိတ် +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=မက်ဆေ့ - {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=အထပ် - {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ဖိုင် {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=လိုင်း - {{line}} +rendering_error=စာမျက်နှာကို ပုံဖော်နေချိန်မှာ အမှားတစ်ခုတွေ့ရပါတယ်။ + +# Predefined zoom values +page_scale_width=စာမျက်နှာ အကျယ် +page_scale_fit=စာမျက်နှာ ကွက်တိ +page_scale_auto=အလိုအလျောက် ချုံ့ချဲ့ +page_scale_actual=အမှန်တကယ်ရှိတဲ့ အရွယ် +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=အမှား +loading_error=PDF ဖိုင် ကိုဆွဲတင်နေချိန်မှာ အမှားတစ်ခုတွေ့ရပါတယ်။ +invalid_file_error=မရသော သို့ ပျက်နေသော PDF ဖိုင် +missing_file_error=PDF ပျောက်ဆုံး +unexpected_response_error=မမျှော်လင့်ထားသော ဆာဗာမှ ပြန်ကြားချက် + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} အဓိပ္ပာယ်ဖွင့်ဆိုချက်] +password_label=PDF အားဖွင့်ရန် ပတ်စ်ဝတ်အားထည့်ပါ +password_invalid=စာဝှက် မှားသည်။ ထပ်ကြိုးစားကြည့်ပါ။ +password_ok=OK +password_cancel=ပယ်​ဖျက်ပါ + +printing_not_supported=သတိပေးချက်၊ပရင့်ထုတ်ခြင်းကိုဤဘယောက်ဆာသည် ပြည့်ဝစွာထောက်ပံ့မထားပါ ။ +printing_not_ready=သတိပေးချက်: ယခု PDF ဖိုင်သည် ပုံနှိပ်ရန် မပြည့်စုံပါ +web_fonts_disabled=Web fonts are disabled: unable to use embedded PDF fonts. +document_colors_not_allowed=PDF ဖိုင်အား ၎င်းဤ ကိုယ်ပိုင်အရောင်များကို အသုံးပြုခွင့်မပေးထားပါ ။ 'စာမျက်နှာအားလုံးအားအရောင်ရွေးချယ်ခွင့်' အား ယခု ဘယောက်ဆာတွင် ပိတ်ထားခြင်းကြောင့်ဖြစ် သှ် diff --git a/static/pdf.js/locale/nb-NO/viewer.ftl b/static/pdf.js/locale/nb-NO/viewer.ftl deleted file mode 100644 index 6519adb3..00000000 --- a/static/pdf.js/locale/nb-NO/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Forrige side -pdfjs-previous-button-label = Forrige -pdfjs-next-button = - .title = Neste side -pdfjs-next-button-label = Neste -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Side -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = av { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } av { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom ut -pdfjs-zoom-out-button-label = Zoom ut -pdfjs-zoom-in-button = - .title = Zoom inn -pdfjs-zoom-in-button-label = Zoom inn -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Bytt til presentasjonsmodus -pdfjs-presentation-mode-button-label = Presentasjonsmodus -pdfjs-open-file-button = - .title = Åpne fil -pdfjs-open-file-button-label = Åpne -pdfjs-print-button = - .title = Skriv ut -pdfjs-print-button-label = Skriv ut -pdfjs-save-button = - .title = Lagre -pdfjs-save-button-label = Lagre -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Last ned -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Last ned -pdfjs-bookmark-button = - .title = Gjeldende side (se URL fra gjeldende side) -pdfjs-bookmark-button-label = Gjeldende side - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Verktøy -pdfjs-tools-button-label = Verktøy -pdfjs-first-page-button = - .title = Gå til første side -pdfjs-first-page-button-label = Gå til første side -pdfjs-last-page-button = - .title = Gå til siste side -pdfjs-last-page-button-label = Gå til siste side -pdfjs-page-rotate-cw-button = - .title = Roter med klokken -pdfjs-page-rotate-cw-button-label = Roter med klokken -pdfjs-page-rotate-ccw-button = - .title = Roter mot klokken -pdfjs-page-rotate-ccw-button-label = Roter mot klokken -pdfjs-cursor-text-select-tool-button = - .title = Aktiver tekstmarkeringsverktøy -pdfjs-cursor-text-select-tool-button-label = Tekstmarkeringsverktøy -pdfjs-cursor-hand-tool-button = - .title = Aktiver handverktøy -pdfjs-cursor-hand-tool-button-label = Handverktøy -pdfjs-scroll-page-button = - .title = Bruk siderulling -pdfjs-scroll-page-button-label = Siderulling -pdfjs-scroll-vertical-button = - .title = Bruk vertikal rulling -pdfjs-scroll-vertical-button-label = Vertikal rulling -pdfjs-scroll-horizontal-button = - .title = Bruk horisontal rulling -pdfjs-scroll-horizontal-button-label = Horisontal rulling -pdfjs-scroll-wrapped-button = - .title = Bruk flersiderulling -pdfjs-scroll-wrapped-button-label = Flersiderulling -pdfjs-spread-none-button = - .title = Vis enkeltsider -pdfjs-spread-none-button-label = Enkeltsider -pdfjs-spread-odd-button = - .title = Vis oppslag med ulike sidenumre til venstre -pdfjs-spread-odd-button-label = Oppslag med forside -pdfjs-spread-even-button = - .title = Vis oppslag med like sidenumre til venstre -pdfjs-spread-even-button-label = Oppslag uten forside - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumentegenskaper … -pdfjs-document-properties-button-label = Dokumentegenskaper … -pdfjs-document-properties-file-name = Filnavn: -pdfjs-document-properties-file-size = Filstørrelse: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Dokumentegenskaper … -pdfjs-document-properties-author = Forfatter: -pdfjs-document-properties-subject = Emne: -pdfjs-document-properties-keywords = Nøkkelord: -pdfjs-document-properties-creation-date = Opprettet dato: -pdfjs-document-properties-modification-date = Endret dato: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Opprettet av: -pdfjs-document-properties-producer = PDF-verktøy: -pdfjs-document-properties-version = PDF-versjon: -pdfjs-document-properties-page-count = Sideantall: -pdfjs-document-properties-page-size = Sidestørrelse: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = stående -pdfjs-document-properties-page-size-orientation-landscape = liggende -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Hurtig nettvisning: -pdfjs-document-properties-linearized-yes = Ja -pdfjs-document-properties-linearized-no = Nei -pdfjs-document-properties-close-button = Lukk - -## Print - -pdfjs-print-progress-message = Forbereder dokument for utskrift … -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Avbryt -pdfjs-printing-not-supported = Advarsel: Utskrift er ikke fullstendig støttet av denne nettleseren. -pdfjs-printing-not-ready = Advarsel: PDF er ikke fullstendig innlastet for utskrift. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Slå av/på sidestolpe -pdfjs-toggle-sidebar-notification-button = - .title = Vis/gjem sidestolpe (dokumentet inneholder oversikt/vedlegg/lag) -pdfjs-toggle-sidebar-button-label = Slå av/på sidestolpe -pdfjs-document-outline-button = - .title = Vis dokumentdisposisjonen (dobbeltklikk for å utvide/skjule alle elementer) -pdfjs-document-outline-button-label = Dokumentdisposisjon -pdfjs-attachments-button = - .title = Vis vedlegg -pdfjs-attachments-button-label = Vedlegg -pdfjs-layers-button = - .title = Vis lag (dobbeltklikk for å tilbakestille alle lag til standardtilstand) -pdfjs-layers-button-label = Lag -pdfjs-thumbs-button = - .title = Vis miniatyrbilde -pdfjs-thumbs-button-label = Miniatyrbilde -pdfjs-current-outline-item-button = - .title = Finn gjeldende disposisjonselement -pdfjs-current-outline-item-button-label = Gjeldende disposisjonselement -pdfjs-findbar-button = - .title = Finn i dokumentet -pdfjs-findbar-button-label = Finn -pdfjs-additional-layers = Ytterligere lag - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Side { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatyrbilde av side { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Søk - .placeholder = Søk i dokument… -pdfjs-find-previous-button = - .title = Finn forrige forekomst av frasen -pdfjs-find-previous-button-label = Forrige -pdfjs-find-next-button = - .title = Finn neste forekomst av frasen -pdfjs-find-next-button-label = Neste -pdfjs-find-highlight-checkbox = Uthev alle -pdfjs-find-match-case-checkbox-label = Skill store/små bokstaver -pdfjs-find-match-diacritics-checkbox-label = Samsvar diakritiske tegn -pdfjs-find-entire-word-checkbox-label = Hele ord -pdfjs-find-reached-top = Nådde toppen av dokumentet, fortsetter fra bunnen -pdfjs-find-reached-bottom = Nådde bunnen av dokumentet, fortsetter fra toppen -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } av { $total } treff - *[other] { $current } av { $total } treff - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Mer enn { $limit } treff - *[other] Mer enn { $limit } treff - } -pdfjs-find-not-found = Fant ikke teksten - -## Predefined zoom values - -pdfjs-page-scale-width = Sidebredde -pdfjs-page-scale-fit = Tilpass til siden -pdfjs-page-scale-auto = Automatisk zoom -pdfjs-page-scale-actual = Virkelig størrelse -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale } % - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Side { $page } - -## Loading indicator messages - -pdfjs-loading-error = En feil oppstod ved lasting av PDF. -pdfjs-invalid-file-error = Ugyldig eller skadet PDF-fil. -pdfjs-missing-file-error = Manglende PDF-fil. -pdfjs-unexpected-response-error = Uventet serverrespons. -pdfjs-rendering-error = En feil oppstod ved opptegning av siden. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } annotasjon] - -## Password - -pdfjs-password-label = Skriv inn passordet for å åpne denne PDF-filen. -pdfjs-password-invalid = Ugyldig passord. Prøv igjen. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Avbryt -pdfjs-web-fonts-disabled = Web-fonter er avslått: Kan ikke bruke innbundne PDF-fonter. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Tegn -pdfjs-editor-ink-button-label = Tegn -pdfjs-editor-stamp-button = - .title = Legg til eller rediger bilder -pdfjs-editor-stamp-button-label = Legg til eller rediger bilder -pdfjs-editor-highlight-button = - .title = Markere -pdfjs-editor-highlight-button-label = Markere -pdfjs-highlight-floating-button = - .title = Markere -pdfjs-highlight-floating-button1 = - .title = Markere - .aria-label = Markere -pdfjs-highlight-floating-button-label = Markere - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Fjern tegningen -pdfjs-editor-remove-freetext-button = - .title = Fjern tekst -pdfjs-editor-remove-stamp-button = - .title = Fjern bildet -pdfjs-editor-remove-highlight-button = - .title = Fjern utheving - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Farge -pdfjs-editor-free-text-size-input = Størrelse -pdfjs-editor-ink-color-input = Farge -pdfjs-editor-ink-thickness-input = Tykkelse -pdfjs-editor-ink-opacity-input = Ugjennomsiktighet -pdfjs-editor-stamp-add-image-button = - .title = Legg til bilde -pdfjs-editor-stamp-add-image-button-label = Legg til bilde -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tykkelse -pdfjs-editor-free-highlight-thickness-title = - .title = Endre tykkelse når du markerer andre elementer enn tekst -pdfjs-free-text = - .aria-label = Tekstredigering -pdfjs-free-text-default-content = Begynn å skrive… -pdfjs-ink = - .aria-label = Tegneredigering -pdfjs-ink-canvas = - .aria-label = Brukerskapt bilde - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alt-tekst -pdfjs-editor-alt-text-edit-button-label = Rediger alt-tekst tekst -pdfjs-editor-alt-text-dialog-label = Velg et alternativ -pdfjs-editor-alt-text-dialog-description = Alt-tekst (alternativ tekst) hjelper når folk ikke kan se bildet eller når det ikke lastes inn. -pdfjs-editor-alt-text-add-description-label = Legg til en beskrivelse -pdfjs-editor-alt-text-add-description-description = Gå etter 1-2 setninger som beskriver emnet, settingen eller handlingene. -pdfjs-editor-alt-text-mark-decorative-label = Merk som dekorativt -pdfjs-editor-alt-text-mark-decorative-description = Dette brukes til dekorative bilder, som kantlinjer eller vannmerker. -pdfjs-editor-alt-text-cancel-button = Avbryt -pdfjs-editor-alt-text-save-button = Lagre -pdfjs-editor-alt-text-decorative-tooltip = Merket som dekorativ -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = For eksempel, «En ung mann setter seg ved et bord for å spise et måltid» - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Øverste venstre hjørne – endre størrelse -pdfjs-editor-resizer-label-top-middle = Øverst i midten — endre størrelse -pdfjs-editor-resizer-label-top-right = Øverste høyre hjørne – endre størrelse -pdfjs-editor-resizer-label-middle-right = Midt til høyre – endre størrelse -pdfjs-editor-resizer-label-bottom-right = Nederste høyre hjørne – endre størrelse -pdfjs-editor-resizer-label-bottom-middle = Nederst i midten — endre størrelse -pdfjs-editor-resizer-label-bottom-left = Nederste venstre hjørne – endre størrelse -pdfjs-editor-resizer-label-middle-left = Midt til venstre — endre størrelse - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Uthevingsfarge -pdfjs-editor-colorpicker-button = - .title = Endre farge -pdfjs-editor-colorpicker-dropdown = - .aria-label = Fargevalg -pdfjs-editor-colorpicker-yellow = - .title = Gul -pdfjs-editor-colorpicker-green = - .title = Grønn -pdfjs-editor-colorpicker-blue = - .title = Blå -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Rød - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Vis alle -pdfjs-editor-highlight-show-all-button = - .title = Vis alle diff --git a/static/pdf.js/locale/nb-NO/viewer.properties b/static/pdf.js/locale/nb-NO/viewer.properties new file mode 100644 index 00000000..13d3670e --- /dev/null +++ b/static/pdf.js/locale/nb-NO/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Forrige side +previous_label=Forrige +next.title=Neste side +next_label=Neste + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Side: +page_of=av {{pageCount}} + +zoom_out.title=Zoom ut +zoom_out_label=Zoom ut +zoom_in.title=Zoom inn +zoom_in_label=Zoom inn +zoom.title=Zoom +presentation_mode.title=Bytt til presentasjonsmodus +presentation_mode_label=Presentasjonsmodus +open_file.title=Åpne fil +open_file_label=Åpne +print.title=Skriv ut +print_label=Skriv ut +download.title=Last ned +download_label=Last ned +bookmark.title=Nåværende visning (kopier eller åpne i et nytt vindu) +bookmark_label=Nåværende visning + +# Secondary toolbar and context menu +tools.title=Verktøy +tools_label=Verktøy +first_page.title=Gå til første side +first_page.label=Gå til første side +first_page_label=Gå til første side +last_page.title=Gå til siste side +last_page.label=Gå til siste side +last_page_label=Gå til siste side +page_rotate_cw.title=Roter med klokken +page_rotate_cw.label=Roter med klokken +page_rotate_cw_label=Roter med klokken +page_rotate_ccw.title=Roter mot klokken +page_rotate_ccw.label=Roter mot klokken +page_rotate_ccw_label=Roter mot klokken + +hand_tool_enable.title=Slå på hånd-verktøy +hand_tool_enable_label=Slå på hånd-verktøy +hand_tool_disable.title=Slå av hånd-verktøy +hand_tool_disable_label=Slå av hånd-verktøy + +# Document properties dialog box +document_properties.title=Dokumentegenskaper … +document_properties_label=Dokumentegenskaper … +document_properties_file_name=Filnavn: +document_properties_file_size=Filstørrelse: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Dokumentegenskaper … +document_properties_author=Forfatter: +document_properties_subject=Emne: +document_properties_keywords=Nøkkelord: +document_properties_creation_date=Opprettet dato: +document_properties_modification_date=Endret dato: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Opprettet av: +document_properties_producer=PDF-verktøy: +document_properties_version=PDF-versjon: +document_properties_page_count=Sideantall: +document_properties_close=Lukk + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Slå av/på sidestolpe +toggle_sidebar_label=Slå av/på sidestolpe +outline.title=Vis dokumentdisposisjon +outline_label=Dokumentdisposisjon +attachments.title=Vis vedlegg +attachments_label=Vedlegg +thumbs.title=Vis miniatyrbilde +thumbs_label=Miniatyrbilde +findbar.title=Finn i dokumentet +findbar_label=Finn + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Side {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatyrbilde av side {{page}} + +# Find panel button title and messages +find_label=Finn: +find_previous.title=Finn forrige forekomst av frasen +find_previous_label=Forrige +find_next.title=Finn neste forekomst av frasen +find_next_label=Neste +find_highlight=Uthev alle +find_match_case_label=Skill store/små bokstaver +find_reached_top=Nådde toppen av dokumentet, fortsetter fra bunnen +find_reached_bottom=Nådde bunnen av dokumentet, fortsetter fra toppen +find_not_found=Fant ikke teksten + +# Error panel labels +error_more_info=Mer info +error_less_info=Mindre info +error_close=Lukk +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (bygg: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Melding: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stakk: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fil: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linje: {{line}} +rendering_error=En feil oppstod ved opptegning av siden. + +# Predefined zoom values +page_scale_width=Sidebredde +page_scale_fit=Tilpass til siden +page_scale_auto=Automatisk zoom +page_scale_actual=Virkelig størrelse +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}} % + +# Loading indicator messages +loading_error_indicator=Feil +loading_error=En feil oppstod ved lasting av PDF. +invalid_file_error=Ugyldig eller skadet PDF-fil. +missing_file_error=Manglende PDF-fil. +unexpected_response_error=Uventet serverrespons. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} annotasjon] +password_label=Skriv inn passordet for å åpne denne PDF-filen. +password_invalid=Ugyldig passord. Prøv igjen. +password_ok=OK +password_cancel=Avbryt + +printing_not_supported=Advarsel: Utskrift er ikke fullstendig støttet av denne nettleseren. +printing_not_ready=Advarsel: PDF er ikke fullstendig innlastet for utskrift. +web_fonts_disabled=Web-fonter er avslått: Kan ikke bruke innbundne PDF-fonter. +document_colors_not_allowed=PDF-dokumenter tillates ikke å bruke deres egne farger: 'Tillat sider å velge egne farger' er deaktivert i nettleseren. diff --git a/static/pdf.js/locale/ne-NP/viewer.ftl b/static/pdf.js/locale/ne-NP/viewer.ftl deleted file mode 100644 index 65193b6e..00000000 --- a/static/pdf.js/locale/ne-NP/viewer.ftl +++ /dev/null @@ -1,234 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = अघिल्लो पृष्ठ -pdfjs-previous-button-label = अघिल्लो -pdfjs-next-button = - .title = पछिल्लो पृष्ठ -pdfjs-next-button-label = पछिल्लो -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = पृष्ठ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } मध्ये -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pagesCount } को { $pageNumber }) -pdfjs-zoom-out-button = - .title = जुम घटाउनुहोस् -pdfjs-zoom-out-button-label = जुम घटाउनुहोस् -pdfjs-zoom-in-button = - .title = जुम बढाउनुहोस् -pdfjs-zoom-in-button-label = जुम बढाउनुहोस् -pdfjs-zoom-select = - .title = जुम गर्नुहोस् -pdfjs-presentation-mode-button = - .title = प्रस्तुति मोडमा जानुहोस् -pdfjs-presentation-mode-button-label = प्रस्तुति मोड -pdfjs-open-file-button = - .title = फाइल खोल्नुहोस् -pdfjs-open-file-button-label = खोल्नुहोस् -pdfjs-print-button = - .title = मुद्रण गर्नुहोस् -pdfjs-print-button-label = मुद्रण गर्नुहोस् - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = औजारहरू -pdfjs-tools-button-label = औजारहरू -pdfjs-first-page-button = - .title = पहिलो पृष्ठमा जानुहोस् -pdfjs-first-page-button-label = पहिलो पृष्ठमा जानुहोस् -pdfjs-last-page-button = - .title = पछिल्लो पृष्ठमा जानुहोस् -pdfjs-last-page-button-label = पछिल्लो पृष्ठमा जानुहोस् -pdfjs-page-rotate-cw-button = - .title = घडीको दिशामा घुमाउनुहोस् -pdfjs-page-rotate-cw-button-label = घडीको दिशामा घुमाउनुहोस् -pdfjs-page-rotate-ccw-button = - .title = घडीको विपरित दिशामा घुमाउनुहोस् -pdfjs-page-rotate-ccw-button-label = घडीको विपरित दिशामा घुमाउनुहोस् -pdfjs-cursor-text-select-tool-button = - .title = पाठ चयन उपकरण सक्षम गर्नुहोस् -pdfjs-cursor-text-select-tool-button-label = पाठ चयन उपकरण -pdfjs-cursor-hand-tool-button = - .title = हाते उपकरण सक्षम गर्नुहोस् -pdfjs-cursor-hand-tool-button-label = हाते उपकरण -pdfjs-scroll-vertical-button = - .title = ठाडो स्क्रोलिङ्ग प्रयोग गर्नुहोस् -pdfjs-scroll-vertical-button-label = ठाडो स्क्र्रोलिङ्ग -pdfjs-scroll-horizontal-button = - .title = तेर्सो स्क्रोलिङ्ग प्रयोग गर्नुहोस् -pdfjs-scroll-horizontal-button-label = तेर्सो स्क्रोलिङ्ग -pdfjs-scroll-wrapped-button = - .title = लिपि स्क्रोलिङ्ग प्रयोग गर्नुहोस् -pdfjs-scroll-wrapped-button-label = लिपि स्क्रोलिङ्ग -pdfjs-spread-none-button = - .title = पृष्ठ स्प्रेडमा सामेल हुनुहुन्न -pdfjs-spread-none-button-label = स्प्रेड छैन - -## Document properties dialog - -pdfjs-document-properties-button = - .title = कागजात विशेषताहरू... -pdfjs-document-properties-button-label = कागजात विशेषताहरू... -pdfjs-document-properties-file-name = फाइल नाम: -pdfjs-document-properties-file-size = फाइल आकार: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = शीर्षक: -pdfjs-document-properties-author = लेखक: -pdfjs-document-properties-subject = विषयः -pdfjs-document-properties-keywords = शब्दकुञ्जीः -pdfjs-document-properties-creation-date = सिर्जना गरिएको मिति: -pdfjs-document-properties-modification-date = परिमार्जित मिति: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = सर्जक: -pdfjs-document-properties-producer = PDF निर्माता: -pdfjs-document-properties-version = PDF संस्करण -pdfjs-document-properties-page-count = पृष्ठ गणना: -pdfjs-document-properties-page-size = पृष्ठ आकार: -pdfjs-document-properties-page-size-unit-inches = इन्च -pdfjs-document-properties-page-size-unit-millimeters = मि.मि. -pdfjs-document-properties-page-size-orientation-portrait = पोट्रेट -pdfjs-document-properties-page-size-orientation-landscape = परिदृश्य -pdfjs-document-properties-page-size-name-letter = अक्षर -pdfjs-document-properties-page-size-name-legal = कानूनी - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -pdfjs-document-properties-linearized-yes = हो -pdfjs-document-properties-linearized-no = होइन -pdfjs-document-properties-close-button = बन्द गर्नुहोस् - -## Print - -pdfjs-print-progress-message = मुद्रणका लागि कागजात तयारी गरिदै… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = रद्द गर्नुहोस् -pdfjs-printing-not-supported = चेतावनी: यो ब्राउजरमा मुद्रण पूर्णतया समर्थित छैन। -pdfjs-printing-not-ready = चेतावनी: PDF मुद्रणका लागि पूर्णतया लोड भएको छैन। - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = टगल साइडबार -pdfjs-toggle-sidebar-button-label = टगल साइडबार -pdfjs-document-outline-button = - .title = कागजातको रूपरेखा देखाउनुहोस् (सबै वस्तुहरू विस्तार/पतन गर्न डबल-क्लिक गर्नुहोस्) -pdfjs-document-outline-button-label = दस्तावेजको रूपरेखा -pdfjs-attachments-button = - .title = संलग्नहरू देखाउनुहोस् -pdfjs-attachments-button-label = संलग्नकहरू -pdfjs-thumbs-button = - .title = थम्बनेलहरू देखाउनुहोस् -pdfjs-thumbs-button-label = थम्बनेलहरू -pdfjs-findbar-button = - .title = कागजातमा फेला पार्नुहोस् -pdfjs-findbar-button-label = फेला पार्नुहोस् - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = पृष्ठ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } पृष्ठको थम्बनेल - -## Find panel button title and messages - -pdfjs-find-input = - .title = फेला पार्नुहोस् - .placeholder = कागजातमा फेला पार्नुहोस्… -pdfjs-find-previous-button = - .title = यस वाक्यांशको अघिल्लो घटना फेला पार्नुहोस् -pdfjs-find-previous-button-label = अघिल्लो -pdfjs-find-next-button = - .title = यस वाक्यांशको पछिल्लो घटना फेला पार्नुहोस् -pdfjs-find-next-button-label = अर्को -pdfjs-find-highlight-checkbox = सबै हाइलाइट गर्ने -pdfjs-find-match-case-checkbox-label = केस जोडा मिलाउनुहोस् -pdfjs-find-entire-word-checkbox-label = पुरा शब्दहरु -pdfjs-find-reached-top = पृष्ठको शिर्षमा पुगीयो, तलबाट जारी गरिएको थियो -pdfjs-find-reached-bottom = पृष्ठको अन्त्यमा पुगीयो, शिर्षबाट जारी गरिएको थियो -pdfjs-find-not-found = वाक्यांश फेला परेन - -## Predefined zoom values - -pdfjs-page-scale-width = पृष्ठ चौडाइ -pdfjs-page-scale-fit = पृष्ठ ठिक्क मिल्ने -pdfjs-page-scale-auto = स्वचालित जुम -pdfjs-page-scale-actual = वास्तविक आकार -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = यो PDF लोड गर्दा एउटा त्रुटि देखापर्‍यो। -pdfjs-invalid-file-error = अवैध वा दुषित PDF फाइल। -pdfjs-missing-file-error = हराईरहेको PDF फाइल। -pdfjs-unexpected-response-error = अप्रत्याशित सर्भर प्रतिक्रिया। -pdfjs-rendering-error = पृष्ठ प्रतिपादन गर्दा एउटा त्रुटि देखापर्‍यो। - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = यस PDF फाइललाई खोल्न गोप्यशब्द प्रविष्ट गर्नुहोस्। -pdfjs-password-invalid = अवैध गोप्यशब्द। पुनः प्रयास गर्नुहोस्। -pdfjs-password-ok-button = ठिक छ -pdfjs-password-cancel-button = रद्द गर्नुहोस् -pdfjs-web-fonts-disabled = वेब फन्ट असक्षम छन्: एम्बेडेड PDF फन्ट प्रयोग गर्न असमर्थ। - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/nl/viewer.ftl b/static/pdf.js/locale/nl/viewer.ftl deleted file mode 100644 index a1dd47d3..00000000 --- a/static/pdf.js/locale/nl/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Vorige pagina -pdfjs-previous-button-label = Vorige -pdfjs-next-button = - .title = Volgende pagina -pdfjs-next-button-label = Volgende -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pagina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = van { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } van { $pagesCount }) -pdfjs-zoom-out-button = - .title = Uitzoomen -pdfjs-zoom-out-button-label = Uitzoomen -pdfjs-zoom-in-button = - .title = Inzoomen -pdfjs-zoom-in-button-label = Inzoomen -pdfjs-zoom-select = - .title = Zoomen -pdfjs-presentation-mode-button = - .title = Wisselen naar presentatiemodus -pdfjs-presentation-mode-button-label = Presentatiemodus -pdfjs-open-file-button = - .title = Bestand openen -pdfjs-open-file-button-label = Openen -pdfjs-print-button = - .title = Afdrukken -pdfjs-print-button-label = Afdrukken -pdfjs-save-button = - .title = Opslaan -pdfjs-save-button-label = Opslaan -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Downloaden -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Downloaden -pdfjs-bookmark-button = - .title = Huidige pagina (URL van huidige pagina bekijken) -pdfjs-bookmark-button-label = Huidige pagina -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Openen in app -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Openen in app - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Hulpmiddelen -pdfjs-tools-button-label = Hulpmiddelen -pdfjs-first-page-button = - .title = Naar eerste pagina gaan -pdfjs-first-page-button-label = Naar eerste pagina gaan -pdfjs-last-page-button = - .title = Naar laatste pagina gaan -pdfjs-last-page-button-label = Naar laatste pagina gaan -pdfjs-page-rotate-cw-button = - .title = Rechtsom draaien -pdfjs-page-rotate-cw-button-label = Rechtsom draaien -pdfjs-page-rotate-ccw-button = - .title = Linksom draaien -pdfjs-page-rotate-ccw-button-label = Linksom draaien -pdfjs-cursor-text-select-tool-button = - .title = Tekstselectiehulpmiddel inschakelen -pdfjs-cursor-text-select-tool-button-label = Tekstselectiehulpmiddel -pdfjs-cursor-hand-tool-button = - .title = Handhulpmiddel inschakelen -pdfjs-cursor-hand-tool-button-label = Handhulpmiddel -pdfjs-scroll-page-button = - .title = Paginascrollen gebruiken -pdfjs-scroll-page-button-label = Paginascrollen -pdfjs-scroll-vertical-button = - .title = Verticaal scrollen gebruiken -pdfjs-scroll-vertical-button-label = Verticaal scrollen -pdfjs-scroll-horizontal-button = - .title = Horizontaal scrollen gebruiken -pdfjs-scroll-horizontal-button-label = Horizontaal scrollen -pdfjs-scroll-wrapped-button = - .title = Scrollen met terugloop gebruiken -pdfjs-scroll-wrapped-button-label = Scrollen met terugloop -pdfjs-spread-none-button = - .title = Dubbele pagina’s niet samenvoegen -pdfjs-spread-none-button-label = Geen dubbele pagina’s -pdfjs-spread-odd-button = - .title = Dubbele pagina’s samenvoegen vanaf oneven pagina’s -pdfjs-spread-odd-button-label = Oneven dubbele pagina’s -pdfjs-spread-even-button = - .title = Dubbele pagina’s samenvoegen vanaf even pagina’s -pdfjs-spread-even-button-label = Even dubbele pagina’s - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Documenteigenschappen… -pdfjs-document-properties-button-label = Documenteigenschappen… -pdfjs-document-properties-file-name = Bestandsnaam: -pdfjs-document-properties-file-size = Bestandsgrootte: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Titel: -pdfjs-document-properties-author = Auteur: -pdfjs-document-properties-subject = Onderwerp: -pdfjs-document-properties-keywords = Sleutelwoorden: -pdfjs-document-properties-creation-date = Aanmaakdatum: -pdfjs-document-properties-modification-date = Wijzigingsdatum: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Maker: -pdfjs-document-properties-producer = PDF-producent: -pdfjs-document-properties-version = PDF-versie: -pdfjs-document-properties-page-count = Aantal pagina’s: -pdfjs-document-properties-page-size = Paginagrootte: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = staand -pdfjs-document-properties-page-size-orientation-landscape = liggend -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Snelle webweergave: -pdfjs-document-properties-linearized-yes = Ja -pdfjs-document-properties-linearized-no = Nee -pdfjs-document-properties-close-button = Sluiten - -## Print - -pdfjs-print-progress-message = Document voorbereiden voor afdrukken… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Annuleren -pdfjs-printing-not-supported = Waarschuwing: afdrukken wordt niet volledig ondersteund door deze browser. -pdfjs-printing-not-ready = Waarschuwing: de PDF is niet volledig geladen voor afdrukken. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Zijbalk in-/uitschakelen -pdfjs-toggle-sidebar-notification-button = - .title = Zijbalk in-/uitschakelen (document bevat overzicht/bijlagen/lagen) -pdfjs-toggle-sidebar-button-label = Zijbalk in-/uitschakelen -pdfjs-document-outline-button = - .title = Documentoverzicht tonen (dubbelklik om alle items uit/samen te vouwen) -pdfjs-document-outline-button-label = Documentoverzicht -pdfjs-attachments-button = - .title = Bijlagen tonen -pdfjs-attachments-button-label = Bijlagen -pdfjs-layers-button = - .title = Lagen tonen (dubbelklik om alle lagen naar de standaardstatus terug te zetten) -pdfjs-layers-button-label = Lagen -pdfjs-thumbs-button = - .title = Miniaturen tonen -pdfjs-thumbs-button-label = Miniaturen -pdfjs-current-outline-item-button = - .title = Huidig item in inhoudsopgave zoeken -pdfjs-current-outline-item-button-label = Huidig item in inhoudsopgave -pdfjs-findbar-button = - .title = Zoeken in document -pdfjs-findbar-button-label = Zoeken -pdfjs-additional-layers = Aanvullende lagen - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pagina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatuur van pagina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Zoeken - .placeholder = Zoeken in document… -pdfjs-find-previous-button = - .title = De vorige overeenkomst van de tekst zoeken -pdfjs-find-previous-button-label = Vorige -pdfjs-find-next-button = - .title = De volgende overeenkomst van de tekst zoeken -pdfjs-find-next-button-label = Volgende -pdfjs-find-highlight-checkbox = Alles markeren -pdfjs-find-match-case-checkbox-label = Hoofdlettergevoelig -pdfjs-find-match-diacritics-checkbox-label = Diakritische tekens gebruiken -pdfjs-find-entire-word-checkbox-label = Hele woorden -pdfjs-find-reached-top = Bovenkant van document bereikt, doorgegaan vanaf onderkant -pdfjs-find-reached-bottom = Onderkant van document bereikt, doorgegaan vanaf bovenkant -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } van { $total } overeenkomst - *[other] { $current } van { $total } overeenkomsten - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Meer dan { $limit } overeenkomst - *[other] Meer dan { $limit } overeenkomsten - } -pdfjs-find-not-found = Tekst niet gevonden - -## Predefined zoom values - -pdfjs-page-scale-width = Paginabreedte -pdfjs-page-scale-fit = Hele pagina -pdfjs-page-scale-auto = Automatisch zoomen -pdfjs-page-scale-actual = Werkelijke grootte -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pagina { $page } - -## Loading indicator messages - -pdfjs-loading-error = Er is een fout opgetreden bij het laden van de PDF. -pdfjs-invalid-file-error = Ongeldig of beschadigd PDF-bestand. -pdfjs-missing-file-error = PDF-bestand ontbreekt. -pdfjs-unexpected-response-error = Onverwacht serverantwoord. -pdfjs-rendering-error = Er is een fout opgetreden bij het weergeven van de pagina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type }-aantekening] - -## Password - -pdfjs-password-label = Voer het wachtwoord in om dit PDF-bestand te openen. -pdfjs-password-invalid = Ongeldig wachtwoord. Probeer het opnieuw. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Annuleren -pdfjs-web-fonts-disabled = Weblettertypen zijn uitgeschakeld: gebruik van ingebedde PDF-lettertypen is niet mogelijk. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Tekenen -pdfjs-editor-ink-button-label = Tekenen -pdfjs-editor-stamp-button = - .title = Afbeeldingen toevoegen of bewerken -pdfjs-editor-stamp-button-label = Afbeeldingen toevoegen of bewerken -pdfjs-editor-highlight-button = - .title = Markeren -pdfjs-editor-highlight-button-label = Markeren -pdfjs-highlight-floating-button = - .title = Markeren -pdfjs-highlight-floating-button1 = - .title = Markeren - .aria-label = Markeren -pdfjs-highlight-floating-button-label = Markeren - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Tekening verwijderen -pdfjs-editor-remove-freetext-button = - .title = Tekst verwijderen -pdfjs-editor-remove-stamp-button = - .title = Afbeelding verwijderen -pdfjs-editor-remove-highlight-button = - .title = Markering verwijderen - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Kleur -pdfjs-editor-free-text-size-input = Grootte -pdfjs-editor-ink-color-input = Kleur -pdfjs-editor-ink-thickness-input = Dikte -pdfjs-editor-ink-opacity-input = Opaciteit -pdfjs-editor-stamp-add-image-button = - .title = Afbeelding toevoegen -pdfjs-editor-stamp-add-image-button-label = Afbeelding toevoegen -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Dikte -pdfjs-editor-free-highlight-thickness-title = - .title = Dikte wijzigen bij accentuering van andere items dan tekst -pdfjs-free-text = - .aria-label = Tekstbewerker -pdfjs-free-text-default-content = Begin met typen… -pdfjs-ink = - .aria-label = Tekeningbewerker -pdfjs-ink-canvas = - .aria-label = Door gebruiker gemaakte afbeelding - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternatieve tekst -pdfjs-editor-alt-text-edit-button-label = Alternatieve tekst bewerken -pdfjs-editor-alt-text-dialog-label = Kies een optie -pdfjs-editor-alt-text-dialog-description = Alternatieve tekst helpt wanneer mensen de afbeelding niet kunnen zien of wanneer deze niet wordt geladen. -pdfjs-editor-alt-text-add-description-label = Voeg een beschrijving toe -pdfjs-editor-alt-text-add-description-description = Streef naar 1-2 zinnen die het onderwerp, de omgeving of de acties beschrijven. -pdfjs-editor-alt-text-mark-decorative-label = Als decoratief markeren -pdfjs-editor-alt-text-mark-decorative-description = Dit wordt gebruikt voor sierafbeeldingen, zoals randen of watermerken. -pdfjs-editor-alt-text-cancel-button = Annuleren -pdfjs-editor-alt-text-save-button = Opslaan -pdfjs-editor-alt-text-decorative-tooltip = Als decoratief gemarkeerd -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Bijvoorbeeld: ‘Een jonge man gaat aan een tafel zitten om te eten’ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Linkerbovenhoek – formaat wijzigen -pdfjs-editor-resizer-label-top-middle = Midden boven – formaat wijzigen -pdfjs-editor-resizer-label-top-right = Rechterbovenhoek – formaat wijzigen -pdfjs-editor-resizer-label-middle-right = Midden rechts – formaat wijzigen -pdfjs-editor-resizer-label-bottom-right = Rechterbenedenhoek – formaat wijzigen -pdfjs-editor-resizer-label-bottom-middle = Midden onder – formaat wijzigen -pdfjs-editor-resizer-label-bottom-left = Linkerbenedenhoek – formaat wijzigen -pdfjs-editor-resizer-label-middle-left = Links midden – formaat wijzigen - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Markeringskleur -pdfjs-editor-colorpicker-button = - .title = Kleur wijzigen -pdfjs-editor-colorpicker-dropdown = - .aria-label = Kleurkeuzes -pdfjs-editor-colorpicker-yellow = - .title = Geel -pdfjs-editor-colorpicker-green = - .title = Groen -pdfjs-editor-colorpicker-blue = - .title = Blauw -pdfjs-editor-colorpicker-pink = - .title = Roze -pdfjs-editor-colorpicker-red = - .title = Rood - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Alles tonen -pdfjs-editor-highlight-show-all-button = - .title = Alles tonen diff --git a/static/pdf.js/locale/nl/viewer.properties b/static/pdf.js/locale/nl/viewer.properties new file mode 100644 index 00000000..1481904f --- /dev/null +++ b/static/pdf.js/locale/nl/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Vorige pagina +previous_label=Vorige +next.title=Volgende pagina +next_label=Volgende + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pagina: +page_of=van {{pageCount}} + +zoom_out.title=Uitzoomen +zoom_out_label=Uitzoomen +zoom_in.title=Inzoomen +zoom_in_label=Inzoomen +zoom.title=Zoomen +presentation_mode.title=Wisselen naar presentatiemodus +presentation_mode_label=Presentatiemodus +open_file.title=Bestand openen +open_file_label=Openen +print.title=Afdrukken +print_label=Afdrukken +download.title=Downloaden +download_label=Downloaden +bookmark.title=Huidige weergave (kopiëren of openen in nieuw venster) +bookmark_label=Huidige weergave + +# Secondary toolbar and context menu +tools.title=Hulpmiddelen +tools_label=Hulpmiddelen +first_page.title=Naar eerste pagina gaan +first_page.label=Naar eerste pagina gaan +first_page_label=Naar eerste pagina gaan +last_page.title=Naar laatste pagina gaan +last_page.label=Naar laatste pagina gaan +last_page_label=Naar laatste pagina gaan +page_rotate_cw.title=Rechtsom draaien +page_rotate_cw.label=Rechtsom draaien +page_rotate_cw_label=Rechtsom draaien +page_rotate_ccw.title=Linksom draaien +page_rotate_ccw.label=Linksom draaien +page_rotate_ccw_label=Linksom draaien + +hand_tool_enable.title=Handhulpmiddel inschakelen +hand_tool_enable_label=Handhulpmiddel inschakelen +hand_tool_disable.title=Handhulpmiddel uitschakelen +hand_tool_disable_label=Handhulpmiddel uitschakelen + +# Document properties dialog box +document_properties.title=Documenteigenschappen… +document_properties_label=Documenteigenschappen… +document_properties_file_name=Bestandsnaam: +document_properties_file_size=Bestandsgrootte: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Titel: +document_properties_author=Auteur: +document_properties_subject=Onderwerp: +document_properties_keywords=Trefwoorden: +document_properties_creation_date=Aanmaakdatum: +document_properties_modification_date=Wijzigingsdatum: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Auteur: +document_properties_producer=PDF-producent: +document_properties_version=PDF-versie: +document_properties_page_count=Aantal pagina’s: +document_properties_close=Sluiten + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Zijbalk in-/uitschakelen +toggle_sidebar_label=Zijbalk in-/uitschakelen +outline.title=Documentoverzicht tonen +outline_label=Documentoverzicht +attachments.title=Bijlagen tonen +attachments_label=Bijlagen +thumbs.title=Miniaturen tonen +thumbs_label=Miniaturen +findbar.title=Zoeken in document +findbar_label=Zoeken + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pagina {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatuur van pagina {{page}} + +# Find panel button title and messages +find_label=Zoeken: +find_previous.title=Het vorige voorkomen van de tekst zoeken +find_previous_label=Vorige +find_next.title=Het volgende voorkomen van de tekst zoeken +find_next_label=Volgende +find_highlight=Alles markeren +find_match_case_label=Hoofdlettergevoelig +find_reached_top=Bovenkant van het document bereikt, doorgegaan vanaf de onderkant +find_reached_bottom=Onderkant van het document bereikt, doorgegaan vanaf de bovenkant +find_not_found=Tekst niet gevonden + +# Error panel labels +error_more_info=Meer informatie +error_less_info=Minder informatie +error_close=Sluiten +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Bericht: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Bestand: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Regel: {{line}} +rendering_error=Er is een fout opgetreden bij het weergeven van de pagina. + +# Predefined zoom values +page_scale_width=Paginabreedte +page_scale_fit=Hele pagina +page_scale_auto=Automatisch zoomen +page_scale_actual=Werkelijke grootte +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Fout +loading_error=Er is een fout opgetreden bij het laden van de PDF. +invalid_file_error=Ongeldig of beschadigd PDF-bestand. +missing_file_error=PDF-bestand ontbreekt. +unexpected_response_error=Onverwacht serverantwoord. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}}-aantekening] +password_label=Voer het wachtwoord in om dit PDF-bestand te openen. +password_invalid=Ongeldig wachtwoord. Probeer het opnieuw. +password_ok=OK +password_cancel=Annuleren + +printing_not_supported=Waarschuwing: afdrukken wordt niet volledig ondersteund door deze browser. +printing_not_ready=Waarschuwing: de PDF is niet volledig geladen voor afdrukken. +web_fonts_disabled=Weblettertypen zijn uitgeschakeld: gebruik van ingebedde PDF-lettertypen is niet mogelijk. +document_colors_not_allowed=PDF-documenten mogen hun eigen kleuren niet gebruiken: ‘Pagina’s toestaan om hun eigen kleuren te kiezen’ is uitgeschakeld in de browser. diff --git a/static/pdf.js/locale/nn-NO/viewer.ftl b/static/pdf.js/locale/nn-NO/viewer.ftl deleted file mode 100644 index e32b147c..00000000 --- a/static/pdf.js/locale/nn-NO/viewer.ftl +++ /dev/null @@ -1,394 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Føregåande side -pdfjs-previous-button-label = Føregåande -pdfjs-next-button = - .title = Neste side -pdfjs-next-button-label = Neste -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Side -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = av { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } av { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom ut -pdfjs-zoom-out-button-label = Zoom ut -pdfjs-zoom-in-button = - .title = Zoom inn -pdfjs-zoom-in-button-label = Zoom inn -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Byt til presentasjonsmodus -pdfjs-presentation-mode-button-label = Presentasjonsmodus -pdfjs-open-file-button = - .title = Opne fil -pdfjs-open-file-button-label = Opne -pdfjs-print-button = - .title = Skriv ut -pdfjs-print-button-label = Skriv ut -pdfjs-save-button = - .title = Lagre -pdfjs-save-button-label = Lagre -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Last ned -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Last ned -pdfjs-bookmark-button = - .title = Gjeldande side (sjå URL frå gjeldande side) -pdfjs-bookmark-button-label = Gjeldande side - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Verktøy -pdfjs-tools-button-label = Verktøy -pdfjs-first-page-button = - .title = Gå til første side -pdfjs-first-page-button-label = Gå til første side -pdfjs-last-page-button = - .title = Gå til siste side -pdfjs-last-page-button-label = Gå til siste side -pdfjs-page-rotate-cw-button = - .title = Roter med klokka -pdfjs-page-rotate-cw-button-label = Roter med klokka -pdfjs-page-rotate-ccw-button = - .title = Roter mot klokka -pdfjs-page-rotate-ccw-button-label = Roter mot klokka -pdfjs-cursor-text-select-tool-button = - .title = Aktiver tekstmarkeringsverktøy -pdfjs-cursor-text-select-tool-button-label = Tekstmarkeringsverktøy -pdfjs-cursor-hand-tool-button = - .title = Aktiver handverktøy -pdfjs-cursor-hand-tool-button-label = Handverktøy -pdfjs-scroll-page-button = - .title = Bruk siderulling -pdfjs-scroll-page-button-label = Siderulling -pdfjs-scroll-vertical-button = - .title = Bruk vertikal rulling -pdfjs-scroll-vertical-button-label = Vertikal rulling -pdfjs-scroll-horizontal-button = - .title = Bruk horisontal rulling -pdfjs-scroll-horizontal-button-label = Horisontal rulling -pdfjs-scroll-wrapped-button = - .title = Bruk fleirsiderulling -pdfjs-scroll-wrapped-button-label = Fleirsiderulling -pdfjs-spread-none-button = - .title = Vis enkeltsider -pdfjs-spread-none-button-label = Enkeltside -pdfjs-spread-odd-button = - .title = Vis oppslag med ulike sidenummer til venstre -pdfjs-spread-odd-button-label = Oppslag med framside -pdfjs-spread-even-button = - .title = Vis oppslag med like sidenummmer til venstre -pdfjs-spread-even-button-label = Oppslag utan framside - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumenteigenskapar… -pdfjs-document-properties-button-label = Dokumenteigenskapar… -pdfjs-document-properties-file-name = Filnamn: -pdfjs-document-properties-file-size = Filstorleik: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Tittel: -pdfjs-document-properties-author = Forfattar: -pdfjs-document-properties-subject = Emne: -pdfjs-document-properties-keywords = Stikkord: -pdfjs-document-properties-creation-date = Dato oppretta: -pdfjs-document-properties-modification-date = Dato endra: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Oppretta av: -pdfjs-document-properties-producer = PDF-verktøy: -pdfjs-document-properties-version = PDF-versjon: -pdfjs-document-properties-page-count = Sidetal: -pdfjs-document-properties-page-size = Sidestørrelse: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = ståande -pdfjs-document-properties-page-size-orientation-landscape = liggande -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Brev -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Rask nettvising: -pdfjs-document-properties-linearized-yes = Ja -pdfjs-document-properties-linearized-no = Nei -pdfjs-document-properties-close-button = Lat att - -## Print - -pdfjs-print-progress-message = Førebur dokumentet for utskrift… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Avbryt -pdfjs-printing-not-supported = Åtvaring: Utskrift er ikkje fullstendig støtta av denne nettlesaren. -pdfjs-printing-not-ready = Åtvaring: PDF ikkje fullstendig innlasta for utskrift. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Slå av/på sidestolpe -pdfjs-toggle-sidebar-notification-button = - .title = Vis/gøym sidestolpe (dokumentet inneheld oversikt/vedlegg/lag) -pdfjs-toggle-sidebar-button-label = Slå av/på sidestolpe -pdfjs-document-outline-button = - .title = Vis dokumentdisposisjonen (dobbelklikk for å utvide/gøyme alle elementa) -pdfjs-document-outline-button-label = Dokumentdisposisjon -pdfjs-attachments-button = - .title = Vis vedlegg -pdfjs-attachments-button-label = Vedlegg -pdfjs-layers-button = - .title = Vis lag (dobbeltklikk for å tilbakestille alle lag til standardtilstand) -pdfjs-layers-button-label = Lag -pdfjs-thumbs-button = - .title = Vis miniatyrbilde -pdfjs-thumbs-button-label = Miniatyrbilde -pdfjs-current-outline-item-button = - .title = Finn gjeldande disposisjonselement -pdfjs-current-outline-item-button-label = Gjeldande disposisjonselement -pdfjs-findbar-button = - .title = Finn i dokumentet -pdfjs-findbar-button-label = Finn -pdfjs-additional-layers = Ytterlegare lag - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Side { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatyrbilde av side { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Søk - .placeholder = Søk i dokument… -pdfjs-find-previous-button = - .title = Finn førre førekomst av frasen -pdfjs-find-previous-button-label = Førre -pdfjs-find-next-button = - .title = Finn neste førekomst av frasen -pdfjs-find-next-button-label = Neste -pdfjs-find-highlight-checkbox = Uthev alle -pdfjs-find-match-case-checkbox-label = Skil store/små bokstavar -pdfjs-find-match-diacritics-checkbox-label = Samsvar diakritiske teikn -pdfjs-find-entire-word-checkbox-label = Heile ord -pdfjs-find-reached-top = Nådde toppen av dokumentet, fortset frå botnen -pdfjs-find-reached-bottom = Nådde botnen av dokumentet, fortset frå toppen -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } av { $total } treff - *[other] { $current } av { $total } treff - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Meir enn { $limit } treff - *[other] Meir enn { $limit } treff - } -pdfjs-find-not-found = Fann ikkje teksten - -## Predefined zoom values - -pdfjs-page-scale-width = Sidebreidde -pdfjs-page-scale-fit = Tilpass til sida -pdfjs-page-scale-auto = Automatisk skalering -pdfjs-page-scale-actual = Verkeleg storleik -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Side { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ein feil oppstod ved lasting av PDF. -pdfjs-invalid-file-error = Ugyldig eller korrupt PDF-fil. -pdfjs-missing-file-error = Manglande PDF-fil. -pdfjs-unexpected-response-error = Uventa tenarrespons. -pdfjs-rendering-error = Ein feil oppstod under vising av sida. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date } { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } annotasjon] - -## Password - -pdfjs-password-label = Skriv inn passordet for å opne denne PDF-fila. -pdfjs-password-invalid = Ugyldig passord. Prøv på nytt. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Avbryt -pdfjs-web-fonts-disabled = Web-skrifter er slått av: Kan ikkje bruke innbundne PDF-skrifter. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Teikne -pdfjs-editor-ink-button-label = Teikne -pdfjs-editor-stamp-button = - .title = Legg til eller rediger bilde -pdfjs-editor-stamp-button-label = Legg til eller rediger bilde -pdfjs-editor-highlight-button = - .title = Markere -pdfjs-editor-highlight-button-label = Markere -pdfjs-highlight-floating-button1 = - .title = Markere - .aria-label = Markere -pdfjs-highlight-floating-button-label = Markere - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Fjern teikninga -pdfjs-editor-remove-freetext-button = - .title = Fjern tekst -pdfjs-editor-remove-stamp-button = - .title = Fjern bildet -pdfjs-editor-remove-highlight-button = - .title = Fjern utheving - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Farge -pdfjs-editor-free-text-size-input = Storleik -pdfjs-editor-ink-color-input = Farge -pdfjs-editor-ink-thickness-input = Tjukkleik -pdfjs-editor-ink-opacity-input = Ugjennomskinleg -pdfjs-editor-stamp-add-image-button = - .title = Legg til bilde -pdfjs-editor-stamp-add-image-button-label = Legg til bilde -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tjukkleik -pdfjs-editor-free-highlight-thickness-title = - .title = Endre tjukn når du markerer andre element enn tekst -pdfjs-free-text = - .aria-label = Tekstredigering -pdfjs-free-text-default-content = Byrje å skrive… -pdfjs-ink = - .aria-label = Teikneredigering -pdfjs-ink-canvas = - .aria-label = Brukarskapt bilde - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alt-tekst -pdfjs-editor-alt-text-edit-button-label = Rediger alt-tekst tekst -pdfjs-editor-alt-text-dialog-label = Vel eit alternativ -pdfjs-editor-alt-text-dialog-description = Alt-tekst (alternativ tekst) hjelper når folk ikkje kan sjå bildet eller når det ikkje vert lasta inn. -pdfjs-editor-alt-text-add-description-label = Legg til ei skildring -pdfjs-editor-alt-text-add-description-description = Gå etter 1-2 setninger som skildrar emnet, settinga eller handlingane. -pdfjs-editor-alt-text-mark-decorative-label = Merk som dekorativt -pdfjs-editor-alt-text-mark-decorative-description = Dette vert brukt til dekorative bilde, som kantlinjer eller vassmerke. -pdfjs-editor-alt-text-cancel-button = Avbryt -pdfjs-editor-alt-text-save-button = Lagre -pdfjs-editor-alt-text-decorative-tooltip = Merkt som dekorativ -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Til dømes, «Ein ung mann set seg ved eit bord for å ete eit måltid» - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Øvste venstre hjørne – endre størrelse -pdfjs-editor-resizer-label-top-middle = Øvst i midten — endre størrelse -pdfjs-editor-resizer-label-top-right = Øvste høgre hjørne – endre størrelse -pdfjs-editor-resizer-label-middle-right = Midt til høgre – endre størrelse -pdfjs-editor-resizer-label-bottom-right = Nedste høgre hjørne – endre størrelse -pdfjs-editor-resizer-label-bottom-middle = Nedst i midten — endre størrelse -pdfjs-editor-resizer-label-bottom-left = Nedste venstre hjørne – endre størrelse -pdfjs-editor-resizer-label-middle-left = Midt til venstre — endre størrelse - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Uthevingsfarge -pdfjs-editor-colorpicker-button = - .title = Endre farge -pdfjs-editor-colorpicker-dropdown = - .aria-label = Fargeval -pdfjs-editor-colorpicker-yellow = - .title = Gul -pdfjs-editor-colorpicker-green = - .title = Grøn -pdfjs-editor-colorpicker-blue = - .title = Blå -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Raud - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Vis alle -pdfjs-editor-highlight-show-all-button = - .title = Vis alle diff --git a/static/pdf.js/locale/nn-NO/viewer.properties b/static/pdf.js/locale/nn-NO/viewer.properties new file mode 100644 index 00000000..b3c80895 --- /dev/null +++ b/static/pdf.js/locale/nn-NO/viewer.properties @@ -0,0 +1,167 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Førre side +previous_label=Førre +next.title=Neste side +next_label=Neste + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Side: +page_of=av {{pageCount}} + +zoom_out.title=Mindre +zoom_out_label=Mindre +zoom_in.title=Større +zoom_in_label=Større +zoom.title=Skalering +presentation_mode.title=Byt til presentasjonsmodus +presentation_mode_label=Presentasjonsmodus +open_file.title=Opna fil +open_file_label=Opna +print.title=Skriv ut +print_label=Skriv ut +download.title=Last ned +download_label=Last ned +bookmark.title=Gjeldande vising (kopier eller opna i nytt vindauge) +bookmark_label=Gjeldande vising + +# Secondary toolbar and context menu +tools.title=Verktøy +tools_label=Verktøy +first_page.title=Gå til fyrstesida +first_page.label=Gå til fyrstesida +first_page_label=Gå til fyrstesida +last_page.title=Gå til siste side +last_page.label=Gå til siste side +last_page_label=Gå til siste side +page_rotate_cw.title=Roter med klokka +page_rotate_cw.label=Roter med klokka +page_rotate_cw_label=Roter med klokka +page_rotate_ccw.title=Roter mot klokka +page_rotate_ccw.label=Roter mot klokka +page_rotate_ccw_label=Roter mot klokka + +hand_tool_enable.title=Slå på handverktøy +hand_tool_enable_label=Slå på handverktøy +hand_tool_disable.title=Så av handverktøy +hand_tool_disable_label=Slå av handverktøy + +# Document properties dialog box +document_properties.title=Dokumenteigenskapar … +document_properties_label=Dokumenteigenskapar … +document_properties_file_name=Filnamn: +document_properties_file_size=Filstorleik: +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Dokumenteigenskapar … +document_properties_author=Forfattar: +document_properties_subject=Emne: +document_properties_keywords=Stikkord: +document_properties_creation_date=Dato oppretta: +document_properties_modification_date=Dato endra: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Oppretta av: +document_properties_producer=PDF-verktøy: +document_properties_version=PDF-versjon: +document_properties_page_count=Sidetal: +document_properties_close=Lukk + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Slå av/på sidestolpe +toggle_sidebar_label=Slå av/på sidestolpe +outline.title=Vis dokumentdisposisjon +outline_label=Dokumentdisposisjon +attachments.title=Vis vedlegg +attachments_label=Vedlegg +thumbs.title=Vis miniatyrbilde +thumbs_label=Miniatyrbilde +findbar.title=Finn i dokumentet +findbar_label=Finn + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Side {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatyrbilde av side {{page}} + +# Find panel button title and messages +find_label=Finn: +find_previous.title=Finn tidlegare førekomst av frasen +find_previous_label=Førre +find_next.title=Finn neste førekomst av frasen +find_next_label=Neste +find_highlight=Uthev alle +find_match_case_label=Skil store/små bokstavar +find_reached_top=Nådde toppen av dokumentet, held fram frå botnen +find_reached_bottom=Nådde botnen av dokumentet, held fram frå toppen +find_not_found=Fann ikkje teksten + +# Error panel labels +error_more_info=Meir info +error_less_info=Mindre info +error_close=Lukk +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (bygg: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Melding: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stakk: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fil: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linje: {{line}} +rendering_error=Ein feil oppstod ved oppteikning av sida. + +# Predefined zoom values +page_scale_width=Sidebreidde +page_scale_fit=Tilpass til sida +page_scale_auto=Automatisk skalering +page_scale_actual=Verkeleg storleik +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Feil +loading_error=Ein feil oppstod ved lasting av PDF. +invalid_file_error=Ugyldig eller korrupt PDF-fil. +missing_file_error=Manglande PDF-fil. +unexpected_response_error=Uventa tenarrespons. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} annotasjon] +password_label=Skriv inn passordet for å opna denne PDF-fila. +password_invalid=Ugyldig passord. Prøv igjen. +password_ok=OK +password_cancel=Avbryt + +printing_not_supported=Åtvaring: Utskrift er ikkje fullstendig støtta av denne nettlesaren. +printing_not_ready=Åtvaring: PDF ikkje fullstendig innlasta for utskrift. +web_fonts_disabled=Vev-skrifter er slått av: Kan ikkje bruka innbundne PDF-skrifter. +document_colors_disabled=PDF-dokument har ikkje løyve til å bruka eigne fargar: 'Tillat sider å velja eigne fargar' er slått av i nettlesaren. diff --git a/static/pdf.js/locale/no/viewer.properties b/static/pdf.js/locale/no/viewer.properties new file mode 100644 index 00000000..6c160fc7 --- /dev/null +++ b/static/pdf.js/locale/no/viewer.properties @@ -0,0 +1,134 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Førre Side +previous_label=Førre +next.title=Neste side +next_label=Neste + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Side: +page_of=av {{pageCount}} + +zoom_out.title=Zoom ut +zoom_out_label=Zoom ut +zoom_in.title=Zoom inn +zoom_in_label=Zoom inn +zoom.title=Zoom +presentation_mode.title=Bytt til presentasjonsmodus +presentation_mode_label=Presentasjonsmodus +open_file.title=Opne fil +open_file_label=Opne +print.title=Skriv ut +print_label=Skriv ut +download.title=Last ned +download_label=Last ned +bookmark.title=Gjeldande visning (kopier eller opne i nytt vindauge) +bookmark_label=Gjeldende visning + +# Secondary toolbar and context menu +tools.title=Verktøy +tools_label=Verktøy +first_page.title=Gå til første side +first_page.label=Gå til første side +first_page_label=Gå til første side +last_page.title=Gå til siste side +last_page.label=Gå til siste side +last_page_label=Gå til siste side +page_rotate_cw.title=Roter med klokka +page_rotate_cw.label=Roter med klokka +page_rotate_cw_label=Roter med klokka +page_rotate_ccw.title=Roter mot klokka +page_rotate_ccw.label=Roter mot klokka +page_rotate_ccw_label=Roter mot klokka + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Veksle Sidebar +toggle_sidebar_label=Veksle Sidebar +outline.title=Vis Document Outline +outline_label=Document Outline +thumbs.title=Vis miniatyrbilder +thumbs_label=Miniatyrbilder +findbar.title=Finne i Dokument +findbar_label=Finn + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Side {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Thumbnail av siden {{page}} + +# Find panel button title and messages +find_label=Finn: +find_previous.title=Finn tidlegare førekomst av frasa +find_previous_label=Førre +find_next.title=Finn neste førekomst av frasa +find_next_label=Neste +find_highlight=Uthev alle +find_match_case_label=Skil store/små bokstavar +find_reached_top=Nådde toppen av dokumentet, held fram frå botnen +find_reached_bottom=Nådde botnen av dokumentet, held fram frå toppen +find_not_found=Fann ikkje teksten + +# Error panel labels +error_more_info=Meir info +error_less_info=Mindre info +error_close=Lukk +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v {{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Melding: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stakk: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fil: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linje: {{line}} +rendering_error=Ein feil oppstod ved oppteikning av sida. + +# Predefined zoom values +page_scale_width=Sidebreidde +page_scale_fit=Tilpass til sida +page_scale_auto=Automatisk zoom +page_scale_actual=Verkeleg størrelse + +# Loading indicator messages +loading_error_indicator=Feil +loading_error=Ein feil oppstod ved lasting av PDF. +invalid_file_error=Ugyldig eller korrupt PDF fil. +missing_file_error=Manglande PDF-fil. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} annotasjon] +request_password=PDF er beskytta av eit passord: +invalid_password=Ugyldig passord. + +printing_not_supported=Åtvaring: Utskrift er ikkje fullstendig støtta av denne nettlesaren. +printing_not_ready=Åtvaring: PDF ikkje fullstendig innlasta for utskrift. +web_fonts_disabled=Web-fontar er avslått: Kan ikkje bruke innbundne PDF-fontar. +document_colors_disabled=PDF-dokument har ikkje løyve til å nytte eigne fargar: \'Tillat sider å velje eigne fargar\' er slått av i nettlesaren. diff --git a/static/pdf.js/locale/nso/viewer.properties b/static/pdf.js/locale/nso/viewer.properties new file mode 100644 index 00000000..02cc7d85 --- /dev/null +++ b/static/pdf.js/locale/nso/viewer.properties @@ -0,0 +1,131 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Letlakala le fetilego +previous_label=Fetilego +next.title=Letlakala le latelago +next_label=Latelago + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Letlakala: +page_of=la {{pageCount}} + +zoom_out.title=Bušetša ka gare +zoom_out_label=Bušetša ka gare +zoom_in.title=Godišetša ka ntle +zoom_in_label=Godišetša ka ntle +zoom.title=Godiša +presentation_mode.title=Fetogela go mokgwa wa tlhagišo +presentation_mode_label=Mokgwa wa tlhagišo +open_file.title=Bula faele +open_file_label=Bula +print.title=Gatiša +print_label=Gatiša +download.title=Laolla +download_label=Laolla +bookmark.title=Pono ya bjale (kopiša le go bula lefasetereng le leswa) +bookmark_label=Tebelelo ya gona bjale + +# Secondary toolbar and context menu + + +# Document properties dialog box +document_properties_file_name=Leina la faele: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Thaetlele: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Šielanya para ya ka thoko +toggle_sidebar_label=Šielanya para ya ka thoko +outline.title=Laetša kakaretšo ya tokumente +outline_label=Kakaretšo ya tokumente +thumbs.title=Laetša dikhutšofatšo +thumbs_label=Dikhutšofatšo +findbar.title=Hwetša go tokumente +findbar_label=Hwetša + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Letlakala {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Khutšofatšo ya letlakala {{page}} + +# Find panel button title and messages +find_label=Hwetša: +find_previous.title=Hwetša tiragalo e fetilego ya sekafoko +find_previous_label=Fetilego +find_next.title=Hwetša tiragalo e latelago ya sekafoko +find_next_label=Latelago +find_highlight=Bonagatša tšohle +find_match_case_label=Swantšha kheisi +find_reached_top=Fihlile godimo ga tokumente, go tšwetšwe pele go tloga tlase +find_reached_bottom=Fihlile mafelelong a tokumente, go tšwetšwe pele go tloga godimo +find_not_found=Sekafoko ga sa hwetšwa + +# Error panel labels +error_more_info=Tshedimošo e oketšegilego +error_less_info=Tshedimošo ya tlasana +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Molaetša: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Mokgobo: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Faele: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Mothaladi: {{line}} +rendering_error=Go diregile phošo ge go be go gafelwa letlakala. + +# Predefined zoom values +page_scale_width=Bophara bja letlakala +page_scale_fit=Go lekana ga letlakala +page_scale_auto=Kgodišo ya maitirišo +page_scale_actual=Bogolo bja kgonthe +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Phošo +loading_error=Go diregile phošo ge go hlahlelwa PDF. +invalid_file_error=Faele ye e sa šomego goba e senyegilego ya PDF. +missing_file_error=Faele yeo e sego gona ya PDF. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Tlhaloso] +password_ok=LOKILE +password_cancel=Khansela + +printing_not_supported=Temošo: Go gatiša ga go thekgwe ke praosara ye ka botlalo. +printing_not_ready=Temošo: PDF ga ya hlahlelwa ka botlalo bakeng sa go gatišwa. +web_fonts_disabled=Difonte tša wepe di šitišitšwe: ga e kgone go diriša difonte tša PDF tše khutišitšwego. diff --git a/static/pdf.js/locale/oc/viewer.ftl b/static/pdf.js/locale/oc/viewer.ftl deleted file mode 100644 index 68889798..00000000 --- a/static/pdf.js/locale/oc/viewer.ftl +++ /dev/null @@ -1,354 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pagina precedenta -pdfjs-previous-button-label = Precedent -pdfjs-next-button = - .title = Pagina seguenta -pdfjs-next-button-label = Seguent -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pagina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = sus { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom arrièr -pdfjs-zoom-out-button-label = Zoom arrièr -pdfjs-zoom-in-button = - .title = Zoom avant -pdfjs-zoom-in-button-label = Zoom avant -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Bascular en mòde presentacion -pdfjs-presentation-mode-button-label = Mòde Presentacion -pdfjs-open-file-button = - .title = Dobrir lo fichièr -pdfjs-open-file-button-label = Dobrir -pdfjs-print-button = - .title = Imprimir -pdfjs-print-button-label = Imprimir -pdfjs-save-button = - .title = Enregistrar -pdfjs-save-button-label = Enregistrar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Telecargar -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Telecargar -pdfjs-bookmark-button = - .title = Pagina actuala (mostrar l’adreça de la pagina actuala) -pdfjs-bookmark-button-label = Pagina actuala -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Dobrir amb l’aplicacion -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Dobrir amb l’aplicacion - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Aisinas -pdfjs-tools-button-label = Aisinas -pdfjs-first-page-button = - .title = Anar a la primièra pagina -pdfjs-first-page-button-label = Anar a la primièra pagina -pdfjs-last-page-button = - .title = Anar a la darrièra pagina -pdfjs-last-page-button-label = Anar a la darrièra pagina -pdfjs-page-rotate-cw-button = - .title = Rotacion orària -pdfjs-page-rotate-cw-button-label = Rotacion orària -pdfjs-page-rotate-ccw-button = - .title = Rotacion antiorària -pdfjs-page-rotate-ccw-button-label = Rotacion antiorària -pdfjs-cursor-text-select-tool-button = - .title = Activar l'aisina de seleccion de tèxte -pdfjs-cursor-text-select-tool-button-label = Aisina de seleccion de tèxte -pdfjs-cursor-hand-tool-button = - .title = Activar l’aisina man -pdfjs-cursor-hand-tool-button-label = Aisina man -pdfjs-scroll-page-button = - .title = Activar lo defilament per pagina -pdfjs-scroll-page-button-label = Defilament per pagina -pdfjs-scroll-vertical-button = - .title = Utilizar lo defilament vertical -pdfjs-scroll-vertical-button-label = Defilament vertical -pdfjs-scroll-horizontal-button = - .title = Utilizar lo defilament orizontal -pdfjs-scroll-horizontal-button-label = Defilament orizontal -pdfjs-scroll-wrapped-button = - .title = Activar lo defilament continú -pdfjs-scroll-wrapped-button-label = Defilament continú -pdfjs-spread-none-button = - .title = Agropar pas las paginas doas a doas -pdfjs-spread-none-button-label = Una sola pagina -pdfjs-spread-odd-button = - .title = Mostrar doas paginas en començant per las paginas imparas a esquèrra -pdfjs-spread-odd-button-label = Dobla pagina, impara a drecha -pdfjs-spread-even-button = - .title = Mostrar doas paginas en començant per las paginas paras a esquèrra -pdfjs-spread-even-button-label = Dobla pagina, para a drecha - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Proprietats del document… -pdfjs-document-properties-button-label = Proprietats del document… -pdfjs-document-properties-file-name = Nom del fichièr : -pdfjs-document-properties-file-size = Talha del fichièr : -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } Ko ({ $size_b } octets) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } Mo ({ $size_b } octets) -pdfjs-document-properties-title = Títol : -pdfjs-document-properties-author = Autor : -pdfjs-document-properties-subject = Subjècte : -pdfjs-document-properties-keywords = Mots claus : -pdfjs-document-properties-creation-date = Data de creacion : -pdfjs-document-properties-modification-date = Data de modificacion : -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, a { $time } -pdfjs-document-properties-creator = Creator : -pdfjs-document-properties-producer = Aisina de conversion PDF : -pdfjs-document-properties-version = Version PDF : -pdfjs-document-properties-page-count = Nombre de paginas : -pdfjs-document-properties-page-size = Talha de la pagina : -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = retrach -pdfjs-document-properties-page-size-orientation-landscape = païsatge -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letra -pdfjs-document-properties-page-size-name-legal = Document juridic - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista web rapida : -pdfjs-document-properties-linearized-yes = Òc -pdfjs-document-properties-linearized-no = Non -pdfjs-document-properties-close-button = Tampar - -## Print - -pdfjs-print-progress-message = Preparacion del document per l’impression… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Anullar -pdfjs-printing-not-supported = Atencion : l'impression es pas complètament gerida per aqueste navegador. -pdfjs-printing-not-ready = Atencion : lo PDF es pas entièrament cargat per lo poder imprimir. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Afichar/amagar lo panèl lateral -pdfjs-toggle-sidebar-notification-button = - .title = Afichar/amagar lo panèl lateral (lo document conten esquèmas/pèças juntas/calques) -pdfjs-toggle-sidebar-button-label = Afichar/amagar lo panèl lateral -pdfjs-document-outline-button = - .title = Mostrar los esquèmas del document (dobleclicar per espandre/reduire totes los elements) -pdfjs-document-outline-button-label = Marcapaginas del document -pdfjs-attachments-button = - .title = Visualizar las pèças juntas -pdfjs-attachments-button-label = Pèças juntas -pdfjs-layers-button = - .title = Afichar los calques (doble-clicar per reïnicializar totes los calques a l’estat per defaut) -pdfjs-layers-button-label = Calques -pdfjs-thumbs-button = - .title = Afichar las vinhetas -pdfjs-thumbs-button-label = Vinhetas -pdfjs-current-outline-item-button = - .title = Trobar l’element de plan actual -pdfjs-current-outline-item-button-label = Element de plan actual -pdfjs-findbar-button = - .title = Cercar dins lo document -pdfjs-findbar-button-label = Recercar -pdfjs-additional-layers = Calques suplementaris - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pagina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Vinheta de la pagina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Recercar - .placeholder = Cercar dins lo document… -pdfjs-find-previous-button = - .title = Tròba l'ocurréncia precedenta de la frasa -pdfjs-find-previous-button-label = Precedent -pdfjs-find-next-button = - .title = Tròba l'ocurréncia venenta de la frasa -pdfjs-find-next-button-label = Seguent -pdfjs-find-highlight-checkbox = Suslinhar tot -pdfjs-find-match-case-checkbox-label = Respectar la cassa -pdfjs-find-match-diacritics-checkbox-label = Respectar los diacritics -pdfjs-find-entire-word-checkbox-label = Mots entièrs -pdfjs-find-reached-top = Naut de la pagina atenh, perseguida del bas -pdfjs-find-reached-bottom = Bas de la pagina atench, perseguida al començament -pdfjs-find-not-found = Frasa pas trobada - -## Predefined zoom values - -pdfjs-page-scale-width = Largor plena -pdfjs-page-scale-fit = Pagina entièra -pdfjs-page-scale-auto = Zoom automatic -pdfjs-page-scale-actual = Talha vertadièra -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pagina { $page } - -## Loading indicator messages - -pdfjs-loading-error = Una error s'es producha pendent lo cargament del fichièr PDF. -pdfjs-invalid-file-error = Fichièr PDF invalid o corromput. -pdfjs-missing-file-error = Fichièr PDF mancant. -pdfjs-unexpected-response-error = Responsa de servidor imprevista. -pdfjs-rendering-error = Una error s'es producha pendent l'afichatge de la pagina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date } a { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotacion { $type }] - -## Password - -pdfjs-password-label = Picatz lo senhal per dobrir aqueste fichièr PDF. -pdfjs-password-invalid = Senhal incorrècte. Tornatz ensajar. -pdfjs-password-ok-button = D'acòrdi -pdfjs-password-cancel-button = Anullar -pdfjs-web-fonts-disabled = Las polissas web son desactivadas : impossible d'utilizar las polissas integradas al PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tèxte -pdfjs-editor-free-text-button-label = Tèxte -pdfjs-editor-ink-button = - .title = Dessenhar -pdfjs-editor-ink-button-label = Dessenhar -pdfjs-editor-stamp-button = - .title = Apondre o modificar d’imatges -pdfjs-editor-stamp-button-label = Apondre o modificar d’imatges - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-freetext-button = - .title = Suprimir lo tèxte -pdfjs-editor-remove-stamp-button = - .title = Suprimir l’imatge - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Color -pdfjs-editor-free-text-size-input = Talha -pdfjs-editor-ink-color-input = Color -pdfjs-editor-ink-thickness-input = Espessor -pdfjs-editor-ink-opacity-input = Opacitat -pdfjs-editor-stamp-add-image-button = - .title = Apondre imatge -pdfjs-editor-stamp-add-image-button-label = Apondre imatge -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Espessor -pdfjs-free-text = - .aria-label = Editor de tèxte -pdfjs-free-text-default-content = Començatz d’escriure… -pdfjs-ink = - .aria-label = Editor de dessenh -pdfjs-ink-canvas = - .aria-label = Imatge creat per l’utilizaire - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Tèxt alternatiu -pdfjs-editor-alt-text-edit-button-label = Modificar lo tèxt alternatiu -pdfjs-editor-alt-text-dialog-label = Causir una opcion -pdfjs-editor-alt-text-add-description-label = Apondre una descripcion -pdfjs-editor-alt-text-cancel-button = Anullar -pdfjs-editor-alt-text-save-button = Enregistrar - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Color de suslinhatge -pdfjs-editor-colorpicker-button = - .title = Cambiar de color -pdfjs-editor-colorpicker-yellow = - .title = Jaune -pdfjs-editor-colorpicker-green = - .title = Verd -pdfjs-editor-colorpicker-blue = - .title = Blau -pdfjs-editor-colorpicker-pink = - .title = Ròse -pdfjs-editor-colorpicker-red = - .title = Roge - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = O afichar tot -pdfjs-editor-highlight-show-all-button = - .title = O afichar tot diff --git a/static/pdf.js/locale/oc/viewer.properties b/static/pdf.js/locale/oc/viewer.properties new file mode 100644 index 00000000..d9a91657 --- /dev/null +++ b/static/pdf.js/locale/oc/viewer.properties @@ -0,0 +1,171 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Pagina precedenta +previous_label=Precedent +next.title=Pagina seguenta +next_label=Seguent + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pagina : +page_of=sus {{pageCount}} + +zoom_out.title=Zoom arrièr +zoom_out_label=Zoom arrièr +zoom_in.title=Zoom avant +zoom_in_label=Zoom avant +zoom.title=Zoom +presentation_mode.title=Bascular en mòde presentacion +presentation_mode_label=Mòde Presentacion +open_file.title=Dobrir lo fichièr +open_file_label=Dobrir +print.title=Imprimir +print_label=Imprimir +download.title=Telecargar +download_label=Telecargar +bookmark.title=Afichatge corrent (copiar o dobrir dins una fenèstra novèla) +bookmark_label=Afichatge actual + +# Secondary toolbar and context menu +tools.title=Aisinas +tools_label=Aisinas +first_page.title=Anar a la primièra pagina +first_page.label=Anar a la primièra pagina +first_page_label=Anar a la primièra pagina +last_page.title=Anar a la darrièra pagina +last_page.label=Anar a la darrièra pagina +last_page_label=Anar a la darrièra pagina +page_rotate_cw.title=Rotacion orària +page_rotate_cw.label=Rotacion orària +page_rotate_cw_label=Rotacion orària +page_rotate_ccw.title=Rotacion antiorària +page_rotate_ccw.label=Rotacion antiorària +page_rotate_ccw_label=Rotacion antiorària + +hand_tool_enable.title=Activar l'aisina man +hand_tool_enable_label=Activar l'aisina man +hand_tool_disable.title=Desactivar l'aisina man +hand_tool_disable_label=Desactivar l'aisina man + +# Document properties dialog box +document_properties.title=Proprietats del document... +document_properties_label=Proprietats del document... +document_properties_file_name=Nom del fichièr : +document_properties_file_size=Talha del fichièr : +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} Ko ({{size_b}} octets) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} Mo ({{size_b}} octets) +document_properties_title=Títol : +document_properties_author=Autor : +document_properties_subject=Subjècte : +document_properties_keywords=Mots claus : +document_properties_creation_date=Data de creacion : +document_properties_modification_date=Data de modificacion : +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Creator : +document_properties_producer=Aisina de conversion PDF : +document_properties_version=Version PDF : +document_properties_page_count=Nombre de paginas : +document_properties_close=Tampar + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Afichar/amagar lo panèl lateral +toggle_sidebar_label=Afichar/amagar lo panèl lateral +outline.title=Afichar los marcapaginas +outline_label=Marcapaginas del document +attachments.title=Visualizar las pèças juntas +attachments_label=Pèças juntas +thumbs.title=Afichar las vinhetas +thumbs_label=Vinhetas +findbar.title=Trobar dins lo document +findbar_label=Recercar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pagina {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Vinheta de la pagina {{page}} + +# Find panel button title and messages +find_label=Recercar +find_previous.title=Tròba l'ocurréncia precedenta de la frasa +find_previous_label=Precedent +find_next.title=Tròba l'ocurréncia venenta de la frasa +find_next_label=Seguent +find_highlight=Suslinhar tot +find_match_case_label=Respectar la cassa +find_reached_top=Naut de la pagina atench, perseguida dempuèi lo bas +find_reached_bottom=Bas de la pagina atench, perseguida al començament +find_not_found=Frasa pas trobada + +# Error panel labels +error_more_info=Mai de detalhs +error_less_info=Mens d'informacions +error_close=Tampar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (identificant de compilacion : {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Messatge : {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pila : {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fichièr : {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linha : {{line}} +rendering_error=Una error s'es producha pendent l'afichatge de la pagina. + +# Predefined zoom values +page_scale_width=Largor plena +page_scale_fit=Pagina entièra +page_scale_auto=Zoom automatic +page_scale_actual=Talha vertadièra +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Error +loading_error=Una error s'es producha pendent lo cargament del fichièr PDF. +invalid_file_error=Fichièr PDF invalid o corromput. +missing_file_error=Fichièr PDF mancant. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotacion {{type}}] +password_label=Picatz lo senhal per dobrir aqueste fichièr PDF. +password_invalid=Senhal incorrècte. Tornatz ensajar. +password_ok=D'acòrdi +password_cancel=Anullar + +printing_not_supported=Atencion : l'estampatge es pas completament gerit per aqueste navigador. +printing_not_ready=Atencion : lo PDF es pas entièrament cargat per lo poder imprimir. +web_fonts_disabled=Las poliças web son desactivadas : impossible d'utilizar las poliças integradas al PDF. +document_colors_not_allowed=Los documents PDF pòdon pas utilizar lors pròprias colors : « Autorizar las paginas web d'utilizar lors pròprias colors » es desactivat dins lo navigador. diff --git a/static/pdf.js/locale/or/viewer.properties b/static/pdf.js/locale/or/viewer.properties new file mode 100644 index 00000000..279407d9 --- /dev/null +++ b/static/pdf.js/locale/or/viewer.properties @@ -0,0 +1,172 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=ପୂର୍ବ ପୃଷ୍ଠା +previous_label=ପୂର୍ବ +next.title=ପର ପୃଷ୍ଠା +next_label=ପର + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=ପୃଷ୍ଠା: +page_of={{pageCount}} ର + +zoom_out.title=ଛୋଟ କରନ୍ତୁ +zoom_out_label=ଛୋଟ କରନ୍ତୁ +zoom_in.title=ବଡ଼ କରନ୍ତୁ +zoom_in_label=ବଡ଼ କରନ୍ତୁ +zoom.title=ଛୋଟ ବଡ଼ କରନ୍ତୁ +presentation_mode.title=ଉପସ୍ଥାପନ ଧାରାକୁ ବଦଳାନ୍ତୁ +presentation_mode_label=ଉପସ୍ଥାପନ ଧାରା +open_file.title=ଫାଇଲ ଖୋଲନ୍ତୁ +open_file_label=ଖୋଲନ୍ତୁ +print.title=ମୁଦ୍ରଣ +print_label=ମୁଦ୍ରଣ +download.title=ଆହରଣ +download_label=ଆହରଣ +bookmark.title=ପ୍ରଚଳିତ ଦୃଶ୍ୟ (ନକଲ କରନ୍ତୁ କିମ୍ବା ଏକ ନୂତନ ୱିଣ୍ଡୋରେ ଖୋଲନ୍ତୁ) +bookmark_label=ପ୍ରଚଳିତ ଦୃଶ୍ୟ + +# Secondary toolbar and context menu +tools.title=ସାଧନଗୁଡ଼ିକ +tools_label=ସାଧନଗୁଡ଼ିକ +first_page.title=ପ୍ରଥମ ପୃଷ୍ଠାକୁ ଯାଆନ୍ତୁ +first_page.label=ପ୍ରଥମ ପୃଷ୍ଠାକୁ ଯାଆନ୍ତୁ +first_page_label=ପ୍ରଥମ ପୃଷ୍ଠାକୁ ଯାଆନ୍ତୁ +last_page.title=ଶେଷ ପୃଷ୍ଠାକୁ ଯାଆନ୍ତୁ +last_page.label=ଶେଷ ପୃଷ୍ଠାକୁ ଯାଆନ୍ତୁ +last_page_label=ଶେଷ ପୃଷ୍ଠାକୁ ଯାଆନ୍ତୁ +page_rotate_cw.title=ଦକ୍ଷିଣାବର୍ତ୍ତୀ ଘୁରାନ୍ତୁ +page_rotate_cw.label=ଦକ୍ଷିଣାବର୍ତ୍ତୀ ଘୁରାନ୍ତୁ +page_rotate_cw_label=ଦକ୍ଷିଣାବର୍ତ୍ତୀ ଘୁରାନ୍ତୁ +page_rotate_ccw.title=ବାମାବର୍ତ୍ତୀ ଘୁରାନ୍ତୁ +page_rotate_ccw.label=ବାମାବର୍ତ୍ତୀ ଘୁରାନ୍ତୁ +page_rotate_ccw_label=ବାମାବର୍ତ୍ତୀ ଘୁରାନ୍ତୁ + +hand_tool_enable.title=ହସ୍ତକୃତ ସାଧନକୁ ସକ୍ରିୟ କରନ୍ତୁ +hand_tool_enable_label=ହସ୍ତକୃତ ସାଧନକୁ ସକ୍ରିୟ କରନ୍ତୁ +hand_tool_disable.title=ହସ୍ତକୃତ ସାଧନକୁ ନିଷ୍କ୍ରିୟ କରନ୍ତୁ +hand_tool_disable_label=ହସ୍ତକୃତ ସାଧନକୁ ନିଷ୍କ୍ରିୟ କରନ୍ତୁ + +# Document properties dialog box +document_properties.title=ଦଲିଲ ଗୁଣଧର୍ମ… +document_properties_label=ଦଲିଲ ଗୁଣଧର୍ମ… +document_properties_file_name=ଫାଇଲ ନାମ: +document_properties_file_size=ଫାଇଲ ଆକାର: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=ଶୀର୍ଷକ: +document_properties_author=ଲେଖକ: +document_properties_subject=ବିଷୟ: +document_properties_keywords=ସୂଚକ ଶବ୍ଦ: +document_properties_creation_date=ନିର୍ମାଣ ତାରିଖ: +document_properties_modification_date=ପରିବର୍ତ୍ତନ ତାରିଖ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=ନିର୍ମାତା: +document_properties_producer=PDF ପ୍ରଯୋଜକ: +document_properties_version=PDF ସଂସ୍କରଣ: +document_properties_page_count=ପୃଷ୍ଠା ଗଣନା: +document_properties_close=ବନ୍ଦ କରନ୍ତୁ + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=ପାର୍ଶ୍ୱପଟିକୁ ଆଗପଛ କରନ୍ତୁ +toggle_sidebar_label=ପାର୍ଶ୍ୱପଟିକୁ ଆଗପଛ କରନ୍ତୁ +outline.title=ଦଲିଲ ସାରାଂଶ ଦର୍ଶାନ୍ତୁ +outline_label=ଦଲିଲ ସାରାଂଶ +attachments.title=ସଂଲଗ୍ନକଗୁଡ଼ିକୁ ଦର୍ଶାନ୍ତୁ +attachments_label=ସଲଗ୍ନକଗୁଡିକ +thumbs.title=ସଂକ୍ଷିପ୍ତ ବିବରଣୀ ଦର୍ଶାନ୍ତୁ +thumbs_label=ସଂକ୍ଷିପ୍ତ ବିବରଣୀ +findbar.title=ଦଲିଲରେ ଖୋଜନ୍ତୁ +findbar_label=ଖୋଜନ୍ତୁ + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=ପୃଷ୍ଠା {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=ପୃଷ୍ଠାର ସଂକ୍ଷିପ୍ତ ବିବରଣୀ {{page}} + +# Find panel button title and messages +find_label=ଖୋଜନ୍ତୁ: +find_previous.title=ଏହି ବାକ୍ୟାଂଶର ପୂର୍ବ ଉପସ୍ଥିତିକୁ ଖୋଜନ୍ତୁ +find_previous_label=ପୂର୍ବବର୍ତ୍ତୀ +find_next.title=ଏହି ବାକ୍ୟାଂଶର ପରବର୍ତ୍ତୀ ଉପସ୍ଥିତିକୁ ଖୋଜନ୍ତୁ +find_next_label=ପରବର୍ତ୍ତୀ\u0020 +find_highlight=ସମସ୍ତଙ୍କୁ ଆଲୋକିତ କରନ୍ତୁ +find_match_case_label=ଅକ୍ଷର ମେଳାନ୍ତୁ +find_reached_top=ତଳୁ ଉପରକୁ ଗତି କରି ଦଲିଲର ଉପର ଭାଗରେ ପହଞ୍ଚି ଯାଇଛି +find_reached_bottom=ଉପରୁ ତଳକୁ ଗତି କରି ଦଲିଲର ଶେଷ ଭାଗରେ ପହଞ୍ଚି ଯାଇଛି +find_not_found=ବାକ୍ୟାଂଶ ମିଳିଲା ନାହିଁ + +# Error panel labels +error_more_info=ଅଧିକ ସୂଚନା +error_less_info=ସ୍ୱଳ୍ପ ସୂଚନା +error_close=ବନ୍ଦ କରନ୍ତୁ +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=ସନ୍ଦେଶ: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=ଷ୍ଟାକ: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ଫାଇଲ: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=ଧାଡ଼ି: {{line}} +rendering_error=ପୃଷ୍ଠା ଚିତ୍ରଣ କରିବା ସମୟରେ ତ୍ରୁଟି ଘଟିଲା। + +# Predefined zoom values +page_scale_width=ପୃଷ୍ଠା ଓସାର +page_scale_fit=ପୃଷ୍ଠା ମେଳନ +page_scale_auto=ସ୍ୱୟଂଚାଳିତ ଭାବରେ ଛୋଟବଡ଼ କରିବା +page_scale_actual=ପ୍ରକୃତ ଆକାର +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=ତ୍ରୁଟି +loading_error=PDF ଧାରଣ କରିବା ସମୟରେ ଏକ ତ୍ରୁଟି ଘଟିଲା। +invalid_file_error=ଅବୈଧ କିମ୍ବା ତ୍ରୁଟିଯୁକ୍ତ PDF ଫାଇଲ। +missing_file_error=ହଜିଯାଇଥିବା PDF ଫାଇଲ। +unexpected_response_error=ଅପ୍ରତ୍ୟାଶିତ ସର୍ଭର ଉତ୍ତର। + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Annotation] +password_label=ଏହି PDF ଫାଇଲକୁ ଖୋଲିବା ପାଇଁ ପ୍ରବେଶ ସଂକେତ ଭରଣ କରନ୍ତୁ। +password_invalid=ଭୁଲ ପ୍ରବେଶ ସଂକେତ। ଦୟାକରି ପୁଣି ଚେଷ୍ଟା କରନ୍ତୁ। +password_ok=ଠିକ ଅଛି +password_cancel=ବାତିଲ କରନ୍ତୁ + +printing_not_supported=ଚେତାବନୀ: ଏହି ବ୍ରାଉଜର ଦ୍ୱାରା ମୁଦ୍ରଣ କ୍ରିୟା ସମ୍ପୂର୍ଣ୍ଣ ଭାବରେ ସହାୟତା ପ୍ରାପ୍ତ ନୁହଁ। +printing_not_ready=ଚେତାବନୀ: PDF ଟି ମୁଦ୍ରଣ ପାଇଁ ସମ୍ପୂର୍ଣ୍ଣ ଭାବରେ ଧାରଣ ହୋଇ ନାହିଁ। +web_fonts_disabled=ୱେବ ଅକ୍ଷରରୂପଗୁଡ଼ିକୁ ନିଷ୍କ୍ରିୟ କରାଯାଇଛି: ସନ୍ନିହିତ PDF ଅକ୍ଷରରୂପଗୁଡ଼ିକୁ ବ୍ୟବହାର କରିବାରେ ଅସମର୍ଥ। +document_colors_not_allowed=PDF ଦଲିଲଗୁଡ଼ିକ ସେମାନଙ୍କର ନିଜର ରଙ୍ଗ ବ୍ୟବହାର କରିବା ପାଇଁ ଅନୁମତି ପ୍ରାପ୍ତ ନୁହଁ: 'ସେମାନଙ୍କର ନିଜ ରଙ୍ଗ ବାଛିବା ପାଇଁ ପୃଷ୍ଠାଗୁଡ଼ିକୁ ଅନୁମତି ଦିଅନ୍ତୁ' କୁ ବ୍ରାଉଜରରେ ନିଷ୍କ୍ରିୟ କରାଯାଇଛି। diff --git a/static/pdf.js/locale/pa-IN/viewer.ftl b/static/pdf.js/locale/pa-IN/viewer.ftl deleted file mode 100644 index eef67d35..00000000 --- a/static/pdf.js/locale/pa-IN/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = ਪਿਛਲਾ ਸਫ਼ਾ -pdfjs-previous-button-label = ਪਿੱਛੇ -pdfjs-next-button = - .title = ਅਗਲਾ ਸਫ਼ਾ -pdfjs-next-button-label = ਅੱਗੇ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = ਸਫ਼ਾ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } ਵਿੱਚੋਂ -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = { $pagesCount }) ਵਿੱਚੋਂ ({ $pageNumber } -pdfjs-zoom-out-button = - .title = ਜ਼ੂਮ ਆਉਟ -pdfjs-zoom-out-button-label = ਜ਼ੂਮ ਆਉਟ -pdfjs-zoom-in-button = - .title = ਜ਼ੂਮ ਇਨ -pdfjs-zoom-in-button-label = ਜ਼ੂਮ ਇਨ -pdfjs-zoom-select = - .title = ਜ਼ੂਨ -pdfjs-presentation-mode-button = - .title = ਪਰਿਜੈਂਟੇਸ਼ਨ ਮੋਡ ਵਿੱਚ ਜਾਓ -pdfjs-presentation-mode-button-label = ਪਰਿਜੈਂਟੇਸ਼ਨ ਮੋਡ -pdfjs-open-file-button = - .title = ਫਾਈਲ ਨੂੰ ਖੋਲ੍ਹੋ -pdfjs-open-file-button-label = ਖੋਲ੍ਹੋ -pdfjs-print-button = - .title = ਪਰਿੰਟ -pdfjs-print-button-label = ਪਰਿੰਟ -pdfjs-save-button = - .title = ਸੰਭਾਲੋ -pdfjs-save-button-label = ਸੰਭਾਲੋ -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = ਡਾਊਨਲੋਡ -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = ਡਾਊਨਲੋਡ -pdfjs-bookmark-button = - .title = ਮੌਜੂਦਾ ਸਫ਼਼ਾ (ਮੌਜੂਦਾ ਸਫ਼ੇ ਤੋਂ URL ਵੇਖੋ) -pdfjs-bookmark-button-label = ਮੌਜੂਦਾ ਸਫ਼਼ਾ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ਟੂਲ -pdfjs-tools-button-label = ਟੂਲ -pdfjs-first-page-button = - .title = ਪਹਿਲੇ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ -pdfjs-first-page-button-label = ਪਹਿਲੇ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ -pdfjs-last-page-button = - .title = ਆਖਰੀ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ -pdfjs-last-page-button-label = ਆਖਰੀ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ -pdfjs-page-rotate-cw-button = - .title = ਸੱਜੇ ਦਾਅ ਘੁੰਮਾਓ -pdfjs-page-rotate-cw-button-label = ਸੱਜੇ ਦਾਅ ਘੁੰਮਾਓ -pdfjs-page-rotate-ccw-button = - .title = ਖੱਬੇ ਦਾਅ ਘੁੰਮਾਓ -pdfjs-page-rotate-ccw-button-label = ਖੱਬੇ ਦਾਅ ਘੁੰਮਾਓ -pdfjs-cursor-text-select-tool-button = - .title = ਲਿਖਤ ਚੋਣ ਟੂਲ ਸਮਰੱਥ ਕਰੋ -pdfjs-cursor-text-select-tool-button-label = ਲਿਖਤ ਚੋਣ ਟੂਲ -pdfjs-cursor-hand-tool-button = - .title = ਹੱਥ ਟੂਲ ਸਮਰੱਥ ਕਰੋ -pdfjs-cursor-hand-tool-button-label = ਹੱਥ ਟੂਲ -pdfjs-scroll-page-button = - .title = ਸਫ਼ਾ ਖਿਸਕਾਉਣ ਨੂੰ ਵਰਤੋਂ -pdfjs-scroll-page-button-label = ਸਫ਼ਾ ਖਿਸਕਾਉਣਾ -pdfjs-scroll-vertical-button = - .title = ਖੜ੍ਹਵੇਂ ਸਕਰਾਉਣ ਨੂੰ ਵਰਤੋਂ -pdfjs-scroll-vertical-button-label = ਖੜ੍ਹਵਾਂ ਸਰਕਾਉਣਾ -pdfjs-scroll-horizontal-button = - .title = ਲੇਟਵੇਂ ਸਰਕਾਉਣ ਨੂੰ ਵਰਤੋਂ -pdfjs-scroll-horizontal-button-label = ਲੇਟਵਾਂ ਸਰਕਾਉਣਾ -pdfjs-scroll-wrapped-button = - .title = ਸਮੇਟੇ ਸਰਕਾਉਣ ਨੂੰ ਵਰਤੋਂ -pdfjs-scroll-wrapped-button-label = ਸਮੇਟਿਆ ਸਰਕਾਉਣਾ -pdfjs-spread-none-button = - .title = ਸਫ਼ਾ ਫੈਲਾਅ ਵਿੱਚ ਸ਼ਾਮਲ ਨਾ ਹੋਵੋ -pdfjs-spread-none-button-label = ਕੋਈ ਫੈਲਾਅ ਨਹੀਂ -pdfjs-spread-odd-button = - .title = ਟਾਂਕ ਅੰਕ ਵਾਲੇ ਸਫ਼ਿਆਂ ਨਾਲ ਸ਼ੁਰੂ ਹੋਣ ਵਾਲੇ ਸਫਿਆਂ ਵਿੱਚ ਸ਼ਾਮਲ ਹੋਵੋ -pdfjs-spread-odd-button-label = ਟਾਂਕ ਫੈਲਾਅ -pdfjs-spread-even-button = - .title = ਜਿਸਤ ਅੰਕ ਵਾਲੇ ਸਫ਼ਿਆਂ ਨਾਲ ਸ਼ੁਰੂ ਹੋਣ ਵਾਲੇ ਸਫਿਆਂ ਵਿੱਚ ਸ਼ਾਮਲ ਹੋਵੋ -pdfjs-spread-even-button-label = ਜਿਸਤ ਫੈਲਾਅ - -## Document properties dialog - -pdfjs-document-properties-button = - .title = …ਦਸਤਾਵੇਜ਼ ਦੀ ਵਿਸ਼ੇਸ਼ਤਾ -pdfjs-document-properties-button-label = …ਦਸਤਾਵੇਜ਼ ਦੀ ਵਿਸ਼ੇਸ਼ਤਾ -pdfjs-document-properties-file-name = ਫਾਈਲ ਦਾ ਨਾਂ: -pdfjs-document-properties-file-size = ਫਾਈਲ ਦਾ ਆਕਾਰ: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } ਬਾਈਟ) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } ਬਾਈਟ) -pdfjs-document-properties-title = ਟਾਈਟਲ: -pdfjs-document-properties-author = ਲੇਖਕ: -pdfjs-document-properties-subject = ਵਿਸ਼ਾ: -pdfjs-document-properties-keywords = ਸ਼ਬਦ: -pdfjs-document-properties-creation-date = ਬਣਾਉਣ ਦੀ ਮਿਤੀ: -pdfjs-document-properties-modification-date = ਸੋਧ ਦੀ ਮਿਤੀ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = ਨਿਰਮਾਤਾ: -pdfjs-document-properties-producer = PDF ਪ੍ਰੋਡਿਊਸਰ: -pdfjs-document-properties-version = PDF ਵਰਜਨ: -pdfjs-document-properties-page-count = ਸਫ਼ੇ ਦੀ ਗਿਣਤੀ: -pdfjs-document-properties-page-size = ਸਫ਼ਾ ਆਕਾਰ: -pdfjs-document-properties-page-size-unit-inches = ਇੰਚ -pdfjs-document-properties-page-size-unit-millimeters = ਮਿਮੀ -pdfjs-document-properties-page-size-orientation-portrait = ਪੋਰਟਰੇਟ -pdfjs-document-properties-page-size-orientation-landscape = ਲੈਂਡਸਕੇਪ -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = ਲੈਟਰ -pdfjs-document-properties-page-size-name-legal = ਕਨੂੰਨੀ - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = ਤੇਜ਼ ਵੈੱਬ ਝਲਕ: -pdfjs-document-properties-linearized-yes = ਹਾਂ -pdfjs-document-properties-linearized-no = ਨਹੀਂ -pdfjs-document-properties-close-button = ਬੰਦ ਕਰੋ - -## Print - -pdfjs-print-progress-message = …ਪਰਿੰਟ ਕਰਨ ਲਈ ਦਸਤਾਵੇਜ਼ ਨੂੰ ਤਿਆਰ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = ਰੱਦ ਕਰੋ -pdfjs-printing-not-supported = ਸਾਵਧਾਨ: ਇਹ ਬਰਾਊਜ਼ਰ ਪਰਿੰਟ ਕਰਨ ਲਈ ਪੂਰੀ ਤਰ੍ਹਾਂ ਸਹਾਇਕ ਨਹੀਂ ਹੈ। -pdfjs-printing-not-ready = ਸਾਵਧਾਨ: PDF ਨੂੰ ਪਰਿੰਟ ਕਰਨ ਲਈ ਪੂਰੀ ਤਰ੍ਹਾਂ ਲੋਡ ਨਹੀਂ ਹੈ। - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = ਬਾਹੀ ਬਦਲੋ -pdfjs-toggle-sidebar-notification-button = - .title = ਬਾਹੀ ਨੂੰ ਬਦਲੋ (ਦਸਤਾਵੇਜ਼ ਖਾਕਾ/ਅਟੈਚਮੈਂਟ/ਪਰਤਾਂ ਰੱਖਦਾ ਹੈ) -pdfjs-toggle-sidebar-button-label = ਬਾਹੀ ਬਦਲੋ -pdfjs-document-outline-button = - .title = ਦਸਤਾਵੇਜ਼ ਖਾਕਾ ਦਿਖਾਓ (ਸਾਰੀਆਂ ਆਈਟਮਾਂ ਨੂੰ ਫੈਲਾਉਣ/ਸਮੇਟਣ ਲਈ ਦੋ ਵਾਰ ਕਲਿੱਕ ਕਰੋ) -pdfjs-document-outline-button-label = ਦਸਤਾਵੇਜ਼ ਖਾਕਾ -pdfjs-attachments-button = - .title = ਅਟੈਚਮੈਂਟ ਵੇਖਾਓ -pdfjs-attachments-button-label = ਅਟੈਚਮੈਂਟਾਂ -pdfjs-layers-button = - .title = ਪਰਤਾਂ ਵੇਖਾਓ (ਸਾਰੀਆਂ ਪਰਤਾਂ ਨੂੰ ਮੂਲ ਹਾਲਤ ਉੱਤੇ ਮੁੜ-ਸੈੱਟ ਕਰਨ ਲਈ ਦੋ ਵਾਰ ਕਲਿੱਕ ਕਰੋ) -pdfjs-layers-button-label = ਪਰਤਾਂ -pdfjs-thumbs-button = - .title = ਥੰਮਨੇਲ ਨੂੰ ਵੇਖਾਓ -pdfjs-thumbs-button-label = ਥੰਮਨੇਲ -pdfjs-current-outline-item-button = - .title = ਮੌੌਜੂਦਾ ਖਾਕਾ ਚੀਜ਼ ਲੱਭੋ -pdfjs-current-outline-item-button-label = ਮੌਜੂਦਾ ਖਾਕਾ ਚੀਜ਼ -pdfjs-findbar-button = - .title = ਦਸਤਾਵੇਜ਼ ਵਿੱਚ ਲੱਭੋ -pdfjs-findbar-button-label = ਲੱਭੋ -pdfjs-additional-layers = ਵਾਧੂ ਪਰਤਾਂ - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = ਸਫ਼ਾ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } ਸਫ਼ੇ ਦਾ ਥੰਮਨੇਲ - -## Find panel button title and messages - -pdfjs-find-input = - .title = ਲੱਭੋ - .placeholder = …ਦਸਤਾਵੇਜ਼ 'ਚ ਲੱਭੋ -pdfjs-find-previous-button = - .title = ਵਾਕ ਦੀ ਪਿਛਲੀ ਮੌਜੂਦਗੀ ਲੱਭੋ -pdfjs-find-previous-button-label = ਪਿੱਛੇ -pdfjs-find-next-button = - .title = ਵਾਕ ਦੀ ਅਗਲੀ ਮੌਜੂਦਗੀ ਲੱਭੋ -pdfjs-find-next-button-label = ਅੱਗੇ -pdfjs-find-highlight-checkbox = ਸਭ ਉਭਾਰੋ -pdfjs-find-match-case-checkbox-label = ਅੱਖਰ ਆਕਾਰ ਨੂੰ ਮਿਲਾਉ -pdfjs-find-match-diacritics-checkbox-label = ਭੇਦਸੂਚਕ ਮੇਲ -pdfjs-find-entire-word-checkbox-label = ਪੂਰੇ ਸ਼ਬਦ -pdfjs-find-reached-top = ਦਸਤਾਵੇਜ਼ ਦੇ ਉੱਤੇ ਆ ਗਏ ਹਾਂ, ਥੱਲੇ ਤੋਂ ਜਾਰੀ ਰੱਖਿਆ ਹੈ -pdfjs-find-reached-bottom = ਦਸਤਾਵੇਜ਼ ਦੇ ਅੰਤ ਉੱਤੇ ਆ ਗਏ ਹਾਂ, ਉੱਤੇ ਤੋਂ ਜਾਰੀ ਰੱਖਿਆ ਹੈ -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $total } ਵਿੱਚੋਂ { $current } ਮੇਲ - *[other] { $total } ਵਿੱਚੋਂ { $current } ਮੇਲ - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] { $limit } ਤੋਂ ਵੱਧ ਮੇਲ - *[other] { $limit } ਤੋਂ ਵੱਧ ਮੇਲ - } -pdfjs-find-not-found = ਵਾਕ ਨਹੀਂ ਲੱਭਿਆ - -## Predefined zoom values - -pdfjs-page-scale-width = ਸਫ਼ੇ ਦੀ ਚੌੜਾਈ -pdfjs-page-scale-fit = ਸਫ਼ਾ ਫਿੱਟ -pdfjs-page-scale-auto = ਆਟੋਮੈਟਿਕ ਜ਼ੂਮ ਕਰੋ -pdfjs-page-scale-actual = ਆਟੋਮੈਟਿਕ ਆਕਾਰ -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = ਸਫ਼ਾ { $page } - -## Loading indicator messages - -pdfjs-loading-error = PDF ਲੋਡ ਕਰਨ ਦੇ ਦੌਰਾਨ ਗਲਤੀ ਆਈ ਹੈ। -pdfjs-invalid-file-error = ਗਲਤ ਜਾਂ ਨਿਕਾਰਾ PDF ਫਾਈਲ ਹੈ। -pdfjs-missing-file-error = ਨਾ-ਮੌਜੂਦ PDF ਫਾਈਲ। -pdfjs-unexpected-response-error = ਅਣਜਾਣ ਸਰਵਰ ਜਵਾਬ। -pdfjs-rendering-error = ਸਫ਼ਾ ਰੈਡਰ ਕਰਨ ਦੇ ਦੌਰਾਨ ਗਲਤੀ ਆਈ ਹੈ। - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } ਵਿਆਖਿਆ] - -## Password - -pdfjs-password-label = ਇਹ PDF ਫਾਈਲ ਨੂੰ ਖੋਲ੍ਹਣ ਲਈ ਪਾਸਵਰਡ ਦਿਉ। -pdfjs-password-invalid = ਗਲਤ ਪਾਸਵਰਡ। ਫੇਰ ਕੋਸ਼ਿਸ਼ ਕਰੋ ਜੀ। -pdfjs-password-ok-button = ਠੀਕ ਹੈ -pdfjs-password-cancel-button = ਰੱਦ ਕਰੋ -pdfjs-web-fonts-disabled = ਵੈਬ ਫੋਂਟ ਬੰਦ ਹਨ: ਇੰਬੈਡ PDF ਫੋਂਟ ਨੂੰ ਵਰਤਣ ਲਈ ਅਸਮਰੱਥ ਹੈ। - -## Editing - -pdfjs-editor-free-text-button = - .title = ਲਿਖਤ -pdfjs-editor-free-text-button-label = ਲਿਖਤ -pdfjs-editor-ink-button = - .title = ਵਾਹੋ -pdfjs-editor-ink-button-label = ਵਾਹੋ -pdfjs-editor-stamp-button = - .title = ਚਿੱਤਰ ਜੋੜੋ ਜਾਂ ਸੋਧੋ -pdfjs-editor-stamp-button-label = ਚਿੱਤਰ ਜੋੜੋ ਜਾਂ ਸੋਧੋ -pdfjs-editor-highlight-button = - .title = ਹਾਈਲਾਈਟ -pdfjs-editor-highlight-button-label = ਹਾਈਲਾਈਟ -pdfjs-highlight-floating-button = - .title = ਹਾਈਲਾਈਟ -pdfjs-highlight-floating-button1 = - .title = ਹਾਈਲਾਈਟ - .aria-label = ਹਾਈਲਾਈਟ -pdfjs-highlight-floating-button-label = ਹਾਈਲਾਈਟ - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = ਡਰਾਇੰਗ ਨੂੰ ਹਟਾਓ -pdfjs-editor-remove-freetext-button = - .title = ਲਿਖਤ ਨੂੰ ਹਟਾਓ -pdfjs-editor-remove-stamp-button = - .title = ਚਿੱਤਰ ਨੂੰ ਹਟਾਓ -pdfjs-editor-remove-highlight-button = - .title = ਹਾਈਲਾਈਟ ਨੂੰ ਹਟਾਓ - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = ਰੰਗ -pdfjs-editor-free-text-size-input = ਆਕਾਰ -pdfjs-editor-ink-color-input = ਰੰਗ -pdfjs-editor-ink-thickness-input = ਮੋਟਾਈ -pdfjs-editor-ink-opacity-input = ਧੁੰਦਲਾਪਨ -pdfjs-editor-stamp-add-image-button = - .title = ਚਿੱਤਰ ਜੋੜੋ -pdfjs-editor-stamp-add-image-button-label = ਚਿੱਤਰ ਜੋੜੋ -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = ਮੋਟਾਈ -pdfjs-editor-free-highlight-thickness-title = - .title = ਚੀਜ਼ਾਂ ਨੂੰ ਹੋਰ ਲਿਖਤਾਂ ਤੋਂ ਉਘਾੜਨ ਸਮੇਂ ਮੋਟਾਈ ਨੂੰ ਬਦਲੋ -pdfjs-free-text = - .aria-label = ਲਿਖਤ ਐਡੀਟਰ -pdfjs-free-text-default-content = …ਲਿਖਣਾ ਸ਼ੁਰੂ ਕਰੋ -pdfjs-ink = - .aria-label = ਵਹਾਉਣ ਐਡੀਟਰ -pdfjs-ink-canvas = - .aria-label = ਵਰਤੋਂਕਾਰ ਵਲੋਂ ਬਣਾਇਆ ਚਿੱਤਰ - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = ਬਦਲਵੀਂ ਲਿਖਤ -pdfjs-editor-alt-text-edit-button-label = ਬਦਲਵੀ ਲਿਖਤ ਨੂੰ ਸੋਧੋ -pdfjs-editor-alt-text-dialog-label = ਚੋਣ ਕਰੋ -pdfjs-editor-alt-text-dialog-description = ਚਿੱਤਰ ਨਾ ਦਿੱਸਣ ਜਾਂ ਲੋਡ ਨਾ ਹੋਣ ਦੀ ਹਾਲਤ ਵਿੱਚ Alt ਲਿਖਤ (ਬਦਲਵੀਂ ਲਿਖਤ) ਲੋਕਾਂ ਲਈ ਮਦਦਗਾਰ ਹੁੰਦੀ ਹੈ। -pdfjs-editor-alt-text-add-description-label = ਵਰਣਨ ਜੋੜੋ -pdfjs-editor-alt-text-add-description-description = 1-2 ਵਾਕ ਰੱਖੋ, ਜੋ ਕਿ ਵਿਸ਼ੇ, ਸੈਟਿੰਗ ਜਾਂ ਕਾਰਵਾਈਆਂ ਬਾਰੇ ਦਰਸਾਉਂਦੇ ਹੋਣ। -pdfjs-editor-alt-text-mark-decorative-label = ਸਜਾਵਟ ਵਜੋਂ ਨਿਸ਼ਾਨ ਲਾਇਆ -pdfjs-editor-alt-text-mark-decorative-description = ਇਸ ਨੂੰ ਸਜਾਵਟੀ ਚਿੱਤਰਾਂ ਲਈ ਵਰਤਿਆ ਜਾਂਦਾ ਹੈ ਜਿਵੇਂ ਕਿ ਹਾਸ਼ੀਆ ਜਾਂ ਵਾਟਰਮਾਰਕ ਆਦਿ। -pdfjs-editor-alt-text-cancel-button = ਰੱਦ ਕਰੋ -pdfjs-editor-alt-text-save-button = ਸੰਭਾਲੋ -pdfjs-editor-alt-text-decorative-tooltip = ਸਜਾਵਟ ਵਜੋਂ ਨਿਸ਼ਾਨ ਲਾਓ -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = ਮਿਸਾਲ ਵਜੋਂ, “ਗੱਭਰੂ ਭੋਜਨ ਲੈ ਕੇ ਮੇਜ਼ ਉੱਤੇ ਬੈਠਾ ਹੈ” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = ਉੱਤੇ ਖੱਬਾ ਕੋਨਾ — ਮੁੜ-ਆਕਾਰ ਕਰੋ -pdfjs-editor-resizer-label-top-middle = ਉੱਤੇ ਮੱਧ — ਮੁੜ-ਆਕਾਰ ਕਰੋ -pdfjs-editor-resizer-label-top-right = ਉੱਤੇ ਸੱਜਾ ਕੋਨਾ — ਮੁੜ-ਆਕਾਰ ਕਰੋ -pdfjs-editor-resizer-label-middle-right = ਮੱਧ ਸੱਜਾ — ਮੁੜ-ਆਕਾਰ ਕਰੋ -pdfjs-editor-resizer-label-bottom-right = ਹੇਠਾਂ ਸੱਜਾ ਕੋਨਾ — ਮੁੜ-ਆਕਾਰ ਕਰੋ -pdfjs-editor-resizer-label-bottom-middle = ਹੇਠਾਂ ਮੱਧ — ਮੁੜ-ਆਕਾਰ ਕਰੋ -pdfjs-editor-resizer-label-bottom-left = ਹੇਠਾਂ ਖੱਬਾ ਕੋਨਾ — ਮੁੜ-ਆਕਾਰ ਕਰੋ -pdfjs-editor-resizer-label-middle-left = ਮੱਧ ਖੱਬਾ — ਮੁੜ-ਆਕਾਰ ਕਰੋ - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = ਹਾਈਟਲਾਈਟ ਦਾ ਰੰਗ -pdfjs-editor-colorpicker-button = - .title = ਰੰਗ ਨੂੰ ਬਦਲੋ -pdfjs-editor-colorpicker-dropdown = - .aria-label = ਰੰਗ ਚੋਣਾਂ -pdfjs-editor-colorpicker-yellow = - .title = ਪੀਲਾ -pdfjs-editor-colorpicker-green = - .title = ਹਰਾ -pdfjs-editor-colorpicker-blue = - .title = ਨੀਲਾ -pdfjs-editor-colorpicker-pink = - .title = ਗੁਲਾਬੀ -pdfjs-editor-colorpicker-red = - .title = ਲਾਲ - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = ਸਭ ਵੇਖੋ -pdfjs-editor-highlight-show-all-button = - .title = ਸਭ ਵੇਖੋ diff --git a/static/pdf.js/locale/pa-IN/viewer.properties b/static/pdf.js/locale/pa-IN/viewer.properties new file mode 100644 index 00000000..fb26fc31 --- /dev/null +++ b/static/pdf.js/locale/pa-IN/viewer.properties @@ -0,0 +1,181 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=ਸਫ਼ਾ ਪਿੱਛੇ +previous_label=ਪਿੱਛੇ +next.title=ਸਫ਼ਾ ਅੱਗੇ +next_label=ਅੱਗੇ + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=ਸਫ਼ਾ: +page_of={{pageCount}} ਵਿੱਚੋਂ + +zoom_out.title=ਜ਼ੂਮ ਆਉਟ +zoom_out_label=ਜ਼ੂਮ ਆਉਟ +zoom_in.title=ਜ਼ੂਮ ਇਨ +zoom_in_label=ਜ਼ੂਮ ਇਨ +zoom.title=ਜ਼ੂਨ +print.title=ਪਰਿੰਟ +print_label=ਪਰਿੰਟ +presentation_mode.title=ਪਰਿਜੈਂਟੇਸ਼ਨ ਮੋਡ ਵਿੱਚ ਜਾਓ +presentation_mode_label=ਪਰਿਜੈਂਟੇਸ਼ਨ ਮੋਡ + +open_file.title=ਫਾਈਲ ਖੋਲ੍ਹੋ +open_file_label=ਖੋਲ੍ਹੋ +download.title=ਡਾਊਨਲੋਡ +download_label=ਡਾਊਨਲੋਡ +bookmark.title=ਮੌਜੂਦਾ ਝਲਕ (ਨਵੀਂ ਵਿੰਡੋ ਵਿੱਚ ਕਾਪੀ ਕਰੋ ਜਾਂ ਖੋਲ੍ਹੋ) +bookmark_label=ਮੌਜੂਦਾ ਝਲਕ + +# Secondary toolbar and context menu +tools.title=ਟੂਲ +tools_label=ਟੂਲ +first_page.title=ਪਹਿਲੇ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ +first_page.label=ਪਹਿਲੇ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ +first_page_label=ਪਹਿਲੇ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ + +last_page.title=ਆਖਰੀ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ +last_page_label=ਆਖਰੀ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ +page_rotate_cw.title=ਸੱਜੇ ਦਾਅ ਘੁੰਮਾਓ +page_rotate_cw.label=ਸੱਜੇ ਦਾਅ ਘੁੰਮਾਓ +page_rotate_cw_label=ਸੱਜੇ ਦਾਅ ਘੁੰਮਾਓ +page_rotate_ccw.title=ਖੱਬੇ ਦਾਅ ਘੁੰਮਾਓ +page_rotate_ccw_label=ਖੱਬੇ ਦਾਅ ਘੁੰਮਾਓ + +hand_tool_enable.title=ਹੱਥ ਟੂਲ ਚਾਲੂ +hand_tool_enable_label=ਹੱਥ ਟੂਲ ਚਾਲੂ +hand_tool_disable.title=ਹੱਥ ਟੂਲ ਬੰਦ +hand_tool_disable_label=ਹੱਥ ਟੂਲ ਬੰਦ + +# Document properties dialog box +document_properties.title=…ਦਸਤਾਵੇਜ਼ ਵਿਸ਼ੇਸ਼ਤਾ +document_properties_label=…ਦਸਤਾਵੇਜ਼ ਵਿਸ਼ੇਸ਼ਤਾ +document_properties_file_name=ਫਾਈਲ ਨਾਂ: +document_properties_file_size=ਫਾਈਲ ਆਕਾਰ: +document_properties_kb={{size_kb}} KB ({{size_b}} ਬਾਈਟ) +document_properties_mb={{size_mb}} MB ({{size_b}} ਬਾਈਟ) +document_properties_title=ਟਾਈਟਲ: +document_properties_author=ਲੇਖਕ: +document_properties_subject=ਵਿਸ਼ਾ: +document_properties_keywords=ਸ਼ਬਦ: +document_properties_creation_date=ਬਣਾਉਣ ਮਿਤੀ: +document_properties_modification_date=ਸੋਧ ਮਿਤੀ: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=ਨਿਰਮਾਤਾ: +document_properties_producer=PDF ਪ੍ਰੋਡਿਊਸਰ: +document_properties_version=PDF ਵਰਜਨ: +document_properties_page_count=ਸਫ਼ਾ ਗਿਣਤੀ: +document_properties_close=ਬੰਦ ਕਰੋ + + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=ਬਾਹੀ ਬਦਲੋ +toggle_sidebar_label=ਬਾਹੀ ਬਦਲੋ + +outline.title=ਦਸਤਾਵੇਜ਼ ਆਉਟਲਾਈਨ ਵੇਖਾਓ +outline_label=ਦਸਤਾਵੇਜ਼ ਆਉਟਲਾਈਨ +attachments.title=ਅਟੈਚਮੈਂਟ ਵੇਖਾਓ +attachments_label=ਅਟੈਚਮੈਂਟ +thumbs.title=ਥੰਮਨੇਲ ਵੇਖਾਓ +thumbs_label=ਥੰਮਨੇਲ +findbar.title=ਦਸਤਾਵੇਜ਼ ਵਿੱਚ ਲੱਭੋ +findbar_label=ਲੱਭੋ + + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=ਸਫ਼ਾ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}} ਸਫ਼ੇ ਦਾ ਥੰਮਨੇਲ + + +# Context menu +first_page.label=ਪਹਿਲੇ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ +last_page.label=ਆਖਰੀ ਸਫ਼ੇ ਉੱਤੇ ਜਾਓ +page_rotate_cw.label=ਸੱਜੇ ਦਾਅ ਘੁੰਮਾਉ +page_rotate_ccw.label=ਖੱਬੇ ਦਾਅ ਘੁੰਮਾਉ + +# Find panel button title and messages +find_label=ਲੱਭੋ: +find_previous.title=ਵਾਕ ਦੀ ਪਿਛਲੀ ਮੌਜੂਦਗੀ ਲੱਭੋ +find_previous_label=ਪਿੱਛੇ +find_next.title=ਵਾਕ ਦੀ ਅਗਲੀ ਮੌਜੂਦਗੀ ਲੱਭੋ +find_next_label=ਅੱਗੇ +find_highlight=ਸਭ ਉਭਾਰੋ +find_match_case_label=ਅੱਖਰ ਆਕਾਰ ਮਿਲਾਉ +find_reached_top=ਦਸਤਾਵੇਜ਼ ਦੇ ਉੱਤੇ ਆ ਗਏ ਹਾਂ, ਥੱਲੇ ਤੋਂ ਜਾਰੀ ਰੱਖਿਆ ਹੈ +find_reached_bottom=ਦਸਤਾਵੇਜ਼ ਦੇ ਅੰਤ ਉੱਤੇ ਆ ਗਏ ਹਾਂ, ਉੱਤੇ ਤੋਂ ਜਾਰੀ ਰੱਖਿਆ ਹੈ +find_not_found=ਵਾਕ ਨਹੀਂ ਲੱਭਿਆ + + +# Error panel labels +error_more_info=ਹੋਰ ਜਾਣਕਾਰੀ +error_less_info=ਘੱਟ ਜਾਣਕਾਰੀ +error_close=ਬੰਦ ਕਰੋ + +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (ਬਿਲਡ: {{build}} + +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=ਸੁਨੇਹਾ: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=ਸਟੈਕ: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ਫਾਈਲ: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=ਲਾਈਨ: {{line}} +rendering_error=ਸਫ਼ਾ ਰੈਡਰ ਕਰਨ ਦੇ ਦੌਰਾਨ ਗਲਤੀ ਆਈ ਹੈ। + +# Predefined zoom values +page_scale_width=ਸਫ਼ਾ ਚੌੜਾਈ +page_scale_fit=ਸਫ਼ਾ ਫਿੱਟ +page_scale_auto=ਆਟੋਮੈਟਿਕ ਜ਼ੂਮ +page_scale_actual=ਆਟੋਮੈਟਿਕ ਆਕਾਰ +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +# LOCALIZATION NOTE (error_line): "{{[percent}}" will be replaced with a percentage +loading_error_indicator=ਗਲਤੀ +loading_error=PDF ਲੋਡ ਕਰਨ ਦੇ ਦੌਰਾਨ ਗਲਤੀ ਆਈ ਹੈ। +invalid_file_error=ਗਲਤ ਜਾਂ ਨਿਕਾਰਾ PDF ਫਾਈਲ ਹੈ। +missing_file_error=ਨਾ-ਮੌਜੂਦ PDF ਫਾਈਲ। +unexpected_response_error=ਅਣਜਾਣ ਸਰਵਰ ਜਵਾਬ। + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} ਵਿਆਖਿਆ] +password_label=ਇਹ PDF ਫਾਈਲ ਖੋਲ੍ਹਣ ਲਈ ਪਾਸਵਰਡ ਦਿਉ। +password_invalid=ਗਲਤ ਪਾਸਵਰਡ। ਫੇਰ ਕੋਸ਼ਿਸ਼ ਕਰੋ ਜੀ। +password_ok=ਠੀਕ ਹੈ +password_cancel=ਰੱਦ ਕਰੋ + +printing_not_supported=ਸਾਵਧਾਨ: ਇਹ ਬਰਾਊਜ਼ਰ ਪਰਿੰਟ ਕਰਨ ਲਈ ਪੂਰੀ ਤਰ੍ਹਾਂ ਸਹਾਇਕ ਨਹੀਂ ਹੈ। +printing_not_ready=ਸਾਵਧਾਨ: PDF ਪਰਿੰਟ ਕਰਨ ਲਈ ਪੂਰੀ ਤਰ੍ਹਾਂ ਲੋਡ ਨਹੀਂ ਹੈ। +web_fonts_disabled=ਵੈਬ ਫੋਂਟ ਬੰਦ ਹਨ: ਇੰਬੈਡ PDF ਫੋਂਟ ਵਰਤਨ ਲਈ ਅਸਮਰੱਥ ਹੈ। +document_colors_disabled=PDF ਡੌਕੂਮੈਂਟ ਨੂੰ ਆਪਣੇ ਰੰਗ ਵਰਤਣ ਦੀ ਇਜ਼ਾਜ਼ਤ ਨਹੀਂ ਹੈ।: ਬਰਾਊਜ਼ਰ ਵਿੱਚ \u0022ਸਫ਼ਿਆਂ ਨੂੰ ਆਪਣੇ ਰੰਗ ਵਰਤਣ ਦਿਉ\u0022 ਨੂੰ ਬੰਦ ਕੀਤਾ ਹੋਇਆ ਹੈ। \ No newline at end of file diff --git a/static/pdf.js/locale/pl/viewer.ftl b/static/pdf.js/locale/pl/viewer.ftl deleted file mode 100644 index b34d6074..00000000 --- a/static/pdf.js/locale/pl/viewer.ftl +++ /dev/null @@ -1,404 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Poprzednia strona -pdfjs-previous-button-label = Poprzednia -pdfjs-next-button = - .title = Następna strona -pdfjs-next-button-label = Następna -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Strona -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = z { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } z { $pagesCount }) -pdfjs-zoom-out-button = - .title = Pomniejsz -pdfjs-zoom-out-button-label = Pomniejsz -pdfjs-zoom-in-button = - .title = Powiększ -pdfjs-zoom-in-button-label = Powiększ -pdfjs-zoom-select = - .title = Skala -pdfjs-presentation-mode-button = - .title = Przełącz na tryb prezentacji -pdfjs-presentation-mode-button-label = Tryb prezentacji -pdfjs-open-file-button = - .title = Otwórz plik -pdfjs-open-file-button-label = Otwórz -pdfjs-print-button = - .title = Drukuj -pdfjs-print-button-label = Drukuj -pdfjs-save-button = - .title = Zapisz -pdfjs-save-button-label = Zapisz -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Pobierz -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Pobierz -pdfjs-bookmark-button = - .title = Bieżąca strona (adres do otwarcia na bieżącej stronie) -pdfjs-bookmark-button-label = Bieżąca strona -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Otwórz w aplikacji -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Otwórz w aplikacji - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Narzędzia -pdfjs-tools-button-label = Narzędzia -pdfjs-first-page-button = - .title = Przejdź do pierwszej strony -pdfjs-first-page-button-label = Przejdź do pierwszej strony -pdfjs-last-page-button = - .title = Przejdź do ostatniej strony -pdfjs-last-page-button-label = Przejdź do ostatniej strony -pdfjs-page-rotate-cw-button = - .title = Obróć zgodnie z ruchem wskazówek zegara -pdfjs-page-rotate-cw-button-label = Obróć zgodnie z ruchem wskazówek zegara -pdfjs-page-rotate-ccw-button = - .title = Obróć przeciwnie do ruchu wskazówek zegara -pdfjs-page-rotate-ccw-button-label = Obróć przeciwnie do ruchu wskazówek zegara -pdfjs-cursor-text-select-tool-button = - .title = Włącz narzędzie zaznaczania tekstu -pdfjs-cursor-text-select-tool-button-label = Narzędzie zaznaczania tekstu -pdfjs-cursor-hand-tool-button = - .title = Włącz narzędzie rączka -pdfjs-cursor-hand-tool-button-label = Narzędzie rączka -pdfjs-scroll-page-button = - .title = Przewijaj strony -pdfjs-scroll-page-button-label = Przewijanie stron -pdfjs-scroll-vertical-button = - .title = Przewijaj dokument w pionie -pdfjs-scroll-vertical-button-label = Przewijanie pionowe -pdfjs-scroll-horizontal-button = - .title = Przewijaj dokument w poziomie -pdfjs-scroll-horizontal-button-label = Przewijanie poziome -pdfjs-scroll-wrapped-button = - .title = Strony dokumentu wyświetlaj i przewijaj w kolumnach -pdfjs-scroll-wrapped-button-label = Widok dwóch stron -pdfjs-spread-none-button = - .title = Nie ustawiaj stron obok siebie -pdfjs-spread-none-button-label = Brak kolumn -pdfjs-spread-odd-button = - .title = Strony nieparzyste ustawiaj na lewo od parzystych -pdfjs-spread-odd-button-label = Nieparzyste po lewej -pdfjs-spread-even-button = - .title = Strony parzyste ustawiaj na lewo od nieparzystych -pdfjs-spread-even-button-label = Parzyste po lewej - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Właściwości dokumentu… -pdfjs-document-properties-button-label = Właściwości dokumentu… -pdfjs-document-properties-file-name = Nazwa pliku: -pdfjs-document-properties-file-size = Rozmiar pliku: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } B) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } B) -pdfjs-document-properties-title = Tytuł: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Temat: -pdfjs-document-properties-keywords = Słowa kluczowe: -pdfjs-document-properties-creation-date = Data utworzenia: -pdfjs-document-properties-modification-date = Data modyfikacji: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Utworzony przez: -pdfjs-document-properties-producer = PDF wyprodukowany przez: -pdfjs-document-properties-version = Wersja PDF: -pdfjs-document-properties-page-count = Liczba stron: -pdfjs-document-properties-page-size = Wymiary strony: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = pionowa -pdfjs-document-properties-page-size-orientation-landscape = pozioma -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = US Letter -pdfjs-document-properties-page-size-name-legal = US Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width }×{ $height } { $unit } (orientacja { $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width }×{ $height } { $unit } ({ $name }, orientacja { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Szybki podgląd w Internecie: -pdfjs-document-properties-linearized-yes = tak -pdfjs-document-properties-linearized-no = nie -pdfjs-document-properties-close-button = Zamknij - -## Print - -pdfjs-print-progress-message = Przygotowywanie dokumentu do druku… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Anuluj -pdfjs-printing-not-supported = Ostrzeżenie: drukowanie nie jest w pełni obsługiwane przez tę przeglądarkę. -pdfjs-printing-not-ready = Ostrzeżenie: dokument PDF nie jest całkowicie wczytany, więc nie można go wydrukować. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Przełącz panel boczny -pdfjs-toggle-sidebar-notification-button = - .title = Przełącz panel boczny (dokument zawiera konspekt/załączniki/warstwy) -pdfjs-toggle-sidebar-button-label = Przełącz panel boczny -pdfjs-document-outline-button = - .title = Konspekt dokumentu (podwójne kliknięcie rozwija lub zwija wszystkie pozycje) -pdfjs-document-outline-button-label = Konspekt dokumentu -pdfjs-attachments-button = - .title = Załączniki -pdfjs-attachments-button-label = Załączniki -pdfjs-layers-button = - .title = Warstwy (podwójne kliknięcie przywraca wszystkie warstwy do stanu domyślnego) -pdfjs-layers-button-label = Warstwy -pdfjs-thumbs-button = - .title = Miniatury -pdfjs-thumbs-button-label = Miniatury -pdfjs-current-outline-item-button = - .title = Znajdź bieżący element konspektu -pdfjs-current-outline-item-button-label = Bieżący element konspektu -pdfjs-findbar-button = - .title = Znajdź w dokumencie -pdfjs-findbar-button-label = Znajdź -pdfjs-additional-layers = Dodatkowe warstwy - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page }. strona -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura { $page }. strony - -## Find panel button title and messages - -pdfjs-find-input = - .title = Znajdź - .placeholder = Znajdź w dokumencie… -pdfjs-find-previous-button = - .title = Znajdź poprzednie wystąpienie tekstu -pdfjs-find-previous-button-label = Poprzednie -pdfjs-find-next-button = - .title = Znajdź następne wystąpienie tekstu -pdfjs-find-next-button-label = Następne -pdfjs-find-highlight-checkbox = Wyróżnianie wszystkich -pdfjs-find-match-case-checkbox-label = Rozróżnianie wielkości liter -pdfjs-find-match-diacritics-checkbox-label = Rozróżnianie liter diakrytyzowanych -pdfjs-find-entire-word-checkbox-label = Całe słowa -pdfjs-find-reached-top = Początek dokumentu. Wyszukiwanie od końca. -pdfjs-find-reached-bottom = Koniec dokumentu. Wyszukiwanie od początku. -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current }. z { $total } trafienia - [few] { $current }. z { $total } trafień - *[many] { $current }. z { $total } trafień - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Więcej niż { $limit } trafienie - [few] Więcej niż { $limit } trafienia - *[many] Więcej niż { $limit } trafień - } -pdfjs-find-not-found = Nie znaleziono tekstu - -## Predefined zoom values - -pdfjs-page-scale-width = Szerokość strony -pdfjs-page-scale-fit = Dopasowanie strony -pdfjs-page-scale-auto = Skala automatyczna -pdfjs-page-scale-actual = Rozmiar oryginalny -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = { $page }. strona - -## Loading indicator messages - -pdfjs-loading-error = Podczas wczytywania dokumentu PDF wystąpił błąd. -pdfjs-invalid-file-error = Nieprawidłowy lub uszkodzony plik PDF. -pdfjs-missing-file-error = Brak pliku PDF. -pdfjs-unexpected-response-error = Nieoczekiwana odpowiedź serwera. -pdfjs-rendering-error = Podczas renderowania strony wystąpił błąd. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Przypis: { $type }] - -## Password - -pdfjs-password-label = Wprowadź hasło, aby otworzyć ten dokument PDF. -pdfjs-password-invalid = Nieprawidłowe hasło. Proszę spróbować ponownie. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Anuluj -pdfjs-web-fonts-disabled = Czcionki sieciowe są wyłączone: nie można użyć osadzonych czcionek PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Rysunek -pdfjs-editor-ink-button-label = Rysunek -pdfjs-editor-stamp-button = - .title = Dodaj lub edytuj obrazy -pdfjs-editor-stamp-button-label = Dodaj lub edytuj obrazy -pdfjs-editor-highlight-button = - .title = Wyróżnij -pdfjs-editor-highlight-button-label = Wyróżnij -pdfjs-highlight-floating-button = - .title = Wyróżnij -pdfjs-highlight-floating-button1 = - .title = Wyróżnij - .aria-label = Wyróżnij -pdfjs-highlight-floating-button-label = Wyróżnij - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Usuń rysunek -pdfjs-editor-remove-freetext-button = - .title = Usuń tekst -pdfjs-editor-remove-stamp-button = - .title = Usuń obraz -pdfjs-editor-remove-highlight-button = - .title = Usuń wyróżnienie - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Kolor -pdfjs-editor-free-text-size-input = Rozmiar -pdfjs-editor-ink-color-input = Kolor -pdfjs-editor-ink-thickness-input = Grubość -pdfjs-editor-ink-opacity-input = Nieprzezroczystość -pdfjs-editor-stamp-add-image-button = - .title = Dodaj obraz -pdfjs-editor-stamp-add-image-button-label = Dodaj obraz -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Grubość -pdfjs-editor-free-highlight-thickness-title = - .title = Zmień grubość podczas wyróżniania elementów innych niż tekst -pdfjs-free-text = - .aria-label = Edytor tekstu -pdfjs-free-text-default-content = Zacznij pisać… -pdfjs-ink = - .aria-label = Edytor rysunku -pdfjs-ink-canvas = - .aria-label = Obraz utworzony przez użytkownika - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Tekst alternatywny -pdfjs-editor-alt-text-edit-button-label = Edytuj tekst alternatywny -pdfjs-editor-alt-text-dialog-label = Wybierz opcję -pdfjs-editor-alt-text-dialog-description = Tekst alternatywny pomaga, kiedy ktoś nie może zobaczyć obrazu lub gdy się nie wczytuje. -pdfjs-editor-alt-text-add-description-label = Dodaj opis -pdfjs-editor-alt-text-add-description-description = Staraj się napisać 1-2 zdania opisujące temat, miejsce lub działania. -pdfjs-editor-alt-text-mark-decorative-label = Oznacz jako dekoracyjne -pdfjs-editor-alt-text-mark-decorative-description = Używane w przypadku obrazów ozdobnych, takich jak obramowania lub znaki wodne. -pdfjs-editor-alt-text-cancel-button = Anuluj -pdfjs-editor-alt-text-save-button = Zapisz -pdfjs-editor-alt-text-decorative-tooltip = Oznaczone jako dekoracyjne -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Na przykład: „Młody człowiek siada przy stole, aby zjeść posiłek” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Lewy górny róg — zmień rozmiar -pdfjs-editor-resizer-label-top-middle = Górny środkowy — zmień rozmiar -pdfjs-editor-resizer-label-top-right = Prawy górny róg — zmień rozmiar -pdfjs-editor-resizer-label-middle-right = Prawy środkowy — zmień rozmiar -pdfjs-editor-resizer-label-bottom-right = Prawy dolny róg — zmień rozmiar -pdfjs-editor-resizer-label-bottom-middle = Dolny środkowy — zmień rozmiar -pdfjs-editor-resizer-label-bottom-left = Lewy dolny róg — zmień rozmiar -pdfjs-editor-resizer-label-middle-left = Lewy środkowy — zmień rozmiar - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Kolor wyróżnienia -pdfjs-editor-colorpicker-button = - .title = Zmień kolor -pdfjs-editor-colorpicker-dropdown = - .aria-label = Wybór kolorów -pdfjs-editor-colorpicker-yellow = - .title = Żółty -pdfjs-editor-colorpicker-green = - .title = Zielony -pdfjs-editor-colorpicker-blue = - .title = Niebieski -pdfjs-editor-colorpicker-pink = - .title = Różowy -pdfjs-editor-colorpicker-red = - .title = Czerwony - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Pokaż wszystkie -pdfjs-editor-highlight-show-all-button = - .title = Pokaż wszystkie diff --git a/static/pdf.js/locale/pl/viewer.properties b/static/pdf.js/locale/pl/viewer.properties new file mode 100644 index 00000000..f4fa2735 --- /dev/null +++ b/static/pdf.js/locale/pl/viewer.properties @@ -0,0 +1,124 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +previous.title=Poprzednia strona +previous_label=Poprzednia +next.title=Następna strona +next_label=Następna + +page_label=Strona: +page_of=z {{pageCount}} + +zoom_out.title=Pomniejszenie +zoom_out_label=Pomniejsz +zoom_in.title=Powiększenie +zoom_in_label=Powiększ +zoom.title=Skala +presentation_mode.title=Przełącz na tryb prezentacji +presentation_mode_label=Tryb prezentacji +open_file.title=Otwieranie pliku +open_file_label=Otwórz +print.title=Drukowanie +print_label=Drukuj +download.title=Pobieranie +download_label=Pobierz +bookmark.title=Bieżąca pozycja (skopiuj lub otwórz jako odnośnik w nowym oknie) +bookmark_label=Bieżąca pozycja + +tools.title=Narzędzia +tools_label=Narzędzia +first_page.title=Przechodzenie do pierwszej strony +first_page.label=Przejdź do pierwszej strony +first_page_label=Przejdź do pierwszej strony +last_page.title=Przechodzenie do ostatniej strony +last_page.label=Przejdź do ostatniej strony +last_page_label=Przejdź do ostatniej strony +page_rotate_cw.title=Obracanie zgodnie z ruchem wskazówek zegara +page_rotate_cw.label=Obróć zgodnie z ruchem wskazówek zegara +page_rotate_cw_label=Obróć zgodnie z ruchem wskazówek zegara +page_rotate_ccw.title=Obracanie przeciwnie do ruchu wskazówek zegara +page_rotate_ccw.label=Obróć przeciwnie do ruchu wskazówek zegara +page_rotate_ccw_label=Obróć przeciwnie do ruchu wskazówek zegara + +hand_tool_enable.title=Włączanie narzędzia rączka +hand_tool_enable_label=Włącz narzędzie rączka +hand_tool_disable.title=Wyłączanie narzędzia rączka +hand_tool_disable_label=Wyłącz narzędzie rączka + +document_properties.title=Właściwości dokumentu… +document_properties_label=Właściwości dokumentu… +document_properties_file_name=Nazwa pliku: +document_properties_file_size=Rozmiar pliku: +document_properties_kb={{size_kb}} KB ({{size_b}} b) +document_properties_mb={{size_mb}} MB ({{size_b}} b) +document_properties_title=Tytuł: +document_properties_author=Autor: +document_properties_subject=Temat: +document_properties_keywords=Słowa kluczowe: +document_properties_creation_date=Data utworzenia: +document_properties_modification_date=Data modyfikacji: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Utworzony przez: +document_properties_producer=PDF wyprodukowany przez: +document_properties_version=Wersja PDF: +document_properties_page_count=Liczba stron: +document_properties_close=Zamknij + +toggle_sidebar.title=Przełączanie panelu bocznego +toggle_sidebar_label=Przełącz panel boczny +outline.title=Wyświetlanie zarysu dokumentu +outline_label=Zarys dokumentu +attachments.title=Wyświetlanie załączników +attachments_label=Załączniki +thumbs.title=Wyświetlanie miniaturek +thumbs_label=Miniaturki +findbar.title=Znajdź w dokumencie +findbar_label=Znajdź + +thumb_page_title=Strona {{page}} +thumb_page_canvas=Miniaturka strony {{page}} + +find_label=Znajdź: +find_previous.title=Znajdź poprzednie wystąpienie tekstu +find_previous_label=Poprzednie +find_next.title=Znajdź następne wystąpienie tekstu +find_next_label=Następne +find_highlight=Podświetl wszystkie +find_match_case_label=Rozróżniaj wielkość znaków +find_reached_top=Osiągnięto początek dokumentu, kontynuacja od końca +find_reached_bottom=Osiągnięto koniec dokumentu, kontynuacja od początku +find_not_found=Tekst nieznaleziony + +error_more_info=Więcej informacji +error_less_info=Mniej informacji +error_close=Zamknij +error_version_info=PDF.js v{{version}} (kompilacja: {{build}}) +error_message=Wiadomość: {{message}} +error_stack=Stos: {{stack}} +error_file=Plik: {{file}} +error_line=Wiersz: {{line}} +rendering_error=Podczas renderowania strony wystąpił błąd. + +page_scale_width=Szerokość strony +page_scale_fit=Dopasowanie strony +page_scale_auto=Skala automatyczna +page_scale_actual=Rozmiar rzeczywisty +page_scale_percent={{scale}}% + +loading_error_indicator=Błąd +loading_error=Podczas wczytywania dokumentu PDF wystąpił błąd. +invalid_file_error=Nieprawidłowy lub uszkodzony plik PDF. +missing_file_error=Brak pliku PDF. +unexpected_response_error=Nieoczekiwana odpowiedź serwera. + +text_annotation_type.alt=[Adnotacja: {{type}}] +password_label=Wprowadź hasło, aby otworzyć ten dokument PDF. +password_invalid=Nieprawidłowe hasło. Proszę spróbować ponownie. +password_ok=OK +password_cancel=Anuluj + +printing_not_supported=Ostrzeżenie: Drukowanie nie jest w pełni obsługiwane przez przeglądarkę. +printing_not_ready=Ostrzeżenie: Dokument PDF nie jest całkowicie wczytany, więc nie można go wydrukować. +web_fonts_disabled=Czcionki sieciowe są wyłączone: nie można użyć osadzonych czcionek PDF. +document_colors_not_allowed=Dokumenty PDF nie mogą używać własnych kolorów: Opcja „Pozwalaj stronom stosować inne kolory” w przeglądarce jest nieaktywna. diff --git a/static/pdf.js/locale/pt-BR/viewer.ftl b/static/pdf.js/locale/pt-BR/viewer.ftl deleted file mode 100644 index 153f0426..00000000 --- a/static/pdf.js/locale/pt-BR/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Página anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Próxima página -pdfjs-next-button-label = Próxima -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Página -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Reduzir -pdfjs-zoom-out-button-label = Reduzir -pdfjs-zoom-in-button = - .title = Ampliar -pdfjs-zoom-in-button-label = Ampliar -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Mudar para o modo de apresentação -pdfjs-presentation-mode-button-label = Modo de apresentação -pdfjs-open-file-button = - .title = Abrir arquivo -pdfjs-open-file-button-label = Abrir -pdfjs-print-button = - .title = Imprimir -pdfjs-print-button-label = Imprimir -pdfjs-save-button = - .title = Salvar -pdfjs-save-button-label = Salvar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Baixar -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Baixar -pdfjs-bookmark-button = - .title = Página atual (ver URL da página atual) -pdfjs-bookmark-button-label = Pagina atual - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Ferramentas -pdfjs-tools-button-label = Ferramentas -pdfjs-first-page-button = - .title = Ir para a primeira página -pdfjs-first-page-button-label = Ir para a primeira página -pdfjs-last-page-button = - .title = Ir para a última página -pdfjs-last-page-button-label = Ir para a última página -pdfjs-page-rotate-cw-button = - .title = Girar no sentido horário -pdfjs-page-rotate-cw-button-label = Girar no sentido horário -pdfjs-page-rotate-ccw-button = - .title = Girar no sentido anti-horário -pdfjs-page-rotate-ccw-button-label = Girar no sentido anti-horário -pdfjs-cursor-text-select-tool-button = - .title = Ativar a ferramenta de seleção de texto -pdfjs-cursor-text-select-tool-button-label = Ferramenta de seleção de texto -pdfjs-cursor-hand-tool-button = - .title = Ativar ferramenta de deslocamento -pdfjs-cursor-hand-tool-button-label = Ferramenta de deslocamento -pdfjs-scroll-page-button = - .title = Usar rolagem de página -pdfjs-scroll-page-button-label = Rolagem de página -pdfjs-scroll-vertical-button = - .title = Usar deslocamento vertical -pdfjs-scroll-vertical-button-label = Deslocamento vertical -pdfjs-scroll-horizontal-button = - .title = Usar deslocamento horizontal -pdfjs-scroll-horizontal-button-label = Deslocamento horizontal -pdfjs-scroll-wrapped-button = - .title = Usar deslocamento contido -pdfjs-scroll-wrapped-button-label = Deslocamento contido -pdfjs-spread-none-button = - .title = Não reagrupar páginas -pdfjs-spread-none-button-label = Não estender -pdfjs-spread-odd-button = - .title = Agrupar páginas começando em páginas com números ímpares -pdfjs-spread-odd-button-label = Estender ímpares -pdfjs-spread-even-button = - .title = Agrupar páginas começando em páginas com números pares -pdfjs-spread-even-button-label = Estender pares - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propriedades do documento… -pdfjs-document-properties-button-label = Propriedades do documento… -pdfjs-document-properties-file-name = Nome do arquivo: -pdfjs-document-properties-file-size = Tamanho do arquivo: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Título: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Assunto: -pdfjs-document-properties-keywords = Palavras-chave: -pdfjs-document-properties-creation-date = Data da criação: -pdfjs-document-properties-modification-date = Data da modificação: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Criação: -pdfjs-document-properties-producer = Criador do PDF: -pdfjs-document-properties-version = Versão do PDF: -pdfjs-document-properties-page-count = Número de páginas: -pdfjs-document-properties-page-size = Tamanho da página: -pdfjs-document-properties-page-size-unit-inches = pol. -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = retrato -pdfjs-document-properties-page-size-orientation-landscape = paisagem -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Jurídico - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Exibição web rápida: -pdfjs-document-properties-linearized-yes = Sim -pdfjs-document-properties-linearized-no = Não -pdfjs-document-properties-close-button = Fechar - -## Print - -pdfjs-print-progress-message = Preparando documento para impressão… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress } % -pdfjs-print-progress-close-button = Cancelar -pdfjs-printing-not-supported = Aviso: a impressão não é totalmente suportada neste navegador. -pdfjs-printing-not-ready = Aviso: o PDF não está totalmente carregado para impressão. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Exibir/ocultar painel lateral -pdfjs-toggle-sidebar-notification-button = - .title = Exibir/ocultar painel (documento contém estrutura/anexos/camadas) -pdfjs-toggle-sidebar-button-label = Exibir/ocultar painel -pdfjs-document-outline-button = - .title = Mostrar estrutura do documento (duplo-clique expande/recolhe todos os itens) -pdfjs-document-outline-button-label = Estrutura do documento -pdfjs-attachments-button = - .title = Mostrar anexos -pdfjs-attachments-button-label = Anexos -pdfjs-layers-button = - .title = Mostrar camadas (duplo-clique redefine todas as camadas ao estado predefinido) -pdfjs-layers-button-label = Camadas -pdfjs-thumbs-button = - .title = Mostrar miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Encontrar item atual da estrutura -pdfjs-current-outline-item-button-label = Item atual da estrutura -pdfjs-findbar-button = - .title = Procurar no documento -pdfjs-findbar-button-label = Procurar -pdfjs-additional-layers = Camadas adicionais - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Página { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura da página { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Procurar - .placeholder = Procurar no documento… -pdfjs-find-previous-button = - .title = Procurar a ocorrência anterior da frase -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button = - .title = Procurar a próxima ocorrência da frase -pdfjs-find-next-button-label = Próxima -pdfjs-find-highlight-checkbox = Destacar tudo -pdfjs-find-match-case-checkbox-label = Diferenciar maiúsculas/minúsculas -pdfjs-find-match-diacritics-checkbox-label = Considerar acentuação -pdfjs-find-entire-word-checkbox-label = Palavras completas -pdfjs-find-reached-top = Início do documento alcançado, continuando do fim -pdfjs-find-reached-bottom = Fim do documento alcançado, continuando do início -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } de { $total } ocorrência - *[other] { $current } de { $total } ocorrências - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Mais de { $limit } ocorrência - *[other] Mais de { $limit } ocorrências - } -pdfjs-find-not-found = Não encontrado - -## Predefined zoom values - -pdfjs-page-scale-width = Largura da página -pdfjs-page-scale-fit = Ajustar à janela -pdfjs-page-scale-auto = Zoom automático -pdfjs-page-scale-actual = Tamanho real -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Página { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ocorreu um erro ao carregar o PDF. -pdfjs-invalid-file-error = Arquivo PDF corrompido ou inválido. -pdfjs-missing-file-error = Arquivo PDF ausente. -pdfjs-unexpected-response-error = Resposta inesperada do servidor. -pdfjs-rendering-error = Ocorreu um erro ao renderizar a página. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotação { $type }] - -## Password - -pdfjs-password-label = Forneça a senha para abrir este arquivo PDF. -pdfjs-password-invalid = Senha inválida. Tente novamente. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Cancelar -pdfjs-web-fonts-disabled = As fontes web estão desativadas: não foi possível usar fontes incorporadas do PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texto -pdfjs-editor-free-text-button-label = Texto -pdfjs-editor-ink-button = - .title = Desenho -pdfjs-editor-ink-button-label = Desenho -pdfjs-editor-stamp-button = - .title = Adicionar ou editar imagens -pdfjs-editor-stamp-button-label = Adicionar ou editar imagens -pdfjs-editor-highlight-button = - .title = Destaque -pdfjs-editor-highlight-button-label = Destaque -pdfjs-highlight-floating-button = - .title = Destaque -pdfjs-highlight-floating-button1 = - .title = Destaque - .aria-label = Destaque -pdfjs-highlight-floating-button-label = Destaque - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Remover desenho -pdfjs-editor-remove-freetext-button = - .title = Remover texto -pdfjs-editor-remove-stamp-button = - .title = Remover imagem -pdfjs-editor-remove-highlight-button = - .title = Remover destaque - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Cor -pdfjs-editor-free-text-size-input = Tamanho -pdfjs-editor-ink-color-input = Cor -pdfjs-editor-ink-thickness-input = Espessura -pdfjs-editor-ink-opacity-input = Opacidade -pdfjs-editor-stamp-add-image-button = - .title = Adicionar imagem -pdfjs-editor-stamp-add-image-button-label = Adicionar imagem -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Espessura -pdfjs-editor-free-highlight-thickness-title = - .title = Mudar espessura ao destacar itens que não são texto -pdfjs-free-text = - .aria-label = Editor de texto -pdfjs-free-text-default-content = Comece digitando… -pdfjs-ink = - .aria-label = Editor de desenho -pdfjs-ink-canvas = - .aria-label = Imagem criada pelo usuário - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Texto alternativo -pdfjs-editor-alt-text-edit-button-label = Editar texto alternativo -pdfjs-editor-alt-text-dialog-label = Escolha uma opção -pdfjs-editor-alt-text-dialog-description = O texto alternativo ajuda quando uma imagem não aparece ou não é carregada. -pdfjs-editor-alt-text-add-description-label = Adicionar uma descrição -pdfjs-editor-alt-text-add-description-description = Procure usar uma ou duas frases que descrevam o assunto, cenário ou ação. -pdfjs-editor-alt-text-mark-decorative-label = Marcar como decorativa -pdfjs-editor-alt-text-mark-decorative-description = Isto é usado em imagens ornamentais, como bordas ou marcas d'água. -pdfjs-editor-alt-text-cancel-button = Cancelar -pdfjs-editor-alt-text-save-button = Salvar -pdfjs-editor-alt-text-decorative-tooltip = Marcado como decorativa -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Por exemplo, “Um jovem senta-se à mesa para comer uma refeição” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Canto superior esquerdo — redimensionar -pdfjs-editor-resizer-label-top-middle = No centro do topo — redimensionar -pdfjs-editor-resizer-label-top-right = Canto superior direito — redimensionar -pdfjs-editor-resizer-label-middle-right = No meio à direita — redimensionar -pdfjs-editor-resizer-label-bottom-right = Canto inferior direito — redimensionar -pdfjs-editor-resizer-label-bottom-middle = No centro da base — redimensionar -pdfjs-editor-resizer-label-bottom-left = Canto inferior esquerdo — redimensionar -pdfjs-editor-resizer-label-middle-left = No meio à esquerda — redimensionar - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Cor de destaque -pdfjs-editor-colorpicker-button = - .title = Mudar cor -pdfjs-editor-colorpicker-dropdown = - .aria-label = Opções de cores -pdfjs-editor-colorpicker-yellow = - .title = Amarelo -pdfjs-editor-colorpicker-green = - .title = Verde -pdfjs-editor-colorpicker-blue = - .title = Azul -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Vermelho - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Mostrar todos -pdfjs-editor-highlight-show-all-button = - .title = Mostrar todos diff --git a/static/pdf.js/locale/pt-BR/viewer.properties b/static/pdf.js/locale/pt-BR/viewer.properties new file mode 100644 index 00000000..cdfd8f0c --- /dev/null +++ b/static/pdf.js/locale/pt-BR/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Página anterior +previous_label=Anterior +next.title=Próxima página +next_label=Próxima + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Página: +page_of=de {{pageCount}} + +zoom_out.title=Diminuir zoom +zoom_out_label=Diminuir zoom +zoom_in.title=Aumentar zoom +zoom_in_label=Aumentar zoom +zoom.title=Zoom +presentation_mode.title=Alternar para modo de apresentação +presentation_mode_label=Modo de apresentação +open_file.title=Abrir arquivo +open_file_label=Abrir +print.title=Imprimir +print_label=Imprimir +download.title=Download +download_label=Download +bookmark.title=Visualização atual (copie ou abra em uma nova janela) +bookmark_label=Visualização atual + +# Secondary toolbar and context menu +tools.title=Ferramentas +tools_label=Ferramentas +first_page.title=Ir para a primeira página +first_page.label=Ir para a primeira página +first_page_label=Ir para a primeira página +last_page.title=Ir para a última página +last_page.label=Ir para a última página +last_page_label=Ir para a última página +page_rotate_cw.title=Girar no sentido horário +page_rotate_cw.label=Girar no sentido horário +page_rotate_cw_label=Girar no sentido horário +page_rotate_ccw.title=Girar no sentido anti-horário +page_rotate_ccw.label=Girar no sentido anti-horário +page_rotate_ccw_label=Girar no sentido anti-horário + +hand_tool_enable.title=Ativar ferramenta da mão +hand_tool_enable_label=Ativar ferramenta da mão +hand_tool_disable.title=Desativar ferramenta da mão +hand_tool_disable_label=Desativar ferramenta da mão + +# Document properties dialog box +document_properties.title=Propriedades do documento… +document_properties_label=Propriedades do documento… +document_properties_file_name=Nome do arquivo: +document_properties_file_size=Tamanho do arquivo: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Título: +document_properties_author=Autor: +document_properties_subject=Assunto: +document_properties_keywords=Palavras-chave: +document_properties_creation_date=Data da criação: +document_properties_modification_date=Data da modificação: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Criação: +document_properties_producer=Criador do PDF: +document_properties_version=Versão do PDF: +document_properties_page_count=Número de páginas: +document_properties_close=Fechar + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Exibir/ocultar painel +toggle_sidebar_label=Exibir/ocultar painel +outline.title=Exibir estrutura de tópicos +outline_label=Estrutura de tópicos do documento +attachments.title=Exibir anexos +attachments_label=Anexos +thumbs.title=Exibir miniaturas das páginas +thumbs_label=Miniaturas +findbar.title=Localizar no documento +findbar_label=Localizar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Página {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura da página {{page}} + +# Find panel button title and messages +find_label=Localizar: +find_previous.title=Localizar a ocorrência anterior do texto +find_previous_label=Anterior +find_next.title=Localizar a próxima ocorrência do texto +find_next_label=Próxima +find_highlight=Realçar tudo +find_match_case_label=Diferenciar maiúsculas/minúsculas +find_reached_top=Atingido o início do documento, continuando do fim +find_reached_bottom=Atingido o fim do documento, continuando do início +find_not_found=Texto não encontrado + +# Error panel labels +error_more_info=Mais informações +error_less_info=Menos informações +error_close=Fechar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mensagem: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Arquivo: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linha: {{line}} +rendering_error=Ocorreu um erro ao renderizar a página. + +# Predefined zoom values +page_scale_width=Largura da página +page_scale_fit=Ajustar à janela +page_scale_auto=Zoom automático +page_scale_actual=Tamanho real +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Erro +loading_error=Ocorreu um erro ao carregar o PDF. +invalid_file_error=Arquivo PDF corrompido ou inválido. +missing_file_error=Arquivo PDF ausente. +unexpected_response_error=Resposta inesperada do servidor. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotação {{type}}] +password_label=Forneça a senha para abrir este arquivo PDF. +password_invalid=Senha inválida. Por favor, tente de novo. +password_ok=OK +password_cancel=Cancelar + +printing_not_supported=Alerta: a impressão não é totalmente suportada neste navegador. +printing_not_ready=Alerta: o PDF não está totalmente carregado para impressão. +web_fonts_disabled=Fontes da web estão desativadas: não é possível usar fontes incorporadas do PDF. +document_colors_not_allowed=Documentos PDF não estão autorizados a usar suas próprias cores: “Páginas podem usar outras cores” está desativado no navegador. diff --git a/static/pdf.js/locale/pt-PT/viewer.ftl b/static/pdf.js/locale/pt-PT/viewer.ftl deleted file mode 100644 index 7fd8d378..00000000 --- a/static/pdf.js/locale/pt-PT/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Página anterior -pdfjs-previous-button-label = Anterior -pdfjs-next-button = - .title = Página seguinte -pdfjs-next-button-label = Seguinte -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Página -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Reduzir -pdfjs-zoom-out-button-label = Reduzir -pdfjs-zoom-in-button = - .title = Ampliar -pdfjs-zoom-in-button-label = Ampliar -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Trocar para o modo de apresentação -pdfjs-presentation-mode-button-label = Modo de apresentação -pdfjs-open-file-button = - .title = Abrir ficheiro -pdfjs-open-file-button-label = Abrir -pdfjs-print-button = - .title = Imprimir -pdfjs-print-button-label = Imprimir -pdfjs-save-button = - .title = Guardar -pdfjs-save-button-label = Guardar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Transferir -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Transferir -pdfjs-bookmark-button = - .title = Página atual (ver URL da página atual) -pdfjs-bookmark-button-label = Pagina atual -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Abrir na aplicação -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Abrir na aplicação - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Ferramentas -pdfjs-tools-button-label = Ferramentas -pdfjs-first-page-button = - .title = Ir para a primeira página -pdfjs-first-page-button-label = Ir para a primeira página -pdfjs-last-page-button = - .title = Ir para a última página -pdfjs-last-page-button-label = Ir para a última página -pdfjs-page-rotate-cw-button = - .title = Rodar à direita -pdfjs-page-rotate-cw-button-label = Rodar à direita -pdfjs-page-rotate-ccw-button = - .title = Rodar à esquerda -pdfjs-page-rotate-ccw-button-label = Rodar à esquerda -pdfjs-cursor-text-select-tool-button = - .title = Ativar ferramenta de seleção de texto -pdfjs-cursor-text-select-tool-button-label = Ferramenta de seleção de texto -pdfjs-cursor-hand-tool-button = - .title = Ativar ferramenta de mão -pdfjs-cursor-hand-tool-button-label = Ferramenta de mão -pdfjs-scroll-page-button = - .title = Utilizar deslocamento da página -pdfjs-scroll-page-button-label = Deslocamento da página -pdfjs-scroll-vertical-button = - .title = Utilizar deslocação vertical -pdfjs-scroll-vertical-button-label = Deslocação vertical -pdfjs-scroll-horizontal-button = - .title = Utilizar deslocação horizontal -pdfjs-scroll-horizontal-button-label = Deslocação horizontal -pdfjs-scroll-wrapped-button = - .title = Utilizar deslocação encapsulada -pdfjs-scroll-wrapped-button-label = Deslocação encapsulada -pdfjs-spread-none-button = - .title = Não juntar páginas dispersas -pdfjs-spread-none-button-label = Sem spreads -pdfjs-spread-odd-button = - .title = Juntar páginas dispersas a partir de páginas com números ímpares -pdfjs-spread-odd-button-label = Spreads ímpares -pdfjs-spread-even-button = - .title = Juntar páginas dispersas a partir de páginas com números pares -pdfjs-spread-even-button-label = Spreads pares - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propriedades do documento… -pdfjs-document-properties-button-label = Propriedades do documento… -pdfjs-document-properties-file-name = Nome do ficheiro: -pdfjs-document-properties-file-size = Tamanho do ficheiro: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Título: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Assunto: -pdfjs-document-properties-keywords = Palavras-chave: -pdfjs-document-properties-creation-date = Data de criação: -pdfjs-document-properties-modification-date = Data de modificação: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Criador: -pdfjs-document-properties-producer = Produtor de PDF: -pdfjs-document-properties-version = Versão do PDF: -pdfjs-document-properties-page-count = N.º de páginas: -pdfjs-document-properties-page-size = Tamanho da página: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = retrato -pdfjs-document-properties-page-size-orientation-landscape = paisagem -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Carta -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista rápida web: -pdfjs-document-properties-linearized-yes = Sim -pdfjs-document-properties-linearized-no = Não -pdfjs-document-properties-close-button = Fechar - -## Print - -pdfjs-print-progress-message = A preparar o documento para impressão… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cancelar -pdfjs-printing-not-supported = Aviso: a impressão não é totalmente suportada por este navegador. -pdfjs-printing-not-ready = Aviso: o PDF ainda não está totalmente carregado. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Alternar barra lateral -pdfjs-toggle-sidebar-notification-button = - .title = Alternar barra lateral (o documento contém contornos/anexos/camadas) -pdfjs-toggle-sidebar-button-label = Alternar barra lateral -pdfjs-document-outline-button = - .title = Mostrar esquema do documento (duplo clique para expandir/colapsar todos os itens) -pdfjs-document-outline-button-label = Esquema do documento -pdfjs-attachments-button = - .title = Mostrar anexos -pdfjs-attachments-button-label = Anexos -pdfjs-layers-button = - .title = Mostrar camadas (clique duas vezes para repor todas as camadas para o estado predefinido) -pdfjs-layers-button-label = Camadas -pdfjs-thumbs-button = - .title = Mostrar miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Encontrar o item atualmente destacado -pdfjs-current-outline-item-button-label = Item atualmente destacado -pdfjs-findbar-button = - .title = Localizar em documento -pdfjs-findbar-button-label = Localizar -pdfjs-additional-layers = Camadas adicionais - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Página { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura da página { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Localizar - .placeholder = Localizar em documento… -pdfjs-find-previous-button = - .title = Localizar ocorrência anterior da frase -pdfjs-find-previous-button-label = Anterior -pdfjs-find-next-button = - .title = Localizar ocorrência seguinte da frase -pdfjs-find-next-button-label = Seguinte -pdfjs-find-highlight-checkbox = Destacar tudo -pdfjs-find-match-case-checkbox-label = Correspondência -pdfjs-find-match-diacritics-checkbox-label = Corresponder diacríticos -pdfjs-find-entire-word-checkbox-label = Palavras completas -pdfjs-find-reached-top = Topo do documento atingido, a continuar a partir do fundo -pdfjs-find-reached-bottom = Fim do documento atingido, a continuar a partir do topo -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } de { $total } correspondência - *[other] { $current } de { $total } correspondências - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Mais de { $limit } correspondência - *[other] Mais de { $limit } correspondências - } -pdfjs-find-not-found = Frase não encontrada - -## Predefined zoom values - -pdfjs-page-scale-width = Ajustar à largura -pdfjs-page-scale-fit = Ajustar à página -pdfjs-page-scale-auto = Zoom automático -pdfjs-page-scale-actual = Tamanho real -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Página { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ocorreu um erro ao carregar o PDF. -pdfjs-invalid-file-error = Ficheiro PDF inválido ou danificado. -pdfjs-missing-file-error = Ficheiro PDF inexistente. -pdfjs-unexpected-response-error = Resposta inesperada do servidor. -pdfjs-rendering-error = Ocorreu um erro ao processar a página. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotação { $type }] - -## Password - -pdfjs-password-label = Introduza a palavra-passe para abrir este ficheiro PDF. -pdfjs-password-invalid = Palavra-passe inválida. Por favor, tente novamente. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Cancelar -pdfjs-web-fonts-disabled = Os tipos de letra web estão desativados: não é possível utilizar os tipos de letra PDF embutidos. - -## Editing - -pdfjs-editor-free-text-button = - .title = Texto -pdfjs-editor-free-text-button-label = Texto -pdfjs-editor-ink-button = - .title = Desenhar -pdfjs-editor-ink-button-label = Desenhar -pdfjs-editor-stamp-button = - .title = Adicionar ou editar imagens -pdfjs-editor-stamp-button-label = Adicionar ou editar imagens -pdfjs-editor-highlight-button = - .title = Destaque -pdfjs-editor-highlight-button-label = Destaque -pdfjs-highlight-floating-button = - .title = Destaque -pdfjs-highlight-floating-button1 = - .title = Realçar - .aria-label = Realçar -pdfjs-highlight-floating-button-label = Realçar - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Remover desenho -pdfjs-editor-remove-freetext-button = - .title = Remover texto -pdfjs-editor-remove-stamp-button = - .title = Remover imagem -pdfjs-editor-remove-highlight-button = - .title = Remover destaque - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Cor -pdfjs-editor-free-text-size-input = Tamanho -pdfjs-editor-ink-color-input = Cor -pdfjs-editor-ink-thickness-input = Espessura -pdfjs-editor-ink-opacity-input = Opacidade -pdfjs-editor-stamp-add-image-button = - .title = Adicionar imagem -pdfjs-editor-stamp-add-image-button-label = Adicionar imagem -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Espessura -pdfjs-editor-free-highlight-thickness-title = - .title = Alterar espessura quando destacar itens que não sejam texto -pdfjs-free-text = - .aria-label = Editor de texto -pdfjs-free-text-default-content = Começar a digitar… -pdfjs-ink = - .aria-label = Editor de desenho -pdfjs-ink-canvas = - .aria-label = Imagem criada pelo utilizador - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Texto alternativo -pdfjs-editor-alt-text-edit-button-label = Editar texto alternativo -pdfjs-editor-alt-text-dialog-label = Escolher uma opção -pdfjs-editor-alt-text-dialog-description = O texto alternativo (texto alternativo) ajuda quando as pessoas não conseguem ver a imagem ou quando a mesma não é carregada. -pdfjs-editor-alt-text-add-description-label = Adicionar uma descrição -pdfjs-editor-alt-text-add-description-description = Aponte para 1-2 frases que descrevam o assunto, definição ou ações. -pdfjs-editor-alt-text-mark-decorative-label = Marcar como decorativa -pdfjs-editor-alt-text-mark-decorative-description = Isto é utilizado para imagens decorativas, tais como limites ou marcas d'água. -pdfjs-editor-alt-text-cancel-button = Cancelar -pdfjs-editor-alt-text-save-button = Guardar -pdfjs-editor-alt-text-decorative-tooltip = Marcada como decorativa -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Por exemplo, “Um jovem senta-se à mesa para comer uma refeição” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Canto superior esquerdo — redimensionar -pdfjs-editor-resizer-label-top-middle = Superior ao centro — redimensionar -pdfjs-editor-resizer-label-top-right = Canto superior direito — redimensionar -pdfjs-editor-resizer-label-middle-right = Centro à direita — redimensionar -pdfjs-editor-resizer-label-bottom-right = Canto inferior direito — redimensionar -pdfjs-editor-resizer-label-bottom-middle = Inferior ao centro — redimensionar -pdfjs-editor-resizer-label-bottom-left = Canto inferior esquerdo — redimensionar -pdfjs-editor-resizer-label-middle-left = Centro à esquerda — redimensionar - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Cor de destaque -pdfjs-editor-colorpicker-button = - .title = Alterar cor -pdfjs-editor-colorpicker-dropdown = - .aria-label = Escolhas de cor -pdfjs-editor-colorpicker-yellow = - .title = Amarelo -pdfjs-editor-colorpicker-green = - .title = Verde -pdfjs-editor-colorpicker-blue = - .title = Azul -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Vermelho - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Mostrar tudo -pdfjs-editor-highlight-show-all-button = - .title = Mostrar tudo diff --git a/static/pdf.js/locale/pt-PT/viewer.properties b/static/pdf.js/locale/pt-PT/viewer.properties new file mode 100644 index 00000000..71409520 --- /dev/null +++ b/static/pdf.js/locale/pt-PT/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Página anterior +previous_label=Anterior +next.title=Página seguinte +next_label=Seguinte + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Página: +page_of=de {{pageCount}} + +zoom_out.title=Reduzir +zoom_out_label=Reduzir +zoom_in.title=Ampliar +zoom_in_label=Ampliar +zoom.title=Ampliação +presentation_mode.title=Mudar para modo de apresentação +presentation_mode_label=Modo de apresentação +open_file.title=Abrir ficheiro +open_file_label=Abrir +print.title=Imprimir +print_label=Imprimir +download.title=Descarregar +download_label=Descarregar +bookmark.title=Visão atual (copiar ou abrir em nova janela) +bookmark_label=Visão atual + +# Secondary toolbar and context menu +tools.title=Ferramentas +tools_label=Ferramentas +first_page.title=Ir para a primeira página +first_page.label=Ir para a primeira página +first_page_label=Ir para a primeira página +last_page.title=Ir para a última página +last_page.label=Ir para a última página +last_page_label=Ir para a última página +page_rotate_cw.title=Rodar à direita +page_rotate_cw.label=Rodar à direita +page_rotate_cw_label=Rodar à direita +page_rotate_ccw.title=Rodar à esquerda +page_rotate_ccw.label=Rodar à esquerda +page_rotate_ccw_label=Rodar à esquerda + +hand_tool_enable.title=Ativar ferramenta de mão +hand_tool_enable_label=Ativar ferramenta de mão +hand_tool_disable.title=Desativar ferramenta de mão +hand_tool_disable_label=Desativar ferramenta de mão + +# Document properties dialog box +document_properties.title=Propriedades do documento… +document_properties_label=Propriedades do documento… +document_properties_file_name=Nome do ficheiro: +document_properties_file_size=Tamanho do ficheiro: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Título: +document_properties_author=Autor: +document_properties_subject=Assunto: +document_properties_keywords=Palavras-chave: +document_properties_creation_date=Data de criação: +document_properties_modification_date=Data de modificação: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Criador: +document_properties_producer=Produtor de PDF: +document_properties_version=Versão do PDF: +document_properties_page_count=N.º de páginas: +document_properties_close=Fechar + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Comutar barra lateral +toggle_sidebar_label=Comutar barra lateral +outline.title=Mostrar estrutura do documento +outline_label=Estrutura do documento +attachments.title=Mostrar anexos +attachments_label=Anexos +thumbs.title=Mostrar miniaturas +thumbs_label=Miniaturas +findbar.title=Localizar no documento +findbar_label=Localizar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Página {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura da página {{page}} + +# Find panel button title and messages +find_label=Localizar: +find_previous.title=Localizar ocorrência anterior da frase +find_previous_label=Anterior +find_next.title=Localizar ocorrência seguinte da frase +find_next_label=Seguinte +find_highlight=Destacar tudo +find_match_case_label=Correspondência +find_reached_top=Início de documento atingido, a continuar do fim +find_reached_bottom=Fim da página atingido, a continuar do início +find_not_found=Frase não encontrada + +# Error panel labels +error_more_info=Mais informação +error_less_info=Menos informação +error_close=Fechar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (compilação: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mensagem: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Pilha: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Ficheiro: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linha: {{line}} +rendering_error=Ocorreu um erro ao processar a página. + +# Predefined zoom values +page_scale_width=Ajustar à largura +page_scale_fit=Ajustar à página +page_scale_auto=Tamanho automático +page_scale_actual=Tamanho real +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Erro +loading_error=Ocorreu um erro ao carregar o PDF. +invalid_file_error=Ficheiro PDF inválido ou danificado. +missing_file_error=Ficheiro PDF inexistente. +unexpected_response_error=Resposta inesperada do servidor. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotação {{type}}] +password_label=Digite a palavra-passe para abrir este PDF. +password_invalid=Palavra-passe inválida. Por favor, tente novamente. +password_ok=OK +password_cancel=Cancelar + +printing_not_supported=Aviso: a impressão não é totalmente suportada por este navegador. +printing_not_ready=Aviso: o PDF ainda não está totalmente carregado. +web_fonts_disabled=Os tipos de letra web estão desativados: não é possível utilizar os tipos de letra PDF incorporados. +document_colors_not_allowed=Os documentos PDF não permitem a utilização das suas próprias cores: 'Autorizar as páginas a escolher as suas próprias cores' está desativada no navegador. diff --git a/static/pdf.js/locale/rm/viewer.ftl b/static/pdf.js/locale/rm/viewer.ftl deleted file mode 100644 index e428e133..00000000 --- a/static/pdf.js/locale/rm/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pagina precedenta -pdfjs-previous-button-label = Enavos -pdfjs-next-button = - .title = Proxima pagina -pdfjs-next-button-label = Enavant -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pagina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = da { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } da { $pagesCount }) -pdfjs-zoom-out-button = - .title = Empitschnir -pdfjs-zoom-out-button-label = Empitschnir -pdfjs-zoom-in-button = - .title = Engrondir -pdfjs-zoom-in-button-label = Engrondir -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Midar en il modus da preschentaziun -pdfjs-presentation-mode-button-label = Modus da preschentaziun -pdfjs-open-file-button = - .title = Avrir datoteca -pdfjs-open-file-button-label = Avrir -pdfjs-print-button = - .title = Stampar -pdfjs-print-button-label = Stampar -pdfjs-save-button = - .title = Memorisar -pdfjs-save-button-label = Memorisar -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Telechargiar -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Telechargiar -pdfjs-bookmark-button = - .title = Pagina actuala (mussar l'URL da la pagina actuala) -pdfjs-bookmark-button-label = Pagina actuala - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Utensils -pdfjs-tools-button-label = Utensils -pdfjs-first-page-button = - .title = Siglir a l'emprima pagina -pdfjs-first-page-button-label = Siglir a l'emprima pagina -pdfjs-last-page-button = - .title = Siglir a la davosa pagina -pdfjs-last-page-button-label = Siglir a la davosa pagina -pdfjs-page-rotate-cw-button = - .title = Rotar en direcziun da l'ura -pdfjs-page-rotate-cw-button-label = Rotar en direcziun da l'ura -pdfjs-page-rotate-ccw-button = - .title = Rotar en direcziun cuntraria a l'ura -pdfjs-page-rotate-ccw-button-label = Rotar en direcziun cuntraria a l'ura -pdfjs-cursor-text-select-tool-button = - .title = Activar l'utensil per selecziunar text -pdfjs-cursor-text-select-tool-button-label = Utensil per selecziunar text -pdfjs-cursor-hand-tool-button = - .title = Activar l'utensil da maun -pdfjs-cursor-hand-tool-button-label = Utensil da maun -pdfjs-scroll-page-button = - .title = Utilisar la defilada per pagina -pdfjs-scroll-page-button-label = Defilada per pagina -pdfjs-scroll-vertical-button = - .title = Utilisar il defilar vertical -pdfjs-scroll-vertical-button-label = Defilar vertical -pdfjs-scroll-horizontal-button = - .title = Utilisar il defilar orizontal -pdfjs-scroll-horizontal-button-label = Defilar orizontal -pdfjs-scroll-wrapped-button = - .title = Utilisar il defilar en colonnas -pdfjs-scroll-wrapped-button-label = Defilar en colonnas -pdfjs-spread-none-button = - .title = Betg parallelisar las paginas -pdfjs-spread-none-button-label = Betg parallel -pdfjs-spread-odd-button = - .title = Parallelisar las paginas cun cumenzar cun paginas spèras -pdfjs-spread-odd-button-label = Parallel spèr -pdfjs-spread-even-button = - .title = Parallelisar las paginas cun cumenzar cun paginas pèras -pdfjs-spread-even-button-label = Parallel pèr - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Caracteristicas dal document… -pdfjs-document-properties-button-label = Caracteristicas dal document… -pdfjs-document-properties-file-name = Num da la datoteca: -pdfjs-document-properties-file-size = Grondezza da la datoteca: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Titel: -pdfjs-document-properties-author = Autur: -pdfjs-document-properties-subject = Tema: -pdfjs-document-properties-keywords = Chavazzins: -pdfjs-document-properties-creation-date = Data da creaziun: -pdfjs-document-properties-modification-date = Data da modificaziun: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date } { $time } -pdfjs-document-properties-creator = Creà da: -pdfjs-document-properties-producer = Creà il PDF cun: -pdfjs-document-properties-version = Versiun da PDF: -pdfjs-document-properties-page-count = Dumber da paginas: -pdfjs-document-properties-page-size = Grondezza da la pagina: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = vertical -pdfjs-document-properties-page-size-orientation-landscape = orizontal -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Gea -pdfjs-document-properties-linearized-no = Na -pdfjs-document-properties-close-button = Serrar - -## Print - -pdfjs-print-progress-message = Preparar il document per stampar… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Interrumper -pdfjs-printing-not-supported = Attenziun: Il stampar na funcziunescha anc betg dal tut en quest navigatur. -pdfjs-printing-not-ready = Attenziun: Il PDF n'è betg chargià cumplettamain per stampar. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Activar/deactivar la trav laterala -pdfjs-toggle-sidebar-notification-button = - .title = Activar/deactivar la trav laterala (il document cuntegna structura dal document/agiuntas/nivels) -pdfjs-toggle-sidebar-button-label = Activar/deactivar la trav laterala -pdfjs-document-outline-button = - .title = Mussar la structura dal document (cliccar duas giadas per extender/cumprimer tut ils elements) -pdfjs-document-outline-button-label = Structura dal document -pdfjs-attachments-button = - .title = Mussar agiuntas -pdfjs-attachments-button-label = Agiuntas -pdfjs-layers-button = - .title = Mussar ils nivels (cliccar dubel per restaurar il stadi da standard da tut ils nivels) -pdfjs-layers-button-label = Nivels -pdfjs-thumbs-button = - .title = Mussar las miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Tschertgar l'element da structura actual -pdfjs-current-outline-item-button-label = Element da structura actual -pdfjs-findbar-button = - .title = Tschertgar en il document -pdfjs-findbar-button-label = Tschertgar -pdfjs-additional-layers = Nivels supplementars - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pagina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura da la pagina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Tschertgar - .placeholder = Tschertgar en il document… -pdfjs-find-previous-button = - .title = Tschertgar la posiziun precedenta da l'expressiun -pdfjs-find-previous-button-label = Enavos -pdfjs-find-next-button = - .title = Tschertgar la proxima posiziun da l'expressiun -pdfjs-find-next-button-label = Enavant -pdfjs-find-highlight-checkbox = Relevar tuts -pdfjs-find-match-case-checkbox-label = Resguardar maiusclas/minusclas -pdfjs-find-match-diacritics-checkbox-label = Resguardar ils segns diacritics -pdfjs-find-entire-word-checkbox-label = Pleds entirs -pdfjs-find-reached-top = Il cumenzament dal document è cuntanschì, la tschertga cuntinuescha a la fin dal document -pdfjs-find-reached-bottom = La fin dal document è cuntanschì, la tschertga cuntinuescha al cumenzament dal document -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } dad { $total } correspundenza - *[other] { $current } da { $total } correspundenzas - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Dapli che { $limit } correspundenza - *[other] Dapli che { $limit } correspundenzas - } -pdfjs-find-not-found = Impussibel da chattar l'expressiun - -## Predefined zoom values - -pdfjs-page-scale-width = Ladezza da la pagina -pdfjs-page-scale-fit = Entira pagina -pdfjs-page-scale-auto = Zoom automatic -pdfjs-page-scale-actual = Grondezza actuala -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pagina { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ina errur è cumparida cun chargiar il PDF. -pdfjs-invalid-file-error = Datoteca PDF nunvalida u donnegiada. -pdfjs-missing-file-error = Datoteca PDF manconta. -pdfjs-unexpected-response-error = Resposta nunspetgada dal server. -pdfjs-rendering-error = Ina errur è cumparida cun visualisar questa pagina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Annotaziun da { $type }] - -## Password - -pdfjs-password-label = Endatescha il pled-clav per avrir questa datoteca da PDF. -pdfjs-password-invalid = Pled-clav nunvalid. Emprova anc ina giada. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Interrumper -pdfjs-web-fonts-disabled = Scrittiras dal web èn deactivadas: impussibel dad utilisar las scrittiras integradas en il PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Dissegnar -pdfjs-editor-ink-button-label = Dissegnar -pdfjs-editor-stamp-button = - .title = Agiuntar u modifitgar maletgs -pdfjs-editor-stamp-button-label = Agiuntar u modifitgar maletgs -pdfjs-editor-highlight-button = - .title = Marcar -pdfjs-editor-highlight-button-label = Marcar -pdfjs-highlight-floating-button = - .title = Relevar -pdfjs-highlight-floating-button1 = - .title = Marcar - .aria-label = Marcar -pdfjs-highlight-floating-button-label = Marcar - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Allontanar il dissegn -pdfjs-editor-remove-freetext-button = - .title = Allontanar il text -pdfjs-editor-remove-stamp-button = - .title = Allontanar la grafica -pdfjs-editor-remove-highlight-button = - .title = Allontanar l'emfasa - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Colur -pdfjs-editor-free-text-size-input = Grondezza -pdfjs-editor-ink-color-input = Colur -pdfjs-editor-ink-thickness-input = Grossezza -pdfjs-editor-ink-opacity-input = Opacitad -pdfjs-editor-stamp-add-image-button = - .title = Agiuntar in maletg -pdfjs-editor-stamp-add-image-button-label = Agiuntar in maletg -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Grossezza -pdfjs-editor-free-highlight-thickness-title = - .title = Midar la grossezza cun relevar elements betg textuals -pdfjs-free-text = - .aria-label = Editur da text -pdfjs-free-text-default-content = Cumenzar a tippar… -pdfjs-ink = - .aria-label = Editur dissegn -pdfjs-ink-canvas = - .aria-label = Maletg creà da l'utilisader - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Text alternativ -pdfjs-editor-alt-text-edit-button-label = Modifitgar il text alternativ -pdfjs-editor-alt-text-dialog-label = Tscherner ina opziun -pdfjs-editor-alt-text-dialog-description = Il text alternativ (alt text) gida en cas che persunas na vesan betg il maletg u sch'i na reussescha betg d'al chargiar. -pdfjs-editor-alt-text-add-description-label = Agiuntar ina descripziun -pdfjs-editor-alt-text-add-description-description = Scriva idealmain 1-2 frasas che descrivan l'object, la situaziun u las acziuns. -pdfjs-editor-alt-text-mark-decorative-label = Marcar sco decorativ -pdfjs-editor-alt-text-mark-decorative-description = Quai vegn duvrà per maletgs ornamentals, sco urs u filigranas. -pdfjs-editor-alt-text-cancel-button = Interrumper -pdfjs-editor-alt-text-save-button = Memorisar -pdfjs-editor-alt-text-decorative-tooltip = Marcà sco decorativ -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Per exempel: «In um giuven sesa a maisa per mangiar in past» - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Chantun sura a sanestra — redimensiunar -pdfjs-editor-resizer-label-top-middle = Sura amez — redimensiunar -pdfjs-editor-resizer-label-top-right = Chantun sura a dretga — redimensiunar -pdfjs-editor-resizer-label-middle-right = Da vart dretga amez — redimensiunar -pdfjs-editor-resizer-label-bottom-right = Chantun sut a dretga — redimensiunar -pdfjs-editor-resizer-label-bottom-middle = Sutvart amez — redimensiunar -pdfjs-editor-resizer-label-bottom-left = Chantun sut a sanestra — redimensiunar -pdfjs-editor-resizer-label-middle-left = Vart sanestra amez — redimensiunar - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Colur per l'emfasa -pdfjs-editor-colorpicker-button = - .title = Midar la colur -pdfjs-editor-colorpicker-dropdown = - .aria-label = Colurs disponiblas -pdfjs-editor-colorpicker-yellow = - .title = Mellen -pdfjs-editor-colorpicker-green = - .title = Verd -pdfjs-editor-colorpicker-blue = - .title = Blau -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Cotschen - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Mussar tut -pdfjs-editor-highlight-show-all-button = - .title = Mussar tut diff --git a/static/pdf.js/locale/rm/viewer.properties b/static/pdf.js/locale/rm/viewer.properties new file mode 100644 index 00000000..419aea39 --- /dev/null +++ b/static/pdf.js/locale/rm/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Pagina precedenta +previous_label=Enavos +next.title=Proxima pagina +next_label=Enavant + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pagina: +page_of=da {{pageCount}} + +zoom_out.title=Empitschnir +zoom_out_label=Empitschnir +zoom_in.title=Engrondir +zoom_in_label=Engrondir +zoom.title=Zoom +presentation_mode.title=Midar en il modus da preschentaziun +presentation_mode_label=Modus da preschentaziun +open_file.title=Avrir datoteca +open_file_label=Avrir +print.title=Stampar +print_label=Stampar +download.title=Telechargiar +download_label=Telechargiar +bookmark.title=Vista actuala (copiar u avrir en ina nova fanestra) +bookmark_label=Vista actuala + +# Secondary toolbar and context menu +tools.title=Utensils +tools_label=Utensils +first_page.title=Siglir a l'emprima pagina +first_page.label=Siglir a l'emprima pagina +first_page_label=Siglir a l'emprima pagina +last_page.title=Siglir a la davosa pagina +last_page.label=Siglir a la davosa pagina +last_page_label=Siglir a la davosa pagina +page_rotate_cw.title=Rotar en direcziun da l'ura +page_rotate_cw.label=Rotar en direcziun da l'ura +page_rotate_cw_label=Rotar en direcziun da l'ura +page_rotate_ccw.title=Rotar en direcziun cuntraria a l'ura +page_rotate_ccw.label=Rotar en direcziun cuntraria a l'ura +page_rotate_ccw_label=Rotar en direcziun cuntraria a l'ura + +hand_tool_enable.title=Activar l'utensil da maun +hand_tool_enable_label=Activar l'utensil da maun +hand_tool_disable.title=Deactivar l'utensil da maun +hand_tool_disable_label=Deactivar l'utensil da maun + +# Document properties dialog box +document_properties.title=Caracteristicas dal document… +document_properties_label=Caracteristicas dal document… +document_properties_file_name=Num da la datoteca: +document_properties_file_size=Grondezza da la datoteca: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=Titel: +document_properties_author=Autur: +document_properties_subject=Tema: +document_properties_keywords=Chavazzins: +document_properties_creation_date=Data da creaziun: +document_properties_modification_date=Data da modificaziun: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}} {{time}} +document_properties_creator=Creà da: +document_properties_producer=Creà il PDF cun: +document_properties_version=Versiun da PDF: +document_properties_page_count=Dumber da paginas: +document_properties_close=Serrar + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Activar/deactivar la trav laterala +toggle_sidebar_label=Activar/deactivar la trav laterala +outline.title=Mussar la structura da la pagina +outline_label=Structura da la pagina +attachments.title=Mussar agiuntas +attachments_label=Agiuntas +thumbs.title=Mussar las miniaturas +thumbs_label=Miniaturas +findbar.title=Tschertgar en il document +findbar_label=Tschertgar + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pagina {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura da la pagina {{page}} + +# Find panel button title and messages +find_label=Tschertgar: +find_previous.title=Tschertgar la posiziun precedenta da l'expressiun +find_previous_label=Enavos +find_next.title=Tschertgar la proxima posiziun da l'expressiun +find_next_label=Enavant +find_highlight=Relevar tuts +find_match_case_label=Resguardar maiusclas/minusclas +find_reached_top=Il cumenzament dal document è cuntanschì, la tschertga cuntinuescha a la fin dal document +find_reached_bottom=La fin dal document è cuntanschì, la tschertga cuntinuescha al cumenzament dal document +find_not_found=Impussibel da chattar l'expressiun + +# Error panel labels +error_more_info=Dapli infurmaziuns +error_less_info=Damain infurmaziuns +error_close=Serrar +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Messadi: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Datoteca: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Lingia: {{line}} +rendering_error=Ina errur è cumparida cun visualisar questa pagina. + +# Predefined zoom values +page_scale_width=Ladezza da la pagina +page_scale_fit=Entira pagina +page_scale_auto=Zoom automatic +page_scale_actual=Grondezza actuala +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Errur +loading_error=Ina errur è cumparida cun chargiar il PDF. +invalid_file_error=Datoteca PDF nunvalida u donnegiada. +missing_file_error=Datoteca PDF manconta. +unexpected_response_error=Resposta nunspetgada dal server. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Annotaziun da {{type}}] +password_label=Endatescha il pled-clav per avrir questa datoteca da PDF. +password_invalid=Pled-clav nunvalid. Emprova anc ina giada. +password_ok=OK +password_cancel=Interrumper + +printing_not_supported=Attenziun: Il stampar na funcziunescha anc betg dal tut en quest navigatur. +printing_not_ready=Attenziun: Il PDF n'è betg chargià cumplettamain per stampar. +web_fonts_disabled=Scrittiras dal web èn deactivadas: impussibel dad utilisar las scrittiras integradas en il PDF. +document_colors_not_allowed=Documents da PDF na dastgan betg duvrar las atgnas colurs: 'Permetter a paginas da tscherner lur atgna colur' è deactivà en il navigatur. diff --git a/static/pdf.js/locale/ro/viewer.ftl b/static/pdf.js/locale/ro/viewer.ftl deleted file mode 100644 index 7c6f0b6a..00000000 --- a/static/pdf.js/locale/ro/viewer.ftl +++ /dev/null @@ -1,251 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pagina precedentă -pdfjs-previous-button-label = Înapoi -pdfjs-next-button = - .title = Pagina următoare -pdfjs-next-button-label = Înainte -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pagina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = din { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } din { $pagesCount }) -pdfjs-zoom-out-button = - .title = Micșorează -pdfjs-zoom-out-button-label = Micșorează -pdfjs-zoom-in-button = - .title = Mărește -pdfjs-zoom-in-button-label = Mărește -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Comută la modul de prezentare -pdfjs-presentation-mode-button-label = Mod de prezentare -pdfjs-open-file-button = - .title = Deschide un fișier -pdfjs-open-file-button-label = Deschide -pdfjs-print-button = - .title = Tipărește -pdfjs-print-button-label = Tipărește - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Instrumente -pdfjs-tools-button-label = Instrumente -pdfjs-first-page-button = - .title = Mergi la prima pagină -pdfjs-first-page-button-label = Mergi la prima pagină -pdfjs-last-page-button = - .title = Mergi la ultima pagină -pdfjs-last-page-button-label = Mergi la ultima pagină -pdfjs-page-rotate-cw-button = - .title = Rotește în sensul acelor de ceas -pdfjs-page-rotate-cw-button-label = Rotește în sensul acelor de ceas -pdfjs-page-rotate-ccw-button = - .title = Rotește în sens invers al acelor de ceas -pdfjs-page-rotate-ccw-button-label = Rotește în sens invers al acelor de ceas -pdfjs-cursor-text-select-tool-button = - .title = Activează instrumentul de selecție a textului -pdfjs-cursor-text-select-tool-button-label = Instrumentul de selecție a textului -pdfjs-cursor-hand-tool-button = - .title = Activează instrumentul mână -pdfjs-cursor-hand-tool-button-label = Unealta mână -pdfjs-scroll-vertical-button = - .title = Folosește derularea verticală -pdfjs-scroll-vertical-button-label = Derulare verticală -pdfjs-scroll-horizontal-button = - .title = Folosește derularea orizontală -pdfjs-scroll-horizontal-button-label = Derulare orizontală -pdfjs-scroll-wrapped-button = - .title = Folosește derularea încadrată -pdfjs-scroll-wrapped-button-label = Derulare încadrată -pdfjs-spread-none-button = - .title = Nu uni paginile broșate -pdfjs-spread-none-button-label = Fără pagini broșate -pdfjs-spread-odd-button = - .title = Unește paginile broșate începând cu cele impare -pdfjs-spread-odd-button-label = Broșare pagini impare -pdfjs-spread-even-button = - .title = Unește paginile broșate începând cu cele pare -pdfjs-spread-even-button-label = Broșare pagini pare - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Proprietățile documentului… -pdfjs-document-properties-button-label = Proprietățile documentului… -pdfjs-document-properties-file-name = Numele fișierului: -pdfjs-document-properties-file-size = Mărimea fișierului: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } byți) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } byți) -pdfjs-document-properties-title = Titlu: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Subiect: -pdfjs-document-properties-keywords = Cuvinte cheie: -pdfjs-document-properties-creation-date = Data creării: -pdfjs-document-properties-modification-date = Data modificării: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Autor: -pdfjs-document-properties-producer = Producător PDF: -pdfjs-document-properties-version = Versiune PDF: -pdfjs-document-properties-page-count = Număr de pagini: -pdfjs-document-properties-page-size = Mărimea paginii: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = verticală -pdfjs-document-properties-page-size-orientation-landscape = orizontală -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Literă -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vizualizare web rapidă: -pdfjs-document-properties-linearized-yes = Da -pdfjs-document-properties-linearized-no = Nu -pdfjs-document-properties-close-button = Închide - -## Print - -pdfjs-print-progress-message = Se pregătește documentul pentru tipărire… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Renunță -pdfjs-printing-not-supported = Avertisment: Tipărirea nu este suportată în totalitate de acest browser. -pdfjs-printing-not-ready = Avertisment: PDF-ul nu este încărcat complet pentru tipărire. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Comută bara laterală -pdfjs-toggle-sidebar-button-label = Comută bara laterală -pdfjs-document-outline-button = - .title = Afișează schița documentului (dublu-clic pentru a extinde/restrânge toate elementele) -pdfjs-document-outline-button-label = Schița documentului -pdfjs-attachments-button = - .title = Afișează atașamentele -pdfjs-attachments-button-label = Atașamente -pdfjs-thumbs-button = - .title = Afișează miniaturi -pdfjs-thumbs-button-label = Miniaturi -pdfjs-findbar-button = - .title = Caută în document -pdfjs-findbar-button-label = Caută - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pagina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura paginii { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Caută - .placeholder = Caută în document… -pdfjs-find-previous-button = - .title = Mergi la apariția anterioară a textului -pdfjs-find-previous-button-label = Înapoi -pdfjs-find-next-button = - .title = Mergi la apariția următoare a textului -pdfjs-find-next-button-label = Înainte -pdfjs-find-highlight-checkbox = Evidențiază toate aparițiile -pdfjs-find-match-case-checkbox-label = Ține cont de majuscule și minuscule -pdfjs-find-entire-word-checkbox-label = Cuvinte întregi -pdfjs-find-reached-top = Am ajuns la începutul documentului, continuă de la sfârșit -pdfjs-find-reached-bottom = Am ajuns la sfârșitul documentului, continuă de la început -pdfjs-find-not-found = Nu s-a găsit textul - -## Predefined zoom values - -pdfjs-page-scale-width = Lățime pagină -pdfjs-page-scale-fit = Potrivire la pagină -pdfjs-page-scale-auto = Zoom automat -pdfjs-page-scale-actual = Mărime reală -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = A intervenit o eroare la încărcarea PDF-ului. -pdfjs-invalid-file-error = Fișier PDF nevalid sau corupt. -pdfjs-missing-file-error = Fișier PDF lipsă. -pdfjs-unexpected-response-error = Răspuns neașteptat de la server. -pdfjs-rendering-error = A intervenit o eroare la randarea paginii. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Adnotare { $type }] - -## Password - -pdfjs-password-label = Introdu parola pentru a deschide acest fișier PDF. -pdfjs-password-invalid = Parolă nevalidă. Te rugăm să încerci din nou. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Renunță -pdfjs-web-fonts-disabled = Fonturile web sunt dezactivate: nu se pot folosi fonturile PDF încorporate. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ro/viewer.properties b/static/pdf.js/locale/ro/viewer.properties new file mode 100644 index 00000000..f4170ed8 --- /dev/null +++ b/static/pdf.js/locale/ro/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Pagina precedentă +previous_label=Înapoi +next.title=Pagina următoare +next_label=Înainte + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pagină: +page_of=din {{pageCount}} + +zoom_out.title=Micșorează +zoom_out_label=Micșorează +zoom_in.title=Mărește +zoom_in_label=Mărește +zoom.title=Scalare +presentation_mode.title=Schimbă la modul de prezentare +presentation_mode_label=Mod de prezentare +open_file.title=Deschide un fișier +open_file_label=Deschide +print.title=Tipărește +print_label=Tipărește +download.title=Descarcă +download_label=Descarcă +bookmark.title=Vizualizare actuală (copiați sau deschideți într-o fereastră nouă) +bookmark_label=Vizualizare actuală + +# Secondary toolbar and context menu +tools.title=Unelte +tools_label=Unelte +first_page.title=Mergi la prima pagină +first_page.label=Mergeți la prima pagină +first_page_label=Mergi la prima pagină +last_page.title=Mergi la ultima pagină +last_page.label=Mergi la ultima pagină +last_page_label=Mergi la ultima pagină +page_rotate_cw.title=Rotește în sensul acelor de ceasornic +page_rotate_cw.label=Rotește în sensul acelor de ceasornic +page_rotate_cw_label=Rotește în sensul acelor de ceasornic +page_rotate_ccw.title=Rotește în sens invers al acelor de ceasornic +page_rotate_ccw.label=Rotate Counter-Clockwise +page_rotate_ccw_label=Rotește în sens invers acelor de ceasornic + +hand_tool_enable.title=Activează instrumentul mână +hand_tool_enable_label=Activează instrumentul mână +hand_tool_disable.title=Dezactivează instrumentul mână +hand_tool_disable_label=Dezactivează instrumentul mână + +# Document properties dialog box +document_properties.title=Proprietățile documentului… +document_properties_label=Proprietățile documentului… +document_properties_file_name=Nume fișier: +document_properties_file_size=Dimensiune fișier: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} byți) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} byți) +document_properties_title=Titlu: +document_properties_author=Autor: +document_properties_subject=Subiect: +document_properties_keywords=Cuvinte cheie: +document_properties_creation_date=Data creării: +document_properties_modification_date=Data modificării: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Autor: +document_properties_producer=Producător PDF: +document_properties_version=Versiune PDF: +document_properties_page_count=Număr de pagini: +document_properties_close=Închide + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Comută bara laterală +toggle_sidebar_label=Comută bara laterală +outline.title=Arată schița documentului +outline_label=Schiță document +attachments.title=Afișează atașamentele +attachments_label=Atașamente +thumbs.title=Arată miniaturi +thumbs_label=Miniaturi +findbar.title=Caută în document +findbar_label=Căutați + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pagina {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatura paginii {{page}} + +# Find panel button title and messages +find_label=Caută: +find_previous.title=Găsește instanța anterioară în frază +find_previous_label=Anterior +find_next.title=Găstește următoarea instanță în frază +find_next_label=Următor +find_highlight=Evidențiază aparițiile +find_match_case_label=Potrivește literele mari și mici +find_reached_top=Am ajuns la începutul documentului, continuă de la sfârșit +find_reached_bottom=Am ajuns la sfârșitul documentului, continuă de la început +find_not_found=Nu s-a găsit textul + +# Error panel labels +error_more_info=Mai multe informații +error_less_info=Mai puține informații +error_close=Închide +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (varianta: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mesaj: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stivă: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fișier: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linie: {{line}} +rendering_error=A intervenit o eroare la afișarea paginii. + +# Predefined zoom values +page_scale_width=Lățime pagină +page_scale_fit=Potrivire la pagină +page_scale_auto=Dimensiune automată +page_scale_actual=Dimensiune reală +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Eroare +loading_error=A intervenit o eroare la încărcarea fișierului PDF. +invalid_file_error=Fișier PDF invalid sau deteriorat. +missing_file_error=Fișier PDF lipsă. +unexpected_response_error=Răspuns neașteptat de la server. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Adnotare] +password_label=Introduceți parola pentru a deschide acest fișier PDF. +password_invalid=Parolă greșită. Vă rugăm să încercați din nou. +password_ok=Ok +password_cancel=Renunță + +printing_not_supported=Atenție: Tipărirea nu este suportată în totalitate de acest browser. +printing_not_ready=Atenție: Fișierul PDF nu este încărcat complet pentru tipărire. +web_fonts_disabled=Fonturile web sunt dezactivate: nu pot utiliza fonturile PDF încorporate. +document_colors_not_allowed=Documentele PDF nu sunt autorizate să folosească propriile culori: 'Permite paginilor să aleagă propriile culori' este dezactivată în browser. diff --git a/static/pdf.js/locale/ru/viewer.ftl b/static/pdf.js/locale/ru/viewer.ftl deleted file mode 100644 index 6e3713ce..00000000 --- a/static/pdf.js/locale/ru/viewer.ftl +++ /dev/null @@ -1,404 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Предыдущая страница -pdfjs-previous-button-label = Предыдущая -pdfjs-next-button = - .title = Следующая страница -pdfjs-next-button-label = Следующая -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Страница -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = из { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } из { $pagesCount }) -pdfjs-zoom-out-button = - .title = Уменьшить -pdfjs-zoom-out-button-label = Уменьшить -pdfjs-zoom-in-button = - .title = Увеличить -pdfjs-zoom-in-button-label = Увеличить -pdfjs-zoom-select = - .title = Масштаб -pdfjs-presentation-mode-button = - .title = Перейти в режим презентации -pdfjs-presentation-mode-button-label = Режим презентации -pdfjs-open-file-button = - .title = Открыть файл -pdfjs-open-file-button-label = Открыть -pdfjs-print-button = - .title = Печать -pdfjs-print-button-label = Печать -pdfjs-save-button = - .title = Сохранить -pdfjs-save-button-label = Сохранить -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Загрузить -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Загрузить -pdfjs-bookmark-button = - .title = Текущая страница (просмотр URL-адреса с текущей страницы) -pdfjs-bookmark-button-label = Текущая страница -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Открыть в приложении -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Открыть в программе - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Инструменты -pdfjs-tools-button-label = Инструменты -pdfjs-first-page-button = - .title = Перейти на первую страницу -pdfjs-first-page-button-label = Перейти на первую страницу -pdfjs-last-page-button = - .title = Перейти на последнюю страницу -pdfjs-last-page-button-label = Перейти на последнюю страницу -pdfjs-page-rotate-cw-button = - .title = Повернуть по часовой стрелке -pdfjs-page-rotate-cw-button-label = Повернуть по часовой стрелке -pdfjs-page-rotate-ccw-button = - .title = Повернуть против часовой стрелки -pdfjs-page-rotate-ccw-button-label = Повернуть против часовой стрелки -pdfjs-cursor-text-select-tool-button = - .title = Включить Инструмент «Выделение текста» -pdfjs-cursor-text-select-tool-button-label = Инструмент «Выделение текста» -pdfjs-cursor-hand-tool-button = - .title = Включить Инструмент «Рука» -pdfjs-cursor-hand-tool-button-label = Инструмент «Рука» -pdfjs-scroll-page-button = - .title = Использовать прокрутку страниц -pdfjs-scroll-page-button-label = Прокрутка страниц -pdfjs-scroll-vertical-button = - .title = Использовать вертикальную прокрутку -pdfjs-scroll-vertical-button-label = Вертикальная прокрутка -pdfjs-scroll-horizontal-button = - .title = Использовать горизонтальную прокрутку -pdfjs-scroll-horizontal-button-label = Горизонтальная прокрутка -pdfjs-scroll-wrapped-button = - .title = Использовать масштабируемую прокрутку -pdfjs-scroll-wrapped-button-label = Масштабируемая прокрутка -pdfjs-spread-none-button = - .title = Не использовать режим разворотов страниц -pdfjs-spread-none-button-label = Без разворотов страниц -pdfjs-spread-odd-button = - .title = Развороты начинаются с нечётных номеров страниц -pdfjs-spread-odd-button-label = Нечётные страницы слева -pdfjs-spread-even-button = - .title = Развороты начинаются с чётных номеров страниц -pdfjs-spread-even-button-label = Чётные страницы слева - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Свойства документа… -pdfjs-document-properties-button-label = Свойства документа… -pdfjs-document-properties-file-name = Имя файла: -pdfjs-document-properties-file-size = Размер файла: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } КБ ({ $size_b } байт) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } МБ ({ $size_b } байт) -pdfjs-document-properties-title = Заголовок: -pdfjs-document-properties-author = Автор: -pdfjs-document-properties-subject = Тема: -pdfjs-document-properties-keywords = Ключевые слова: -pdfjs-document-properties-creation-date = Дата создания: -pdfjs-document-properties-modification-date = Дата изменения: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Приложение: -pdfjs-document-properties-producer = Производитель PDF: -pdfjs-document-properties-version = Версия PDF: -pdfjs-document-properties-page-count = Число страниц: -pdfjs-document-properties-page-size = Размер страницы: -pdfjs-document-properties-page-size-unit-inches = дюймов -pdfjs-document-properties-page-size-unit-millimeters = мм -pdfjs-document-properties-page-size-orientation-portrait = книжная -pdfjs-document-properties-page-size-orientation-landscape = альбомная -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Быстрый просмотр в Web: -pdfjs-document-properties-linearized-yes = Да -pdfjs-document-properties-linearized-no = Нет -pdfjs-document-properties-close-button = Закрыть - -## Print - -pdfjs-print-progress-message = Подготовка документа к печати… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Отмена -pdfjs-printing-not-supported = Предупреждение: В этом браузере не полностью поддерживается печать. -pdfjs-printing-not-ready = Предупреждение: PDF не полностью загружен для печати. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Показать/скрыть боковую панель -pdfjs-toggle-sidebar-notification-button = - .title = Показать/скрыть боковую панель (документ имеет содержание/вложения/слои) -pdfjs-toggle-sidebar-button-label = Показать/скрыть боковую панель -pdfjs-document-outline-button = - .title = Показать содержание документа (двойной щелчок, чтобы развернуть/свернуть все элементы) -pdfjs-document-outline-button-label = Содержание документа -pdfjs-attachments-button = - .title = Показать вложения -pdfjs-attachments-button-label = Вложения -pdfjs-layers-button = - .title = Показать слои (дважды щёлкните, чтобы сбросить все слои к состоянию по умолчанию) -pdfjs-layers-button-label = Слои -pdfjs-thumbs-button = - .title = Показать миниатюры -pdfjs-thumbs-button-label = Миниатюры -pdfjs-current-outline-item-button = - .title = Найти текущий элемент структуры -pdfjs-current-outline-item-button-label = Текущий элемент структуры -pdfjs-findbar-button = - .title = Найти в документе -pdfjs-findbar-button-label = Найти -pdfjs-additional-layers = Дополнительные слои - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Страница { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Миниатюра страницы { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Найти - .placeholder = Найти в документе… -pdfjs-find-previous-button = - .title = Найти предыдущее вхождение фразы в текст -pdfjs-find-previous-button-label = Назад -pdfjs-find-next-button = - .title = Найти следующее вхождение фразы в текст -pdfjs-find-next-button-label = Далее -pdfjs-find-highlight-checkbox = Подсветить все -pdfjs-find-match-case-checkbox-label = С учётом регистра -pdfjs-find-match-diacritics-checkbox-label = С учётом диакритических знаков -pdfjs-find-entire-word-checkbox-label = Слова целиком -pdfjs-find-reached-top = Достигнут верх документа, продолжено снизу -pdfjs-find-reached-bottom = Достигнут конец документа, продолжено сверху -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } из { $total } совпадения - [few] { $current } из { $total } совпадений - *[many] { $current } из { $total } совпадений - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Более { $limit } совпадения - [few] Более { $limit } совпадений - *[many] Более { $limit } совпадений - } -pdfjs-find-not-found = Фраза не найдена - -## Predefined zoom values - -pdfjs-page-scale-width = По ширине страницы -pdfjs-page-scale-fit = По размеру страницы -pdfjs-page-scale-auto = Автоматически -pdfjs-page-scale-actual = Реальный размер -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Страница { $page } - -## Loading indicator messages - -pdfjs-loading-error = При загрузке PDF произошла ошибка. -pdfjs-invalid-file-error = Некорректный или повреждённый PDF-файл. -pdfjs-missing-file-error = PDF-файл отсутствует. -pdfjs-unexpected-response-error = Неожиданный ответ сервера. -pdfjs-rendering-error = При создании страницы произошла ошибка. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Аннотация { $type }] - -## Password - -pdfjs-password-label = Введите пароль, чтобы открыть этот PDF-файл. -pdfjs-password-invalid = Неверный пароль. Пожалуйста, попробуйте снова. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Отмена -pdfjs-web-fonts-disabled = Веб-шрифты отключены: не удалось задействовать встроенные PDF-шрифты. - -## Editing - -pdfjs-editor-free-text-button = - .title = Текст -pdfjs-editor-free-text-button-label = Текст -pdfjs-editor-ink-button = - .title = Рисовать -pdfjs-editor-ink-button-label = Рисовать -pdfjs-editor-stamp-button = - .title = Добавить или изменить изображения -pdfjs-editor-stamp-button-label = Добавить или изменить изображения -pdfjs-editor-highlight-button = - .title = Выделение -pdfjs-editor-highlight-button-label = Выделение -pdfjs-highlight-floating-button = - .title = Выделение -pdfjs-highlight-floating-button1 = - .title = Выделение - .aria-label = Выделение -pdfjs-highlight-floating-button-label = Выделение - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Удалить рисунок -pdfjs-editor-remove-freetext-button = - .title = Удалить текст -pdfjs-editor-remove-stamp-button = - .title = Удалить изображение -pdfjs-editor-remove-highlight-button = - .title = Удалить выделение - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Цвет -pdfjs-editor-free-text-size-input = Размер -pdfjs-editor-ink-color-input = Цвет -pdfjs-editor-ink-thickness-input = Толщина -pdfjs-editor-ink-opacity-input = Прозрачность -pdfjs-editor-stamp-add-image-button = - .title = Добавить изображение -pdfjs-editor-stamp-add-image-button-label = Добавить изображение -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Толщина -pdfjs-editor-free-highlight-thickness-title = - .title = Изменить толщину при выделении элементов, кроме текста -pdfjs-free-text = - .aria-label = Текстовый редактор -pdfjs-free-text-default-content = Начните вводить… -pdfjs-ink = - .aria-label = Редактор рисования -pdfjs-ink-canvas = - .aria-label = Созданное пользователем изображение - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Альтернативный текст -pdfjs-editor-alt-text-edit-button-label = Изменить альтернативный текст -pdfjs-editor-alt-text-dialog-label = Выберите вариант -pdfjs-editor-alt-text-dialog-description = Альтернативный текст помогает, когда люди не видят изображение или оно не загружается. -pdfjs-editor-alt-text-add-description-label = Добавить описание -pdfjs-editor-alt-text-add-description-description = Старайтесь составлять 1–2 предложения, описывающих предмет, обстановку или действия. -pdfjs-editor-alt-text-mark-decorative-label = Отметить как декоративное -pdfjs-editor-alt-text-mark-decorative-description = Используется для декоративных изображений, таких как рамки или водяные знаки. -pdfjs-editor-alt-text-cancel-button = Отменить -pdfjs-editor-alt-text-save-button = Сохранить -pdfjs-editor-alt-text-decorative-tooltip = Помечен как декоративный -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Например: «Молодой человек садится за стол, чтобы поесть» - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Левый верхний угол — изменить размер -pdfjs-editor-resizer-label-top-middle = Вверху посередине — изменить размер -pdfjs-editor-resizer-label-top-right = Верхний правый угол — изменить размер -pdfjs-editor-resizer-label-middle-right = В центре справа — изменить размер -pdfjs-editor-resizer-label-bottom-right = Нижний правый угол — изменить размер -pdfjs-editor-resizer-label-bottom-middle = Внизу посередине — изменить размер -pdfjs-editor-resizer-label-bottom-left = Нижний левый угол — изменить размер -pdfjs-editor-resizer-label-middle-left = В центре слева — изменить размер - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Цвет выделения -pdfjs-editor-colorpicker-button = - .title = Изменить цвет -pdfjs-editor-colorpicker-dropdown = - .aria-label = Выбор цвета -pdfjs-editor-colorpicker-yellow = - .title = Жёлтый -pdfjs-editor-colorpicker-green = - .title = Зелёный -pdfjs-editor-colorpicker-blue = - .title = Синий -pdfjs-editor-colorpicker-pink = - .title = Розовый -pdfjs-editor-colorpicker-red = - .title = Красный - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Показать все -pdfjs-editor-highlight-show-all-button = - .title = Показать все diff --git a/static/pdf.js/locale/ru/viewer.properties b/static/pdf.js/locale/ru/viewer.properties new file mode 100644 index 00000000..c1af9769 --- /dev/null +++ b/static/pdf.js/locale/ru/viewer.properties @@ -0,0 +1,111 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +previous.title = Предыдущая страница +previous_label = Предыдущая +next.title = Следующая страница +next_label = Следующая +page_label = Страница: +page_of = из {{pageCount}} +zoom_out.title = Уменьшить +zoom_out_label = Уменьшить +zoom_in.title = Увеличить +zoom_in_label = Увеличить +zoom.title = Масштаб +presentation_mode.title = Перейти в режим презентации +presentation_mode_label = Режим презентации +open_file.title = Открыть файл +open_file_label = Открыть +print.title = Печать +print_label = Печать +download.title = Загрузить +download_label = Загрузить +bookmark.title = Ссылка на текущий вид (скопировать или открыть в новом окне) +bookmark_label = Текущий вид +tools.title = Инструменты +tools_label = Инструменты +first_page.title = Перейти на первую страницу +first_page.label = Перейти на первую страницу +first_page_label = Перейти на первую страницу +last_page.title = Перейти на последнюю страницу +last_page.label = Перейти на последнюю страницу +last_page_label = Перейти на последнюю страницу +page_rotate_cw.title = Повернуть по часовой стрелке +page_rotate_cw.label = Повернуть по часовой стрелке +page_rotate_cw_label = Повернуть по часовой стрелке +page_rotate_ccw.title = Повернуть против часовой стрелки +page_rotate_ccw.label = Повернуть против часовой стрелки +page_rotate_ccw_label = Повернуть против часовой стрелки +hand_tool_enable.title = Включить Инструмент «Рука» +hand_tool_enable_label = Включить Инструмент «Рука» +hand_tool_disable.title = Отключить Инструмент «Рука» +hand_tool_disable_label = Отключить Инструмент «Рука» +document_properties.title = Свойства документа… +document_properties_label = Свойства документа… +document_properties_file_name = Имя файла: +document_properties_file_size = Размер файла: +document_properties_kb = {{size_kb}} КБ ({{size_b}} байт) +document_properties_mb = {{size_mb}} МБ ({{size_b}} байт) +document_properties_title = Заголовок: +document_properties_author = Автор: +document_properties_subject = Тема: +document_properties_keywords = Ключевые слова: +document_properties_creation_date = Дата создания: +document_properties_modification_date = Дата изменения: +document_properties_date_string = {{date}}, {{time}} +document_properties_creator = Приложение: +document_properties_producer = Производитель PDF: +document_properties_version = Версия PDF: +document_properties_page_count = Число страниц: +document_properties_close = Закрыть +toggle_sidebar.title = Открыть/закрыть боковую панель +toggle_sidebar_label = Открыть/закрыть боковую панель +outline.title = Показать содержание документа +outline_label = Содержание документа +attachments.title = Показать вложения +attachments_label = Вложения +thumbs.title = Показать миниатюры +thumbs_label = Миниатюры +findbar.title = Найти в документе +findbar_label = Найти +thumb_page_title = Страница {{page}} +thumb_page_canvas = Миниатюра страницы {{page}} +find_label = Найти: +find_previous.title = Найти предыдущее вхождение фразы в текст +find_previous_label = Назад +find_next.title = Найти следующее вхождение фразы в текст +find_next_label = Далее +find_highlight = Подсветить все +find_match_case_label = С учётом регистра +find_reached_top = Достигнут верх документа, продолжено снизу +find_reached_bottom = Достигнут конец документа, продолжено сверху +find_not_found = Фраза не найдена +error_more_info = Детали +error_less_info = Скрыть детали +error_close = Закрыть +error_version_info = PDF.js v{{version}} (сборка: {{build}}) +error_message = Сообщение: {{message}} +error_stack = Стeк: {{stack}} +error_file = Файл: {{file}} +error_line = Строка: {{line}} +rendering_error = При создании страницы произошла ошибка. +page_scale_width = По ширине страницы +page_scale_fit = По размеру страницы +page_scale_auto = Автоматически +page_scale_actual = Реальный размер +page_scale_percent = {{scale}}% +loading_error_indicator = Ошибка +loading_error = При загрузке PDF произошла ошибка. +invalid_file_error = Некорректный или повреждённый PDF-файл. +missing_file_error = PDF-файл отсутствует. +unexpected_response_error = Неожиданный ответ сервера. +text_annotation_type.alt = [Аннотация {{type}}] +password_label = Введите пароль, чтобы открыть этот PDF-файл. +password_invalid = Неверный пароль. Пожалуйста, попробуйте снова. +password_ok = OK +password_cancel = Отмена +printing_not_supported = Предупреждение: В этом браузере не полностью поддерживается печать. +printing_not_ready = Предупреждение: PDF не полностью загружен для печати. +web_fonts_disabled = Веб-шрифты отключены: невозможно использовать встроенные PDF-шрифты. +document_colors_not_allowed = PDF-документам не разрешено использовать свои цвета: в браузере отключён параметр «Разрешить веб-сайтам использовать свои цвета». diff --git a/static/pdf.js/locale/rw/viewer.properties b/static/pdf.js/locale/rw/viewer.properties new file mode 100644 index 00000000..7858fe64 --- /dev/null +++ b/static/pdf.js/locale/rw/viewer.properties @@ -0,0 +1,79 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. + +zoom.title=Ihindurangano +open_file.title=Gufungura Dosiye +open_file_label=Gufungura + +# Secondary toolbar and context menu + + +# Document properties dialog box +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Umutwe: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +findbar_label=Gushakisha + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. + +# Find panel button title and messages +find_label="Gushaka:" +find_previous.title=Gushaka aho uyu murongo ugaruka mbere y'aha +find_next.title=Gushaka aho uyu murongo wongera kugaruka +find_not_found=Umurongo ntubonetse + +# Error panel labels +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number + +# Predefined zoom values +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Ikosa + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +password_invalid=Ijambo ry'ibanga ridahari. Wakongera ukagerageza +password_ok=YEGO +password_cancel=Kureka + diff --git a/static/pdf.js/locale/sah/viewer.properties b/static/pdf.js/locale/sah/viewer.properties new file mode 100644 index 00000000..d0e08614 --- /dev/null +++ b/static/pdf.js/locale/sah/viewer.properties @@ -0,0 +1,171 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Инники сирэй +previous_label=Иннинээҕи +next.title=Аныгыскы сирэй +next_label=Аныгыскы + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Сирэй: +page_of=мантан {{pageCount}} + +zoom_out.title=Куччат +zoom_out_label=Куччат +zoom_in.title=Улаатыннар +zoom_in_label=Улаатыннар +zoom.title=Улаатыннар +presentation_mode.title=Көрдөрөр эрэсиимҥэ +presentation_mode_label=Көрдөрөр эрэсиим +open_file.title=Билэни арый +open_file_label=Ас +print.title=Бэчээт +print_label=Бэчээт +download.title=Хачайдааһын +download_label=Хачайдааһын +bookmark.title=Билиҥҥи көстүүтэ (хатылаа эбэтэр саҥа түннүккэ арый) +bookmark_label=Билиҥҥи көстүүтэ + +# Secondary toolbar and context menu +tools.title=Тэриллэр +tools_label=Тэриллэр +first_page.title=Бастакы сирэйгэ көс +first_page.label=Бастакы сирэйгэ көс +first_page_label=Бастакы сирэйгэ көс +last_page.title=Тиһэх сирэйгэ көс +last_page.label=Тиһэх сирэйгэ көс +last_page_label=Тиһэх сирэйгэ көс +page_rotate_cw.title=Чаһы хоту эргит +page_rotate_cw.label=Чаһы хоту эргит +page_rotate_cw_label=Чаһы хоту эргит +page_rotate_ccw.title=Чаһы утары эргит +page_rotate_ccw.label=Чаһы утары эргит +page_rotate_ccw_label=Чаһы утары эргит + +hand_tool_enable.title=«Илии» диэн тэрили холбоо +hand_tool_enable_label=«Илии» диэн тэрили холбоо +hand_tool_disable.title=«Илии» диэн тэрили араар +hand_tool_disable_label=«Илии» диэн тэрили араар + +# Document properties dialog box +document_properties.title=Докумуон туруоруулара... +document_properties_label=Докумуон туруоруулара...\u0020 +document_properties_file_name=Билэ аата: +document_properties_file_size=Билэ кээмэйэ: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} КБ ({{size_b}} баайт) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} МБ ({{size_b}} баайт) +document_properties_title=Баһа: +document_properties_author=Ааптар: +document_properties_subject=Тиэмэ: +document_properties_keywords=Күлүүс тыл: +document_properties_creation_date=Оҥоһуллубут кэмэ: +document_properties_modification_date=Уларытыллыбыт кэмэ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_producer=PDF оҥорооччу: +document_properties_version=PDF барыла: +document_properties_page_count=Сирэй ахсаана: +document_properties_close=Сап + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Ойоҕос хапталы арый/сап +toggle_sidebar_label=Ойоҕос хапталы арый/сап +outline.title=Дөкүмүөн иһинээҕитин көрдөр +outline_label=Дөкүмүөн иһинээҕитэ +attachments.title=Кыбытыктары көрдөр +attachments_label=Кыбытык +thumbs.title=Ойуучааннары көрдөр +thumbs_label=Ойуучааннар +findbar.title=Дөкүмүөнтэн бул +findbar_label=Бул + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Сирэй {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Сирэй ойуучаана {{page}} + +# Find panel button title and messages +find_label=Бул: +find_previous.title=Этии тиэкискэ бу иннинээҕи киириитин бул +find_previous_label=Иннинээҕи +find_next.title=Этии тиэкискэ бу кэннинээҕи киириитин бул +find_next_label=Аныгыскы +find_highlight=Барытын сырдатан көрдөр +find_match_case_label=Буукуба улаханын-кыратын араар +find_reached_top=Сирэй үрдүгэр тиийдиҥ, салгыыта аллара +find_reached_bottom=Сирэй бүттэ, үөһэ салҕанна +find_not_found=Этии көстүбэтэ + +# Error panel labels +error_more_info=Сиһилии +error_less_info=Сиһилиитин кистээ +error_close=Сап +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (хомуйуута: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Этии: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Стeк: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Билэ: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Устуруока: {{line}} +rendering_error=Сирэйи айарга алҕас таҕыста. + +# Predefined zoom values +page_scale_width=Сирэй кэтитинэн +page_scale_fit=Сирэй кээмэйинэн +page_scale_auto=Аптамаатынан +page_scale_actual=Дьиҥнээх кээмэйэ +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Алҕас +loading_error=PDF-билэни хачайдыырга алҕас таҕыста. +invalid_file_error=Туох эрэ алҕастаах эбэтэр алдьаммыт PDF-билэ. +missing_file_error=PDF-билэ суох. +unexpected_response_error=Сиэрбэр хоруйдаабат. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} туһунан] +password_label=Бу PDF-билэни арыйарга көмүскэл тылы киллэриэхтээхин. +password_invalid=Киирии тыл алҕастаах. Бука диэн, хатылаан көр. +password_ok=СӨП +password_cancel=Салҕаама + +printing_not_supported=Сэрэтии: Бу браузер бэчээттиири толору өйөөбөт. +printing_not_ready=Сэрэтии: PDF бэчээттииргэ толору хачайдана илик. +web_fonts_disabled=Ситим-бичиктэр араарыллыахтара: PDF бичиктэрэ кыайан көстүбэттэр. +document_colors_not_allowed=PDF-дөкүмүөүннэргэ бэйэлэрин өҥнөрүн туттар көҥүллэммэтэ: "Ситим-сирдэр бэйэлэрин өҥнөрүн тутталларын көҥүллүүргэ" диэн браузерга арахса сылдьар эбит. diff --git a/static/pdf.js/locale/sat/viewer.ftl b/static/pdf.js/locale/sat/viewer.ftl deleted file mode 100644 index 90f12a31..00000000 --- a/static/pdf.js/locale/sat/viewer.ftl +++ /dev/null @@ -1,311 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = ᱢᱟᱲᱟᱝ ᱥᱟᱦᱴᱟ -pdfjs-previous-button-label = ᱢᱟᱲᱟᱝᱟᱜ -pdfjs-next-button = - .title = ᱤᱱᱟᱹ ᱛᱟᱭᱚᱢ ᱥᱟᱦᱴᱟ -pdfjs-next-button-label = ᱤᱱᱟᱹ ᱛᱟᱭᱚᱢ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = ᱥᱟᱦᱴᱟ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = ᱨᱮᱭᱟᱜ { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } ᱠᱷᱚᱱ { $pagesCount }) -pdfjs-zoom-out-button = - .title = ᱦᱤᱲᱤᱧ ᱛᱮᱭᱟᱨ -pdfjs-zoom-out-button-label = ᱦᱤᱲᱤᱧ ᱛᱮᱭᱟᱨ -pdfjs-zoom-in-button = - .title = ᱢᱟᱨᱟᱝ ᱛᱮᱭᱟᱨ -pdfjs-zoom-in-button-label = ᱢᱟᱨᱟᱝ ᱛᱮᱭᱟᱨ -pdfjs-zoom-select = - .title = ᱡᱩᱢ -pdfjs-presentation-mode-button = - .title = ᱩᱫᱩᱜ ᱥᱚᱫᱚᱨ ᱚᱵᱚᱥᱛᱟ ᱨᱮ ᱚᱛᱟᱭ ᱢᱮ -pdfjs-presentation-mode-button-label = ᱩᱫᱩᱜ ᱥᱚᱫᱚᱨ ᱚᱵᱚᱥᱛᱟ ᱨᱮ -pdfjs-open-file-button = - .title = ᱨᱮᱫ ᱡᱷᱤᱡᱽ ᱢᱮ -pdfjs-open-file-button-label = ᱡᱷᱤᱡᱽ ᱢᱮ -pdfjs-print-button = - .title = ᱪᱷᱟᱯᱟ -pdfjs-print-button-label = ᱪᱷᱟᱯᱟ -pdfjs-save-button = - .title = ᱥᱟᱺᱪᱟᱣ ᱢᱮ -pdfjs-save-button-label = ᱥᱟᱺᱪᱟᱣ ᱢᱮ -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = ᱰᱟᱣᱩᱱᱞᱚᱰ -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = ᱰᱟᱣᱩᱱᱞᱚᱰ -pdfjs-bookmark-button = - .title = ᱱᱤᱛᱚᱜᱟᱜ ᱥᱟᱦᱴᱟ (ᱱᱤᱛᱚᱜᱟᱜ ᱥᱟᱦᱴᱟ ᱠᱷᱚᱱ URL ᱫᱮᱠᱷᱟᱣ ᱢᱮ) -pdfjs-bookmark-button-label = ᱱᱤᱛᱚᱜᱟᱜ ᱥᱟᱦᱴᱟ -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = ᱮᱯ ᱨᱮ ᱡᱷᱤᱡᱽ ᱢᱮ -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = ᱮᱯ ᱨᱮ ᱡᱷᱤᱡᱽ ᱢᱮ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = ᱦᱟᱹᱛᱤᱭᱟᱹᱨ ᱠᱚ -pdfjs-tools-button-label = ᱦᱟᱹᱛᱤᱭᱟᱹᱨ ᱠᱚ -pdfjs-first-page-button = - .title = ᱯᱩᱭᱞᱩ ᱥᱟᱦᱴᱟ ᱥᱮᱫ ᱪᱟᱞᱟᱜ ᱢᱮ -pdfjs-first-page-button-label = ᱯᱩᱭᱞᱩ ᱥᱟᱦᱴᱟ ᱥᱮᱫ ᱪᱟᱞᱟᱜ ᱢᱮ -pdfjs-last-page-button = - .title = ᱢᱩᱪᱟᱹᱫ ᱥᱟᱦᱴᱟ ᱥᱮᱫ ᱪᱟᱞᱟᱜ ᱢᱮ -pdfjs-last-page-button-label = ᱢᱩᱪᱟᱹᱫ ᱥᱟᱦᱴᱟ ᱥᱮᱫ ᱪᱟᱞᱟᱜ ᱢᱮ -pdfjs-page-rotate-cw-button = - .title = ᱜᱷᱚᱰᱤ ᱦᱤᱥᱟᱹᱵ ᱛᱮ ᱟᱹᱪᱩᱨ -pdfjs-page-rotate-cw-button-label = ᱜᱷᱚᱰᱤ ᱦᱤᱥᱟᱹᱵ ᱛᱮ ᱟᱹᱪᱩᱨ -pdfjs-page-rotate-ccw-button = - .title = ᱜᱷᱚᱰᱤ ᱦᱤᱥᱟᱹᱵ ᱛᱮ ᱩᱞᱴᱟᱹ ᱟᱹᱪᱩᱨ -pdfjs-page-rotate-ccw-button-label = ᱜᱷᱚᱰᱤ ᱦᱤᱥᱟᱹᱵ ᱛᱮ ᱩᱞᱴᱟᱹ ᱟᱹᱪᱩᱨ -pdfjs-cursor-text-select-tool-button = - .title = ᱚᱞ ᱵᱟᱪᱷᱟᱣ ᱦᱟᱹᱛᱤᱭᱟᱨ ᱮᱢ ᱪᱷᱚᱭ ᱢᱮ -pdfjs-cursor-text-select-tool-button-label = ᱚᱞ ᱵᱟᱪᱷᱟᱣ ᱦᱟᱹᱛᱤᱭᱟᱨ -pdfjs-cursor-hand-tool-button = - .title = ᱛᱤ ᱦᱟᱹᱛᱤᱭᱟᱨ ᱮᱢ ᱪᱷᱚᱭ ᱢᱮ -pdfjs-cursor-hand-tool-button-label = ᱛᱤ ᱦᱟᱹᱛᱤᱭᱟᱨ -pdfjs-scroll-page-button = - .title = ᱥᱟᱦᱴᱟ ᱜᱩᱲᱟᱹᱣ ᱵᱮᱵᱷᱟᱨ ᱢᱮ -pdfjs-scroll-page-button-label = ᱥᱟᱦᱴᱟ ᱜᱩᱲᱟᱹᱣ -pdfjs-scroll-vertical-button = - .title = ᱥᱤᱫᱽ ᱜᱩᱲᱟᱹᱣ ᱵᱮᱵᱷᱟᱨ ᱢᱮ -pdfjs-scroll-vertical-button-label = ᱥᱤᱫᱽ ᱜᱩᱲᱟᱹᱣ -pdfjs-scroll-horizontal-button = - .title = ᱜᱤᱛᱤᱡ ᱛᱮ ᱜᱩᱲᱟᱹᱣ ᱵᱮᱵᱷᱟᱨ ᱢᱮ -pdfjs-scroll-horizontal-button-label = ᱜᱤᱛᱤᱡ ᱛᱮ ᱜᱩᱲᱟᱹᱣ -pdfjs-scroll-wrapped-button = - .title = ᱞᱤᱯᱴᱟᱹᱣ ᱜᱩᱰᱨᱟᱹᱣ ᱵᱮᱵᱷᱟᱨ ᱢᱮ -pdfjs-scroll-wrapped-button-label = ᱞᱤᱯᱴᱟᱣ ᱜᱩᱰᱨᱟᱹᱣ -pdfjs-spread-none-button = - .title = ᱟᱞᱚᱢ ᱡᱚᱲᱟᱣ ᱟ ᱥᱟᱦᱴᱟ ᱫᱚ ᱯᱟᱥᱱᱟᱣᱜᱼᱟ -pdfjs-spread-none-button-label = ᱯᱟᱥᱱᱟᱣ ᱵᱟᱹᱱᱩᱜᱼᱟ -pdfjs-spread-odd-button = - .title = ᱥᱟᱦᱴᱟ ᱯᱟᱥᱱᱟᱣ ᱡᱚᱲᱟᱣ ᱢᱮ ᱡᱟᱦᱟᱸ ᱫᱚ ᱚᱰᱼᱮᱞ ᱥᱟᱦᱴᱟᱠᱚ ᱥᱟᱞᱟᱜ ᱮᱛᱦᱚᱵᱚᱜ ᱠᱟᱱᱟ -pdfjs-spread-odd-button-label = ᱚᱰ ᱯᱟᱥᱱᱟᱣ -pdfjs-spread-even-button = - .title = ᱥᱟᱦᱴᱟ ᱯᱟᱥᱱᱟᱣ ᱡᱚᱲᱟᱣ ᱢᱮ ᱡᱟᱦᱟᱸ ᱫᱚ ᱤᱣᱮᱱᱼᱮᱞ ᱥᱟᱦᱴᱟᱠᱚ ᱥᱟᱞᱟᱜ ᱮᱛᱦᱚᱵᱚᱜ ᱠᱟᱱᱟ -pdfjs-spread-even-button-label = ᱯᱟᱥᱱᱟᱣ ᱤᱣᱮᱱ - -## Document properties dialog - -pdfjs-document-properties-button = - .title = ᱫᱚᱞᱤᱞ ᱜᱩᱱᱠᱚ … -pdfjs-document-properties-button-label = ᱫᱚᱞᱤᱞ ᱜᱩᱱᱠᱚ … -pdfjs-document-properties-file-name = ᱨᱮᱫᱽ ᱧᱩᱛᱩᱢ : -pdfjs-document-properties-file-size = ᱨᱮᱫᱽ ᱢᱟᱯ : -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } ᱵᱟᱭᱤᱴ ᱠᱚ) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } ᱵᱟᱭᱤᱴ ᱠᱚ) -pdfjs-document-properties-title = ᱧᱩᱛᱩᱢ : -pdfjs-document-properties-author = ᱚᱱᱚᱞᱤᱭᱟᱹ : -pdfjs-document-properties-subject = ᱵᱤᱥᱚᱭ : -pdfjs-document-properties-keywords = ᱠᱟᱹᱴᱷᱤ ᱥᱟᱵᱟᱫᱽ : -pdfjs-document-properties-creation-date = ᱛᱮᱭᱟᱨ ᱢᱟᱸᱦᱤᱛ : -pdfjs-document-properties-modification-date = ᱵᱚᱫᱚᱞ ᱦᱚᱪᱚ ᱢᱟᱹᱦᱤᱛ : -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = ᱵᱮᱱᱟᱣᱤᱡ : -pdfjs-document-properties-producer = PDF ᱛᱮᱭᱟᱨ ᱚᱰᱚᱠᱤᱡ : -pdfjs-document-properties-version = PDF ᱵᱷᱟᱹᱨᱥᱚᱱ : -pdfjs-document-properties-page-count = ᱥᱟᱦᱴᱟ ᱞᱮᱠᱷᱟ : -pdfjs-document-properties-page-size = ᱥᱟᱦᱴᱟ ᱢᱟᱯ : -pdfjs-document-properties-page-size-unit-inches = ᱤᱧᱪ -pdfjs-document-properties-page-size-unit-millimeters = ᱢᱤᱢᱤ -pdfjs-document-properties-page-size-orientation-portrait = ᱯᱚᱴᱨᱮᱴ -pdfjs-document-properties-page-size-orientation-landscape = ᱞᱮᱱᱰᱥᱠᱮᱯ -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = ᱪᱤᱴᱷᱤ -pdfjs-document-properties-page-size-name-legal = ᱠᱟᱹᱱᱩᱱᱤ - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = ᱞᱚᱜᱚᱱ ᱣᱮᱵᱽ ᱧᱮᱞ : -pdfjs-document-properties-linearized-yes = ᱦᱚᱭ -pdfjs-document-properties-linearized-no = ᱵᱟᱝ -pdfjs-document-properties-close-button = ᱵᱚᱸᱫᱚᱭ ᱢᱮ - -## Print - -pdfjs-print-progress-message = ᱪᱷᱟᱯᱟ ᱞᱟᱹᱜᱤᱫ ᱫᱚᱞᱤᱞ ᱛᱮᱭᱟᱨᱚᱜ ᱠᱟᱱᱟ … -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = ᱵᱟᱹᱰᱨᱟᱹ -pdfjs-printing-not-supported = ᱦᱚᱥᱤᱭᱟᱨ : ᱪᱷᱟᱯᱟ ᱱᱚᱣᱟ ᱯᱟᱱᱛᱮᱭᱟᱜ ᱫᱟᱨᱟᱭ ᱛᱮ ᱯᱩᱨᱟᱹᱣ ᱵᱟᱭ ᱜᱚᱲᱚᱣᱟᱠᱟᱱᱟ ᱾ -pdfjs-printing-not-ready = ᱦᱩᱥᱤᱭᱟᱹᱨ : ᱪᱷᱟᱯᱟ ᱞᱟᱹᱜᱤᱫ PDF ᱯᱩᱨᱟᱹ ᱵᱟᱭ ᱞᱟᱫᱮ ᱟᱠᱟᱱᱟ ᱾ - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = ᱫᱷᱟᱨᱮᱵᱟᱨ ᱥᱮᱫ ᱩᱪᱟᱹᱲᱚᱜ ᱢᱮ -pdfjs-toggle-sidebar-notification-button = - .title = ᱫᱷᱟᱨᱮᱵᱟᱨ ᱥᱮᱫ ᱩᱪᱟᱹᱲᱚᱜ ᱢᱮ (ᱫᱚᱞᱤᱞ ᱨᱮ ᱟᱣᱴᱞᱟᱭᱤᱢ ᱢᱮᱱᱟᱜᱼᱟ/ᱞᱟᱪᱷᱟᱠᱚ/ᱯᱚᱨᱚᱛᱠᱚ) -pdfjs-toggle-sidebar-button-label = ᱫᱷᱟᱨᱮᱵᱟᱨ ᱥᱮᱫ ᱩᱪᱟᱹᱲᱚᱜ ᱢᱮ -pdfjs-document-outline-button = - .title = ᱫᱚᱞᱚᱞ ᱟᱣᱴᱞᱟᱭᱤᱱ ᱫᱮᱠᱷᱟᱣ ᱢᱮ (ᱡᱷᱚᱛᱚ ᱡᱤᱱᱤᱥᱠᱚ ᱵᱟᱨ ᱡᱮᱠᱷᱟ ᱚᱛᱟ ᱠᱮᱛᱮ ᱡᱷᱟᱹᱞ/ᱦᱩᱰᱤᱧ ᱪᱷᱚᱭ ᱢᱮ) -pdfjs-document-outline-button-label = ᱫᱚᱞᱤᱞ ᱛᱮᱭᱟᱨ ᱛᱮᱫ -pdfjs-attachments-button = - .title = ᱞᱟᱴᱷᱟ ᱥᱮᱞᱮᱫ ᱠᱚ ᱩᱫᱩᱜᱽ ᱢᱮ -pdfjs-attachments-button-label = ᱞᱟᱴᱷᱟ ᱥᱮᱞᱮᱫ ᱠᱚ -pdfjs-layers-button = - .title = ᱯᱚᱨᱚᱛ ᱫᱮᱠᱷᱟᱣ ᱢᱮ (ᱢᱩᱞ ᱡᱟᱭᱜᱟ ᱛᱮ ᱡᱷᱚᱛᱚ ᱯᱚᱨᱚᱛᱠᱚ ᱨᱤᱥᱮᱴ ᱞᱟᱹᱜᱤᱫ ᱵᱟᱨ ᱡᱮᱠᱷᱟ ᱚᱛᱚᱭ ᱢᱮ) -pdfjs-layers-button-label = ᱯᱚᱨᱚᱛᱠᱚ -pdfjs-thumbs-button = - .title = ᱪᱤᱛᱟᱹᱨ ᱟᱦᱞᱟ ᱠᱚ ᱩᱫᱩᱜᱽ ᱢᱮ -pdfjs-thumbs-button-label = ᱪᱤᱛᱟᱹᱨ ᱟᱦᱞᱟ ᱠᱚ -pdfjs-current-outline-item-button = - .title = ᱱᱤᱛᱚᱜᱟᱜ ᱟᱣᱴᱞᱟᱭᱤᱱ ᱡᱟᱱᱤᱥ ᱯᱟᱱᱛᱮ ᱢᱮ -pdfjs-current-outline-item-button-label = ᱱᱤᱛᱚᱜᱟᱜ ᱟᱣᱴᱞᱟᱭᱤᱱ ᱡᱟᱱᱤᱥ -pdfjs-findbar-button = - .title = ᱫᱚᱞᱤᱞ ᱨᱮ ᱯᱟᱱᱛᱮ -pdfjs-findbar-button-label = ᱥᱮᱸᱫᱽᱨᱟᱭ ᱢᱮ -pdfjs-additional-layers = ᱵᱟᱹᱲᱛᱤ ᱯᱚᱨᱚᱛᱠᱚ - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page } ᱥᱟᱦᱴᱟ -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } ᱥᱟᱦᱴᱟ ᱨᱮᱭᱟᱜ ᱪᱤᱛᱟᱹᱨ ᱟᱦᱞᱟ - -## Find panel button title and messages - -pdfjs-find-input = - .title = ᱥᱮᱸᱫᱽᱨᱟᱭ ᱢᱮ - .placeholder = ᱫᱚᱞᱤᱞ ᱨᱮ ᱯᱟᱱᱛᱮ ᱢᱮ … -pdfjs-find-previous-button = - .title = ᱟᱭᱟᱛ ᱦᱤᱸᱥ ᱨᱮᱭᱟᱜ ᱯᱟᱹᱦᱤᱞ ᱥᱮᱫᱟᱜ ᱚᱰᱚᱠ ᱧᱟᱢ ᱢᱮ -pdfjs-find-previous-button-label = ᱢᱟᱲᱟᱝᱟᱜ -pdfjs-find-next-button = - .title = ᱟᱭᱟᱛ ᱦᱤᱸᱥ ᱨᱮᱭᱟᱜ ᱤᱱᱟᱹ ᱛᱟᱭᱚᱢ ᱚᱰᱚᱠ ᱧᱟᱢ ᱢᱮ -pdfjs-find-next-button-label = ᱤᱱᱟᱹ ᱛᱟᱭᱚᱢ -pdfjs-find-highlight-checkbox = ᱡᱷᱚᱛᱚ ᱩᱫᱩᱜ ᱨᱟᱠᱟᱵ -pdfjs-find-match-case-checkbox-label = ᱡᱚᱲ ᱠᱟᱛᱷᱟ -pdfjs-find-match-diacritics-checkbox-label = ᱵᱤᱥᱮᱥᱚᱠ ᱠᱚ ᱢᱮᱲᱟᱣ ᱢᱮ -pdfjs-find-entire-word-checkbox-label = ᱡᱷᱚᱛᱚ ᱟᱹᱲᱟᱹᱠᱚ -pdfjs-find-reached-top = ᱫᱚᱞᱤᱞ ᱨᱮᱭᱟᱜ ᱪᱤᱴ ᱨᱮ ᱥᱮᱴᱮᱨ, ᱞᱟᱛᱟᱨ ᱠᱷᱚᱱ ᱞᱮᱛᱟᱲ -pdfjs-find-reached-bottom = ᱫᱚᱞᱤᱞ ᱨᱮᱭᱟᱜ ᱢᱩᱪᱟᱹᱫ ᱨᱮ ᱥᱮᱴᱮᱨ, ᱪᱚᱴ ᱠᱷᱚᱱ ᱞᱮᱛᱟᱲ -pdfjs-find-not-found = ᱛᱚᱯᱚᱞ ᱫᱚᱱᱚᱲ ᱵᱟᱝ ᱧᱟᱢ ᱞᱮᱱᱟ - -## Predefined zoom values - -pdfjs-page-scale-width = ᱥᱟᱦᱴᱟ ᱚᱥᱟᱨ -pdfjs-page-scale-fit = ᱥᱟᱦᱴᱟ ᱠᱷᱟᱯ -pdfjs-page-scale-auto = ᱟᱡᱼᱟᱡ ᱛᱮ ᱦᱩᱰᱤᱧ ᱞᱟᱹᱴᱩ ᱛᱮᱭᱟᱨ -pdfjs-page-scale-actual = ᱴᱷᱤᱠ ᱢᱟᱨᱟᱝ ᱛᱮᱫ -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = { $page } ᱥᱟᱦᱴᱟ - -## Loading indicator messages - -pdfjs-loading-error = PDF ᱞᱟᱫᱮ ᱡᱚᱦᱚᱜ ᱢᱤᱫ ᱵᱷᱩᱞ ᱦᱩᱭ ᱮᱱᱟ ᱾ -pdfjs-invalid-file-error = ᱵᱟᱝ ᱵᱟᱛᱟᱣ ᱟᱨᱵᱟᱝᱠᱷᱟᱱ ᱰᱤᱜᱟᱹᱣ PDF ᱨᱮᱫᱽ ᱾ -pdfjs-missing-file-error = ᱟᱫᱟᱜ PDF ᱨᱮᱫᱽ ᱾ -pdfjs-unexpected-response-error = ᱵᱟᱝᱵᱩᱡᱷ ᱥᱚᱨᱵᱷᱚᱨ ᱛᱮᱞᱟ ᱾ -pdfjs-rendering-error = ᱥᱟᱦᱴᱟ ᱮᱢ ᱡᱚᱦᱚᱠ ᱢᱤᱫ ᱵᱷᱩᱞ ᱦᱩᱭ ᱮᱱᱟ ᱾ - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } ᱢᱚᱱᱛᱚ ᱮᱢ] - -## Password - -pdfjs-password-label = ᱱᱚᱶᱟ PDF ᱨᱮᱫᱽ ᱡᱷᱤᱡᱽ ᱞᱟᱹᱜᱤᱫ ᱫᱟᱱᱟᱝ ᱥᱟᱵᱟᱫᱽ ᱟᱫᱮᱨ ᱢᱮ ᱾ -pdfjs-password-invalid = ᱵᱷᱩᱞ ᱫᱟᱱᱟᱝ ᱥᱟᱵᱟᱫᱽ ᱾ ᱫᱟᱭᱟᱠᱟᱛᱮ ᱫᱩᱦᱲᱟᱹ ᱪᱮᱥᱴᱟᱭ ᱢᱮ ᱾ -pdfjs-password-ok-button = ᱴᱷᱤᱠ -pdfjs-password-cancel-button = ᱵᱟᱹᱰᱨᱟᱹ -pdfjs-web-fonts-disabled = ᱣᱮᱵᱽ ᱪᱤᱠᱤ ᱵᱟᱝ ᱦᱩᱭ ᱦᱚᱪᱚ ᱠᱟᱱᱟ : ᱵᱷᱤᱛᱤᱨ ᱛᱷᱟᱯᱚᱱ PDF ᱪᱤᱠᱤ ᱵᱮᱵᱷᱟᱨ ᱵᱟᱝ ᱦᱩᱭ ᱠᱮᱭᱟ ᱾ - -## Editing - -pdfjs-editor-free-text-button = - .title = ᱚᱞ -pdfjs-editor-free-text-button-label = ᱚᱞ -pdfjs-editor-ink-button = - .title = ᱛᱮᱭᱟᱨ -pdfjs-editor-ink-button-label = ᱛᱮᱭᱟᱨ -pdfjs-editor-stamp-button = - .title = ᱪᱤᱛᱟᱹᱨᱠᱚ ᱥᱮᱞᱮᱫ ᱥᱮ ᱥᱟᱯᱲᱟᱣ ᱢᱮ -pdfjs-editor-stamp-button-label = ᱪᱤᱛᱟᱹᱨᱠᱚ ᱥᱮᱞᱮᱫ ᱥᱮ ᱥᱟᱯᱲᱟᱣ ᱢᱮ -# Editor Parameters -pdfjs-editor-free-text-color-input = ᱨᱚᱝ -pdfjs-editor-free-text-size-input = ᱢᱟᱯ -pdfjs-editor-ink-color-input = ᱨᱚᱝ -pdfjs-editor-ink-thickness-input = ᱢᱚᱴᱟ -pdfjs-editor-ink-opacity-input = ᱟᱨᱯᱟᱨ -pdfjs-editor-stamp-add-image-button = - .title = ᱪᱤᱛᱟᱹᱨ ᱥᱮᱞᱮᱫ ᱢᱮ -pdfjs-editor-stamp-add-image-button-label = ᱪᱤᱛᱟᱹᱨ ᱥᱮᱞᱮᱫ ᱢᱮ -pdfjs-free-text = - .aria-label = ᱚᱞ ᱥᱟᱯᱲᱟᱣᱤᱭᱟᱹ -pdfjs-free-text-default-content = ᱚᱞ ᱮᱛᱦᱚᱵ ᱢᱮ … -pdfjs-ink = - .aria-label = ᱛᱮᱭᱟᱨ ᱥᱟᱯᱲᱟᱣᱤᱭᱟᱹ -pdfjs-ink-canvas = - .aria-label = ᱵᱮᱵᱷᱟᱨᱤᱭᱟᱹ ᱛᱮᱭᱟᱨ ᱠᱟᱫ ᱪᱤᱛᱟᱹᱨ - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/sc/viewer.ftl b/static/pdf.js/locale/sc/viewer.ftl deleted file mode 100644 index a51943c9..00000000 --- a/static/pdf.js/locale/sc/viewer.ftl +++ /dev/null @@ -1,290 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pàgina anteriore -pdfjs-previous-button-label = S'ischeda chi b'est primu -pdfjs-next-button = - .title = Pàgina imbeniente -pdfjs-next-button-label = Imbeniente -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pàgina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = de { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } de { $pagesCount }) -pdfjs-zoom-out-button = - .title = Impitica -pdfjs-zoom-out-button-label = Impitica -pdfjs-zoom-in-button = - .title = Ismànnia -pdfjs-zoom-in-button-label = Ismànnia -pdfjs-zoom-select = - .title = Ismànnia -pdfjs-presentation-mode-button = - .title = Cola a sa modalidade de presentatzione -pdfjs-presentation-mode-button-label = Modalidade de presentatzione -pdfjs-open-file-button = - .title = Aberi s'archìviu -pdfjs-open-file-button-label = Abertu -pdfjs-print-button = - .title = Imprenta -pdfjs-print-button-label = Imprenta -pdfjs-save-button = - .title = Sarva -pdfjs-save-button-label = Sarva -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Iscàrriga -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Iscàrriga -pdfjs-bookmark-button = - .title = Pàgina atuale (ammustra s’URL de sa pàgina atuale) -pdfjs-bookmark-button-label = Pàgina atuale -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Aberi in un’aplicatzione -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Aberi in un’aplicatzione - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Istrumentos -pdfjs-tools-button-label = Istrumentos -pdfjs-first-page-button = - .title = Bae a sa prima pàgina -pdfjs-first-page-button-label = Bae a sa prima pàgina -pdfjs-last-page-button = - .title = Bae a s'ùrtima pàgina -pdfjs-last-page-button-label = Bae a s'ùrtima pàgina -pdfjs-page-rotate-cw-button = - .title = Gira in sensu oràriu -pdfjs-page-rotate-cw-button-label = Gira in sensu oràriu -pdfjs-page-rotate-ccw-button = - .title = Gira in sensu anti-oràriu -pdfjs-page-rotate-ccw-button-label = Gira in sensu anti-oràriu -pdfjs-cursor-text-select-tool-button = - .title = Ativa s'aina de seletzione de testu -pdfjs-cursor-text-select-tool-button-label = Aina de seletzione de testu -pdfjs-cursor-hand-tool-button = - .title = Ativa s'aina de manu -pdfjs-cursor-hand-tool-button-label = Aina de manu -pdfjs-scroll-page-button = - .title = Imprea s'iscurrimentu de pàgina -pdfjs-scroll-page-button-label = Iscurrimentu de pàgina -pdfjs-scroll-vertical-button = - .title = Imprea s'iscurrimentu verticale -pdfjs-scroll-vertical-button-label = Iscurrimentu verticale -pdfjs-scroll-horizontal-button = - .title = Imprea s'iscurrimentu orizontale -pdfjs-scroll-horizontal-button-label = Iscurrimentu orizontale -pdfjs-scroll-wrapped-button = - .title = Imprea s'iscurrimentu continu -pdfjs-scroll-wrapped-button-label = Iscurrimentu continu - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Propiedades de su documentu… -pdfjs-document-properties-button-label = Propiedades de su documentu… -pdfjs-document-properties-file-name = Nòmine de s'archìviu: -pdfjs-document-properties-file-size = Mannària de s'archìviu: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Tìtulu: -pdfjs-document-properties-author = Autoria: -pdfjs-document-properties-subject = Ogetu: -pdfjs-document-properties-keywords = Faeddos crae: -pdfjs-document-properties-creation-date = Data de creatzione: -pdfjs-document-properties-modification-date = Data de modìfica: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Creatzione: -pdfjs-document-properties-producer = Produtore de PDF: -pdfjs-document-properties-version = Versione de PDF: -pdfjs-document-properties-page-count = Contu de pàginas: -pdfjs-document-properties-page-size = Mannària de sa pàgina: -pdfjs-document-properties-page-size-unit-inches = pòddighes -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = verticale -pdfjs-document-properties-page-size-orientation-landscape = orizontale -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Lìtera -pdfjs-document-properties-page-size-name-legal = Legale - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Visualizatzione web lestra: -pdfjs-document-properties-linearized-yes = Eja -pdfjs-document-properties-linearized-no = Nono -pdfjs-document-properties-close-button = Serra - -## Print - -pdfjs-print-progress-message = Aparitzende s'imprenta de su documentu… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Cantzella -pdfjs-printing-not-supported = Atentzione: s'imprenta no est funtzionende de su totu in custu navigadore. -pdfjs-printing-not-ready = Atentzione: su PDF no est istadu carrigadu de su totu pro s'imprenta. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Ativa/disativa sa barra laterale -pdfjs-toggle-sidebar-notification-button = - .title = Ativa/disativa sa barra laterale (su documentu cuntenet un'ischema, alligongiados o livellos) -pdfjs-toggle-sidebar-button-label = Ativa/disativa sa barra laterale -pdfjs-document-outline-button-label = Ischema de su documentu -pdfjs-attachments-button = - .title = Ammustra alligongiados -pdfjs-attachments-button-label = Alliongiados -pdfjs-layers-button = - .title = Ammustra livellos (clic dòpiu pro ripristinare totu is livellos a s'istadu predefinidu) -pdfjs-layers-button-label = Livellos -pdfjs-thumbs-button = - .title = Ammustra miniaturas -pdfjs-thumbs-button-label = Miniaturas -pdfjs-current-outline-item-button = - .title = Agata s'elementu atuale de s'ischema -pdfjs-current-outline-item-button-label = Elementu atuale de s'ischema -pdfjs-findbar-button = - .title = Agata in su documentu -pdfjs-findbar-button-label = Agata -pdfjs-additional-layers = Livellos additzionales - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pàgina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura de sa pàgina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Agata - .placeholder = Agata in su documentu… -pdfjs-find-previous-button = - .title = Agata s'ocurrèntzia pretzedente de sa fràsia -pdfjs-find-previous-button-label = S'ischeda chi b'est primu -pdfjs-find-next-button = - .title = Agata s'ocurrèntzia imbeniente de sa fràsia -pdfjs-find-next-button-label = Imbeniente -pdfjs-find-highlight-checkbox = Evidèntzia totu -pdfjs-find-match-case-checkbox-label = Distinghe intre majùsculas e minùsculas -pdfjs-find-match-diacritics-checkbox-label = Respeta is diacrìticos -pdfjs-find-entire-word-checkbox-label = Faeddos intreos -pdfjs-find-reached-top = S'est lòmpidu a su cumintzu de su documentu, si sighit dae su bàsciu -pdfjs-find-reached-bottom = Acabbu de su documentu, si sighit dae s'artu -pdfjs-find-not-found = Testu no agatadu - -## Predefined zoom values - -pdfjs-page-scale-auto = Ingrandimentu automàticu -pdfjs-page-scale-actual = Mannària reale -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Pàgina { $page } - -## Loading indicator messages - -pdfjs-loading-error = Faddina in sa càrriga de su PDF. -pdfjs-invalid-file-error = Archìviu PDF non vàlidu o corrùmpidu. -pdfjs-missing-file-error = Ammancat s'archìviu PDF. -pdfjs-unexpected-response-error = Risposta imprevista de su serbidore. -pdfjs-rendering-error = Faddina in sa visualizatzione de sa pàgina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } - -## Password - -pdfjs-password-label = Inserta sa crae pro abèrrere custu archìviu PDF. -pdfjs-password-invalid = Sa crae no est curreta. Torra a nche proare. -pdfjs-password-ok-button = Andat bene -pdfjs-password-cancel-button = Cantzella -pdfjs-web-fonts-disabled = Is tipografias web sunt disativadas: is tipografias incrustadas a su PDF non podent èssere impreadas. - -## Editing - -pdfjs-editor-free-text-button = - .title = Testu -pdfjs-editor-free-text-button-label = Testu -pdfjs-editor-ink-button = - .title = Disinnu -pdfjs-editor-ink-button-label = Disinnu -pdfjs-editor-stamp-button = - .title = Agiunghe o modìfica immàgines -pdfjs-editor-stamp-button-label = Agiunghe o modìfica immàgines -# Editor Parameters -pdfjs-editor-free-text-color-input = Colore -pdfjs-editor-free-text-size-input = Mannària -pdfjs-editor-ink-color-input = Colore -pdfjs-editor-ink-thickness-input = Grussària -pdfjs-editor-stamp-add-image-button = - .title = Agiunghe un’immàgine -pdfjs-editor-stamp-add-image-button-label = Agiunghe un’immàgine -pdfjs-free-text = - .aria-label = Editore de testu -pdfjs-free-text-default-content = Cumintza a iscrìere… -pdfjs-ink = - .aria-label = Editore de disinnos -pdfjs-ink-canvas = - .aria-label = Immàgine creada dae s’utente - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/scn/viewer.ftl b/static/pdf.js/locale/scn/viewer.ftl deleted file mode 100644 index a3c7c038..00000000 --- a/static/pdf.js/locale/scn/viewer.ftl +++ /dev/null @@ -1,74 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-zoom-out-button = - .title = Cchiù nicu -pdfjs-zoom-out-button-label = Cchiù nicu -pdfjs-zoom-in-button = - .title = Cchiù granni -pdfjs-zoom-in-button-label = Cchiù granni - -## Secondary toolbar and context menu - - -## Document properties dialog - - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Vista web lesta: -pdfjs-document-properties-linearized-yes = Se - -## Print - -pdfjs-print-progress-close-button = Sfai - -## Tooltips and alt text for side panel toolbar buttons - - -## Thumbnails panel item (tooltip and alt text for images) - - -## Find panel button title and messages - - -## Predefined zoom values - -pdfjs-page-scale-width = Larghizza dâ pàggina - -## PDF page - - -## Loading indicator messages - - -## Annotations - - -## Password - -pdfjs-password-cancel-button = Sfai - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/sco/viewer.ftl b/static/pdf.js/locale/sco/viewer.ftl deleted file mode 100644 index 6f71c47a..00000000 --- a/static/pdf.js/locale/sco/viewer.ftl +++ /dev/null @@ -1,264 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Page Afore -pdfjs-previous-button-label = Previous -pdfjs-next-button = - .title = Page Efter -pdfjs-next-button-label = Neist -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Page -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = o { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } o { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zoom Oot -pdfjs-zoom-out-button-label = Zoom Oot -pdfjs-zoom-in-button = - .title = Zoom In -pdfjs-zoom-in-button-label = Zoom In -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Flit tae Presentation Mode -pdfjs-presentation-mode-button-label = Presentation Mode -pdfjs-open-file-button = - .title = Open File -pdfjs-open-file-button-label = Open -pdfjs-print-button = - .title = Prent -pdfjs-print-button-label = Prent - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Tools -pdfjs-tools-button-label = Tools -pdfjs-first-page-button = - .title = Gang tae First Page -pdfjs-first-page-button-label = Gang tae First Page -pdfjs-last-page-button = - .title = Gang tae Lest Page -pdfjs-last-page-button-label = Gang tae Lest Page -pdfjs-page-rotate-cw-button = - .title = Rotate Clockwise -pdfjs-page-rotate-cw-button-label = Rotate Clockwise -pdfjs-page-rotate-ccw-button = - .title = Rotate Coonterclockwise -pdfjs-page-rotate-ccw-button-label = Rotate Coonterclockwise -pdfjs-cursor-text-select-tool-button = - .title = Enable Text Walin Tool -pdfjs-cursor-text-select-tool-button-label = Text Walin Tool -pdfjs-cursor-hand-tool-button = - .title = Enable Haun Tool -pdfjs-cursor-hand-tool-button-label = Haun Tool -pdfjs-scroll-vertical-button = - .title = Yaise Vertical Scrollin -pdfjs-scroll-vertical-button-label = Vertical Scrollin -pdfjs-scroll-horizontal-button = - .title = Yaise Horizontal Scrollin -pdfjs-scroll-horizontal-button-label = Horizontal Scrollin -pdfjs-scroll-wrapped-button = - .title = Yaise Wrapped Scrollin -pdfjs-scroll-wrapped-button-label = Wrapped Scrollin -pdfjs-spread-none-button = - .title = Dinnae jyn page spreids -pdfjs-spread-none-button-label = Nae Spreids -pdfjs-spread-odd-button = - .title = Jyn page spreids stertin wi odd-numbered pages -pdfjs-spread-odd-button-label = Odd Spreids -pdfjs-spread-even-button = - .title = Jyn page spreids stertin wi even-numbered pages -pdfjs-spread-even-button-label = Even Spreids - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Document Properties… -pdfjs-document-properties-button-label = Document Properties… -pdfjs-document-properties-file-name = File nemme: -pdfjs-document-properties-file-size = File size: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Title: -pdfjs-document-properties-author = Author: -pdfjs-document-properties-subject = Subjeck: -pdfjs-document-properties-keywords = Keywirds: -pdfjs-document-properties-creation-date = Date o Makkin: -pdfjs-document-properties-modification-date = Date o Chynges: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Makker: -pdfjs-document-properties-producer = PDF Producer: -pdfjs-document-properties-version = PDF Version: -pdfjs-document-properties-page-count = Page Coont: -pdfjs-document-properties-page-size = Page Size: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portrait -pdfjs-document-properties-page-size-orientation-landscape = landscape -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Wab View: -pdfjs-document-properties-linearized-yes = Aye -pdfjs-document-properties-linearized-no = Naw -pdfjs-document-properties-close-button = Sneck - -## Print - -pdfjs-print-progress-message = Reddin document fur prentin… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Stap -pdfjs-printing-not-supported = Tak tent: Prentin isnae richt supportit by this stravaiger. -pdfjs-printing-not-ready = Tak tent: The PDF isnae richt loadit fur prentin. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Toggle Sidebaur -pdfjs-toggle-sidebar-notification-button = - .title = Toggle Sidebaur (document conteens ootline/attachments/layers) -pdfjs-toggle-sidebar-button-label = Toggle Sidebaur -pdfjs-document-outline-button = - .title = Kythe Document Ootline (double-click fur tae oot-fauld/in-fauld aw items) -pdfjs-document-outline-button-label = Document Ootline -pdfjs-attachments-button = - .title = Kythe Attachments -pdfjs-attachments-button-label = Attachments -pdfjs-layers-button = - .title = Kythe Layers (double-click fur tae reset aw layers tae the staunart state) -pdfjs-layers-button-label = Layers -pdfjs-thumbs-button = - .title = Kythe Thumbnails -pdfjs-thumbs-button-label = Thumbnails -pdfjs-current-outline-item-button = - .title = Find Current Ootline Item -pdfjs-current-outline-item-button-label = Current Ootline Item -pdfjs-findbar-button = - .title = Find in Document -pdfjs-findbar-button-label = Find -pdfjs-additional-layers = Mair Layers - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Page { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Thumbnail o Page { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Find - .placeholder = Find in document… -pdfjs-find-previous-button = - .title = Airt oot the last time this phrase occurred -pdfjs-find-previous-button-label = Previous -pdfjs-find-next-button = - .title = Airt oot the neist time this phrase occurs -pdfjs-find-next-button-label = Neist -pdfjs-find-highlight-checkbox = Highlicht aw -pdfjs-find-match-case-checkbox-label = Match case -pdfjs-find-entire-word-checkbox-label = Hale Wirds -pdfjs-find-reached-top = Raxed tap o document, went on fae the dowp end -pdfjs-find-reached-bottom = Raxed end o document, went on fae the tap -pdfjs-find-not-found = Phrase no fund - -## Predefined zoom values - -pdfjs-page-scale-width = Page Width -pdfjs-page-scale-fit = Page Fit -pdfjs-page-scale-auto = Automatic Zoom -pdfjs-page-scale-actual = Actual Size -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Page { $page } - -## Loading indicator messages - -pdfjs-loading-error = An mishanter tuik place while loadin the PDF. -pdfjs-invalid-file-error = No suithfest or camshauchlet PDF file. -pdfjs-missing-file-error = PDF file tint. -pdfjs-unexpected-response-error = Unexpectit server repone. -pdfjs-rendering-error = A mishanter tuik place while renderin the page. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Inpit the passwird fur tae open this PDF file. -pdfjs-password-invalid = Passwird no suithfest. Gonnae gie it anither shot. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Stap -pdfjs-web-fonts-disabled = Wab fonts are disabled: cannae yaise embeddit PDF fonts. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/si/viewer.ftl b/static/pdf.js/locale/si/viewer.ftl deleted file mode 100644 index 28387298..00000000 --- a/static/pdf.js/locale/si/viewer.ftl +++ /dev/null @@ -1,253 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = කලින් පිටුව -pdfjs-previous-button-label = කලින් -pdfjs-next-button = - .title = ඊළඟ පිටුව -pdfjs-next-button-label = ඊළඟ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = පිටුව -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } / { $pagesCount }) -pdfjs-zoom-out-button = - .title = කුඩාලනය -pdfjs-zoom-out-button-label = කුඩාලනය -pdfjs-zoom-in-button = - .title = විශාලනය -pdfjs-zoom-in-button-label = විශාලනය -pdfjs-zoom-select = - .title = විශාල කරන්න -pdfjs-presentation-mode-button = - .title = සමර්පණ ප්‍රකාරය වෙත මාරුවන්න -pdfjs-presentation-mode-button-label = සමර්පණ ප්‍රකාරය -pdfjs-open-file-button = - .title = ගොනුව අරින්න -pdfjs-open-file-button-label = අරින්න -pdfjs-print-button = - .title = මුද්‍රණය -pdfjs-print-button-label = මුද්‍රණය -pdfjs-save-button = - .title = සුරකින්න -pdfjs-save-button-label = සුරකින්න -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = බාගන්න -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = බාගන්න -pdfjs-bookmark-button-label = පවතින පිටුව -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = යෙදුමෙහි අරින්න -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = යෙදුමෙහි අරින්න - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = මෙවලම් -pdfjs-tools-button-label = මෙවලම් -pdfjs-first-page-button = - .title = මුල් පිටුවට යන්න -pdfjs-first-page-button-label = මුල් පිටුවට යන්න -pdfjs-last-page-button = - .title = අවසන් පිටුවට යන්න -pdfjs-last-page-button-label = අවසන් පිටුවට යන්න -pdfjs-cursor-text-select-tool-button = - .title = පෙළ තේරීමේ මෙවලම සබල කරන්න -pdfjs-cursor-text-select-tool-button-label = පෙළ තේරීමේ මෙවලම -pdfjs-cursor-hand-tool-button = - .title = අත් මෙවලම සබල කරන්න -pdfjs-cursor-hand-tool-button-label = අත් මෙවලම -pdfjs-scroll-page-button = - .title = පිටුව අනුචලනය භාවිතය -pdfjs-scroll-page-button-label = පිටුව අනුචලනය -pdfjs-scroll-vertical-button = - .title = සිරස් අනුචලනය භාවිතය -pdfjs-scroll-vertical-button-label = සිරස් අනුචලනය -pdfjs-scroll-horizontal-button = - .title = තිරස් අනුචලනය භාවිතය -pdfjs-scroll-horizontal-button-label = තිරස් අනුචලනය - -## Document properties dialog - -pdfjs-document-properties-button = - .title = ලේඛනයේ ගුණාංග… -pdfjs-document-properties-button-label = ලේඛනයේ ගුණාංග… -pdfjs-document-properties-file-name = ගොනුවේ නම: -pdfjs-document-properties-file-size = ගොනුවේ ප්‍රමාණය: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = කි.බ. { $size_kb } (බයිට { $size_b }) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = මෙ.බ. { $size_mb } (බයිට { $size_b }) -pdfjs-document-properties-title = සිරැසිය: -pdfjs-document-properties-author = කතෘ: -pdfjs-document-properties-subject = මාතෘකාව: -pdfjs-document-properties-keywords = මූල පද: -pdfjs-document-properties-creation-date = සෑදූ දිනය: -pdfjs-document-properties-modification-date = සංශෝධිත දිනය: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = නිර්මාතෘ: -pdfjs-document-properties-producer = පීඩීඑෆ් සම්පාදක: -pdfjs-document-properties-version = පීඩීඑෆ් අනුවාදය: -pdfjs-document-properties-page-count = පිටු ගණන: -pdfjs-document-properties-page-size = පිටුවේ තරම: -pdfjs-document-properties-page-size-unit-inches = අඟල් -pdfjs-document-properties-page-size-unit-millimeters = මි.මී. -pdfjs-document-properties-page-size-orientation-portrait = සිරස් -pdfjs-document-properties-page-size-orientation-landscape = තිරස් -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width }×{ $height }{ $unit }{ $name }{ $orientation } - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = වේගවත් වියමන දැක්ම: -pdfjs-document-properties-linearized-yes = ඔව් -pdfjs-document-properties-linearized-no = නැහැ -pdfjs-document-properties-close-button = වසන්න - -## Print - -pdfjs-print-progress-message = මුද්‍රණය සඳහා ලේඛනය සූදානම් වෙමින්… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = අවලංගු කරන්න -pdfjs-printing-not-supported = අවවාදයයි: මෙම අතිරික්සුව මුද්‍රණය සඳහා හොඳින් සහාය නොදක්වයි. -pdfjs-printing-not-ready = අවවාදයයි: මුද්‍රණයට පීඩීඑෆ් ගොනුව සම්පූර්ණයෙන් පූරණය වී නැත. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-document-outline-button-label = ලේඛනයේ වටසන -pdfjs-attachments-button = - .title = ඇමුණුම් පෙන්වන්න -pdfjs-attachments-button-label = ඇමුණුම් -pdfjs-layers-button = - .title = ස්තර පෙන්වන්න (සියළු ස්තර පෙරනිමි තත්‍වයට යළි සැකසීමට දෙවරක් ඔබන්න) -pdfjs-layers-button-label = ස්තර -pdfjs-thumbs-button = - .title = සිඟිති රූ පෙන්වන්න -pdfjs-thumbs-button-label = සිඟිති රූ -pdfjs-findbar-button = - .title = ලේඛනයෙහි සොයන්න -pdfjs-findbar-button-label = සොයන්න -pdfjs-additional-layers = අතිරේක ස්තර - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = පිටුව { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = පිටුවේ සිඟිත රූව { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = සොයන්න - .placeholder = ලේඛනයේ සොයන්න… -pdfjs-find-previous-button = - .title = මෙම වැකිකඩ කලින් යෙදුණු ස්ථානය සොයන්න -pdfjs-find-previous-button-label = කලින් -pdfjs-find-next-button = - .title = මෙම වැකිකඩ ඊළඟට යෙදෙන ස්ථානය සොයන්න -pdfjs-find-next-button-label = ඊළඟ -pdfjs-find-highlight-checkbox = සියල්ල උද්දීපනය -pdfjs-find-entire-word-checkbox-label = සමස්ත වචන -pdfjs-find-reached-top = ලේඛනයේ මුදුනට ළඟා විය, පහළ සිට ඉහළට -pdfjs-find-reached-bottom = ලේඛනයේ අවසානයට ළඟා විය, ඉහළ සිට පහළට -pdfjs-find-not-found = වැකිකඩ හමු නොවිණි - -## Predefined zoom values - -pdfjs-page-scale-width = පිටුවේ පළල -pdfjs-page-scale-auto = ස්වයංක්‍රීය විශාලනය -pdfjs-page-scale-actual = සැබෑ ප්‍රමාණය -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = පිටුව { $page } - -## Loading indicator messages - -pdfjs-loading-error = පීඩීඑෆ් පූරණය කිරීමේදී දෝෂයක් සිදු විය. -pdfjs-invalid-file-error = වලංගු නොවන හෝ හානිවූ පීඩීඑෆ් ගොනුවකි. -pdfjs-missing-file-error = මඟහැරුණු පීඩීඑෆ් ගොනුවකි. -pdfjs-unexpected-response-error = අනපේක්‍ෂිත සේවාදායක ප්‍රතිචාරයකි. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } - -## Password - -pdfjs-password-label = මෙම පීඩීඑෆ් ගොනුව විවෘත කිරීමට මුරපදය යොදන්න. -pdfjs-password-invalid = වැරදි මුරපදයකි. නැවත උත්සාහ කරන්න. -pdfjs-password-ok-button = හරි -pdfjs-password-cancel-button = අවලංගු -pdfjs-web-fonts-disabled = වියමන අකුරු අබලයි: පීඩීඑෆ් වෙත කාවැද්දූ රුවකුරු භාවිතා කළ නොහැකිය. - -## Editing - -pdfjs-editor-free-text-button = - .title = පෙළ -pdfjs-editor-free-text-button-label = පෙළ -pdfjs-editor-ink-button = - .title = අඳින්න -pdfjs-editor-ink-button-label = අඳින්න -# Editor Parameters -pdfjs-editor-free-text-color-input = වර්ණය -pdfjs-editor-free-text-size-input = තරම -pdfjs-editor-ink-color-input = වර්ණය -pdfjs-editor-ink-thickness-input = ඝණකම -pdfjs-free-text = - .aria-label = වදන් සකසනය -pdfjs-free-text-default-content = ලිවීීම අරඹන්න… - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/si/viewer.properties b/static/pdf.js/locale/si/viewer.properties new file mode 100644 index 00000000..80cae85f --- /dev/null +++ b/static/pdf.js/locale/si/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=මීට පෙර පිටුව +previous_label=පෙර +next.title=මීළඟ පිටුව +next_label=මීළඟ + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=පිටුව: +page_of={{pageCount}} කින් + +zoom_out.title=කුඩා කරන්න +zoom_out_label=කුඩා කරන්න +zoom_in.title=විශාල කරන්න +zoom_in_label=විශාල කරන්න +zoom.title=විශාලණය +presentation_mode.title=ඉදිරිපත්කිරීම් ප්‍රකාරය වෙත මාරුවන්න +presentation_mode_label=ඉදිරිපත්කිරීම් ප්‍රකාරය +open_file.title=ගොනුව විවෘත කරන්න +open_file_label=විවෘත කරන්න +print.title=මුද්‍රණය +print_label=මුද්‍රණය +download.title=බාගන්න +download_label=බාගන්න +bookmark.title=දැනට ඇති දසුන (පිටපත් කරන්න හෝ නව කවුළුවක විවෘත කරන්න) +bookmark_label=දැනට ඇති දසුන + +# Secondary toolbar and context menu +tools.title=මෙවලම් +tools_label=මෙවලම් +first_page.title=මුල් පිටුවට යන්න +first_page.label=මුල් පිටුවට යන්න +first_page_label=මුල් පිටුවට යන්න +last_page.title=අවසන් පිටුවට යන්න +last_page.label=අවසන් පිටුවට යන්න +last_page_label=අවසන් පිටුවට යන්න +page_rotate_cw.title=දක්ශිණාවර්තව භ්‍රමණය +page_rotate_cw.label=දක්ශිණාවර්තව භ්‍රමණය +page_rotate_cw_label=දක්ශිණාවර්තව භ්‍රමණය +page_rotate_ccw.title=වාමාවර්තව භ්‍රමණය +page_rotate_ccw.label=වාමාවර්තව භ්‍රමණය +page_rotate_ccw_label=වාමාවර්තව භ්‍රමණය + +hand_tool_enable.title=හස්ත මෙවලම සක්‍රීය +hand_tool_enable_label=හස්ත මෙවලම සක්‍රීය +hand_tool_disable.title=හස්ත මෙවලම අක්‍රීය +hand_tool_disable_label=හස්ත මෙවලම අක්‍රීය + +# Document properties dialog box +document_properties.title=ලේඛන වත්කම්... +document_properties_label=ලේඛන වත්කම්... +document_properties_file_name=ගොනු නම: +document_properties_file_size=ගොනු ප්‍රමාණය: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} බයිට) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} බයිට) +document_properties_title=සිරස්තලය: +document_properties_author=කතෲ +document_properties_subject=මාතෘකාව: +document_properties_keywords=යතුරු වදන්: +document_properties_creation_date=නිර්මිත දිනය: +document_properties_modification_date=වෙනස්කල දිනය: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=නිර්මාපක: +document_properties_producer=PDF නිශ්පාදක: +document_properties_version=PDF නිකුතුව: +document_properties_page_count=පිටු ගණන: +document_properties_close=වසන්න + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=පැති තීරුවට මාරුවන්න +toggle_sidebar_label=පැති තීරුවට මාරුවන්න +outline.title=ලේඛනයේ පිට මායිම පෙන්වන්න +outline_label=ලේඛනයේ පිට මායිම +attachments.title=ඇමිණුම් පෙන්වන්න +attachments_label=ඇමිණුම් +thumbs.title=සිඟිති රූ පෙන්වන්න +thumbs_label=සිඟිති රූ +findbar.title=ලේඛනය තුළ සොයන්න +findbar_label=සොයන්න + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=පිටුව {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=පිටුවෙ සිඟිත රූව {{page}} + +# Find panel button title and messages +find_label=සොයන්න: +find_previous.title=මේ වාක්‍ය ඛණ්ඩය මීට පෙර යෙදුණු ස්ථානය සොයන්න +find_previous_label=පෙර: +find_next.title=මේ වාක්‍ය ඛණ්ඩය මීළඟට යෙදෙන ස්ථානය සොයන්න +find_next_label=මීළඟ +find_highlight=සියල්ල උද්දීපනය +find_match_case_label=අකුරු ගළපන්න +find_reached_top=පිටුවේ ඉහළ කෙළවරට ලගාවිය, පහළ සිට ඉදිරියට යමින් +find_reached_bottom=පිටුවේ පහළ කෙළවරට ලගාවිය, ඉහළ සිට ඉදිරියට යමින් +find_not_found=ඔබ සෙව් වචන හමු නොවීය + +# Error panel labels +error_more_info=බොහෝ තොරතුරු +error_less_info=අවම තොරතුරු +error_close=වසන්න +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (නිකුතුව: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=පණිවිඩය: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ගොනුව: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=පේළිය: {{line}} +rendering_error=පිටුව රෙන්ඩර් විමේදි ගැටලුවක් හට ගැනුණි. + +# Predefined zoom values +page_scale_width=පිටුවේ පළල +page_scale_fit=පිටුවට සුදුසු ලෙස +page_scale_auto=ස්වයංක්‍රීය විශාලණය +page_scale_actual=නියමිත ප්‍රමාණය +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=දෝෂය +loading_error=PDF පූරණය විමේදි දෝෂයක් හට ගැනුණි. +invalid_file_error=දූශිත හෝ සාවද්‍ය PDF ගොනුව. +missing_file_error=නැතිවූ PDF ගොනුව. +unexpected_response_error=බලාපොරොත්තු නොවූ සේවාදායක ප්‍රතිචාරය. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} විස්තරය] +password_label=මෙම PDF ගොනුව විවෘත කිරීමට මුරපදය ඇතුළත් කරන්න. +password_invalid=වැරදි මුරපදයක්. කරුණාකර නැවත උත්සහ කරන්න. +password_ok=හරි +password_cancel=එපා + +printing_not_supported=අවවාදයයි: මෙම ගවේශකය මුද්‍රණය සඳහා සම්පූර්ණයෙන් සහය නොදක්වයි. +printing_not_ready=අවවාදයයි: මුද්‍රණය සඳහා PDF සම්පූර්ණයෙන් පූර්ණය වී නොමැත. +web_fonts_disabled=ජාල අකුරු අක්‍රීයයි: තිළැලි PDF අකුරු භාවිත කළ නොහැක. +document_colors_disabled=PDF ලේඛනයට ඔවුන්ගේම වර්ණ භාවිතයට ඉඩ නොලැබේ: 'පිටු වෙත ඔවුන්ගේම වර්ණ භාවිතයට ඉඩදෙන්න' ගවේශකය මත අක්‍රීය කර ඇත. diff --git a/static/pdf.js/locale/sk/viewer.ftl b/static/pdf.js/locale/sk/viewer.ftl deleted file mode 100644 index 07a0c5ef..00000000 --- a/static/pdf.js/locale/sk/viewer.ftl +++ /dev/null @@ -1,406 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Predchádzajúca strana -pdfjs-previous-button-label = Predchádzajúca -pdfjs-next-button = - .title = Nasledujúca strana -pdfjs-next-button-label = Nasledujúca -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Strana -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = z { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } z { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zmenšiť veľkosť -pdfjs-zoom-out-button-label = Zmenšiť veľkosť -pdfjs-zoom-in-button = - .title = Zväčšiť veľkosť -pdfjs-zoom-in-button-label = Zväčšiť veľkosť -pdfjs-zoom-select = - .title = Nastavenie veľkosti -pdfjs-presentation-mode-button = - .title = Prepnúť na režim prezentácie -pdfjs-presentation-mode-button-label = Režim prezentácie -pdfjs-open-file-button = - .title = Otvoriť súbor -pdfjs-open-file-button-label = Otvoriť -pdfjs-print-button = - .title = Tlačiť -pdfjs-print-button-label = Tlačiť -pdfjs-save-button = - .title = Uložiť -pdfjs-save-button-label = Uložiť -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Stiahnuť -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Stiahnuť -pdfjs-bookmark-button = - .title = Aktuálna stránka (zobraziť adresu URL z aktuálnej stránky) -pdfjs-bookmark-button-label = Aktuálna stránka -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Otvoriť v aplikácii -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Otvoriť v aplikácii - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Nástroje -pdfjs-tools-button-label = Nástroje -pdfjs-first-page-button = - .title = Prejsť na prvú stranu -pdfjs-first-page-button-label = Prejsť na prvú stranu -pdfjs-last-page-button = - .title = Prejsť na poslednú stranu -pdfjs-last-page-button-label = Prejsť na poslednú stranu -pdfjs-page-rotate-cw-button = - .title = Otočiť v smere hodinových ručičiek -pdfjs-page-rotate-cw-button-label = Otočiť v smere hodinových ručičiek -pdfjs-page-rotate-ccw-button = - .title = Otočiť proti smeru hodinových ručičiek -pdfjs-page-rotate-ccw-button-label = Otočiť proti smeru hodinových ručičiek -pdfjs-cursor-text-select-tool-button = - .title = Povoliť výber textu -pdfjs-cursor-text-select-tool-button-label = Výber textu -pdfjs-cursor-hand-tool-button = - .title = Povoliť nástroj ruka -pdfjs-cursor-hand-tool-button-label = Nástroj ruka -pdfjs-scroll-page-button = - .title = Použiť rolovanie po stránkach -pdfjs-scroll-page-button-label = Rolovanie po stránkach -pdfjs-scroll-vertical-button = - .title = Používať zvislé posúvanie -pdfjs-scroll-vertical-button-label = Zvislé posúvanie -pdfjs-scroll-horizontal-button = - .title = Používať vodorovné posúvanie -pdfjs-scroll-horizontal-button-label = Vodorovné posúvanie -pdfjs-scroll-wrapped-button = - .title = Použiť postupné posúvanie -pdfjs-scroll-wrapped-button-label = Postupné posúvanie -pdfjs-spread-none-button = - .title = Nezdružovať stránky -pdfjs-spread-none-button-label = Žiadne združovanie -pdfjs-spread-odd-button = - .title = Združí stránky a umiestni nepárne stránky vľavo -pdfjs-spread-odd-button-label = Združiť stránky (nepárne vľavo) -pdfjs-spread-even-button = - .title = Združí stránky a umiestni párne stránky vľavo -pdfjs-spread-even-button-label = Združiť stránky (párne vľavo) - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Vlastnosti dokumentu… -pdfjs-document-properties-button-label = Vlastnosti dokumentu… -pdfjs-document-properties-file-name = Názov súboru: -pdfjs-document-properties-file-size = Veľkosť súboru: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kB ({ $size_b } bajtov) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bajtov) -pdfjs-document-properties-title = Názov: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Predmet: -pdfjs-document-properties-keywords = Kľúčové slová: -pdfjs-document-properties-creation-date = Dátum vytvorenia: -pdfjs-document-properties-modification-date = Dátum úpravy: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Aplikácia: -pdfjs-document-properties-producer = Tvorca PDF: -pdfjs-document-properties-version = Verzia PDF: -pdfjs-document-properties-page-count = Počet strán: -pdfjs-document-properties-page-size = Veľkosť stránky: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = na výšku -pdfjs-document-properties-page-size-orientation-landscape = na šírku -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = List -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Rýchle zobrazovanie z webu: -pdfjs-document-properties-linearized-yes = Áno -pdfjs-document-properties-linearized-no = Nie -pdfjs-document-properties-close-button = Zavrieť - -## Print - -pdfjs-print-progress-message = Príprava dokumentu na tlač… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress } % -pdfjs-print-progress-close-button = Zrušiť -pdfjs-printing-not-supported = Upozornenie: tlač nie je v tomto prehliadači plne podporovaná. -pdfjs-printing-not-ready = Upozornenie: súbor PDF nie je plne načítaný pre tlač. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Prepnúť bočný panel -pdfjs-toggle-sidebar-notification-button = - .title = Prepnúť bočný panel (dokument obsahuje osnovu/prílohy/vrstvy) -pdfjs-toggle-sidebar-button-label = Prepnúť bočný panel -pdfjs-document-outline-button = - .title = Zobraziť osnovu dokumentu (dvojitým kliknutím rozbalíte/zbalíte všetky položky) -pdfjs-document-outline-button-label = Osnova dokumentu -pdfjs-attachments-button = - .title = Zobraziť prílohy -pdfjs-attachments-button-label = Prílohy -pdfjs-layers-button = - .title = Zobraziť vrstvy (dvojitým kliknutím uvediete všetky vrstvy do pôvodného stavu) -pdfjs-layers-button-label = Vrstvy -pdfjs-thumbs-button = - .title = Zobraziť miniatúry -pdfjs-thumbs-button-label = Miniatúry -pdfjs-current-outline-item-button = - .title = Nájsť aktuálnu položku v osnove -pdfjs-current-outline-item-button-label = Aktuálna položka v osnove -pdfjs-findbar-button = - .title = Hľadať v dokumente -pdfjs-findbar-button-label = Hľadať -pdfjs-additional-layers = Ďalšie vrstvy - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Strana { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatúra strany { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Hľadať - .placeholder = Hľadať v dokumente… -pdfjs-find-previous-button = - .title = Vyhľadať predchádzajúci výskyt reťazca -pdfjs-find-previous-button-label = Predchádzajúce -pdfjs-find-next-button = - .title = Vyhľadať ďalší výskyt reťazca -pdfjs-find-next-button-label = Ďalšie -pdfjs-find-highlight-checkbox = Zvýrazniť všetky -pdfjs-find-match-case-checkbox-label = Rozlišovať veľkosť písmen -pdfjs-find-match-diacritics-checkbox-label = Rozlišovať diakritiku -pdfjs-find-entire-word-checkbox-label = Celé slová -pdfjs-find-reached-top = Bol dosiahnutý začiatok stránky, pokračuje sa od konca -pdfjs-find-reached-bottom = Bol dosiahnutý koniec stránky, pokračuje sa od začiatku -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] Výskyt { $current } z { $total } - [few] Výskyt { $current } z { $total } - [many] Výskyt { $current } z { $total } - *[other] Výskyt { $current } z { $total } - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Viac ako { $limit } výskyt - [few] Viac ako { $limit } výskyty - [many] Viac ako { $limit } výskytov - *[other] Viac ako { $limit } výskytov - } -pdfjs-find-not-found = Výraz nebol nájdený - -## Predefined zoom values - -pdfjs-page-scale-width = Na šírku strany -pdfjs-page-scale-fit = Na veľkosť strany -pdfjs-page-scale-auto = Automatická veľkosť -pdfjs-page-scale-actual = Skutočná veľkosť -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale } % - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Strana { $page } - -## Loading indicator messages - -pdfjs-loading-error = Počas načítavania dokumentu PDF sa vyskytla chyba. -pdfjs-invalid-file-error = Neplatný alebo poškodený súbor PDF. -pdfjs-missing-file-error = Chýbajúci súbor PDF. -pdfjs-unexpected-response-error = Neočakávaná odpoveď zo servera. -pdfjs-rendering-error = Pri vykresľovaní stránky sa vyskytla chyba. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotácia typu { $type }] - -## Password - -pdfjs-password-label = Ak chcete otvoriť tento súbor PDF, zadajte jeho heslo. -pdfjs-password-invalid = Heslo nie je platné. Skúste to znova. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Zrušiť -pdfjs-web-fonts-disabled = Webové písma sú vypnuté: nie je možné použiť písma vložené do súboru PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Kresliť -pdfjs-editor-ink-button-label = Kresliť -pdfjs-editor-stamp-button = - .title = Pridať alebo upraviť obrázky -pdfjs-editor-stamp-button-label = Pridať alebo upraviť obrázky -pdfjs-editor-highlight-button = - .title = Zvýrazniť -pdfjs-editor-highlight-button-label = Zvýrazniť -pdfjs-highlight-floating-button = - .title = Zvýrazniť -pdfjs-highlight-floating-button1 = - .title = Zvýrazniť - .aria-label = Zvýrazniť -pdfjs-highlight-floating-button-label = Zvýrazniť - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Odstrániť kresbu -pdfjs-editor-remove-freetext-button = - .title = Odstrániť text -pdfjs-editor-remove-stamp-button = - .title = Odstrániť obrázok -pdfjs-editor-remove-highlight-button = - .title = Odstrániť zvýraznenie - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Farba -pdfjs-editor-free-text-size-input = Veľkosť -pdfjs-editor-ink-color-input = Farba -pdfjs-editor-ink-thickness-input = Hrúbka -pdfjs-editor-ink-opacity-input = Priehľadnosť -pdfjs-editor-stamp-add-image-button = - .title = Pridať obrázok -pdfjs-editor-stamp-add-image-button-label = Pridať obrázok -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Hrúbka -pdfjs-editor-free-highlight-thickness-title = - .title = Zmeňte hrúbku pre zvýrazňovanie iných položiek ako textu -pdfjs-free-text = - .aria-label = Textový editor -pdfjs-free-text-default-content = Začnite písať… -pdfjs-ink = - .aria-label = Editor kreslenia -pdfjs-ink-canvas = - .aria-label = Obrázok vytvorený používateľom - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternatívny text -pdfjs-editor-alt-text-edit-button-label = Upraviť alternatívny text -pdfjs-editor-alt-text-dialog-label = Vyberte možnosť -pdfjs-editor-alt-text-dialog-description = Alternatívny text (alt text) pomáha, keď ľudia obrázok nevidia alebo sa nenačítava. -pdfjs-editor-alt-text-add-description-label = Pridať popis -pdfjs-editor-alt-text-add-description-description = Zamerajte sa na 1-2 vety, ktoré popisujú predmet, prostredie alebo akcie. -pdfjs-editor-alt-text-mark-decorative-label = Označiť ako dekoratívny -pdfjs-editor-alt-text-mark-decorative-description = Používa sa na ozdobné obrázky, ako sú okraje alebo vodoznaky. -pdfjs-editor-alt-text-cancel-button = Zrušiť -pdfjs-editor-alt-text-save-button = Uložiť -pdfjs-editor-alt-text-decorative-tooltip = Označený ako dekoratívny -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Napríklad: „Mladý muž si sadá za stôl, aby sa najedol“ - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Ľavý horný roh – zmena veľkosti -pdfjs-editor-resizer-label-top-middle = Horný stred – zmena veľkosti -pdfjs-editor-resizer-label-top-right = Pravý horný roh – zmena veľkosti -pdfjs-editor-resizer-label-middle-right = Vpravo uprostred – zmena veľkosti -pdfjs-editor-resizer-label-bottom-right = Pravý dolný roh – zmena veľkosti -pdfjs-editor-resizer-label-bottom-middle = Stred dole – zmena veľkosti -pdfjs-editor-resizer-label-bottom-left = Ľavý dolný roh – zmena veľkosti -pdfjs-editor-resizer-label-middle-left = Vľavo uprostred – zmena veľkosti - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Farba zvýraznenia -pdfjs-editor-colorpicker-button = - .title = Zmeniť farbu -pdfjs-editor-colorpicker-dropdown = - .aria-label = Výber farieb -pdfjs-editor-colorpicker-yellow = - .title = Žltá -pdfjs-editor-colorpicker-green = - .title = Zelená -pdfjs-editor-colorpicker-blue = - .title = Modrá -pdfjs-editor-colorpicker-pink = - .title = Ružová -pdfjs-editor-colorpicker-red = - .title = Červená - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Zobraziť všetko -pdfjs-editor-highlight-show-all-button = - .title = Zobraziť všetko diff --git a/static/pdf.js/locale/sk/viewer.properties b/static/pdf.js/locale/sk/viewer.properties new file mode 100644 index 00000000..e73d1b7f --- /dev/null +++ b/static/pdf.js/locale/sk/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Predchádzajúca strana +previous_label=Predchádzajúca +next.title=Nasledujúca strana +next_label=Nasledujúca + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Strana: +page_of=z {{pageCount}} + +zoom_out.title=Vzdialiť +zoom_out_label=Vzdialiť +zoom_in.title=Priblížiť +zoom_in_label=Priblížiť +zoom.title=Lupa +presentation_mode.title=Prepnúť na režim Prezentácia +presentation_mode_label=Režim Prezentácia +open_file.title=Otvoriť súbor +open_file_label=Otvoriť +print.title=Tlačiť +print_label=Tlačiť +download.title=Prevziať +download_label=Prevziať +bookmark.title=Aktuálne zobrazenie (kopírovať alebo otvoriť v novom okne) +bookmark_label=Aktuálne zobrazenie + +# Secondary toolbar and context menu +tools.title=Nástroje +tools_label=Nástroje +first_page.title=Prejsť na prvú stranu +first_page.label=Prejsť na prvú stranu +first_page_label=Prejsť na prvú stranu +last_page.title=Prejsť na poslednú stranu +last_page.label=Prejsť na poslednú stranu +last_page_label=Prejsť na poslednú stranu +page_rotate_cw.title=Otočiť v smere hodinových ručičiek +page_rotate_cw.label=Otočiť v smere hodinových ručičiek +page_rotate_cw_label=Otočiť v smere hodinových ručičiek +page_rotate_ccw.title=Otočiť proti smeru hodinových ručičiek +page_rotate_ccw.label=Otočiť proti smeru hodinových ručičiek +page_rotate_ccw_label=Otočiť proti smeru hodinových ručičiek + +hand_tool_enable.title=Zapnúť nástroj Ruka +hand_tool_enable_label=Zapnúť nástroj Ruka +hand_tool_disable.title=Vypnúť nástroj Ruka +hand_tool_disable_label=Vypnúť nástroj Ruka + +# Document properties dialog box +document_properties.title=Vlastnosti dokumentu… +document_properties_label=Vlastnosti dokumentu… +document_properties_file_name=Názov súboru: +document_properties_file_size=Veľkosť súboru: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} kB ({{size_b}} bajtov) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bajtov) +document_properties_title=Názov: +document_properties_author=Autor: +document_properties_subject=Predmet: +document_properties_keywords=Kľúčové slová: +document_properties_creation_date=Dátum vytvorenia: +document_properties_modification_date=Dátum úpravy: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Vytvoril: +document_properties_producer=Tvorca PDF: +document_properties_version=Verzia PDF: +document_properties_page_count=Počet strán: +document_properties_close=Zavrieť + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Prepnúť bočný panel +toggle_sidebar_label=Prepnúť bočný panel +outline.title=Zobraziť prehľad dokumentu +outline_label=Prehľad dokumentu +attachments.title=Zobraziť prílohy +attachments_label=Prílohy +thumbs.title=Zobraziť miniatúry +thumbs_label=Miniatúry +findbar.title=Hľadať v dokumente +findbar_label=Hľadať + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Strana {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatúra strany {{page}} + +# Find panel button title and messages +find_label=Hľadať: +find_previous.title=Vyhľadať predchádzajúci výskyt reťazca +find_previous_label=Predchádzajúce +find_next.title=Vyhľadať ďalší výskyt reťazca +find_next_label=Ďalšie +find_highlight=Zvýrazniť všetky +find_match_case_label=Rozlišovať malé/veľké písmená +find_reached_top=Bol dosiahnutý začiatok stránky, pokračuje sa od konca +find_reached_bottom=Bol dosiahnutý koniec stránky, pokračuje sa od začiatku +find_not_found=Výraz nebol nájdený + +# Error panel labels +error_more_info=Viac informácií +error_less_info=Menej informácií +error_close=Zavrieť +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (zostavenie: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Správa: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Zásobník: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Súbor: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Riadok: {{line}} +rendering_error=Pri vykresľovaní stránky sa vyskytla chyba. + +# Predefined zoom values +page_scale_width=Na šírku strany +page_scale_fit=Na veľkosť strany +page_scale_auto=Automatická veľkosť +page_scale_actual=Skutočná veľkosť +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Chyba +loading_error=Počas načítavania dokumentu PDF sa vyskytla chyba. +invalid_file_error=Neplatný alebo poškodený súbor PDF. +missing_file_error=Chýbajúci súbor PDF. +unexpected_response_error=Neočakávaná odpoveď zo servera. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Anotácia typu {{type}}] +password_label=Ak chcete otvoriť tento súbor PDF, zadajte jeho heslo. +password_invalid=Heslo nie je platné. Skúste to znova. +password_ok=OK +password_cancel=Zrušiť + +printing_not_supported=Upozornenie: tlač nie je v tomto prehliadači plne podporovaná. +printing_not_ready=Upozornenie: súbor PDF nie je plne načítaný pre tlač. +web_fonts_disabled=Webové písma sú vypnuté: nie je možné použiť písma vložené do súboru PDF. +document_colors_not_allowed=Dokumenty PDF nemajú povolené používať vlastné farby, pretože voľba "Povoliť stránkam používať vlastné farby" je v nastaveniach prehliadača vypnutá. diff --git a/static/pdf.js/locale/skr/viewer.ftl b/static/pdf.js/locale/skr/viewer.ftl deleted file mode 100644 index 72afe356..00000000 --- a/static/pdf.js/locale/skr/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = پچھلا ورقہ -pdfjs-previous-button-label = پچھلا -pdfjs-next-button = - .title = اڳلا ورقہ -pdfjs-next-button-label = اڳلا -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = ورقہ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } دا -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } دا { $pagesCount }) -pdfjs-zoom-out-button = - .title = زوم آؤٹ -pdfjs-zoom-out-button-label = زوم آؤٹ -pdfjs-zoom-in-button = - .title = زوم اِن -pdfjs-zoom-in-button-label = زوم اِن -pdfjs-zoom-select = - .title = زوم -pdfjs-presentation-mode-button = - .title = پریزنٹیشن موڈ تے سوئچ کرو -pdfjs-presentation-mode-button-label = پریزنٹیشن موڈ -pdfjs-open-file-button = - .title = فائل کھولو -pdfjs-open-file-button-label = کھولو -pdfjs-print-button = - .title = چھاپو -pdfjs-print-button-label = چھاپو -pdfjs-save-button = - .title = ہتھیکڑا کرو -pdfjs-save-button-label = ہتھیکڑا کرو -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = ڈاؤن لوڈ -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = ڈاؤن لوڈ -pdfjs-bookmark-button = - .title = موجودہ ورقہ (موجودہ ورقے کنوں یوآرایل ݙیکھو) -pdfjs-bookmark-button-label = موجودہ ورقہ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = اوزار -pdfjs-tools-button-label = اوزار -pdfjs-first-page-button = - .title = پہلے ورقے تے ونڄو -pdfjs-first-page-button-label = پہلے ورقے تے ونڄو -pdfjs-last-page-button = - .title = چھیکڑی ورقے تے ونڄو -pdfjs-last-page-button-label = چھیکڑی ورقے تے ونڄو -pdfjs-page-rotate-cw-button = - .title = گھڑی وانگوں گھماؤ -pdfjs-page-rotate-cw-button-label = گھڑی وانگوں گھماؤ -pdfjs-page-rotate-ccw-button = - .title = گھڑی تے اُپٹھ گھماؤ -pdfjs-page-rotate-ccw-button-label = گھڑی تے اُپٹھ گھماؤ -pdfjs-cursor-text-select-tool-button = - .title = متن منتخب کݨ والا آلہ فعال بݨاؤ -pdfjs-cursor-text-select-tool-button-label = متن منتخب کرݨ والا آلہ -pdfjs-cursor-hand-tool-button = - .title = ہینڈ ٹول فعال بݨاؤ -pdfjs-cursor-hand-tool-button-label = ہینڈ ٹول -pdfjs-scroll-page-button = - .title = پیج سکرولنگ استعمال کرو -pdfjs-scroll-page-button-label = پیج سکرولنگ -pdfjs-scroll-vertical-button = - .title = عمودی سکرولنگ استعمال کرو -pdfjs-scroll-vertical-button-label = عمودی سکرولنگ -pdfjs-scroll-horizontal-button = - .title = افقی سکرولنگ استعمال کرو -pdfjs-scroll-horizontal-button-label = افقی سکرولنگ -pdfjs-scroll-wrapped-button = - .title = ویڑھی ہوئی سکرولنگ استعمال کرو -pdfjs-scroll-wrapped-button-label = وہڑھی ہوئی سکرولنگ -pdfjs-spread-none-button = - .title = پیج سپریڈز وِچ شامل نہ تھیوو۔ -pdfjs-spread-none-button-label = کوئی پولھ کائنی -pdfjs-spread-odd-button = - .title = طاق نمبر والے ورقیاں دے نال شروع تھیوݨ والے پیج سپریڈز وِچ شامل تھیوو۔ -pdfjs-spread-odd-button-label = تاک پھیلاؤ -pdfjs-spread-even-button = - .title = جفت نمر والے ورقیاں نال شروع تھیوݨ والے پیج سپریڈز وِ شامل تھیوو۔ -pdfjs-spread-even-button-label = جفت پھیلاؤ - -## Document properties dialog - -pdfjs-document-properties-button = - .title = دستاویز خواص… -pdfjs-document-properties-button-label = دستاویز خواص … -pdfjs-document-properties-file-name = فائل دا ناں: -pdfjs-document-properties-file-size = فائل دا سائز: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } کے بی ({ $size_b } بائٹس) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } ایم بی ({ $size_b } بائٹس) -pdfjs-document-properties-title = عنوان: -pdfjs-document-properties-author = تخلیق کار: -pdfjs-document-properties-subject = موضوع: -pdfjs-document-properties-keywords = کلیدی الفاظ: -pdfjs-document-properties-creation-date = تخلیق دی تاریخ: -pdfjs-document-properties-modification-date = ترمیم دی تاریخ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = تخلیق کار: -pdfjs-document-properties-producer = PDF پیدا کار: -pdfjs-document-properties-version = PDF ورژن: -pdfjs-document-properties-page-count = ورقہ شماری: -pdfjs-document-properties-page-size = ورقہ دی سائز: -pdfjs-document-properties-page-size-unit-inches = وِچ -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = عمودی انداز -pdfjs-document-properties-page-size-orientation-landscape = افقى انداز -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = لیٹر -pdfjs-document-properties-page-size-name-legal = قنونی - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = تکھا ویب نظارہ: -pdfjs-document-properties-linearized-yes = جیا -pdfjs-document-properties-linearized-no = کو -pdfjs-document-properties-close-button = بند کرو - -## Print - -pdfjs-print-progress-message = چھاپݨ کیتے دستاویز تیار تھیندے پئے ہن … -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = منسوخ کرو -pdfjs-printing-not-supported = چتاوݨی: چھپائی ایں براؤزر تے پوری طراں معاونت شدہ کائنی۔ -pdfjs-printing-not-ready = چتاوݨی: PDF چھپائی کیتے پوری طراں لوڈ نئیں تھئی۔ - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = سائیڈ بار ٹوگل کرو -pdfjs-toggle-sidebar-notification-button = - .title = سائیڈ بار ٹوگل کرو (دستاویز وِچ آؤٹ لائن/ منسلکات/ پرتاں شامل ہن) -pdfjs-toggle-sidebar-button-label = سائیڈ بار ٹوگل کرو -pdfjs-document-outline-button = - .title = دستاویز دا خاکہ ݙکھاؤ (تمام آئٹمز کوں پھیلاوݨ/سنگوڑݨ کیتے ڈبل کلک کرو) -pdfjs-document-outline-button-label = دستاویز آؤٹ لائن -pdfjs-attachments-button = - .title = نتھیاں ݙکھاؤ -pdfjs-attachments-button-label = منسلکات -pdfjs-layers-button = - .title = پرتاں ݙکھاؤ (تمام پرتاں کوں ڈیفالٹ حالت وِچ دوبارہ ترتیب ݙیوݨ کیتے ڈبل کلک کرو) -pdfjs-layers-button-label = پرتاں -pdfjs-thumbs-button = - .title = تھمبنیل ݙکھاؤ -pdfjs-thumbs-button-label = تھمبنیلز -pdfjs-current-outline-item-button = - .title = موجودہ آؤٹ لائن آئٹم لبھو -pdfjs-current-outline-item-button-label = موجودہ آؤٹ لائن آئٹم -pdfjs-findbar-button = - .title = دستاویز وِچ لبھو -pdfjs-findbar-button-label = لبھو -pdfjs-additional-layers = اضافی پرتاں - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = ورقہ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = ورقے دا تھمبنیل { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = لبھو - .placeholder = دستاویز وِچ لبھو … -pdfjs-find-previous-button = - .title = فقرے دا پچھلا واقعہ لبھو -pdfjs-find-previous-button-label = پچھلا -pdfjs-find-next-button = - .title = فقرے دا اڳلا واقعہ لبھو -pdfjs-find-next-button-label = اڳلا -pdfjs-find-highlight-checkbox = تمام نشابر کرو -pdfjs-find-match-case-checkbox-label = حروف مشابہ کرو -pdfjs-find-match-diacritics-checkbox-label = ڈائیکرٹکس مشابہ کرو -pdfjs-find-entire-word-checkbox-label = تمام الفاظ -pdfjs-find-reached-top = ورقے دے شروع تے پُج ڳیا، تلوں جاری کیتا ڳیا -pdfjs-find-reached-bottom = ورقے دے پاند تے پُڄ ڳیا، اُتوں شروع کیتا ڳیا -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $total } وِچوں { $current } مشابہ - *[other] { $total } وِچوں { $current } مشابے - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] { $limit } توں ودھ مماثلت۔ - *[other] { $limit } توں ودھ مماثلتاں۔ - } -pdfjs-find-not-found = فقرہ نئیں ملیا - -## Predefined zoom values - -pdfjs-page-scale-width = ورقے دی چوڑائی -pdfjs-page-scale-fit = ورقہ فٹنگ -pdfjs-page-scale-auto = آپوں آپ زوم -pdfjs-page-scale-actual = اصل میچا -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = ورقہ { $page } - -## Loading indicator messages - -pdfjs-loading-error = PDF لوڈ کریندے ویلھے نقص آ ڳیا۔ -pdfjs-invalid-file-error = غلط یا خراب شدہ PDF فائل۔ -pdfjs-missing-file-error = PDF فائل غائب ہے۔ -pdfjs-unexpected-response-error = سرور دا غیر متوقع جواب۔ -pdfjs-rendering-error = ورقہ رینڈر کریندے ویلھے ہک خرابی پیش آڳئی۔ - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } تشریح] - -## Password - -pdfjs-password-label = ایہ PDF فائل کھولݨ کیتے پاس ورڈ درج کرو۔ -pdfjs-password-invalid = غلط پاس ورڈ: براہ مہربانی ولدا کوشش کرو۔ -pdfjs-password-ok-button = ٹھیک ہے -pdfjs-password-cancel-button = منسوخ کرو -pdfjs-web-fonts-disabled = ویب فونٹس غیر فعال ہن: ایمبیڈڈ PDF فونٹس استعمال کرݨ کنوں قاصر ہن - -## Editing - -pdfjs-editor-free-text-button = - .title = متن -pdfjs-editor-free-text-button-label = متن -pdfjs-editor-ink-button = - .title = چھکو -pdfjs-editor-ink-button-label = چھکو -pdfjs-editor-stamp-button = - .title = تصویراں کوں شامل کرو یا ترمیم کرو -pdfjs-editor-stamp-button-label = تصویراں کوں شامل کرو یا ترمیم کرو -pdfjs-editor-highlight-button = - .title = نمایاں کرو -pdfjs-editor-highlight-button-label = نمایاں کرو -pdfjs-highlight-floating-button = - .title = نمایاں کرو -pdfjs-highlight-floating-button1 = - .title = نمایاں کرو - .aria-label = نمایاں کرو -pdfjs-highlight-floating-button-label = نمایاں کرو - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = ڈرائینگ ہٹاؤ -pdfjs-editor-remove-freetext-button = - .title = متن ہٹاؤ -pdfjs-editor-remove-stamp-button = - .title = تصویر ہٹاؤ -pdfjs-editor-remove-highlight-button = - .title = نمایاں ہٹاؤ - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = رنگ -pdfjs-editor-free-text-size-input = سائز -pdfjs-editor-ink-color-input = رنگ -pdfjs-editor-ink-thickness-input = ٹھولھ -pdfjs-editor-ink-opacity-input = دھندلاپن -pdfjs-editor-stamp-add-image-button = - .title = تصویر شامل کرو -pdfjs-editor-stamp-add-image-button-label = تصویر شامل کرو -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = مُٹاݨ -pdfjs-editor-free-highlight-thickness-title = - .title = متن توں ان٘ج ٻئے شئیں کوں نمایاں کرݨ ویلے مُٹاݨ کوں بدلو -pdfjs-free-text = - .aria-label = ٹیکسٹ ایڈیٹر -pdfjs-free-text-default-content = ٹائپنگ شروع کرو … -pdfjs-ink = - .aria-label = ڈرا ایڈیٹر -pdfjs-ink-canvas = - .aria-label = صارف دی بݨائی ہوئی تصویر - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alt متن -pdfjs-editor-alt-text-edit-button-label = alt متن وِچ ترمیم کرو -pdfjs-editor-alt-text-dialog-label = ہِک اختیار چُݨو -pdfjs-editor-alt-text-dialog-description = Alt متن (متبادل متن) اِیں ویلے مَدَت کرین٘دا ہِے جہڑیلے لوک تصویر کوں نِھیں ݙیکھ سڳدے یا جہڑیلے اِیہ لوڈ کائنی تِھین٘دا۔ -pdfjs-editor-alt-text-add-description-label = تفصیل شامل کرو -pdfjs-editor-alt-text-add-description-description = 1-2 جملیاں دا مقصد جہڑے موضوع، ترتیب، یا اعمال کوں بیان کرین٘دے ہِن۔ -pdfjs-editor-alt-text-mark-decorative-label = آرائشی طور تے نشان زد کرو -pdfjs-editor-alt-text-mark-decorative-description = اِیہ آرائشی تصویراں کِیتے استعمال تِھین٘دا ہِے، جیویں بارڈر یا واٹر مارکس۔ -pdfjs-editor-alt-text-cancel-button = منسوخ -pdfjs-editor-alt-text-save-button = محفوظ -pdfjs-editor-alt-text-decorative-tooltip = آرائشی دے طور تے نشان زد تِھی ڳِیا -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = مثال دے طور تے، "ہِک جؤان کھاݨاں کھاوݨ کِیتے میز اُتّے ٻیٹھا ہِے" - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = اُتلی کَھٻّی نُکّڑ — سائز بدلو -pdfjs-editor-resizer-label-top-middle = اُتلا وِچلا — سائز بدلو -pdfjs-editor-resizer-label-top-right = اُتلی سَڄّی نُکَّڑ — سائز بدلو -pdfjs-editor-resizer-label-middle-right = وِچلا سڄّا — سائز بدلو -pdfjs-editor-resizer-label-bottom-right = تلوِیں سَڄّی نُکَّڑ — سائز بدلو -pdfjs-editor-resizer-label-bottom-middle = تلواں وِچلا — سائز بدلو -pdfjs-editor-resizer-label-bottom-left = تلوِیں کَھٻّی نُکّڑ — سائز بدلو -pdfjs-editor-resizer-label-middle-left = وِچلا کَھٻّا — سائز بدلو - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = نشابر رنگ -pdfjs-editor-colorpicker-button = - .title = رنگ بدلو -pdfjs-editor-colorpicker-dropdown = - .aria-label = رنگ اختیارات -pdfjs-editor-colorpicker-yellow = - .title = پیلا -pdfjs-editor-colorpicker-green = - .title = ساوا -pdfjs-editor-colorpicker-blue = - .title = نیلا -pdfjs-editor-colorpicker-pink = - .title = گلابی -pdfjs-editor-colorpicker-red = - .title = لال - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = سارے ݙکھاؤ -pdfjs-editor-highlight-show-all-button = - .title = سارے ݙکھاؤ diff --git a/static/pdf.js/locale/sl/viewer.ftl b/static/pdf.js/locale/sl/viewer.ftl deleted file mode 100644 index 841dfccb..00000000 --- a/static/pdf.js/locale/sl/viewer.ftl +++ /dev/null @@ -1,398 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Prejšnja stran -pdfjs-previous-button-label = Nazaj -pdfjs-next-button = - .title = Naslednja stran -pdfjs-next-button-label = Naprej -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Stran -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = od { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } od { $pagesCount }) -pdfjs-zoom-out-button = - .title = Pomanjšaj -pdfjs-zoom-out-button-label = Pomanjšaj -pdfjs-zoom-in-button = - .title = Povečaj -pdfjs-zoom-in-button-label = Povečaj -pdfjs-zoom-select = - .title = Povečava -pdfjs-presentation-mode-button = - .title = Preklopi v način predstavitve -pdfjs-presentation-mode-button-label = Način predstavitve -pdfjs-open-file-button = - .title = Odpri datoteko -pdfjs-open-file-button-label = Odpri -pdfjs-print-button = - .title = Natisni -pdfjs-print-button-label = Natisni -pdfjs-save-button = - .title = Shrani -pdfjs-save-button-label = Shrani -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Prenesi -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Prenesi -pdfjs-bookmark-button = - .title = Trenutna stran (prikaži URL, ki vodi do trenutne strani) -pdfjs-bookmark-button-label = Na trenutno stran - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Orodja -pdfjs-tools-button-label = Orodja -pdfjs-first-page-button = - .title = Pojdi na prvo stran -pdfjs-first-page-button-label = Pojdi na prvo stran -pdfjs-last-page-button = - .title = Pojdi na zadnjo stran -pdfjs-last-page-button-label = Pojdi na zadnjo stran -pdfjs-page-rotate-cw-button = - .title = Zavrti v smeri urnega kazalca -pdfjs-page-rotate-cw-button-label = Zavrti v smeri urnega kazalca -pdfjs-page-rotate-ccw-button = - .title = Zavrti v nasprotni smeri urnega kazalca -pdfjs-page-rotate-ccw-button-label = Zavrti v nasprotni smeri urnega kazalca -pdfjs-cursor-text-select-tool-button = - .title = Omogoči orodje za izbor besedila -pdfjs-cursor-text-select-tool-button-label = Orodje za izbor besedila -pdfjs-cursor-hand-tool-button = - .title = Omogoči roko -pdfjs-cursor-hand-tool-button-label = Roka -pdfjs-scroll-page-button = - .title = Uporabi drsenje po strani -pdfjs-scroll-page-button-label = Drsenje po strani -pdfjs-scroll-vertical-button = - .title = Uporabi navpično drsenje -pdfjs-scroll-vertical-button-label = Navpično drsenje -pdfjs-scroll-horizontal-button = - .title = Uporabi vodoravno drsenje -pdfjs-scroll-horizontal-button-label = Vodoravno drsenje -pdfjs-scroll-wrapped-button = - .title = Uporabi ovito drsenje -pdfjs-scroll-wrapped-button-label = Ovito drsenje -pdfjs-spread-none-button = - .title = Ne združuj razponov strani -pdfjs-spread-none-button-label = Brez razponov -pdfjs-spread-odd-button = - .title = Združuj razpone strani z začetkom pri lihih straneh -pdfjs-spread-odd-button-label = Lihi razponi -pdfjs-spread-even-button = - .title = Združuj razpone strani z začetkom pri sodih straneh -pdfjs-spread-even-button-label = Sodi razponi - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Lastnosti dokumenta … -pdfjs-document-properties-button-label = Lastnosti dokumenta … -pdfjs-document-properties-file-name = Ime datoteke: -pdfjs-document-properties-file-size = Velikost datoteke: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bajtov) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bajtov) -pdfjs-document-properties-title = Ime: -pdfjs-document-properties-author = Avtor: -pdfjs-document-properties-subject = Tema: -pdfjs-document-properties-keywords = Ključne besede: -pdfjs-document-properties-creation-date = Datum nastanka: -pdfjs-document-properties-modification-date = Datum spremembe: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Ustvaril: -pdfjs-document-properties-producer = Izdelovalec PDF: -pdfjs-document-properties-version = Različica PDF: -pdfjs-document-properties-page-count = Število strani: -pdfjs-document-properties-page-size = Velikost strani: -pdfjs-document-properties-page-size-unit-inches = palcev -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = pokončno -pdfjs-document-properties-page-size-orientation-landscape = ležeče -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Pismo -pdfjs-document-properties-page-size-name-legal = Pravno - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Hitri spletni ogled: -pdfjs-document-properties-linearized-yes = Da -pdfjs-document-properties-linearized-no = Ne -pdfjs-document-properties-close-button = Zapri - -## Print - -pdfjs-print-progress-message = Priprava dokumenta na tiskanje … -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress } % -pdfjs-print-progress-close-button = Prekliči -pdfjs-printing-not-supported = Opozorilo: ta brskalnik ne podpira vseh možnosti tiskanja. -pdfjs-printing-not-ready = Opozorilo: PDF ni v celoti naložen za tiskanje. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Preklopi stransko vrstico -pdfjs-toggle-sidebar-notification-button = - .title = Preklopi stransko vrstico (dokument vsebuje oris/priponke/plasti) -pdfjs-toggle-sidebar-button-label = Preklopi stransko vrstico -pdfjs-document-outline-button = - .title = Prikaži oris dokumenta (dvokliknite za razširitev/strnitev vseh predmetov) -pdfjs-document-outline-button-label = Oris dokumenta -pdfjs-attachments-button = - .title = Prikaži priponke -pdfjs-attachments-button-label = Priponke -pdfjs-layers-button = - .title = Prikaži plasti (dvokliknite za ponastavitev vseh plasti na privzeto stanje) -pdfjs-layers-button-label = Plasti -pdfjs-thumbs-button = - .title = Prikaži sličice -pdfjs-thumbs-button-label = Sličice -pdfjs-current-outline-item-button = - .title = Najdi trenutni predmet orisa -pdfjs-current-outline-item-button-label = Trenutni predmet orisa -pdfjs-findbar-button = - .title = Iskanje po dokumentu -pdfjs-findbar-button-label = Najdi -pdfjs-additional-layers = Dodatne plasti - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Stran { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Sličica strani { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Najdi - .placeholder = Najdi v dokumentu … -pdfjs-find-previous-button = - .title = Najdi prejšnjo ponovitev iskanega -pdfjs-find-previous-button-label = Najdi nazaj -pdfjs-find-next-button = - .title = Najdi naslednjo ponovitev iskanega -pdfjs-find-next-button-label = Najdi naprej -pdfjs-find-highlight-checkbox = Označi vse -pdfjs-find-match-case-checkbox-label = Razlikuj velike/male črke -pdfjs-find-match-diacritics-checkbox-label = Razlikuj diakritične znake -pdfjs-find-entire-word-checkbox-label = Cele besede -pdfjs-find-reached-top = Dosežen začetek dokumenta iz smeri konca -pdfjs-find-reached-bottom = Doseženo konec dokumenta iz smeri začetka -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] Zadetek { $current } od { $total } - [two] Zadetek { $current } od { $total } - [few] Zadetek { $current } od { $total } - *[other] Zadetek { $current } od { $total } - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Več kot { $limit } zadetek - [two] Več kot { $limit } zadetka - [few] Več kot { $limit } zadetki - *[other] Več kot { $limit } zadetkov - } -pdfjs-find-not-found = Iskanega ni mogoče najti - -## Predefined zoom values - -pdfjs-page-scale-width = Širina strani -pdfjs-page-scale-fit = Prilagodi stran -pdfjs-page-scale-auto = Samodejno -pdfjs-page-scale-actual = Dejanska velikost -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale } % - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Stran { $page } - -## Loading indicator messages - -pdfjs-loading-error = Med nalaganjem datoteke PDF je prišlo do napake. -pdfjs-invalid-file-error = Neveljavna ali pokvarjena datoteka PDF. -pdfjs-missing-file-error = Ni datoteke PDF. -pdfjs-unexpected-response-error = Nepričakovan odgovor strežnika. -pdfjs-rendering-error = Med pripravljanjem strani je prišlo do napake! - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Opomba vrste { $type }] - -## Password - -pdfjs-password-label = Vnesite geslo za odpiranje te datoteke PDF. -pdfjs-password-invalid = Neveljavno geslo. Poskusite znova. -pdfjs-password-ok-button = V redu -pdfjs-password-cancel-button = Prekliči -pdfjs-web-fonts-disabled = Spletne pisave so onemogočene: vgradnih pisav za PDF ni mogoče uporabiti. - -## Editing - -pdfjs-editor-free-text-button = - .title = Besedilo -pdfjs-editor-free-text-button-label = Besedilo -pdfjs-editor-ink-button = - .title = Riši -pdfjs-editor-ink-button-label = Riši -pdfjs-editor-stamp-button = - .title = Dodajanje ali urejanje slik -pdfjs-editor-stamp-button-label = Dodajanje ali urejanje slik -pdfjs-editor-highlight-button = - .title = Označevalnik -pdfjs-editor-highlight-button-label = Označevalnik -pdfjs-highlight-floating-button1 = - .title = Označi - .aria-label = Označi -pdfjs-highlight-floating-button-label = Označi - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Odstrani risbo -pdfjs-editor-remove-freetext-button = - .title = Odstrani besedilo -pdfjs-editor-remove-stamp-button = - .title = Odstrani sliko -pdfjs-editor-remove-highlight-button = - .title = Odstrani označbo - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Barva -pdfjs-editor-free-text-size-input = Velikost -pdfjs-editor-ink-color-input = Barva -pdfjs-editor-ink-thickness-input = Debelina -pdfjs-editor-ink-opacity-input = Neprosojnost -pdfjs-editor-stamp-add-image-button = - .title = Dodaj sliko -pdfjs-editor-stamp-add-image-button-label = Dodaj sliko -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Debelina -pdfjs-editor-free-highlight-thickness-title = - .title = Spremeni debelino pri označevanju nebesedilnih elementov -pdfjs-free-text = - .aria-label = Urejevalnik besedila -pdfjs-free-text-default-content = Začnite tipkati … -pdfjs-ink = - .aria-label = Urejevalnik risanja -pdfjs-ink-canvas = - .aria-label = Uporabnikova slika - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Nadomestno besedilo -pdfjs-editor-alt-text-edit-button-label = Uredi nadomestno besedilo -pdfjs-editor-alt-text-dialog-label = Izberite možnost -pdfjs-editor-alt-text-dialog-description = Nadomestno besedilo se prikaže tistim, ki ne vidijo slike, ali če se ta ne naloži. -pdfjs-editor-alt-text-add-description-label = Dodaj opis -pdfjs-editor-alt-text-add-description-description = Poskušajte v enem ali dveh stavkih opisati motiv, okolje ali dejanja. -pdfjs-editor-alt-text-mark-decorative-label = Označi kot okrasno -pdfjs-editor-alt-text-mark-decorative-description = Uporablja se za slike, ki služijo samo okrasu, na primer obrobe ali vodne žige. -pdfjs-editor-alt-text-cancel-button = Prekliči -pdfjs-editor-alt-text-save-button = Shrani -pdfjs-editor-alt-text-decorative-tooltip = Označeno kot okrasno -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Na primer: "Mladenič sedi za mizo pri jedi" - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Zgornji levi kot – spremeni velikost -pdfjs-editor-resizer-label-top-middle = Zgoraj na sredini – spremeni velikost -pdfjs-editor-resizer-label-top-right = Zgornji desni kot – spremeni velikost -pdfjs-editor-resizer-label-middle-right = Desno na sredini – spremeni velikost -pdfjs-editor-resizer-label-bottom-right = Spodnji desni kot – spremeni velikost -pdfjs-editor-resizer-label-bottom-middle = Spodaj na sredini – spremeni velikost -pdfjs-editor-resizer-label-bottom-left = Spodnji levi kot – spremeni velikost -pdfjs-editor-resizer-label-middle-left = Levo na sredini – spremeni velikost - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Barva označbe -pdfjs-editor-colorpicker-button = - .title = Spremeni barvo -pdfjs-editor-colorpicker-dropdown = - .aria-label = Izbira barve -pdfjs-editor-colorpicker-yellow = - .title = Rumena -pdfjs-editor-colorpicker-green = - .title = Zelena -pdfjs-editor-colorpicker-blue = - .title = Modra -pdfjs-editor-colorpicker-pink = - .title = Roza -pdfjs-editor-colorpicker-red = - .title = Rdeča - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Prikaži vse -pdfjs-editor-highlight-show-all-button = - .title = Prikaži vse diff --git a/static/pdf.js/locale/sl/viewer.properties b/static/pdf.js/locale/sl/viewer.properties new file mode 100644 index 00000000..e4483f06 --- /dev/null +++ b/static/pdf.js/locale/sl/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Prejšnja stran +previous_label=Nazaj +next.title=Naslednja stran +next_label=Naprej + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Stran: +page_of=od {{pageCount}} + +zoom_out.title=Pomanjšaj +zoom_out_label=Pomanjšaj +zoom_in.title=Povečaj +zoom_in_label=Povečaj +zoom.title=Povečava +presentation_mode.title=Preklopi v način predstavitve +presentation_mode_label=Način predstavitve +open_file.title=Odpri datoteko +open_file_label=Odpri +print.title=Natisni +print_label=Natisni +download.title=Prenesi +download_label=Prenesi +bookmark.title=Trenutni pogled (kopiraj ali odpri v novem oknu) +bookmark_label=Trenutni pogled + +# Secondary toolbar and context menu +tools.title=Orodja +tools_label=Orodja +first_page.title=Pojdi na prvo stran +first_page.label=Pojdi na prvo stran +first_page_label=Pojdi na prvo stran +last_page.title=Pojdi na zadnjo stran +last_page.label=Pojdi na zadnjo stran +last_page_label=Pojdi na zadnjo stran +page_rotate_cw.title=Zavrti v smeri urninega kazalca +page_rotate_cw.label=Zavrti v smeri urninega kazalca +page_rotate_cw_label=Zavrti v smeri urninega kazalca +page_rotate_ccw.title=Zavrti v nasprotni smeri urninega kazalca +page_rotate_ccw.label=Zavrti v nasprotni smeri urninega kazalca +page_rotate_ccw_label=Zavrti v nasprotni smeri urninega kazalca + +hand_tool_enable.title=Omogoči roko +hand_tool_enable_label=Omogoči roko +hand_tool_disable.title=Onemogoči roko +hand_tool_disable_label=Onemogoči roko + +# Document properties dialog box +document_properties.title=Lastnosti dokumenta … +document_properties_label=Lastnosti dokumenta … +document_properties_file_name=Ime datoteke: +document_properties_file_size=Velikost datoteke: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bajtov) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bajtov) +document_properties_title=Ime: +document_properties_author=Avtor: +document_properties_subject=Tema: +document_properties_keywords=Ključne besede: +document_properties_creation_date=Datum nastanka: +document_properties_modification_date=Datum spremembe: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Ustvaril: +document_properties_producer=Izdelovalec PDF: +document_properties_version=Različica PDF: +document_properties_page_count=Število strani: +document_properties_close=Zapri + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Preklopi stransko vrstico +toggle_sidebar_label=Preklopi stransko vrstico +outline.title=Prikaži oris dokumenta +outline_label=Oris dokumenta +attachments.title=Prikaži priponke +attachments_label=Priponke +thumbs.title=Prikaži sličice +thumbs_label=Sličice +findbar.title=Iskanje po dokumentu +findbar_label=Iskanje + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Stran {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Sličica strani {{page}} + +# Find panel button title and messages +find_label=Najdi: +find_previous.title=Najdi prejšnjo ponovitev iskanega +find_previous_label=Najdi nazaj +find_next.title=Najdi naslednjo ponovitev iskanega +find_next_label=Najdi naprej +find_highlight=Označi vse +find_match_case_label=Razlikuj velike/male črke +find_reached_top=Dosežen začetek dokumenta iz smeri konca +find_reached_bottom=Doseženo konec dokumenta iz smeri začetka +find_not_found=Iskanega ni mogoče najti + +# Error panel labels +error_more_info=Več informacij +error_less_info=Manj informacij +error_close=Zapri +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js r{{version}} (graditev: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Sporočilo: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Sklad: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Datoteka: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Vrstica: {{line}} +rendering_error=Med pripravljanjem strani je prišlo do napake! + +# Predefined zoom values +page_scale_width=Širina strani +page_scale_fit=Prilagodi stran +page_scale_auto=Samodejno +page_scale_actual=Dejanska velikost +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}} % + +# Loading indicator messages +loading_error_indicator=Napaka +loading_error=Med nalaganjem datoteke PDF je prišlo do napake. +invalid_file_error=Neveljavna ali pokvarjena datoteka PDF. +missing_file_error=Ni datoteke PDF. +unexpected_response_error=Nepričakovan odgovor strežnika. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Opomba vrste {{type}}] +password_label=Vnesite geslo za odpiranje te datoteke PDF. +password_invalid=Neveljavno geslo. Poskusite znova. +password_ok=V redu +password_cancel=Prekliči + +printing_not_supported=Opozorilo: ta brskalnik ne podpira vseh možnosti tiskanja. +printing_not_ready=Opozorilo: PDF ni v celoti naložen za tiskanje. +web_fonts_disabled=Spletne pisave so onemogočene: vgradnih pisav za PDF ni mogoče uporabiti. +document_colors_not_allowed=Dokumenti PDF ne smejo uporabljati svojih lastnih barv: možnost 'Dovoli stranem uporabo lastnih barv' je v brskalniku onemogočena. diff --git a/static/pdf.js/locale/son/viewer.ftl b/static/pdf.js/locale/son/viewer.ftl deleted file mode 100644 index fa4f6b1f..00000000 --- a/static/pdf.js/locale/son/viewer.ftl +++ /dev/null @@ -1,206 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Moo bisante -pdfjs-previous-button-label = Bisante -pdfjs-next-button = - .title = Jinehere moo -pdfjs-next-button-label = Jine -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Moo -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } ra -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } ka hun { $pagesCount }) ra -pdfjs-zoom-out-button = - .title = Nakasandi -pdfjs-zoom-out-button-label = Nakasandi -pdfjs-zoom-in-button = - .title = Bebbeerandi -pdfjs-zoom-in-button-label = Bebbeerandi -pdfjs-zoom-select = - .title = Bebbeerandi -pdfjs-presentation-mode-button = - .title = Bere cebeyan alhaali -pdfjs-presentation-mode-button-label = Cebeyan alhaali -pdfjs-open-file-button = - .title = Tuku feeri -pdfjs-open-file-button-label = Feeri -pdfjs-print-button = - .title = Kar -pdfjs-print-button-label = Kar - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Goyjinawey -pdfjs-tools-button-label = Goyjinawey -pdfjs-first-page-button = - .title = Koy moo jinaa ga -pdfjs-first-page-button-label = Koy moo jinaa ga -pdfjs-last-page-button = - .title = Koy moo koraa ga -pdfjs-last-page-button-label = Koy moo koraa ga -pdfjs-page-rotate-cw-button = - .title = Kuubi kanbe guma here -pdfjs-page-rotate-cw-button-label = Kuubi kanbe guma here -pdfjs-page-rotate-ccw-button = - .title = Kuubi kanbe wowa here -pdfjs-page-rotate-ccw-button-label = Kuubi kanbe wowa here - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Takadda mayrawey… -pdfjs-document-properties-button-label = Takadda mayrawey… -pdfjs-document-properties-file-name = Tuku maa: -pdfjs-document-properties-file-size = Tuku adadu: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = KB { $size_kb } (cebsu-ize { $size_b }) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = MB { $size_mb } (cebsu-ize { $size_b }) -pdfjs-document-properties-title = Tiiramaa: -pdfjs-document-properties-author = Hantumkaw: -pdfjs-document-properties-subject = Dalil: -pdfjs-document-properties-keywords = Kufalkalimawey: -pdfjs-document-properties-creation-date = Teeyan han: -pdfjs-document-properties-modification-date = Barmayan han: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Teekaw: -pdfjs-document-properties-producer = PDF berandikaw: -pdfjs-document-properties-version = PDF dumi: -pdfjs-document-properties-page-count = Moo hinna: - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -pdfjs-document-properties-close-button = Daabu - -## Print - -pdfjs-print-progress-message = Goo ma takaddaa soolu k'a kar se… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Naŋ -pdfjs-printing-not-supported = Yaamar: Karyan ši tee ka timme nda ceecikaa woo. -pdfjs-printing-not-ready = Yaamar: PDF ši zunbu ka timme karyan še. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Kanjari ceraw zuu -pdfjs-toggle-sidebar-button-label = Kanjari ceraw zuu -pdfjs-document-outline-button = - .title = Takaddaa korfur alhaaloo cebe (naagu cee hinka ka haya-izey kul hayandi/kankamandi) -pdfjs-document-outline-button-label = Takadda filla-boŋ -pdfjs-attachments-button = - .title = Hangarey cebe -pdfjs-attachments-button-label = Hangarey -pdfjs-thumbs-button = - .title = Kabeboy biyey cebe -pdfjs-thumbs-button-label = Kabeboy biyey -pdfjs-findbar-button = - .title = Ceeci takaddaa ra -pdfjs-findbar-button-label = Ceeci - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page } moo -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Kabeboy bii { $page } moo še - -## Find panel button title and messages - -pdfjs-find-input = - .title = Ceeci - .placeholder = Ceeci takaddaa ra… -pdfjs-find-previous-button = - .title = Kalimaɲaŋoo bangayri bisantaa ceeci -pdfjs-find-previous-button-label = Bisante -pdfjs-find-next-button = - .title = Kalimaɲaŋoo hiino bangayroo ceeci -pdfjs-find-next-button-label = Jine -pdfjs-find-highlight-checkbox = Ikul šilbay -pdfjs-find-match-case-checkbox-label = Harfu-beeriyan hawgay -pdfjs-find-reached-top = A too moŋoo boŋoo, koy jine ka šinitin nda cewoo -pdfjs-find-reached-bottom = A too moɲoo cewoo, koy jine šintioo ga -pdfjs-find-not-found = Kalimaɲaa mana duwandi - -## Predefined zoom values - -pdfjs-page-scale-width = Mooo hayyan -pdfjs-page-scale-fit = Moo sawayan -pdfjs-page-scale-auto = Boŋše azzaati barmayyan -pdfjs-page-scale-actual = Adadu cimi -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Firka bangay kaŋ PDF goo ma zumandi. -pdfjs-invalid-file-error = PDF tuku laala wala laybante. -pdfjs-missing-file-error = PDF tuku kumante. -pdfjs-unexpected-response-error = Manti feršikaw tuuruyan maatante. -pdfjs-rendering-error = Firka bangay kaŋ moɲoo goo ma willandi. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = { $type } maasa-caw] - -## Password - -pdfjs-password-label = Šennikufal dam ka PDF tukoo woo feeri. -pdfjs-password-invalid = Šennikufal laalo. Ceeci koyne taare. -pdfjs-password-ok-button = Ayyo -pdfjs-password-cancel-button = Naŋ -pdfjs-web-fonts-disabled = Interneti šigirawey kay: ši hin ka goy nda PDF šigira hurantey. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/son/viewer.properties b/static/pdf.js/locale/son/viewer.properties new file mode 100644 index 00000000..c7742e40 --- /dev/null +++ b/static/pdf.js/locale/son/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Moo bisante +previous_label=Bisante +next.title=Jinehere moo +next_label=Jine + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=&Moo: +page_of={{pageCount}} ga + +zoom_out.title=Nakasandi +zoom_out_label=Nakasandi +zoom_in.title=Bebbeerandi +zoom_in_label=Bebbeerandi +zoom.title=Bebbeerandi +presentation_mode.title=Bere cebeyan alhaali +presentation_mode_label=Cebeyan alhaali +open_file.title=Tuku feeri +open_file_label=Feeri +print.title=Kar +print_label=Kar +download.title=Zumandi +download_label=Zumandi +bookmark.title=Sohõ gunarro (bere wala feeri zanfun taaga ra) +bookmark_label=Sohõ gunaroo + +# Secondary toolbar and context menu +tools.title=Goyjinawey +tools_label=Goyjinawey +first_page.title=Koy moo jinaa ga +first_page.label=Koy moo jinaa ga +first_page_label=Koy moo jinaa ga +last_page.title=Koy moo koraa ga +last_page.label=Koy moo koraa ga +last_page_label=Koy moo koraa ga +page_rotate_cw.title=Kuubi kanbe guma here +page_rotate_cw.label=Kuubi kanbe guma here +page_rotate_cw_label=Kuubi kanbe guma here +page_rotate_ccw.title=Kuubi kanbe wowa here +page_rotate_ccw.label=Kuubi kanbe wowa here +page_rotate_ccw_label=Kuubi kanbe wowa here + +hand_tool_enable.title=Kanbe goyjinay tunandi +hand_tool_enable_label=Kanbe goyjinay tunandi +hand_tool_disable.title=Kanbe joyjinay kaa +hand_tool_disable_label=Kanbe goyjinay kaa + +# Document properties dialog box +document_properties.title=Takadda mayrawey… +document_properties_label=Takadda mayrawey… +document_properties_file_name=Tuku maa: +document_properties_file_size=Tuku adadu: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb=KB {{size_kb}} (cebsu-ize {{size_b}}) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb=MB {{size_mb}} (cebsu-ize {{size_b}}) +document_properties_title=Tiiramaa: +document_properties_author=Hantumkaw: +document_properties_subject=Dalil: +document_properties_keywords=Kufalkalimawey: +document_properties_creation_date=Teeyan han: +document_properties_modification_date=Barmayan han: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Teekaw: +document_properties_producer=PDF berandikaw: +document_properties_version=PDF dumi: +document_properties_page_count=Moo hinna: +document_properties_close=Daabu + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Kanjari ceraw zuu +toggle_sidebar_label=Kanjari ceraw zuu +outline.title=Takadda filla-boŋ cebe +outline_label=Takadda filla-boŋ +attachments.title=Hangarey cebe +attachments_label=Hangarey +thumbs.title=Kabeboy biyey cebe +thumbs_label=Kabeboy biyey +findbar.title=Ceeci takaddaa ra +findbar_label=Ceeci + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title={{page}} moo +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Kabeboy bii {{page}} moo še + +# Find panel button title and messages +find_label=Ceeci: +find_previous.title=Kalimaɲaŋoo bangayri bisantaa ceeci +find_previous_label=Bisante +find_next.title=Kalimaɲaŋoo hiino bangayroo ceeci +find_next_label=Jine +find_highlight=Ikul šilbay +find_match_case_label=Harfu-beeriyan hawgay +find_reached_top=A too moŋoo boŋoo, koy jine ka šinitin nda cewoo +find_reached_bottom=A too moɲoo cewoo, koy jine šintioo ga +find_not_found=Kalimaɲaa mana duwandi + +# Error panel labels +error_more_info=Alhabar tontoni +error_less_info=Alhabar tontoni +error_close=Daabu +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Alhabar: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Dekeri: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Tuku: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Žeeri: {{line}} +rendering_error=Firka bangay kaŋ moɲoo goo ma willandi. + +# Predefined zoom values +page_scale_width=Mooo hayyan +page_scale_fit=Moo sawayan +page_scale_auto=Boŋše azzaati barmayyan +page_scale_actual=Adadu cimi +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Firka +loading_error=Firka bangay kaŋ PDF goo ma zumandi. +invalid_file_error=PDF tuku laala wala laybante. +missing_file_error=PDF tuku kumante. +unexpected_response_error=Manti feršikaw tuuruyan maatante. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt={{type}} maasa-caw] +password_label=Šennikufal dam ka PDF tukoo woo feeri. +password_invalid=Šennikufal laalo. Ceeci koyne taare. +password_ok=Ayyo +password_cancel=Naŋ + +printing_not_supported=Yaamar: Karyan ši tee ka timme nda ceecikaa woo. +printing_not_ready=Yaamar: PDF ši zunbu ka timme karyan še. +web_fonts_disabled=Interneti šigirawey kay: ši hin ka goy nda PDF šigira hurantey. +document_colors_not_allowed=PDF takaddawey ši duu fondo ka ngey boŋ noonawey zaa: 'Naŋ moɲey ma ngey boŋ noonawey suuba' ši dira ceecikaa ga. diff --git a/static/pdf.js/locale/sq/viewer.ftl b/static/pdf.js/locale/sq/viewer.ftl deleted file mode 100644 index be5b273d..00000000 --- a/static/pdf.js/locale/sq/viewer.ftl +++ /dev/null @@ -1,387 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Faqja e Mëparshme -pdfjs-previous-button-label = E mëparshmja -pdfjs-next-button = - .title = Faqja Pasuese -pdfjs-next-button-label = Pasuesja -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Faqe -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = nga { $pagesCount } gjithsej -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } nga { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zvogëlojeni -pdfjs-zoom-out-button-label = Zvogëlojeni -pdfjs-zoom-in-button = - .title = Zmadhojeni -pdfjs-zoom-in-button-label = Zmadhojini -pdfjs-zoom-select = - .title = Zmadhim/Zvogëlim -pdfjs-presentation-mode-button = - .title = Kalo te Mënyra Paraqitje -pdfjs-presentation-mode-button-label = Mënyra Paraqitje -pdfjs-open-file-button = - .title = Hapni Kartelë -pdfjs-open-file-button-label = Hape -pdfjs-print-button = - .title = Shtypje -pdfjs-print-button-label = Shtype -pdfjs-save-button = - .title = Ruaje -pdfjs-save-button-label = Ruaje -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Shkarkojeni -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Shkarkoje -pdfjs-bookmark-button = - .title = Faqja e Tanishme (Shihni URL nga Faqja e Tanishme) -pdfjs-bookmark-button-label = Faqja e Tanishme - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Mjete -pdfjs-tools-button-label = Mjete -pdfjs-first-page-button = - .title = Kaloni te Faqja e Parë -pdfjs-first-page-button-label = Kaloni te Faqja e Parë -pdfjs-last-page-button = - .title = Kaloni te Faqja e Fundit -pdfjs-last-page-button-label = Kaloni te Faqja e Fundit -pdfjs-page-rotate-cw-button = - .title = Rrotullojeni Në Kahun Orar -pdfjs-page-rotate-cw-button-label = Rrotulloje Në Kahun Orar -pdfjs-page-rotate-ccw-button = - .title = Rrotullojeni Në Kahun Kundërorar -pdfjs-page-rotate-ccw-button-label = Rrotulloje Në Kahun Kundërorar -pdfjs-cursor-text-select-tool-button = - .title = Aktivizo Mjet Përzgjedhjeje Teksti -pdfjs-cursor-text-select-tool-button-label = Mjet Përzgjedhjeje Teksti -pdfjs-cursor-hand-tool-button = - .title = Aktivizo Mjetin Dorë -pdfjs-cursor-hand-tool-button-label = Mjeti Dorë -pdfjs-scroll-page-button = - .title = Përdor Rrëshqitje Në Faqe -pdfjs-scroll-page-button-label = Rrëshqitje Në Faqe -pdfjs-scroll-vertical-button = - .title = Përdor Rrëshqitje Vertikale -pdfjs-scroll-vertical-button-label = Rrëshqitje Vertikale -pdfjs-scroll-horizontal-button = - .title = Përdor Rrëshqitje Horizontale -pdfjs-scroll-horizontal-button-label = Rrëshqitje Horizontale -pdfjs-scroll-wrapped-button = - .title = Përdor Rrëshqitje Me Mbështjellje -pdfjs-scroll-wrapped-button-label = Rrëshqitje Me Mbështjellje - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Veti Dokumenti… -pdfjs-document-properties-button-label = Veti Dokumenti… -pdfjs-document-properties-file-name = Emër kartele: -pdfjs-document-properties-file-size = Madhësi kartele: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bajte) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bajte) -pdfjs-document-properties-title = Titull: -pdfjs-document-properties-author = Autor: -pdfjs-document-properties-subject = Subjekt: -pdfjs-document-properties-keywords = Fjalëkyçe: -pdfjs-document-properties-creation-date = Datë Krijimi: -pdfjs-document-properties-modification-date = Datë Ndryshimi: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Krijues: -pdfjs-document-properties-producer = Prodhues PDF-je: -pdfjs-document-properties-version = Version PDF-je: -pdfjs-document-properties-page-count = Numër Faqesh: -pdfjs-document-properties-page-size = Madhësi Faqeje: -pdfjs-document-properties-page-size-unit-inches = inç -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = portret -pdfjs-document-properties-page-size-orientation-landscape = së gjeri -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Parje e Shpjetë në Web: -pdfjs-document-properties-linearized-yes = Po -pdfjs-document-properties-linearized-no = Jo -pdfjs-document-properties-close-button = Mbylleni - -## Print - -pdfjs-print-progress-message = Po përgatitet dokumenti për shtypje… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Anuloje -pdfjs-printing-not-supported = Kujdes: Shtypja s’mbulohet plotësisht nga ky shfletues. -pdfjs-printing-not-ready = Kujdes: PDF-ja s’është ngarkuar plotësisht që ta shtypni. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Shfaqni/Fshihni Anështyllën -pdfjs-toggle-sidebar-notification-button = - .title = Hap/Mbyll Anështylë (dokumenti përmban përvijim/nashkëngjitje/shtresa) -pdfjs-toggle-sidebar-button-label = Shfaq/Fshih Anështyllën -pdfjs-document-outline-button = - .title = Shfaqni Përvijim Dokumenti (dyklikoni që të shfaqen/fshihen krejt elementët) -pdfjs-document-outline-button-label = Përvijim Dokumenti -pdfjs-attachments-button = - .title = Shfaqni Bashkëngjitje -pdfjs-attachments-button-label = Bashkëngjitje -pdfjs-layers-button = - .title = Shfaq Shtresa (dyklikoni që të rikthehen krejt shtresat në gjendjen e tyre parazgjedhje) -pdfjs-layers-button-label = Shtresa -pdfjs-thumbs-button = - .title = Shfaqni Miniatura -pdfjs-thumbs-button-label = Miniatura -pdfjs-current-outline-item-button = - .title = Gjej Objektin e Tanishëm të Përvijuar -pdfjs-current-outline-item-button-label = Objekt i Tanishëm i Përvijuar -pdfjs-findbar-button = - .title = Gjeni në Dokument -pdfjs-findbar-button-label = Gjej -pdfjs-additional-layers = Shtresa Shtesë - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Faqja { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniaturë e Faqes { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Gjej - .placeholder = Gjeni në dokument… -pdfjs-find-previous-button = - .title = Gjeni hasjen e mëparshme të togfjalëshit -pdfjs-find-previous-button-label = E mëparshmja -pdfjs-find-next-button = - .title = Gjeni hasjen pasuese të togfjalëshit -pdfjs-find-next-button-label = Pasuesja -pdfjs-find-highlight-checkbox = Theksoji të tëra -pdfjs-find-match-case-checkbox-label = Siç Është Shkruar -pdfjs-find-match-diacritics-checkbox-label = Me Përputhje Me Shenjat Diakritike -pdfjs-find-entire-word-checkbox-label = Fjalë të Plota -pdfjs-find-reached-top = U mbërrit në krye të dokumentit, vazhduar prej fundit -pdfjs-find-reached-bottom = U mbërrit në fund të dokumentit, vazhduar prej kreut -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } nga { $total } përputhje - *[other] { $current } nga { $total } përputhje - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Më tepër se { $limit } përputhje - *[other] Më tepër se { $limit } përputhje - } -pdfjs-find-not-found = Togfjalësh që s’gjendet - -## Predefined zoom values - -pdfjs-page-scale-width = Gjerësi Faqeje -pdfjs-page-scale-fit = Sa Nxë Faqja -pdfjs-page-scale-auto = Zoom i Vetvetishëm -pdfjs-page-scale-actual = Madhësia Faktike -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Faqja { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ndodhi një gabim gjatë ngarkimit të PDF-së. -pdfjs-invalid-file-error = Kartelë PDF e pavlefshme ose e dëmtuar. -pdfjs-missing-file-error = Kartelë PDF që mungon. -pdfjs-unexpected-response-error = Përgjigje shërbyesi e papritur. -pdfjs-rendering-error = Ndodhi një gabim gjatë riprodhimit të faqes. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Nënvizim { $type }] - -## Password - -pdfjs-password-label = Jepni fjalëkalimin që të hapet kjo kartelë PDF. -pdfjs-password-invalid = Fjalëkalim i pavlefshëm. Ju lutemi, riprovoni. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Anuloje -pdfjs-web-fonts-disabled = Shkronjat Web janë të çaktivizuara: s’arrihet të përdoren shkronja të trupëzuara në PDF. - -## Editing - -pdfjs-editor-free-text-button = - .title = Tekst -pdfjs-editor-free-text-button-label = Tekst -pdfjs-editor-ink-button = - .title = Vizatoni -pdfjs-editor-ink-button-label = Vizatoni -pdfjs-editor-stamp-button = - .title = Shtoni ose përpunoni figura -pdfjs-editor-stamp-button-label = Shtoni ose përpunoni figura -pdfjs-editor-highlight-button = - .title = Theksim -pdfjs-editor-highlight-button-label = Theksoje -pdfjs-highlight-floating-button = - .title = Theksim -pdfjs-highlight-floating-button1 = - .title = Theksim - .aria-label = Theksim -pdfjs-highlight-floating-button-label = Theksim - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Hiq vizatim -pdfjs-editor-remove-freetext-button = - .title = Hiq tekst -pdfjs-editor-remove-stamp-button = - .title = Hiq figurë -pdfjs-editor-remove-highlight-button = - .title = Hiqe theksimin - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Ngjyrë -pdfjs-editor-free-text-size-input = Madhësi -pdfjs-editor-ink-color-input = Ngjyrë -pdfjs-editor-ink-thickness-input = Trashësi -pdfjs-editor-ink-opacity-input = Patejdukshmëri -pdfjs-editor-stamp-add-image-button = - .title = Shtoni figurë -pdfjs-editor-stamp-add-image-button-label = Shtoni figurë -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Trashësi -pdfjs-editor-free-highlight-thickness-title = - .title = Ndryshoni trashësinë kur theksoni objekte tjetër nga tekst -pdfjs-free-text = - .aria-label = Përpunues Tekstesh -pdfjs-free-text-default-content = Filloni të shtypni… -pdfjs-ink = - .aria-label = Përpunues Vizatimesh -pdfjs-ink-canvas = - .aria-label = Figurë e krijuar nga përdoruesi - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Tekst alternativ -pdfjs-editor-alt-text-edit-button-label = Përpunoni tekst alternativ -pdfjs-editor-alt-text-dialog-label = Zgjidhni një mundësi -pdfjs-editor-alt-text-dialog-description = Teksti alt (tekst alternativ) vjen në ndihmë kur njerëzit s’mund të shohin figurën, ose kur ajo nuk ngarkohet. -pdfjs-editor-alt-text-add-description-label = Shtoni një përshkrim -pdfjs-editor-alt-text-add-description-description = Synoni për 1-2 togfjalësha që përshkruajnë subjektin, rrethanat apo veprimet. -pdfjs-editor-alt-text-mark-decorative-label = Vëri shenjë si dekorative -pdfjs-editor-alt-text-mark-decorative-description = Kjo përdoret për figura zbukuruese, fjala vjen, anë, ose watermark-e. -pdfjs-editor-alt-text-cancel-button = Anuloje -pdfjs-editor-alt-text-save-button = Ruaje -pdfjs-editor-alt-text-decorative-tooltip = Iu vu shenjë si dekorative -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Për shembull, “Një djalosh ulet në një tryezë të hajë” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Cepi i sipërm majtas — ripërmasojeni -pdfjs-editor-resizer-label-top-middle = Mesi i pjesës sipër — ripërmasojeni -pdfjs-editor-resizer-label-top-right = Cepi i sipërm djathtas — ripërmasojeni -pdfjs-editor-resizer-label-middle-right = Djathtas në mes — ripërmasojeni -pdfjs-editor-resizer-label-bottom-right = Cepi i poshtëm djathtas — ripërmasojeni -pdfjs-editor-resizer-label-bottom-middle = Mesi i pjesës poshtë — ripërmasojeni -pdfjs-editor-resizer-label-bottom-left = Cepi i poshtëm — ripërmasojeni -pdfjs-editor-resizer-label-middle-left = Majtas në mes — ripërmasojeni - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Ngjyrë theksimi -pdfjs-editor-colorpicker-button = - .title = Ndryshoni ngjyrë -pdfjs-editor-colorpicker-dropdown = - .aria-label = Zgjedhje ngjyre -pdfjs-editor-colorpicker-yellow = - .title = E verdhë -pdfjs-editor-colorpicker-green = - .title = E gjelbër -pdfjs-editor-colorpicker-blue = - .title = Blu -pdfjs-editor-colorpicker-pink = - .title = Rozë -pdfjs-editor-colorpicker-red = - .title = E kuqe - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Shfaqi krejt -pdfjs-editor-highlight-show-all-button = - .title = Shfaqi krejt diff --git a/static/pdf.js/locale/sq/viewer.properties b/static/pdf.js/locale/sq/viewer.properties new file mode 100644 index 00000000..0f883051 --- /dev/null +++ b/static/pdf.js/locale/sq/viewer.properties @@ -0,0 +1,166 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Faqja e Mëparshme +previous_label=E mëparshmja +next.title=Faqja Pasuese +next_label=Pasuesja + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Faqja: +page_of=nga {{pageCount}} + +zoom_out.title=Zmadhim +zoom_out_label=Zmadhoji +zoom_in.title=Zvogëlim +zoom_in_label=Zvogëloji +zoom.title=Zoom +print.title=Shtypje +print_label=Shtypeni +presentation_mode.title=Kalo te Mënyra Paraqitje +presentation_mode_label=Mënyra Paraqitje +open_file.title=Hapni Kartelë +open_file_label=Hapeni +download.title=Shkarkim +download_label=Shkarkojeni +bookmark.title=Pamja e tanishme (kopjojeni ose hapeni në dritare të re) +bookmark_label=Pamja e Tanishme + +# Secondary toolbar and context menu +tools.title=Mjete +tools_label=Mjete +first_page.title=Shkoni te Faqja e Parë +first_page.label=Shkoni te Faqja e Parë +first_page_label=Shkoni te Faqja e Parë +last_page.title=Shkoni te Faqja e Fundit +last_page.label=Shkoni te Faqja e Fundit +last_page_label=Shkoni te Faqja e Fundit +page_rotate_cw.title=Rrotullojeni Në Kahun Orar +page_rotate_cw.label=Rrotullojeni Në Kahun Orar +page_rotate_cw_label=Rrotullojeni Në Kahun Orar +page_rotate_ccw.title=Rrotullojeni Në Kahun Kundërorar +page_rotate_ccw.label=Rrotullojeni Në Kahun Kundërorar +page_rotate_ccw_label=Rrotullojeni Në Kahun Kundërorar + +hand_tool_enable.title=Aktivizoni mjet dore +hand_tool_enable_label=Aktivizoni mjet dore +hand_tool_disable.title=Çaktivizoni mjet dore +hand_tool_disable_label=Çaktivizoni mjet dore + +# Document properties dialog box +document_properties.title=Veti Dokumenti… +document_properties_label=Veti Dokumenti… +document_properties_file_name=Emër kartele: +document_properties_file_size=Madhësi kartele: +document_properties_kb={{size_kb}} KB ({{size_b}} bajte) +document_properties_mb={{size_mb}} MB ({{size_b}} bajte) +document_properties_title=Titull: +document_properties_author=Autor: +document_properties_subject=Subjekt: +document_properties_keywords=Fjalëkyçe: +document_properties_creation_date=Datë Krijimi: +document_properties_modification_date=Datë Ndryshimi: +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Krijues: +document_properties_producer=Prodhues PDF-je: +document_properties_version=Version PDF-je: +document_properties_page_count=Numër Faqesh: +document_properties_close=Mbylle + + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Shfaqni/Fshihni Anështyllën +toggle_sidebar_label=Shfaqni/Fshihni Anështyllën +outline.title=Shfaq Përvijim Dokumenti +outline_label=Shfaq Përvijim Dokumenti +attachments.title=Shfaq Bashkëngjitje +attachments_label=Bashkëngjitje +thumbs.title=Shfaq Miniatura +thumbs_label=Miniatura +findbar.title=Gjej në Dokument +findbar_label=Gjej + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Faqja {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniaturë e Faqes {{page}} + +# Context menu +first_page.label=Kalo te Faqja e Parë +last_page.label=Kalo te Faqja e Fundit +page_rotate_cw.label=Rrotulloje Në Kahun Orar +page_rotate_ccw.label=Rrotulloje Në Kahun Antiorar + +# Find panel button title and messages +find_label=Gjej: +find_previous.title=Gjeni hasjen e mëparshme të togfjalëshit +find_previous_label=E mëparshmja +find_next.title=Gjeni hasjen pasuese të togfjalëshit +find_next_label=Pasuesja +find_highlight=Theksoji të gjitha +find_match_case_label=Siç është shkruar +find_reached_top=U mbërrit në krye të dokumentit, vazhduar prej fundit +find_reached_bottom=U mbërrit në fund të dokumentit, vazhduar prej kreut +find_not_found=Nuk u gjet togfjalëshi + +# Error panel labels +error_more_info=Më Tepër të Dhëna +error_less_info=Më Pak të Dhëna +error_close=Mbylle +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mesazh: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Kartelë: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rresht: {{line}} +rendering_error=Ndodhi një gabim gjatë riprodhimit të faqes. + +# Predefined zoom values +page_scale_width=Gjerësi Faqeje +page_scale_fit=Sa Nxë Faqja +page_scale_auto=Zoom i Vetvetishëm +page_scale_actual=Madhësia Faktike +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +# LOCALIZATION NOTE (error_line): "{{[percent}}" will be replaced with a percentage +loading_error_indicator=Gabim +loading_error=Ndodhi një gabim gjatë ngarkimit të PDF-së. +invalid_file_error=Kartelë PDF e pavlefshme ose e dëmtuar. +missing_file_error=Kartelë PDF që mungon. +unexpected_response_error=Përgjigje shërbyesi e papritur. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Nënvizim {{type}}] +password_label=Jepni fjalëkalimin që të hapet kjo kartelë PDF. +password_invalid=Fjalëkalim i pavlefshëm. Ju lutemi, riprovoni. +password_ok=OK +password_cancel=Anuloje + +printing_not_supported=Kujdes: Shtypja nuk mbulohet plotësisht nga ky shfletues. +printing_not_ready=Kujdes: PDF-ja nuk është ngarkuar plotësisht që ta shtypni. +web_fonts_disabled=Shkronjat Web janë të çaktivizuara: i pazoti të përdorë shkronja të trupëzuara në PDF. + +document_colors_not_allowed=Dokumenteve PDF s’u lejohet të përdorin ngjyrat e tyre: 'Lejoji faqet t'i zgjedhin vetë ngjyrat' është e çaktivizuar te shfletuesi. diff --git a/static/pdf.js/locale/sr/viewer.ftl b/static/pdf.js/locale/sr/viewer.ftl deleted file mode 100644 index c678d491..00000000 --- a/static/pdf.js/locale/sr/viewer.ftl +++ /dev/null @@ -1,299 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Претходна страница -pdfjs-previous-button-label = Претходна -pdfjs-next-button = - .title = Следећа страница -pdfjs-next-button-label = Следећа -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Страница -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = од { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } од { $pagesCount }) -pdfjs-zoom-out-button = - .title = Умањи -pdfjs-zoom-out-button-label = Умањи -pdfjs-zoom-in-button = - .title = Увеличај -pdfjs-zoom-in-button-label = Увеличај -pdfjs-zoom-select = - .title = Увеличавање -pdfjs-presentation-mode-button = - .title = Промени на приказ у режиму презентације -pdfjs-presentation-mode-button-label = Режим презентације -pdfjs-open-file-button = - .title = Отвори датотеку -pdfjs-open-file-button-label = Отвори -pdfjs-print-button = - .title = Штампај -pdfjs-print-button-label = Штампај -pdfjs-save-button = - .title = Сачувај -pdfjs-save-button-label = Сачувај -pdfjs-bookmark-button = - .title = Тренутна страница (погледајте URL са тренутне странице) -pdfjs-bookmark-button-label = Тренутна страница -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Отвори у апликацији -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Отвори у апликацији - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Алатке -pdfjs-tools-button-label = Алатке -pdfjs-first-page-button = - .title = Иди на прву страницу -pdfjs-first-page-button-label = Иди на прву страницу -pdfjs-last-page-button = - .title = Иди на последњу страницу -pdfjs-last-page-button-label = Иди на последњу страницу -pdfjs-page-rotate-cw-button = - .title = Ротирај у смеру казаљке на сату -pdfjs-page-rotate-cw-button-label = Ротирај у смеру казаљке на сату -pdfjs-page-rotate-ccw-button = - .title = Ротирај у смеру супротном од казаљке на сату -pdfjs-page-rotate-ccw-button-label = Ротирај у смеру супротном од казаљке на сату -pdfjs-cursor-text-select-tool-button = - .title = Омогући алат за селектовање текста -pdfjs-cursor-text-select-tool-button-label = Алат за селектовање текста -pdfjs-cursor-hand-tool-button = - .title = Омогући алат за померање -pdfjs-cursor-hand-tool-button-label = Алат за померање -pdfjs-scroll-page-button = - .title = Користи скроловање по омоту -pdfjs-scroll-page-button-label = Скроловање странице -pdfjs-scroll-vertical-button = - .title = Користи вертикално скроловање -pdfjs-scroll-vertical-button-label = Вертикално скроловање -pdfjs-scroll-horizontal-button = - .title = Користи хоризонтално скроловање -pdfjs-scroll-horizontal-button-label = Хоризонтално скроловање -pdfjs-scroll-wrapped-button = - .title = Користи скроловање по омоту -pdfjs-scroll-wrapped-button-label = Скроловање по омоту -pdfjs-spread-none-button = - .title = Немој спајати ширења страница -pdfjs-spread-none-button-label = Без распростирања -pdfjs-spread-odd-button = - .title = Споји ширења страница које почињу непарним бројем -pdfjs-spread-odd-button-label = Непарна распростирања -pdfjs-spread-even-button = - .title = Споји ширења страница које почињу парним бројем -pdfjs-spread-even-button-label = Парна распростирања - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Параметри документа… -pdfjs-document-properties-button-label = Параметри документа… -pdfjs-document-properties-file-name = Име датотеке: -pdfjs-document-properties-file-size = Величина датотеке: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } B) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } B) -pdfjs-document-properties-title = Наслов: -pdfjs-document-properties-author = Аутор: -pdfjs-document-properties-subject = Тема: -pdfjs-document-properties-keywords = Кључне речи: -pdfjs-document-properties-creation-date = Датум креирања: -pdfjs-document-properties-modification-date = Датум модификације: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Стваралац: -pdfjs-document-properties-producer = PDF произвођач: -pdfjs-document-properties-version = PDF верзија: -pdfjs-document-properties-page-count = Број страница: -pdfjs-document-properties-page-size = Величина странице: -pdfjs-document-properties-page-size-unit-inches = ин -pdfjs-document-properties-page-size-unit-millimeters = мм -pdfjs-document-properties-page-size-orientation-portrait = усправно -pdfjs-document-properties-page-size-orientation-landscape = водоравно -pdfjs-document-properties-page-size-name-a-three = А3 -pdfjs-document-properties-page-size-name-a-four = А4 -pdfjs-document-properties-page-size-name-letter = Слово -pdfjs-document-properties-page-size-name-legal = Права - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Брз веб приказ: -pdfjs-document-properties-linearized-yes = Да -pdfjs-document-properties-linearized-no = Не -pdfjs-document-properties-close-button = Затвори - -## Print - -pdfjs-print-progress-message = Припремам документ за штампање… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Откажи -pdfjs-printing-not-supported = Упозорење: Штампање није у потпуности подржано у овом прегледачу. -pdfjs-printing-not-ready = Упозорење: PDF није у потпуности учитан за штампу. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Прикажи додатну палету -pdfjs-toggle-sidebar-notification-button = - .title = Прикажи/сакриј бочну траку (документ садржи контуру/прилоге/слојеве) -pdfjs-toggle-sidebar-button-label = Прикажи додатну палету -pdfjs-document-outline-button = - .title = Прикажи структуру документа (двоструким кликом проширујете/скупљате све ставке) -pdfjs-document-outline-button-label = Контура документа -pdfjs-attachments-button = - .title = Прикажи прилоге -pdfjs-attachments-button-label = Прилози -pdfjs-layers-button = - .title = Прикажи слојеве (дупли клик за враћање свих слојева у подразумевано стање) -pdfjs-layers-button-label = Слојеви -pdfjs-thumbs-button = - .title = Прикажи сличице -pdfjs-thumbs-button-label = Сличице -pdfjs-current-outline-item-button = - .title = Пронађите тренутни елемент структуре -pdfjs-current-outline-item-button-label = Тренутна контура -pdfjs-findbar-button = - .title = Пронађи у документу -pdfjs-findbar-button-label = Пронађи -pdfjs-additional-layers = Додатни слојеви - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Страница { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Сличица од странице { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Пронађи - .placeholder = Пронађи у документу… -pdfjs-find-previous-button = - .title = Пронађи претходно појављивање фразе -pdfjs-find-previous-button-label = Претходна -pdfjs-find-next-button = - .title = Пронађи следеће појављивање фразе -pdfjs-find-next-button-label = Следећа -pdfjs-find-highlight-checkbox = Истакнути све -pdfjs-find-match-case-checkbox-label = Подударања -pdfjs-find-match-diacritics-checkbox-label = Дијакритика -pdfjs-find-entire-word-checkbox-label = Целе речи -pdfjs-find-reached-top = Достигнут врх документа, наставио са дна -pdfjs-find-reached-bottom = Достигнуто дно документа, наставио са врха -pdfjs-find-not-found = Фраза није пронађена - -## Predefined zoom values - -pdfjs-page-scale-width = Ширина странице -pdfjs-page-scale-fit = Прилагоди страницу -pdfjs-page-scale-auto = Аутоматско увеличавање -pdfjs-page-scale-actual = Стварна величина -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Страница { $page } - -## Loading indicator messages - -pdfjs-loading-error = Дошло је до грешке приликом учитавања PDF-а. -pdfjs-invalid-file-error = PDF датотека је неважећа или је оштећена. -pdfjs-missing-file-error = Недостаје PDF датотека. -pdfjs-unexpected-response-error = Неочекиван одговор од сервера. -pdfjs-rendering-error = Дошло је до грешке приликом рендеровања ове странице. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } коментар] - -## Password - -pdfjs-password-label = Унесите лозинку да бисте отворили овај PDF докуменат. -pdfjs-password-invalid = Неисправна лозинка. Покушајте поново. -pdfjs-password-ok-button = У реду -pdfjs-password-cancel-button = Откажи -pdfjs-web-fonts-disabled = Веб фонтови су онемогућени: не могу користити уграђене PDF фонтове. - -## Editing - -pdfjs-editor-free-text-button = - .title = Текст -pdfjs-editor-free-text-button-label = Текст -pdfjs-editor-ink-button = - .title = Цртај -pdfjs-editor-ink-button-label = Цртај -# Editor Parameters -pdfjs-editor-free-text-color-input = Боја -pdfjs-editor-free-text-size-input = Величина -pdfjs-editor-ink-color-input = Боја -pdfjs-editor-ink-thickness-input = Дебљина -pdfjs-editor-ink-opacity-input = Опацитет -pdfjs-free-text = - .aria-label = Уређивач текста -pdfjs-free-text-default-content = Почни куцање… -pdfjs-ink = - .aria-label = Уређивач цртежа -pdfjs-ink-canvas = - .aria-label = Кориснички направљена слика - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/sr/viewer.properties b/static/pdf.js/locale/sr/viewer.properties new file mode 100644 index 00000000..bff06ca1 --- /dev/null +++ b/static/pdf.js/locale/sr/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Претходна страница +previous_label=Претходна +next.title=Следећа страница +next_label=Следећа + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Страница: +page_of=од {{pageCount}} + +zoom_out.title=Умањи +zoom_out_label=Умањи +zoom_in.title=Увеличај +zoom_in_label=Увеличај +zoom.title=Увеличавање +presentation_mode.title=Промени на приказ у режиму презентације +presentation_mode_label=Режим презентације +open_file.title=Отвори датотеку +open_file_label=Отвори +print.title=Штампај +print_label=Штампај +download.title=Преузми +download_label=Преузми +bookmark.title=Тренутни приказ (копирај или отвори нови прозор) +bookmark_label=Тренутни приказ + +# Secondary toolbar and context menu +tools.title=Алатке +tools_label=Алатке +first_page.title=Иди на прву страницу +first_page.label=Иди на прву страницу +first_page_label=Иди на прву страницу +last_page.title=Иди на последњу страницу +last_page.label=Иди на последњу страницу +last_page_label=Иди на последњу страницу +page_rotate_cw.title=Ротирај у смеру казаљке на сату +page_rotate_cw.label=Ротирај у смеру казаљке на сату +page_rotate_cw_label=Ротирај у смеру казаљке на сату +page_rotate_ccw.title=Ротирај у смеру супротном од казаљке на сату +page_rotate_ccw.label=Ротирај у смеру супротном од казаљке на сату +page_rotate_ccw_label=Ротирај у смеру супротном од казаљке на сату + +hand_tool_enable.title=Омогући алатку за померање +hand_tool_enable_label=Омогући алатку за померање +hand_tool_disable.title=Онемогући алатку за померање +hand_tool_disable_label=Онемогући алатку за померање + +# Document properties dialog box +document_properties.title=Параметри документа… +document_properties_label=Параметри документа… +document_properties_file_name=Име датотеке: +document_properties_file_size=Величина датотеке: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} B) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} B) +document_properties_title=Наслов: +document_properties_author=Аутор: +document_properties_subject=Тема: +document_properties_keywords=Кључне речи: +document_properties_creation_date=Датум креирања: +document_properties_modification_date=Датум модификације: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Стваралац: +document_properties_producer=PDF произвођач: +document_properties_version=PDF верзија: +document_properties_page_count=Број страница: +document_properties_close=Затвори + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Прикажи додатну палету +toggle_sidebar_label=Прикажи додатну палету +outline.title=Прикажи контуру документа +outline_label=Контура документа +attachments.title=Прикажи прилоге +attachments_label=Прилози +thumbs.title=Прикажи сличице +thumbs_label=Сличице +findbar.title=Пронађи у документу +findbar_label=Пронађи + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Страница {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Сличица од странице {{page}} + +# Find panel button title and messages +find_label=Пронађи: +find_previous.title=Пронађи претходну појаву фразе +find_previous_label=Претходна +find_next.title=Пронађи следећу појаву фразе +find_next_label=Следећа +find_highlight=Истакнути све +find_match_case_label=Подударања +find_reached_top=Достигнут врх документа, наставио са дна +find_reached_bottom=Достигнуто дно документа, наставио са врха +find_not_found=Фраза није пронађена + +# Error panel labels +error_more_info=Више информација +error_less_info=Мање информација +error_close=Затвори +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Порука: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Стек: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Датотека: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Линија: {{line}} +rendering_error=Дошло је до грешке приликом рендеровања ове странице. + +# Predefined zoom values +page_scale_width=Ширина странице +page_scale_fit=Прилагоди страницу +page_scale_auto=Аутоматско увеличавање +page_scale_actual=Стварна величина +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Грешка +loading_error=Дошло је до грешке приликом учитавања PDF-а. +invalid_file_error=PDF датотека је оштећена или је неисправна. +missing_file_error=PDF датотека није пронађена. +unexpected_response_error=Неочекиван одговор од сервера. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} коментар] +password_label=Унесите лозинку да бисте отворили овај PDF докуменат. +password_invalid=Неисправна лозинка. Покушајте поново. +password_ok=У реду +password_cancel=Откажи + +printing_not_supported=Упозорење: Штампање није у потпуности подржано у овом прегледачу. +printing_not_ready=Упозорење: PDF није у потпуности учитан за штампу. +web_fonts_disabled=Веб фонтови су онемогућени: не могу користити уграђене PDF фонтове. +document_colors_not_allowed=PDF документи не могу да користе сопствене боје: “Дозволи страницама да изаберу своје боје” је деактивирано у прегледачу. diff --git a/static/pdf.js/locale/sv-SE/viewer.ftl b/static/pdf.js/locale/sv-SE/viewer.ftl deleted file mode 100644 index 61d69867..00000000 --- a/static/pdf.js/locale/sv-SE/viewer.ftl +++ /dev/null @@ -1,402 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Föregående sida -pdfjs-previous-button-label = Föregående -pdfjs-next-button = - .title = Nästa sida -pdfjs-next-button-label = Nästa -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Sida -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = av { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } av { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zooma ut -pdfjs-zoom-out-button-label = Zooma ut -pdfjs-zoom-in-button = - .title = Zooma in -pdfjs-zoom-in-button-label = Zooma in -pdfjs-zoom-select = - .title = Zoom -pdfjs-presentation-mode-button = - .title = Byt till presentationsläge -pdfjs-presentation-mode-button-label = Presentationsläge -pdfjs-open-file-button = - .title = Öppna fil -pdfjs-open-file-button-label = Öppna -pdfjs-print-button = - .title = Skriv ut -pdfjs-print-button-label = Skriv ut -pdfjs-save-button = - .title = Spara -pdfjs-save-button-label = Spara -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Hämta -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Hämta -pdfjs-bookmark-button = - .title = Aktuell sida (Visa URL från aktuell sida) -pdfjs-bookmark-button-label = Aktuell sida -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Öppna i app -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Öppna i app - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Verktyg -pdfjs-tools-button-label = Verktyg -pdfjs-first-page-button = - .title = Gå till första sidan -pdfjs-first-page-button-label = Gå till första sidan -pdfjs-last-page-button = - .title = Gå till sista sidan -pdfjs-last-page-button-label = Gå till sista sidan -pdfjs-page-rotate-cw-button = - .title = Rotera medurs -pdfjs-page-rotate-cw-button-label = Rotera medurs -pdfjs-page-rotate-ccw-button = - .title = Rotera moturs -pdfjs-page-rotate-ccw-button-label = Rotera moturs -pdfjs-cursor-text-select-tool-button = - .title = Aktivera textmarkeringsverktyg -pdfjs-cursor-text-select-tool-button-label = Textmarkeringsverktyg -pdfjs-cursor-hand-tool-button = - .title = Aktivera handverktyg -pdfjs-cursor-hand-tool-button-label = Handverktyg -pdfjs-scroll-page-button = - .title = Använd sidrullning -pdfjs-scroll-page-button-label = Sidrullning -pdfjs-scroll-vertical-button = - .title = Använd vertikal rullning -pdfjs-scroll-vertical-button-label = Vertikal rullning -pdfjs-scroll-horizontal-button = - .title = Använd horisontell rullning -pdfjs-scroll-horizontal-button-label = Horisontell rullning -pdfjs-scroll-wrapped-button = - .title = Använd överlappande rullning -pdfjs-scroll-wrapped-button-label = Överlappande rullning -pdfjs-spread-none-button = - .title = Visa enkelsidor -pdfjs-spread-none-button-label = Enkelsidor -pdfjs-spread-odd-button = - .title = Visa uppslag med olika sidnummer till vänster -pdfjs-spread-odd-button-label = Uppslag med framsida -pdfjs-spread-even-button = - .title = Visa uppslag med lika sidnummer till vänster -pdfjs-spread-even-button-label = Uppslag utan framsida - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Dokumentegenskaper… -pdfjs-document-properties-button-label = Dokumentegenskaper… -pdfjs-document-properties-file-name = Filnamn: -pdfjs-document-properties-file-size = Filstorlek: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } kB ({ $size_b } byte) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } byte) -pdfjs-document-properties-title = Titel: -pdfjs-document-properties-author = Författare: -pdfjs-document-properties-subject = Ämne: -pdfjs-document-properties-keywords = Nyckelord: -pdfjs-document-properties-creation-date = Skapades: -pdfjs-document-properties-modification-date = Ändrades: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Skapare: -pdfjs-document-properties-producer = PDF-producent: -pdfjs-document-properties-version = PDF-version: -pdfjs-document-properties-page-count = Sidantal: -pdfjs-document-properties-page-size = Pappersstorlek: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = porträtt -pdfjs-document-properties-page-size-orientation-landscape = landskap -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Snabb webbvisning: -pdfjs-document-properties-linearized-yes = Ja -pdfjs-document-properties-linearized-no = Nej -pdfjs-document-properties-close-button = Stäng - -## Print - -pdfjs-print-progress-message = Förbereder sidor för utskrift… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Avbryt -pdfjs-printing-not-supported = Varning: Utskrifter stöds inte helt av den här webbläsaren. -pdfjs-printing-not-ready = Varning: PDF:en är inte klar för utskrift. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Visa/dölj sidofält -pdfjs-toggle-sidebar-notification-button = - .title = Växla sidofält (dokumentet innehåller dokumentstruktur/bilagor/lager) -pdfjs-toggle-sidebar-button-label = Visa/dölj sidofält -pdfjs-document-outline-button = - .title = Visa dokumentdisposition (dubbelklicka för att expandera/komprimera alla objekt) -pdfjs-document-outline-button-label = Dokumentöversikt -pdfjs-attachments-button = - .title = Visa Bilagor -pdfjs-attachments-button-label = Bilagor -pdfjs-layers-button = - .title = Visa lager (dubbelklicka för att återställa alla lager till standardläge) -pdfjs-layers-button-label = Lager -pdfjs-thumbs-button = - .title = Visa miniatyrer -pdfjs-thumbs-button-label = Miniatyrer -pdfjs-current-outline-item-button = - .title = Hitta aktuellt dispositionsobjekt -pdfjs-current-outline-item-button-label = Aktuellt dispositionsobjekt -pdfjs-findbar-button = - .title = Sök i dokument -pdfjs-findbar-button-label = Sök -pdfjs-additional-layers = Ytterligare lager - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Sida { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatyr av sida { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Sök - .placeholder = Sök i dokument… -pdfjs-find-previous-button = - .title = Hitta föregående förekomst av frasen -pdfjs-find-previous-button-label = Föregående -pdfjs-find-next-button = - .title = Hitta nästa förekomst av frasen -pdfjs-find-next-button-label = Nästa -pdfjs-find-highlight-checkbox = Markera alla -pdfjs-find-match-case-checkbox-label = Matcha versal/gemen -pdfjs-find-match-diacritics-checkbox-label = Matcha diakritiska tecken -pdfjs-find-entire-word-checkbox-label = Hela ord -pdfjs-find-reached-top = Nådde början av dokumentet, började från slutet -pdfjs-find-reached-bottom = Nådde slutet på dokumentet, började från början -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } av { $total } match - *[other] { $current } av { $total } matchningar - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Mer än { $limit } matchning - *[other] Fler än { $limit } matchningar - } -pdfjs-find-not-found = Frasen hittades inte - -## Predefined zoom values - -pdfjs-page-scale-width = Sidbredd -pdfjs-page-scale-fit = Anpassa sida -pdfjs-page-scale-auto = Automatisk zoom -pdfjs-page-scale-actual = Verklig storlek -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Sida { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ett fel uppstod vid laddning av PDF-filen. -pdfjs-invalid-file-error = Ogiltig eller korrupt PDF-fil. -pdfjs-missing-file-error = Saknad PDF-fil. -pdfjs-unexpected-response-error = Oväntat svar från servern. -pdfjs-rendering-error = Ett fel uppstod vid visning av sidan. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date } { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type }-annotering] - -## Password - -pdfjs-password-label = Skriv in lösenordet för att öppna PDF-filen. -pdfjs-password-invalid = Ogiltigt lösenord. Försök igen. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Avbryt -pdfjs-web-fonts-disabled = Webbtypsnitt är inaktiverade: kan inte använda inbäddade PDF-typsnitt. - -## Editing - -pdfjs-editor-free-text-button = - .title = Text -pdfjs-editor-free-text-button-label = Text -pdfjs-editor-ink-button = - .title = Rita -pdfjs-editor-ink-button-label = Rita -pdfjs-editor-stamp-button = - .title = Lägg till eller redigera bilder -pdfjs-editor-stamp-button-label = Lägg till eller redigera bilder -pdfjs-editor-highlight-button = - .title = Markera -pdfjs-editor-highlight-button-label = Markera -pdfjs-highlight-floating-button = - .title = Markera -pdfjs-highlight-floating-button1 = - .title = Markera - .aria-label = Markera -pdfjs-highlight-floating-button-label = Markera - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Ta bort ritning -pdfjs-editor-remove-freetext-button = - .title = Ta bort text -pdfjs-editor-remove-stamp-button = - .title = Ta bort bild -pdfjs-editor-remove-highlight-button = - .title = Ta bort markering - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Färg -pdfjs-editor-free-text-size-input = Storlek -pdfjs-editor-ink-color-input = Färg -pdfjs-editor-ink-thickness-input = Tjocklek -pdfjs-editor-ink-opacity-input = Opacitet -pdfjs-editor-stamp-add-image-button = - .title = Lägg till bild -pdfjs-editor-stamp-add-image-button-label = Lägg till bild -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Tjocklek -pdfjs-editor-free-highlight-thickness-title = - .title = Ändra tjocklek när du markerar andra objekt än text -pdfjs-free-text = - .aria-label = Textredigerare -pdfjs-free-text-default-content = Börja skriva… -pdfjs-ink = - .aria-label = Ritredigerare -pdfjs-ink-canvas = - .aria-label = Användarskapad bild - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternativ text -pdfjs-editor-alt-text-edit-button-label = Redigera alternativ text -pdfjs-editor-alt-text-dialog-label = Välj ett alternativ -pdfjs-editor-alt-text-dialog-description = Alt text (alternativ text) hjälper till när människor inte kan se bilden eller när den inte laddas. -pdfjs-editor-alt-text-add-description-label = Lägg till en beskrivning -pdfjs-editor-alt-text-add-description-description = Sikta på 1-2 meningar som beskriver ämnet, miljön eller handlingen. -pdfjs-editor-alt-text-mark-decorative-label = Markera som dekorativ -pdfjs-editor-alt-text-mark-decorative-description = Detta används för dekorativa bilder, som kanter eller vattenstämplar. -pdfjs-editor-alt-text-cancel-button = Avbryt -pdfjs-editor-alt-text-save-button = Spara -pdfjs-editor-alt-text-decorative-tooltip = Märkt som dekorativ -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Till exempel, "En ung man sätter sig vid ett bord för att äta en måltid" - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Det övre vänstra hörnet — ändra storlek -pdfjs-editor-resizer-label-top-middle = Överst i mitten — ändra storlek -pdfjs-editor-resizer-label-top-right = Det övre högra hörnet — ändra storlek -pdfjs-editor-resizer-label-middle-right = Mitten höger — ändra storlek -pdfjs-editor-resizer-label-bottom-right = Nedre högra hörnet — ändra storlek -pdfjs-editor-resizer-label-bottom-middle = Nedre mitten — ändra storlek -pdfjs-editor-resizer-label-bottom-left = Nedre vänstra hörnet — ändra storlek -pdfjs-editor-resizer-label-middle-left = Mitten till vänster — ändra storlek - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Markeringsfärg -pdfjs-editor-colorpicker-button = - .title = Ändra färg -pdfjs-editor-colorpicker-dropdown = - .aria-label = Färgval -pdfjs-editor-colorpicker-yellow = - .title = Gul -pdfjs-editor-colorpicker-green = - .title = Grön -pdfjs-editor-colorpicker-blue = - .title = Blå -pdfjs-editor-colorpicker-pink = - .title = Rosa -pdfjs-editor-colorpicker-red = - .title = Röd - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Visa alla -pdfjs-editor-highlight-show-all-button = - .title = Visa alla diff --git a/static/pdf.js/locale/sv-SE/viewer.properties b/static/pdf.js/locale/sv-SE/viewer.properties new file mode 100644 index 00000000..97be61df --- /dev/null +++ b/static/pdf.js/locale/sv-SE/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Föregående sida +previous_label=Föregående +next.title=Nästa sida +next_label=Nästa + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Sida: +page_of=av {{pageCount}} + +zoom_out.title=Zooma ut +zoom_out_label=Zooma ut +zoom_in.title=Zooma in +zoom_in_label=Zooma in +zoom.title=Zoom +presentation_mode.title=Byt till presentationsläge +presentation_mode_label=Presentationsläge +open_file.title=Öppna fil +open_file_label=Öppna +print.title=Skriv ut +print_label=Skriv ut +download.title=Hämta +download_label=Hämta +bookmark.title=Aktuell vy (kopiera eller öppna i nytt fönster) +bookmark_label=Aktuell vy + +# Secondary toolbar and context menu +tools.title=Verktyg +tools_label=Verktyg +first_page.title=Gå till första sidan +first_page.label=Gå till första sidan +first_page_label=Gå till första sidan +last_page.title=Gå till sista sidan +last_page.label=Gå till sista sidan +last_page_label=Gå till sista sidan +page_rotate_cw.title=Rotera medurs +page_rotate_cw.label=Rotera medurs +page_rotate_cw_label=Rotera medurs +page_rotate_ccw.title=Rotera moturs +page_rotate_ccw.label=Rotera moturs +page_rotate_ccw_label=Rotera moturs + +hand_tool_enable.title=Aktivera handverktyg +hand_tool_enable_label=Aktivera handverktyg +hand_tool_disable.title=Inaktivera handverktyg +hand_tool_disable_label=Inaktivera handverktyg + +# Document properties dialog box +document_properties.title=Dokumentegenskaper… +document_properties_label=Dokumentegenskaper… +document_properties_file_name=Filnamn: +document_properties_file_size=Filstorlek: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} kB ({{size_b}} byte) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} byte) +document_properties_title=Titel: +document_properties_author=Författare: +document_properties_subject=Ämne: +document_properties_keywords=Nyckelord: +document_properties_creation_date=Skapades: +document_properties_modification_date=Ändrades: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Skapare: +document_properties_producer=PDF-producent: +document_properties_version=PDF-version: +document_properties_page_count=Sidantal: +document_properties_close=Stäng + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Visa/dölj sidofält +toggle_sidebar_label=Visa/dölj sidofält +outline.title=Visa dokumentöversikt +outline_label=Dokumentöversikt +attachments.title=Visa Bilagor +attachments_label=Bilagor +thumbs.title=Visa miniatyrer +thumbs_label=Miniatyrer +findbar.title=Sök i dokument +findbar_label=Sök + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Sida {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatyr av sida {{page}} + +# Find panel button title and messages +find_label=Sök: +find_previous.title=Hitta föregående förekomst av frasen +find_previous_label=Föregående +find_next.title=Hitta nästa förekomst av frasen +find_next_label=Nästa +find_highlight=Markera alla +find_match_case_label=Matcha versal/gemen +find_reached_top=Nådde början av dokumentet, började från slutet +find_reached_bottom=Nådde slutet på dokumentet, började från början +find_not_found=Frasen hittades inte + +# Error panel labels +error_more_info=Mer information +error_less_info=Mindre information +error_close=Stäng +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Meddelande: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fil: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rad: {{line}} +rendering_error=Ett fel uppstod vid visning av sidan. + +# Predefined zoom values +page_scale_width=Sidbredd +page_scale_fit=Anpassa sida +page_scale_auto=Automatisk zoom +page_scale_actual=Verklig storlek +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Fel +loading_error=Ett fel uppstod vid laddning av PDF-filen. +invalid_file_error=Ogiltig eller korrupt PDF-fil. +missing_file_error=Saknad PDF-fil. +unexpected_response_error=Oväntat svar från servern. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}}-annotering] +password_label=Skriv in lösenordet för att öppna PDF-filen. +password_invalid=Ogiltigt lösenord. Försök igen. +password_ok=OK +password_cancel=Avbryt + +printing_not_supported=Varning: Utskrifter stöds inte helt av den här webbläsaren. +printing_not_ready=Varning: PDF:en är inte klar för utskrift. +web_fonts_disabled=Webbtypsnitt är inaktiverade: kan inte använda inbäddade PDF-typsnitt. +document_colors_not_allowed=PDF-dokument tillåts inte använda egna färger: 'Låt sidor använda egna färger' är inaktiverat i webbläsaren. diff --git a/static/pdf.js/locale/sv/viewer.properties b/static/pdf.js/locale/sv/viewer.properties new file mode 100644 index 00000000..92312851 --- /dev/null +++ b/static/pdf.js/locale/sv/viewer.properties @@ -0,0 +1,142 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Föregående sida +previous_label=Föregående +next.title=Nästa sida +next_label=Nästa + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Sida: +page_of=av {{pageCount}} + +zoom_out.title=Zooma ut +zoom_out_label=Zooma ut +zoom_in.title=Zooma in +zoom_in_label=Zooma in +zoom.title=Zooma +presentation_mode.title=Presentationsläge +presentation_mode_label=Presentationsläge +open_file.title=Öppna fil +open_file_label=Öppna +print.title=Skriv ut +print_label=Skriv ut +download.title=Ladda ner +download_label=Ladda ner +bookmark.title=Aktuell vy (kopiera eller öppna i nytt fönster) +bookmark_label=Aktuell vy + +# Secondary toolbar and context menu +tools.title=Verktyg +tools_label=Verktyg +first_page.title=Gå till första sidan +first_page.label=Gå till första sidan +first_page_label=Gå till första sidan +last_page.title=Gå till sista sidan +last_page.label=Gå till sista sidan +last_page_label=Gå till sista sidan +page_rotate_cw.title=Rotera medurs +page_rotate_cw.label=Rotera medurs +page_rotate_cw_label=Rotera medurs +page_rotate_ccw.title=Rotera moturs +page_rotate_ccw.label=Rotera moturs +page_rotate_ccw_label=Rotera moturs + +hand_tool_enable.title=Aktivera handverktyget +hand_tool_enable_label=Aktivera handverktyget +hand_tool_disable.title=Avaktivera handverktyget +hand_tool_disable_label=Avaktivera handverktyget + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Visa/Dölj sidopanel +toggle_sidebar_label=Visa/Dölj sidopanel +outline.title=Visa bokmärken +outline_label=Bokmärken +thumbs.title=Visa sidminiatyrer +thumbs_label=Sidminiatyrer +findbar.title=Sök i dokumentet +findbar_label=Sök + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Sida {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Miniatyr av sida {{page}} + +# Find panel button title and messages +find_label=Sök: +find_previous.title=Hitta föregående förekomst av frasen +find_previous_label=Föregående +find_next.title=Hitta nästa förekomst av frasen +find_next_label=Nästa +find_highlight=Markera alla +find_match_case_label=Matcha VERSALER/gemener +find_reached_top=Kommit till början av dokumentet, börjat om +find_reached_bottom=Kommit till slutet av dokumentet, börjat om +find_not_found=Frasen hittades inte + +# Error panel labels +error_more_info=Mer information +error_less_info=Mindre information +error_close=Stäng +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (bygge: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Meddelande: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Fil: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rad: {{line}} +rendering_error=Ett fel inträffade när sidan renderades. + +# Predefined zoom values +page_scale_width=Sidbredd +page_scale_fit=Helsida +page_scale_auto=Automatisk zoom +page_scale_actual=Faktisk storlek + +# Loading indicator messages +loading_error_indicator=Fel +loading_error=Ett fel inträffade när PDF-filen laddades. +invalid_file_error=Ogiltig eller korrupt PDF-fil. +missing_file_error=PDF-filen saknas. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}}-anteckning] + +password_label=Ange lösenordet för att öppna PDF-filen. +password_invalid=Felaktigt lösenord. Försök igen. +password_ok=OK +password_cancel=Avbryt + +printing_not_supported=Varning: Utskrifter stöds inte fullt ut av denna webbläsare. +printing_not_ready=Varning: Hela PDF-filen måste laddas innan utskrift kan ske. +web_fonts_disabled=Webbtypsnitt är inaktiverade: Typsnitt inbäddade i PDF-filer kan inte användas. +document_colors_disabled=PDF-dokument kan inte använda egna färger: \'Låt sidor använda egna färger\' är inaktiverat i webbläsaren. diff --git a/static/pdf.js/locale/sw/viewer.properties b/static/pdf.js/locale/sw/viewer.properties new file mode 100644 index 00000000..7f0f1b8c --- /dev/null +++ b/static/pdf.js/locale/sw/viewer.properties @@ -0,0 +1,129 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Ukurasa Uliotangulia +previous_label=Iliyotangulia +next.title=Ukurasa Ufuatao +next_label=Ifuatayo + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Ukurasa: +page_of=ya {{Hesabu ya ukurasa}} + +zoom_out.title=Kuza Nje +zoom_out_label=Kuza Nje +zoom_in.title=Kuza Ndani +zoom_in_label=Kuza Ndani +zoom.title=Kuza +presentation_mode.title=Badili kwa Hali ya Uwasilishaji +presentation_mode_label=Hali ya Uwasilishaji +open_file.title=Fungua Faili +open_file_label=Fungua +print.title=Chapisha +print_label=Chapisha +download.title=Pakua +download_label=Pakua +bookmark.title=Mwonekano wa sasa (nakili au ufungue katika dirisha mpya) +bookmark_label=Mwonekano wa Sasa + +# Secondary toolbar and context menu + + +# Document properties dialog box +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Kichwa: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Kibiano cha Upau wa Kando +toggle_sidebar_label=Kibiano cha Upau wa Kando +outline.title=Onyesha Ufupisho wa Waraka +outline_label=Ufupisho wa Waraka +thumbs.title=Onyesha Kijipicha +thumbs_label=Vijipicha +findbar.title=Pata katika Waraka +findbar_label=Tafuta + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Ukurasa {{ukurasa}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Kijipicha cha ukurasa {{ukurasa}} + +# Find panel button title and messages +find_label=Tafuta: +find_previous.title=Tafuta tukio kabla ya msemo huu +find_previous_label=Iliyotangulia +find_next.title=Tafuta tukio linalofuata la msemo +find_next_label=Ifuatayo +find_highlight=Angazia yote +find_match_case_label=Linganisha herufi +find_reached_top=Imefika juu ya waraka, imeendelea kutoka chini +find_reached_bottom=Imefika mwisho wa waraka, imeendelea kutoka juu +find_not_found=Msemo hukupatikana + +# Error panel labels +error_more_info=Maelezo Zaidi +error_less_info=Maelezo Kidogo +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (jenga: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Ujumbe: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Panganya: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Faili: {{faili}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Laini: {{laini}} +rendering_error=Hitilafu lilitokea wajati wa kutoa ukurasa + +# Predefined zoom values +page_scale_width=Upana wa Ukurasa +page_scale_fit=Usawa wa Ukurasa +page_scale_auto=Ukuzaji wa Kiotomatiki +page_scale_actual=Ukubwa Halisi +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Hitilafu +loading_error=Hitilafu lilitokea wakati wa kupakia PDF. +invalid_file_error=Faili ya PDF isiyohalali au potofu. +missing_file_error=Faili ya PDF isiyopo. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Ufafanuzi] +password_ok=SAWA +password_cancel=Ghairi + +printing_not_supported=Onyo: Uchapishaji hauauniwi kabisa kwa kivinjari hiki. +web_fonts_disabled=Fonti za tovuti zimelemazwa: haziwezi kutumia fonti za PDF zilizopachikwa. diff --git a/static/pdf.js/locale/szl/viewer.ftl b/static/pdf.js/locale/szl/viewer.ftl deleted file mode 100644 index cbf166e4..00000000 --- a/static/pdf.js/locale/szl/viewer.ftl +++ /dev/null @@ -1,257 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Piyrwyjszo strōna -pdfjs-previous-button-label = Piyrwyjszo -pdfjs-next-button = - .title = Nastympno strōna -pdfjs-next-button-label = Dalij -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Strōna -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = ze { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } ze { $pagesCount }) -pdfjs-zoom-out-button = - .title = Zmyńsz -pdfjs-zoom-out-button-label = Zmyńsz -pdfjs-zoom-in-button = - .title = Zwiynksz -pdfjs-zoom-in-button-label = Zwiynksz -pdfjs-zoom-select = - .title = Srogość -pdfjs-presentation-mode-button = - .title = Przełōncz na tryb prezyntacyje -pdfjs-presentation-mode-button-label = Tryb prezyntacyje -pdfjs-open-file-button = - .title = Ôdewrzij zbiōr -pdfjs-open-file-button-label = Ôdewrzij -pdfjs-print-button = - .title = Durkuj -pdfjs-print-button-label = Durkuj - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Noczynia -pdfjs-tools-button-label = Noczynia -pdfjs-first-page-button = - .title = Idź ku piyrszyj strōnie -pdfjs-first-page-button-label = Idź ku piyrszyj strōnie -pdfjs-last-page-button = - .title = Idź ku ôstatnij strōnie -pdfjs-last-page-button-label = Idź ku ôstatnij strōnie -pdfjs-page-rotate-cw-button = - .title = Zwyrtnij w prawo -pdfjs-page-rotate-cw-button-label = Zwyrtnij w prawo -pdfjs-page-rotate-ccw-button = - .title = Zwyrtnij w lewo -pdfjs-page-rotate-ccw-button-label = Zwyrtnij w lewo -pdfjs-cursor-text-select-tool-button = - .title = Załōncz noczynie ôbiyranio tekstu -pdfjs-cursor-text-select-tool-button-label = Noczynie ôbiyranio tekstu -pdfjs-cursor-hand-tool-button = - .title = Załōncz noczynie rōnczka -pdfjs-cursor-hand-tool-button-label = Noczynie rōnczka -pdfjs-scroll-vertical-button = - .title = Używej piōnowego przewijanio -pdfjs-scroll-vertical-button-label = Piōnowe przewijanie -pdfjs-scroll-horizontal-button = - .title = Używej poziōmego przewijanio -pdfjs-scroll-horizontal-button-label = Poziōme przewijanie -pdfjs-scroll-wrapped-button = - .title = Używej szichtowego przewijanio -pdfjs-scroll-wrapped-button-label = Szichtowe przewijanie -pdfjs-spread-none-button = - .title = Niy dowej strōn w widoku po dwie -pdfjs-spread-none-button-label = Po jednyj strōnie -pdfjs-spread-odd-button = - .title = Pokoż strōny po dwie; niyporziste po lewyj -pdfjs-spread-odd-button-label = Niyporziste po lewyj -pdfjs-spread-even-button = - .title = Pokoż strōny po dwie; porziste po lewyj -pdfjs-spread-even-button-label = Porziste po lewyj - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Włosności dokumyntu… -pdfjs-document-properties-button-label = Włosności dokumyntu… -pdfjs-document-properties-file-name = Miano zbioru: -pdfjs-document-properties-file-size = Srogość zbioru: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } B) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } B) -pdfjs-document-properties-title = Tytuł: -pdfjs-document-properties-author = Autōr: -pdfjs-document-properties-subject = Tymat: -pdfjs-document-properties-keywords = Kluczowe słowa: -pdfjs-document-properties-creation-date = Data zrychtowanio: -pdfjs-document-properties-modification-date = Data zmiany: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Zrychtowane ôd: -pdfjs-document-properties-producer = PDF ôd: -pdfjs-document-properties-version = Wersyjo PDF: -pdfjs-document-properties-page-count = Wielość strōn: -pdfjs-document-properties-page-size = Srogość strōny: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = piōnowo -pdfjs-document-properties-page-size-orientation-landscape = poziōmo -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Gibki necowy podglōnd: -pdfjs-document-properties-linearized-yes = Ja -pdfjs-document-properties-linearized-no = Niy -pdfjs-document-properties-close-button = Zawrzij - -## Print - -pdfjs-print-progress-message = Rychtowanie dokumyntu do durku… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Pociep -pdfjs-printing-not-supported = Pozōr: Ta przeglōndarka niy cołkiym ôbsuguje durk. -pdfjs-printing-not-ready = Pozōr: Tyn PDF niy ma za tela zaladowany do durku. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Przełōncz posek na rancie -pdfjs-toggle-sidebar-notification-button = - .title = Przełōncz posek na rancie (dokumynt mo struktura/przidowki/warstwy) -pdfjs-toggle-sidebar-button-label = Przełōncz posek na rancie -pdfjs-document-outline-button = - .title = Pokoż struktura dokumyntu (tuplowane klikniyncie rozszyrzo/swijo wszyskie elymynta) -pdfjs-document-outline-button-label = Struktura dokumyntu -pdfjs-attachments-button = - .title = Pokoż przidowki -pdfjs-attachments-button-label = Przidowki -pdfjs-layers-button = - .title = Pokoż warstwy (tuplowane klikniyncie resetuje wszyskie warstwy do bazowego stanu) -pdfjs-layers-button-label = Warstwy -pdfjs-thumbs-button = - .title = Pokoż miniatury -pdfjs-thumbs-button-label = Miniatury -pdfjs-findbar-button = - .title = Znojdź w dokumyncie -pdfjs-findbar-button-label = Znojdź -pdfjs-additional-layers = Nadbytnie warstwy - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Strōna { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Miniatura strōny { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Znojdź - .placeholder = Znojdź w dokumyncie… -pdfjs-find-previous-button = - .title = Znojdź piyrwyjsze pokozanie sie tyj frazy -pdfjs-find-previous-button-label = Piyrwyjszo -pdfjs-find-next-button = - .title = Znojdź nastympne pokozanie sie tyj frazy -pdfjs-find-next-button-label = Dalij -pdfjs-find-highlight-checkbox = Zaznacz wszysko -pdfjs-find-match-case-checkbox-label = Poznowej srogość liter -pdfjs-find-entire-word-checkbox-label = Cołke słowa -pdfjs-find-reached-top = Doszło do samego wiyrchu strōny, dalij ôd spodku -pdfjs-find-reached-bottom = Doszło do samego spodku strōny, dalij ôd wiyrchu -pdfjs-find-not-found = Fraza niy znaleziōno - -## Predefined zoom values - -pdfjs-page-scale-width = Szyrzka strōny -pdfjs-page-scale-fit = Napasowanie strōny -pdfjs-page-scale-auto = Autōmatyczno srogość -pdfjs-page-scale-actual = Aktualno srogość -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Przi ladowaniu PDFa pokozoł sie feler. -pdfjs-invalid-file-error = Zły abo felerny zbiōr PDF. -pdfjs-missing-file-error = Chybio zbioru PDF. -pdfjs-unexpected-response-error = Niyôczekowano ôdpowiydź serwera. -pdfjs-rendering-error = Przi renderowaniu strōny pokozoł sie feler. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Anotacyjo typu { $type }] - -## Password - -pdfjs-password-label = Wkludź hasło, coby ôdewrzić tyn zbiōr PDF. -pdfjs-password-invalid = Hasło je złe. Sprōbuj jeszcze roz. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Pociep -pdfjs-web-fonts-disabled = Necowe fōnty sōm zastawiōne: niy idzie użyć wkludzōnych fōntōw PDF. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ta-LK/viewer.properties b/static/pdf.js/locale/ta-LK/viewer.properties new file mode 100644 index 00000000..178b6199 --- /dev/null +++ b/static/pdf.js/locale/ta-LK/viewer.properties @@ -0,0 +1,72 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. + +zoom.title=அளவு +open_file.title=கோப்பினைத் திறக்க +open_file_label=திறக்க + +# Secondary toolbar and context menu + + +# Document properties dialog box +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. + +# Find panel button title and messages +find_previous.title=இந்த சொற்றொடரின் முன்னைய நிகழ்வை தேடு +find_next.title=இந்த சொற்றொடரின் அடுத்த நிகழ்வைத் தேடு + +# Error panel labels +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number + +# Predefined zoom values +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +password_ok=ஆம் + diff --git a/static/pdf.js/locale/ta/viewer.ftl b/static/pdf.js/locale/ta/viewer.ftl deleted file mode 100644 index 82cf1970..00000000 --- a/static/pdf.js/locale/ta/viewer.ftl +++ /dev/null @@ -1,223 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = முந்தைய பக்கம் -pdfjs-previous-button-label = முந்தையது -pdfjs-next-button = - .title = அடுத்த பக்கம் -pdfjs-next-button-label = அடுத்து -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = பக்கம் -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } இல் -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = { $pagesCount }) இல் ({ $pageNumber } -pdfjs-zoom-out-button = - .title = சிறிதாக்கு -pdfjs-zoom-out-button-label = சிறிதாக்கு -pdfjs-zoom-in-button = - .title = பெரிதாக்கு -pdfjs-zoom-in-button-label = பெரிதாக்கு -pdfjs-zoom-select = - .title = பெரிதாக்கு -pdfjs-presentation-mode-button = - .title = விளக்ககாட்சி பயன்முறைக்கு மாறு -pdfjs-presentation-mode-button-label = விளக்ககாட்சி பயன்முறை -pdfjs-open-file-button = - .title = கோப்பினை திற -pdfjs-open-file-button-label = திற -pdfjs-print-button = - .title = அச்சிடு -pdfjs-print-button-label = அச்சிடு - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = கருவிகள் -pdfjs-tools-button-label = கருவிகள் -pdfjs-first-page-button = - .title = முதல் பக்கத்திற்கு செல்லவும் -pdfjs-first-page-button-label = முதல் பக்கத்திற்கு செல்லவும் -pdfjs-last-page-button = - .title = கடைசி பக்கத்திற்கு செல்லவும் -pdfjs-last-page-button-label = கடைசி பக்கத்திற்கு செல்லவும் -pdfjs-page-rotate-cw-button = - .title = வலஞ்சுழியாக சுழற்று -pdfjs-page-rotate-cw-button-label = வலஞ்சுழியாக சுழற்று -pdfjs-page-rotate-ccw-button = - .title = இடஞ்சுழியாக சுழற்று -pdfjs-page-rotate-ccw-button-label = இடஞ்சுழியாக சுழற்று -pdfjs-cursor-text-select-tool-button = - .title = உரைத் தெரிவு கருவியைச் செயல்படுத்து -pdfjs-cursor-text-select-tool-button-label = உரைத் தெரிவு கருவி -pdfjs-cursor-hand-tool-button = - .title = கைக் கருவிக்ச் செயற்படுத்து -pdfjs-cursor-hand-tool-button-label = கைக்குருவி - -## Document properties dialog - -pdfjs-document-properties-button = - .title = ஆவண பண்புகள்... -pdfjs-document-properties-button-label = ஆவண பண்புகள்... -pdfjs-document-properties-file-name = கோப்பு பெயர்: -pdfjs-document-properties-file-size = கோப்பின் அளவு: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } கிபை ({ $size_b } பைட்டுகள்) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } மெபை ({ $size_b } பைட்டுகள்) -pdfjs-document-properties-title = தலைப்பு: -pdfjs-document-properties-author = எழுதியவர் -pdfjs-document-properties-subject = பொருள்: -pdfjs-document-properties-keywords = முக்கிய வார்த்தைகள்: -pdfjs-document-properties-creation-date = படைத்த தேதி : -pdfjs-document-properties-modification-date = திருத்திய தேதி: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = உருவாக்குபவர்: -pdfjs-document-properties-producer = பிடிஎஃப் தயாரிப்பாளர்: -pdfjs-document-properties-version = PDF பதிப்பு: -pdfjs-document-properties-page-count = பக்க எண்ணிக்கை: -pdfjs-document-properties-page-size = பக்க அளவு: -pdfjs-document-properties-page-size-unit-inches = இதில் -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = நிலைபதிப்பு -pdfjs-document-properties-page-size-orientation-landscape = நிலைபரப்பு -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = கடிதம் -pdfjs-document-properties-page-size-name-legal = சட்டபூர்வ - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-close-button = மூடுக - -## Print - -pdfjs-print-progress-message = அச்சிடுவதற்கான ஆவணம் தயாராகிறது... -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = ரத்து -pdfjs-printing-not-supported = எச்சரிக்கை: இந்த உலாவி அச்சிடுதலை முழுமையாக ஆதரிக்கவில்லை. -pdfjs-printing-not-ready = எச்சரிக்கை: PDF அச்சிட முழுவதுமாக ஏற்றப்படவில்லை. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = பக்கப் பட்டியை நிலைமாற்று -pdfjs-toggle-sidebar-button-label = பக்கப் பட்டியை நிலைமாற்று -pdfjs-document-outline-button = - .title = ஆவண அடக்கத்தைக் காட்டு (இருமுறைச் சொடுக்கி அனைத்து உறுப்பிடிகளையும் விரி/சேர்) -pdfjs-document-outline-button-label = ஆவண வெளிவரை -pdfjs-attachments-button = - .title = இணைப்புகளை காண்பி -pdfjs-attachments-button-label = இணைப்புகள் -pdfjs-thumbs-button = - .title = சிறுபடங்களைக் காண்பி -pdfjs-thumbs-button-label = சிறுபடங்கள் -pdfjs-findbar-button = - .title = ஆவணத்தில் கண்டறி -pdfjs-findbar-button-label = தேடு - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = பக்கம் { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = பக்கத்தின் சிறுபடம் { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = கண்டுபிடி - .placeholder = ஆவணத்தில் கண்டறி… -pdfjs-find-previous-button = - .title = இந்த சொற்றொடரின் முந்தைய நிகழ்வை தேடு -pdfjs-find-previous-button-label = முந்தையது -pdfjs-find-next-button = - .title = இந்த சொற்றொடரின் அடுத்த நிகழ்வை தேடு -pdfjs-find-next-button-label = அடுத்து -pdfjs-find-highlight-checkbox = அனைத்தையும் தனிப்படுத்து -pdfjs-find-match-case-checkbox-label = பேரெழுத்தாக்கத்தை உணர் -pdfjs-find-reached-top = ஆவணத்தின் மேல் பகுதியை அடைந்தது, அடிப்பக்கத்திலிருந்து தொடர்ந்தது -pdfjs-find-reached-bottom = ஆவணத்தின் முடிவை அடைந்தது, மேலிருந்து தொடர்ந்தது -pdfjs-find-not-found = சொற்றொடர் காணவில்லை - -## Predefined zoom values - -pdfjs-page-scale-width = பக்க அகலம் -pdfjs-page-scale-fit = பக்கப் பொருத்தம் -pdfjs-page-scale-auto = தானியக்க பெரிதாக்கல் -pdfjs-page-scale-actual = உண்மையான அளவு -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF ஐ ஏற்றும் போது ஒரு பிழை ஏற்பட்டது. -pdfjs-invalid-file-error = செல்லுபடியாகாத அல்லது சிதைந்த PDF கோப்பு. -pdfjs-missing-file-error = PDF கோப்பு காணவில்லை. -pdfjs-unexpected-response-error = சேவகன் பதில் எதிர்பாரதது. -pdfjs-rendering-error = இந்தப் பக்கத்தை காட்சிப்படுத்தும் போது ஒரு பிழை ஏற்பட்டது. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } விளக்கம்] - -## Password - -pdfjs-password-label = இந்த PDF கோப்பை திறக்க கடவுச்சொல்லை உள்ளிடவும். -pdfjs-password-invalid = செல்லுபடியாகாத கடவுச்சொல், தயை செய்து மீண்டும் முயற்சி செய்க. -pdfjs-password-ok-button = சரி -pdfjs-password-cancel-button = ரத்து -pdfjs-web-fonts-disabled = வலை எழுத்துருக்கள் முடக்கப்பட்டுள்ளன: உட்பொதிக்கப்பட்ட PDF எழுத்துருக்களைப் பயன்படுத்த முடியவில்லை. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ta/viewer.properties b/static/pdf.js/locale/ta/viewer.properties new file mode 100644 index 00000000..b0d40f1e --- /dev/null +++ b/static/pdf.js/locale/ta/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=முந்தைய பக்கம் +previous_label=முந்தையது +next.title=அடுத்த பக்கம் +next_label=அடுத்து + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=பக்கம்: +page_of=இல் {{pageCount}} + +zoom_out.title=சிறிதாக்கு +zoom_out_label=சிறிதாக்கு +zoom_in.title=பெரிதாக்கு +zoom_in_label=பெரிதாக்கு +zoom.title=பெரிதாக்கு +presentation_mode.title=விளக்ககாட்சி பயன்முறைக்கு மாறு +presentation_mode_label=விளக்ககாட்சி பயன்முறை +open_file.title=கோப்பினை திற +open_file_label=திற +print.title=அச்சிடு +print_label=அச்சிடு +download.title=பதிவிறக்கு +download_label=பதிவிறக்கு +bookmark.title=தற்போதைய காட்சி (புதிய சாளரத்திற்கு நகலெடு அல்லது புதிய சாளரத்தில் திற) +bookmark_label=தற்போதைய காட்சி + +# Secondary toolbar and context menu +tools.title=கருவிகள் +tools_label=கருவிகள் +first_page.title=முதல் பக்கத்திற்கு செல்லவும் +first_page.label=முதல் பக்கத்திற்கு செல்லவும் +first_page_label=முதல் பக்கத்திற்கு செல்லவும் +last_page.title=கடைசி பக்கத்திற்கு செல்லவும் +last_page.label=கடைசி பக்கத்திற்கு செல்லவும் +last_page_label=கடைசி பக்கத்திற்கு செல்லவும் +page_rotate_cw.title=வலஞ்சுழியாக சுழற்று +page_rotate_cw.label=வலஞ்சுழியாக சுழற்று +page_rotate_cw_label=வலஞ்சுழியாக சுழற்று +page_rotate_ccw.title=இடஞ்சுழியாக சுழற்று +page_rotate_ccw.label=இடஞ்சுழியாக சுழற்று +page_rotate_ccw_label=இடஞ்சுழியாக சுழற்று + +hand_tool_enable.title=கை கருவியை செயலாக்கு +hand_tool_enable_label=கை கருவியை செயலாக்கு +hand_tool_disable.title=கை கருவியை முடக்கு +hand_tool_disable_label=கை கருவியை முடக்கு + +# Document properties dialog box +document_properties.title=ஆவண பண்புகள்... +document_properties_label=ஆவண பண்புகள்... +document_properties_file_name=கோப்பு பெயர்: +document_properties_file_size=கோப்பின் அளவு: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} கிபை ({{size_b}} பைட்டுகள்) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} மெபை ({{size_b}} பைட்டுகள்) +document_properties_title=தலைப்பு: +document_properties_author=எழுதியவர் +document_properties_subject=பொருள்: +document_properties_keywords=முக்கிய வார்த்தைகள்: +document_properties_creation_date=படைத்த தேதி : +document_properties_modification_date=திருத்திய தேதி: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=உருவாக்குபவர்: +document_properties_producer=பிடிஎஃப் தயாரிப்பாளர்: +document_properties_version=PDF பதிப்பு: +document_properties_page_count=பக்க எண்ணிக்கை: +document_properties_close=மூடுக + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=பக்கப் பட்டியை நிலைமாற்று +toggle_sidebar_label=பக்கப் பட்டியை நிலைமாற்று +outline.title=ஆவண வெளிவரையைக் காண்பி +outline_label=ஆவண வெளிவரை +attachments.title=இணைப்புகளை காண்பி +attachments_label=இணைப்புகள் +thumbs.title=சிறுபடங்களைக் காண்பி +thumbs_label=சிறுபடங்கள் +findbar.title=ஆவணத்தில் கண்டறி +findbar_label=கண்டுபிடி + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=பக்கம் {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=பக்கத்தின் சிறுபடம் {{page}} + +# Find panel button title and messages +find_label=கண்டறி: +find_previous.title=இந்த சொற்றொடரின் முந்தைய நிகழ்வை தேடு +find_previous_label=முந்தையது +find_next.title=இந்த சொற்றொடரின் அடுத்த நிகழ்வை தேடு +find_next_label=அடுத்து +find_highlight=அனைத்தையும் தனிப்படுத்து +find_match_case_label=பேரெழுத்தாக்கத்தை உணர் +find_reached_top=ஆவணத்தின் மேல் பகுதியை அடைந்தது, அடிப்பக்கத்திலிருந்து தொடர்ந்தது +find_reached_bottom=ஆவணத்தின் முடிவை அடைந்தது, மேலிருந்து தொடர்ந்தது +find_not_found=சொற்றொடர் காணவில்லை + +# Error panel labels +error_more_info=கூடுதல் தகவல் +error_less_info=குறைந்த தகவல் +error_close=மூடுக +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=செய்தி: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=ஸ்டேக்: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=கோப்பு: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=வரி: {{line}} +rendering_error=இந்தப் பக்கத்தை காட்சிப்படுத்தும் போது ஒரு பிழை ஏற்பட்டது. + +# Predefined zoom values +page_scale_width=பக்க அகலம் +page_scale_fit=பக்கப் பொருத்தம் +page_scale_auto=தானியக்க பெரிதாக்கல் +page_scale_actual=உண்மையான அளவு +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=பிழை +loading_error=PDF ஐ ஏற்றும் போது ஒரு பிழை ஏற்பட்டது. +invalid_file_error=செல்லுபடியாகாத அல்லது சிதைந்த PDF கோப்பு. +missing_file_error=PDF கோப்பு காணவில்லை. +unexpected_response_error=சேவகன் பதில் எதிர்பாரதது. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} விளக்கம்] +password_label=இந்த PDF கோப்பை திறக்க கடவுச்சொல்லை உள்ளிடவும். +password_invalid=செல்லுபடியாகாத கடவுச்சொல், தயை செய்து மீண்டும் முயற்சி செய்க. +password_ok=சரி +password_cancel=இரத்து + +printing_not_supported=எச்சரிக்கை: இந்த உலாவி அச்சிடுதலை முழுமையாக ஆதரிக்கவில்லை. +printing_not_ready=எச்சரிக்கை: PDF அச்சிட முழுவதுமாக ஏற்றப்படவில்லை. +web_fonts_disabled=வலை எழுத்துருக்கள் முடக்கப்பட்டுள்ளன: உட்பொதிக்கப்பட்ட PDF எழுத்துருக்களைப் பயன்படுத்த முடியவில்லை. +document_colors_not_allowed=PDF ஆவணங்களுக்கு அவற்றின் சொந்த நிறங்களைப் பயன்படுத்த அனுமதியில்லை: உலாவியில் 'பக்கங்கள் தங்கள் சொந்த நிறங்களைத் தேர்வு செய்துகொள்ள அனுமதி' என்னும் விருப்பம் முடக்கப்பட்டுள்ளது. diff --git a/static/pdf.js/locale/te/viewer.ftl b/static/pdf.js/locale/te/viewer.ftl deleted file mode 100644 index 94dc2b8e..00000000 --- a/static/pdf.js/locale/te/viewer.ftl +++ /dev/null @@ -1,239 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = మునుపటి పేజీ -pdfjs-previous-button-label = క్రితం -pdfjs-next-button = - .title = తరువాత పేజీ -pdfjs-next-button-label = తరువాత -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = పేజీ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = మొత్తం { $pagesCount } లో -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = (మొత్తం { $pagesCount } లో { $pageNumber }వది) -pdfjs-zoom-out-button = - .title = జూమ్ తగ్గించు -pdfjs-zoom-out-button-label = జూమ్ తగ్గించు -pdfjs-zoom-in-button = - .title = జూమ్ చేయి -pdfjs-zoom-in-button-label = జూమ్ చేయి -pdfjs-zoom-select = - .title = జూమ్ -pdfjs-presentation-mode-button = - .title = ప్రదర్శనా రీతికి మారు -pdfjs-presentation-mode-button-label = ప్రదర్శనా రీతి -pdfjs-open-file-button = - .title = ఫైల్ తెరువు -pdfjs-open-file-button-label = తెరువు -pdfjs-print-button = - .title = ముద్రించు -pdfjs-print-button-label = ముద్రించు - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = పనిముట్లు -pdfjs-tools-button-label = పనిముట్లు -pdfjs-first-page-button = - .title = మొదటి పేజీకి వెళ్ళు -pdfjs-first-page-button-label = మొదటి పేజీకి వెళ్ళు -pdfjs-last-page-button = - .title = చివరి పేజీకి వెళ్ళు -pdfjs-last-page-button-label = చివరి పేజీకి వెళ్ళు -pdfjs-page-rotate-cw-button = - .title = సవ్యదిశలో తిప్పు -pdfjs-page-rotate-cw-button-label = సవ్యదిశలో తిప్పు -pdfjs-page-rotate-ccw-button = - .title = అపసవ్యదిశలో తిప్పు -pdfjs-page-rotate-ccw-button-label = అపసవ్యదిశలో తిప్పు -pdfjs-cursor-text-select-tool-button = - .title = టెక్స్ట్ ఎంపిక సాధనాన్ని ప్రారంభించండి -pdfjs-cursor-text-select-tool-button-label = టెక్స్ట్ ఎంపిక సాధనం -pdfjs-cursor-hand-tool-button = - .title = చేతి సాధనం చేతనించు -pdfjs-cursor-hand-tool-button-label = చేతి సాధనం -pdfjs-scroll-vertical-button-label = నిలువు స్క్రోలింగు - -## Document properties dialog - -pdfjs-document-properties-button = - .title = పత్రము లక్షణాలు... -pdfjs-document-properties-button-label = పత్రము లక్షణాలు... -pdfjs-document-properties-file-name = దస్త్రం పేరు: -pdfjs-document-properties-file-size = దస్త్రం పరిమాణం: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = శీర్షిక: -pdfjs-document-properties-author = మూలకర్త: -pdfjs-document-properties-subject = విషయం: -pdfjs-document-properties-keywords = కీ పదాలు: -pdfjs-document-properties-creation-date = సృష్టించిన తేదీ: -pdfjs-document-properties-modification-date = సవరించిన తేదీ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = సృష్టికర్త: -pdfjs-document-properties-producer = PDF ఉత్పాదకి: -pdfjs-document-properties-version = PDF వర్షన్: -pdfjs-document-properties-page-count = పేజీల సంఖ్య: -pdfjs-document-properties-page-size = కాగితం పరిమాణం: -pdfjs-document-properties-page-size-unit-inches = లో -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = నిలువుచిత్రం -pdfjs-document-properties-page-size-orientation-landscape = అడ్డచిత్రం -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = లేఖ -pdfjs-document-properties-page-size-name-legal = చట్టపరమైన - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -pdfjs-document-properties-linearized-yes = అవును -pdfjs-document-properties-linearized-no = కాదు -pdfjs-document-properties-close-button = మూసివేయి - -## Print - -pdfjs-print-progress-message = ముద్రించడానికి పత్రము సిద్ధమవుతున్నది… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = రద్దుచేయి -pdfjs-printing-not-supported = హెచ్చరిక: ఈ విహారిణి చేత ముద్రణ పూర్తిగా తోడ్పాటు లేదు. -pdfjs-printing-not-ready = హెచ్చరిక: ముద్రణ కొరకు ఈ PDF పూర్తిగా లోడవలేదు. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = పక్కపట్టీ మార్చు -pdfjs-toggle-sidebar-button-label = పక్కపట్టీ మార్చు -pdfjs-document-outline-button = - .title = పత్రము రూపము చూపించు (డబుల్ క్లిక్ చేసి అన్ని అంశాలను విస్తరించు/కూల్చు) -pdfjs-document-outline-button-label = పత్రము అవుట్‌లైన్ -pdfjs-attachments-button = - .title = అనుబంధాలు చూపు -pdfjs-attachments-button-label = అనుబంధాలు -pdfjs-layers-button-label = పొరలు -pdfjs-thumbs-button = - .title = థంబ్‌నైల్స్ చూపు -pdfjs-thumbs-button-label = థంబ్‌నైల్స్ -pdfjs-findbar-button = - .title = పత్రములో కనుగొనుము -pdfjs-findbar-button-label = కనుగొను -pdfjs-additional-layers = అదనపు పొరలు - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = పేజీ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } పేజీ నఖచిత్రం - -## Find panel button title and messages - -pdfjs-find-input = - .title = కనుగొను - .placeholder = పత్రములో కనుగొను… -pdfjs-find-previous-button = - .title = పదం యొక్క ముందు సంభవాన్ని కనుగొను -pdfjs-find-previous-button-label = మునుపటి -pdfjs-find-next-button = - .title = పదం యొక్క తర్వాతి సంభవాన్ని కనుగొను -pdfjs-find-next-button-label = తరువాత -pdfjs-find-highlight-checkbox = అన్నిటిని ఉద్దీపనం చేయుము -pdfjs-find-match-case-checkbox-label = అక్షరముల తేడాతో పోల్చు -pdfjs-find-entire-word-checkbox-label = పూర్తి పదాలు -pdfjs-find-reached-top = పేజీ పైకి చేరుకున్నది, క్రింది నుండి కొనసాగించండి -pdfjs-find-reached-bottom = పేజీ చివరకు చేరుకున్నది, పైనుండి కొనసాగించండి -pdfjs-find-not-found = పదబంధం కనబడలేదు - -## Predefined zoom values - -pdfjs-page-scale-width = పేజీ వెడల్పు -pdfjs-page-scale-fit = పేజీ అమర్పు -pdfjs-page-scale-auto = స్వయంచాలక జూమ్ -pdfjs-page-scale-actual = యథార్ధ పరిమాణం -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF లోడవుచున్నప్పుడు ఒక దోషం ఎదురైంది. -pdfjs-invalid-file-error = చెల్లని లేదా పాడైన PDF ఫైలు. -pdfjs-missing-file-error = దొరకని PDF ఫైలు. -pdfjs-unexpected-response-error = అనుకోని సర్వర్ స్పందన. -pdfjs-rendering-error = పేజీను రెండర్ చేయుటలో ఒక దోషం ఎదురైంది. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } టీకా] - -## Password - -pdfjs-password-label = ఈ PDF ఫైల్ తెరుచుటకు సంకేతపదం ప్రవేశపెట్టుము. -pdfjs-password-invalid = సంకేతపదం చెల్లదు. దయచేసి మళ్ళీ ప్రయత్నించండి. -pdfjs-password-ok-button = సరే -pdfjs-password-cancel-button = రద్దుచేయి -pdfjs-web-fonts-disabled = వెబ్ ఫాంట్లు అచేతనించబడెను: ఎంబెడెడ్ PDF ఫాంట్లు ఉపయోగించలేక పోయింది. - -## Editing - -# Editor Parameters -pdfjs-editor-free-text-color-input = రంగు -pdfjs-editor-free-text-size-input = పరిమాణం -pdfjs-editor-ink-color-input = రంగు -pdfjs-editor-ink-thickness-input = మందం -pdfjs-editor-ink-opacity-input = అకిరణ్యత - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/te/viewer.properties b/static/pdf.js/locale/te/viewer.properties new file mode 100644 index 00000000..e08d5e7d --- /dev/null +++ b/static/pdf.js/locale/te/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=క్రితం పేజీ +previous_label=క్రితం +next.title=తరువాత పేజీ +next_label=తరువాత + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=పేజీ: +page_of=మొత్తం {{pageCount}} లో + +zoom_out.title=జూమ్ తగ్గించు +zoom_out_label=జూమ్ తగ్గించు +zoom_in.title=జూమ్ చేయి +zoom_in_label=జూమ్ చేయి +zoom.title=జూమ్ +presentation_mode.title=ప్రదర్శనా రీతికి మారు +presentation_mode_label=ప్రదర్శనా రీతి +open_file.title=ఫైల్ తెరువు +open_file_label=తెరువు +print.title=ముద్రించు +print_label=ముద్రించు +download.title=డౌనులోడు +download_label=డౌనులోడు +bookmark.title=ప్రస్తుత దర్శనం (నకలుతీయి లేదా కొత్త విండోనందు తెరువుము) +bookmark_label=ప్రస్తుత దర్శనం + +# Secondary toolbar and context menu +tools.title=పనిముట్లు +tools_label=పనిముట్లు +first_page.title=మొదటి పేజీకి వెళ్ళు +first_page.label=మొదటి పేజీకి వెళ్ళు +first_page_label=మొదటి పేజీకి వెళ్ళు +last_page.title=చివరి పేజీకి వెళ్ళు +last_page.label=చివరి పేజీకి వెళ్ళు +last_page_label=చివరి పేజీకి వెళ్ళు +page_rotate_cw.title=సవ్యదిశలో తిప్పుము +page_rotate_cw.label=సవ్యదిశలో తిప్పుము +page_rotate_cw_label=సవ్యదిశలో తిప్పుము +page_rotate_ccw.title=అపసవ్యదిశలో తిప్పుము +page_rotate_ccw.label=అపసవ్యదిశలో తిప్పుము +page_rotate_ccw_label=అపసవ్యదిశలో తిప్పుము + +hand_tool_enable.title=చేతి సాధనం చేతనించు +hand_tool_enable_label=చేతి సాధనం చేతనించు +hand_tool_disable.title=చేతి సాధనం అచేతనించు +hand_tool_disable_label=చేతి సాధనం అచేతనించు + +# Document properties dialog box +document_properties.title=పత్రము లక్షణాలు... +document_properties_label=పత్రము లక్షణాలు... +document_properties_file_name=దస్త్రం పేరు: +document_properties_file_size=దస్త్రం పరిమాణం: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=శీర్షిక: +document_properties_author=మూలకర్త: +document_properties_subject=విషయం: +document_properties_keywords=కీపదాలు: +document_properties_creation_date=సృష్టించిన తేదీ: +document_properties_modification_date=సవరించిన తేదీ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=సృష్టికర్త: +document_properties_producer=PDF ఉత్పాదకి: +document_properties_version=PDF వర్షన్: +document_properties_page_count=పేజీల సంఖ్య: +document_properties_close=మూసివేయి + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=పక్కపట్టీ మార్చు +toggle_sidebar_label=పక్కపట్టీ మార్చు +outline.title=పత్రము అవుట్‌లైన్ చూపు +outline_label=పత్రము అవుట్‌లైన్ +attachments.title=అనుబంధాలు చూపు +attachments_label=అనుబంధాలు +thumbs.title=థంబ్‌నైల్స్ చూపు +thumbs_label=థంబ్‌నైల్స్ +findbar.title=ఈ పత్రమునందు కనుగొనుము +findbar_label=కనుగొను + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=పేజీ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=పేజీ {{page}} యొక్క థంబ్‌నైల్ + +# Find panel button title and messages +find_label=కనుగొను: +find_previous.title=పదంయొక్క ముందలి సంభవాన్ని కనుగొను +find_previous_label=మునుపటి +find_next.title=పదం యొక్క తర్వాతి సంభవాన్ని కనుగొను +find_next_label=తరువాత +find_highlight=అన్నిటిని ఉద్దీపనం చేయుము +find_match_case_label=అక్షరములతేడాతో పోల్చుము +find_reached_top=పేజీ పైకి చేరుకున్నది, క్రింది నుండి కొనసాగించండి +find_reached_bottom=పేజీ చివరకు చేరుకున్నది, పైనుండి కొనసాగించండి +find_not_found=పదం కనబడలేదు + +# Error panel labels +error_more_info=మరింత సమాచారం +error_less_info=తక్కువ సమాచారం +error_close=మూసివేయి +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=సందేశం: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=స్టాక్: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=ఫైలు: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=వరుస: {{line}} +rendering_error=పేజీను రెండర్ చేయుటలో వొక దోషం యెదురైంది. + +# Predefined zoom values +page_scale_width=పేజీ వెడల్పు +page_scale_fit=పేజీ అమర్పు +page_scale_auto=స్వయంచాలక జూమ్ +page_scale_actual=యథార్ధ పరిమాణం +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=దోషం +loading_error=PDF లోడవుచున్నప్పుడు వొక దోషం యెదురైంది. +invalid_file_error=చెల్లని లేదా పాడైన PDF ఫైలు. +missing_file_error=దొరకని PDF ఫైలు. +unexpected_response_error=అనుకోని సేవిక స్పందన. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} టీకా] +password_label=ఈ PDF ఫైల్ తెరుచుటకు సంకేతపదం ప్రవేశపెట్టుము +password_invalid=సంకేతపదం చెల్లదు. దయచేసి మళ్ళీ ప్రయత్నించండి. +password_ok=సరే +password_cancel=రద్దుచేయి + +printing_not_supported=హెచ్చరిక: ఈ విహారిణి చేత ముద్రణ పూర్తిగా తోడ్పాటునీయబడుట లేదు +printing_not_ready=హెచ్చరిక: ముద్రణ కొరకు ఈ PDF పూర్తిగా లోడవలేదు. +web_fonts_disabled=వెబ్ ఫాంట్లు అచేతనపరచ బడెను: ఎంబెడెడ్ PDF ఫాంట్లు వుపయోగించలేక పోయింది. +document_colors_not_allowed=PDF పత్రాలు వాటి స్వంత రంగులను వుపయోగించుకొనుటకు అనుమతించబడవు: విహరణి నందు 'పేజీలను వాటి స్వంత రంగులను యెంచుకొనుటకు అనుమతించు' అనునది అచేతనం చేయబడివుంది. diff --git a/static/pdf.js/locale/tg/viewer.ftl b/static/pdf.js/locale/tg/viewer.ftl deleted file mode 100644 index 42964701..00000000 --- a/static/pdf.js/locale/tg/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Саҳифаи қаблӣ -pdfjs-previous-button-label = Қаблӣ -pdfjs-next-button = - .title = Саҳифаи навбатӣ -pdfjs-next-button-label = Навбатӣ -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Саҳифа -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = аз { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } аз { $pagesCount }) -pdfjs-zoom-out-button = - .title = Хурд кардан -pdfjs-zoom-out-button-label = Хурд кардан -pdfjs-zoom-in-button = - .title = Калон кардан -pdfjs-zoom-in-button-label = Калон кардан -pdfjs-zoom-select = - .title = Танзими андоза -pdfjs-presentation-mode-button = - .title = Гузариш ба реҷаи тақдим -pdfjs-presentation-mode-button-label = Реҷаи тақдим -pdfjs-open-file-button = - .title = Кушодани файл -pdfjs-open-file-button-label = Кушодан -pdfjs-print-button = - .title = Чоп кардан -pdfjs-print-button-label = Чоп кардан -pdfjs-save-button = - .title = Нигоҳ доштан -pdfjs-save-button-label = Нигоҳ доштан -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Боргирӣ кардан -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Боргирӣ кардан -pdfjs-bookmark-button = - .title = Саҳифаи ҷорӣ (Дидани нишонии URL аз саҳифаи ҷорӣ) -pdfjs-bookmark-button-label = Саҳифаи ҷорӣ - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Абзорҳо -pdfjs-tools-button-label = Абзорҳо -pdfjs-first-page-button = - .title = Ба саҳифаи аввал гузаред -pdfjs-first-page-button-label = Ба саҳифаи аввал гузаред -pdfjs-last-page-button = - .title = Ба саҳифаи охирин гузаред -pdfjs-last-page-button-label = Ба саҳифаи охирин гузаред -pdfjs-page-rotate-cw-button = - .title = Ба самти ҳаракати ақрабаки соат давр задан -pdfjs-page-rotate-cw-button-label = Ба самти ҳаракати ақрабаки соат давр задан -pdfjs-page-rotate-ccw-button = - .title = Ба муқобили самти ҳаракати ақрабаки соат давр задан -pdfjs-page-rotate-ccw-button-label = Ба муқобили самти ҳаракати ақрабаки соат давр задан -pdfjs-cursor-text-select-tool-button = - .title = Фаъол кардани «Абзори интихоби матн» -pdfjs-cursor-text-select-tool-button-label = Абзори интихоби матн -pdfjs-cursor-hand-tool-button = - .title = Фаъол кардани «Абзори даст» -pdfjs-cursor-hand-tool-button-label = Абзори даст -pdfjs-scroll-page-button = - .title = Истифодаи варақзанӣ -pdfjs-scroll-page-button-label = Варақзанӣ -pdfjs-scroll-vertical-button = - .title = Истифодаи варақзании амудӣ -pdfjs-scroll-vertical-button-label = Варақзании амудӣ -pdfjs-scroll-horizontal-button = - .title = Истифодаи варақзании уфуқӣ -pdfjs-scroll-horizontal-button-label = Варақзании уфуқӣ -pdfjs-scroll-wrapped-button = - .title = Истифодаи варақзании миқёсбандӣ -pdfjs-scroll-wrapped-button-label = Варақзании миқёсбандӣ -pdfjs-spread-none-button = - .title = Густариши саҳифаҳо истифода бурда нашавад -pdfjs-spread-none-button-label = Бе густурдани саҳифаҳо -pdfjs-spread-odd-button = - .title = Густариши саҳифаҳо аз саҳифаҳо бо рақамҳои тоқ оғоз карда мешавад -pdfjs-spread-odd-button-label = Саҳифаҳои тоқ аз тарафи чап -pdfjs-spread-even-button = - .title = Густариши саҳифаҳо аз саҳифаҳо бо рақамҳои ҷуфт оғоз карда мешавад -pdfjs-spread-even-button-label = Саҳифаҳои ҷуфт аз тарафи чап - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Хусусиятҳои ҳуҷҷат… -pdfjs-document-properties-button-label = Хусусиятҳои ҳуҷҷат… -pdfjs-document-properties-file-name = Номи файл: -pdfjs-document-properties-file-size = Андозаи файл: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } КБ ({ $size_b } байт) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } МБ ({ $size_b } байт) -pdfjs-document-properties-title = Сарлавҳа: -pdfjs-document-properties-author = Муаллиф: -pdfjs-document-properties-subject = Мавзуъ: -pdfjs-document-properties-keywords = Калимаҳои калидӣ: -pdfjs-document-properties-creation-date = Санаи эҷод: -pdfjs-document-properties-modification-date = Санаи тағйирот: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Эҷодкунанда: -pdfjs-document-properties-producer = Таҳиякунандаи «PDF»: -pdfjs-document-properties-version = Версияи «PDF»: -pdfjs-document-properties-page-count = Шумораи саҳифаҳо: -pdfjs-document-properties-page-size = Андозаи саҳифа: -pdfjs-document-properties-page-size-unit-inches = дюйм -pdfjs-document-properties-page-size-unit-millimeters = мм -pdfjs-document-properties-page-size-orientation-portrait = амудӣ -pdfjs-document-properties-page-size-orientation-landscape = уфуқӣ -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Мактуб -pdfjs-document-properties-page-size-name-legal = Ҳуқуқӣ - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Намоиши тез дар Интернет: -pdfjs-document-properties-linearized-yes = Ҳа -pdfjs-document-properties-linearized-no = Не -pdfjs-document-properties-close-button = Пӯшидан - -## Print - -pdfjs-print-progress-message = Омодасозии ҳуҷҷат барои чоп… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Бекор кардан -pdfjs-printing-not-supported = Диққат: Чопкунӣ аз тарафи ин браузер ба таври пурра дастгирӣ намешавад. -pdfjs-printing-not-ready = Диққат: Файли «PDF» барои чопкунӣ пурра бор карда нашуд. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Фаъол кардани навори ҷонибӣ -pdfjs-toggle-sidebar-notification-button = - .title = Фаъол кардани навори ҷонибӣ (ҳуҷҷат дорои сохтор/замимаҳо/қабатҳо мебошад) -pdfjs-toggle-sidebar-button-label = Фаъол кардани навори ҷонибӣ -pdfjs-document-outline-button = - .title = Намоиш додани сохтори ҳуҷҷат (барои баркушодан/пеҷондани ҳамаи унсурҳо дубора зер кунед) -pdfjs-document-outline-button-label = Сохтори ҳуҷҷат -pdfjs-attachments-button = - .title = Намоиш додани замимаҳо -pdfjs-attachments-button-label = Замимаҳо -pdfjs-layers-button = - .title = Намоиш додани қабатҳо (барои барқарор кардани ҳамаи қабатҳо ба вазъияти пешфарз дубора зер кунед) -pdfjs-layers-button-label = Қабатҳо -pdfjs-thumbs-button = - .title = Намоиш додани тасвирчаҳо -pdfjs-thumbs-button-label = Тасвирчаҳо -pdfjs-current-outline-item-button = - .title = Ёфтани унсури сохтори ҷорӣ -pdfjs-current-outline-item-button-label = Унсури сохтори ҷорӣ -pdfjs-findbar-button = - .title = Ёфтан дар ҳуҷҷат -pdfjs-findbar-button-label = Ёфтан -pdfjs-additional-layers = Қабатҳои иловагӣ - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Саҳифаи { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Тасвирчаи саҳифаи { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Ёфтан - .placeholder = Ёфтан дар ҳуҷҷат… -pdfjs-find-previous-button = - .title = Ҷустуҷӯи мавриди қаблии ибораи пешниҳодшуда -pdfjs-find-previous-button-label = Қаблӣ -pdfjs-find-next-button = - .title = Ҷустуҷӯи мавриди навбатии ибораи пешниҳодшуда -pdfjs-find-next-button-label = Навбатӣ -pdfjs-find-highlight-checkbox = Ҳамаашро бо ранг ҷудо кардан -pdfjs-find-match-case-checkbox-label = Бо дарназардошти ҳарфҳои хурду калон -pdfjs-find-match-diacritics-checkbox-label = Бо дарназардошти аломатҳои диакритикӣ -pdfjs-find-entire-word-checkbox-label = Калимаҳои пурра -pdfjs-find-reached-top = Ба болои ҳуҷҷат расид, аз поён идома ёфт -pdfjs-find-reached-bottom = Ба поёни ҳуҷҷат расид, аз боло идома ёфт -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } аз { $total } мувофиқат - *[other] { $current } аз { $total } мувофиқат - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Зиёда аз { $limit } мувофиқат - *[other] Зиёда аз { $limit } мувофиқат - } -pdfjs-find-not-found = Ибора ёфт нашуд - -## Predefined zoom values - -pdfjs-page-scale-width = Аз рӯи паҳнои саҳифа -pdfjs-page-scale-fit = Аз рӯи андозаи саҳифа -pdfjs-page-scale-auto = Андозаи худкор -pdfjs-page-scale-actual = Андозаи воқеӣ -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Саҳифаи { $page } - -## Loading indicator messages - -pdfjs-loading-error = Ҳангоми боркунии «PDF» хато ба миён омад. -pdfjs-invalid-file-error = Файли «PDF» нодуруст ё вайроншуда мебошад. -pdfjs-missing-file-error = Файли «PDF» ғоиб аст. -pdfjs-unexpected-response-error = Ҷавоби ногаҳон аз сервер. -pdfjs-rendering-error = Ҳангоми шаклсозии саҳифа хато ба миён омад. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Ҳошиянависӣ - { $type }] - -## Password - -pdfjs-password-label = Барои кушодани ин файли «PDF» ниҳонвожаро ворид кунед. -pdfjs-password-invalid = Ниҳонвожаи нодуруст. Лутфан, аз нав кӯшиш кунед. -pdfjs-password-ok-button = ХУБ -pdfjs-password-cancel-button = Бекор кардан -pdfjs-web-fonts-disabled = Шрифтҳои интернетӣ ғайрифаъоланд: истифодаи шрифтҳои дарунсохти «PDF» ғайриимкон аст. - -## Editing - -pdfjs-editor-free-text-button = - .title = Матн -pdfjs-editor-free-text-button-label = Матн -pdfjs-editor-ink-button = - .title = Расмкашӣ -pdfjs-editor-ink-button-label = Расмкашӣ -pdfjs-editor-stamp-button = - .title = Илова ё таҳрир кардани тасвирҳо -pdfjs-editor-stamp-button-label = Илова ё таҳрир кардани тасвирҳо -pdfjs-editor-highlight-button = - .title = Ҷудокунӣ -pdfjs-editor-highlight-button-label = Ҷудокунӣ -pdfjs-highlight-floating-button = - .title = Ҷудокунӣ -pdfjs-highlight-floating-button1 = - .title = Ҷудокунӣ - .aria-label = Ҷудокунӣ -pdfjs-highlight-floating-button-label = Ҷудокунӣ - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Тоза кардани нақша -pdfjs-editor-remove-freetext-button = - .title = Тоза кардани матн -pdfjs-editor-remove-stamp-button = - .title = Тоза кардани тасвир -pdfjs-editor-remove-highlight-button = - .title = Тоза кардани ҷудокунӣ - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Ранг -pdfjs-editor-free-text-size-input = Андоза -pdfjs-editor-ink-color-input = Ранг -pdfjs-editor-ink-thickness-input = Ғафсӣ -pdfjs-editor-ink-opacity-input = Шаффофӣ -pdfjs-editor-stamp-add-image-button = - .title = Илова кардани тасвир -pdfjs-editor-stamp-add-image-button-label = Илова кардани тасвир -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Ғафсӣ -pdfjs-editor-free-highlight-thickness-title = - .title = Иваз кардани ғафсӣ ҳангоми ҷудокунии унсурҳо ба ғайр аз матн -pdfjs-free-text = - .aria-label = Муҳаррири матн -pdfjs-free-text-default-content = Нависед… -pdfjs-ink = - .aria-label = Муҳаррири расмкашӣ -pdfjs-ink-canvas = - .aria-label = Тасвири эҷодкардаи корбар - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Матни ивазкунанда -pdfjs-editor-alt-text-edit-button-label = Таҳрир кардани матни ивазкунанда -pdfjs-editor-alt-text-dialog-label = Имконеро интихоб намоед -pdfjs-editor-alt-text-dialog-description = Вақте ки одамон тасвирро дида наметавонанд ё вақте ки тасвир бор карда намешавад, матни иловагӣ (Alt text) кумак мерасонад. -pdfjs-editor-alt-text-add-description-label = Илова кардани тавсиф -pdfjs-editor-alt-text-add-description-description = Кӯшиш кунед, ки 1-2 ҷумлаеро нависед, ки ба мавзӯъ, танзим ё амалҳо тавзеҳ медиҳад. -pdfjs-editor-alt-text-mark-decorative-label = Гузоштан ҳамчун матни ороишӣ -pdfjs-editor-alt-text-mark-decorative-description = Ин барои тасвирҳои ороишӣ, ба монанди марзҳо ё аломатҳои обӣ, истифода мешавад. -pdfjs-editor-alt-text-cancel-button = Бекор кардан -pdfjs-editor-alt-text-save-button = Нигоҳ доштан -pdfjs-editor-alt-text-decorative-tooltip = Ҳамчун матни ороишӣ гузошта шуд -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Барои мисол, «Ман забони тоҷикиро дӯст медорам» - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Кунҷи чапи боло — тағйир додани андоза -pdfjs-editor-resizer-label-top-middle = Канори миёнаи боло — тағйир додани андоза -pdfjs-editor-resizer-label-top-right = Кунҷи рости боло — тағйир додани андоза -pdfjs-editor-resizer-label-middle-right = Канори миёнаи рост — тағйир додани андоза -pdfjs-editor-resizer-label-bottom-right = Кунҷи рости поён — тағйир додани андоза -pdfjs-editor-resizer-label-bottom-middle = Канори миёнаи поён — тағйир додани андоза -pdfjs-editor-resizer-label-bottom-left = Кунҷи чапи поён — тағйир додани андоза -pdfjs-editor-resizer-label-middle-left = Канори миёнаи чап — тағйир додани андоза - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Ранги ҷудокунӣ -pdfjs-editor-colorpicker-button = - .title = Иваз кардани ранг -pdfjs-editor-colorpicker-dropdown = - .aria-label = Интихоби ранг -pdfjs-editor-colorpicker-yellow = - .title = Зард -pdfjs-editor-colorpicker-green = - .title = Сабз -pdfjs-editor-colorpicker-blue = - .title = Кабуд -pdfjs-editor-colorpicker-pink = - .title = Гулобӣ -pdfjs-editor-colorpicker-red = - .title = Сурх - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Ҳамаро намоиш додан -pdfjs-editor-highlight-show-all-button = - .title = Ҳамаро намоиш додан diff --git a/static/pdf.js/locale/th/viewer.ftl b/static/pdf.js/locale/th/viewer.ftl deleted file mode 100644 index 283b440c..00000000 --- a/static/pdf.js/locale/th/viewer.ftl +++ /dev/null @@ -1,394 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = หน้าก่อนหน้า -pdfjs-previous-button-label = ก่อนหน้า -pdfjs-next-button = - .title = หน้าถัดไป -pdfjs-next-button-label = ถัดไป -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = หน้า -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = จาก { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } จาก { $pagesCount }) -pdfjs-zoom-out-button = - .title = ซูมออก -pdfjs-zoom-out-button-label = ซูมออก -pdfjs-zoom-in-button = - .title = ซูมเข้า -pdfjs-zoom-in-button-label = ซูมเข้า -pdfjs-zoom-select = - .title = ซูม -pdfjs-presentation-mode-button = - .title = สลับเป็นโหมดการนำเสนอ -pdfjs-presentation-mode-button-label = โหมดการนำเสนอ -pdfjs-open-file-button = - .title = เปิดไฟล์ -pdfjs-open-file-button-label = เปิด -pdfjs-print-button = - .title = พิมพ์ -pdfjs-print-button-label = พิมพ์ -pdfjs-save-button = - .title = บันทึก -pdfjs-save-button-label = บันทึก -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = ดาวน์โหลด -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = ดาวน์โหลด -pdfjs-bookmark-button = - .title = หน้าปัจจุบัน (ดู URL จากหน้าปัจจุบัน) -pdfjs-bookmark-button-label = หน้าปัจจุบัน -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = เปิดในแอป -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = เปิดในแอป - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = เครื่องมือ -pdfjs-tools-button-label = เครื่องมือ -pdfjs-first-page-button = - .title = ไปยังหน้าแรก -pdfjs-first-page-button-label = ไปยังหน้าแรก -pdfjs-last-page-button = - .title = ไปยังหน้าสุดท้าย -pdfjs-last-page-button-label = ไปยังหน้าสุดท้าย -pdfjs-page-rotate-cw-button = - .title = หมุนตามเข็มนาฬิกา -pdfjs-page-rotate-cw-button-label = หมุนตามเข็มนาฬิกา -pdfjs-page-rotate-ccw-button = - .title = หมุนทวนเข็มนาฬิกา -pdfjs-page-rotate-ccw-button-label = หมุนทวนเข็มนาฬิกา -pdfjs-cursor-text-select-tool-button = - .title = เปิดใช้งานเครื่องมือการเลือกข้อความ -pdfjs-cursor-text-select-tool-button-label = เครื่องมือการเลือกข้อความ -pdfjs-cursor-hand-tool-button = - .title = เปิดใช้งานเครื่องมือมือ -pdfjs-cursor-hand-tool-button-label = เครื่องมือมือ -pdfjs-scroll-page-button = - .title = ใช้การเลื่อนหน้า -pdfjs-scroll-page-button-label = การเลื่อนหน้า -pdfjs-scroll-vertical-button = - .title = ใช้การเลื่อนแนวตั้ง -pdfjs-scroll-vertical-button-label = การเลื่อนแนวตั้ง -pdfjs-scroll-horizontal-button = - .title = ใช้การเลื่อนแนวนอน -pdfjs-scroll-horizontal-button-label = การเลื่อนแนวนอน -pdfjs-scroll-wrapped-button = - .title = ใช้การเลื่อนแบบคลุม -pdfjs-scroll-wrapped-button-label = เลื่อนแบบคลุม -pdfjs-spread-none-button = - .title = ไม่ต้องรวมการกระจายหน้า -pdfjs-spread-none-button-label = ไม่กระจาย -pdfjs-spread-odd-button = - .title = รวมการกระจายหน้าเริ่มจากหน้าคี่ -pdfjs-spread-odd-button-label = กระจายอย่างเหลือเศษ -pdfjs-spread-even-button = - .title = รวมการกระจายหน้าเริ่มจากหน้าคู่ -pdfjs-spread-even-button-label = กระจายอย่างเท่าเทียม - -## Document properties dialog - -pdfjs-document-properties-button = - .title = คุณสมบัติเอกสาร… -pdfjs-document-properties-button-label = คุณสมบัติเอกสาร… -pdfjs-document-properties-file-name = ชื่อไฟล์: -pdfjs-document-properties-file-size = ขนาดไฟล์: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } ไบต์) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } ไบต์) -pdfjs-document-properties-title = ชื่อเรื่อง: -pdfjs-document-properties-author = ผู้สร้าง: -pdfjs-document-properties-subject = ชื่อเรื่อง: -pdfjs-document-properties-keywords = คำสำคัญ: -pdfjs-document-properties-creation-date = วันที่สร้าง: -pdfjs-document-properties-modification-date = วันที่แก้ไข: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = ผู้สร้าง: -pdfjs-document-properties-producer = ผู้ผลิต PDF: -pdfjs-document-properties-version = รุ่น PDF: -pdfjs-document-properties-page-count = จำนวนหน้า: -pdfjs-document-properties-page-size = ขนาดหน้า: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = แนวตั้ง -pdfjs-document-properties-page-size-orientation-landscape = แนวนอน -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = จดหมาย -pdfjs-document-properties-page-size-name-legal = ข้อกฎหมาย - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = มุมมองเว็บแบบรวดเร็ว: -pdfjs-document-properties-linearized-yes = ใช่ -pdfjs-document-properties-linearized-no = ไม่ -pdfjs-document-properties-close-button = ปิด - -## Print - -pdfjs-print-progress-message = กำลังเตรียมเอกสารสำหรับการพิมพ์… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = ยกเลิก -pdfjs-printing-not-supported = คำเตือน: เบราว์เซอร์นี้ไม่ได้สนับสนุนการพิมพ์อย่างเต็มที่ -pdfjs-printing-not-ready = คำเตือน: PDF ไม่ได้รับการโหลดอย่างเต็มที่สำหรับการพิมพ์ - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = เปิด/ปิดแถบข้าง -pdfjs-toggle-sidebar-notification-button = - .title = เปิด/ปิดแถบข้าง (เอกสารมีเค้าร่าง/ไฟล์แนบ/เลเยอร์) -pdfjs-toggle-sidebar-button-label = เปิด/ปิดแถบข้าง -pdfjs-document-outline-button = - .title = แสดงเค้าร่างเอกสาร (คลิกสองครั้งเพื่อขยาย/ยุบรายการทั้งหมด) -pdfjs-document-outline-button-label = เค้าร่างเอกสาร -pdfjs-attachments-button = - .title = แสดงไฟล์แนบ -pdfjs-attachments-button-label = ไฟล์แนบ -pdfjs-layers-button = - .title = แสดงเลเยอร์ (คลิกสองครั้งเพื่อรีเซ็ตเลเยอร์ทั้งหมดเป็นสถานะเริ่มต้น) -pdfjs-layers-button-label = เลเยอร์ -pdfjs-thumbs-button = - .title = แสดงภาพขนาดย่อ -pdfjs-thumbs-button-label = ภาพขนาดย่อ -pdfjs-current-outline-item-button = - .title = ค้นหารายการเค้าร่างปัจจุบัน -pdfjs-current-outline-item-button-label = รายการเค้าร่างปัจจุบัน -pdfjs-findbar-button = - .title = ค้นหาในเอกสาร -pdfjs-findbar-button-label = ค้นหา -pdfjs-additional-layers = เลเยอร์เพิ่มเติม - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = หน้า { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = ภาพขนาดย่อของหน้า { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = ค้นหา - .placeholder = ค้นหาในเอกสาร… -pdfjs-find-previous-button = - .title = หาตำแหน่งก่อนหน้าของวลี -pdfjs-find-previous-button-label = ก่อนหน้า -pdfjs-find-next-button = - .title = หาตำแหน่งถัดไปของวลี -pdfjs-find-next-button-label = ถัดไป -pdfjs-find-highlight-checkbox = เน้นสีทั้งหมด -pdfjs-find-match-case-checkbox-label = ตัวพิมพ์ใหญ่เล็กตรงกัน -pdfjs-find-match-diacritics-checkbox-label = เครื่องหมายกำกับการออกเสียงตรงกัน -pdfjs-find-entire-word-checkbox-label = ทั้งคำ -pdfjs-find-reached-top = ค้นหาถึงจุดเริ่มต้นของหน้า เริ่มค้นต่อจากด้านล่าง -pdfjs-find-reached-bottom = ค้นหาถึงจุดสิ้นสุดหน้า เริ่มค้นต่อจากด้านบน -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = { $current } จาก { $total } รายการที่ตรงกัน -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = มากกว่า { $limit } รายการที่ตรงกัน -pdfjs-find-not-found = ไม่พบวลี - -## Predefined zoom values - -pdfjs-page-scale-width = ความกว้างหน้า -pdfjs-page-scale-fit = พอดีหน้า -pdfjs-page-scale-auto = ซูมอัตโนมัติ -pdfjs-page-scale-actual = ขนาดจริง -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = หน้า { $page } - -## Loading indicator messages - -pdfjs-loading-error = เกิดข้อผิดพลาดขณะโหลด PDF -pdfjs-invalid-file-error = ไฟล์ PDF ไม่ถูกต้องหรือเสียหาย -pdfjs-missing-file-error = ไฟล์ PDF หายไป -pdfjs-unexpected-response-error = การตอบสนองของเซิร์ฟเวอร์ที่ไม่คาดคิด -pdfjs-rendering-error = เกิดข้อผิดพลาดขณะเรนเดอร์หน้า - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [คำอธิบายประกอบ { $type }] - -## Password - -pdfjs-password-label = ป้อนรหัสผ่านเพื่อเปิดไฟล์ PDF นี้ -pdfjs-password-invalid = รหัสผ่านไม่ถูกต้อง โปรดลองอีกครั้ง -pdfjs-password-ok-button = ตกลง -pdfjs-password-cancel-button = ยกเลิก -pdfjs-web-fonts-disabled = แบบอักษรเว็บถูกปิดใช้งาน: ไม่สามารถใช้แบบอักษร PDF ฝังตัว - -## Editing - -pdfjs-editor-free-text-button = - .title = ข้อความ -pdfjs-editor-free-text-button-label = ข้อความ -pdfjs-editor-ink-button = - .title = รูปวาด -pdfjs-editor-ink-button-label = รูปวาด -pdfjs-editor-stamp-button = - .title = เพิ่มหรือแก้ไขภาพ -pdfjs-editor-stamp-button-label = เพิ่มหรือแก้ไขภาพ -pdfjs-editor-highlight-button = - .title = เน้น -pdfjs-editor-highlight-button-label = เน้น -pdfjs-highlight-floating-button = - .title = เน้นสี -pdfjs-highlight-floating-button1 = - .title = เน้นสี - .aria-label = เน้นสี -pdfjs-highlight-floating-button-label = เน้นสี - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = เอาภาพวาดออก -pdfjs-editor-remove-freetext-button = - .title = เอาข้อความออก -pdfjs-editor-remove-stamp-button = - .title = เอาภาพออก -pdfjs-editor-remove-highlight-button = - .title = เอาการเน้นสีออก - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = สี -pdfjs-editor-free-text-size-input = ขนาด -pdfjs-editor-ink-color-input = สี -pdfjs-editor-ink-thickness-input = ความหนา -pdfjs-editor-ink-opacity-input = ความทึบ -pdfjs-editor-stamp-add-image-button = - .title = เพิ่มภาพ -pdfjs-editor-stamp-add-image-button-label = เพิ่มภาพ -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = ความหนา -pdfjs-editor-free-highlight-thickness-title = - .title = เปลี่ยนความหนาเมื่อเน้นรายการอื่นๆ ที่ไม่ใช่ข้อความ -pdfjs-free-text = - .aria-label = ตัวแก้ไขข้อความ -pdfjs-free-text-default-content = เริ่มพิมพ์… -pdfjs-ink = - .aria-label = ตัวแก้ไขรูปวาด -pdfjs-ink-canvas = - .aria-label = ภาพที่ผู้ใช้สร้างขึ้น - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = ข้อความทดแทน -pdfjs-editor-alt-text-edit-button-label = แก้ไขข้อความทดแทน -pdfjs-editor-alt-text-dialog-label = เลือกตัวเลือก -pdfjs-editor-alt-text-dialog-description = ข้อความทดแทนสามารถช่วยเหลือได้เมื่อผู้ใช้มองไม่เห็นภาพ หรือภาพไม่โหลด -pdfjs-editor-alt-text-add-description-label = เพิ่มคำอธิบาย -pdfjs-editor-alt-text-add-description-description = แนะนำให้ใช้ 1-2 ประโยคซึ่งอธิบายหัวเรื่อง ฉาก หรือการกระทำ -pdfjs-editor-alt-text-mark-decorative-label = ทำเครื่องหมายเป็นสิ่งตกแต่ง -pdfjs-editor-alt-text-mark-decorative-description = สิ่งนี้ใช้สำหรับภาพที่เป็นสิ่งประดับ เช่น ขอบ หรือลายน้ำ -pdfjs-editor-alt-text-cancel-button = ยกเลิก -pdfjs-editor-alt-text-save-button = บันทึก -pdfjs-editor-alt-text-decorative-tooltip = ทำเครื่องหมายเป็นสิ่งตกแต่งแล้ว -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = ตัวอย่างเช่น “ชายหนุ่มคนหนึ่งนั่งลงที่โต๊ะเพื่อรับประทานอาหารมื้อหนึ่ง” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = มุมซ้ายบน — ปรับขนาด -pdfjs-editor-resizer-label-top-middle = ตรงกลางด้านบน — ปรับขนาด -pdfjs-editor-resizer-label-top-right = มุมขวาบน — ปรับขนาด -pdfjs-editor-resizer-label-middle-right = ตรงกลางด้านขวา — ปรับขนาด -pdfjs-editor-resizer-label-bottom-right = มุมขวาล่าง — ปรับขนาด -pdfjs-editor-resizer-label-bottom-middle = ตรงกลางด้านล่าง — ปรับขนาด -pdfjs-editor-resizer-label-bottom-left = มุมซ้ายล่าง — ปรับขนาด -pdfjs-editor-resizer-label-middle-left = ตรงกลางด้านซ้าย — ปรับขนาด - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = สีเน้น -pdfjs-editor-colorpicker-button = - .title = เปลี่ยนสี -pdfjs-editor-colorpicker-dropdown = - .aria-label = ทางเลือกสี -pdfjs-editor-colorpicker-yellow = - .title = เหลือง -pdfjs-editor-colorpicker-green = - .title = เขียว -pdfjs-editor-colorpicker-blue = - .title = น้ำเงิน -pdfjs-editor-colorpicker-pink = - .title = ชมพู -pdfjs-editor-colorpicker-red = - .title = แดง - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = แสดงทั้งหมด -pdfjs-editor-highlight-show-all-button = - .title = แสดงทั้งหมด diff --git a/static/pdf.js/locale/th/viewer.properties b/static/pdf.js/locale/th/viewer.properties new file mode 100644 index 00000000..151e6b86 --- /dev/null +++ b/static/pdf.js/locale/th/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=หน้าก่อนหน้า +previous_label=ก่อนหน้า +next.title=หน้าถัดไป +next_label=ถัดไป + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=หน้า: +page_of=จาก {{pageCount}} + +zoom_out.title=ย่อ +zoom_out_label=ย่อ Out +zoom_in.title=ขยาย +zoom_in_label=ขยาย +zoom.title=ย่อ-ขยาย +presentation_mode.title=สลับเข้าสู่รูปแบบการนำเสนอ +presentation_mode_label=รูปแบบการนำเสนอ +open_file.title=เปิดแฟ้ม +open_file_label=เปิด +print.title=พิมพ์ +print_label=พิมพ์ +download.title=ดาวน์โหลด +download_label=ดาวน์โหลด +bookmark.title=มุมมองปัจจุบัน (คัดลอกหรือเปิดในหน้าต่างใหม่) +bookmark_label=มุมมองปัจจุบัน + +# Secondary toolbar and context menu +tools.title=เครื่องมือ +tools_label=เครื่องมือ +first_page.title=ไปยังหน้าแรก +first_page.label=ไปยังหน้าแรก +first_page_label=ไปยังหน้าแรก +last_page.title=ไปยังหน้าสุดท้าย +last_page.label=ไปยังหน้าสุดท้าย +last_page_label=ไปยังหน้าสุดท้าย +page_rotate_cw.title=หมุนตามเข็มนาฬิกา +page_rotate_cw.label=หมุนตามเข็มนาฬิกา +page_rotate_cw_label=หมุนตามเข็มนาฬิกา +page_rotate_ccw.title=หมุนทวนเข็มนาฬิกา +page_rotate_ccw.label=หมุนทวนเข็มนาฬิกา +page_rotate_ccw_label=หมุนทวนเข็มนาฬิกา + +hand_tool_enable.title=เปิดใช้งานเครื่องมือรูปมือ +hand_tool_enable_label=เปิดใช้งานเครื่องมือรูปมือ +hand_tool_disable.title=ปิดใช้งานเครื่องมือรูปมือ +hand_tool_disable_label=ปิดใช้งานเครื่องมือรูปมือ + +# Document properties dialog box +document_properties.title=คุณสมบัติเอกสาร… +document_properties_label=คุณสมบัติเอกสาร… +document_properties_file_name=ชื่อแฟ้ม : +document_properties_file_size=ขนาดแฟ้ม : +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} กิโลไบต์ ({{size_b}} ไบต์) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} เมกะไบต์ ({{size_b}} ไบต์) +document_properties_title=หัวเรื่อง : +document_properties_author=ผู้แต่ง : +document_properties_subject=หัวข้อ : +document_properties_keywords=คำสำคัญ : +document_properties_creation_date=วันที่สร้าง : +document_properties_modification_date=วันที่แก้ไข : +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=สร้างโดย : +document_properties_producer=ผู้ผลิต PDF : +document_properties_version=รุ่น PDF : +document_properties_page_count=จำนวนหน้า : +document_properties_close=ปิด + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=สลับแถบข้าง +toggle_sidebar_label=สลับแถบข้าง +outline.title=แสดงโครงเอกสาร +outline_label=โครงเอกสาร +attachments.title=แสดงสิ่งที่แนบมา +attachments_label=สิ่งที่แนบมา +thumbs.title=แสดงภาพขนาดย่อ +thumbs_label=ภาพขนาดย่อ +findbar.title=ค้นหาในเอกสาร +findbar_label=ค้นหา + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=หน้า {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=ภาพขนาดย่อของหน้า {{page}} + +# Find panel button title and messages +find_label=ค้นหา: +find_previous.title=หาตำแหน่งก่อนหน้าของคำค้น +find_previous_label=ก่อนหน้า +find_next.title=หาตำแหน่งถัดไปของคำค้น +find_next_label=ถัดไป +find_highlight=เน้นสีทั้งหมด +find_match_case_label=ตัวพิมพ์ตรงกัน +find_reached_top=ค้นหาถึงจุดเริ่มต้นของหน้า เริ่มค้นต่อจากด้านล่าง +find_reached_bottom=ค้นหาถึงจุดสิ้นสุดหน้า เริ่มค้นต่อจากด้านบน +find_not_found=ไม่พบวลีที่ต้องการ + +# Error panel labels +error_more_info=ข้อมูลเพิ่มเติม +error_less_info=ข้อมูลน้อย +error_close=ปิด +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=ข้อความ: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=สแต็ก: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=แฟ้ม: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=บรรทัด: {{line}} +rendering_error=เกิดข้อผิดพลาดขณะกำลังคำนวณการแสดงผลของหน้า + +# Predefined zoom values +page_scale_width=ความกว้างหน้า +page_scale_fit=พอดีหน้า +page_scale_auto=ย่อ-ขยายอัตโนมัติ +page_scale_actual=ขนาดเท่าจริง +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=ข้อผิดพลาด +loading_error=เกิดข้อผิดพลาดขณะกำลังโหลด PDF +invalid_file_error=แฟ้ม PDF ไม่ถูกต้องหรือไม่สมบูรณ์ +missing_file_error=แฟ้ม PDF หาย +unexpected_response_error=การตอบสนองเซิร์ฟเวอร์ที่ไม่คาดหวัง + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[คำอธิบายประกอบ {{type}}] +password_label=ใส่รหัสผ่านเพื่อเปิดไฟล์ PDF นี้ +password_invalid=รหัสผ่านไม่ถูกต้อง โปรดลองอีกครั้ง +password_ok=ตกลง +password_cancel=ยกเลิก + +printing_not_supported=คำเตือน: เบราว์เซอร์นี้ไม่ได้สนับสนุนการพิมพ์อย่างเต็มที่ +printing_not_ready=คำเตือน: PDF ไม่ได้รับการโหลดอย่างเต็มที่สำหรับการพิมพ์ +web_fonts_disabled=แบบอักษรเว็บถูกปิดการใช้งาน: ไม่สามารถใช้แบบอักษรฝังตัวใน PDF +document_colors_not_allowed=เอกสาร PDF ไม่ได้รับอนุญาตให้ใช้สีของตัวเอง: 'อนุญาตให้หน้าเอกสารสามารถเลือกสีของตัวเอง' ถูกปิดใช้งานในเบราว์เซอร์ diff --git a/static/pdf.js/locale/tl/viewer.ftl b/static/pdf.js/locale/tl/viewer.ftl deleted file mode 100644 index faa0009b..00000000 --- a/static/pdf.js/locale/tl/viewer.ftl +++ /dev/null @@ -1,257 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Naunang Pahina -pdfjs-previous-button-label = Nakaraan -pdfjs-next-button = - .title = Sunod na Pahina -pdfjs-next-button-label = Sunod -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Pahina -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = ng { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } ng { $pagesCount }) -pdfjs-zoom-out-button = - .title = Paliitin -pdfjs-zoom-out-button-label = Paliitin -pdfjs-zoom-in-button = - .title = Palakihin -pdfjs-zoom-in-button-label = Palakihin -pdfjs-zoom-select = - .title = Mag-zoom -pdfjs-presentation-mode-button = - .title = Lumipat sa Presentation Mode -pdfjs-presentation-mode-button-label = Presentation Mode -pdfjs-open-file-button = - .title = Magbukas ng file -pdfjs-open-file-button-label = Buksan -pdfjs-print-button = - .title = i-Print -pdfjs-print-button-label = i-Print - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Mga Kagamitan -pdfjs-tools-button-label = Mga Kagamitan -pdfjs-first-page-button = - .title = Pumunta sa Unang Pahina -pdfjs-first-page-button-label = Pumunta sa Unang Pahina -pdfjs-last-page-button = - .title = Pumunta sa Huling Pahina -pdfjs-last-page-button-label = Pumunta sa Huling Pahina -pdfjs-page-rotate-cw-button = - .title = Paikutin Pakanan -pdfjs-page-rotate-cw-button-label = Paikutin Pakanan -pdfjs-page-rotate-ccw-button = - .title = Paikutin Pakaliwa -pdfjs-page-rotate-ccw-button-label = Paikutin Pakaliwa -pdfjs-cursor-text-select-tool-button = - .title = I-enable ang Text Selection Tool -pdfjs-cursor-text-select-tool-button-label = Text Selection Tool -pdfjs-cursor-hand-tool-button = - .title = I-enable ang Hand Tool -pdfjs-cursor-hand-tool-button-label = Hand Tool -pdfjs-scroll-vertical-button = - .title = Gumamit ng Vertical Scrolling -pdfjs-scroll-vertical-button-label = Vertical Scrolling -pdfjs-scroll-horizontal-button = - .title = Gumamit ng Horizontal Scrolling -pdfjs-scroll-horizontal-button-label = Horizontal Scrolling -pdfjs-scroll-wrapped-button = - .title = Gumamit ng Wrapped Scrolling -pdfjs-scroll-wrapped-button-label = Wrapped Scrolling -pdfjs-spread-none-button = - .title = Huwag pagsamahin ang mga page spread -pdfjs-spread-none-button-label = No Spreads -pdfjs-spread-odd-button = - .title = Join page spreads starting with odd-numbered pages -pdfjs-spread-odd-button-label = Mga Odd Spread -pdfjs-spread-even-button = - .title = Pagsamahin ang mga page spread na nagsisimula sa mga even-numbered na pahina -pdfjs-spread-even-button-label = Mga Even Spread - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Mga Katangian ng Dokumento… -pdfjs-document-properties-button-label = Mga Katangian ng Dokumento… -pdfjs-document-properties-file-name = File name: -pdfjs-document-properties-file-size = File size: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Pamagat: -pdfjs-document-properties-author = May-akda: -pdfjs-document-properties-subject = Paksa: -pdfjs-document-properties-keywords = Mga keyword: -pdfjs-document-properties-creation-date = Petsa ng Pagkakagawa: -pdfjs-document-properties-modification-date = Petsa ng Pagkakabago: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Tagalikha: -pdfjs-document-properties-producer = PDF Producer: -pdfjs-document-properties-version = PDF Version: -pdfjs-document-properties-page-count = Bilang ng Pahina: -pdfjs-document-properties-page-size = Laki ng Pahina: -pdfjs-document-properties-page-size-unit-inches = pulgada -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = patayo -pdfjs-document-properties-page-size-orientation-landscape = pahiga -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Fast Web View: -pdfjs-document-properties-linearized-yes = Oo -pdfjs-document-properties-linearized-no = Hindi -pdfjs-document-properties-close-button = Isara - -## Print - -pdfjs-print-progress-message = Inihahanda ang dokumento para sa pag-print… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Kanselahin -pdfjs-printing-not-supported = Babala: Hindi pa ganap na suportado ang pag-print sa browser na ito. -pdfjs-printing-not-ready = Babala: Hindi ganap na nabuksan ang PDF para sa pag-print. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Ipakita/Itago ang Sidebar -pdfjs-toggle-sidebar-notification-button = - .title = Ipakita/Itago ang Sidebar (nagtataglay ang dokumento ng balangkas/mga attachment/mga layer) -pdfjs-toggle-sidebar-button-label = Ipakita/Itago ang Sidebar -pdfjs-document-outline-button = - .title = Ipakita ang Document Outline (mag-double-click para i-expand/collapse ang laman) -pdfjs-document-outline-button-label = Balangkas ng Dokumento -pdfjs-attachments-button = - .title = Ipakita ang mga Attachment -pdfjs-attachments-button-label = Mga attachment -pdfjs-layers-button = - .title = Ipakita ang mga Layer (mag-double click para mareset ang lahat ng layer sa orihinal na estado) -pdfjs-layers-button-label = Mga layer -pdfjs-thumbs-button = - .title = Ipakita ang mga Thumbnail -pdfjs-thumbs-button-label = Mga thumbnail -pdfjs-findbar-button = - .title = Hanapin sa Dokumento -pdfjs-findbar-button-label = Hanapin -pdfjs-additional-layers = Mga Karagdagang Layer - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Pahina { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Thumbnail ng Pahina { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Hanapin - .placeholder = Hanapin sa dokumento… -pdfjs-find-previous-button = - .title = Hanapin ang nakaraang pangyayari ng parirala -pdfjs-find-previous-button-label = Nakaraan -pdfjs-find-next-button = - .title = Hanapin ang susunod na pangyayari ng parirala -pdfjs-find-next-button-label = Susunod -pdfjs-find-highlight-checkbox = I-highlight lahat -pdfjs-find-match-case-checkbox-label = Itugma ang case -pdfjs-find-entire-word-checkbox-label = Buong salita -pdfjs-find-reached-top = Naabot na ang tuktok ng dokumento, ipinagpatuloy mula sa ilalim -pdfjs-find-reached-bottom = Naabot na ang dulo ng dokumento, ipinagpatuloy mula sa tuktok -pdfjs-find-not-found = Hindi natagpuan ang parirala - -## Predefined zoom values - -pdfjs-page-scale-width = Lapad ng Pahina -pdfjs-page-scale-fit = Pagkasyahin ang Pahina -pdfjs-page-scale-auto = Automatic Zoom -pdfjs-page-scale-actual = Totoong sukat -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Nagkaproblema habang niloload ang PDF. -pdfjs-invalid-file-error = Di-wasto o sira ang PDF file. -pdfjs-missing-file-error = Nawawalang PDF file. -pdfjs-unexpected-response-error = Hindi inaasahang tugon ng server. -pdfjs-rendering-error = Nagkaproblema habang nirerender ang pahina. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = Ipasok ang password upang buksan ang PDF file na ito. -pdfjs-password-invalid = Maling password. Subukan uli. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Kanselahin -pdfjs-web-fonts-disabled = Naka-disable ang mga Web font: hindi kayang gamitin ang mga naka-embed na PDF font. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/tl/viewer.properties b/static/pdf.js/locale/tl/viewer.properties new file mode 100644 index 00000000..e83cc87a --- /dev/null +++ b/static/pdf.js/locale/tl/viewer.properties @@ -0,0 +1,94 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Naunang Pahina +next.title=Sunod na Pahina + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Pahina: +page_of=ng {{pageCount}} + +open_file.title=Magbukas ng file +open_file_label=Buksan +bookmark.title=Kasalukuyang tingin (kopyahin o buksan sa bagong window) +bookmark_label=Kasalukuyang tingin + +# Secondary toolbar and context menu +tools.title=Mga Tool +tools_label=Mga Tool + + +# Document properties dialog box +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Pamagat: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +outline.title=Ipakita ang banghay ng dokumento +outline_label=Banghay ng dokumento +thumbs.title=Ipakita ang mga Thumbnails +findbar_label=Hanapin + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Pahina {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Thumbnail ng Pahina {{page}} + +# Find panel button title and messages +find_highlight=I-highlight lahat + +# Error panel labels +error_more_info=Maraming Inpormasyon +error_less_info=Maikling Inpormasyon +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Mensahe: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Linya: {{line}} +rendering_error=May naganap na pagkakamali habang pagsasalin sa pahina. + +# Predefined zoom values +page_scale_width=Haba ng Pahina +page_scale_fit=ang pahina ay angkop +page_scale_auto=awtomatikong pag-imbulog +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error=May maling nangyari habang kinakarga ang PDF. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +password_ok=OK + diff --git a/static/pdf.js/locale/tn/viewer.properties b/static/pdf.js/locale/tn/viewer.properties new file mode 100644 index 00000000..3c9b5031 --- /dev/null +++ b/static/pdf.js/locale/tn/viewer.properties @@ -0,0 +1,83 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Tsebe: + +zoom.title=Zuma/gogela +open_file.title=Bula Faele +open_file_label=Bula + +# Secondary toolbar and context menu + +hand_tool_disable.title=Thibela go dira ga sediriswa sa seatla +hand_tool_disable_label=Thibela go dira ga sediriswa sa seatla + +# Document properties dialog box +document_properties_file_name=Leina la faele: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Leina: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +findbar_label=Batla + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. + +# Find panel button title and messages +find_previous.title=Batla tiragalo e e fetileng ya setlhopha sa mafoko +find_next.title=Batla tiragalo e e latelang ya setlhopha sa mafoko +find_not_found=Setlhopha sa mafoko ga se a bonwa + +# Error panel labels +error_more_info=Tshedimosetso e Nngwe +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number + +# Predefined zoom values +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Phoso + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +password_ok=Siame +password_cancel=Khansela + +web_fonts_disabled=Mefutatlhaka ya Webo ga e dire: ga e kgone go dirisa mofutatlhaka wa PDF o tsentsweng. diff --git a/static/pdf.js/locale/tr/viewer.ftl b/static/pdf.js/locale/tr/viewer.ftl deleted file mode 100644 index 198022eb..00000000 --- a/static/pdf.js/locale/tr/viewer.ftl +++ /dev/null @@ -1,396 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Önceki sayfa -pdfjs-previous-button-label = Önceki -pdfjs-next-button = - .title = Sonraki sayfa -pdfjs-next-button-label = Sonraki -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Sayfa -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = / { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } / { $pagesCount }) -pdfjs-zoom-out-button = - .title = Uzaklaştır -pdfjs-zoom-out-button-label = Uzaklaştır -pdfjs-zoom-in-button = - .title = Yakınlaştır -pdfjs-zoom-in-button-label = Yakınlaştır -pdfjs-zoom-select = - .title = Yakınlaştırma -pdfjs-presentation-mode-button = - .title = Sunum moduna geç -pdfjs-presentation-mode-button-label = Sunum modu -pdfjs-open-file-button = - .title = Dosya aç -pdfjs-open-file-button-label = Aç -pdfjs-print-button = - .title = Yazdır -pdfjs-print-button-label = Yazdır -pdfjs-save-button = - .title = Kaydet -pdfjs-save-button-label = Kaydet -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = İndir -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = İndir -pdfjs-bookmark-button = - .title = Geçerli sayfa (geçerli sayfanın adresini görüntüle) -pdfjs-bookmark-button-label = Geçerli sayfa - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Araçlar -pdfjs-tools-button-label = Araçlar -pdfjs-first-page-button = - .title = İlk sayfaya git -pdfjs-first-page-button-label = İlk sayfaya git -pdfjs-last-page-button = - .title = Son sayfaya git -pdfjs-last-page-button-label = Son sayfaya git -pdfjs-page-rotate-cw-button = - .title = Saat yönünde döndür -pdfjs-page-rotate-cw-button-label = Saat yönünde döndür -pdfjs-page-rotate-ccw-button = - .title = Saat yönünün tersine döndür -pdfjs-page-rotate-ccw-button-label = Saat yönünün tersine döndür -pdfjs-cursor-text-select-tool-button = - .title = Metin seçme aracını etkinleştir -pdfjs-cursor-text-select-tool-button-label = Metin seçme aracı -pdfjs-cursor-hand-tool-button = - .title = El aracını etkinleştir -pdfjs-cursor-hand-tool-button-label = El aracı -pdfjs-scroll-page-button = - .title = Sayfa kaydırmayı kullan -pdfjs-scroll-page-button-label = Sayfa kaydırma -pdfjs-scroll-vertical-button = - .title = Dikey kaydırmayı kullan -pdfjs-scroll-vertical-button-label = Dikey kaydırma -pdfjs-scroll-horizontal-button = - .title = Yatay kaydırmayı kullan -pdfjs-scroll-horizontal-button-label = Yatay kaydırma -pdfjs-scroll-wrapped-button = - .title = Yan yana kaydırmayı kullan -pdfjs-scroll-wrapped-button-label = Yan yana kaydırma -pdfjs-spread-none-button = - .title = Yan yana sayfaları birleştirme -pdfjs-spread-none-button-label = Birleştirme -pdfjs-spread-odd-button = - .title = Yan yana sayfaları tek numaralı sayfalardan başlayarak birleştir -pdfjs-spread-odd-button-label = Tek numaralı -pdfjs-spread-even-button = - .title = Yan yana sayfaları çift numaralı sayfalardan başlayarak birleştir -pdfjs-spread-even-button-label = Çift numaralı - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Belge özellikleri… -pdfjs-document-properties-button-label = Belge özellikleri… -pdfjs-document-properties-file-name = Dosya adı: -pdfjs-document-properties-file-size = Dosya boyutu: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bayt) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bayt) -pdfjs-document-properties-title = Başlık: -pdfjs-document-properties-author = Yazar: -pdfjs-document-properties-subject = Konu: -pdfjs-document-properties-keywords = Anahtar kelimeler: -pdfjs-document-properties-creation-date = Oluşturma tarihi: -pdfjs-document-properties-modification-date = Değiştirme tarihi: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date } { $time } -pdfjs-document-properties-creator = Oluşturan: -pdfjs-document-properties-producer = PDF üreticisi: -pdfjs-document-properties-version = PDF sürümü: -pdfjs-document-properties-page-count = Sayfa sayısı: -pdfjs-document-properties-page-size = Sayfa boyutu: -pdfjs-document-properties-page-size-unit-inches = inç -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = dikey -pdfjs-document-properties-page-size-orientation-landscape = yatay -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Hızlı web görünümü: -pdfjs-document-properties-linearized-yes = Evet -pdfjs-document-properties-linearized-no = Hayır -pdfjs-document-properties-close-button = Kapat - -## Print - -pdfjs-print-progress-message = Belge yazdırılmaya hazırlanıyor… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = %{ $progress } -pdfjs-print-progress-close-button = İptal -pdfjs-printing-not-supported = Uyarı: Yazdırma bu tarayıcı tarafından tam olarak desteklenmemektedir. -pdfjs-printing-not-ready = Uyarı: PDF tamamen yüklenmedi ve yazdırmaya hazır değil. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Kenar çubuğunu aç/kapat -pdfjs-toggle-sidebar-notification-button = - .title = Kenar çubuğunu aç/kapat (Belge ana hat/ekler/katmanlar içeriyor) -pdfjs-toggle-sidebar-button-label = Kenar çubuğunu aç/kapat -pdfjs-document-outline-button = - .title = Belge ana hatlarını göster (Tüm öğeleri genişletmek/daraltmak için çift tıklayın) -pdfjs-document-outline-button-label = Belge ana hatları -pdfjs-attachments-button = - .title = Ekleri göster -pdfjs-attachments-button-label = Ekler -pdfjs-layers-button = - .title = Katmanları göster (tüm katmanları varsayılan duruma sıfırlamak için çift tıklayın) -pdfjs-layers-button-label = Katmanlar -pdfjs-thumbs-button = - .title = Küçük resimleri göster -pdfjs-thumbs-button-label = Küçük resimler -pdfjs-current-outline-item-button = - .title = Mevcut ana hat öğesini bul -pdfjs-current-outline-item-button-label = Mevcut ana hat öğesi -pdfjs-findbar-button = - .title = Belgede bul -pdfjs-findbar-button-label = Bul -pdfjs-additional-layers = Ek katmanlar - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Sayfa { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page }. sayfanın küçük hâli - -## Find panel button title and messages - -pdfjs-find-input = - .title = Bul - .placeholder = Belgede bul… -pdfjs-find-previous-button = - .title = Önceki eşleşmeyi bul -pdfjs-find-previous-button-label = Önceki -pdfjs-find-next-button = - .title = Sonraki eşleşmeyi bul -pdfjs-find-next-button-label = Sonraki -pdfjs-find-highlight-checkbox = Tümünü vurgula -pdfjs-find-match-case-checkbox-label = Büyük-küçük harfe duyarlı -pdfjs-find-match-diacritics-checkbox-label = Fonetik işaretleri bul -pdfjs-find-entire-word-checkbox-label = Tam sözcükler -pdfjs-find-reached-top = Belgenin başına ulaşıldı, sonundan devam edildi -pdfjs-find-reached-bottom = Belgenin sonuna ulaşıldı, başından devam edildi -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $total } eşleşmeden { $current }. eşleşme - *[other] { $total } eşleşmeden { $current }. eşleşme - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] { $limit } eşleşmeden fazla - *[other] { $limit } eşleşmeden fazla - } -pdfjs-find-not-found = Eşleşme bulunamadı - -## Predefined zoom values - -pdfjs-page-scale-width = Sayfa genişliği -pdfjs-page-scale-fit = Sayfayı sığdır -pdfjs-page-scale-auto = Otomatik yakınlaştır -pdfjs-page-scale-actual = Gerçek boyut -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = %{ $scale } - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Sayfa { $page } - -## Loading indicator messages - -pdfjs-loading-error = PDF yüklenirken bir hata oluştu. -pdfjs-invalid-file-error = Geçersiz veya bozulmuş PDF dosyası. -pdfjs-missing-file-error = PDF dosyası eksik. -pdfjs-unexpected-response-error = Beklenmeyen sunucu yanıtı. -pdfjs-rendering-error = Sayfa yorumlanırken bir hata oluştu. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date } { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } işareti] - -## Password - -pdfjs-password-label = Bu PDF dosyasını açmak için parolasını yazın. -pdfjs-password-invalid = Geçersiz parola. Lütfen yeniden deneyin. -pdfjs-password-ok-button = Tamam -pdfjs-password-cancel-button = İptal -pdfjs-web-fonts-disabled = Web fontları devre dışı: Gömülü PDF fontları kullanılamıyor. - -## Editing - -pdfjs-editor-free-text-button = - .title = Metin -pdfjs-editor-free-text-button-label = Metin -pdfjs-editor-ink-button = - .title = Çiz -pdfjs-editor-ink-button-label = Çiz -pdfjs-editor-stamp-button = - .title = Resim ekle veya düzenle -pdfjs-editor-stamp-button-label = Resim ekle veya düzenle -pdfjs-editor-highlight-button = - .title = Vurgula -pdfjs-editor-highlight-button-label = Vurgula -pdfjs-highlight-floating-button = - .title = Vurgula -pdfjs-highlight-floating-button1 = - .title = Vurgula - .aria-label = Vurgula -pdfjs-highlight-floating-button-label = Vurgula - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Çizimi kaldır -pdfjs-editor-remove-freetext-button = - .title = Metni kaldır -pdfjs-editor-remove-stamp-button = - .title = Resmi kaldır -pdfjs-editor-remove-highlight-button = - .title = Vurgulamayı kaldır - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Renk -pdfjs-editor-free-text-size-input = Boyut -pdfjs-editor-ink-color-input = Renk -pdfjs-editor-ink-thickness-input = Kalınlık -pdfjs-editor-ink-opacity-input = Saydamlık -pdfjs-editor-stamp-add-image-button = - .title = Resim ekle -pdfjs-editor-stamp-add-image-button-label = Resim ekle -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Kalınlık -pdfjs-editor-free-highlight-thickness-title = - .title = Metin dışındaki öğeleri vurgularken kalınlığı değiştir -pdfjs-free-text = - .aria-label = Metin düzenleyicisi -pdfjs-free-text-default-content = Yazmaya başlayın… -pdfjs-ink = - .aria-label = Çizim düzenleyicisi -pdfjs-ink-canvas = - .aria-label = Kullanıcı tarafından oluşturulan resim - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Alternatif metin -pdfjs-editor-alt-text-edit-button-label = Alternatif metni düzenle -pdfjs-editor-alt-text-dialog-label = Bir seçenek seçin -pdfjs-editor-alt-text-dialog-description = Alternatif metin, insanlar resmi göremediğinde veya resim yüklenmediğinde işe yarar. -pdfjs-editor-alt-text-add-description-label = Açıklama ekle -pdfjs-editor-alt-text-add-description-description = Konuyu, ortamı veya eylemleri tanımlayan bir iki cümle yazmaya çalışın. -pdfjs-editor-alt-text-mark-decorative-label = Dekoratif olarak işaretle -pdfjs-editor-alt-text-mark-decorative-description = Kenarlıklar veya filigranlar gibi dekoratif resimler için kullanılır. -pdfjs-editor-alt-text-cancel-button = Vazgeç -pdfjs-editor-alt-text-save-button = Kaydet -pdfjs-editor-alt-text-decorative-tooltip = Dekoratif olarak işaretlendi -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Örneğin, “Genç bir adam yemek yemek için masaya oturuyor” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Sol üst köşe — yeniden boyutlandır -pdfjs-editor-resizer-label-top-middle = Üst orta — yeniden boyutlandır -pdfjs-editor-resizer-label-top-right = Sağ üst köşe — yeniden boyutlandır -pdfjs-editor-resizer-label-middle-right = Orta sağ — yeniden boyutlandır -pdfjs-editor-resizer-label-bottom-right = Sağ alt köşe — yeniden boyutlandır -pdfjs-editor-resizer-label-bottom-middle = Alt orta — yeniden boyutlandır -pdfjs-editor-resizer-label-bottom-left = Sol alt köşe — yeniden boyutlandır -pdfjs-editor-resizer-label-middle-left = Orta sol — yeniden boyutlandır - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Vurgu rengi -pdfjs-editor-colorpicker-button = - .title = Rengi değiştir -pdfjs-editor-colorpicker-dropdown = - .aria-label = Renk seçenekleri -pdfjs-editor-colorpicker-yellow = - .title = Sarı -pdfjs-editor-colorpicker-green = - .title = Yeşil -pdfjs-editor-colorpicker-blue = - .title = Mavi -pdfjs-editor-colorpicker-pink = - .title = Pembe -pdfjs-editor-colorpicker-red = - .title = Kırmızı - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Tümünü göster -pdfjs-editor-highlight-show-all-button = - .title = Tümünü göster diff --git a/static/pdf.js/locale/tr/viewer.properties b/static/pdf.js/locale/tr/viewer.properties new file mode 100644 index 00000000..19b47732 --- /dev/null +++ b/static/pdf.js/locale/tr/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Önceki sayfa +previous_label=Önceki +next.title=Sonraki sayfa +next_label=Sonraki + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Sayfa: +page_of=/ {{pageCount}} + +zoom_out.title=Uzaklaș +zoom_out_label=Uzaklaș +zoom_in.title=Yaklaş +zoom_in_label=Yaklaş +zoom.title=Yakınlaştırma +presentation_mode.title=Sunum moduna geç +presentation_mode_label=Sunum Modu +open_file.title=Dosya aç +open_file_label=Aç +print.title=Yazdır +print_label=Yazdır +download.title=İndir +download_label=İndir +bookmark.title=Geçerli görünüm (kopyala veya yeni pencerede aç) +bookmark_label=Geçerli görünüm + +# Secondary toolbar and context menu +tools.title=Araçlar +tools_label=Araçlar +first_page.title=İlk sayfaya git +first_page.label=İlk sayfaya git +first_page_label=İlk sayfaya git +last_page.title=Son sayfaya git +last_page.label=Son sayfaya git +last_page_label=Son sayfaya git +page_rotate_cw.title=Saat yönünde döndür +page_rotate_cw.label=Saat yönünde döndür +page_rotate_cw_label=Saat yönünde döndür +page_rotate_ccw.title=Saat yönünün tersine döndür +page_rotate_ccw.label=Saat yönünün tersine döndür +page_rotate_ccw_label=Saat yönünün tersine döndür + +hand_tool_enable.title=El aracını etkinleştir +hand_tool_enable_label=El aracını etkinleştir +hand_tool_disable.title=El aracını kapat +hand_tool_disable_label=El aracını kapat + +# Document properties dialog box +document_properties.title=Belge özellikleri… +document_properties_label=Belge özellikleri… +document_properties_file_name=Dosya adı: +document_properties_file_size=Dosya boyutu: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bayt) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bayt) +document_properties_title=Başlık: +document_properties_author=Yazar: +document_properties_subject=Konu: +document_properties_keywords=Anahtar kelimeler: +document_properties_creation_date=Oluturma tarihi: +document_properties_modification_date=Değiştirme tarihi: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}} {{time}} +document_properties_creator=Oluşturan: +document_properties_producer=PDF üreticisi: +document_properties_version=PDF sürümü: +document_properties_page_count=Sayfa sayısı: +document_properties_close=Kapat + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Kenar çubuğunu aç/kapat +toggle_sidebar_label=Kenar çubuğunu aç/kapat +outline.title=Belge şemasını göster +outline_label=Belge şeması +attachments.title=Ekleri göster +attachments_label=Ekler +thumbs.title=Küçük resimleri göster +thumbs_label=Küçük resimler +findbar.title=Belgede bul +findbar_label=Bul + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Sayfa {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas={{page}}. sayfanın küçük hâli + +# Find panel button title and messages +find_label=Bul: +find_previous.title=Önceki eşleşmeyi bul +find_previous_label=Önceki +find_next.title=Sonraki eşleşmeyi bul +find_next_label=Sonraki +find_highlight=Tümünü vurgula +find_match_case_label=Büyük-küçük harf eşleştir +find_reached_top=Belgenin başına ulaşıldı, sonundan devam edildi +find_reached_bottom=Belgenin sonuna ulaşıldı, başından devam edildi +find_not_found=Eşleşme bulunamadı + +# Error panel labels +error_more_info=Daha fazla bilgi al +error_less_info=Daha az bilgi +error_close=Kapat +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js sürüm {{version}} (yapı: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=İleti: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Yığın: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Dosya: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Satır: {{line}} +rendering_error=Sayfa yorumlanırken bir hata oluştu. + +# Predefined zoom values +page_scale_width=Sayfa genişliği +page_scale_fit=Sayfayı sığdır +page_scale_auto=Otomatik yakınlaştır +page_scale_actual=Gerçek boyut +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent=%{{scale}} + +# Loading indicator messages +loading_error_indicator=Hata +loading_error=PDF yüklenirken bir hata oluştu. +invalid_file_error=Geçersiz veya bozulmuş PDF dosyası. +missing_file_error=PDF dosyası eksik. +unexpected_response_error=Beklenmeyen sunucu yanıtı. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} işareti] +password_label=Bu PDF dosyasını açmak için parolasını girin. +password_invalid=Geçersiz parola. Lütfen tekrar deneyin. +password_ok=Tamam +password_cancel=İptal + +printing_not_supported=Uyarı: Yazdırma bu tarayıcı tarafından tam olarak desteklenmemektedir. +printing_not_ready=Uyarı: PDF tamamen yüklenmedi ve yazdırmaya hazır değil. +web_fonts_disabled=Web fontları devre dışı: Gömülü PDF fontları kullanılamıyor. +document_colors_not_allowed=PDF belgelerinin kendi renklerini kullanması için izin verilmiyor: 'Sayfalara kendi renklerini seçmesi için izin ver' tarayıcıda etkinleştirilmemiş. diff --git a/static/pdf.js/locale/trs/viewer.ftl b/static/pdf.js/locale/trs/viewer.ftl deleted file mode 100644 index aba3c72a..00000000 --- a/static/pdf.js/locale/trs/viewer.ftl +++ /dev/null @@ -1,197 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Pajinâ gunâj rukùu -pdfjs-previous-button-label = Sa gachin -pdfjs-next-button = - .title = Pajinâ 'na' ñaan -pdfjs-next-button-label = Ne' ñaan -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Ñanj -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = si'iaj { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } of { $pagesCount }) -pdfjs-zoom-out-button = - .title = Nagi'iaj li' -pdfjs-zoom-out-button-label = Nagi'iaj li' -pdfjs-zoom-in-button = - .title = Nagi'iaj niko' -pdfjs-zoom-in-button-label = Nagi'iaj niko' -pdfjs-zoom-select = - .title = dàj nìko ma'an -pdfjs-presentation-mode-button = - .title = Naduno' daj ga ma -pdfjs-presentation-mode-button-label = Daj gà ma -pdfjs-open-file-button = - .title = Na'nïn' chrû ñanj -pdfjs-open-file-button-label = Na'nïn -pdfjs-print-button = - .title = Nari' ña du'ua -pdfjs-print-button-label = Nari' ñadu'ua - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Rasun -pdfjs-tools-button-label = Nej rasùun -pdfjs-first-page-button = - .title = gun' riña pajina asiniin -pdfjs-first-page-button-label = Gun' riña pajina asiniin -pdfjs-last-page-button = - .title = Gun' riña pajina rukù ni'in -pdfjs-last-page-button-label = Gun' riña pajina rukù ni'inj -pdfjs-page-rotate-cw-button = - .title = Tanikaj ne' huat -pdfjs-page-rotate-cw-button-label = Tanikaj ne' huat -pdfjs-page-rotate-ccw-button = - .title = Tanikaj ne' chînt' -pdfjs-page-rotate-ccw-button-label = Tanikaj ne' chint -pdfjs-cursor-text-select-tool-button = - .title = Dugi'iaj sun' sa ganahui texto -pdfjs-cursor-text-select-tool-button-label = Nej rasun arajsun' da' nahui' texto -pdfjs-cursor-hand-tool-button = - .title = Nachrun' nej rasun -pdfjs-cursor-hand-tool-button-label = Sa rajsun ro'o' -pdfjs-scroll-vertical-button = - .title = Garasun' dukuán runūu -pdfjs-scroll-vertical-button-label = Dukuán runūu -pdfjs-scroll-horizontal-button = - .title = Garasun' dukuán nikin' nahui -pdfjs-scroll-horizontal-button-label = Dukuán nikin' nahui -pdfjs-scroll-wrapped-button = - .title = Garasun' sa nachree -pdfjs-scroll-wrapped-button-label = Sa nachree -pdfjs-spread-none-button = - .title = Si nagi'iaj nugun'un' nej pagina hua ninin -pdfjs-spread-none-button-label = Ni'io daj hua pagina -pdfjs-spread-odd-button = - .title = Nagi'iaj nugua'ant nej pajina -pdfjs-spread-odd-button-label = Ni'io' daj hua libro gurin -pdfjs-spread-even-button = - .title = Nakāj dugui' ngà nej pajinâ ayi'ì ngà da' hùi hùi -pdfjs-spread-even-button-label = Nahuin nìko nej - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Nej sa nikāj ñanj… -pdfjs-document-properties-button-label = Nej sa nikāj ñanj… -pdfjs-document-properties-file-name = Si yugui archîbo: -pdfjs-document-properties-file-size = Dàj yachìj archîbo: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Si yugui: -pdfjs-document-properties-author = Sí girirà: -pdfjs-document-properties-subject = Dugui': -pdfjs-document-properties-keywords = Nej nuguan' huìi: -pdfjs-document-properties-creation-date = Gui gurugui' man: -pdfjs-document-properties-modification-date = Nuguan' nahuin nakà: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Guiri ro' -pdfjs-document-properties-producer = Sa ri PDF: -pdfjs-document-properties-version = PDF Version: -pdfjs-document-properties-page-count = Si Guendâ Pâjina: -pdfjs-document-properties-page-size = Dàj yachìj pâjina: -pdfjs-document-properties-page-size-unit-inches = riña -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = nadu'ua -pdfjs-document-properties-page-size-orientation-landscape = dàj huaj -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Da'ngà'a -pdfjs-document-properties-page-size-name-legal = Nuguan' a'nï'ïn - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Nanèt chre ni'iajt riña Web: -pdfjs-document-properties-linearized-yes = Ga'ue -pdfjs-document-properties-linearized-no = Si ga'ue -pdfjs-document-properties-close-button = Narán - -## Print - -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Duyichin' - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Nadunā barrâ nù yi'nïn -pdfjs-toggle-sidebar-button-label = Nadunā barrâ nù yi'nïn -pdfjs-findbar-button-label = Narì' - -## Thumbnails panel item (tooltip and alt text for images) - - -## Find panel button title and messages - -pdfjs-find-previous-button-label = Sa gachîn -pdfjs-find-next-button-label = Ne' ñaan -pdfjs-find-highlight-checkbox = Daran' sa ña'an -pdfjs-find-match-case-checkbox-label = Match case -pdfjs-find-not-found = Nu narì'ij nugua'anj - -## Predefined zoom values - -pdfjs-page-scale-actual = Dàj yàchi akuan' nín -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - - -## Annotations - - -## Password - -pdfjs-password-ok-button = Ga'ue -pdfjs-password-cancel-button = Duyichin' - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/uk/viewer.ftl b/static/pdf.js/locale/uk/viewer.ftl deleted file mode 100644 index d663e675..00000000 --- a/static/pdf.js/locale/uk/viewer.ftl +++ /dev/null @@ -1,398 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Попередня сторінка -pdfjs-previous-button-label = Попередня -pdfjs-next-button = - .title = Наступна сторінка -pdfjs-next-button-label = Наступна -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Сторінка -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = із { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } із { $pagesCount }) -pdfjs-zoom-out-button = - .title = Зменшити -pdfjs-zoom-out-button-label = Зменшити -pdfjs-zoom-in-button = - .title = Збільшити -pdfjs-zoom-in-button-label = Збільшити -pdfjs-zoom-select = - .title = Масштаб -pdfjs-presentation-mode-button = - .title = Перейти в режим презентації -pdfjs-presentation-mode-button-label = Режим презентації -pdfjs-open-file-button = - .title = Відкрити файл -pdfjs-open-file-button-label = Відкрити -pdfjs-print-button = - .title = Друк -pdfjs-print-button-label = Друк -pdfjs-save-button = - .title = Зберегти -pdfjs-save-button-label = Зберегти -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Завантажити -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Завантажити -pdfjs-bookmark-button = - .title = Поточна сторінка (перегляд URL-адреси з поточної сторінки) -pdfjs-bookmark-button-label = Поточна сторінка - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Інструменти -pdfjs-tools-button-label = Інструменти -pdfjs-first-page-button = - .title = На першу сторінку -pdfjs-first-page-button-label = На першу сторінку -pdfjs-last-page-button = - .title = На останню сторінку -pdfjs-last-page-button-label = На останню сторінку -pdfjs-page-rotate-cw-button = - .title = Повернути за годинниковою стрілкою -pdfjs-page-rotate-cw-button-label = Повернути за годинниковою стрілкою -pdfjs-page-rotate-ccw-button = - .title = Повернути проти годинникової стрілки -pdfjs-page-rotate-ccw-button-label = Повернути проти годинникової стрілки -pdfjs-cursor-text-select-tool-button = - .title = Увімкнути інструмент вибору тексту -pdfjs-cursor-text-select-tool-button-label = Інструмент вибору тексту -pdfjs-cursor-hand-tool-button = - .title = Увімкнути інструмент "Рука" -pdfjs-cursor-hand-tool-button-label = Інструмент "Рука" -pdfjs-scroll-page-button = - .title = Використовувати прокручування сторінки -pdfjs-scroll-page-button-label = Прокручування сторінки -pdfjs-scroll-vertical-button = - .title = Використовувати вертикальне прокручування -pdfjs-scroll-vertical-button-label = Вертикальне прокручування -pdfjs-scroll-horizontal-button = - .title = Використовувати горизонтальне прокручування -pdfjs-scroll-horizontal-button-label = Горизонтальне прокручування -pdfjs-scroll-wrapped-button = - .title = Використовувати масштабоване прокручування -pdfjs-scroll-wrapped-button-label = Масштабоване прокручування -pdfjs-spread-none-button = - .title = Не використовувати розгорнуті сторінки -pdfjs-spread-none-button-label = Без розгорнутих сторінок -pdfjs-spread-odd-button = - .title = Розгорнуті сторінки починаються з непарних номерів -pdfjs-spread-odd-button-label = Непарні сторінки зліва -pdfjs-spread-even-button = - .title = Розгорнуті сторінки починаються з парних номерів -pdfjs-spread-even-button-label = Парні сторінки зліва - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Властивості документа… -pdfjs-document-properties-button-label = Властивості документа… -pdfjs-document-properties-file-name = Назва файлу: -pdfjs-document-properties-file-size = Розмір файлу: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } КБ ({ $size_b } байтів) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } МБ ({ $size_b } байтів) -pdfjs-document-properties-title = Заголовок: -pdfjs-document-properties-author = Автор: -pdfjs-document-properties-subject = Тема: -pdfjs-document-properties-keywords = Ключові слова: -pdfjs-document-properties-creation-date = Дата створення: -pdfjs-document-properties-modification-date = Дата зміни: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Створено: -pdfjs-document-properties-producer = Виробник PDF: -pdfjs-document-properties-version = Версія PDF: -pdfjs-document-properties-page-count = Кількість сторінок: -pdfjs-document-properties-page-size = Розмір сторінки: -pdfjs-document-properties-page-size-unit-inches = дюймів -pdfjs-document-properties-page-size-unit-millimeters = мм -pdfjs-document-properties-page-size-orientation-portrait = книжкова -pdfjs-document-properties-page-size-orientation-landscape = альбомна -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Швидкий перегляд в Інтернеті: -pdfjs-document-properties-linearized-yes = Так -pdfjs-document-properties-linearized-no = Ні -pdfjs-document-properties-close-button = Закрити - -## Print - -pdfjs-print-progress-message = Підготовка документу до друку… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Скасувати -pdfjs-printing-not-supported = Попередження: Цей браузер не повністю підтримує друк. -pdfjs-printing-not-ready = Попередження: PDF не повністю завантажений для друку. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Бічна панель -pdfjs-toggle-sidebar-notification-button = - .title = Перемкнути бічну панель (документ містить ескіз/вкладення/шари) -pdfjs-toggle-sidebar-button-label = Перемкнути бічну панель -pdfjs-document-outline-button = - .title = Показати схему документу (подвійний клік для розгортання/згортання елементів) -pdfjs-document-outline-button-label = Схема документа -pdfjs-attachments-button = - .title = Показати вкладення -pdfjs-attachments-button-label = Вкладення -pdfjs-layers-button = - .title = Показати шари (двічі клацніть, щоб скинути всі шари до типового стану) -pdfjs-layers-button-label = Шари -pdfjs-thumbs-button = - .title = Показати мініатюри -pdfjs-thumbs-button-label = Мініатюри -pdfjs-current-outline-item-button = - .title = Знайти поточний елемент змісту -pdfjs-current-outline-item-button-label = Поточний елемент змісту -pdfjs-findbar-button = - .title = Знайти в документі -pdfjs-findbar-button-label = Знайти -pdfjs-additional-layers = Додаткові шари - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Сторінка { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Ескіз сторінки { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Знайти - .placeholder = Знайти в документі… -pdfjs-find-previous-button = - .title = Знайти попереднє входження фрази -pdfjs-find-previous-button-label = Попереднє -pdfjs-find-next-button = - .title = Знайти наступне входження фрази -pdfjs-find-next-button-label = Наступне -pdfjs-find-highlight-checkbox = Підсвітити все -pdfjs-find-match-case-checkbox-label = З урахуванням регістру -pdfjs-find-match-diacritics-checkbox-label = Відповідність діакритичних знаків -pdfjs-find-entire-word-checkbox-label = Цілі слова -pdfjs-find-reached-top = Досягнуто початку документу, продовжено з кінця -pdfjs-find-reached-bottom = Досягнуто кінця документу, продовжено з початку -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = - { $total -> - [one] { $current } збіг з { $total } - [few] { $current } збіги з { $total } - *[many] { $current } збігів з { $total } - } -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = - { $limit -> - [one] Понад { $limit } збіг - [few] Понад { $limit } збіги - *[many] Понад { $limit } збігів - } -pdfjs-find-not-found = Фразу не знайдено - -## Predefined zoom values - -pdfjs-page-scale-width = За шириною -pdfjs-page-scale-fit = Вмістити -pdfjs-page-scale-auto = Автомасштаб -pdfjs-page-scale-actual = Дійсний розмір -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Сторінка { $page } - -## Loading indicator messages - -pdfjs-loading-error = Під час завантаження PDF сталася помилка. -pdfjs-invalid-file-error = Недійсний або пошкоджений PDF-файл. -pdfjs-missing-file-error = Відсутній PDF-файл. -pdfjs-unexpected-response-error = Неочікувана відповідь сервера. -pdfjs-rendering-error = Під час виведення сторінки сталася помилка. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type }-анотація] - -## Password - -pdfjs-password-label = Введіть пароль для відкриття цього PDF-файлу. -pdfjs-password-invalid = Неправильний пароль. Спробуйте ще раз. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Скасувати -pdfjs-web-fonts-disabled = Веб-шрифти вимкнено: неможливо використати вбудовані у PDF шрифти. - -## Editing - -pdfjs-editor-free-text-button = - .title = Текст -pdfjs-editor-free-text-button-label = Текст -pdfjs-editor-ink-button = - .title = Малювати -pdfjs-editor-ink-button-label = Малювати -pdfjs-editor-stamp-button = - .title = Додати чи редагувати зображення -pdfjs-editor-stamp-button-label = Додати чи редагувати зображення -pdfjs-editor-highlight-button = - .title = Підсвітити -pdfjs-editor-highlight-button-label = Підсвітити -pdfjs-highlight-floating-button = - .title = Підсвітити -pdfjs-highlight-floating-button1 = - .title = Підсвітити - .aria-label = Підсвітити -pdfjs-highlight-floating-button-label = Підсвітити - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Вилучити малюнок -pdfjs-editor-remove-freetext-button = - .title = Вилучити текст -pdfjs-editor-remove-stamp-button = - .title = Вилучити зображення -pdfjs-editor-remove-highlight-button = - .title = Вилучити підсвічування - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Колір -pdfjs-editor-free-text-size-input = Розмір -pdfjs-editor-ink-color-input = Колір -pdfjs-editor-ink-thickness-input = Товщина -pdfjs-editor-ink-opacity-input = Прозорість -pdfjs-editor-stamp-add-image-button = - .title = Додати зображення -pdfjs-editor-stamp-add-image-button-label = Додати зображення -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Товщина -pdfjs-editor-free-highlight-thickness-title = - .title = Змінюйте товщину під час підсвічування елементів, крім тексту -pdfjs-free-text = - .aria-label = Текстовий редактор -pdfjs-free-text-default-content = Почніть вводити… -pdfjs-ink = - .aria-label = Графічний редактор -pdfjs-ink-canvas = - .aria-label = Зображення, створене користувачем - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Альтернативний текст -pdfjs-editor-alt-text-edit-button-label = Змінити альтернативний текст -pdfjs-editor-alt-text-dialog-label = Вибрати варіант -pdfjs-editor-alt-text-dialog-description = Альтернативний текст допомагає, коли зображення не видно або коли воно не завантажується. -pdfjs-editor-alt-text-add-description-label = Додати опис -pdfjs-editor-alt-text-add-description-description = Намагайтеся створити 1-2 речення, які описують тему, обставини або дії. -pdfjs-editor-alt-text-mark-decorative-label = Позначити декоративним -pdfjs-editor-alt-text-mark-decorative-description = Використовується для декоративних зображень, наприклад рамок або водяних знаків. -pdfjs-editor-alt-text-cancel-button = Скасувати -pdfjs-editor-alt-text-save-button = Зберегти -pdfjs-editor-alt-text-decorative-tooltip = Позначено декоративним -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Наприклад, “Молодий чоловік сідає за стіл їсти” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Верхній лівий кут – зміна розміру -pdfjs-editor-resizer-label-top-middle = Вгорі посередині – зміна розміру -pdfjs-editor-resizer-label-top-right = Верхній правий кут – зміна розміру -pdfjs-editor-resizer-label-middle-right = Праворуч посередині – зміна розміру -pdfjs-editor-resizer-label-bottom-right = Нижній правий кут – зміна розміру -pdfjs-editor-resizer-label-bottom-middle = Внизу посередині – зміна розміру -pdfjs-editor-resizer-label-bottom-left = Нижній лівий кут – зміна розміру -pdfjs-editor-resizer-label-middle-left = Ліворуч посередині – зміна розміру - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Колір підсвічування -pdfjs-editor-colorpicker-button = - .title = Змінити колір -pdfjs-editor-colorpicker-dropdown = - .aria-label = Вибір кольору -pdfjs-editor-colorpicker-yellow = - .title = Жовтий -pdfjs-editor-colorpicker-green = - .title = Зелений -pdfjs-editor-colorpicker-blue = - .title = Блакитний -pdfjs-editor-colorpicker-pink = - .title = Рожевий -pdfjs-editor-colorpicker-red = - .title = Червоний - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Показати все -pdfjs-editor-highlight-show-all-button = - .title = Показати все diff --git a/static/pdf.js/locale/uk/viewer.properties b/static/pdf.js/locale/uk/viewer.properties new file mode 100644 index 00000000..f899197d --- /dev/null +++ b/static/pdf.js/locale/uk/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Попередня сторінка +previous_label=Попередня +next.title=Наступна сторінка +next_label=Наступна + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Сторінка: +page_of=з {{pageCount}} + +zoom_out.title=Зменшити +zoom_out_label=Зменшити +zoom_in.title=Збільшити +zoom_in_label=Збільшити +zoom.title=Масштаб +presentation_mode.title=Перейти в режим презентації +presentation_mode_label=Режим презентації +open_file.title=Відкрити файл +open_file_label=Відкрити +print.title=Друк +print_label=Друк +download.title=Завантажити +download_label=Завантажити +bookmark.title=Поточний вигляд (копіювати чи відкрити у новому вікні) +bookmark_label=Поточний вигляд + +# Secondary toolbar and context menu +tools.title=Інструменти +tools_label=Інструменти +first_page.title=На першу сторінку +first_page.label=На першу сторінку +first_page_label=На першу сторінку +last_page.title=На останню сторінку +last_page.label=На останню сторінку +last_page_label=На останню сторінку +page_rotate_cw.title=Повернути за годинниковою стрілкою +page_rotate_cw.label=Повернути за годинниковою стрілкою +page_rotate_cw_label=Повернути за годинниковою стрілкою +page_rotate_ccw.title=Повернути проти годинникової стрілки +page_rotate_ccw.label=Повернути проти годинникової стрілки +page_rotate_ccw_label=Повернути проти годинникової стрілки + +hand_tool_enable.title=Увімкнути інструмент «Рука» +hand_tool_enable_label=Увімкнути інструмент «Рука» +hand_tool_disable.title=Вимкнути інструмент «Рука» +hand_tool_disable_label=Вимкнути інструмент «Рука» + +# Document properties dialog box +document_properties.title=Властивості документа… +document_properties_label=Властивості документа… +document_properties_file_name=Назва файла: +document_properties_file_size=Розмір файла: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} КБ ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} МБ ({{size_b}} bytes) +document_properties_title=Заголовок: +document_properties_author=Автор: +document_properties_subject=Тема: +document_properties_keywords=Ключові слова: +document_properties_creation_date=Дата створення: +document_properties_modification_date=Дата зміни: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Створено: +document_properties_producer=Виробник PDF: +document_properties_version=Версія PDF: +document_properties_page_count=Кількість сторінок: +document_properties_close=Закрити + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Бічна панель +toggle_sidebar_label=Перемкнути бічну панель +outline.title=Показувати схему документа +outline_label=Схема документа +attachments.title=Показати прикріплення +attachments_label=Прикріплення +thumbs.title=Показувати ескізи +thumbs_label=Ескізи +findbar.title=Шукати в документі +findbar_label=Пошук + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Сторінка {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Ескіз сторінки {{page}} + +# Find panel button title and messages +find_label=Знайти: +find_previous.title=Знайти попереднє входження фрази +find_previous_label=Попереднє +find_next.title=Знайти наступне входження фрази +find_next_label=Наступне +find_highlight=Підсвітити все +find_match_case_label=З урахуванням регістру +find_reached_top=Досягнуто початку документу, продовжено з кінця +find_reached_bottom=Досягнуто кінця документу, продовжено з початку +find_not_found=Фразу не знайдено + +# Error panel labels +error_more_info=Більше інформації +error_less_info=Менше інформації +error_close=Закрити +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Повідомлення: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Стек: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Файл: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Рядок: {{line}} +rendering_error=Під час виведення сторінки сталася помилка. + +# Predefined zoom values +page_scale_width=За шириною +page_scale_fit=Умістити +page_scale_auto=Авто-масштаб +page_scale_actual=Дійсний розмір +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Помилка +loading_error=Під час завантаження PDF сталася помилка. +invalid_file_error=Недійсний або пошкоджений PDF-файл. +missing_file_error=Відсутній PDF-файл. +unexpected_response_error=Неочікувана відповідь сервера. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}}-аннотація] +password_label=Введіть пароль для відкриття цього PDF-файла. +password_invalid=Невірний пароль. Спробуйте ще. +password_ok=Гаразд +password_cancel=Скасувати + +printing_not_supported=Попередження: Цей браузер не повністю підтримує друк. +printing_not_ready=Попередження: PDF не повністю завантажений для друку. +web_fonts_disabled=Веб-шрифти вимкнено: неможливо використати вбудовані у PDF шрифти. +document_colors_not_allowed=PDF-документам не дозволено використовувати власні кольори: в браузері вимкнено параметр «Дозволити сторінкам використовувати власні кольори». diff --git a/static/pdf.js/locale/ur/viewer.ftl b/static/pdf.js/locale/ur/viewer.ftl deleted file mode 100644 index c15f157e..00000000 --- a/static/pdf.js/locale/ur/viewer.ftl +++ /dev/null @@ -1,248 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = پچھلا صفحہ -pdfjs-previous-button-label = پچھلا -pdfjs-next-button = - .title = اگلا صفحہ -pdfjs-next-button-label = آگے -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = صفحہ -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = { $pagesCount } کا -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } کا { $pagesCount }) -pdfjs-zoom-out-button = - .title = باہر زوم کریں -pdfjs-zoom-out-button-label = باہر زوم کریں -pdfjs-zoom-in-button = - .title = اندر زوم کریں -pdfjs-zoom-in-button-label = اندر زوم کریں -pdfjs-zoom-select = - .title = زوم -pdfjs-presentation-mode-button = - .title = پیشکش موڈ میں چلے جائیں -pdfjs-presentation-mode-button-label = پیشکش موڈ -pdfjs-open-file-button = - .title = مسل کھولیں -pdfjs-open-file-button-label = کھولیں -pdfjs-print-button = - .title = چھاپیں -pdfjs-print-button-label = چھاپیں - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = آلات -pdfjs-tools-button-label = آلات -pdfjs-first-page-button = - .title = پہلے صفحہ پر جائیں -pdfjs-first-page-button-label = پہلے صفحہ پر جائیں -pdfjs-last-page-button = - .title = آخری صفحہ پر جائیں -pdfjs-last-page-button-label = آخری صفحہ پر جائیں -pdfjs-page-rotate-cw-button = - .title = گھڑی وار گھمائیں -pdfjs-page-rotate-cw-button-label = گھڑی وار گھمائیں -pdfjs-page-rotate-ccw-button = - .title = ضد گھڑی وار گھمائیں -pdfjs-page-rotate-ccw-button-label = ضد گھڑی وار گھمائیں -pdfjs-cursor-text-select-tool-button = - .title = متن کے انتخاب کے ٹول کو فعال بناے -pdfjs-cursor-text-select-tool-button-label = متن کے انتخاب کا آلہ -pdfjs-cursor-hand-tool-button = - .title = ہینڈ ٹول کو فعال بناییں -pdfjs-cursor-hand-tool-button-label = ہاتھ کا آلہ -pdfjs-scroll-vertical-button = - .title = عمودی اسکرولنگ کا استعمال کریں -pdfjs-scroll-vertical-button-label = عمودی اسکرولنگ -pdfjs-scroll-horizontal-button = - .title = افقی سکرولنگ کا استعمال کریں -pdfjs-scroll-horizontal-button-label = افقی سکرولنگ -pdfjs-spread-none-button = - .title = صفحہ پھیلانے میں شامل نہ ہوں -pdfjs-spread-none-button-label = کوئی پھیلاؤ نہیں -pdfjs-spread-odd-button-label = تاک پھیلاؤ -pdfjs-spread-even-button-label = جفت پھیلاؤ - -## Document properties dialog - -pdfjs-document-properties-button = - .title = دستاویز خواص… -pdfjs-document-properties-button-label = دستاویز خواص… -pdfjs-document-properties-file-name = نام مسل: -pdfjs-document-properties-file-size = مسل سائز: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = عنوان: -pdfjs-document-properties-author = تخلیق کار: -pdfjs-document-properties-subject = موضوع: -pdfjs-document-properties-keywords = کلیدی الفاظ: -pdfjs-document-properties-creation-date = تخلیق کی تاریخ: -pdfjs-document-properties-modification-date = ترمیم کی تاریخ: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }، { $time } -pdfjs-document-properties-creator = تخلیق کار: -pdfjs-document-properties-producer = PDF پیدا کار: -pdfjs-document-properties-version = PDF ورژن: -pdfjs-document-properties-page-count = صفحہ شمار: -pdfjs-document-properties-page-size = صفہ کی لمبائ: -pdfjs-document-properties-page-size-unit-inches = میں -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = عمودی انداز -pdfjs-document-properties-page-size-orientation-landscape = افقى انداز -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = خط -pdfjs-document-properties-page-size-name-legal = قانونی - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } { $name } { $orientation } - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = تیز ویب دیکھیں: -pdfjs-document-properties-linearized-yes = ہاں -pdfjs-document-properties-linearized-no = نہیں -pdfjs-document-properties-close-button = بند کریں - -## Print - -pdfjs-print-progress-message = چھاپنے کرنے کے لیے دستاویز تیار کیے جا رھے ھیں -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = *{ $progress }%* -pdfjs-print-progress-close-button = منسوخ کریں -pdfjs-printing-not-supported = تنبیہ:چھاپنا اس براؤزر پر پوری طرح معاونت شدہ نہیں ہے۔ -pdfjs-printing-not-ready = تنبیہ: PDF چھپائی کے لیے پوری طرح لوڈ نہیں ہوئی۔ - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = سلائیڈ ٹوگل کریں -pdfjs-toggle-sidebar-button-label = سلائیڈ ٹوگل کریں -pdfjs-document-outline-button = - .title = دستاویز کی سرخیاں دکھایں (تمام اشیاء وسیع / غائب کرنے کے لیے ڈبل کلک کریں) -pdfjs-document-outline-button-label = دستاویز آؤٹ لائن -pdfjs-attachments-button = - .title = منسلکات دکھائیں -pdfjs-attachments-button-label = منسلکات -pdfjs-thumbs-button = - .title = تھمبنیل دکھائیں -pdfjs-thumbs-button-label = مجمل -pdfjs-findbar-button = - .title = دستاویز میں ڈھونڈیں -pdfjs-findbar-button-label = ڈھونڈیں - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = صفحہ { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = صفحے کا مجمل { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = ڈھونڈیں - .placeholder = دستاویز… میں ڈھونڈیں -pdfjs-find-previous-button = - .title = فقرے کا پچھلا وقوع ڈھونڈیں -pdfjs-find-previous-button-label = پچھلا -pdfjs-find-next-button = - .title = فقرے کا اگلہ وقوع ڈھونڈیں -pdfjs-find-next-button-label = آگے -pdfjs-find-highlight-checkbox = تمام نمایاں کریں -pdfjs-find-match-case-checkbox-label = حروف مشابہ کریں -pdfjs-find-entire-word-checkbox-label = تمام الفاظ -pdfjs-find-reached-top = صفحہ کے شروع پر پہنچ گیا، نیچے سے جاری کیا -pdfjs-find-reached-bottom = صفحہ کے اختتام پر پہنچ گیا، اوپر سے جاری کیا -pdfjs-find-not-found = فقرا نہیں ملا - -## Predefined zoom values - -pdfjs-page-scale-width = صفحہ چوڑائی -pdfjs-page-scale-fit = صفحہ فٹنگ -pdfjs-page-scale-auto = خودکار زوم -pdfjs-page-scale-actual = اصل سائز -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = صفحہ { $page } - -## Loading indicator messages - -pdfjs-loading-error = PDF لوڈ کرتے وقت نقص آ گیا۔ -pdfjs-invalid-file-error = ناجائز یا خراب PDF مسل -pdfjs-missing-file-error = PDF مسل غائب ہے۔ -pdfjs-unexpected-response-error = غیرمتوقع پیش کار جواب -pdfjs-rendering-error = صفحہ بناتے ہوئے نقص آ گیا۔ - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }.{ $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } نوٹ] - -## Password - -pdfjs-password-label = PDF مسل کھولنے کے لیے پاس ورڈ داخل کریں. -pdfjs-password-invalid = ناجائز پاس ورڈ. براےؑ کرم دوبارہ کوشش کریں. -pdfjs-password-ok-button = ٹھیک ہے -pdfjs-password-cancel-button = منسوخ کریں -pdfjs-web-fonts-disabled = ویب فانٹ نا اہل ہیں: شامل PDF فانٹ استعمال کرنے میں ناکام۔ - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/ur/viewer.properties b/static/pdf.js/locale/ur/viewer.properties new file mode 100644 index 00000000..4551f631 --- /dev/null +++ b/static/pdf.js/locale/ur/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=پچھلا صفحہ +previous_label=پچھلا +next.title=اگلا صفحہ +next_label=آگے + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=صفحہ: +page_of={{pageCount}} کا + +zoom_out.title=باہر زوم کریں +zoom_out_label=باہر زوم کریں +zoom_in.title=اندر زوم کریں +zoom_in_label=اندر زوم کریں +zoom.title=زوم +presentation_mode.title=پیشکش موڈ میں چلے جائیں +presentation_mode_label=پیشکش موڈ +open_file.title=مسل کھولیں +open_file_label=کھولیں +print.title=چھاپیں +print_label=چھاپیں +download.title=ڈاؤن لوڈ +download_label=ڈاؤن لوڈ +bookmark.title=حالیہ نظارہ (نۓ دریچہ میں نقل کریں یا کھولیں) +bookmark_label=حالیہ نظارہ + +# Secondary toolbar and context menu +tools.title=آلات +tools_label=آلات +first_page.title=پہلے صفحہ پر جائیں +first_page.label=پہلے صفحہ پر جائیں +first_page_label=پہلے صفحہ پر جائیں +last_page.title=آخری صفحہ پر جائیں +last_page.label=آخری صفحہ پر جائیں +last_page_label=آخری صفحہ پر جائیں +page_rotate_cw.title=گھڑی وار گھمائیں +page_rotate_cw.label=گھڑی وار گھمائیں +page_rotate_cw_label=گھڑی وار گھمائیں +page_rotate_ccw.title=ضد گھڑی وار گھمائیں +page_rotate_ccw.label=ضد گھڑی وار گھمائیں +page_rotate_ccw_label=ضد گھڑی وار گھمائیں + +hand_tool_enable.title=ہاتھ ٹول اہل بنائیں +hand_tool_enable_label=ہاتھ ٹول اہل بنائیں +hand_tool_disable.title=ہاتھ ٹول nنااہل بنائیں\u0020 +hand_tool_disable_label=ہاتھ ٹول نااہل بنائیں + +# Document properties dialog box +document_properties.title=دستاویز خواص… +document_properties_label=دستاویز خواص…\u0020 +document_properties_file_name=نام مسل: +document_properties_file_size=مسل سائز: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} bytes) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} bytes) +document_properties_title=عنوان: +document_properties_author=تخلیق کار: +document_properties_subject=موضوع: +document_properties_keywords=کلیدی الفاظ: +document_properties_creation_date=تخلیق کی تاریخ: +document_properties_modification_date=ترمیم کی تاریخ: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}، {{time}} +document_properties_creator=تخلیق کار: +document_properties_producer=PDF پیدا کار: +document_properties_version=PDF ورژن: +document_properties_page_count=صفحہ شمار: +document_properties_close=بند کریں + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=سلائیڈ ٹوگل کریں +toggle_sidebar_label=سلائیڈ ٹوگل کریں +outline.title=دستاویز آؤٹ لائن دکھائیں +outline_label=دستاویز آؤٹ لائن +attachments.title=منسلکات دکھائیں +attachments_label=منسلکات +thumbs.title=تھمبنیل دکھائیں +thumbs_label=مجمل +findbar.title=دستاویز میں ڈھونڈیں +findbar_label=ڈھونڈیں + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=صفحہ {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=صفحے کا مجمل {{page}} + +# Find panel button title and messages +find_label=ڈھونڈیں: +find_previous.title=فقرے کا پچھلا وقوع ڈھونڈیں +find_previous_label=پچھلا +find_next.title=فقرے کا اگلہ وقوع ڈھونڈیں +find_next_label=آگے +find_highlight=تمام نمایاں کریں +find_match_case_label=حروف مشابہ کریں +find_reached_top=صفحہ کے شروع پر پہنچ گیا، نیچے سے جاری کیا +find_reached_bottom=صفحہ کے اختتام پر پہنچ گیا، اوپر سے جاری کیا +find_not_found=فقرا نہیں ملا + +# Error panel labels +error_more_info=مزید معلومات +error_less_info=کم معلومات +error_close=بند کریں +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=پیغام: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=سٹیک: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=مسل: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=لائن: {{line}} +rendering_error=صفحہ بناتے ہوئے نقص آ گیا۔ + +# Predefined zoom values +page_scale_width=صفحہ چوڑائی +page_scale_fit=صفحہ فٹنگ +page_scale_auto=خودکار زوم +page_scale_actual=اصل سائز +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=نقص +loading_error=PDF لوڈ کرتے وقت نقص آ گیا۔ +invalid_file_error=ناجائز یا خراب PDF مسل +missing_file_error=PDF مسل غائب ہے۔ +unexpected_response_error=غیرمتوقع پیش کار جواب + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} نوٹ] +password_label=PDF مسل کھولنے کے لیے پاس ورڈ داخل کریں. +password_invalid=ناجائز پاس ورڈ. براےؑ کرم دوبارہ کوشش کریں. +password_ok=سہی +password_cancel=منسوخ کریں + +printing_not_supported=تنبیہ:چھاپنا اس براؤزر پر پوری طرح معاونت شدہ نہیں ہے۔ +printing_not_ready=تنبیہ: PDF چھپائی کے لیے پوری طرح لوڈ نہیں ہوئی۔ +web_fonts_disabled=ویب فانٹ نا اہل ہیں: شامل PDF فانٹ استعمال کرنے میں ناکام۔ +document_colors_not_allowed=PDF دستاویزات کو اپنے رنگ استعمال کرنے کی اجازت نہیں: 'صفحات کو اپنے رنگ چنیں' کی اِجازت براؤزر میں بے عمل ہے۔ diff --git a/static/pdf.js/locale/uz/viewer.ftl b/static/pdf.js/locale/uz/viewer.ftl deleted file mode 100644 index fb82f22d..00000000 --- a/static/pdf.js/locale/uz/viewer.ftl +++ /dev/null @@ -1,187 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Oldingi sahifa -pdfjs-previous-button-label = Oldingi -pdfjs-next-button = - .title = Keyingi sahifa -pdfjs-next-button-label = Keyingi -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = /{ $pagesCount } -pdfjs-zoom-out-button = - .title = Kichiklashtirish -pdfjs-zoom-out-button-label = Kichiklashtirish -pdfjs-zoom-in-button = - .title = Kattalashtirish -pdfjs-zoom-in-button-label = Kattalashtirish -pdfjs-zoom-select = - .title = Masshtab -pdfjs-presentation-mode-button = - .title = Namoyish usuliga oʻtish -pdfjs-presentation-mode-button-label = Namoyish usuli -pdfjs-open-file-button = - .title = Faylni ochish -pdfjs-open-file-button-label = Ochish -pdfjs-print-button = - .title = Chop qilish -pdfjs-print-button-label = Chop qilish - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Vositalar -pdfjs-tools-button-label = Vositalar -pdfjs-first-page-button = - .title = Birinchi sahifaga oʻtish -pdfjs-first-page-button-label = Birinchi sahifaga oʻtish -pdfjs-last-page-button = - .title = Soʻnggi sahifaga oʻtish -pdfjs-last-page-button-label = Soʻnggi sahifaga oʻtish -pdfjs-page-rotate-cw-button = - .title = Soat yoʻnalishi boʻyicha burish -pdfjs-page-rotate-cw-button-label = Soat yoʻnalishi boʻyicha burish -pdfjs-page-rotate-ccw-button = - .title = Soat yoʻnalishiga qarshi burish -pdfjs-page-rotate-ccw-button-label = Soat yoʻnalishiga qarshi burish - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Hujjat xossalari -pdfjs-document-properties-button-label = Hujjat xossalari -pdfjs-document-properties-file-name = Fayl nomi: -pdfjs-document-properties-file-size = Fayl hajmi: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } bytes) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } bytes) -pdfjs-document-properties-title = Nomi: -pdfjs-document-properties-author = Muallifi: -pdfjs-document-properties-subject = Mavzusi: -pdfjs-document-properties-keywords = Kalit so‘zlar -pdfjs-document-properties-creation-date = Yaratilgan sanasi: -pdfjs-document-properties-modification-date = O‘zgartirilgan sanasi -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Yaratuvchi: -pdfjs-document-properties-producer = PDF ishlab chiqaruvchi: -pdfjs-document-properties-version = PDF versiyasi: -pdfjs-document-properties-page-count = Sahifa soni: - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -pdfjs-document-properties-close-button = Yopish - -## Print - -pdfjs-printing-not-supported = Diqqat: chop qilish bruzer tomonidan toʻliq qoʻllab-quvvatlanmaydi. -pdfjs-printing-not-ready = Diqqat: PDF fayl chop qilish uchun toʻliq yuklanmadi. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Yon panelni yoqib/oʻchirib qoʻyish -pdfjs-toggle-sidebar-button-label = Yon panelni yoqib/oʻchirib qoʻyish -pdfjs-document-outline-button-label = Hujjat tuzilishi -pdfjs-attachments-button = - .title = Ilovalarni ko‘rsatish -pdfjs-attachments-button-label = Ilovalar -pdfjs-thumbs-button = - .title = Nishonchalarni koʻrsatish -pdfjs-thumbs-button-label = Nishoncha -pdfjs-findbar-button = - .title = Hujjat ichidan topish - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = { $page } sahifa -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = { $page } sahifa nishonchasi - -## Find panel button title and messages - -pdfjs-find-previous-button = - .title = Soʻzlardagi oldingi hodisani topish -pdfjs-find-previous-button-label = Oldingi -pdfjs-find-next-button = - .title = Iboradagi keyingi hodisani topish -pdfjs-find-next-button-label = Keyingi -pdfjs-find-highlight-checkbox = Barchasini ajratib koʻrsatish -pdfjs-find-match-case-checkbox-label = Katta-kichik harflarni farqlash -pdfjs-find-reached-top = Hujjatning boshigacha yetib keldik, pastdan davom ettiriladi -pdfjs-find-reached-bottom = Hujjatning oxiriga yetib kelindi, yuqoridan davom ettirladi -pdfjs-find-not-found = Soʻzlar topilmadi - -## Predefined zoom values - -pdfjs-page-scale-width = Sahifa eni -pdfjs-page-scale-fit = Sahifani moslashtirish -pdfjs-page-scale-auto = Avtomatik masshtab -pdfjs-page-scale-actual = Haqiqiy hajmi -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = PDF yuklanayotganda xato yuz berdi. -pdfjs-invalid-file-error = Xato yoki buzuq PDF fayli. -pdfjs-missing-file-error = PDF fayl kerak. -pdfjs-unexpected-response-error = Kutilmagan server javobi. -pdfjs-rendering-error = Sahifa renderlanayotganda xato yuz berdi. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Annotation] - -## Password - -pdfjs-password-label = PDF faylni ochish uchun parolni kiriting. -pdfjs-password-invalid = Parol - notoʻgʻri. Qaytadan urinib koʻring. -pdfjs-password-ok-button = OK -pdfjs-web-fonts-disabled = Veb shriftlar oʻchirilgan: ichki PDF shriftlardan foydalanib boʻlmmaydi. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/vi/viewer.ftl b/static/pdf.js/locale/vi/viewer.ftl deleted file mode 100644 index 4c53f75b..00000000 --- a/static/pdf.js/locale/vi/viewer.ftl +++ /dev/null @@ -1,394 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Trang trước -pdfjs-previous-button-label = Trước -pdfjs-next-button = - .title = Trang Sau -pdfjs-next-button-label = Tiếp -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Trang -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = trên { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } trên { $pagesCount }) -pdfjs-zoom-out-button = - .title = Thu nhỏ -pdfjs-zoom-out-button-label = Thu nhỏ -pdfjs-zoom-in-button = - .title = Phóng to -pdfjs-zoom-in-button-label = Phóng to -pdfjs-zoom-select = - .title = Thu phóng -pdfjs-presentation-mode-button = - .title = Chuyển sang chế độ trình chiếu -pdfjs-presentation-mode-button-label = Chế độ trình chiếu -pdfjs-open-file-button = - .title = Mở tập tin -pdfjs-open-file-button-label = Mở tập tin -pdfjs-print-button = - .title = In -pdfjs-print-button-label = In -pdfjs-save-button = - .title = Lưu -pdfjs-save-button-label = Lưu -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = Tải xuống -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = Tải xuống -pdfjs-bookmark-button = - .title = Trang hiện tại (xem URL từ trang hiện tại) -pdfjs-bookmark-button-label = Trang hiện tại -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = Mở trong ứng dụng -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = Mở trong ứng dụng - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Công cụ -pdfjs-tools-button-label = Công cụ -pdfjs-first-page-button = - .title = Về trang đầu -pdfjs-first-page-button-label = Về trang đầu -pdfjs-last-page-button = - .title = Đến trang cuối -pdfjs-last-page-button-label = Đến trang cuối -pdfjs-page-rotate-cw-button = - .title = Xoay theo chiều kim đồng hồ -pdfjs-page-rotate-cw-button-label = Xoay theo chiều kim đồng hồ -pdfjs-page-rotate-ccw-button = - .title = Xoay ngược chiều kim đồng hồ -pdfjs-page-rotate-ccw-button-label = Xoay ngược chiều kim đồng hồ -pdfjs-cursor-text-select-tool-button = - .title = Kích hoạt công cụ chọn vùng văn bản -pdfjs-cursor-text-select-tool-button-label = Công cụ chọn vùng văn bản -pdfjs-cursor-hand-tool-button = - .title = Kích hoạt công cụ con trỏ -pdfjs-cursor-hand-tool-button-label = Công cụ con trỏ -pdfjs-scroll-page-button = - .title = Sử dụng cuộn trang hiện tại -pdfjs-scroll-page-button-label = Cuộn trang hiện tại -pdfjs-scroll-vertical-button = - .title = Sử dụng cuộn dọc -pdfjs-scroll-vertical-button-label = Cuộn dọc -pdfjs-scroll-horizontal-button = - .title = Sử dụng cuộn ngang -pdfjs-scroll-horizontal-button-label = Cuộn ngang -pdfjs-scroll-wrapped-button = - .title = Sử dụng cuộn ngắt dòng -pdfjs-scroll-wrapped-button-label = Cuộn ngắt dòng -pdfjs-spread-none-button = - .title = Không nối rộng trang -pdfjs-spread-none-button-label = Không có phân cách -pdfjs-spread-odd-button = - .title = Nối trang bài bắt đầu với các trang được đánh số lẻ -pdfjs-spread-odd-button-label = Phân cách theo số lẻ -pdfjs-spread-even-button = - .title = Nối trang bài bắt đầu với các trang được đánh số chẵn -pdfjs-spread-even-button-label = Phân cách theo số chẵn - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Thuộc tính của tài liệu… -pdfjs-document-properties-button-label = Thuộc tính của tài liệu… -pdfjs-document-properties-file-name = Tên tập tin: -pdfjs-document-properties-file-size = Kích thước: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } byte) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } byte) -pdfjs-document-properties-title = Tiêu đề: -pdfjs-document-properties-author = Tác giả: -pdfjs-document-properties-subject = Chủ đề: -pdfjs-document-properties-keywords = Từ khóa: -pdfjs-document-properties-creation-date = Ngày tạo: -pdfjs-document-properties-modification-date = Ngày sửa đổi: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Người tạo: -pdfjs-document-properties-producer = Phần mềm tạo PDF: -pdfjs-document-properties-version = Phiên bản PDF: -pdfjs-document-properties-page-count = Tổng số trang: -pdfjs-document-properties-page-size = Kích thước trang: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = khổ dọc -pdfjs-document-properties-page-size-orientation-landscape = khổ ngang -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Thư -pdfjs-document-properties-page-size-name-legal = Pháp lý - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit } ({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit } ({ $name }, { $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = Xem nhanh trên web: -pdfjs-document-properties-linearized-yes = Có -pdfjs-document-properties-linearized-no = Không -pdfjs-document-properties-close-button = Ðóng - -## Print - -pdfjs-print-progress-message = Chuẩn bị trang để in… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Hủy bỏ -pdfjs-printing-not-supported = Cảnh báo: In ấn không được hỗ trợ đầy đủ ở trình duyệt này. -pdfjs-printing-not-ready = Cảnh báo: PDF chưa được tải hết để in. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Bật/Tắt thanh lề -pdfjs-toggle-sidebar-notification-button = - .title = Bật tắt thanh lề (tài liệu bao gồm bản phác thảo/tập tin đính kèm/lớp) -pdfjs-toggle-sidebar-button-label = Bật/Tắt thanh lề -pdfjs-document-outline-button = - .title = Hiển thị tài liệu phác thảo (nhấp đúp vào để mở rộng/thu gọn tất cả các mục) -pdfjs-document-outline-button-label = Bản phác tài liệu -pdfjs-attachments-button = - .title = Hiện nội dung đính kèm -pdfjs-attachments-button-label = Nội dung đính kèm -pdfjs-layers-button = - .title = Hiển thị các lớp (nhấp đúp để đặt lại tất cả các lớp về trạng thái mặc định) -pdfjs-layers-button-label = Lớp -pdfjs-thumbs-button = - .title = Hiển thị ảnh thu nhỏ -pdfjs-thumbs-button-label = Ảnh thu nhỏ -pdfjs-current-outline-item-button = - .title = Tìm mục phác thảo hiện tại -pdfjs-current-outline-item-button-label = Mục phác thảo hiện tại -pdfjs-findbar-button = - .title = Tìm trong tài liệu -pdfjs-findbar-button-label = Tìm -pdfjs-additional-layers = Các lớp bổ sung - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Trang { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Ảnh thu nhỏ của trang { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Tìm - .placeholder = Tìm trong tài liệu… -pdfjs-find-previous-button = - .title = Tìm cụm từ ở phần trước -pdfjs-find-previous-button-label = Trước -pdfjs-find-next-button = - .title = Tìm cụm từ ở phần sau -pdfjs-find-next-button-label = Tiếp -pdfjs-find-highlight-checkbox = Đánh dấu tất cả -pdfjs-find-match-case-checkbox-label = Phân biệt hoa, thường -pdfjs-find-match-diacritics-checkbox-label = Khớp dấu phụ -pdfjs-find-entire-word-checkbox-label = Toàn bộ từ -pdfjs-find-reached-top = Đã đến phần đầu tài liệu, quay trở lại từ cuối -pdfjs-find-reached-bottom = Đã đến phần cuối của tài liệu, quay trở lại từ đầu -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = { $current } trên { $total } kết quả -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = Tìm thấy hơn { $limit } kết quả -pdfjs-find-not-found = Không tìm thấy cụm từ này - -## Predefined zoom values - -pdfjs-page-scale-width = Vừa chiều rộng -pdfjs-page-scale-fit = Vừa chiều cao -pdfjs-page-scale-auto = Tự động chọn kích thước -pdfjs-page-scale-actual = Kích thước thực -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = Trang { $page } - -## Loading indicator messages - -pdfjs-loading-error = Lỗi khi tải tài liệu PDF. -pdfjs-invalid-file-error = Tập tin PDF hỏng hoặc không hợp lệ. -pdfjs-missing-file-error = Thiếu tập tin PDF. -pdfjs-unexpected-response-error = Máy chủ có phản hồi lạ. -pdfjs-rendering-error = Lỗi khi hiển thị trang. - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date }, { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Chú thích] - -## Password - -pdfjs-password-label = Nhập mật khẩu để mở tập tin PDF này. -pdfjs-password-invalid = Mật khẩu không đúng. Vui lòng thử lại. -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Hủy bỏ -pdfjs-web-fonts-disabled = Phông chữ Web bị vô hiệu hóa: không thể sử dụng các phông chữ PDF được nhúng. - -## Editing - -pdfjs-editor-free-text-button = - .title = Văn bản -pdfjs-editor-free-text-button-label = Văn bản -pdfjs-editor-ink-button = - .title = Vẽ -pdfjs-editor-ink-button-label = Vẽ -pdfjs-editor-stamp-button = - .title = Thêm hoặc chỉnh sửa hình ảnh -pdfjs-editor-stamp-button-label = Thêm hoặc chỉnh sửa hình ảnh -pdfjs-editor-highlight-button = - .title = Đánh dấu -pdfjs-editor-highlight-button-label = Đánh dấu -pdfjs-highlight-floating-button = - .title = Đánh dấu -pdfjs-highlight-floating-button1 = - .title = Đánh dấu - .aria-label = Đánh dấu -pdfjs-highlight-floating-button-label = Đánh dấu - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = Xóa bản vẽ -pdfjs-editor-remove-freetext-button = - .title = Xóa văn bản -pdfjs-editor-remove-stamp-button = - .title = Xóa ảnh -pdfjs-editor-remove-highlight-button = - .title = Xóa phần đánh dấu - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = Màu -pdfjs-editor-free-text-size-input = Kích cỡ -pdfjs-editor-ink-color-input = Màu -pdfjs-editor-ink-thickness-input = Độ dày -pdfjs-editor-ink-opacity-input = Độ mờ -pdfjs-editor-stamp-add-image-button = - .title = Thêm hình ảnh -pdfjs-editor-stamp-add-image-button-label = Thêm hình ảnh -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = Độ dày -pdfjs-editor-free-highlight-thickness-title = - .title = Thay đổi độ dày khi đánh dấu các mục không phải là văn bản -pdfjs-free-text = - .aria-label = Trình sửa văn bản -pdfjs-free-text-default-content = Bắt đầu nhập… -pdfjs-ink = - .aria-label = Trình sửa nét vẽ -pdfjs-ink-canvas = - .aria-label = Hình ảnh do người dùng tạo - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = Văn bản thay thế -pdfjs-editor-alt-text-edit-button-label = Chỉnh sửa văn bản thay thế -pdfjs-editor-alt-text-dialog-label = Chọn một lựa chọn -pdfjs-editor-alt-text-dialog-description = Văn bản thay thế sẽ hữu ích khi mọi người không thể thấy hình ảnh hoặc khi hình ảnh không tải. -pdfjs-editor-alt-text-add-description-label = Thêm một mô tả -pdfjs-editor-alt-text-add-description-description = Hãy nhắm tới 1-2 câu mô tả chủ đề, bối cảnh hoặc hành động. -pdfjs-editor-alt-text-mark-decorative-label = Đánh dấu là trang trí -pdfjs-editor-alt-text-mark-decorative-description = Điều này được sử dụng cho các hình ảnh trang trí, như đường viền hoặc watermark. -pdfjs-editor-alt-text-cancel-button = Hủy bỏ -pdfjs-editor-alt-text-save-button = Lưu -pdfjs-editor-alt-text-decorative-tooltip = Đã đánh dấu là trang trí -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = Ví dụ: “Một thanh niên ngồi xuống bàn để thưởng thức một bữa ăn” - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = Trên cùng bên trái — thay đổi kích thước -pdfjs-editor-resizer-label-top-middle = Trên cùng ở giữa — thay đổi kích thước -pdfjs-editor-resizer-label-top-right = Trên cùng bên phải — thay đổi kích thước -pdfjs-editor-resizer-label-middle-right = Ở giữa bên phải — thay đổi kích thước -pdfjs-editor-resizer-label-bottom-right = Dưới cùng bên phải — thay đổi kích thước -pdfjs-editor-resizer-label-bottom-middle = Ở giữa dưới cùng — thay đổi kích thước -pdfjs-editor-resizer-label-bottom-left = Góc dưới bên trái — thay đổi kích thước -pdfjs-editor-resizer-label-middle-left = Ở giữa bên trái — thay đổi kích thước - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = Màu đánh dấu -pdfjs-editor-colorpicker-button = - .title = Thay đổi màu -pdfjs-editor-colorpicker-dropdown = - .aria-label = Lựa chọn màu sắc -pdfjs-editor-colorpicker-yellow = - .title = Vàng -pdfjs-editor-colorpicker-green = - .title = Xanh lục -pdfjs-editor-colorpicker-blue = - .title = Xanh dương -pdfjs-editor-colorpicker-pink = - .title = Hồng -pdfjs-editor-colorpicker-red = - .title = Đỏ - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = Hiện tất cả -pdfjs-editor-highlight-show-all-button = - .title = Hiện tất cả diff --git a/static/pdf.js/locale/vi/viewer.properties b/static/pdf.js/locale/vi/viewer.properties new file mode 100644 index 00000000..93a95403 --- /dev/null +++ b/static/pdf.js/locale/vi/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Trang Trước +previous_label=Trước +next.title=Trang Sau +next_label=Tiếp + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Trang: +page_of=trên {{pageCount}} + +zoom_out.title=Thu nhỏ +zoom_out_label=Thu nhỏ +zoom_in.title=Phóng to +zoom_in_label=Phóng to +zoom.title=Chỉnh kích thước +presentation_mode.title=Chuyển sang chế độ trình chiếu +presentation_mode_label=Chế độ trình chiếu +open_file.title=Mở tập tin +open_file_label=Mở tập tin +print.title=In +print_label=In +download.title=Tải xuống +download_label=Tải xuống +bookmark.title=Góc nhìn hiện tại (copy hoặc mở trong cửa sổ mới) +bookmark_label=Chế độ xem hiện tại + +# Secondary toolbar and context menu +tools.title=Công cụ +tools_label=Công cụ +first_page.title=Về trang đầu +first_page.label=Về trang đầu +first_page_label=Về trang đầu +last_page.title=Đến trang cuối +last_page.label=Đến trang cuối +last_page_label=Đến trang cuối +page_rotate_cw.title=Xoay theo chiều kim đồng hồ +page_rotate_cw.label=Xoay theo chiều kim đồng hồ +page_rotate_cw_label=Xoay theo chiều kim đồng hồ +page_rotate_ccw.title=Xoay ngược chiều kim đồng hồ +page_rotate_ccw.label=Xoay ngược chiều kim đồng hồ +page_rotate_ccw_label=Xoay ngược chiều kim đồng hồ + +hand_tool_enable.title=Cho phép kéo để cuộn trang +hand_tool_enable_label=Cho phép kéo để cuộn trang +hand_tool_disable.title=Tắt kéo để cuộn trang +hand_tool_disable_label=Tắt kéo để cuộn trang + +# Document properties dialog box +document_properties.title=Thuộc tính của tài liệu… +document_properties_label=Thuộc tính của tài liệu… +document_properties_file_name=Tên tập tin: +document_properties_file_size=Kích thước: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} byte) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} byte) +document_properties_title=Tiêu đề: +document_properties_author=Tác giả: +document_properties_subject=Chủ đề: +document_properties_keywords=Từ khóa: +document_properties_creation_date=Ngày tạo: +document_properties_modification_date=Ngày sửa đổi: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Người tạo: +document_properties_producer=Phần mềm tạo PDF: +document_properties_version=Phiên bản PDF: +document_properties_page_count=Tổng số trang: +document_properties_close=Ðóng + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Bật/Tắt thanh lề +toggle_sidebar_label=Bật/Tắt thanh lề +outline.title=Hiển thị bản phác tài liệu +outline_label=Bản phác tài liệu +attachments.title=Hiện nội dung đính kèm +attachments_label=Nội dung đính kèm +thumbs.title=Hiển thị ảnh thu nhỏ +thumbs_label=Ảnh thu nhỏ +findbar.title=Tìm trong tài liệu +findbar_label=Tìm + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Trang {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Ảnh thu nhỏ của trang {{page}} + +# Find panel button title and messages +find_label=Tìm: +find_previous.title=Tìm cụm từ ở phần trước +find_previous_label=Trước +find_next.title=Tìm cụm từ ở phần sau +find_next_label=Tiếp +find_highlight=Tô sáng tất cả +find_match_case_label=Phân biệt hoa, thường +find_reached_top=Đã đến phần đầu tài liệu, quay trở lại từ cuối +find_reached_bottom=Đã đến phần cuối của tài liệu, quay trở lại từ đầu +find_not_found=Không tìm thấy cụm từ này + +# Error panel labels +error_more_info=Thông tin thêm +error_less_info=Hiển thị ít thông tin hơn +error_close=Đóng +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Thông điệp: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Stack: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Tập tin: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Dòng: {{line}} +rendering_error=Lỗi khi hiển thị trang. + +# Predefined zoom values +page_scale_width=Vừa chiều rộng +page_scale_fit=Vừa chiều cao +page_scale_auto=Tự động chọn kích thước +page_scale_actual=Kích thước thực +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Lỗi +loading_error=Lỗi khi tải tài liệu PDF. +invalid_file_error=Tập tin PDF hỏng hoặc không hợp lệ. +missing_file_error=Thiếu tập tin PDF. +unexpected_response_error=Máy chủ có phản hồi lạ. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Chú thích] +password_label=Nhập mật khẩu để mở tập tin PDF này. +password_invalid=Mật khẩu không đúng. Vui lòng thử lại. +password_ok=OK +password_cancel=Hủy bỏ + +printing_not_supported=Cảnh báo: In ấn không được hỗ trợ đầy đủ ở trình duyệt này. +printing_not_ready=Cảnh báo: PDF chưa được tải hết để in. +web_fonts_disabled=Phông chữ Web bị vô hiệu hóa: không thể sử dụng các phông chữ PDF được nhúng. +document_colors_not_allowed=Tài liệu PDF không được cho phép dùng màu riêng: 'Cho phép trang chọn màu riêng' đã bị tắt trên trình duyệt. diff --git a/static/pdf.js/locale/wo/viewer.ftl b/static/pdf.js/locale/wo/viewer.ftl deleted file mode 100644 index d66c4591..00000000 --- a/static/pdf.js/locale/wo/viewer.ftl +++ /dev/null @@ -1,127 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Xët wi jiitu -pdfjs-previous-button-label = Bi jiitu -pdfjs-next-button = - .title = Xët wi ci topp -pdfjs-next-button-label = Bi ci topp -pdfjs-zoom-out-button = - .title = Wàññi -pdfjs-zoom-out-button-label = Wàññi -pdfjs-zoom-in-button = - .title = Yaatal -pdfjs-zoom-in-button-label = Yaatal -pdfjs-zoom-select = - .title = Yambalaŋ -pdfjs-presentation-mode-button = - .title = Wañarñil ci anamu wone -pdfjs-presentation-mode-button-label = Anamu Wone -pdfjs-open-file-button = - .title = Ubbi benn dencukaay -pdfjs-open-file-button-label = Ubbi -pdfjs-print-button = - .title = Móol -pdfjs-print-button-label = Móol - -## Secondary toolbar and context menu - - -## Document properties dialog - -pdfjs-document-properties-title = Bopp: - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - - -## Print - -pdfjs-printing-not-supported = Artu: Joowkat bii nanguwul lool mool. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-thumbs-button = - .title = Wone nataal yu ndaw yi -pdfjs-thumbs-button-label = Nataal yu ndaw yi -pdfjs-findbar-button = - .title = Gis ci biir jukki bi -pdfjs-findbar-button-label = Wut - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Xët { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Wiñet bu xët { $page } - -## Find panel button title and messages - -pdfjs-find-previous-button = - .title = Seet beneen kaddu bu ni mel te jiitu -pdfjs-find-previous-button-label = Bi jiitu -pdfjs-find-next-button = - .title = Seet beneen kaddu bu ni mel -pdfjs-find-next-button-label = Bi ci topp -pdfjs-find-highlight-checkbox = Melaxal lépp -pdfjs-find-match-case-checkbox-label = Sàmm jëmmalin wi -pdfjs-find-reached-top = Jot nañu ndorteel xët wi, kontine dale ko ci suuf -pdfjs-find-reached-bottom = Jot nañu jeexitalu xët wi, kontine ci ndorte -pdfjs-find-not-found = Gisiñu kaddu gi - -## Predefined zoom values - -pdfjs-page-scale-width = Yaatuwaay bu mët -pdfjs-page-scale-fit = Xët lëmm -pdfjs-page-scale-auto = Yambalaŋ ci saa si -pdfjs-page-scale-actual = Dayo bi am - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Am na njumte ci yebum dencukaay PDF bi. -pdfjs-invalid-file-error = Dencukaay PDF bi baaxul walla mu sankar. -pdfjs-rendering-error = Am njumte bu am bi xët bi di wonewu. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [Karmat { $type }] - -## Password - -pdfjs-password-ok-button = OK -pdfjs-password-cancel-button = Neenal - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/wo/viewer.properties b/static/pdf.js/locale/wo/viewer.properties new file mode 100644 index 00000000..1e70845b --- /dev/null +++ b/static/pdf.js/locale/wo/viewer.properties @@ -0,0 +1,124 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Xët wi jiitu +previous_label=Bi jiitu +next.title=Xët wi ci topp +next_label=Bi ci topp + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Xët: +page_of=ci {{pageCount}} + +zoom_out.title=Wàññi +zoom_out_label=Wàññi +zoom_in.title=Yaatal +zoom_in_label=Yaatal +zoom.title=Yambalaŋ +presentation_mode.title=Wañarñil ci anamu wone +presentation_mode_label=Anamu Wone +open_file.title=Ubbi benn dencukaay +open_file_label=Ubbi +print.title=Móol +print_label=Móol +download.title=Yeb yi +download_label=Yeb yi +bookmark.title=Wone bi taxaw (duppi walla ubbi palanteer bu bees) +bookmark_label=Wone bi feeñ + +# Secondary toolbar and context menu + + +# Document properties dialog box +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Bopp: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +outline.title=Wone takku yi +outline_label=Takku jukki yi +thumbs.title=Wone nataal yu ndaw yi +thumbs_label=Nataal yu ndaw yi +findbar.title=Gis ci biir jukki bi +findbar_label=Wut + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Xët {{xët}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Wiñet bu xët{{xët}} + +# Find panel button title and messages +find_label=Wut: +find_previous.title=Seet beneen kaddu bu ni mel te jiitu +find_previous_label=Bi jiitu +find_next.title=Seet beneen kaddu bu ni mel +find_next_label=Bi ci topp +find_highlight=Melaxal lépp +find_match_case_label=Sàmm jëmmalin wi +find_reached_top=Jot nañu ndorteel xët wi, kontine dale ko ci suuf +find_reached_bottom=Jot nañu jeexitalu xët wi, kontine ci ndorte +find_not_found=Gisiñu kaddu gi + +# Error panel labels +error_more_info=Xibaar yu gën bari +error_less_info=Xibaar yu gën bari +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Bataaxal: {{bataaxal}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Juug: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Dencukaay: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Rëdd : {{line}} +rendering_error=Am njumte bu am bi xët bi di wonewu. + +# Predefined zoom values +page_scale_width=Yaatuwaay bu mët +page_scale_fit=Xët lëmm +page_scale_auto=Yambalaŋ ci saa si +page_scale_actual=Dayo bi am +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Njumte +loading_error=Am na njumte ci yebum dencukaay PDF bi. +invalid_file_error=Dencukaay PDF bi baaxul walla mu sankar. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Karmat {{type}}] +password_ok=OK +password_cancel=Neenal + +printing_not_supported=Artu: Joowkat bii nanguwul lool mool. diff --git a/static/pdf.js/locale/xh/viewer.ftl b/static/pdf.js/locale/xh/viewer.ftl deleted file mode 100644 index 07988873..00000000 --- a/static/pdf.js/locale/xh/viewer.ftl +++ /dev/null @@ -1,212 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = Iphepha langaphambili -pdfjs-previous-button-label = Okwangaphambili -pdfjs-next-button = - .title = Iphepha elilandelayo -pdfjs-next-button-label = Okulandelayo -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = Iphepha -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = kwali- { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } kwali { $pagesCount }) -pdfjs-zoom-out-button = - .title = Bhekelisela Kudana -pdfjs-zoom-out-button-label = Bhekelisela Kudana -pdfjs-zoom-in-button = - .title = Sondeza Kufuphi -pdfjs-zoom-in-button-label = Sondeza Kufuphi -pdfjs-zoom-select = - .title = Yandisa / Nciphisa -pdfjs-presentation-mode-button = - .title = Tshintshela kwimo yonikezelo -pdfjs-presentation-mode-button-label = Imo yonikezelo -pdfjs-open-file-button = - .title = Vula Ifayile -pdfjs-open-file-button-label = Vula -pdfjs-print-button = - .title = Printa -pdfjs-print-button-label = Printa - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = Izixhobo zemiyalelo -pdfjs-tools-button-label = Izixhobo zemiyalelo -pdfjs-first-page-button = - .title = Yiya kwiphepha lokuqala -pdfjs-first-page-button-label = Yiya kwiphepha lokuqala -pdfjs-last-page-button = - .title = Yiya kwiphepha lokugqibela -pdfjs-last-page-button-label = Yiya kwiphepha lokugqibela -pdfjs-page-rotate-cw-button = - .title = Jikelisa ngasekunene -pdfjs-page-rotate-cw-button-label = Jikelisa ngasekunene -pdfjs-page-rotate-ccw-button = - .title = Jikelisa ngasekhohlo -pdfjs-page-rotate-ccw-button-label = Jikelisa ngasekhohlo -pdfjs-cursor-text-select-tool-button = - .title = Vumela iSixhobo sokuKhetha iTeksti -pdfjs-cursor-text-select-tool-button-label = ISixhobo sokuKhetha iTeksti -pdfjs-cursor-hand-tool-button = - .title = Yenza iSixhobo seSandla siSebenze -pdfjs-cursor-hand-tool-button-label = ISixhobo seSandla - -## Document properties dialog - -pdfjs-document-properties-button = - .title = Iipropati zoxwebhu… -pdfjs-document-properties-button-label = Iipropati zoxwebhu… -pdfjs-document-properties-file-name = Igama lefayile: -pdfjs-document-properties-file-size = Isayizi yefayile: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB (iibhayiti{ $size_b }) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB (iibhayithi{ $size_b }) -pdfjs-document-properties-title = Umxholo: -pdfjs-document-properties-author = Umbhali: -pdfjs-document-properties-subject = Umbandela: -pdfjs-document-properties-keywords = Amagama aphambili: -pdfjs-document-properties-creation-date = Umhla wokwenziwa kwayo: -pdfjs-document-properties-modification-date = Umhla wokulungiswa kwayo: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = Umntu oyenzileyo: -pdfjs-document-properties-producer = Umvelisi we-PDF: -pdfjs-document-properties-version = Uhlelo lwe-PDF: -pdfjs-document-properties-page-count = Inani lamaphepha: - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - - -## - -pdfjs-document-properties-close-button = Vala - -## Print - -pdfjs-print-progress-message = Ilungisa uxwebhu ukuze iprinte… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = Rhoxisa -pdfjs-printing-not-supported = Isilumkiso: Ukuprinta akuxhaswa ngokupheleleyo yile bhrawuza. -pdfjs-printing-not-ready = Isilumkiso: IPDF ayihlohlwanga ngokupheleleyo ukwenzela ukuprinta. - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = Togola ngebha eseCaleni -pdfjs-toggle-sidebar-button-label = Togola ngebha eseCaleni -pdfjs-document-outline-button = - .title = Bonisa uLwandlalo loXwebhu (cofa kabini ukuze wandise/diliza zonke izinto) -pdfjs-document-outline-button-label = Isishwankathelo soxwebhu -pdfjs-attachments-button = - .title = Bonisa iziqhotyoshelwa -pdfjs-attachments-button-label = Iziqhoboshelo -pdfjs-thumbs-button = - .title = Bonisa ukrobiso kumfanekiso -pdfjs-thumbs-button-label = Ukrobiso kumfanekiso -pdfjs-findbar-button = - .title = Fumana kuXwebhu -pdfjs-findbar-button-label = Fumana - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = Iphepha { $page } -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = Ukrobiso kumfanekiso wephepha { $page } - -## Find panel button title and messages - -pdfjs-find-input = - .title = Fumana - .placeholder = Fumana kuXwebhu… -pdfjs-find-previous-button = - .title = Fumanisa isenzeko sangaphambili sebinzana lamagama -pdfjs-find-previous-button-label = Okwangaphambili -pdfjs-find-next-button = - .title = Fumanisa isenzeko esilandelayo sebinzana lamagama -pdfjs-find-next-button-label = Okulandelayo -pdfjs-find-highlight-checkbox = Qaqambisa konke -pdfjs-find-match-case-checkbox-label = Tshatisa ngobukhulu bukanobumba -pdfjs-find-reached-top = Ufike ngaphezulu ephepheni, kusukwa ngezantsi -pdfjs-find-reached-bottom = Ufike ekupheleni kwephepha, kusukwa ngaphezulu -pdfjs-find-not-found = Ibinzana alifunyenwanga - -## Predefined zoom values - -pdfjs-page-scale-width = Ububanzi bephepha -pdfjs-page-scale-fit = Ukulinganiswa kwephepha -pdfjs-page-scale-auto = Ukwandisa/Ukunciphisa Ngokwayo -pdfjs-page-scale-actual = Ubungakanani bokwenene -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - - -## Loading indicator messages - -pdfjs-loading-error = Imposiso yenzekile xa kulayishwa i-PDF. -pdfjs-invalid-file-error = Ifayile ye-PDF engeyiyo okanye eyonakalisiweyo. -pdfjs-missing-file-error = Ifayile ye-PDF edukileyo. -pdfjs-unexpected-response-error = Impendulo yeseva engalindelekanga. -pdfjs-rendering-error = Imposiso yenzekile xa bekunikezelwa iphepha. - -## Annotations - -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } Ubhalo-nqaku] - -## Password - -pdfjs-password-label = Faka ipasiwedi ukuze uvule le fayile yePDF. -pdfjs-password-invalid = Ipasiwedi ayisebenzi. Nceda uzame kwakhona. -pdfjs-password-ok-button = KULUNGILE -pdfjs-password-cancel-button = Rhoxisa -pdfjs-web-fonts-disabled = Iifonti zewebhu ziqhwalelisiwe: ayikwazi ukusebenzisa iifonti ze-PDF ezincanyathelisiweyo. - -## Editing - - -## Alt-text dialog - - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - diff --git a/static/pdf.js/locale/xh/viewer.properties b/static/pdf.js/locale/xh/viewer.properties new file mode 100644 index 00000000..db46b4c8 --- /dev/null +++ b/static/pdf.js/locale/xh/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Iphepha langaphambili +previous_label=Okwangaphambili +next.title=Iphepha elilandelayo +next_label=Okulandelayo + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Iphepha: +page_of=kwali- {{pageCount}} + +zoom_out.title=Bhekelisela Kudana +zoom_out_label=Bhekelisela Kudana +zoom_in.title=Sondeza Kufuphi +zoom_in_label=Sondeza Kufuphi +zoom.title=Yandisa / Nciphisa +presentation_mode.title=Tshintshela kwimo yonikezelo +presentation_mode_label=Imo yonikezelo +open_file.title=Vula Ifayile +open_file_label=Vula +print.title=Printa +print_label=Printa +download.title=Khuphela +download_label=Khuphela +bookmark.title=Imbonakalo ekhoyo (kopa okanye vula kwifestile entsha) +bookmark_label=Imbonakalo ekhoyo + +# Secondary toolbar and context menu +tools.title=Izixhobo zemiyalelo +tools_label=Izixhobo zemiyalelo +first_page.title=Yiya kwiphepha lokuqala +first_page.label=Yiya kwiphepha lokuqala +first_page_label=Yiya kwiphepha lokuqala +last_page.title=Yiya kwiphepha lokugqibela +last_page.label=Yiya kwiphepha lokugqibela +last_page_label=Yiya kwiphepha lokugqibela +page_rotate_cw.title=Jikelisa ngasekunene +page_rotate_cw.label=Jikelisa ngasekunene +page_rotate_cw_label=Jikelisa ngasekunene +page_rotate_ccw.title=Jikelisa ngasekhohlo +page_rotate_ccw.label=Jikelisa ngasekhohlo +page_rotate_ccw_label=Jikelisa ngasekhohlo + +hand_tool_enable.title=Yenza isixhobo sesandla sisebenze +hand_tool_enable_label=Yenza isixhobo sesandla sisebenze +hand_tool_disable.title=Yenza isixhobo sesandla singasebenzi +hand_tool_disable_label=Yenza isixhobo sesandla singasebenzi + +# Document properties dialog box +document_properties.title=Iipropati zoxwebhu… +document_properties_label=Iipropati zoxwebhu… +document_properties_file_name=Igama lefayile: +document_properties_file_size=Isayizi yefayile: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB (iibhayiti{{size_b}}) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB (iibhayithi{{size_b}}) +document_properties_title=Umxholo: +document_properties_author=Umbhali: +document_properties_subject=Umbandela: +document_properties_keywords=Amagama aphambili: +document_properties_creation_date=Umhla wokwenziwa kwayo: +document_properties_modification_date=Umhla wokulungiswa kwayo: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=Umntu oyenzileyo: +document_properties_producer=Umvelisi we-PDF: +document_properties_version=Uhlelo lwe-PDF: +document_properties_page_count=Inani lamaphepha: +document_properties_close=Vala + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=Togola ngebha eseCaleni +toggle_sidebar_label=Togola ngebha eseCaleni +outline.title=Bonisa isishwankathelo soxwebhu +outline_label=Isishwankathelo soxwebhu +attachments.title=Bonisa iziqhotyoshelwa +attachments_label=Iziqhoboshelo +thumbs.title=Bonisa ukrobiso kumfanekiso +thumbs_label=Ukrobiso kumfanekiso +findbar.title=Fumana kuXwebhu +findbar_label=Fumana + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Iphepha {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Ukrobiso kumfanekiso wephepha {{page}} + +# Find panel button title and messages +find_label=Fumanisa: +find_previous.title=Fumanisa isenzeko sangaphambili sebinzana lamagama +find_previous_label=Okwangaphambili +find_next.title=Fumanisa isenzeko esilandelayo sebinzana lamagama +find_next_label=Okulandelayo +find_highlight=Qaqambisa konke +find_match_case_label=Tshatisa ngobukhulu bukanobumba +find_reached_top=Ufike ngaphezulu ephepheni, kusukwa ngezantsi +find_reached_bottom=Ufike ekupheleni kwephepha, kusukwa ngaphezulu +find_not_found=Ibinzana alifunyenwanga + +# Error panel labels +error_more_info=Inkcazelo Engakumbi +error_less_info=Inkcazelo Encinane +error_close=Vala +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=I-PDF.js v{{version}} (yakha: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Umyalezo: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Imfumba: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Ifayile: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Umgca: {{line}} +rendering_error=Imposiso yenzekile xa bekunikezelwa iphepha. + +# Predefined zoom values +page_scale_width=Ububanzi bephepha +page_scale_fit=Ukulinganiswa kwephepha +page_scale_auto=Ukwandisa/Ukunciphisa Ngokwayo +page_scale_actual=Ubungakanani bokwenene +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=Imposiso +loading_error=Imposiso yenzekile xa kulayishwa i-PDF. +invalid_file_error=Ifayile ye-PDF engeyiyo okanye eyonakalisiweyo. +missing_file_error=Ifayile ye-PDF edukileyo. +unexpected_response_error=Impendulo yeseva engalindelekanga. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} Ubhalo-nqaku] +password_label=Faka ipasiwedi ukuze uvule le fayile yePDF. +password_invalid=Ipasiwedi ayisebenzi. Nceda uzame kwakhona. +password_ok=KULUNGILE +password_cancel=Rhoxisa + +printing_not_supported=Isilumkiso: Ukuprinta akuxhaswa ngokupheleleyo yile bhrawuza. +printing_not_ready=Isilumkiso: IPDF ayihlohlwanga ngokupheleleyo ukwenzela ukuprinta. +web_fonts_disabled=Iifonti zewebhu ziqhwalelisiwe: ayikwazi ukusebenzisa iifonti ze-PDF ezincanyathelisiweyo. +document_colors_not_allowed=Amaxwebhu ePDF akavumelekanga ukuba asebenzise imibala yawo: 'Ukuvumela amaphepha ukuba asebenzise eyawo imibala' kuvaliwe ukuba kungasebenzi kwibhrawuza. diff --git a/static/pdf.js/locale/zh-CN/viewer.ftl b/static/pdf.js/locale/zh-CN/viewer.ftl deleted file mode 100644 index d653d5c2..00000000 --- a/static/pdf.js/locale/zh-CN/viewer.ftl +++ /dev/null @@ -1,388 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = 上一页 -pdfjs-previous-button-label = 上一页 -pdfjs-next-button = - .title = 下一页 -pdfjs-next-button-label = 下一页 -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = 页面 -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = / { $pagesCount } -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = ({ $pageNumber } / { $pagesCount }) -pdfjs-zoom-out-button = - .title = 缩小 -pdfjs-zoom-out-button-label = 缩小 -pdfjs-zoom-in-button = - .title = 放大 -pdfjs-zoom-in-button-label = 放大 -pdfjs-zoom-select = - .title = 缩放 -pdfjs-presentation-mode-button = - .title = 切换到演示模式 -pdfjs-presentation-mode-button-label = 演示模式 -pdfjs-open-file-button = - .title = 打开文件 -pdfjs-open-file-button-label = 打开 -pdfjs-print-button = - .title = 打印 -pdfjs-print-button-label = 打印 -pdfjs-save-button = - .title = 保存 -pdfjs-save-button-label = 保存 -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = 下载 -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = 下载 -pdfjs-bookmark-button = - .title = 当前页面(在当前页面查看 URL) -pdfjs-bookmark-button-label = 当前页面 - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = 工具 -pdfjs-tools-button-label = 工具 -pdfjs-first-page-button = - .title = 转到第一页 -pdfjs-first-page-button-label = 转到第一页 -pdfjs-last-page-button = - .title = 转到最后一页 -pdfjs-last-page-button-label = 转到最后一页 -pdfjs-page-rotate-cw-button = - .title = 顺时针旋转 -pdfjs-page-rotate-cw-button-label = 顺时针旋转 -pdfjs-page-rotate-ccw-button = - .title = 逆时针旋转 -pdfjs-page-rotate-ccw-button-label = 逆时针旋转 -pdfjs-cursor-text-select-tool-button = - .title = 启用文本选择工具 -pdfjs-cursor-text-select-tool-button-label = 文本选择工具 -pdfjs-cursor-hand-tool-button = - .title = 启用手形工具 -pdfjs-cursor-hand-tool-button-label = 手形工具 -pdfjs-scroll-page-button = - .title = 使用页面滚动 -pdfjs-scroll-page-button-label = 页面滚动 -pdfjs-scroll-vertical-button = - .title = 使用垂直滚动 -pdfjs-scroll-vertical-button-label = 垂直滚动 -pdfjs-scroll-horizontal-button = - .title = 使用水平滚动 -pdfjs-scroll-horizontal-button-label = 水平滚动 -pdfjs-scroll-wrapped-button = - .title = 使用平铺滚动 -pdfjs-scroll-wrapped-button-label = 平铺滚动 -pdfjs-spread-none-button = - .title = 不加入衔接页 -pdfjs-spread-none-button-label = 单页视图 -pdfjs-spread-odd-button = - .title = 加入衔接页使奇数页作为起始页 -pdfjs-spread-odd-button-label = 双页视图 -pdfjs-spread-even-button = - .title = 加入衔接页使偶数页作为起始页 -pdfjs-spread-even-button-label = 书籍视图 - -## Document properties dialog - -pdfjs-document-properties-button = - .title = 文档属性… -pdfjs-document-properties-button-label = 文档属性… -pdfjs-document-properties-file-name = 文件名: -pdfjs-document-properties-file-size = 文件大小: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB ({ $size_b } 字节) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB ({ $size_b } 字节) -pdfjs-document-properties-title = 标题: -pdfjs-document-properties-author = 作者: -pdfjs-document-properties-subject = 主题: -pdfjs-document-properties-keywords = 关键词: -pdfjs-document-properties-creation-date = 创建日期: -pdfjs-document-properties-modification-date = 修改日期: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date }, { $time } -pdfjs-document-properties-creator = 创建者: -pdfjs-document-properties-producer = PDF 生成器: -pdfjs-document-properties-version = PDF 版本: -pdfjs-document-properties-page-count = 页数: -pdfjs-document-properties-page-size = 页面大小: -pdfjs-document-properties-page-size-unit-inches = 英寸 -pdfjs-document-properties-page-size-unit-millimeters = 毫米 -pdfjs-document-properties-page-size-orientation-portrait = 纵向 -pdfjs-document-properties-page-size-orientation-landscape = 横向 -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit }({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit }({ $name },{ $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = 快速 Web 视图: -pdfjs-document-properties-linearized-yes = 是 -pdfjs-document-properties-linearized-no = 否 -pdfjs-document-properties-close-button = 关闭 - -## Print - -pdfjs-print-progress-message = 正在准备打印文档… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = 取消 -pdfjs-printing-not-supported = 警告:此浏览器尚未完整支持打印功能。 -pdfjs-printing-not-ready = 警告:此 PDF 未完成加载,无法打印。 - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = 切换侧栏 -pdfjs-toggle-sidebar-notification-button = - .title = 切换侧栏(文档所含的大纲/附件/图层) -pdfjs-toggle-sidebar-button-label = 切换侧栏 -pdfjs-document-outline-button = - .title = 显示文档大纲(双击展开/折叠所有项) -pdfjs-document-outline-button-label = 文档大纲 -pdfjs-attachments-button = - .title = 显示附件 -pdfjs-attachments-button-label = 附件 -pdfjs-layers-button = - .title = 显示图层(双击即可将所有图层重置为默认状态) -pdfjs-layers-button-label = 图层 -pdfjs-thumbs-button = - .title = 显示缩略图 -pdfjs-thumbs-button-label = 缩略图 -pdfjs-current-outline-item-button = - .title = 查找当前大纲项目 -pdfjs-current-outline-item-button-label = 当前大纲项目 -pdfjs-findbar-button = - .title = 在文档中查找 -pdfjs-findbar-button-label = 查找 -pdfjs-additional-layers = 其他图层 - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = 第 { $page } 页 -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = 页面 { $page } 的缩略图 - -## Find panel button title and messages - -pdfjs-find-input = - .title = 查找 - .placeholder = 在文档中查找… -pdfjs-find-previous-button = - .title = 查找词语上一次出现的位置 -pdfjs-find-previous-button-label = 上一页 -pdfjs-find-next-button = - .title = 查找词语后一次出现的位置 -pdfjs-find-next-button-label = 下一页 -pdfjs-find-highlight-checkbox = 全部高亮显示 -pdfjs-find-match-case-checkbox-label = 区分大小写 -pdfjs-find-match-diacritics-checkbox-label = 匹配变音符号 -pdfjs-find-entire-word-checkbox-label = 全词匹配 -pdfjs-find-reached-top = 到达文档开头,从末尾继续 -pdfjs-find-reached-bottom = 到达文档末尾,从开头继续 -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = 第 { $current } 项,共找到 { $total } 个匹配项 -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = 匹配超过 { $limit } 项 -pdfjs-find-not-found = 找不到指定词语 - -## Predefined zoom values - -pdfjs-page-scale-width = 适合页宽 -pdfjs-page-scale-fit = 适合页面 -pdfjs-page-scale-auto = 自动缩放 -pdfjs-page-scale-actual = 实际大小 -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = 第 { $page } 页 - -## Loading indicator messages - -pdfjs-loading-error = 加载 PDF 时发生错误。 -pdfjs-invalid-file-error = 无效或损坏的 PDF 文件。 -pdfjs-missing-file-error = 缺少 PDF 文件。 -pdfjs-unexpected-response-error = 意外的服务器响应。 -pdfjs-rendering-error = 渲染页面时发生错误。 - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date },{ $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } 注释] - -## Password - -pdfjs-password-label = 输入密码以打开此 PDF 文件。 -pdfjs-password-invalid = 密码无效。请重试。 -pdfjs-password-ok-button = 确定 -pdfjs-password-cancel-button = 取消 -pdfjs-web-fonts-disabled = Web 字体已被禁用:无法使用嵌入的 PDF 字体。 - -## Editing - -pdfjs-editor-free-text-button = - .title = 文本 -pdfjs-editor-free-text-button-label = 文本 -pdfjs-editor-ink-button = - .title = 绘图 -pdfjs-editor-ink-button-label = 绘图 -pdfjs-editor-stamp-button = - .title = 添加或编辑图像 -pdfjs-editor-stamp-button-label = 添加或编辑图像 -pdfjs-editor-highlight-button = - .title = 高亮 -pdfjs-editor-highlight-button-label = 高亮 -pdfjs-highlight-floating-button = - .title = 高亮 -pdfjs-highlight-floating-button1 = - .title = 高亮 - .aria-label = 高亮 -pdfjs-highlight-floating-button-label = 高亮 - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = 移除绘图 -pdfjs-editor-remove-freetext-button = - .title = 移除文本 -pdfjs-editor-remove-stamp-button = - .title = 移除图像 -pdfjs-editor-remove-highlight-button = - .title = 移除高亮 - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = 颜色 -pdfjs-editor-free-text-size-input = 字号 -pdfjs-editor-ink-color-input = 颜色 -pdfjs-editor-ink-thickness-input = 粗细 -pdfjs-editor-ink-opacity-input = 不透明度 -pdfjs-editor-stamp-add-image-button = - .title = 添加图像 -pdfjs-editor-stamp-add-image-button-label = 添加图像 -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = 粗细 -pdfjs-editor-free-highlight-thickness-title = - .title = 更改高亮粗细(用于文本以外项目) -pdfjs-free-text = - .aria-label = 文本编辑器 -pdfjs-free-text-default-content = 开始输入… -pdfjs-ink = - .aria-label = 绘图编辑器 -pdfjs-ink-canvas = - .aria-label = 用户创建图像 - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = 替换文字 -pdfjs-editor-alt-text-edit-button-label = 编辑替换文字 -pdfjs-editor-alt-text-dialog-label = 选择一项 -pdfjs-editor-alt-text-dialog-description = 替换文字可在用户无法看到或加载图像时,描述其内容。 -pdfjs-editor-alt-text-add-description-label = 添加描述 -pdfjs-editor-alt-text-add-description-description = 描述主题、背景或动作,长度尽量控制在两句话内。 -pdfjs-editor-alt-text-mark-decorative-label = 标记为装饰 -pdfjs-editor-alt-text-mark-decorative-description = 用于装饰的图像,例如边框和水印。 -pdfjs-editor-alt-text-cancel-button = 取消 -pdfjs-editor-alt-text-save-button = 保存 -pdfjs-editor-alt-text-decorative-tooltip = 已标记为装饰 -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = 例如:一个少年坐到桌前,准备吃饭 - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = 调整尺寸 - 左上角 -pdfjs-editor-resizer-label-top-middle = 调整尺寸 - 顶部中间 -pdfjs-editor-resizer-label-top-right = 调整尺寸 - 右上角 -pdfjs-editor-resizer-label-middle-right = 调整尺寸 - 右侧中间 -pdfjs-editor-resizer-label-bottom-right = 调整尺寸 - 右下角 -pdfjs-editor-resizer-label-bottom-middle = 调整大小 - 底部中间 -pdfjs-editor-resizer-label-bottom-left = 调整尺寸 - 左下角 -pdfjs-editor-resizer-label-middle-left = 调整尺寸 - 左侧中间 - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = 高亮色 -pdfjs-editor-colorpicker-button = - .title = 更改颜色 -pdfjs-editor-colorpicker-dropdown = - .aria-label = 颜色选择 -pdfjs-editor-colorpicker-yellow = - .title = 黄色 -pdfjs-editor-colorpicker-green = - .title = 绿色 -pdfjs-editor-colorpicker-blue = - .title = 蓝色 -pdfjs-editor-colorpicker-pink = - .title = 粉色 -pdfjs-editor-colorpicker-red = - .title = 红色 - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = 显示全部 -pdfjs-editor-highlight-show-all-button = - .title = 显示全部 diff --git a/static/pdf.js/locale/zh-CN/viewer.properties b/static/pdf.js/locale/zh-CN/viewer.properties new file mode 100644 index 00000000..b3d0de92 --- /dev/null +++ b/static/pdf.js/locale/zh-CN/viewer.properties @@ -0,0 +1,173 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=上一页 +previous_label=上一页 +next.title=下一页 +next_label=下一页 + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=页面: +page_of=/ {{pageCount}} + +zoom_out.title=缩小 +zoom_out_label=缩小 +zoom_in.title=放大 +zoom_in_label=放大 +zoom.title=缩放 +presentation_mode.title=切换到演示模式 +presentation_mode_label=演示模式 +open_file.title=打开文件 +open_file_label=打开 +print.title=打印 +print_label=打印 +download.title=下载 +download_label=下载 +bookmark.title=当前视图(复制或在新窗口中打开) +bookmark_label=当前视图 + +# Secondary toolbar and context menu +tools.title=工具 +tools_label=工具 +first_page.title=转到第一页 +first_page.label=转到第一页 +first_page_label=转到第一页 +last_page.title=转到最后一页 +last_page.label=转到最后一页 +last_page_label=转到最后一页 +page_rotate_cw.title=顺时针旋转 +page_rotate_cw.label=顺时针旋转 +page_rotate_cw_label=顺时针旋转 +page_rotate_ccw.title=逆时针旋转 +page_rotate_ccw.label=逆时针旋转 +page_rotate_ccw_label=逆时针旋转 + +hand_tool_enable.title=启用手形工具 +hand_tool_enable_label=启用手形工具 +hand_tool_disable.title=禁用手形工具 +hand_tool_disable_label=禁用手形工具 + +# Document properties dialog box +document_properties.title=文档属性… +document_properties_label=文档属性… +document_properties_file_name=文件名: +document_properties_file_size=文件大小: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB ({{size_b}} 字节) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB ({{size_b}} 字节) +document_properties_title=标题: +document_properties_author=作者: +document_properties_subject=主题: +document_properties_keywords=关键词: +document_properties_creation_date=创建日期: +document_properties_modification_date=修改日期: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=创建者: +document_properties_producer=PDF 制作者: +document_properties_version=PDF 版本: +document_properties_page_count=页数: +document_properties_close=关闭 + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=切换侧栏 +toggle_sidebar_label=切换侧栏 +outline.title=显示文档大纲 +outline_label=文档大纲 +attachments.title=显示附件 +attachments_label=附件 +thumbs.title=显示缩略图 +thumbs_label=缩略图 +findbar.title=在文档中查找 +findbar_label=查找 + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=页码 {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=页面 {{page}} 的缩略图 + +# Find panel button title and messages +find_label=查找: +find_previous.title=查找词语上一次出现的位置 +find_previous_label=上一页 +find_next.title=查找词语后一次出现的位置 +find_next_label=下一页 +find_highlight=全部高亮显示 +find_match_case_label=区分大小写 +find_reached_top=到达文档开头,从末尾继续 +find_reached_bottom=到达文档末尾,从开头继续 +find_not_found=词语未找到 + +# Error panel labels +error_more_info=更多信息 +error_less_info=更少信息 +error_close=关闭 +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=信息:{{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=堆栈:{{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=文件:{{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=行号:{{line}} +rendering_error=渲染页面时发生错误。 + +# Predefined zoom values +page_scale_width=适合页宽 +page_scale_fit=适合页面 +page_scale_auto=自动缩放 +page_scale_actual=实际大小 +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=错误 +loading_error=载入PDF时发生错误。 +invalid_file_error=无效或损坏的PDF文件。 +missing_file_error=缺少PDF文件。 +unexpected_response_error=意外的服务器响应。 + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} 注解] +password_label=输入密码以打开此 PDF 文件。 +password_invalid=密码无效。请重试。 +password_ok=确定 +password_cancel=取消 + +printing_not_supported=警告:打印功能不完全支持此浏览器。 +printing_not_ready=警告:该 PDF 未完全加载以供打印。 +web_fonts_disabled=Web 字体已被禁用:无法使用嵌入的PDF字体。 +document_colors_not_allowed=不允许 PDF 文档使用自己的颜色:浏览器中“允许页面选择自己的颜色”的选项已停用。 diff --git a/static/pdf.js/locale/zh-TW/viewer.ftl b/static/pdf.js/locale/zh-TW/viewer.ftl deleted file mode 100644 index f8614a9f..00000000 --- a/static/pdf.js/locale/zh-TW/viewer.ftl +++ /dev/null @@ -1,394 +0,0 @@ -# This Source Code Form is subject to the terms of the Mozilla Public -# License, v. 2.0. If a copy of the MPL was not distributed with this -# file, You can obtain one at http://mozilla.org/MPL/2.0/. - - -## Main toolbar buttons (tooltips and alt text for images) - -pdfjs-previous-button = - .title = 上一頁 -pdfjs-previous-button-label = 上一頁 -pdfjs-next-button = - .title = 下一頁 -pdfjs-next-button-label = 下一頁 -# .title: Tooltip for the pageNumber input. -pdfjs-page-input = - .title = 第 -# Variables: -# $pagesCount (Number) - the total number of pages in the document -# This string follows an input field with the number of the page currently displayed. -pdfjs-of-pages = 頁,共 { $pagesCount } 頁 -# Variables: -# $pageNumber (Number) - the currently visible page -# $pagesCount (Number) - the total number of pages in the document -pdfjs-page-of-pages = (第 { $pageNumber } 頁,共 { $pagesCount } 頁) -pdfjs-zoom-out-button = - .title = 縮小 -pdfjs-zoom-out-button-label = 縮小 -pdfjs-zoom-in-button = - .title = 放大 -pdfjs-zoom-in-button-label = 放大 -pdfjs-zoom-select = - .title = 縮放 -pdfjs-presentation-mode-button = - .title = 切換至簡報模式 -pdfjs-presentation-mode-button-label = 簡報模式 -pdfjs-open-file-button = - .title = 開啟檔案 -pdfjs-open-file-button-label = 開啟 -pdfjs-print-button = - .title = 列印 -pdfjs-print-button-label = 列印 -pdfjs-save-button = - .title = 儲存 -pdfjs-save-button-label = 儲存 -# Used in Firefox for Android as a tooltip for the download button (“download” is a verb). -pdfjs-download-button = - .title = 下載 -# Used in Firefox for Android as a label for the download button (“download” is a verb). -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-download-button-label = 下載 -pdfjs-bookmark-button = - .title = 目前頁面(含目前檢視頁面的網址) -pdfjs-bookmark-button-label = 目前頁面 -# Used in Firefox for Android. -pdfjs-open-in-app-button = - .title = 在應用程式中開啟 -# Used in Firefox for Android. -# Length of the translation matters since we are in a mobile context, with limited screen estate. -pdfjs-open-in-app-button-label = 用程式開啟 - -## Secondary toolbar and context menu - -pdfjs-tools-button = - .title = 工具 -pdfjs-tools-button-label = 工具 -pdfjs-first-page-button = - .title = 跳到第一頁 -pdfjs-first-page-button-label = 跳到第一頁 -pdfjs-last-page-button = - .title = 跳到最後一頁 -pdfjs-last-page-button-label = 跳到最後一頁 -pdfjs-page-rotate-cw-button = - .title = 順時針旋轉 -pdfjs-page-rotate-cw-button-label = 順時針旋轉 -pdfjs-page-rotate-ccw-button = - .title = 逆時針旋轉 -pdfjs-page-rotate-ccw-button-label = 逆時針旋轉 -pdfjs-cursor-text-select-tool-button = - .title = 開啟文字選擇工具 -pdfjs-cursor-text-select-tool-button-label = 文字選擇工具 -pdfjs-cursor-hand-tool-button = - .title = 開啟頁面移動工具 -pdfjs-cursor-hand-tool-button-label = 頁面移動工具 -pdfjs-scroll-page-button = - .title = 使用頁面捲動功能 -pdfjs-scroll-page-button-label = 頁面捲動功能 -pdfjs-scroll-vertical-button = - .title = 使用垂直捲動版面 -pdfjs-scroll-vertical-button-label = 垂直捲動 -pdfjs-scroll-horizontal-button = - .title = 使用水平捲動版面 -pdfjs-scroll-horizontal-button-label = 水平捲動 -pdfjs-scroll-wrapped-button = - .title = 使用多頁捲動版面 -pdfjs-scroll-wrapped-button-label = 多頁捲動 -pdfjs-spread-none-button = - .title = 不要進行跨頁顯示 -pdfjs-spread-none-button-label = 不跨頁 -pdfjs-spread-odd-button = - .title = 從奇數頁開始跨頁 -pdfjs-spread-odd-button-label = 奇數跨頁 -pdfjs-spread-even-button = - .title = 從偶數頁開始跨頁 -pdfjs-spread-even-button-label = 偶數跨頁 - -## Document properties dialog - -pdfjs-document-properties-button = - .title = 文件內容… -pdfjs-document-properties-button-label = 文件內容… -pdfjs-document-properties-file-name = 檔案名稱: -pdfjs-document-properties-file-size = 檔案大小: -# Variables: -# $size_kb (Number) - the PDF file size in kilobytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-kb = { $size_kb } KB({ $size_b } 位元組) -# Variables: -# $size_mb (Number) - the PDF file size in megabytes -# $size_b (Number) - the PDF file size in bytes -pdfjs-document-properties-mb = { $size_mb } MB({ $size_b } 位元組) -pdfjs-document-properties-title = 標題: -pdfjs-document-properties-author = 作者: -pdfjs-document-properties-subject = 主旨: -pdfjs-document-properties-keywords = 關鍵字: -pdfjs-document-properties-creation-date = 建立日期: -pdfjs-document-properties-modification-date = 修改日期: -# Variables: -# $date (Date) - the creation/modification date of the PDF file -# $time (Time) - the creation/modification time of the PDF file -pdfjs-document-properties-date-string = { $date } { $time } -pdfjs-document-properties-creator = 建立者: -pdfjs-document-properties-producer = PDF 產生器: -pdfjs-document-properties-version = PDF 版本: -pdfjs-document-properties-page-count = 頁數: -pdfjs-document-properties-page-size = 頁面大小: -pdfjs-document-properties-page-size-unit-inches = in -pdfjs-document-properties-page-size-unit-millimeters = mm -pdfjs-document-properties-page-size-orientation-portrait = 垂直 -pdfjs-document-properties-page-size-orientation-landscape = 水平 -pdfjs-document-properties-page-size-name-a-three = A3 -pdfjs-document-properties-page-size-name-a-four = A4 -pdfjs-document-properties-page-size-name-letter = Letter -pdfjs-document-properties-page-size-name-legal = Legal - -## Variables: -## $width (Number) - the width of the (current) page -## $height (Number) - the height of the (current) page -## $unit (String) - the unit of measurement of the (current) page -## $name (String) - the name of the (current) page -## $orientation (String) - the orientation of the (current) page - -pdfjs-document-properties-page-size-dimension-string = { $width } × { $height } { $unit }({ $orientation }) -pdfjs-document-properties-page-size-dimension-name-string = { $width } × { $height } { $unit }({ $name },{ $orientation }) - -## - -# The linearization status of the document; usually called "Fast Web View" in -# English locales of Adobe software. -pdfjs-document-properties-linearized = 快速 Web 檢視: -pdfjs-document-properties-linearized-yes = 是 -pdfjs-document-properties-linearized-no = 否 -pdfjs-document-properties-close-button = 關閉 - -## Print - -pdfjs-print-progress-message = 正在準備列印文件… -# Variables: -# $progress (Number) - percent value -pdfjs-print-progress-percent = { $progress }% -pdfjs-print-progress-close-button = 取消 -pdfjs-printing-not-supported = 警告: 此瀏覽器未完整支援列印功能。 -pdfjs-printing-not-ready = 警告: 此 PDF 未完成下載以供列印。 - -## Tooltips and alt text for side panel toolbar buttons - -pdfjs-toggle-sidebar-button = - .title = 切換側邊欄 -pdfjs-toggle-sidebar-notification-button = - .title = 切換側邊欄(包含大綱、附件、圖層的文件) -pdfjs-toggle-sidebar-button-label = 切換側邊欄 -pdfjs-document-outline-button = - .title = 顯示文件大綱(雙擊展開/摺疊所有項目) -pdfjs-document-outline-button-label = 文件大綱 -pdfjs-attachments-button = - .title = 顯示附件 -pdfjs-attachments-button-label = 附件 -pdfjs-layers-button = - .title = 顯示圖層(滑鼠雙擊即可將所有圖層重設為預設狀態) -pdfjs-layers-button-label = 圖層 -pdfjs-thumbs-button = - .title = 顯示縮圖 -pdfjs-thumbs-button-label = 縮圖 -pdfjs-current-outline-item-button = - .title = 尋找目前的大綱項目 -pdfjs-current-outline-item-button-label = 目前的大綱項目 -pdfjs-findbar-button = - .title = 在文件中尋找 -pdfjs-findbar-button-label = 尋找 -pdfjs-additional-layers = 其他圖層 - -## Thumbnails panel item (tooltip and alt text for images) - -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-title = - .title = 第 { $page } 頁 -# Variables: -# $page (Number) - the page number -pdfjs-thumb-page-canvas = - .aria-label = 第 { $page } 頁的縮圖 - -## Find panel button title and messages - -pdfjs-find-input = - .title = 尋找 - .placeholder = 在文件中搜尋… -pdfjs-find-previous-button = - .title = 尋找文字前次出現的位置 -pdfjs-find-previous-button-label = 上一個 -pdfjs-find-next-button = - .title = 尋找文字下次出現的位置 -pdfjs-find-next-button-label = 下一個 -pdfjs-find-highlight-checkbox = 強調全部 -pdfjs-find-match-case-checkbox-label = 區分大小寫 -pdfjs-find-match-diacritics-checkbox-label = 符合變音符號 -pdfjs-find-entire-word-checkbox-label = 符合整個字 -pdfjs-find-reached-top = 已搜尋至文件頂端,自底端繼續搜尋 -pdfjs-find-reached-bottom = 已搜尋至文件底端,自頂端繼續搜尋 -# Variables: -# $current (Number) - the index of the currently active find result -# $total (Number) - the total number of matches in the document -pdfjs-find-match-count = 第 { $current } 筆符合,共符合 { $total } 筆 -# Variables: -# $limit (Number) - the maximum number of matches -pdfjs-find-match-count-limit = 符合超過 { $limit } 項 -pdfjs-find-not-found = 找不到指定文字 - -## Predefined zoom values - -pdfjs-page-scale-width = 頁面寬度 -pdfjs-page-scale-fit = 縮放至頁面大小 -pdfjs-page-scale-auto = 自動縮放 -pdfjs-page-scale-actual = 實際大小 -# Variables: -# $scale (Number) - percent value for page scale -pdfjs-page-scale-percent = { $scale }% - -## PDF page - -# Variables: -# $page (Number) - the page number -pdfjs-page-landmark = - .aria-label = 第 { $page } 頁 - -## Loading indicator messages - -pdfjs-loading-error = 載入 PDF 時發生錯誤。 -pdfjs-invalid-file-error = 無效或毀損的 PDF 檔案。 -pdfjs-missing-file-error = 找不到 PDF 檔案。 -pdfjs-unexpected-response-error = 伺服器回應未預期的內容。 -pdfjs-rendering-error = 描繪頁面時發生錯誤。 - -## Annotations - -# Variables: -# $date (Date) - the modification date of the annotation -# $time (Time) - the modification time of the annotation -pdfjs-annotation-date-string = { $date } { $time } -# .alt: This is used as a tooltip. -# Variables: -# $type (String) - an annotation type from a list defined in the PDF spec -# (32000-1:2008 Table 169 – Annotation types). -# Some common types are e.g.: "Check", "Text", "Comment", "Note" -pdfjs-text-annotation-type = - .alt = [{ $type } 註解] - -## Password - -pdfjs-password-label = 請輸入用來開啟此 PDF 檔案的密碼。 -pdfjs-password-invalid = 密碼不正確,請再試一次。 -pdfjs-password-ok-button = 確定 -pdfjs-password-cancel-button = 取消 -pdfjs-web-fonts-disabled = 已停用網路字型 (Web fonts): 無法使用 PDF 內嵌字型。 - -## Editing - -pdfjs-editor-free-text-button = - .title = 文字 -pdfjs-editor-free-text-button-label = 文字 -pdfjs-editor-ink-button = - .title = 繪圖 -pdfjs-editor-ink-button-label = 繪圖 -pdfjs-editor-stamp-button = - .title = 新增或編輯圖片 -pdfjs-editor-stamp-button-label = 新增或編輯圖片 -pdfjs-editor-highlight-button = - .title = 強調 -pdfjs-editor-highlight-button-label = 強調 -pdfjs-highlight-floating-button = - .title = 強調 -pdfjs-highlight-floating-button1 = - .title = 強調 - .aria-label = 強調 -pdfjs-highlight-floating-button-label = 強調 - -## Remove button for the various kind of editor. - -pdfjs-editor-remove-ink-button = - .title = 移除繪圖 -pdfjs-editor-remove-freetext-button = - .title = 移除文字 -pdfjs-editor-remove-stamp-button = - .title = 移除圖片 -pdfjs-editor-remove-highlight-button = - .title = 移除強調範圍 - -## - -# Editor Parameters -pdfjs-editor-free-text-color-input = 色彩 -pdfjs-editor-free-text-size-input = 大小 -pdfjs-editor-ink-color-input = 色彩 -pdfjs-editor-ink-thickness-input = 線條粗細 -pdfjs-editor-ink-opacity-input = 透​明度 -pdfjs-editor-stamp-add-image-button = - .title = 新增圖片 -pdfjs-editor-stamp-add-image-button-label = 新增圖片 -# This refers to the thickness of the line used for free highlighting (not bound to text) -pdfjs-editor-free-highlight-thickness-input = 線條粗細 -pdfjs-editor-free-highlight-thickness-title = - .title = 更改強調文字以外的項目時的線條粗細 -pdfjs-free-text = - .aria-label = 文本編輯器 -pdfjs-free-text-default-content = 開始打字… -pdfjs-ink = - .aria-label = 圖形編輯器 -pdfjs-ink-canvas = - .aria-label = 使用者建立的圖片 - -## Alt-text dialog - -# Alternative text (alt text) helps when people can't see the image. -pdfjs-editor-alt-text-button-label = 替代文字 -pdfjs-editor-alt-text-edit-button-label = 編輯替代文字 -pdfjs-editor-alt-text-dialog-label = 挑選一種 -pdfjs-editor-alt-text-dialog-description = 替代文字可協助盲人,或於圖片無法載入時提供說明。 -pdfjs-editor-alt-text-add-description-label = 新增描述 -pdfjs-editor-alt-text-add-description-description = 用 1-2 句文字描述主題、背景或動作。 -pdfjs-editor-alt-text-mark-decorative-label = 標示為裝飾性內容 -pdfjs-editor-alt-text-mark-decorative-description = 這是裝飾性圖片,例如邊框或浮水印。 -pdfjs-editor-alt-text-cancel-button = 取消 -pdfjs-editor-alt-text-save-button = 儲存 -pdfjs-editor-alt-text-decorative-tooltip = 已標示為裝飾性內容 -# .placeholder: This is a placeholder for the alt text input area -pdfjs-editor-alt-text-textarea = - .placeholder = 例如:「有一位年輕男人坐在桌子前面吃飯」 - -## Editor resizers -## This is used in an aria label to help to understand the role of the resizer. - -pdfjs-editor-resizer-label-top-left = 左上角 — 調整大小 -pdfjs-editor-resizer-label-top-middle = 頂部中間 — 調整大小 -pdfjs-editor-resizer-label-top-right = 右上角 — 調整大小 -pdfjs-editor-resizer-label-middle-right = 中間右方 — 調整大小 -pdfjs-editor-resizer-label-bottom-right = 右下角 — 調整大小 -pdfjs-editor-resizer-label-bottom-middle = 底部中間 — 調整大小 -pdfjs-editor-resizer-label-bottom-left = 左下角 — 調整大小 -pdfjs-editor-resizer-label-middle-left = 中間左方 — 調整大小 - -## Color picker - -# This means "Color used to highlight text" -pdfjs-editor-highlight-colorpicker-label = 強調色彩 -pdfjs-editor-colorpicker-button = - .title = 更改色彩 -pdfjs-editor-colorpicker-dropdown = - .aria-label = 色彩選項 -pdfjs-editor-colorpicker-yellow = - .title = 黃色 -pdfjs-editor-colorpicker-green = - .title = 綠色 -pdfjs-editor-colorpicker-blue = - .title = 藍色 -pdfjs-editor-colorpicker-pink = - .title = 粉紅色 -pdfjs-editor-colorpicker-red = - .title = 紅色 - -## Show all highlights -## This is a toggle button to show/hide all the highlights. - -pdfjs-editor-highlight-show-all-button-label = 顯示全部 -pdfjs-editor-highlight-show-all-button = - .title = 顯示全部 diff --git a/static/pdf.js/locale/zh-TW/viewer.properties b/static/pdf.js/locale/zh-TW/viewer.properties new file mode 100644 index 00000000..495ce107 --- /dev/null +++ b/static/pdf.js/locale/zh-TW/viewer.properties @@ -0,0 +1,174 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=上一頁 +previous_label=上一頁 +next.title=下一頁 +next_label=下一頁 + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=頁: +page_of=/ {{pageCount}} + +zoom_out.title=縮小 +zoom_out_label=縮小 +zoom_in.title=放大 +zoom_in_label=放大 +zoom.title=縮放 +presentation_mode.title=切換至簡報模式 +presentation_mode_label=簡報模式 +open_file.title=開啟檔案 +open_file_label=開啟 +print.title=列印 +print_label=列印 +download.title=下載 +download_label=下載 +bookmark.title=目前檢視的內容(複製或開啟於新視窗) +bookmark_label=目前檢視 + +# Secondary toolbar and context menu +tools.title=工具 +tools_label=工具 +first_page.title=跳到第一頁 +first_page.label=跳到第一頁 +first_page_label=跳到第一頁 +last_page.title=跳到最後一頁 +last_page.label=跳到最後一頁 +last_page_label=跳到最後一頁 +page_rotate_cw.title=順時針旋轉 +page_rotate_cw.label=順時針旋轉 +page_rotate_cw_label=順時針旋轉 +page_rotate_ccw.title=逆時針旋轉 +page_rotate_ccw.label=逆時針旋轉 +page_rotate_ccw_label=逆時針旋轉 + +hand_tool_enable.title=啟用掌型工具 +hand_tool_enable_label=啟用掌型工具 +hand_tool_disable.title=停用掌型工具 +hand_tool_disable_label=停用掌型工具 + +# Document properties dialog box +document_properties.title=文件內容… +document_properties_label=文件內容… +document_properties_file_name=檔案名稱: +document_properties_file_size=檔案大小: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +document_properties_kb={{size_kb}} KB({{size_b}} 位元組) +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_mb={{size_mb}} MB({{size_b}} 位元組) +document_properties_title=標題: +document_properties_author=作者: +document_properties_subject=主旨: +document_properties_keywords=關鍵字: +document_properties_creation_date=建立日期: +document_properties_modification_date=修改日期: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. +document_properties_date_string={{date}}, {{time}} +document_properties_creator=建立者: +document_properties_producer=PDF 產生器: +document_properties_version=PDF 版本: +document_properties_page_count=頁數: +document_properties_close=關閉 + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=切換側邊欄 +toggle_sidebar_label=切換側邊欄 +outline.title=顯示文件大綱 +outline_label=文件大綱 +attachments.title=顯示附件 +attachments_label=附件 +thumbs.title=顯示縮圖 +thumbs_label=縮圖 +findbar.title=在文件中尋找 +findbar_label=尋找 + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=頁 {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=頁 {{page}} 的縮圖 + +# Find panel button title and messages +find_label=尋找: +find_previous.title=尋找文字前次出現的位置 +find_previous_label=上一個 +find_next.title=尋找文字下次出現的位置 +find_next_label=下一個 +find_highlight=全部強調標示 +find_match_case_label=區分大小寫 +find_reached_top=已搜尋至文件頂端,自底端繼續搜尋 +find_reached_bottom=已搜尋至文件底端,自頂端繼續搜尋 +find_not_found=找不到指定文字 + +# Error panel labels +error_more_info=更多資訊 +error_less_info=更少資訊 +error_close=關閉 +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=訊息: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=堆疊: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=檔案: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=行: {{line}} +rendering_error=描繪頁面時發生錯誤。 + +# Predefined zoom values +page_scale_width=頁面寬度 +page_scale_fit=縮放至頁面大小 +page_scale_auto=自動縮放 +page_scale_actual=實際大小 +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. +page_scale_percent={{scale}}% + +# Loading indicator messages +loading_error_indicator=錯誤 +loading_error=載入 PDF 時發生錯誤。 +invalid_file_error=無效或毀損的 PDF 檔案。 +missing_file_error=找不到 PDF 檔案。 +unexpected_response_error=伺服器回應未預期的內容。 + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[{{type}} 註解] +password_label=請輸入用來開啟此 PDF 檔案的密碼。 +password_invalid=密碼不正確,請再試一次。 +password_ok=確定 +password_cancel=取消 + +printing_not_supported=警告: 此瀏覽器未完整支援列印功能。 +printing_not_ready=警告: 此 PDF 未完成下載以供列印。 +web_fonts_disabled=已停用網路字型 (Web fonts): 無法使用 PDF 內嵌字型。 +document_colors_not_allowed=不允許 PDF 文件使用自訂色彩: 已停用瀏覽器的「優先使用網頁指定的色彩」設定。 + diff --git a/static/pdf.js/locale/zu/viewer.properties b/static/pdf.js/locale/zu/viewer.properties new file mode 100644 index 00000000..2ccf70c4 --- /dev/null +++ b/static/pdf.js/locale/zu/viewer.properties @@ -0,0 +1,132 @@ +# Copyright 2012 Mozilla Foundation +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Main toolbar buttons (tooltips and alt text for images) +previous.title=Ikhasi eledlule +previous_label=Okudlule +next.title=Ikhasi elilandelayo +next_label=Okulandelayo + +# LOCALIZATION NOTE (page_label, page_of): +# These strings are concatenated to form the "Page: X of Y" string. +# Do not translate "{{pageCount}}", it will be substituted with a number +# representing the total number of pages. +page_label=Ikhasi: +page_of=kwe-{{pageCount}} + +zoom_out.title=Hlehlisela emuva +zoom_out_label=Hlehlisela emuva +zoom_in.title=Sondeza eduze +zoom_in_label=Sondeza eduze +zoom.title=Lwiza +presentation_mode.title=Guqulela kwindlela yesethulo +presentation_mode_label=Indlelo yesethulo +open_file.title=Vula ifayela +open_file_label=Vula +print.title=Phrinta +print_label=Phrinta +download.title=Landa +download_label=Landa +bookmark.title=Ukubuka kwamanje (kopisha noma vula kwifasitela elisha) +bookmark_label=Ukubuka kwamanje + +# Secondary toolbar and context menu + + +# Document properties dialog box +document_properties_file_name=Igama lefayela: +# LOCALIZATION NOTE (document_properties_kb): "{{size_kb}}" and "{{size_b}}" +# will be replaced by the PDF file size in kilobytes, respectively in bytes. +# LOCALIZATION NOTE (document_properties_mb): "{{size_mb}}" and "{{size_b}}" +# will be replaced by the PDF file size in megabytes, respectively in bytes. +document_properties_title=Isihloko: +# LOCALIZATION NOTE (document_properties_date_string): "{{date}}" and "{{time}}" +# will be replaced by the creation/modification date, and time, of the PDF file. + +# Tooltips and alt text for side panel toolbar buttons +# (the _label strings are alt text for the buttons, the .title strings are +# tooltips) +toggle_sidebar.title=I-toggle yebha yaseceleni +toggle_sidebar_label=i-toggle yebha yaseceleni +outline.title=Bonisa umugqa waseceleni wedokhumenti +outline_label=Umugqa waseceleni wedokhumenti +thumbs.title=Bonisa izithombe ezincane +thumbs_label=Izithonjana +findbar.title=Thola kwidokhumenti +findbar_label=Thola + +# Thumbnails panel item (tooltip and alt text for images) +# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page +# number. +thumb_page_title=Ikhasi {{page}} +# LOCALIZATION NOTE (thumb_page_canvas): "{{page}}" will be replaced by the page +# number. +thumb_page_canvas=Isithonjana sekhasi {{page}} + +# Find panel button title and messages +find_label=Thola +find_previous.title=Thola indawo eyandulelayo okuvela kuyo lomshwana +find_previous_label=Okudlulile +find_next.title=Thola enye indawo okuvela kuyo lomshwana +find_next_label=Okulandelayo +find_highlight=Gqamisa konke +find_match_case_label=Fanisa ikheyisi +find_reached_top=Finyelele phezulu kwidokhumenti, qhubeka kusukaphansi +find_reached_bottom=Ifinyelele ekupheleni kwedokhumenti, qhubeka kusukaphezulu +find_not_found=Umshwana awutholakali + +# Error panel labels +error_more_info=Ukwaziswa Okwengeziwe +error_less_info=Ukwazi okuncane +# LOCALIZATION NOTE (error_version_info): "{{version}}" and "{{build}}" will be +# replaced by the PDF.JS version and build ID. +error_version_info=PDF.js v{{version}} (build: {{build}}) +# LOCALIZATION NOTE (error_message): "{{message}}" will be replaced by an +# english string describing the error. +error_message=Umlayezo: {{message}} +# LOCALIZATION NOTE (error_stack): "{{stack}}" will be replaced with a stack +# trace. +error_stack=Isitaki: {{stack}} +# LOCALIZATION NOTE (error_file): "{{file}}" will be replaced with a filename +error_file=Ifayela: {{file}} +# LOCALIZATION NOTE (error_line): "{{line}}" will be replaced with a line number +error_line=Umugqa: {{line}} +rendering_error=Iphutha lenzekile uma kunikwa ikhasi. + +# Predefined zoom values +page_scale_width=Ububanzi bekhasi +page_scale_fit=Ukulingana kwekhasi +page_scale_auto=Ukulwiza okuzenzekalelayo +page_scale_actual=Usayizi Wangempela +# LOCALIZATION NOTE (page_scale_percent): "{{scale}}" will be replaced by a +# numerical scale value. + +# Loading indicator messages +loading_error_indicator=Iphutha +loading_error=Kwenzeke iphutha uma kulayishwa i-PDF. +invalid_file_error=Ifayela le-PDF elingavumelekile noma elonakele. +missing_file_error=Ifayela le-PDF elilahlekile. + +# LOCALIZATION NOTE (text_annotation_type.alt): This is used as a tooltip. +# "{{type}}" will be replaced with an annotation type from a list defined in +# the PDF spec (32000-1:2008 Table 169 – Annotation types). +# Some common types are e.g.: "Check", "Text", "Comment", "Note" +text_annotation_type.alt=[Amazwibela e-{{type}}] +password_ok=Kulungile +password_cancel=Khansela + +printing_not_supported=Isixwayiso: Ukuphrinta akuxhasiwe yilesisiphequluli ngokugcwele. +printing_not_ready=Isixwayiso: I-PDF ayikalayishwa ngokuphelele yiPhrinta. +web_fonts_disabled=Amafonti e-webhu akutshaziwe: ayikwazi ukusebenzisa amafonti abekiwe e-PDF.\u0020 +document_colors_not_allowed=Amadokhumenti we-PDF awavumelekile ukusebenzisa imibalo yayo: 'Vumela amakhasi ukukhetha imibala yayo' ayisebenzi kusiphequluli. diff --git a/static/pdf.js/minify.py b/static/pdf.js/minify.py new file mode 100644 index 00000000..5e815af5 --- /dev/null +++ b/static/pdf.js/minify.py @@ -0,0 +1,3 @@ +import ox +import sys +with open(sys.argv[2], 'w') as f: f.write(ox.js.minify(open(sys.argv[1]).read())) diff --git a/static/pdf.js/pandora.css b/static/pdf.js/pandora.css deleted file mode 100644 index d146cdc3..00000000 --- a/static/pdf.js/pandora.css +++ /dev/null @@ -1,48 +0,0 @@ - -.toolbarButton.cropFile::before, - .secondaryToolbarButton.cropFile::before { - mask-image: url(custom/toolbarButton-crop.png); -} -.toolbarButton.embedPage::before, - .secondaryToolbarButton.embedPage::before { - mask-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNTYiIGhlaWdodD0iMjU2IiB2aWV3Qm94PSIwIDAgMjU2IDI1NiI+PGxpbmUgeDE9Ijg4IiB5MT0iNTYiIHgyPSIyNCIgeTI9IjEyOCIgc3Ryb2tlPSIjMDAwMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS13aWR0aD0iNDgiLz48bGluZSB4MT0iMjQiIHkxPSIxMjgiIHgyPSI4OCIgeTI9IjIwMCIgc3Ryb2tlPSIjMDAwMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS13aWR0aD0iNDgiLz48bGluZSB4MT0iMTY4IiB5MT0iNTYiIHgyPSIyMzIiIHkyPSIxMjgiIHN0cm9rZT0iIzAwMDAwMCIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2Utd2lkdGg9IjQ4Ii8+PGxpbmUgeDE9IjIzMiIgeTE9IjEyOCIgeDI9IjE2OCIgeTI9IjIwMCIgc3Ryb2tlPSIjMDAwMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS13aWR0aD0iNDgiLz48L3N2Zz48IS0teyJjb2xvciI6ImRlZmF1bHQiLCJuYW1lIjoic3ltYm9sRW1iZWQiLCJ0aGVtZSI6Im94bWVkaXVtIn0tLT4=); -} -@media screen and (min-resolution: 2dppx) { - .toolbarButton.cropFile::before, - .secondaryToolbarButton.cropFile::before { - mask-image: url(custom/toolbarButton-crop@2x.png); - } - .toolbarButton.embedPage::before, - .secondaryToolbarButton.embedPage::before { - mask-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNTYiIGhlaWdodD0iMjU2IiB2aWV3Qm94PSIwIDAgMjU2IDI1NiI+PGxpbmUgeDE9Ijg4IiB5MT0iNTYiIHgyPSIyNCIgeTI9IjEyOCIgc3Ryb2tlPSIjMDAwMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS13aWR0aD0iNDgiLz48bGluZSB4MT0iMjQiIHkxPSIxMjgiIHgyPSI4OCIgeTI9IjIwMCIgc3Ryb2tlPSIjMDAwMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS13aWR0aD0iNDgiLz48bGluZSB4MT0iMTY4IiB5MT0iNTYiIHgyPSIyMzIiIHkyPSIxMjgiIHN0cm9rZT0iIzAwMDAwMCIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2Utd2lkdGg9IjQ4Ii8+PGxpbmUgeDE9IjIzMiIgeTE9IjEyOCIgeDI9IjE2OCIgeTI9IjIwMCIgc3Ryb2tlPSIjMDAwMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS13aWR0aD0iNDgiLz48L3N2Zz48IS0teyJjb2xvciI6ImRlZmF1bHQiLCJuYW1lIjoic3ltYm9sRW1iZWQiLCJ0aGVtZSI6Im94bWVkaXVtIn0tLT4=); - } -} - -.verticalToolbarSeparator.hiddenMediumView, -#print, -#secondaryPrint, -#openFile, -#secondaryOpenFile, -#editorModeButtons { - display: none !important; -} - -.page .crop-overlay { - position: absolute; - top: 0; - bottom: 0; - left: 0; - right: 0; - //background: rgba(0,0,0,0.5); - cursor: crosshair; - z-index: 100; -} -.page .crop-overlay.inactive { - pointer-events: none; - cursor: default; -} - -.page .crop-overlay canvas { - width: 100%; - height: 100%; -} diff --git a/static/pdf.js/pandora.js b/static/pdf.js/pandora.js deleted file mode 100644 index 27f73ccb..00000000 --- a/static/pdf.js/pandora.js +++ /dev/null @@ -1,261 +0,0 @@ -var cropInactive = true -var info = {} -var cache = {} -var documentId -var baseUrl = document.location.protocol + '//' + document.location.host - - - -var div = document.createElement("div") -div.innerHTML = ` - -` -var cropFile = div.querySelector("#cropFile") - -document.querySelector('#toolbarViewerRight').insertBefore(cropFile, document.querySelector('#toolbarViewerRight').firstChild) - -div.innerHTML = ` - -` -var embedPage = div.querySelector("#embedPage") -document.querySelector('#toolbarViewerRight').insertBefore(embedPage, document.querySelector('#toolbarViewerRight').firstChild) -embedPage.addEventListener("click", event => { - Ox.$parent.postMessage('embed', { - page: PDFViewerApplication.page - }); -}) - -// secondary menu -div.innerHTML = ` - -` -var secondaryCropFile = div.querySelector("#secondaryCropFile") -document.querySelector('#secondaryToolbarButtonContainer').insertBefore( - secondaryCropFile, - document.querySelector('#secondaryToolbarButtonContainer').firstChild -) - -div.innerHTML = ` - -` -var secondaryEmbedPage = div.querySelector("#secondaryEmbedPage") -document.querySelector('#secondaryToolbarButtonContainer').insertBefore( - secondaryEmbedPage, - document.querySelector('#secondaryToolbarButtonContainer').firstChild -) -secondaryEmbedPage.addEventListener("click", event => { - Ox.$parent.postMessage('embed', { - page: PDFViewerApplication.page - }); -}) - - -async function archiveAPI(action, data) { - var url = baseUrl + '/api/' - var key = JSON.stringify([action, data]) - if (!cache[key]) { - var response = await fetch(url, { - method: 'POST', - headers: {'Content-Type': 'application/json'}, - body: JSON.stringify({ - action: action, - data: data - }) - }) - cache[key] = await response.json() - } - return cache[key] -} - -function getCookie(name) { - var cookieValue = null; - if (document.cookie && document.cookie !== '') { - var cookies = document.cookie.split(';'); - for (var i = 0; i < cookies.length; i++) { - var cookie = cookies[i].trim(); - // Does this cookie string begin with the name we want? - if (cookie.substring(0, name.length + 1) === (name + '=')) { - cookieValue = decodeURIComponent(cookie.substring(name.length + 1)); - break; - } - } - } - return cookieValue; -} - -function renderCropOverlay(root, documentId, page) { - var canvas = document.createElement('canvas') - root.appendChild(canvas) - canvas.width = canvas.clientWidth - canvas.height = canvas.clientHeight - var ctx = canvas.getContext('2d'); - var viewerContainer = document.querySelector('#viewerContainer') - var bounds = root.getBoundingClientRect(); - var base = 2048 - var scale = Math.max(bounds.height, bounds.width) / base - var last_mousex = last_mousey = 0; - var mousex = mousey = 0; - var mousedown = false; - var p = { - top: 0, - left: 0, - bottom: 0, - right: 0 - } - - canvas.addEventListener('mousedown', function(e) { - let bounds = root.getBoundingClientRect(); - last_mousex = e.clientX - bounds.left; - last_mousey = e.clientY - bounds.top; - p.top = parseInt(last_mousey / scale) - p.left = parseInt(last_mousex / scale) - mousedown = true; - }); - - document.addEventListener('mouseup', function(e) { - if (mousedown) { - mousedown = false; - p.bottom = parseInt(mousey / scale) - p.right = parseInt(mousex / scale) - - if (p.top > p.bottom) { - var t = p.top - p.top = p.bottom - p.bottom = t - } - if (p.left > p.right) { - var t = p.left - p.left = p.right - p.right = t - } - var url = `${baseUrl}/documents/${documentId}/2048p${page},${p.left},${p.top},${p.right},${p.bottom}.jpg` - info.url = `${baseUrl}/document/${documentId}/${page}` - info.page = page - if (p.left != p.right && p.top != p.bottom) { - var context = formatOutput(info, url) - copyToClipboard(context) - addToRecent({ - document: documentId, - page: parseInt(page), - title: info.title, - type: 'fragment', - link: `${baseUrl}/documents/${documentId}/${page}`, - src: url - }) - } - } - }); - - canvas.addEventListener('mousemove', function(e) { - let bounds = root.getBoundingClientRect(); - mousex = e.clientX - bounds.left; - mousey = e.clientY - bounds.top; - - if(mousedown) { - ctx.clearRect(0, 0, canvas.clientWidth, canvas.clientHeight) - ctx.beginPath() - var width = mousex - last_mousex - var height = mousey - last_mousey - ctx.rect(last_mousex, last_mousey, width, height) - ctx.strokeStyle = 'black'; - ctx.lineWidth = 2; - ctx.stroke(); - } - }); -} - - -const copyToClipboard = str => { - const el = document.createElement('textarea'); - el.value = str; - el.setAttribute('readonly', ''); - el.style.position = 'absolute'; - el.style.left = '-9999px'; - document.body.appendChild(el); - el.select(); - document.execCommand('copy'); - document.body.removeChild(el); -}; - - -function getInfo(documentId) { - archiveAPI('getDocument', {id: documentId, keys: ['title', 'pages']}).then(result => { - info.title = result.data.title - info.pages = result.data.pages - info.id = documentId - }) -} - -function formatOutput(info, url) { - var output = `${url}\n${info.title}, Page ${info.page}\n${info.url}` - return output -} - -const addToRecent = obj => { - var recent = [] - if (localStorage['recentClippings']) { - recent = JSON.parse(localStorage['recentClippings']) - } - recent.unshift(obj) - localStorage['recentClippings'] = JSON.stringify(recent) -} - -function initOverlay() { - document.querySelectorAll('#cropFile,.secondaryToolbarButton.cropFile').forEach(btn => { - btn.addEventListener('click', event=> { - if (cropInactive) { - event.target.style.background = 'red' - cropInactive = false - document.querySelectorAll('.crop-overlay.inactive').forEach(element => { - element.classList.remove('inactive') - }) - } else { - event.target.style.background = '' - cropInactive = true - document.querySelectorAll('.crop-overlay').forEach(element => { - element.classList.add('inactive') - }) - } - }) - }) - var first = true - PDFViewerApplication.initializedPromise.then(function() { - PDFViewerApplication.pdfViewer.eventBus.on("pagesinit", function(event) { - documentId = PDFViewerApplication.url.split('/').splice(-2).shift() - getInfo(documentId) - document.querySelector('#viewerContainer').addEventListener('scroll', event => { - if (window.parent && window.parent.postMessage) { - if (first) { - first = false - } else { - window.parent.postMessage({event: 'scrolled', top: event.target.scrollTop}) - } - } - }) - }) - PDFViewerApplication.pdfViewer.eventBus.on("pagerender", function(event) { - var page = event.pageNumber.toString() - var div = event.source.div - var overlay = document.createElement('div') - overlay.classList.add('crop-overlay') - overlay.id = 'overlay' + page - if (cropInactive) { - overlay.classList.add('inactive') - } - div.appendChild(overlay) - renderCropOverlay(overlay, documentId, page) - }) - }) -} - -document.addEventListener('DOMContentLoaded', function() { - window.PDFViewerApplication ? initOverlay() : document.addEventListener("webviewerloaded", initOverlay) -}) diff --git a/static/pdf.js/pdf.js b/static/pdf.js/pdf.js new file mode 100644 index 00000000..6c9aa662 --- /dev/null +++ b/static/pdf.js/pdf.js @@ -0,0 +1,10707 @@ +/* Copyright 2012 Mozilla Foundation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/* jshint globalstrict: false */ +/* umdutils ignore */ + +(function (root, factory) { + 'use strict'; + if (typeof define === 'function' && define.amd) { +define('pdfjs-dist/build/pdf', ['exports'], factory); + } else if (typeof exports !== 'undefined') { + factory(exports); + } else { +factory((root.pdfjsDistBuildPdf = {})); + } +}(this, function (exports) { + // Use strict in our context only - users might not want it + 'use strict'; + +var pdfjsVersion = '1.4.193'; +var pdfjsBuild = '9d1c5b9'; + + var pdfjsFilePath = + typeof document !== 'undefined' && document.currentScript ? + document.currentScript.src : null; + + var pdfjsLibs = {}; + + (function pdfjsWrapper() { + + + +(function (root, factory) { + { + factory((root.pdfjsSharedUtil = {})); + } +}(this, function (exports) { + +var globalScope = (typeof window !== 'undefined') ? window : + (typeof global !== 'undefined') ? global : + (typeof self !== 'undefined') ? self : this; + +var FONT_IDENTITY_MATRIX = [0.001, 0, 0, 0.001, 0, 0]; + +var TextRenderingMode = { + FILL: 0, + STROKE: 1, + FILL_STROKE: 2, + INVISIBLE: 3, + FILL_ADD_TO_PATH: 4, + STROKE_ADD_TO_PATH: 5, + FILL_STROKE_ADD_TO_PATH: 6, + ADD_TO_PATH: 7, + FILL_STROKE_MASK: 3, + ADD_TO_PATH_FLAG: 4 +}; + +var ImageKind = { + GRAYSCALE_1BPP: 1, + RGB_24BPP: 2, + RGBA_32BPP: 3 +}; + +var AnnotationType = { + TEXT: 1, + LINK: 2, + FREETEXT: 3, + LINE: 4, + SQUARE: 5, + CIRCLE: 6, + POLYGON: 7, + POLYLINE: 8, + HIGHLIGHT: 9, + UNDERLINE: 10, + SQUIGGLY: 11, + STRIKEOUT: 12, + STAMP: 13, + CARET: 14, + INK: 15, + POPUP: 16, + FILEATTACHMENT: 17, + SOUND: 18, + MOVIE: 19, + WIDGET: 20, + SCREEN: 21, + PRINTERMARK: 22, + TRAPNET: 23, + WATERMARK: 24, + THREED: 25, + REDACT: 26 +}; + +var AnnotationFlag = { + INVISIBLE: 0x01, + HIDDEN: 0x02, + PRINT: 0x04, + NOZOOM: 0x08, + NOROTATE: 0x10, + NOVIEW: 0x20, + READONLY: 0x40, + LOCKED: 0x80, + TOGGLENOVIEW: 0x100, + LOCKEDCONTENTS: 0x200 +}; + +var AnnotationBorderStyleType = { + SOLID: 1, + DASHED: 2, + BEVELED: 3, + INSET: 4, + UNDERLINE: 5 +}; + +var StreamType = { + UNKNOWN: 0, + FLATE: 1, + LZW: 2, + DCT: 3, + JPX: 4, + JBIG: 5, + A85: 6, + AHX: 7, + CCF: 8, + RL: 9 +}; + +var FontType = { + UNKNOWN: 0, + TYPE1: 1, + TYPE1C: 2, + CIDFONTTYPE0: 3, + CIDFONTTYPE0C: 4, + TRUETYPE: 5, + CIDFONTTYPE2: 6, + TYPE3: 7, + OPENTYPE: 8, + TYPE0: 9, + MMTYPE1: 10 +}; + +var VERBOSITY_LEVELS = { + errors: 0, + warnings: 1, + infos: 5 +}; + +// All the possible operations for an operator list. +var OPS = { + // Intentionally start from 1 so it is easy to spot bad operators that will be + // 0's. + dependency: 1, + setLineWidth: 2, + setLineCap: 3, + setLineJoin: 4, + setMiterLimit: 5, + setDash: 6, + setRenderingIntent: 7, + setFlatness: 8, + setGState: 9, + save: 10, + restore: 11, + transform: 12, + moveTo: 13, + lineTo: 14, + curveTo: 15, + curveTo2: 16, + curveTo3: 17, + closePath: 18, + rectangle: 19, + stroke: 20, + closeStroke: 21, + fill: 22, + eoFill: 23, + fillStroke: 24, + eoFillStroke: 25, + closeFillStroke: 26, + closeEOFillStroke: 27, + endPath: 28, + clip: 29, + eoClip: 30, + beginText: 31, + endText: 32, + setCharSpacing: 33, + setWordSpacing: 34, + setHScale: 35, + setLeading: 36, + setFont: 37, + setTextRenderingMode: 38, + setTextRise: 39, + moveText: 40, + setLeadingMoveText: 41, + setTextMatrix: 42, + nextLine: 43, + showText: 44, + showSpacedText: 45, + nextLineShowText: 46, + nextLineSetSpacingShowText: 47, + setCharWidth: 48, + setCharWidthAndBounds: 49, + setStrokeColorSpace: 50, + setFillColorSpace: 51, + setStrokeColor: 52, + setStrokeColorN: 53, + setFillColor: 54, + setFillColorN: 55, + setStrokeGray: 56, + setFillGray: 57, + setStrokeRGBColor: 58, + setFillRGBColor: 59, + setStrokeCMYKColor: 60, + setFillCMYKColor: 61, + shadingFill: 62, + beginInlineImage: 63, + beginImageData: 64, + endInlineImage: 65, + paintXObject: 66, + markPoint: 67, + markPointProps: 68, + beginMarkedContent: 69, + beginMarkedContentProps: 70, + endMarkedContent: 71, + beginCompat: 72, + endCompat: 73, + paintFormXObjectBegin: 74, + paintFormXObjectEnd: 75, + beginGroup: 76, + endGroup: 77, + beginAnnotations: 78, + endAnnotations: 79, + beginAnnotation: 80, + endAnnotation: 81, + paintJpegXObject: 82, + paintImageMaskXObject: 83, + paintImageMaskXObjectGroup: 84, + paintImageXObject: 85, + paintInlineImageXObject: 86, + paintInlineImageXObjectGroup: 87, + paintImageXObjectRepeat: 88, + paintImageMaskXObjectRepeat: 89, + paintSolidColorImageMask: 90, + constructPath: 91 +}; + +var verbosity = VERBOSITY_LEVELS.warnings; + +function setVerbosityLevel(level) { + verbosity = level; +} + +function getVerbosityLevel() { + return verbosity; +} + +// A notice for devs. These are good for things that are helpful to devs, such +// as warning that Workers were disabled, which is important to devs but not +// end users. +function info(msg) { + if (verbosity >= VERBOSITY_LEVELS.infos) { + console.log('Info: ' + msg); + } +} + +// Non-fatal warnings. +function warn(msg) { + if (verbosity >= VERBOSITY_LEVELS.warnings) { + console.log('Warning: ' + msg); + } +} + +// Deprecated API function -- display regardless of the PDFJS.verbosity setting. +function deprecated(details) { + console.log('Deprecated API usage: ' + details); +} + +// Fatal errors that should trigger the fallback UI and halt execution by +// throwing an exception. +function error(msg) { + if (verbosity >= VERBOSITY_LEVELS.errors) { + console.log('Error: ' + msg); + console.log(backtrace()); + } + throw new Error(msg); +} + +function backtrace() { + try { + throw new Error(); + } catch (e) { + return e.stack ? e.stack.split('\n').slice(2).join('\n') : ''; + } +} + +function assert(cond, msg) { + if (!cond) { + error(msg); + } +} + +var UNSUPPORTED_FEATURES = { + unknown: 'unknown', + forms: 'forms', + javaScript: 'javaScript', + smask: 'smask', + shadingPattern: 'shadingPattern', + font: 'font' +}; + +// Combines two URLs. The baseUrl shall be absolute URL. If the url is an +// absolute URL, it will be returned as is. +function combineUrl(baseUrl, url) { + if (!url) { + return baseUrl; + } + return new URL(url, baseUrl).href; +} + +// Checks if URLs have the same origin. For non-HTTP based URLs, returns false. +function isSameOrigin(baseUrl, otherUrl) { + try { + var base = new URL(baseUrl); + if (!base.origin || base.origin === 'null') { + return false; // non-HTTP url + } + } catch (e) { + return false; + } + + var other = new URL(otherUrl, base); + return base.origin === other.origin; +} + +// Validates if URL is safe and allowed, e.g. to avoid XSS. +function isValidUrl(url, allowRelative) { + if (!url) { + return false; + } + // RFC 3986 (http://tools.ietf.org/html/rfc3986#section-3.1) + // scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." ) + var protocol = /^[a-z][a-z0-9+\-.]*(?=:)/i.exec(url); + if (!protocol) { + return allowRelative; + } + protocol = protocol[0].toLowerCase(); + switch (protocol) { + case 'http': + case 'https': + case 'ftp': + case 'mailto': + case 'tel': + return true; + default: + return false; + } +} + +function shadow(obj, prop, value) { + Object.defineProperty(obj, prop, { value: value, + enumerable: true, + configurable: true, + writable: false }); + return value; +} + +function getLookupTableFactory(initializer) { + var lookup; + return function () { + if (initializer) { + lookup = Object.create(null); + initializer(lookup); + initializer = null; + } + return lookup; + }; +} + +var PasswordResponses = { + NEED_PASSWORD: 1, + INCORRECT_PASSWORD: 2 +}; + +var PasswordException = (function PasswordExceptionClosure() { + function PasswordException(msg, code) { + this.name = 'PasswordException'; + this.message = msg; + this.code = code; + } + + PasswordException.prototype = new Error(); + PasswordException.constructor = PasswordException; + + return PasswordException; +})(); + +var UnknownErrorException = (function UnknownErrorExceptionClosure() { + function UnknownErrorException(msg, details) { + this.name = 'UnknownErrorException'; + this.message = msg; + this.details = details; + } + + UnknownErrorException.prototype = new Error(); + UnknownErrorException.constructor = UnknownErrorException; + + return UnknownErrorException; +})(); + +var InvalidPDFException = (function InvalidPDFExceptionClosure() { + function InvalidPDFException(msg) { + this.name = 'InvalidPDFException'; + this.message = msg; + } + + InvalidPDFException.prototype = new Error(); + InvalidPDFException.constructor = InvalidPDFException; + + return InvalidPDFException; +})(); + +var MissingPDFException = (function MissingPDFExceptionClosure() { + function MissingPDFException(msg) { + this.name = 'MissingPDFException'; + this.message = msg; + } + + MissingPDFException.prototype = new Error(); + MissingPDFException.constructor = MissingPDFException; + + return MissingPDFException; +})(); + +var UnexpectedResponseException = + (function UnexpectedResponseExceptionClosure() { + function UnexpectedResponseException(msg, status) { + this.name = 'UnexpectedResponseException'; + this.message = msg; + this.status = status; + } + + UnexpectedResponseException.prototype = new Error(); + UnexpectedResponseException.constructor = UnexpectedResponseException; + + return UnexpectedResponseException; +})(); + +var NotImplementedException = (function NotImplementedExceptionClosure() { + function NotImplementedException(msg) { + this.message = msg; + } + + NotImplementedException.prototype = new Error(); + NotImplementedException.prototype.name = 'NotImplementedException'; + NotImplementedException.constructor = NotImplementedException; + + return NotImplementedException; +})(); + +var MissingDataException = (function MissingDataExceptionClosure() { + function MissingDataException(begin, end) { + this.begin = begin; + this.end = end; + this.message = 'Missing data [' + begin + ', ' + end + ')'; + } + + MissingDataException.prototype = new Error(); + MissingDataException.prototype.name = 'MissingDataException'; + MissingDataException.constructor = MissingDataException; + + return MissingDataException; +})(); + +var XRefParseException = (function XRefParseExceptionClosure() { + function XRefParseException(msg) { + this.message = msg; + } + + XRefParseException.prototype = new Error(); + XRefParseException.prototype.name = 'XRefParseException'; + XRefParseException.constructor = XRefParseException; + + return XRefParseException; +})(); + +var NullCharactersRegExp = /\x00/g; + +function removeNullCharacters(str) { + if (typeof str !== 'string') { + warn('The argument for removeNullCharacters must be a string.'); + return str; + } + return str.replace(NullCharactersRegExp, ''); +} + +function bytesToString(bytes) { + assert(bytes !== null && typeof bytes === 'object' && + bytes.length !== undefined, 'Invalid argument for bytesToString'); + var length = bytes.length; + var MAX_ARGUMENT_COUNT = 8192; + if (length < MAX_ARGUMENT_COUNT) { + return String.fromCharCode.apply(null, bytes); + } + var strBuf = []; + for (var i = 0; i < length; i += MAX_ARGUMENT_COUNT) { + var chunkEnd = Math.min(i + MAX_ARGUMENT_COUNT, length); + var chunk = bytes.subarray(i, chunkEnd); + strBuf.push(String.fromCharCode.apply(null, chunk)); + } + return strBuf.join(''); +} + +function stringToBytes(str) { + assert(typeof str === 'string', 'Invalid argument for stringToBytes'); + var length = str.length; + var bytes = new Uint8Array(length); + for (var i = 0; i < length; ++i) { + bytes[i] = str.charCodeAt(i) & 0xFF; + } + return bytes; +} + +/** + * Gets length of the array (Array, Uint8Array, or string) in bytes. + * @param {Array|Uint8Array|string} arr + * @returns {number} + */ +function arrayByteLength(arr) { + if (arr.length !== undefined) { + return arr.length; + } + assert(arr.byteLength !== undefined); + return arr.byteLength; +} + +/** + * Combines array items (arrays) into single Uint8Array object. + * @param {Array} arr - the array of the arrays (Array, Uint8Array, or string). + * @returns {Uint8Array} + */ +function arraysToBytes(arr) { + // Shortcut: if first and only item is Uint8Array, return it. + if (arr.length === 1 && (arr[0] instanceof Uint8Array)) { + return arr[0]; + } + var resultLength = 0; + var i, ii = arr.length; + var item, itemLength ; + for (i = 0; i < ii; i++) { + item = arr[i]; + itemLength = arrayByteLength(item); + resultLength += itemLength; + } + var pos = 0; + var data = new Uint8Array(resultLength); + for (i = 0; i < ii; i++) { + item = arr[i]; + if (!(item instanceof Uint8Array)) { + if (typeof item === 'string') { + item = stringToBytes(item); + } else { + item = new Uint8Array(item); + } + } + itemLength = item.byteLength; + data.set(item, pos); + pos += itemLength; + } + return data; +} + +function string32(value) { + return String.fromCharCode((value >> 24) & 0xff, (value >> 16) & 0xff, + (value >> 8) & 0xff, value & 0xff); +} + +function log2(x) { + var n = 1, i = 0; + while (x > n) { + n <<= 1; + i++; + } + return i; +} + +function readInt8(data, start) { + return (data[start] << 24) >> 24; +} + +function readUint16(data, offset) { + return (data[offset] << 8) | data[offset + 1]; +} + +function readUint32(data, offset) { + return ((data[offset] << 24) | (data[offset + 1] << 16) | + (data[offset + 2] << 8) | data[offset + 3]) >>> 0; +} + +// Lazy test the endianness of the platform +// NOTE: This will be 'true' for simulated TypedArrays +function isLittleEndian() { + var buffer8 = new Uint8Array(2); + buffer8[0] = 1; + var buffer16 = new Uint16Array(buffer8.buffer); + return (buffer16[0] === 1); +} + +var Uint32ArrayView = (function Uint32ArrayViewClosure() { + + function Uint32ArrayView(buffer, length) { + this.buffer = buffer; + this.byteLength = buffer.length; + this.length = length === undefined ? (this.byteLength >> 2) : length; + ensureUint32ArrayViewProps(this.length); + } + Uint32ArrayView.prototype = Object.create(null); + + var uint32ArrayViewSetters = 0; + function createUint32ArrayProp(index) { + return { + get: function () { + var buffer = this.buffer, offset = index << 2; + return (buffer[offset] | (buffer[offset + 1] << 8) | + (buffer[offset + 2] << 16) | (buffer[offset + 3] << 24)) >>> 0; + }, + set: function (value) { + var buffer = this.buffer, offset = index << 2; + buffer[offset] = value & 255; + buffer[offset + 1] = (value >> 8) & 255; + buffer[offset + 2] = (value >> 16) & 255; + buffer[offset + 3] = (value >>> 24) & 255; + } + }; + } + + function ensureUint32ArrayViewProps(length) { + while (uint32ArrayViewSetters < length) { + Object.defineProperty(Uint32ArrayView.prototype, + uint32ArrayViewSetters, + createUint32ArrayProp(uint32ArrayViewSetters)); + uint32ArrayViewSetters++; + } + } + + return Uint32ArrayView; +})(); + +exports.Uint32ArrayView = Uint32ArrayView; + +var IDENTITY_MATRIX = [1, 0, 0, 1, 0, 0]; + +var Util = (function UtilClosure() { + function Util() {} + + var rgbBuf = ['rgb(', 0, ',', 0, ',', 0, ')']; + + // makeCssRgb() can be called thousands of times. Using |rgbBuf| avoids + // creating many intermediate strings. + Util.makeCssRgb = function Util_makeCssRgb(r, g, b) { + rgbBuf[1] = r; + rgbBuf[3] = g; + rgbBuf[5] = b; + return rgbBuf.join(''); + }; + + // Concatenates two transformation matrices together and returns the result. + Util.transform = function Util_transform(m1, m2) { + return [ + m1[0] * m2[0] + m1[2] * m2[1], + m1[1] * m2[0] + m1[3] * m2[1], + m1[0] * m2[2] + m1[2] * m2[3], + m1[1] * m2[2] + m1[3] * m2[3], + m1[0] * m2[4] + m1[2] * m2[5] + m1[4], + m1[1] * m2[4] + m1[3] * m2[5] + m1[5] + ]; + }; + + // For 2d affine transforms + Util.applyTransform = function Util_applyTransform(p, m) { + var xt = p[0] * m[0] + p[1] * m[2] + m[4]; + var yt = p[0] * m[1] + p[1] * m[3] + m[5]; + return [xt, yt]; + }; + + Util.applyInverseTransform = function Util_applyInverseTransform(p, m) { + var d = m[0] * m[3] - m[1] * m[2]; + var xt = (p[0] * m[3] - p[1] * m[2] + m[2] * m[5] - m[4] * m[3]) / d; + var yt = (-p[0] * m[1] + p[1] * m[0] + m[4] * m[1] - m[5] * m[0]) / d; + return [xt, yt]; + }; + + // Applies the transform to the rectangle and finds the minimum axially + // aligned bounding box. + Util.getAxialAlignedBoundingBox = + function Util_getAxialAlignedBoundingBox(r, m) { + + var p1 = Util.applyTransform(r, m); + var p2 = Util.applyTransform(r.slice(2, 4), m); + var p3 = Util.applyTransform([r[0], r[3]], m); + var p4 = Util.applyTransform([r[2], r[1]], m); + return [ + Math.min(p1[0], p2[0], p3[0], p4[0]), + Math.min(p1[1], p2[1], p3[1], p4[1]), + Math.max(p1[0], p2[0], p3[0], p4[0]), + Math.max(p1[1], p2[1], p3[1], p4[1]) + ]; + }; + + Util.inverseTransform = function Util_inverseTransform(m) { + var d = m[0] * m[3] - m[1] * m[2]; + return [m[3] / d, -m[1] / d, -m[2] / d, m[0] / d, + (m[2] * m[5] - m[4] * m[3]) / d, (m[4] * m[1] - m[5] * m[0]) / d]; + }; + + // Apply a generic 3d matrix M on a 3-vector v: + // | a b c | | X | + // | d e f | x | Y | + // | g h i | | Z | + // M is assumed to be serialized as [a,b,c,d,e,f,g,h,i], + // with v as [X,Y,Z] + Util.apply3dTransform = function Util_apply3dTransform(m, v) { + return [ + m[0] * v[0] + m[1] * v[1] + m[2] * v[2], + m[3] * v[0] + m[4] * v[1] + m[5] * v[2], + m[6] * v[0] + m[7] * v[1] + m[8] * v[2] + ]; + }; + + // This calculation uses Singular Value Decomposition. + // The SVD can be represented with formula A = USV. We are interested in the + // matrix S here because it represents the scale values. + Util.singularValueDecompose2dScale = + function Util_singularValueDecompose2dScale(m) { + + var transpose = [m[0], m[2], m[1], m[3]]; + + // Multiply matrix m with its transpose. + var a = m[0] * transpose[0] + m[1] * transpose[2]; + var b = m[0] * transpose[1] + m[1] * transpose[3]; + var c = m[2] * transpose[0] + m[3] * transpose[2]; + var d = m[2] * transpose[1] + m[3] * transpose[3]; + + // Solve the second degree polynomial to get roots. + var first = (a + d) / 2; + var second = Math.sqrt((a + d) * (a + d) - 4 * (a * d - c * b)) / 2; + var sx = first + second || 1; + var sy = first - second || 1; + + // Scale values are the square roots of the eigenvalues. + return [Math.sqrt(sx), Math.sqrt(sy)]; + }; + + // Normalize rectangle rect=[x1, y1, x2, y2] so that (x1,y1) < (x2,y2) + // For coordinate systems whose origin lies in the bottom-left, this + // means normalization to (BL,TR) ordering. For systems with origin in the + // top-left, this means (TL,BR) ordering. + Util.normalizeRect = function Util_normalizeRect(rect) { + var r = rect.slice(0); // clone rect + if (rect[0] > rect[2]) { + r[0] = rect[2]; + r[2] = rect[0]; + } + if (rect[1] > rect[3]) { + r[1] = rect[3]; + r[3] = rect[1]; + } + return r; + }; + + // Returns a rectangle [x1, y1, x2, y2] corresponding to the + // intersection of rect1 and rect2. If no intersection, returns 'false' + // The rectangle coordinates of rect1, rect2 should be [x1, y1, x2, y2] + Util.intersect = function Util_intersect(rect1, rect2) { + function compare(a, b) { + return a - b; + } + + // Order points along the axes + var orderedX = [rect1[0], rect1[2], rect2[0], rect2[2]].sort(compare), + orderedY = [rect1[1], rect1[3], rect2[1], rect2[3]].sort(compare), + result = []; + + rect1 = Util.normalizeRect(rect1); + rect2 = Util.normalizeRect(rect2); + + // X: first and second points belong to different rectangles? + if ((orderedX[0] === rect1[0] && orderedX[1] === rect2[0]) || + (orderedX[0] === rect2[0] && orderedX[1] === rect1[0])) { + // Intersection must be between second and third points + result[0] = orderedX[1]; + result[2] = orderedX[2]; + } else { + return false; + } + + // Y: first and second points belong to different rectangles? + if ((orderedY[0] === rect1[1] && orderedY[1] === rect2[1]) || + (orderedY[0] === rect2[1] && orderedY[1] === rect1[1])) { + // Intersection must be between second and third points + result[1] = orderedY[1]; + result[3] = orderedY[2]; + } else { + return false; + } + + return result; + }; + + Util.sign = function Util_sign(num) { + return num < 0 ? -1 : 1; + }; + + var ROMAN_NUMBER_MAP = [ + '', 'C', 'CC', 'CCC', 'CD', 'D', 'DC', 'DCC', 'DCCC', 'CM', + '', 'X', 'XX', 'XXX', 'XL', 'L', 'LX', 'LXX', 'LXXX', 'XC', + '', 'I', 'II', 'III', 'IV', 'V', 'VI', 'VII', 'VIII', 'IX' + ]; + /** + * Converts positive integers to (upper case) Roman numerals. + * @param {integer} number - The number that should be converted. + * @param {boolean} lowerCase - Indicates if the result should be converted + * to lower case letters. The default is false. + * @return {string} The resulting Roman number. + */ + Util.toRoman = function Util_toRoman(number, lowerCase) { + assert(isInt(number) && number > 0, + 'The number should be a positive integer.'); + var pos, romanBuf = []; + // Thousands + while (number >= 1000) { + number -= 1000; + romanBuf.push('M'); + } + // Hundreds + pos = (number / 100) | 0; + number %= 100; + romanBuf.push(ROMAN_NUMBER_MAP[pos]); + // Tens + pos = (number / 10) | 0; + number %= 10; + romanBuf.push(ROMAN_NUMBER_MAP[10 + pos]); + // Ones + romanBuf.push(ROMAN_NUMBER_MAP[20 + number]); + + var romanStr = romanBuf.join(''); + return (lowerCase ? romanStr.toLowerCase() : romanStr); + }; + + Util.appendToArray = function Util_appendToArray(arr1, arr2) { + Array.prototype.push.apply(arr1, arr2); + }; + + Util.prependToArray = function Util_prependToArray(arr1, arr2) { + Array.prototype.unshift.apply(arr1, arr2); + }; + + Util.extendObj = function extendObj(obj1, obj2) { + for (var key in obj2) { + obj1[key] = obj2[key]; + } + }; + + Util.getInheritableProperty = function Util_getInheritableProperty(dict, + name) { + while (dict && !dict.has(name)) { + dict = dict.get('Parent'); + } + if (!dict) { + return null; + } + return dict.get(name); + }; + + Util.inherit = function Util_inherit(sub, base, prototype) { + sub.prototype = Object.create(base.prototype); + sub.prototype.constructor = sub; + for (var prop in prototype) { + sub.prototype[prop] = prototype[prop]; + } + }; + + Util.loadScript = function Util_loadScript(src, callback) { + var script = document.createElement('script'); + var loaded = false; + script.setAttribute('src', src); + if (callback) { + script.onload = function() { + if (!loaded) { + callback(); + } + loaded = true; + }; + } + document.getElementsByTagName('head')[0].appendChild(script); + }; + + return Util; +})(); + +/** + * PDF page viewport created based on scale, rotation and offset. + * @class + * @alias PDFJS.PageViewport + */ +var PageViewport = (function PageViewportClosure() { + /** + * @constructor + * @private + * @param viewBox {Array} xMin, yMin, xMax and yMax coordinates. + * @param scale {number} scale of the viewport. + * @param rotation {number} rotations of the viewport in degrees. + * @param offsetX {number} offset X + * @param offsetY {number} offset Y + * @param dontFlip {boolean} if true, axis Y will not be flipped. + */ + function PageViewport(viewBox, scale, rotation, offsetX, offsetY, dontFlip) { + this.viewBox = viewBox; + this.scale = scale; + this.rotation = rotation; + this.offsetX = offsetX; + this.offsetY = offsetY; + + // creating transform to convert pdf coordinate system to the normal + // canvas like coordinates taking in account scale and rotation + var centerX = (viewBox[2] + viewBox[0]) / 2; + var centerY = (viewBox[3] + viewBox[1]) / 2; + var rotateA, rotateB, rotateC, rotateD; + rotation = rotation % 360; + rotation = rotation < 0 ? rotation + 360 : rotation; + switch (rotation) { + case 180: + rotateA = -1; rotateB = 0; rotateC = 0; rotateD = 1; + break; + case 90: + rotateA = 0; rotateB = 1; rotateC = 1; rotateD = 0; + break; + case 270: + rotateA = 0; rotateB = -1; rotateC = -1; rotateD = 0; + break; + //case 0: + default: + rotateA = 1; rotateB = 0; rotateC = 0; rotateD = -1; + break; + } + + if (dontFlip) { + rotateC = -rotateC; rotateD = -rotateD; + } + + var offsetCanvasX, offsetCanvasY; + var width, height; + if (rotateA === 0) { + offsetCanvasX = Math.abs(centerY - viewBox[1]) * scale + offsetX; + offsetCanvasY = Math.abs(centerX - viewBox[0]) * scale + offsetY; + width = Math.abs(viewBox[3] - viewBox[1]) * scale; + height = Math.abs(viewBox[2] - viewBox[0]) * scale; + } else { + offsetCanvasX = Math.abs(centerX - viewBox[0]) * scale + offsetX; + offsetCanvasY = Math.abs(centerY - viewBox[1]) * scale + offsetY; + width = Math.abs(viewBox[2] - viewBox[0]) * scale; + height = Math.abs(viewBox[3] - viewBox[1]) * scale; + } + // creating transform for the following operations: + // translate(-centerX, -centerY), rotate and flip vertically, + // scale, and translate(offsetCanvasX, offsetCanvasY) + this.transform = [ + rotateA * scale, + rotateB * scale, + rotateC * scale, + rotateD * scale, + offsetCanvasX - rotateA * scale * centerX - rotateC * scale * centerY, + offsetCanvasY - rotateB * scale * centerX - rotateD * scale * centerY + ]; + + this.width = width; + this.height = height; + this.fontScale = scale; + } + PageViewport.prototype = /** @lends PDFJS.PageViewport.prototype */ { + /** + * Clones viewport with additional properties. + * @param args {Object} (optional) If specified, may contain the 'scale' or + * 'rotation' properties to override the corresponding properties in + * the cloned viewport. + * @returns {PDFJS.PageViewport} Cloned viewport. + */ + clone: function PageViewPort_clone(args) { + args = args || {}; + var scale = 'scale' in args ? args.scale : this.scale; + var rotation = 'rotation' in args ? args.rotation : this.rotation; + return new PageViewport(this.viewBox.slice(), scale, rotation, + this.offsetX, this.offsetY, args.dontFlip); + }, + /** + * Converts PDF point to the viewport coordinates. For examples, useful for + * converting PDF location into canvas pixel coordinates. + * @param x {number} X coordinate. + * @param y {number} Y coordinate. + * @returns {Object} Object that contains 'x' and 'y' properties of the + * point in the viewport coordinate space. + * @see {@link convertToPdfPoint} + * @see {@link convertToViewportRectangle} + */ + convertToViewportPoint: function PageViewport_convertToViewportPoint(x, y) { + return Util.applyTransform([x, y], this.transform); + }, + /** + * Converts PDF rectangle to the viewport coordinates. + * @param rect {Array} xMin, yMin, xMax and yMax coordinates. + * @returns {Array} Contains corresponding coordinates of the rectangle + * in the viewport coordinate space. + * @see {@link convertToViewportPoint} + */ + convertToViewportRectangle: + function PageViewport_convertToViewportRectangle(rect) { + var tl = Util.applyTransform([rect[0], rect[1]], this.transform); + var br = Util.applyTransform([rect[2], rect[3]], this.transform); + return [tl[0], tl[1], br[0], br[1]]; + }, + /** + * Converts viewport coordinates to the PDF location. For examples, useful + * for converting canvas pixel location into PDF one. + * @param x {number} X coordinate. + * @param y {number} Y coordinate. + * @returns {Object} Object that contains 'x' and 'y' properties of the + * point in the PDF coordinate space. + * @see {@link convertToViewportPoint} + */ + convertToPdfPoint: function PageViewport_convertToPdfPoint(x, y) { + return Util.applyInverseTransform([x, y], this.transform); + } + }; + return PageViewport; +})(); + +var PDFStringTranslateTable = [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0x2D8, 0x2C7, 0x2C6, 0x2D9, 0x2DD, 0x2DB, 0x2DA, 0x2DC, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x2022, 0x2020, 0x2021, 0x2026, 0x2014, + 0x2013, 0x192, 0x2044, 0x2039, 0x203A, 0x2212, 0x2030, 0x201E, 0x201C, + 0x201D, 0x2018, 0x2019, 0x201A, 0x2122, 0xFB01, 0xFB02, 0x141, 0x152, 0x160, + 0x178, 0x17D, 0x131, 0x142, 0x153, 0x161, 0x17E, 0, 0x20AC +]; + +function stringToPDFString(str) { + var i, n = str.length, strBuf = []; + if (str[0] === '\xFE' && str[1] === '\xFF') { + // UTF16BE BOM + for (i = 2; i < n; i += 2) { + strBuf.push(String.fromCharCode( + (str.charCodeAt(i) << 8) | str.charCodeAt(i + 1))); + } + } else { + for (i = 0; i < n; ++i) { + var code = PDFStringTranslateTable[str.charCodeAt(i)]; + strBuf.push(code ? String.fromCharCode(code) : str.charAt(i)); + } + } + return strBuf.join(''); +} + +function stringToUTF8String(str) { + return decodeURIComponent(escape(str)); +} + +function utf8StringToString(str) { + return unescape(encodeURIComponent(str)); +} + +function isEmptyObj(obj) { + for (var key in obj) { + return false; + } + return true; +} + +function isBool(v) { + return typeof v === 'boolean'; +} + +function isInt(v) { + return typeof v === 'number' && ((v | 0) === v); +} + +function isNum(v) { + return typeof v === 'number'; +} + +function isString(v) { + return typeof v === 'string'; +} + +function isArray(v) { + return v instanceof Array; +} + +function isArrayBuffer(v) { + return typeof v === 'object' && v !== null && v.byteLength !== undefined; +} + +/** + * Promise Capability object. + * + * @typedef {Object} PromiseCapability + * @property {Promise} promise - A promise object. + * @property {function} resolve - Fullfills the promise. + * @property {function} reject - Rejects the promise. + */ + +/** + * Creates a promise capability object. + * @alias PDFJS.createPromiseCapability + * + * @return {PromiseCapability} A capability object contains: + * - a Promise, resolve and reject methods. + */ +function createPromiseCapability() { + var capability = {}; + capability.promise = new Promise(function (resolve, reject) { + capability.resolve = resolve; + capability.reject = reject; + }); + return capability; +} + +/** + * Polyfill for Promises: + * The following promise implementation tries to generally implement the + * Promise/A+ spec. Some notable differences from other promise libaries are: + * - There currently isn't a seperate deferred and promise object. + * - Unhandled rejections eventually show an error if they aren't handled. + * + * Based off of the work in: + * https://bugzilla.mozilla.org/show_bug.cgi?id=810490 + */ +(function PromiseClosure() { + if (globalScope.Promise) { + // Promises existing in the DOM/Worker, checking presence of all/resolve + if (typeof globalScope.Promise.all !== 'function') { + globalScope.Promise.all = function (iterable) { + var count = 0, results = [], resolve, reject; + var promise = new globalScope.Promise(function (resolve_, reject_) { + resolve = resolve_; + reject = reject_; + }); + iterable.forEach(function (p, i) { + count++; + p.then(function (result) { + results[i] = result; + count--; + if (count === 0) { + resolve(results); + } + }, reject); + }); + if (count === 0) { + resolve(results); + } + return promise; + }; + } + if (typeof globalScope.Promise.resolve !== 'function') { + globalScope.Promise.resolve = function (value) { + return new globalScope.Promise(function (resolve) { resolve(value); }); + }; + } + if (typeof globalScope.Promise.reject !== 'function') { + globalScope.Promise.reject = function (reason) { + return new globalScope.Promise(function (resolve, reject) { + reject(reason); + }); + }; + } + if (typeof globalScope.Promise.prototype.catch !== 'function') { + globalScope.Promise.prototype.catch = function (onReject) { + return globalScope.Promise.prototype.then(undefined, onReject); + }; + } + return; + } + var STATUS_PENDING = 0; + var STATUS_RESOLVED = 1; + var STATUS_REJECTED = 2; + + // In an attempt to avoid silent exceptions, unhandled rejections are + // tracked and if they aren't handled in a certain amount of time an + // error is logged. + var REJECTION_TIMEOUT = 500; + + var HandlerManager = { + handlers: [], + running: false, + unhandledRejections: [], + pendingRejectionCheck: false, + + scheduleHandlers: function scheduleHandlers(promise) { + if (promise._status === STATUS_PENDING) { + return; + } + + this.handlers = this.handlers.concat(promise._handlers); + promise._handlers = []; + + if (this.running) { + return; + } + this.running = true; + + setTimeout(this.runHandlers.bind(this), 0); + }, + + runHandlers: function runHandlers() { + var RUN_TIMEOUT = 1; // ms + var timeoutAt = Date.now() + RUN_TIMEOUT; + while (this.handlers.length > 0) { + var handler = this.handlers.shift(); + + var nextStatus = handler.thisPromise._status; + var nextValue = handler.thisPromise._value; + + try { + if (nextStatus === STATUS_RESOLVED) { + if (typeof handler.onResolve === 'function') { + nextValue = handler.onResolve(nextValue); + } + } else if (typeof handler.onReject === 'function') { + nextValue = handler.onReject(nextValue); + nextStatus = STATUS_RESOLVED; + + if (handler.thisPromise._unhandledRejection) { + this.removeUnhandeledRejection(handler.thisPromise); + } + } + } catch (ex) { + nextStatus = STATUS_REJECTED; + nextValue = ex; + } + + handler.nextPromise._updateStatus(nextStatus, nextValue); + if (Date.now() >= timeoutAt) { + break; + } + } + + if (this.handlers.length > 0) { + setTimeout(this.runHandlers.bind(this), 0); + return; + } + + this.running = false; + }, + + addUnhandledRejection: function addUnhandledRejection(promise) { + this.unhandledRejections.push({ + promise: promise, + time: Date.now() + }); + this.scheduleRejectionCheck(); + }, + + removeUnhandeledRejection: function removeUnhandeledRejection(promise) { + promise._unhandledRejection = false; + for (var i = 0; i < this.unhandledRejections.length; i++) { + if (this.unhandledRejections[i].promise === promise) { + this.unhandledRejections.splice(i); + i--; + } + } + }, + + scheduleRejectionCheck: function scheduleRejectionCheck() { + if (this.pendingRejectionCheck) { + return; + } + this.pendingRejectionCheck = true; + setTimeout(function rejectionCheck() { + this.pendingRejectionCheck = false; + var now = Date.now(); + for (var i = 0; i < this.unhandledRejections.length; i++) { + if (now - this.unhandledRejections[i].time > REJECTION_TIMEOUT) { + var unhandled = this.unhandledRejections[i].promise._value; + var msg = 'Unhandled rejection: ' + unhandled; + if (unhandled.stack) { + msg += '\n' + unhandled.stack; + } + warn(msg); + this.unhandledRejections.splice(i); + i--; + } + } + if (this.unhandledRejections.length) { + this.scheduleRejectionCheck(); + } + }.bind(this), REJECTION_TIMEOUT); + } + }; + + function Promise(resolver) { + this._status = STATUS_PENDING; + this._handlers = []; + try { + resolver.call(this, this._resolve.bind(this), this._reject.bind(this)); + } catch (e) { + this._reject(e); + } + } + /** + * Builds a promise that is resolved when all the passed in promises are + * resolved. + * @param {array} array of data and/or promises to wait for. + * @return {Promise} New dependant promise. + */ + Promise.all = function Promise_all(promises) { + var resolveAll, rejectAll; + var deferred = new Promise(function (resolve, reject) { + resolveAll = resolve; + rejectAll = reject; + }); + var unresolved = promises.length; + var results = []; + if (unresolved === 0) { + resolveAll(results); + return deferred; + } + function reject(reason) { + if (deferred._status === STATUS_REJECTED) { + return; + } + results = []; + rejectAll(reason); + } + for (var i = 0, ii = promises.length; i < ii; ++i) { + var promise = promises[i]; + var resolve = (function(i) { + return function(value) { + if (deferred._status === STATUS_REJECTED) { + return; + } + results[i] = value; + unresolved--; + if (unresolved === 0) { + resolveAll(results); + } + }; + })(i); + if (Promise.isPromise(promise)) { + promise.then(resolve, reject); + } else { + resolve(promise); + } + } + return deferred; + }; + + /** + * Checks if the value is likely a promise (has a 'then' function). + * @return {boolean} true if value is thenable + */ + Promise.isPromise = function Promise_isPromise(value) { + return value && typeof value.then === 'function'; + }; + + /** + * Creates resolved promise + * @param value resolve value + * @returns {Promise} + */ + Promise.resolve = function Promise_resolve(value) { + return new Promise(function (resolve) { resolve(value); }); + }; + + /** + * Creates rejected promise + * @param reason rejection value + * @returns {Promise} + */ + Promise.reject = function Promise_reject(reason) { + return new Promise(function (resolve, reject) { reject(reason); }); + }; + + Promise.prototype = { + _status: null, + _value: null, + _handlers: null, + _unhandledRejection: null, + + _updateStatus: function Promise__updateStatus(status, value) { + if (this._status === STATUS_RESOLVED || + this._status === STATUS_REJECTED) { + return; + } + + if (status === STATUS_RESOLVED && + Promise.isPromise(value)) { + value.then(this._updateStatus.bind(this, STATUS_RESOLVED), + this._updateStatus.bind(this, STATUS_REJECTED)); + return; + } + + this._status = status; + this._value = value; + + if (status === STATUS_REJECTED && this._handlers.length === 0) { + this._unhandledRejection = true; + HandlerManager.addUnhandledRejection(this); + } + + HandlerManager.scheduleHandlers(this); + }, + + _resolve: function Promise_resolve(value) { + this._updateStatus(STATUS_RESOLVED, value); + }, + + _reject: function Promise_reject(reason) { + this._updateStatus(STATUS_REJECTED, reason); + }, + + then: function Promise_then(onResolve, onReject) { + var nextPromise = new Promise(function (resolve, reject) { + this.resolve = resolve; + this.reject = reject; + }); + this._handlers.push({ + thisPromise: this, + onResolve: onResolve, + onReject: onReject, + nextPromise: nextPromise + }); + HandlerManager.scheduleHandlers(this); + return nextPromise; + }, + + catch: function Promise_catch(onReject) { + return this.then(undefined, onReject); + } + }; + + globalScope.Promise = Promise; +})(); + +var StatTimer = (function StatTimerClosure() { + function rpad(str, pad, length) { + while (str.length < length) { + str += pad; + } + return str; + } + function StatTimer() { + this.started = Object.create(null); + this.times = []; + this.enabled = true; + } + StatTimer.prototype = { + time: function StatTimer_time(name) { + if (!this.enabled) { + return; + } + if (name in this.started) { + warn('Timer is already running for ' + name); + } + this.started[name] = Date.now(); + }, + timeEnd: function StatTimer_timeEnd(name) { + if (!this.enabled) { + return; + } + if (!(name in this.started)) { + warn('Timer has not been started for ' + name); + } + this.times.push({ + 'name': name, + 'start': this.started[name], + 'end': Date.now() + }); + // Remove timer from started so it can be called again. + delete this.started[name]; + }, + toString: function StatTimer_toString() { + var i, ii; + var times = this.times; + var out = ''; + // Find the longest name for padding purposes. + var longest = 0; + for (i = 0, ii = times.length; i < ii; ++i) { + var name = times[i]['name']; + if (name.length > longest) { + longest = name.length; + } + } + for (i = 0, ii = times.length; i < ii; ++i) { + var span = times[i]; + var duration = span.end - span.start; + out += rpad(span['name'], ' ', longest) + ' ' + duration + 'ms\n'; + } + return out; + } + }; + return StatTimer; +})(); + +var createBlob = function createBlob(data, contentType) { + if (typeof Blob !== 'undefined') { + return new Blob([data], { type: contentType }); + } + // Blob builder is deprecated in FF14 and removed in FF18. + var bb = new MozBlobBuilder(); + bb.append(data); + return bb.getBlob(contentType); +}; + +var createObjectURL = (function createObjectURLClosure() { + // Blob/createObjectURL is not available, falling back to data schema. + var digits = + 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='; + + return function createObjectURL(data, contentType, forceDataSchema) { + if (!forceDataSchema && + typeof URL !== 'undefined' && URL.createObjectURL) { + var blob = createBlob(data, contentType); + return URL.createObjectURL(blob); + } + + var buffer = 'data:' + contentType + ';base64,'; + for (var i = 0, ii = data.length; i < ii; i += 3) { + var b1 = data[i] & 0xFF; + var b2 = data[i + 1] & 0xFF; + var b3 = data[i + 2] & 0xFF; + var d1 = b1 >> 2, d2 = ((b1 & 3) << 4) | (b2 >> 4); + var d3 = i + 1 < ii ? ((b2 & 0xF) << 2) | (b3 >> 6) : 64; + var d4 = i + 2 < ii ? (b3 & 0x3F) : 64; + buffer += digits[d1] + digits[d2] + digits[d3] + digits[d4]; + } + return buffer; + }; +})(); + +function MessageHandler(sourceName, targetName, comObj) { + this.sourceName = sourceName; + this.targetName = targetName; + this.comObj = comObj; + this.callbackIndex = 1; + this.postMessageTransfers = true; + var callbacksCapabilities = this.callbacksCapabilities = Object.create(null); + var ah = this.actionHandler = Object.create(null); + + this._onComObjOnMessage = function messageHandlerComObjOnMessage(event) { + var data = event.data; + if (data.targetName !== this.sourceName) { + return; + } + if (data.isReply) { + var callbackId = data.callbackId; + if (data.callbackId in callbacksCapabilities) { + var callback = callbacksCapabilities[callbackId]; + delete callbacksCapabilities[callbackId]; + if ('error' in data) { + callback.reject(data.error); + } else { + callback.resolve(data.data); + } + } else { + error('Cannot resolve callback ' + callbackId); + } + } else if (data.action in ah) { + var action = ah[data.action]; + if (data.callbackId) { + var sourceName = this.sourceName; + var targetName = data.sourceName; + Promise.resolve().then(function () { + return action[0].call(action[1], data.data); + }).then(function (result) { + comObj.postMessage({ + sourceName: sourceName, + targetName: targetName, + isReply: true, + callbackId: data.callbackId, + data: result + }); + }, function (reason) { + if (reason instanceof Error) { + // Serialize error to avoid "DataCloneError" + reason = reason + ''; + } + comObj.postMessage({ + sourceName: sourceName, + targetName: targetName, + isReply: true, + callbackId: data.callbackId, + error: reason + }); + }); + } else { + action[0].call(action[1], data.data); + } + } else { + error('Unknown action from worker: ' + data.action); + } + }.bind(this); + comObj.addEventListener('message', this._onComObjOnMessage); +} + +MessageHandler.prototype = { + on: function messageHandlerOn(actionName, handler, scope) { + var ah = this.actionHandler; + if (ah[actionName]) { + error('There is already an actionName called "' + actionName + '"'); + } + ah[actionName] = [handler, scope]; + }, + /** + * Sends a message to the comObj to invoke the action with the supplied data. + * @param {String} actionName Action to call. + * @param {JSON} data JSON data to send. + * @param {Array} [transfers] Optional list of transfers/ArrayBuffers + */ + send: function messageHandlerSend(actionName, data, transfers) { + var message = { + sourceName: this.sourceName, + targetName: this.targetName, + action: actionName, + data: data + }; + this.postMessage(message, transfers); + }, + /** + * Sends a message to the comObj to invoke the action with the supplied data. + * Expects that other side will callback with the response. + * @param {String} actionName Action to call. + * @param {JSON} data JSON data to send. + * @param {Array} [transfers] Optional list of transfers/ArrayBuffers. + * @returns {Promise} Promise to be resolved with response data. + */ + sendWithPromise: + function messageHandlerSendWithPromise(actionName, data, transfers) { + var callbackId = this.callbackIndex++; + var message = { + sourceName: this.sourceName, + targetName: this.targetName, + action: actionName, + data: data, + callbackId: callbackId + }; + var capability = createPromiseCapability(); + this.callbacksCapabilities[callbackId] = capability; + try { + this.postMessage(message, transfers); + } catch (e) { + capability.reject(e); + } + return capability.promise; + }, + /** + * Sends raw message to the comObj. + * @private + * @param message {Object} Raw message. + * @param transfers List of transfers/ArrayBuffers, or undefined. + */ + postMessage: function (message, transfers) { + if (transfers && this.postMessageTransfers) { + this.comObj.postMessage(message, transfers); + } else { + this.comObj.postMessage(message); + } + }, + + destroy: function () { + this.comObj.removeEventListener('message', this._onComObjOnMessage); + } +}; + +function loadJpegStream(id, imageUrl, objs) { + var img = new Image(); + img.onload = (function loadJpegStream_onloadClosure() { + objs.resolve(id, img); + }); + img.onerror = (function loadJpegStream_onerrorClosure() { + objs.resolve(id, null); + warn('Error during JPEG image loading'); + }); + img.src = imageUrl; +} + + // Polyfill from https://github.com/Polymer/URL +/* Any copyright is dedicated to the Public Domain. + * http://creativecommons.org/publicdomain/zero/1.0/ */ +(function checkURLConstructor(scope) { + /* jshint ignore:start */ + + // feature detect for URL constructor + var hasWorkingUrl = false; + try { + if (typeof URL === 'function' && + typeof URL.prototype === 'object' && + ('origin' in URL.prototype)) { + var u = new URL('b', 'http://a'); + u.pathname = 'c%20d'; + hasWorkingUrl = u.href === 'http://a/c%20d'; + } + } catch(e) { } + + if (hasWorkingUrl) + return; + + var relative = Object.create(null); + relative['ftp'] = 21; + relative['file'] = 0; + relative['gopher'] = 70; + relative['http'] = 80; + relative['https'] = 443; + relative['ws'] = 80; + relative['wss'] = 443; + + var relativePathDotMapping = Object.create(null); + relativePathDotMapping['%2e'] = '.'; + relativePathDotMapping['.%2e'] = '..'; + relativePathDotMapping['%2e.'] = '..'; + relativePathDotMapping['%2e%2e'] = '..'; + + function isRelativeScheme(scheme) { + return relative[scheme] !== undefined; + } + + function invalid() { + clear.call(this); + this._isInvalid = true; + } + + function IDNAToASCII(h) { + if ('' == h) { + invalid.call(this) + } + // XXX + return h.toLowerCase() + } + + function percentEscape(c) { + var unicode = c.charCodeAt(0); + if (unicode > 0x20 && + unicode < 0x7F && + // " # < > ? ` + [0x22, 0x23, 0x3C, 0x3E, 0x3F, 0x60].indexOf(unicode) == -1 + ) { + return c; + } + return encodeURIComponent(c); + } + + function percentEscapeQuery(c) { + // XXX This actually needs to encode c using encoding and then + // convert the bytes one-by-one. + + var unicode = c.charCodeAt(0); + if (unicode > 0x20 && + unicode < 0x7F && + // " # < > ` (do not escape '?') + [0x22, 0x23, 0x3C, 0x3E, 0x60].indexOf(unicode) == -1 + ) { + return c; + } + return encodeURIComponent(c); + } + + var EOF = undefined, + ALPHA = /[a-zA-Z]/, + ALPHANUMERIC = /[a-zA-Z0-9\+\-\.]/; + + function parse(input, stateOverride, base) { + function err(message) { + errors.push(message) + } + + var state = stateOverride || 'scheme start', + cursor = 0, + buffer = '', + seenAt = false, + seenBracket = false, + errors = []; + + loop: while ((input[cursor - 1] != EOF || cursor == 0) && !this._isInvalid) { + var c = input[cursor]; + switch (state) { + case 'scheme start': + if (c && ALPHA.test(c)) { + buffer += c.toLowerCase(); // ASCII-safe + state = 'scheme'; + } else if (!stateOverride) { + buffer = ''; + state = 'no scheme'; + continue; + } else { + err('Invalid scheme.'); + break loop; + } + break; + + case 'scheme': + if (c && ALPHANUMERIC.test(c)) { + buffer += c.toLowerCase(); // ASCII-safe + } else if (':' == c) { + this._scheme = buffer; + buffer = ''; + if (stateOverride) { + break loop; + } + if (isRelativeScheme(this._scheme)) { + this._isRelative = true; + } + if ('file' == this._scheme) { + state = 'relative'; + } else if (this._isRelative && base && base._scheme == this._scheme) { + state = 'relative or authority'; + } else if (this._isRelative) { + state = 'authority first slash'; + } else { + state = 'scheme data'; + } + } else if (!stateOverride) { + buffer = ''; + cursor = 0; + state = 'no scheme'; + continue; + } else if (EOF == c) { + break loop; + } else { + err('Code point not allowed in scheme: ' + c) + break loop; + } + break; + + case 'scheme data': + if ('?' == c) { + this._query = '?'; + state = 'query'; + } else if ('#' == c) { + this._fragment = '#'; + state = 'fragment'; + } else { + // XXX error handling + if (EOF != c && '\t' != c && '\n' != c && '\r' != c) { + this._schemeData += percentEscape(c); + } + } + break; + + case 'no scheme': + if (!base || !(isRelativeScheme(base._scheme))) { + err('Missing scheme.'); + invalid.call(this); + } else { + state = 'relative'; + continue; + } + break; + + case 'relative or authority': + if ('/' == c && '/' == input[cursor+1]) { + state = 'authority ignore slashes'; + } else { + err('Expected /, got: ' + c); + state = 'relative'; + continue + } + break; + + case 'relative': + this._isRelative = true; + if ('file' != this._scheme) + this._scheme = base._scheme; + if (EOF == c) { + this._host = base._host; + this._port = base._port; + this._path = base._path.slice(); + this._query = base._query; + this._username = base._username; + this._password = base._password; + break loop; + } else if ('/' == c || '\\' == c) { + if ('\\' == c) + err('\\ is an invalid code point.'); + state = 'relative slash'; + } else if ('?' == c) { + this._host = base._host; + this._port = base._port; + this._path = base._path.slice(); + this._query = '?'; + this._username = base._username; + this._password = base._password; + state = 'query'; + } else if ('#' == c) { + this._host = base._host; + this._port = base._port; + this._path = base._path.slice(); + this._query = base._query; + this._fragment = '#'; + this._username = base._username; + this._password = base._password; + state = 'fragment'; + } else { + var nextC = input[cursor+1] + var nextNextC = input[cursor+2] + if ( + 'file' != this._scheme || !ALPHA.test(c) || + (nextC != ':' && nextC != '|') || + (EOF != nextNextC && '/' != nextNextC && '\\' != nextNextC && '?' != nextNextC && '#' != nextNextC)) { + this._host = base._host; + this._port = base._port; + this._username = base._username; + this._password = base._password; + this._path = base._path.slice(); + this._path.pop(); + } + state = 'relative path'; + continue; + } + break; + + case 'relative slash': + if ('/' == c || '\\' == c) { + if ('\\' == c) { + err('\\ is an invalid code point.'); + } + if ('file' == this._scheme) { + state = 'file host'; + } else { + state = 'authority ignore slashes'; + } + } else { + if ('file' != this._scheme) { + this._host = base._host; + this._port = base._port; + this._username = base._username; + this._password = base._password; + } + state = 'relative path'; + continue; + } + break; + + case 'authority first slash': + if ('/' == c) { + state = 'authority second slash'; + } else { + err("Expected '/', got: " + c); + state = 'authority ignore slashes'; + continue; + } + break; + + case 'authority second slash': + state = 'authority ignore slashes'; + if ('/' != c) { + err("Expected '/', got: " + c); + continue; + } + break; + + case 'authority ignore slashes': + if ('/' != c && '\\' != c) { + state = 'authority'; + continue; + } else { + err('Expected authority, got: ' + c); + } + break; + + case 'authority': + if ('@' == c) { + if (seenAt) { + err('@ already seen.'); + buffer += '%40'; + } + seenAt = true; + for (var i = 0; i < buffer.length; i++) { + var cp = buffer[i]; + if ('\t' == cp || '\n' == cp || '\r' == cp) { + err('Invalid whitespace in authority.'); + continue; + } + // XXX check URL code points + if (':' == cp && null === this._password) { + this._password = ''; + continue; + } + var tempC = percentEscape(cp); + (null !== this._password) ? this._password += tempC : this._username += tempC; + } + buffer = ''; + } else if (EOF == c || '/' == c || '\\' == c || '?' == c || '#' == c) { + cursor -= buffer.length; + buffer = ''; + state = 'host'; + continue; + } else { + buffer += c; + } + break; + + case 'file host': + if (EOF == c || '/' == c || '\\' == c || '?' == c || '#' == c) { + if (buffer.length == 2 && ALPHA.test(buffer[0]) && (buffer[1] == ':' || buffer[1] == '|')) { + state = 'relative path'; + } else if (buffer.length == 0) { + state = 'relative path start'; + } else { + this._host = IDNAToASCII.call(this, buffer); + buffer = ''; + state = 'relative path start'; + } + continue; + } else if ('\t' == c || '\n' == c || '\r' == c) { + err('Invalid whitespace in file host.'); + } else { + buffer += c; + } + break; + + case 'host': + case 'hostname': + if (':' == c && !seenBracket) { + // XXX host parsing + this._host = IDNAToASCII.call(this, buffer); + buffer = ''; + state = 'port'; + if ('hostname' == stateOverride) { + break loop; + } + } else if (EOF == c || '/' == c || '\\' == c || '?' == c || '#' == c) { + this._host = IDNAToASCII.call(this, buffer); + buffer = ''; + state = 'relative path start'; + if (stateOverride) { + break loop; + } + continue; + } else if ('\t' != c && '\n' != c && '\r' != c) { + if ('[' == c) { + seenBracket = true; + } else if (']' == c) { + seenBracket = false; + } + buffer += c; + } else { + err('Invalid code point in host/hostname: ' + c); + } + break; + + case 'port': + if (/[0-9]/.test(c)) { + buffer += c; + } else if (EOF == c || '/' == c || '\\' == c || '?' == c || '#' == c || stateOverride) { + if ('' != buffer) { + var temp = parseInt(buffer, 10); + if (temp != relative[this._scheme]) { + this._port = temp + ''; + } + buffer = ''; + } + if (stateOverride) { + break loop; + } + state = 'relative path start'; + continue; + } else if ('\t' == c || '\n' == c || '\r' == c) { + err('Invalid code point in port: ' + c); + } else { + invalid.call(this); + } + break; + + case 'relative path start': + if ('\\' == c) + err("'\\' not allowed in path."); + state = 'relative path'; + if ('/' != c && '\\' != c) { + continue; + } + break; + + case 'relative path': + if (EOF == c || '/' == c || '\\' == c || (!stateOverride && ('?' == c || '#' == c))) { + if ('\\' == c) { + err('\\ not allowed in relative path.'); + } + var tmp; + if (tmp = relativePathDotMapping[buffer.toLowerCase()]) { + buffer = tmp; + } + if ('..' == buffer) { + this._path.pop(); + if ('/' != c && '\\' != c) { + this._path.push(''); + } + } else if ('.' == buffer && '/' != c && '\\' != c) { + this._path.push(''); + } else if ('.' != buffer) { + if ('file' == this._scheme && this._path.length == 0 && buffer.length == 2 && ALPHA.test(buffer[0]) && buffer[1] == '|') { + buffer = buffer[0] + ':'; + } + this._path.push(buffer); + } + buffer = ''; + if ('?' == c) { + this._query = '?'; + state = 'query'; + } else if ('#' == c) { + this._fragment = '#'; + state = 'fragment'; + } + } else if ('\t' != c && '\n' != c && '\r' != c) { + buffer += percentEscape(c); + } + break; + + case 'query': + if (!stateOverride && '#' == c) { + this._fragment = '#'; + state = 'fragment'; + } else if (EOF != c && '\t' != c && '\n' != c && '\r' != c) { + this._query += percentEscapeQuery(c); + } + break; + + case 'fragment': + if (EOF != c && '\t' != c && '\n' != c && '\r' != c) { + this._fragment += c; + } + break; + } + + cursor++; + } + } + + function clear() { + this._scheme = ''; + this._schemeData = ''; + this._username = ''; + this._password = null; + this._host = ''; + this._port = ''; + this._path = []; + this._query = ''; + this._fragment = ''; + this._isInvalid = false; + this._isRelative = false; + } + + // Does not process domain names or IP addresses. + // Does not handle encoding for the query parameter. + function jURL(url, base /* , encoding */) { + if (base !== undefined && !(base instanceof jURL)) + base = new jURL(String(base)); + + this._url = url; + clear.call(this); + + var input = url.replace(/^[ \t\r\n\f]+|[ \t\r\n\f]+$/g, ''); + // encoding = encoding || 'utf-8' + + parse.call(this, input, null, base); + } + + jURL.prototype = { + toString: function() { + return this.href; + }, + get href() { + if (this._isInvalid) + return this._url; + + var authority = ''; + if ('' != this._username || null != this._password) { + authority = this._username + + (null != this._password ? ':' + this._password : '') + '@'; + } + + return this.protocol + + (this._isRelative ? '//' + authority + this.host : '') + + this.pathname + this._query + this._fragment; + }, + set href(href) { + clear.call(this); + parse.call(this, href); + }, + + get protocol() { + return this._scheme + ':'; + }, + set protocol(protocol) { + if (this._isInvalid) + return; + parse.call(this, protocol + ':', 'scheme start'); + }, + + get host() { + return this._isInvalid ? '' : this._port ? + this._host + ':' + this._port : this._host; + }, + set host(host) { + if (this._isInvalid || !this._isRelative) + return; + parse.call(this, host, 'host'); + }, + + get hostname() { + return this._host; + }, + set hostname(hostname) { + if (this._isInvalid || !this._isRelative) + return; + parse.call(this, hostname, 'hostname'); + }, + + get port() { + return this._port; + }, + set port(port) { + if (this._isInvalid || !this._isRelative) + return; + parse.call(this, port, 'port'); + }, + + get pathname() { + return this._isInvalid ? '' : this._isRelative ? + '/' + this._path.join('/') : this._schemeData; + }, + set pathname(pathname) { + if (this._isInvalid || !this._isRelative) + return; + this._path = []; + parse.call(this, pathname, 'relative path start'); + }, + + get search() { + return this._isInvalid || !this._query || '?' == this._query ? + '' : this._query; + }, + set search(search) { + if (this._isInvalid || !this._isRelative) + return; + this._query = '?'; + if ('?' == search[0]) + search = search.slice(1); + parse.call(this, search, 'query'); + }, + + get hash() { + return this._isInvalid || !this._fragment || '#' == this._fragment ? + '' : this._fragment; + }, + set hash(hash) { + if (this._isInvalid) + return; + this._fragment = '#'; + if ('#' == hash[0]) + hash = hash.slice(1); + parse.call(this, hash, 'fragment'); + }, + + get origin() { + var host; + if (this._isInvalid || !this._scheme) { + return ''; + } + // javascript: Gecko returns String(""), WebKit/Blink String("null") + // Gecko throws error for "data://" + // data: Gecko returns "", Blink returns "data://", WebKit returns "null" + // Gecko returns String("") for file: mailto: + // WebKit/Blink returns String("SCHEME://") for file: mailto: + switch (this._scheme) { + case 'data': + case 'file': + case 'javascript': + case 'mailto': + return 'null'; + } + host = this.host; + if (!host) { + return ''; + } + return this._scheme + '://' + host; + } + }; + + // Copy over the static methods + var OriginalURL = scope.URL; + if (OriginalURL) { + jURL.createObjectURL = function(blob) { + // IE extension allows a second optional options argument. + // http://msdn.microsoft.com/en-us/library/ie/hh772302(v=vs.85).aspx + return OriginalURL.createObjectURL.apply(OriginalURL, arguments); + }; + jURL.revokeObjectURL = function(url) { + OriginalURL.revokeObjectURL(url); + }; + } + + scope.URL = jURL; + /* jshint ignore:end */ +})(globalScope); + +exports.FONT_IDENTITY_MATRIX = FONT_IDENTITY_MATRIX; +exports.IDENTITY_MATRIX = IDENTITY_MATRIX; +exports.OPS = OPS; +exports.VERBOSITY_LEVELS = VERBOSITY_LEVELS; +exports.UNSUPPORTED_FEATURES = UNSUPPORTED_FEATURES; +exports.AnnotationBorderStyleType = AnnotationBorderStyleType; +exports.AnnotationFlag = AnnotationFlag; +exports.AnnotationType = AnnotationType; +exports.FontType = FontType; +exports.ImageKind = ImageKind; +exports.InvalidPDFException = InvalidPDFException; +exports.MessageHandler = MessageHandler; +exports.MissingDataException = MissingDataException; +exports.MissingPDFException = MissingPDFException; +exports.NotImplementedException = NotImplementedException; +exports.PageViewport = PageViewport; +exports.PasswordException = PasswordException; +exports.PasswordResponses = PasswordResponses; +exports.StatTimer = StatTimer; +exports.StreamType = StreamType; +exports.TextRenderingMode = TextRenderingMode; +exports.UnexpectedResponseException = UnexpectedResponseException; +exports.UnknownErrorException = UnknownErrorException; +exports.Util = Util; +exports.XRefParseException = XRefParseException; +exports.arrayByteLength = arrayByteLength; +exports.arraysToBytes = arraysToBytes; +exports.assert = assert; +exports.bytesToString = bytesToString; +exports.combineUrl = combineUrl; +exports.createBlob = createBlob; +exports.createPromiseCapability = createPromiseCapability; +exports.createObjectURL = createObjectURL; +exports.deprecated = deprecated; +exports.error = error; +exports.getLookupTableFactory = getLookupTableFactory; +exports.getVerbosityLevel = getVerbosityLevel; +exports.globalScope = globalScope; +exports.info = info; +exports.isArray = isArray; +exports.isArrayBuffer = isArrayBuffer; +exports.isBool = isBool; +exports.isEmptyObj = isEmptyObj; +exports.isInt = isInt; +exports.isNum = isNum; +exports.isString = isString; +exports.isSameOrigin = isSameOrigin; +exports.isValidUrl = isValidUrl; +exports.isLittleEndian = isLittleEndian; +exports.loadJpegStream = loadJpegStream; +exports.log2 = log2; +exports.readInt8 = readInt8; +exports.readUint16 = readUint16; +exports.readUint32 = readUint32; +exports.removeNullCharacters = removeNullCharacters; +exports.setVerbosityLevel = setVerbosityLevel; +exports.shadow = shadow; +exports.string32 = string32; +exports.stringToBytes = stringToBytes; +exports.stringToPDFString = stringToPDFString; +exports.stringToUTF8String = stringToUTF8String; +exports.utf8StringToString = utf8StringToString; +exports.warn = warn; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayGlobal = {}), root.pdfjsSharedUtil); + } +}(this, function (exports, sharedUtil) { + + var globalScope = sharedUtil.globalScope; + + var isWorker = (typeof window === 'undefined'); + + // The global PDFJS object exposes the API + // In production, it will be declared outside a global wrapper + // In development, it will be declared here + if (!globalScope.PDFJS) { + globalScope.PDFJS = {}; + } + var PDFJS = globalScope.PDFJS; + + if (typeof pdfjsVersion !== 'undefined') { + PDFJS.version = pdfjsVersion; + } + if (typeof pdfjsBuild !== 'undefined') { + PDFJS.build = pdfjsBuild; + } + + PDFJS.pdfBug = false; + + if (PDFJS.verbosity !== undefined) { + sharedUtil.setVerbosityLevel(PDFJS.verbosity); + } + delete PDFJS.verbosity; + Object.defineProperty(PDFJS, 'verbosity', { + get: function () { return sharedUtil.getVerbosityLevel(); }, + set: function (level) { sharedUtil.setVerbosityLevel(level); }, + enumerable: true, + configurable: true + }); + + PDFJS.VERBOSITY_LEVELS = sharedUtil.VERBOSITY_LEVELS; + PDFJS.OPS = sharedUtil.OPS; + PDFJS.UNSUPPORTED_FEATURES = sharedUtil.UNSUPPORTED_FEATURES; + PDFJS.isValidUrl = sharedUtil.isValidUrl; + PDFJS.shadow = sharedUtil.shadow; + PDFJS.createBlob = sharedUtil.createBlob; + PDFJS.createObjectURL = function PDFJS_createObjectURL(data, contentType) { + return sharedUtil.createObjectURL(data, contentType, + PDFJS.disableCreateObjectURL); + }; + Object.defineProperty(PDFJS, 'isLittleEndian', { + configurable: true, + get: function PDFJS_isLittleEndian() { + var value = sharedUtil.isLittleEndian(); + return sharedUtil.shadow(PDFJS, 'isLittleEndian', value); + } + }); + PDFJS.removeNullCharacters = sharedUtil.removeNullCharacters; + PDFJS.PasswordResponses = sharedUtil.PasswordResponses; + PDFJS.PasswordException = sharedUtil.PasswordException; + PDFJS.UnknownErrorException = sharedUtil.UnknownErrorException; + PDFJS.InvalidPDFException = sharedUtil.InvalidPDFException; + PDFJS.MissingPDFException = sharedUtil.MissingPDFException; + PDFJS.UnexpectedResponseException = sharedUtil.UnexpectedResponseException; + PDFJS.Util = sharedUtil.Util; + PDFJS.PageViewport = sharedUtil.PageViewport; + PDFJS.createPromiseCapability = sharedUtil.createPromiseCapability; + + exports.globalScope = globalScope; + exports.isWorker = isWorker; + exports.PDFJS = globalScope.PDFJS; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayDOMUtils = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayGlobal); + } +}(this, function (exports, sharedUtil, displayGlobal) { + +var deprecated = sharedUtil.deprecated; +var removeNullCharacters = sharedUtil.removeNullCharacters; +var shadow = sharedUtil.shadow; +var warn = sharedUtil.warn; +var PDFJS = displayGlobal.PDFJS; + +/** + * Optimised CSS custom property getter/setter. + * @class + */ +var CustomStyle = (function CustomStyleClosure() { + + // As noted on: http://www.zachstronaut.com/posts/2009/02/17/ + // animate-css-transforms-firefox-webkit.html + // in some versions of IE9 it is critical that ms appear in this list + // before Moz + var prefixes = ['ms', 'Moz', 'Webkit', 'O']; + var _cache = Object.create(null); + + function CustomStyle() {} + + CustomStyle.getProp = function get(propName, element) { + // check cache only when no element is given + if (arguments.length === 1 && typeof _cache[propName] === 'string') { + return _cache[propName]; + } + + element = element || document.documentElement; + var style = element.style, prefixed, uPropName; + + // test standard property first + if (typeof style[propName] === 'string') { + return (_cache[propName] = propName); + } + + // capitalize + uPropName = propName.charAt(0).toUpperCase() + propName.slice(1); + + // test vendor specific properties + for (var i = 0, l = prefixes.length; i < l; i++) { + prefixed = prefixes[i] + uPropName; + if (typeof style[prefixed] === 'string') { + return (_cache[propName] = prefixed); + } + } + + //if all fails then set to undefined + return (_cache[propName] = 'undefined'); + }; + + CustomStyle.setProp = function set(propName, element, str) { + var prop = this.getProp(propName); + if (prop !== 'undefined') { + element.style[prop] = str; + } + }; + + return CustomStyle; +})(); + +PDFJS.CustomStyle = CustomStyle; + + // Lazy test if the userAgent support CanvasTypedArrays +function hasCanvasTypedArrays() { + var canvas = document.createElement('canvas'); + canvas.width = canvas.height = 1; + var ctx = canvas.getContext('2d'); + var imageData = ctx.createImageData(1, 1); + return (typeof imageData.data.buffer !== 'undefined'); +} + +Object.defineProperty(PDFJS, 'hasCanvasTypedArrays', { + configurable: true, + get: function PDFJS_hasCanvasTypedArrays() { + return shadow(PDFJS, 'hasCanvasTypedArrays', hasCanvasTypedArrays()); + } +}); + +var LinkTarget = { + NONE: 0, // Default value. + SELF: 1, + BLANK: 2, + PARENT: 3, + TOP: 4, +}; + +PDFJS.LinkTarget = LinkTarget; + +var LinkTargetStringMap = [ + '', + '_self', + '_blank', + '_parent', + '_top' +]; + +function isExternalLinkTargetSet() { + if (PDFJS.openExternalLinksInNewWindow) { + deprecated('PDFJS.openExternalLinksInNewWindow, please use ' + + '"PDFJS.externalLinkTarget = PDFJS.LinkTarget.BLANK" instead.'); + if (PDFJS.externalLinkTarget === LinkTarget.NONE) { + PDFJS.externalLinkTarget = LinkTarget.BLANK; + } + // Reset the deprecated parameter, to suppress further warnings. + PDFJS.openExternalLinksInNewWindow = false; + } + switch (PDFJS.externalLinkTarget) { + case LinkTarget.NONE: + return false; + case LinkTarget.SELF: + case LinkTarget.BLANK: + case LinkTarget.PARENT: + case LinkTarget.TOP: + return true; + } + warn('PDFJS.externalLinkTarget is invalid: ' + PDFJS.externalLinkTarget); + // Reset the external link target, to suppress further warnings. + PDFJS.externalLinkTarget = LinkTarget.NONE; + return false; +} +PDFJS.isExternalLinkTargetSet = isExternalLinkTargetSet; + +/** + * Adds various attributes (href, title, target, rel) to hyperlinks. + * @param {HTMLLinkElement} link - The link element. + * @param {Object} params - An object with the properties: + * @param {string} params.url - An absolute URL. + */ +function addLinkAttributes(link, params) { + var url = params && params.url; + link.href = link.title = (url ? removeNullCharacters(url) : ''); + + if (url) { + if (isExternalLinkTargetSet()) { + link.target = LinkTargetStringMap[PDFJS.externalLinkTarget]; + } + // Strip referrer from the URL. + link.rel = PDFJS.externalLinkRel; + } +} +PDFJS.addLinkAttributes = addLinkAttributes; + +// Gets the file name from a given URL. +function getFilenameFromUrl(url) { + var anchor = url.indexOf('#'); + var query = url.indexOf('?'); + var end = Math.min( + anchor > 0 ? anchor : url.length, + query > 0 ? query : url.length); + return url.substring(url.lastIndexOf('/', end) + 1, end); +} +PDFJS.getFilenameFromUrl = getFilenameFromUrl; + +exports.CustomStyle = CustomStyle; +exports.addLinkAttributes = addLinkAttributes; +exports.isExternalLinkTargetSet = isExternalLinkTargetSet; +exports.getFilenameFromUrl = getFilenameFromUrl; +exports.LinkTarget = LinkTarget; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayFontLoader = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayGlobal); + } +}(this, function (exports, sharedUtil, displayGlobal) { + +var assert = sharedUtil.assert; +var bytesToString = sharedUtil.bytesToString; +var string32 = sharedUtil.string32; +var shadow = sharedUtil.shadow; +var warn = sharedUtil.warn; + +var PDFJS = displayGlobal.PDFJS; +var globalScope = displayGlobal.globalScope; +var isWorker = displayGlobal.isWorker; + +function FontLoader(docId) { + this.docId = docId; + this.styleElement = null; + this.nativeFontFaces = []; + this.loadTestFontId = 0; + this.loadingContext = { + requests: [], + nextRequestId: 0 + }; +} +FontLoader.prototype = { + insertRule: function fontLoaderInsertRule(rule) { + var styleElement = this.styleElement; + if (!styleElement) { + styleElement = this.styleElement = document.createElement('style'); + styleElement.id = 'PDFJS_FONT_STYLE_TAG_' + this.docId; + document.documentElement.getElementsByTagName('head')[0].appendChild( + styleElement); + } + + var styleSheet = styleElement.sheet; + styleSheet.insertRule(rule, styleSheet.cssRules.length); + }, + + clear: function fontLoaderClear() { + var styleElement = this.styleElement; + if (styleElement) { + styleElement.parentNode.removeChild(styleElement); + styleElement = this.styleElement = null; + } + this.nativeFontFaces.forEach(function(nativeFontFace) { + document.fonts.delete(nativeFontFace); + }); + this.nativeFontFaces.length = 0; + }, + get loadTestFont() { + // This is a CFF font with 1 glyph for '.' that fills its entire width and + // height. + return shadow(this, 'loadTestFont', atob( + 'T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQAFQ' + + 'AABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQA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+ + 'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAA' + + 'AAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAAAAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgc' + + 'A/gXBIwMAYuL+nz5tQXkD5j3CBLnEQACAQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWF' + + 'hYWFhYWFhYAAABAQAADwACAQEEE/t3Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQA' + + 'AAAAAAABAAAAAMmJbzEAAAAAzgTjFQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAg' + + 'ABAAAAAAAAAAAD6AAAAAAAAA==' + )); + }, + + addNativeFontFace: function fontLoader_addNativeFontFace(nativeFontFace) { + this.nativeFontFaces.push(nativeFontFace); + document.fonts.add(nativeFontFace); + }, + + bind: function fontLoaderBind(fonts, callback) { + assert(!isWorker, 'bind() shall be called from main thread'); + + var rules = []; + var fontsToLoad = []; + var fontLoadPromises = []; + var getNativeFontPromise = function(nativeFontFace) { + // Return a promise that is always fulfilled, even when the font fails to + // load. + return nativeFontFace.loaded.catch(function(e) { + warn('Failed to load font "' + nativeFontFace.family + '": ' + e); + }); + }; + for (var i = 0, ii = fonts.length; i < ii; i++) { + var font = fonts[i]; + + // Add the font to the DOM only once or skip if the font + // is already loaded. + if (font.attached || font.loading === false) { + continue; + } + font.attached = true; + + if (FontLoader.isFontLoadingAPISupported) { + var nativeFontFace = font.createNativeFontFace(); + if (nativeFontFace) { + this.addNativeFontFace(nativeFontFace); + fontLoadPromises.push(getNativeFontPromise(nativeFontFace)); + } + } else { + var rule = font.createFontFaceRule(); + if (rule) { + this.insertRule(rule); + rules.push(rule); + fontsToLoad.push(font); + } + } + } + + var request = this.queueLoadingCallback(callback); + if (FontLoader.isFontLoadingAPISupported) { + Promise.all(fontLoadPromises).then(function() { + request.complete(); + }); + } else if (rules.length > 0 && !FontLoader.isSyncFontLoadingSupported) { + this.prepareFontLoadEvent(rules, fontsToLoad, request); + } else { + request.complete(); + } + }, + + queueLoadingCallback: function FontLoader_queueLoadingCallback(callback) { + function LoadLoader_completeRequest() { + assert(!request.end, 'completeRequest() cannot be called twice'); + request.end = Date.now(); + + // sending all completed requests in order how they were queued + while (context.requests.length > 0 && context.requests[0].end) { + var otherRequest = context.requests.shift(); + setTimeout(otherRequest.callback, 0); + } + } + + var context = this.loadingContext; + var requestId = 'pdfjs-font-loading-' + (context.nextRequestId++); + var request = { + id: requestId, + complete: LoadLoader_completeRequest, + callback: callback, + started: Date.now() + }; + context.requests.push(request); + return request; + }, + + prepareFontLoadEvent: function fontLoaderPrepareFontLoadEvent(rules, + fonts, + request) { + /** Hack begin */ + // There's currently no event when a font has finished downloading so the + // following code is a dirty hack to 'guess' when a font is + // ready. It's assumed fonts are loaded in order, so add a known test + // font after the desired fonts and then test for the loading of that + // test font. + + function int32(data, offset) { + return (data.charCodeAt(offset) << 24) | + (data.charCodeAt(offset + 1) << 16) | + (data.charCodeAt(offset + 2) << 8) | + (data.charCodeAt(offset + 3) & 0xff); + } + + function spliceString(s, offset, remove, insert) { + var chunk1 = s.substr(0, offset); + var chunk2 = s.substr(offset + remove); + return chunk1 + insert + chunk2; + } + + var i, ii; + + var canvas = document.createElement('canvas'); + canvas.width = 1; + canvas.height = 1; + var ctx = canvas.getContext('2d'); + + var called = 0; + function isFontReady(name, callback) { + called++; + // With setTimeout clamping this gives the font ~100ms to load. + if(called > 30) { + warn('Load test font never loaded.'); + callback(); + return; + } + ctx.font = '30px ' + name; + ctx.fillText('.', 0, 20); + var imageData = ctx.getImageData(0, 0, 1, 1); + if (imageData.data[3] > 0) { + callback(); + return; + } + setTimeout(isFontReady.bind(null, name, callback)); + } + + var loadTestFontId = 'lt' + Date.now() + this.loadTestFontId++; + // Chromium seems to cache fonts based on a hash of the actual font data, + // so the font must be modified for each load test else it will appear to + // be loaded already. + // TODO: This could maybe be made faster by avoiding the btoa of the full + // font by splitting it in chunks before hand and padding the font id. + var data = this.loadTestFont; + var COMMENT_OFFSET = 976; // has to be on 4 byte boundary (for checksum) + data = spliceString(data, COMMENT_OFFSET, loadTestFontId.length, + loadTestFontId); + // CFF checksum is important for IE, adjusting it + var CFF_CHECKSUM_OFFSET = 16; + var XXXX_VALUE = 0x58585858; // the "comment" filled with 'X' + var checksum = int32(data, CFF_CHECKSUM_OFFSET); + for (i = 0, ii = loadTestFontId.length - 3; i < ii; i += 4) { + checksum = (checksum - XXXX_VALUE + int32(loadTestFontId, i)) | 0; + } + if (i < loadTestFontId.length) { // align to 4 bytes boundary + checksum = (checksum - XXXX_VALUE + + int32(loadTestFontId + 'XXX', i)) | 0; + } + data = spliceString(data, CFF_CHECKSUM_OFFSET, 4, string32(checksum)); + + var url = 'url(data:font/opentype;base64,' + btoa(data) + ');'; + var rule = '@font-face { font-family:"' + loadTestFontId + '";src:' + + url + '}'; + this.insertRule(rule); + + var names = []; + for (i = 0, ii = fonts.length; i < ii; i++) { + names.push(fonts[i].loadedName); + } + names.push(loadTestFontId); + + var div = document.createElement('div'); + div.setAttribute('style', + 'visibility: hidden;' + + 'width: 10px; height: 10px;' + + 'position: absolute; top: 0px; left: 0px;'); + for (i = 0, ii = names.length; i < ii; ++i) { + var span = document.createElement('span'); + span.textContent = 'Hi'; + span.style.fontFamily = names[i]; + div.appendChild(span); + } + document.body.appendChild(div); + + isFontReady(loadTestFontId, function() { + document.body.removeChild(div); + request.complete(); + }); + /** Hack end */ + } +}; +FontLoader.isFontLoadingAPISupported = (!isWorker && + typeof document !== 'undefined' && !!document.fonts); +Object.defineProperty(FontLoader, 'isSyncFontLoadingSupported', { + get: function () { + var supported = false; + + // User agent string sniffing is bad, but there is no reliable way to tell + // if font is fully loaded and ready to be used with canvas. + var userAgent = window.navigator.userAgent; + var m = /Mozilla\/5.0.*?rv:(\d+).*? Gecko/.exec(userAgent); + if (m && m[1] >= 14) { + supported = true; + } + // TODO other browsers + if (userAgent === 'node') { + supported = true; + } + return shadow(FontLoader, 'isSyncFontLoadingSupported', supported); + }, + enumerable: true, + configurable: true +}); + +var FontFaceObject = (function FontFaceObjectClosure() { + function FontFaceObject(translatedData) { + this.compiledGlyphs = Object.create(null); + // importing translated data + for (var i in translatedData) { + this[i] = translatedData[i]; + } + } + Object.defineProperty(FontFaceObject, 'isEvalSupported', { + get: function () { + var evalSupport = false; + if (PDFJS.isEvalSupported) { + try { + /* jshint evil: true */ + new Function(''); + evalSupport = true; + } catch (e) {} + } + return shadow(this, 'isEvalSupported', evalSupport); + }, + enumerable: true, + configurable: true + }); + FontFaceObject.prototype = { + createNativeFontFace: function FontFaceObject_createNativeFontFace() { + if (!this.data) { + return null; + } + + if (PDFJS.disableFontFace) { + this.disableFontFace = true; + return null; + } + + var nativeFontFace = new FontFace(this.loadedName, this.data, {}); + + if (PDFJS.pdfBug && 'FontInspector' in globalScope && + globalScope['FontInspector'].enabled) { + globalScope['FontInspector'].fontAdded(this); + } + return nativeFontFace; + }, + + createFontFaceRule: function FontFaceObject_createFontFaceRule() { + if (!this.data) { + return null; + } + + if (PDFJS.disableFontFace) { + this.disableFontFace = true; + return null; + } + + var data = bytesToString(new Uint8Array(this.data)); + var fontName = this.loadedName; + + // Add the font-face rule to the document + var url = ('url(data:' + this.mimetype + ';base64,' + + window.btoa(data) + ');'); + var rule = '@font-face { font-family:"' + fontName + '";src:' + url + '}'; + + if (PDFJS.pdfBug && 'FontInspector' in globalScope && + globalScope['FontInspector'].enabled) { + globalScope['FontInspector'].fontAdded(this, url); + } + + return rule; + }, + + getPathGenerator: + function FontFaceObject_getPathGenerator(objs, character) { + if (!(character in this.compiledGlyphs)) { + var cmds = objs.get(this.loadedName + '_path_' + character); + var current, i, len; + + // If we can, compile cmds into JS for MAXIMUM SPEED + if (FontFaceObject.isEvalSupported) { + var args, js = ''; + for (i = 0, len = cmds.length; i < len; i++) { + current = cmds[i]; + + if (current.args !== undefined) { + args = current.args.join(','); + } else { + args = ''; + } + + js += 'c.' + current.cmd + '(' + args + ');\n'; + } + /* jshint -W054 */ + this.compiledGlyphs[character] = new Function('c', 'size', js); + } else { + // But fall back on using Function.prototype.apply() if we're + // blocked from using eval() for whatever reason (like CSP policies) + this.compiledGlyphs[character] = function(c, size) { + for (i = 0, len = cmds.length; i < len; i++) { + current = cmds[i]; + + if (current.cmd === 'scale') { + current.args = [size, -size]; + } + + c[current.cmd].apply(c, current.args); + } + }; + } + } + return this.compiledGlyphs[character]; + } + }; + return FontFaceObject; +})(); + +exports.FontFaceObject = FontFaceObject; +exports.FontLoader = FontLoader; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayMetadata = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayGlobal); + } +}(this, function (exports, sharedUtil, displayGlobal) { + +var error = sharedUtil.error; +var PDFJS = displayGlobal.PDFJS; + +var Metadata = PDFJS.Metadata = (function MetadataClosure() { + function fixMetadata(meta) { + return meta.replace(/>\\376\\377([^<]+)/g, function(all, codes) { + var bytes = codes.replace(/\\([0-3])([0-7])([0-7])/g, + function(code, d1, d2, d3) { + return String.fromCharCode(d1 * 64 + d2 * 8 + d3 * 1); + }); + var chars = ''; + for (var i = 0; i < bytes.length; i += 2) { + var code = bytes.charCodeAt(i) * 256 + bytes.charCodeAt(i + 1); + chars += code >= 32 && code < 127 && code !== 60 && code !== 62 && + code !== 38 && false ? String.fromCharCode(code) : + '&#x' + (0x10000 + code).toString(16).substring(1) + ';'; + } + return '>' + chars; + }); + } + + function Metadata(meta) { + if (typeof meta === 'string') { + // Ghostscript produces invalid metadata + meta = fixMetadata(meta); + + var parser = new DOMParser(); + meta = parser.parseFromString(meta, 'application/xml'); + } else if (!(meta instanceof Document)) { + error('Metadata: Invalid metadata object'); + } + + this.metaDocument = meta; + this.metadata = Object.create(null); + this.parse(); + } + + Metadata.prototype = { + parse: function Metadata_parse() { + var doc = this.metaDocument; + var rdf = doc.documentElement; + + if (rdf.nodeName.toLowerCase() !== 'rdf:rdf') { // Wrapped in + rdf = rdf.firstChild; + while (rdf && rdf.nodeName.toLowerCase() !== 'rdf:rdf') { + rdf = rdf.nextSibling; + } + } + + var nodeName = (rdf) ? rdf.nodeName.toLowerCase() : null; + if (!rdf || nodeName !== 'rdf:rdf' || !rdf.hasChildNodes()) { + return; + } + + var children = rdf.childNodes, desc, entry, name, i, ii, length, iLength; + for (i = 0, length = children.length; i < length; i++) { + desc = children[i]; + if (desc.nodeName.toLowerCase() !== 'rdf:description') { + continue; + } + + for (ii = 0, iLength = desc.childNodes.length; ii < iLength; ii++) { + if (desc.childNodes[ii].nodeName.toLowerCase() !== '#text') { + entry = desc.childNodes[ii]; + name = entry.nodeName.toLowerCase(); + this.metadata[name] = entry.textContent.trim(); + } + } + } + }, + + get: function Metadata_get(name) { + return this.metadata[name] || null; + }, + + has: function Metadata_has(name) { + return typeof this.metadata[name] !== 'undefined'; + } + }; + + return Metadata; +})(); + +exports.Metadata = Metadata; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplaySVG = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayGlobal); + } +}(this, function (exports, sharedUtil, displayGlobal) { + +var FONT_IDENTITY_MATRIX = sharedUtil.FONT_IDENTITY_MATRIX; +var IDENTITY_MATRIX = sharedUtil.IDENTITY_MATRIX; +var ImageKind = sharedUtil.ImageKind; +var OPS = sharedUtil.OPS; +var Util = sharedUtil.Util; +var isNum = sharedUtil.isNum; +var isArray = sharedUtil.isArray; +var warn = sharedUtil.warn; +var PDFJS = displayGlobal.PDFJS; + +var SVG_DEFAULTS = { + fontStyle: 'normal', + fontWeight: 'normal', + fillColor: '#000000' +}; + +var convertImgDataToPng = (function convertImgDataToPngClosure() { + var PNG_HEADER = + new Uint8Array([0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a]); + + var CHUNK_WRAPPER_SIZE = 12; + + var crcTable = new Int32Array(256); + for (var i = 0; i < 256; i++) { + var c = i; + for (var h = 0; h < 8; h++) { + if (c & 1) { + c = 0xedB88320 ^ ((c >> 1) & 0x7fffffff); + } else { + c = (c >> 1) & 0x7fffffff; + } + } + crcTable[i] = c; + } + + function crc32(data, start, end) { + var crc = -1; + for (var i = start; i < end; i++) { + var a = (crc ^ data[i]) & 0xff; + var b = crcTable[a]; + crc = (crc >>> 8) ^ b; + } + return crc ^ -1; + } + + function writePngChunk(type, body, data, offset) { + var p = offset; + var len = body.length; + + data[p] = len >> 24 & 0xff; + data[p + 1] = len >> 16 & 0xff; + data[p + 2] = len >> 8 & 0xff; + data[p + 3] = len & 0xff; + p += 4; + + data[p] = type.charCodeAt(0) & 0xff; + data[p + 1] = type.charCodeAt(1) & 0xff; + data[p + 2] = type.charCodeAt(2) & 0xff; + data[p + 3] = type.charCodeAt(3) & 0xff; + p += 4; + + data.set(body, p); + p += body.length; + + var crc = crc32(data, offset + 4, p); + + data[p] = crc >> 24 & 0xff; + data[p + 1] = crc >> 16 & 0xff; + data[p + 2] = crc >> 8 & 0xff; + data[p + 3] = crc & 0xff; + } + + function adler32(data, start, end) { + var a = 1; + var b = 0; + for (var i = start; i < end; ++i) { + a = (a + (data[i] & 0xff)) % 65521; + b = (b + a) % 65521; + } + return (b << 16) | a; + } + + function encode(imgData, kind) { + var width = imgData.width; + var height = imgData.height; + var bitDepth, colorType, lineSize; + var bytes = imgData.data; + + switch (kind) { + case ImageKind.GRAYSCALE_1BPP: + colorType = 0; + bitDepth = 1; + lineSize = (width + 7) >> 3; + break; + case ImageKind.RGB_24BPP: + colorType = 2; + bitDepth = 8; + lineSize = width * 3; + break; + case ImageKind.RGBA_32BPP: + colorType = 6; + bitDepth = 8; + lineSize = width * 4; + break; + default: + throw new Error('invalid format'); + } + + // prefix every row with predictor 0 + var literals = new Uint8Array((1 + lineSize) * height); + var offsetLiterals = 0, offsetBytes = 0; + var y, i; + for (y = 0; y < height; ++y) { + literals[offsetLiterals++] = 0; // no prediction + literals.set(bytes.subarray(offsetBytes, offsetBytes + lineSize), + offsetLiterals); + offsetBytes += lineSize; + offsetLiterals += lineSize; + } + + if (kind === ImageKind.GRAYSCALE_1BPP) { + // inverting for B/W + offsetLiterals = 0; + for (y = 0; y < height; y++) { + offsetLiterals++; // skipping predictor + for (i = 0; i < lineSize; i++) { + literals[offsetLiterals++] ^= 0xFF; + } + } + } + + var ihdr = new Uint8Array([ + width >> 24 & 0xff, + width >> 16 & 0xff, + width >> 8 & 0xff, + width & 0xff, + height >> 24 & 0xff, + height >> 16 & 0xff, + height >> 8 & 0xff, + height & 0xff, + bitDepth, // bit depth + colorType, // color type + 0x00, // compression method + 0x00, // filter method + 0x00 // interlace method + ]); + + var len = literals.length; + var maxBlockLength = 0xFFFF; + + var deflateBlocks = Math.ceil(len / maxBlockLength); + var idat = new Uint8Array(2 + len + deflateBlocks * 5 + 4); + var pi = 0; + idat[pi++] = 0x78; // compression method and flags + idat[pi++] = 0x9c; // flags + + var pos = 0; + while (len > maxBlockLength) { + // writing non-final DEFLATE blocks type 0 and length of 65535 + idat[pi++] = 0x00; + idat[pi++] = 0xff; + idat[pi++] = 0xff; + idat[pi++] = 0x00; + idat[pi++] = 0x00; + idat.set(literals.subarray(pos, pos + maxBlockLength), pi); + pi += maxBlockLength; + pos += maxBlockLength; + len -= maxBlockLength; + } + + // writing non-final DEFLATE blocks type 0 + idat[pi++] = 0x01; + idat[pi++] = len & 0xff; + idat[pi++] = len >> 8 & 0xff; + idat[pi++] = (~len & 0xffff) & 0xff; + idat[pi++] = (~len & 0xffff) >> 8 & 0xff; + idat.set(literals.subarray(pos), pi); + pi += literals.length - pos; + + var adler = adler32(literals, 0, literals.length); // checksum + idat[pi++] = adler >> 24 & 0xff; + idat[pi++] = adler >> 16 & 0xff; + idat[pi++] = adler >> 8 & 0xff; + idat[pi++] = adler & 0xff; + + // PNG will consists: header, IHDR+data, IDAT+data, and IEND. + var pngLength = PNG_HEADER.length + (CHUNK_WRAPPER_SIZE * 3) + + ihdr.length + idat.length; + var data = new Uint8Array(pngLength); + var offset = 0; + data.set(PNG_HEADER, offset); + offset += PNG_HEADER.length; + writePngChunk('IHDR', ihdr, data, offset); + offset += CHUNK_WRAPPER_SIZE + ihdr.length; + writePngChunk('IDATA', idat, data, offset); + offset += CHUNK_WRAPPER_SIZE + idat.length; + writePngChunk('IEND', new Uint8Array(0), data, offset); + + return PDFJS.createObjectURL(data, 'image/png'); + } + + return function convertImgDataToPng(imgData) { + var kind = (imgData.kind === undefined ? + ImageKind.GRAYSCALE_1BPP : imgData.kind); + return encode(imgData, kind); + }; +})(); + +var SVGExtraState = (function SVGExtraStateClosure() { + function SVGExtraState() { + this.fontSizeScale = 1; + this.fontWeight = SVG_DEFAULTS.fontWeight; + this.fontSize = 0; + + this.textMatrix = IDENTITY_MATRIX; + this.fontMatrix = FONT_IDENTITY_MATRIX; + this.leading = 0; + + // Current point (in user coordinates) + this.x = 0; + this.y = 0; + + // Start of text line (in text coordinates) + this.lineX = 0; + this.lineY = 0; + + // Character and word spacing + this.charSpacing = 0; + this.wordSpacing = 0; + this.textHScale = 1; + this.textRise = 0; + + // Default foreground and background colors + this.fillColor = SVG_DEFAULTS.fillColor; + this.strokeColor = '#000000'; + + this.fillAlpha = 1; + this.strokeAlpha = 1; + this.lineWidth = 1; + this.lineJoin = ''; + this.lineCap = ''; + this.miterLimit = 0; + + this.dashArray = []; + this.dashPhase = 0; + + this.dependencies = []; + + // Clipping + this.clipId = ''; + this.pendingClip = false; + + this.maskId = ''; + } + + SVGExtraState.prototype = { + clone: function SVGExtraState_clone() { + return Object.create(this); + }, + setCurrentPoint: function SVGExtraState_setCurrentPoint(x, y) { + this.x = x; + this.y = y; + } + }; + return SVGExtraState; +})(); + +var SVGGraphics = (function SVGGraphicsClosure() { + function createScratchSVG(width, height) { + var NS = 'http://www.w3.org/2000/svg'; + var svg = document.createElementNS(NS, 'svg:svg'); + svg.setAttributeNS(null, 'version', '1.1'); + svg.setAttributeNS(null, 'width', width + 'px'); + svg.setAttributeNS(null, 'height', height + 'px'); + svg.setAttributeNS(null, 'viewBox', '0 0 ' + width + ' ' + height); + return svg; + } + + function opListToTree(opList) { + var opTree = []; + var tmp = []; + var opListLen = opList.length; + + for (var x = 0; x < opListLen; x++) { + if (opList[x].fn === 'save') { + opTree.push({'fnId': 92, 'fn': 'group', 'items': []}); + tmp.push(opTree); + opTree = opTree[opTree.length - 1].items; + continue; + } + + if(opList[x].fn === 'restore') { + opTree = tmp.pop(); + } else { + opTree.push(opList[x]); + } + } + return opTree; + } + + /** + * Formats float number. + * @param value {number} number to format. + * @returns {string} + */ + function pf(value) { + if (value === (value | 0)) { // integer number + return value.toString(); + } + var s = value.toFixed(10); + var i = s.length - 1; + if (s[i] !== '0') { + return s; + } + // removing trailing zeros + do { + i--; + } while (s[i] === '0'); + return s.substr(0, s[i] === '.' ? i : i + 1); + } + + /** + * Formats transform matrix. The standard rotation, scale and translate + * matrices are replaced by their shorter forms, and for identity matrix + * returns empty string to save the memory. + * @param m {Array} matrix to format. + * @returns {string} + */ + function pm(m) { + if (m[4] === 0 && m[5] === 0) { + if (m[1] === 0 && m[2] === 0) { + if (m[0] === 1 && m[3] === 1) { + return ''; + } + return 'scale(' + pf(m[0]) + ' ' + pf(m[3]) + ')'; + } + if (m[0] === m[3] && m[1] === -m[2]) { + var a = Math.acos(m[0]) * 180 / Math.PI; + return 'rotate(' + pf(a) + ')'; + } + } else { + if (m[0] === 1 && m[1] === 0 && m[2] === 0 && m[3] === 1) { + return 'translate(' + pf(m[4]) + ' ' + pf(m[5]) + ')'; + } + } + return 'matrix(' + pf(m[0]) + ' ' + pf(m[1]) + ' ' + pf(m[2]) + ' ' + + pf(m[3]) + ' ' + pf(m[4]) + ' ' + pf(m[5]) + ')'; + } + + function SVGGraphics(commonObjs, objs) { + this.current = new SVGExtraState(); + this.transformMatrix = IDENTITY_MATRIX; // Graphics state matrix + this.transformStack = []; + this.extraStack = []; + this.commonObjs = commonObjs; + this.objs = objs; + this.pendingEOFill = false; + + this.embedFonts = false; + this.embeddedFonts = Object.create(null); + this.cssStyle = null; + } + + var NS = 'http://www.w3.org/2000/svg'; + var XML_NS = 'http://www.w3.org/XML/1998/namespace'; + var XLINK_NS = 'http://www.w3.org/1999/xlink'; + var LINE_CAP_STYLES = ['butt', 'round', 'square']; + var LINE_JOIN_STYLES = ['miter', 'round', 'bevel']; + var clipCount = 0; + var maskCount = 0; + + SVGGraphics.prototype = { + save: function SVGGraphics_save() { + this.transformStack.push(this.transformMatrix); + var old = this.current; + this.extraStack.push(old); + this.current = old.clone(); + }, + + restore: function SVGGraphics_restore() { + this.transformMatrix = this.transformStack.pop(); + this.current = this.extraStack.pop(); + + this.tgrp = document.createElementNS(NS, 'svg:g'); + this.tgrp.setAttributeNS(null, 'transform', pm(this.transformMatrix)); + this.pgrp.appendChild(this.tgrp); + }, + + group: function SVGGraphics_group(items) { + this.save(); + this.executeOpTree(items); + this.restore(); + }, + + loadDependencies: function SVGGraphics_loadDependencies(operatorList) { + var fnArray = operatorList.fnArray; + var fnArrayLen = fnArray.length; + var argsArray = operatorList.argsArray; + + var self = this; + for (var i = 0; i < fnArrayLen; i++) { + if (OPS.dependency === fnArray[i]) { + var deps = argsArray[i]; + for (var n = 0, nn = deps.length; n < nn; n++) { + var obj = deps[n]; + var common = obj.substring(0, 2) === 'g_'; + var promise; + if (common) { + promise = new Promise(function(resolve) { + self.commonObjs.get(obj, resolve); + }); + } else { + promise = new Promise(function(resolve) { + self.objs.get(obj, resolve); + }); + } + this.current.dependencies.push(promise); + } + } + } + return Promise.all(this.current.dependencies); + }, + + transform: function SVGGraphics_transform(a, b, c, d, e, f) { + var transformMatrix = [a, b, c, d, e, f]; + this.transformMatrix = PDFJS.Util.transform(this.transformMatrix, + transformMatrix); + + this.tgrp = document.createElementNS(NS, 'svg:g'); + this.tgrp.setAttributeNS(null, 'transform', pm(this.transformMatrix)); + }, + + getSVG: function SVGGraphics_getSVG(operatorList, viewport) { + this.svg = createScratchSVG(viewport.width, viewport.height); + this.viewport = viewport; + + return this.loadDependencies(operatorList).then(function () { + this.transformMatrix = IDENTITY_MATRIX; + this.pgrp = document.createElementNS(NS, 'svg:g'); // Parent group + this.pgrp.setAttributeNS(null, 'transform', pm(viewport.transform)); + this.tgrp = document.createElementNS(NS, 'svg:g'); // Transform group + this.tgrp.setAttributeNS(null, 'transform', pm(this.transformMatrix)); + this.defs = document.createElementNS(NS, 'svg:defs'); + this.pgrp.appendChild(this.defs); + this.pgrp.appendChild(this.tgrp); + this.svg.appendChild(this.pgrp); + var opTree = this.convertOpList(operatorList); + this.executeOpTree(opTree); + return this.svg; + }.bind(this)); + }, + + convertOpList: function SVGGraphics_convertOpList(operatorList) { + var argsArray = operatorList.argsArray; + var fnArray = operatorList.fnArray; + var fnArrayLen = fnArray.length; + var REVOPS = []; + var opList = []; + + for (var op in OPS) { + REVOPS[OPS[op]] = op; + } + + for (var x = 0; x < fnArrayLen; x++) { + var fnId = fnArray[x]; + opList.push({'fnId' : fnId, 'fn': REVOPS[fnId], 'args': argsArray[x]}); + } + return opListToTree(opList); + }, + + executeOpTree: function SVGGraphics_executeOpTree(opTree) { + var opTreeLen = opTree.length; + for(var x = 0; x < opTreeLen; x++) { + var fn = opTree[x].fn; + var fnId = opTree[x].fnId; + var args = opTree[x].args; + + switch (fnId | 0) { + case OPS.beginText: + this.beginText(); + break; + case OPS.setLeading: + this.setLeading(args); + break; + case OPS.setLeadingMoveText: + this.setLeadingMoveText(args[0], args[1]); + break; + case OPS.setFont: + this.setFont(args); + break; + case OPS.showText: + this.showText(args[0]); + break; + case OPS.showSpacedText: + this.showText(args[0]); + break; + case OPS.endText: + this.endText(); + break; + case OPS.moveText: + this.moveText(args[0], args[1]); + break; + case OPS.setCharSpacing: + this.setCharSpacing(args[0]); + break; + case OPS.setWordSpacing: + this.setWordSpacing(args[0]); + break; + case OPS.setHScale: + this.setHScale(args[0]); + break; + case OPS.setTextMatrix: + this.setTextMatrix(args[0], args[1], args[2], + args[3], args[4], args[5]); + break; + case OPS.setLineWidth: + this.setLineWidth(args[0]); + break; + case OPS.setLineJoin: + this.setLineJoin(args[0]); + break; + case OPS.setLineCap: + this.setLineCap(args[0]); + break; + case OPS.setMiterLimit: + this.setMiterLimit(args[0]); + break; + case OPS.setFillRGBColor: + this.setFillRGBColor(args[0], args[1], args[2]); + break; + case OPS.setStrokeRGBColor: + this.setStrokeRGBColor(args[0], args[1], args[2]); + break; + case OPS.setDash: + this.setDash(args[0], args[1]); + break; + case OPS.setGState: + this.setGState(args[0]); + break; + case OPS.fill: + this.fill(); + break; + case OPS.eoFill: + this.eoFill(); + break; + case OPS.stroke: + this.stroke(); + break; + case OPS.fillStroke: + this.fillStroke(); + break; + case OPS.eoFillStroke: + this.eoFillStroke(); + break; + case OPS.clip: + this.clip('nonzero'); + break; + case OPS.eoClip: + this.clip('evenodd'); + break; + case OPS.paintSolidColorImageMask: + this.paintSolidColorImageMask(); + break; + case OPS.paintJpegXObject: + this.paintJpegXObject(args[0], args[1], args[2]); + break; + case OPS.paintImageXObject: + this.paintImageXObject(args[0]); + break; + case OPS.paintInlineImageXObject: + this.paintInlineImageXObject(args[0]); + break; + case OPS.paintImageMaskXObject: + this.paintImageMaskXObject(args[0]); + break; + case OPS.paintFormXObjectBegin: + this.paintFormXObjectBegin(args[0], args[1]); + break; + case OPS.paintFormXObjectEnd: + this.paintFormXObjectEnd(); + break; + case OPS.closePath: + this.closePath(); + break; + case OPS.closeStroke: + this.closeStroke(); + break; + case OPS.closeFillStroke: + this.closeFillStroke(); + break; + case OPS.nextLine: + this.nextLine(); + break; + case OPS.transform: + this.transform(args[0], args[1], args[2], args[3], + args[4], args[5]); + break; + case OPS.constructPath: + this.constructPath(args[0], args[1]); + break; + case OPS.endPath: + this.endPath(); + break; + case 92: + this.group(opTree[x].items); + break; + default: + warn('Unimplemented method '+ fn); + break; + } + } + }, + + setWordSpacing: function SVGGraphics_setWordSpacing(wordSpacing) { + this.current.wordSpacing = wordSpacing; + }, + + setCharSpacing: function SVGGraphics_setCharSpacing(charSpacing) { + this.current.charSpacing = charSpacing; + }, + + nextLine: function SVGGraphics_nextLine() { + this.moveText(0, this.current.leading); + }, + + setTextMatrix: function SVGGraphics_setTextMatrix(a, b, c, d, e, f) { + var current = this.current; + this.current.textMatrix = this.current.lineMatrix = [a, b, c, d, e, f]; + + this.current.x = this.current.lineX = 0; + this.current.y = this.current.lineY = 0; + + current.xcoords = []; + current.tspan = document.createElementNS(NS, 'svg:tspan'); + current.tspan.setAttributeNS(null, 'font-family', current.fontFamily); + current.tspan.setAttributeNS(null, 'font-size', + pf(current.fontSize) + 'px'); + current.tspan.setAttributeNS(null, 'y', pf(-current.y)); + + current.txtElement = document.createElementNS(NS, 'svg:text'); + current.txtElement.appendChild(current.tspan); + }, + + beginText: function SVGGraphics_beginText() { + this.current.x = this.current.lineX = 0; + this.current.y = this.current.lineY = 0; + this.current.textMatrix = IDENTITY_MATRIX; + this.current.lineMatrix = IDENTITY_MATRIX; + this.current.tspan = document.createElementNS(NS, 'svg:tspan'); + this.current.txtElement = document.createElementNS(NS, 'svg:text'); + this.current.txtgrp = document.createElementNS(NS, 'svg:g'); + this.current.xcoords = []; + }, + + moveText: function SVGGraphics_moveText(x, y) { + var current = this.current; + this.current.x = this.current.lineX += x; + this.current.y = this.current.lineY += y; + + current.xcoords = []; + current.tspan = document.createElementNS(NS, 'svg:tspan'); + current.tspan.setAttributeNS(null, 'font-family', current.fontFamily); + current.tspan.setAttributeNS(null, 'font-size', + pf(current.fontSize) + 'px'); + current.tspan.setAttributeNS(null, 'y', pf(-current.y)); + }, + + showText: function SVGGraphics_showText(glyphs) { + var current = this.current; + var font = current.font; + var fontSize = current.fontSize; + + if (fontSize === 0) { + return; + } + + var charSpacing = current.charSpacing; + var wordSpacing = current.wordSpacing; + var fontDirection = current.fontDirection; + var textHScale = current.textHScale * fontDirection; + var glyphsLength = glyphs.length; + var vertical = font.vertical; + var widthAdvanceScale = fontSize * current.fontMatrix[0]; + + var x = 0, i; + for (i = 0; i < glyphsLength; ++i) { + var glyph = glyphs[i]; + if (glyph === null) { + // word break + x += fontDirection * wordSpacing; + continue; + } else if (isNum(glyph)) { + x += -glyph * fontSize * 0.001; + continue; + } + current.xcoords.push(current.x + x * textHScale); + + var width = glyph.width; + var character = glyph.fontChar; + var charWidth = width * widthAdvanceScale + charSpacing * fontDirection; + x += charWidth; + + current.tspan.textContent += character; + } + if (vertical) { + current.y -= x * textHScale; + } else { + current.x += x * textHScale; + } + + current.tspan.setAttributeNS(null, 'x', + current.xcoords.map(pf).join(' ')); + current.tspan.setAttributeNS(null, 'y', pf(-current.y)); + current.tspan.setAttributeNS(null, 'font-family', current.fontFamily); + current.tspan.setAttributeNS(null, 'font-size', + pf(current.fontSize) + 'px'); + if (current.fontStyle !== SVG_DEFAULTS.fontStyle) { + current.tspan.setAttributeNS(null, 'font-style', current.fontStyle); + } + if (current.fontWeight !== SVG_DEFAULTS.fontWeight) { + current.tspan.setAttributeNS(null, 'font-weight', current.fontWeight); + } + if (current.fillColor !== SVG_DEFAULTS.fillColor) { + current.tspan.setAttributeNS(null, 'fill', current.fillColor); + } + + current.txtElement.setAttributeNS(null, 'transform', + pm(current.textMatrix) + + ' scale(1, -1)' ); + current.txtElement.setAttributeNS(XML_NS, 'xml:space', 'preserve'); + current.txtElement.appendChild(current.tspan); + current.txtgrp.appendChild(current.txtElement); + + this.tgrp.appendChild(current.txtElement); + + }, + + setLeadingMoveText: function SVGGraphics_setLeadingMoveText(x, y) { + this.setLeading(-y); + this.moveText(x, y); + }, + + addFontStyle: function SVGGraphics_addFontStyle(fontObj) { + if (!this.cssStyle) { + this.cssStyle = document.createElementNS(NS, 'svg:style'); + this.cssStyle.setAttributeNS(null, 'type', 'text/css'); + this.defs.appendChild(this.cssStyle); + } + + var url = PDFJS.createObjectURL(fontObj.data, fontObj.mimetype); + this.cssStyle.textContent += + '@font-face { font-family: "' + fontObj.loadedName + '";' + + ' src: url(' + url + '); }\n'; + }, + + setFont: function SVGGraphics_setFont(details) { + var current = this.current; + var fontObj = this.commonObjs.get(details[0]); + var size = details[1]; + this.current.font = fontObj; + + if (this.embedFonts && fontObj.data && + !this.embeddedFonts[fontObj.loadedName]) { + this.addFontStyle(fontObj); + this.embeddedFonts[fontObj.loadedName] = fontObj; + } + + current.fontMatrix = (fontObj.fontMatrix ? + fontObj.fontMatrix : FONT_IDENTITY_MATRIX); + + var bold = fontObj.black ? (fontObj.bold ? 'bolder' : 'bold') : + (fontObj.bold ? 'bold' : 'normal'); + var italic = fontObj.italic ? 'italic' : 'normal'; + + if (size < 0) { + size = -size; + current.fontDirection = -1; + } else { + current.fontDirection = 1; + } + current.fontSize = size; + current.fontFamily = fontObj.loadedName; + current.fontWeight = bold; + current.fontStyle = italic; + + current.tspan = document.createElementNS(NS, 'svg:tspan'); + current.tspan.setAttributeNS(null, 'y', pf(-current.y)); + current.xcoords = []; + }, + + endText: function SVGGraphics_endText() { + if (this.current.pendingClip) { + this.cgrp.appendChild(this.tgrp); + this.pgrp.appendChild(this.cgrp); + } else { + this.pgrp.appendChild(this.tgrp); + } + this.tgrp = document.createElementNS(NS, 'svg:g'); + this.tgrp.setAttributeNS(null, 'transform', pm(this.transformMatrix)); + }, + + // Path properties + setLineWidth: function SVGGraphics_setLineWidth(width) { + this.current.lineWidth = width; + }, + setLineCap: function SVGGraphics_setLineCap(style) { + this.current.lineCap = LINE_CAP_STYLES[style]; + }, + setLineJoin: function SVGGraphics_setLineJoin(style) { + this.current.lineJoin = LINE_JOIN_STYLES[style]; + }, + setMiterLimit: function SVGGraphics_setMiterLimit(limit) { + this.current.miterLimit = limit; + }, + setStrokeRGBColor: function SVGGraphics_setStrokeRGBColor(r, g, b) { + var color = Util.makeCssRgb(r, g, b); + this.current.strokeColor = color; + }, + setFillRGBColor: function SVGGraphics_setFillRGBColor(r, g, b) { + var color = Util.makeCssRgb(r, g, b); + this.current.fillColor = color; + this.current.tspan = document.createElementNS(NS, 'svg:tspan'); + this.current.xcoords = []; + }, + setDash: function SVGGraphics_setDash(dashArray, dashPhase) { + this.current.dashArray = dashArray; + this.current.dashPhase = dashPhase; + }, + + constructPath: function SVGGraphics_constructPath(ops, args) { + var current = this.current; + var x = current.x, y = current.y; + current.path = document.createElementNS(NS, 'svg:path'); + var d = []; + var opLength = ops.length; + + for (var i = 0, j = 0; i < opLength; i++) { + switch (ops[i] | 0) { + case OPS.rectangle: + x = args[j++]; + y = args[j++]; + var width = args[j++]; + var height = args[j++]; + var xw = x + width; + var yh = y + height; + d.push('M', pf(x), pf(y), 'L', pf(xw) , pf(y), 'L', pf(xw), pf(yh), + 'L', pf(x), pf(yh), 'Z'); + break; + case OPS.moveTo: + x = args[j++]; + y = args[j++]; + d.push('M', pf(x), pf(y)); + break; + case OPS.lineTo: + x = args[j++]; + y = args[j++]; + d.push('L', pf(x) , pf(y)); + break; + case OPS.curveTo: + x = args[j + 4]; + y = args[j + 5]; + d.push('C', pf(args[j]), pf(args[j + 1]), pf(args[j + 2]), + pf(args[j + 3]), pf(x), pf(y)); + j += 6; + break; + case OPS.curveTo2: + x = args[j + 2]; + y = args[j + 3]; + d.push('C', pf(x), pf(y), pf(args[j]), pf(args[j + 1]), + pf(args[j + 2]), pf(args[j + 3])); + j += 4; + break; + case OPS.curveTo3: + x = args[j + 2]; + y = args[j + 3]; + d.push('C', pf(args[j]), pf(args[j + 1]), pf(x), pf(y), + pf(x), pf(y)); + j += 4; + break; + case OPS.closePath: + d.push('Z'); + break; + } + } + current.path.setAttributeNS(null, 'd', d.join(' ')); + current.path.setAttributeNS(null, 'stroke-miterlimit', + pf(current.miterLimit)); + current.path.setAttributeNS(null, 'stroke-linecap', current.lineCap); + current.path.setAttributeNS(null, 'stroke-linejoin', current.lineJoin); + current.path.setAttributeNS(null, 'stroke-width', + pf(current.lineWidth) + 'px'); + current.path.setAttributeNS(null, 'stroke-dasharray', + current.dashArray.map(pf).join(' ')); + current.path.setAttributeNS(null, 'stroke-dashoffset', + pf(current.dashPhase) + 'px'); + current.path.setAttributeNS(null, 'fill', 'none'); + + this.tgrp.appendChild(current.path); + if (current.pendingClip) { + this.cgrp.appendChild(this.tgrp); + this.pgrp.appendChild(this.cgrp); + } else { + this.pgrp.appendChild(this.tgrp); + } + // Saving a reference in current.element so that it can be addressed + // in 'fill' and 'stroke' + current.element = current.path; + current.setCurrentPoint(x, y); + }, + + endPath: function SVGGraphics_endPath() { + var current = this.current; + if (current.pendingClip) { + this.cgrp.appendChild(this.tgrp); + this.pgrp.appendChild(this.cgrp); + } else { + this.pgrp.appendChild(this.tgrp); + } + this.tgrp = document.createElementNS(NS, 'svg:g'); + this.tgrp.setAttributeNS(null, 'transform', pm(this.transformMatrix)); + }, + + clip: function SVGGraphics_clip(type) { + var current = this.current; + // Add current path to clipping path + current.clipId = 'clippath' + clipCount; + clipCount++; + this.clippath = document.createElementNS(NS, 'svg:clipPath'); + this.clippath.setAttributeNS(null, 'id', current.clipId); + var clipElement = current.element.cloneNode(); + if (type === 'evenodd') { + clipElement.setAttributeNS(null, 'clip-rule', 'evenodd'); + } else { + clipElement.setAttributeNS(null, 'clip-rule', 'nonzero'); + } + this.clippath.setAttributeNS(null, 'transform', pm(this.transformMatrix)); + this.clippath.appendChild(clipElement); + this.defs.appendChild(this.clippath); + + // Create a new group with that attribute + current.pendingClip = true; + this.cgrp = document.createElementNS(NS, 'svg:g'); + this.cgrp.setAttributeNS(null, 'clip-path', + 'url(#' + current.clipId + ')'); + this.pgrp.appendChild(this.cgrp); + }, + + closePath: function SVGGraphics_closePath() { + var current = this.current; + var d = current.path.getAttributeNS(null, 'd'); + d += 'Z'; + current.path.setAttributeNS(null, 'd', d); + }, + + setLeading: function SVGGraphics_setLeading(leading) { + this.current.leading = -leading; + }, + + setTextRise: function SVGGraphics_setTextRise(textRise) { + this.current.textRise = textRise; + }, + + setHScale: function SVGGraphics_setHScale(scale) { + this.current.textHScale = scale / 100; + }, + + setGState: function SVGGraphics_setGState(states) { + for (var i = 0, ii = states.length; i < ii; i++) { + var state = states[i]; + var key = state[0]; + var value = state[1]; + + switch (key) { + case 'LW': + this.setLineWidth(value); + break; + case 'LC': + this.setLineCap(value); + break; + case 'LJ': + this.setLineJoin(value); + break; + case 'ML': + this.setMiterLimit(value); + break; + case 'D': + this.setDash(value[0], value[1]); + break; + case 'RI': + break; + case 'FL': + break; + case 'Font': + this.setFont(value); + break; + case 'CA': + break; + case 'ca': + break; + case 'BM': + break; + case 'SMask': + break; + } + } + }, + + fill: function SVGGraphics_fill() { + var current = this.current; + current.element.setAttributeNS(null, 'fill', current.fillColor); + }, + + stroke: function SVGGraphics_stroke() { + var current = this.current; + current.element.setAttributeNS(null, 'stroke', current.strokeColor); + current.element.setAttributeNS(null, 'fill', 'none'); + }, + + eoFill: function SVGGraphics_eoFill() { + var current = this.current; + current.element.setAttributeNS(null, 'fill', current.fillColor); + current.element.setAttributeNS(null, 'fill-rule', 'evenodd'); + }, + + fillStroke: function SVGGraphics_fillStroke() { + // Order is important since stroke wants fill to be none. + // First stroke, then if fill needed, it will be overwritten. + this.stroke(); + this.fill(); + }, + + eoFillStroke: function SVGGraphics_eoFillStroke() { + this.current.element.setAttributeNS(null, 'fill-rule', 'evenodd'); + this.fillStroke(); + }, + + closeStroke: function SVGGraphics_closeStroke() { + this.closePath(); + this.stroke(); + }, + + closeFillStroke: function SVGGraphics_closeFillStroke() { + this.closePath(); + this.fillStroke(); + }, + + paintSolidColorImageMask: + function SVGGraphics_paintSolidColorImageMask() { + var current = this.current; + var rect = document.createElementNS(NS, 'svg:rect'); + rect.setAttributeNS(null, 'x', '0'); + rect.setAttributeNS(null, 'y', '0'); + rect.setAttributeNS(null, 'width', '1px'); + rect.setAttributeNS(null, 'height', '1px'); + rect.setAttributeNS(null, 'fill', current.fillColor); + this.tgrp.appendChild(rect); + }, + + paintJpegXObject: function SVGGraphics_paintJpegXObject(objId, w, h) { + var current = this.current; + var imgObj = this.objs.get(objId); + var imgEl = document.createElementNS(NS, 'svg:image'); + imgEl.setAttributeNS(XLINK_NS, 'xlink:href', imgObj.src); + imgEl.setAttributeNS(null, 'width', imgObj.width + 'px'); + imgEl.setAttributeNS(null, 'height', imgObj.height + 'px'); + imgEl.setAttributeNS(null, 'x', '0'); + imgEl.setAttributeNS(null, 'y', pf(-h)); + imgEl.setAttributeNS(null, 'transform', + 'scale(' + pf(1 / w) + ' ' + pf(-1 / h) + ')'); + + this.tgrp.appendChild(imgEl); + if (current.pendingClip) { + this.cgrp.appendChild(this.tgrp); + this.pgrp.appendChild(this.cgrp); + } else { + this.pgrp.appendChild(this.tgrp); + } + }, + + paintImageXObject: function SVGGraphics_paintImageXObject(objId) { + var imgData = this.objs.get(objId); + if (!imgData) { + warn('Dependent image isn\'t ready yet'); + return; + } + this.paintInlineImageXObject(imgData); + }, + + paintInlineImageXObject: + function SVGGraphics_paintInlineImageXObject(imgData, mask) { + var current = this.current; + var width = imgData.width; + var height = imgData.height; + + var imgSrc = convertImgDataToPng(imgData); + var cliprect = document.createElementNS(NS, 'svg:rect'); + cliprect.setAttributeNS(null, 'x', '0'); + cliprect.setAttributeNS(null, 'y', '0'); + cliprect.setAttributeNS(null, 'width', pf(width)); + cliprect.setAttributeNS(null, 'height', pf(height)); + current.element = cliprect; + this.clip('nonzero'); + var imgEl = document.createElementNS(NS, 'svg:image'); + imgEl.setAttributeNS(XLINK_NS, 'xlink:href', imgSrc); + imgEl.setAttributeNS(null, 'x', '0'); + imgEl.setAttributeNS(null, 'y', pf(-height)); + imgEl.setAttributeNS(null, 'width', pf(width) + 'px'); + imgEl.setAttributeNS(null, 'height', pf(height) + 'px'); + imgEl.setAttributeNS(null, 'transform', + 'scale(' + pf(1 / width) + ' ' + + pf(-1 / height) + ')'); + if (mask) { + mask.appendChild(imgEl); + } else { + this.tgrp.appendChild(imgEl); + } + if (current.pendingClip) { + this.cgrp.appendChild(this.tgrp); + this.pgrp.appendChild(this.cgrp); + } else { + this.pgrp.appendChild(this.tgrp); + } + }, + + paintImageMaskXObject: + function SVGGraphics_paintImageMaskXObject(imgData) { + var current = this.current; + var width = imgData.width; + var height = imgData.height; + var fillColor = current.fillColor; + + current.maskId = 'mask' + maskCount++; + var mask = document.createElementNS(NS, 'svg:mask'); + mask.setAttributeNS(null, 'id', current.maskId); + + var rect = document.createElementNS(NS, 'svg:rect'); + rect.setAttributeNS(null, 'x', '0'); + rect.setAttributeNS(null, 'y', '0'); + rect.setAttributeNS(null, 'width', pf(width)); + rect.setAttributeNS(null, 'height', pf(height)); + rect.setAttributeNS(null, 'fill', fillColor); + rect.setAttributeNS(null, 'mask', 'url(#' + current.maskId +')'); + this.defs.appendChild(mask); + this.tgrp.appendChild(rect); + + this.paintInlineImageXObject(imgData, mask); + }, + + paintFormXObjectBegin: + function SVGGraphics_paintFormXObjectBegin(matrix, bbox) { + this.save(); + + if (isArray(matrix) && matrix.length === 6) { + this.transform(matrix[0], matrix[1], matrix[2], + matrix[3], matrix[4], matrix[5]); + } + + if (isArray(bbox) && bbox.length === 4) { + var width = bbox[2] - bbox[0]; + var height = bbox[3] - bbox[1]; + + var cliprect = document.createElementNS(NS, 'svg:rect'); + cliprect.setAttributeNS(null, 'x', bbox[0]); + cliprect.setAttributeNS(null, 'y', bbox[1]); + cliprect.setAttributeNS(null, 'width', pf(width)); + cliprect.setAttributeNS(null, 'height', pf(height)); + this.current.element = cliprect; + this.clip('nonzero'); + this.endPath(); + } + }, + + paintFormXObjectEnd: + function SVGGraphics_paintFormXObjectEnd() { + this.restore(); + } + }; + return SVGGraphics; +})(); + +PDFJS.SVGGraphics = SVGGraphics; + +exports.SVGGraphics = SVGGraphics; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayWebGL = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayGlobal); + } +}(this, function (exports, sharedUtil, displayGlobal) { + +var shadow = sharedUtil.shadow; +var PDFJS = displayGlobal.PDFJS; + +var WebGLUtils = (function WebGLUtilsClosure() { + function loadShader(gl, code, shaderType) { + var shader = gl.createShader(shaderType); + gl.shaderSource(shader, code); + gl.compileShader(shader); + var compiled = gl.getShaderParameter(shader, gl.COMPILE_STATUS); + if (!compiled) { + var errorMsg = gl.getShaderInfoLog(shader); + throw new Error('Error during shader compilation: ' + errorMsg); + } + return shader; + } + function createVertexShader(gl, code) { + return loadShader(gl, code, gl.VERTEX_SHADER); + } + function createFragmentShader(gl, code) { + return loadShader(gl, code, gl.FRAGMENT_SHADER); + } + function createProgram(gl, shaders) { + var program = gl.createProgram(); + for (var i = 0, ii = shaders.length; i < ii; ++i) { + gl.attachShader(program, shaders[i]); + } + gl.linkProgram(program); + var linked = gl.getProgramParameter(program, gl.LINK_STATUS); + if (!linked) { + var errorMsg = gl.getProgramInfoLog(program); + throw new Error('Error during program linking: ' + errorMsg); + } + return program; + } + function createTexture(gl, image, textureId) { + gl.activeTexture(textureId); + var texture = gl.createTexture(); + gl.bindTexture(gl.TEXTURE_2D, texture); + + // Set the parameters so we can render any size image. + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST); + + // Upload the image into the texture. + gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, image); + return texture; + } + + var currentGL, currentCanvas; + function generateGL() { + if (currentGL) { + return; + } + currentCanvas = document.createElement('canvas'); + currentGL = currentCanvas.getContext('webgl', + { premultipliedalpha: false }); + } + + var smaskVertexShaderCode = '\ + attribute vec2 a_position; \ + attribute vec2 a_texCoord; \ + \ + uniform vec2 u_resolution; \ + \ + varying vec2 v_texCoord; \ + \ + void main() { \ + vec2 clipSpace = (a_position / u_resolution) * 2.0 - 1.0; \ + gl_Position = vec4(clipSpace * vec2(1, -1), 0, 1); \ + \ + v_texCoord = a_texCoord; \ + } '; + + var smaskFragmentShaderCode = '\ + precision mediump float; \ + \ + uniform vec4 u_backdrop; \ + uniform int u_subtype; \ + uniform sampler2D u_image; \ + uniform sampler2D u_mask; \ + \ + varying vec2 v_texCoord; \ + \ + void main() { \ + vec4 imageColor = texture2D(u_image, v_texCoord); \ + vec4 maskColor = texture2D(u_mask, v_texCoord); \ + if (u_backdrop.a > 0.0) { \ + maskColor.rgb = maskColor.rgb * maskColor.a + \ + u_backdrop.rgb * (1.0 - maskColor.a); \ + } \ + float lum; \ + if (u_subtype == 0) { \ + lum = maskColor.a; \ + } else { \ + lum = maskColor.r * 0.3 + maskColor.g * 0.59 + \ + maskColor.b * 0.11; \ + } \ + imageColor.a *= lum; \ + imageColor.rgb *= imageColor.a; \ + gl_FragColor = imageColor; \ + } '; + + var smaskCache = null; + + function initSmaskGL() { + var canvas, gl; + + generateGL(); + canvas = currentCanvas; + currentCanvas = null; + gl = currentGL; + currentGL = null; + + // setup a GLSL program + var vertexShader = createVertexShader(gl, smaskVertexShaderCode); + var fragmentShader = createFragmentShader(gl, smaskFragmentShaderCode); + var program = createProgram(gl, [vertexShader, fragmentShader]); + gl.useProgram(program); + + var cache = {}; + cache.gl = gl; + cache.canvas = canvas; + cache.resolutionLocation = gl.getUniformLocation(program, 'u_resolution'); + cache.positionLocation = gl.getAttribLocation(program, 'a_position'); + cache.backdropLocation = gl.getUniformLocation(program, 'u_backdrop'); + cache.subtypeLocation = gl.getUniformLocation(program, 'u_subtype'); + + var texCoordLocation = gl.getAttribLocation(program, 'a_texCoord'); + var texLayerLocation = gl.getUniformLocation(program, 'u_image'); + var texMaskLocation = gl.getUniformLocation(program, 'u_mask'); + + // provide texture coordinates for the rectangle. + var texCoordBuffer = gl.createBuffer(); + gl.bindBuffer(gl.ARRAY_BUFFER, texCoordBuffer); + gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([ + 0.0, 0.0, + 1.0, 0.0, + 0.0, 1.0, + 0.0, 1.0, + 1.0, 0.0, + 1.0, 1.0]), gl.STATIC_DRAW); + gl.enableVertexAttribArray(texCoordLocation); + gl.vertexAttribPointer(texCoordLocation, 2, gl.FLOAT, false, 0, 0); + + gl.uniform1i(texLayerLocation, 0); + gl.uniform1i(texMaskLocation, 1); + + smaskCache = cache; + } + + function composeSMask(layer, mask, properties) { + var width = layer.width, height = layer.height; + + if (!smaskCache) { + initSmaskGL(); + } + var cache = smaskCache,canvas = cache.canvas, gl = cache.gl; + canvas.width = width; + canvas.height = height; + gl.viewport(0, 0, gl.drawingBufferWidth, gl.drawingBufferHeight); + gl.uniform2f(cache.resolutionLocation, width, height); + + if (properties.backdrop) { + gl.uniform4f(cache.resolutionLocation, properties.backdrop[0], + properties.backdrop[1], properties.backdrop[2], 1); + } else { + gl.uniform4f(cache.resolutionLocation, 0, 0, 0, 0); + } + gl.uniform1i(cache.subtypeLocation, + properties.subtype === 'Luminosity' ? 1 : 0); + + // Create a textures + var texture = createTexture(gl, layer, gl.TEXTURE0); + var maskTexture = createTexture(gl, mask, gl.TEXTURE1); + + + // Create a buffer and put a single clipspace rectangle in + // it (2 triangles) + var buffer = gl.createBuffer(); + gl.bindBuffer(gl.ARRAY_BUFFER, buffer); + gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([ + 0, 0, + width, 0, + 0, height, + 0, height, + width, 0, + width, height]), gl.STATIC_DRAW); + gl.enableVertexAttribArray(cache.positionLocation); + gl.vertexAttribPointer(cache.positionLocation, 2, gl.FLOAT, false, 0, 0); + + // draw + gl.clearColor(0, 0, 0, 0); + gl.enable(gl.BLEND); + gl.blendFunc(gl.ONE, gl.ONE_MINUS_SRC_ALPHA); + gl.clear(gl.COLOR_BUFFER_BIT); + + gl.drawArrays(gl.TRIANGLES, 0, 6); + + gl.flush(); + + gl.deleteTexture(texture); + gl.deleteTexture(maskTexture); + gl.deleteBuffer(buffer); + + return canvas; + } + + var figuresVertexShaderCode = '\ + attribute vec2 a_position; \ + attribute vec3 a_color; \ + \ + uniform vec2 u_resolution; \ + uniform vec2 u_scale; \ + uniform vec2 u_offset; \ + \ + varying vec4 v_color; \ + \ + void main() { \ + vec2 position = (a_position + u_offset) * u_scale; \ + vec2 clipSpace = (position / u_resolution) * 2.0 - 1.0; \ + gl_Position = vec4(clipSpace * vec2(1, -1), 0, 1); \ + \ + v_color = vec4(a_color / 255.0, 1.0); \ + } '; + + var figuresFragmentShaderCode = '\ + precision mediump float; \ + \ + varying vec4 v_color; \ + \ + void main() { \ + gl_FragColor = v_color; \ + } '; + + var figuresCache = null; + + function initFiguresGL() { + var canvas, gl; + + generateGL(); + canvas = currentCanvas; + currentCanvas = null; + gl = currentGL; + currentGL = null; + + // setup a GLSL program + var vertexShader = createVertexShader(gl, figuresVertexShaderCode); + var fragmentShader = createFragmentShader(gl, figuresFragmentShaderCode); + var program = createProgram(gl, [vertexShader, fragmentShader]); + gl.useProgram(program); + + var cache = {}; + cache.gl = gl; + cache.canvas = canvas; + cache.resolutionLocation = gl.getUniformLocation(program, 'u_resolution'); + cache.scaleLocation = gl.getUniformLocation(program, 'u_scale'); + cache.offsetLocation = gl.getUniformLocation(program, 'u_offset'); + cache.positionLocation = gl.getAttribLocation(program, 'a_position'); + cache.colorLocation = gl.getAttribLocation(program, 'a_color'); + + figuresCache = cache; + } + + function drawFigures(width, height, backgroundColor, figures, context) { + if (!figuresCache) { + initFiguresGL(); + } + var cache = figuresCache, canvas = cache.canvas, gl = cache.gl; + + canvas.width = width; + canvas.height = height; + gl.viewport(0, 0, gl.drawingBufferWidth, gl.drawingBufferHeight); + gl.uniform2f(cache.resolutionLocation, width, height); + + // count triangle points + var count = 0; + var i, ii, rows; + for (i = 0, ii = figures.length; i < ii; i++) { + switch (figures[i].type) { + case 'lattice': + rows = (figures[i].coords.length / figures[i].verticesPerRow) | 0; + count += (rows - 1) * (figures[i].verticesPerRow - 1) * 6; + break; + case 'triangles': + count += figures[i].coords.length; + break; + } + } + // transfer data + var coords = new Float32Array(count * 2); + var colors = new Uint8Array(count * 3); + var coordsMap = context.coords, colorsMap = context.colors; + var pIndex = 0, cIndex = 0; + for (i = 0, ii = figures.length; i < ii; i++) { + var figure = figures[i], ps = figure.coords, cs = figure.colors; + switch (figure.type) { + case 'lattice': + var cols = figure.verticesPerRow; + rows = (ps.length / cols) | 0; + for (var row = 1; row < rows; row++) { + var offset = row * cols + 1; + for (var col = 1; col < cols; col++, offset++) { + coords[pIndex] = coordsMap[ps[offset - cols - 1]]; + coords[pIndex + 1] = coordsMap[ps[offset - cols - 1] + 1]; + coords[pIndex + 2] = coordsMap[ps[offset - cols]]; + coords[pIndex + 3] = coordsMap[ps[offset - cols] + 1]; + coords[pIndex + 4] = coordsMap[ps[offset - 1]]; + coords[pIndex + 5] = coordsMap[ps[offset - 1] + 1]; + colors[cIndex] = colorsMap[cs[offset - cols - 1]]; + colors[cIndex + 1] = colorsMap[cs[offset - cols - 1] + 1]; + colors[cIndex + 2] = colorsMap[cs[offset - cols - 1] + 2]; + colors[cIndex + 3] = colorsMap[cs[offset - cols]]; + colors[cIndex + 4] = colorsMap[cs[offset - cols] + 1]; + colors[cIndex + 5] = colorsMap[cs[offset - cols] + 2]; + colors[cIndex + 6] = colorsMap[cs[offset - 1]]; + colors[cIndex + 7] = colorsMap[cs[offset - 1] + 1]; + colors[cIndex + 8] = colorsMap[cs[offset - 1] + 2]; + + coords[pIndex + 6] = coords[pIndex + 2]; + coords[pIndex + 7] = coords[pIndex + 3]; + coords[pIndex + 8] = coords[pIndex + 4]; + coords[pIndex + 9] = coords[pIndex + 5]; + coords[pIndex + 10] = coordsMap[ps[offset]]; + coords[pIndex + 11] = coordsMap[ps[offset] + 1]; + colors[cIndex + 9] = colors[cIndex + 3]; + colors[cIndex + 10] = colors[cIndex + 4]; + colors[cIndex + 11] = colors[cIndex + 5]; + colors[cIndex + 12] = colors[cIndex + 6]; + colors[cIndex + 13] = colors[cIndex + 7]; + colors[cIndex + 14] = colors[cIndex + 8]; + colors[cIndex + 15] = colorsMap[cs[offset]]; + colors[cIndex + 16] = colorsMap[cs[offset] + 1]; + colors[cIndex + 17] = colorsMap[cs[offset] + 2]; + pIndex += 12; + cIndex += 18; + } + } + break; + case 'triangles': + for (var j = 0, jj = ps.length; j < jj; j++) { + coords[pIndex] = coordsMap[ps[j]]; + coords[pIndex + 1] = coordsMap[ps[j] + 1]; + colors[cIndex] = colorsMap[cs[j]]; + colors[cIndex + 1] = colorsMap[cs[j] + 1]; + colors[cIndex + 2] = colorsMap[cs[j] + 2]; + pIndex += 2; + cIndex += 3; + } + break; + } + } + + // draw + if (backgroundColor) { + gl.clearColor(backgroundColor[0] / 255, backgroundColor[1] / 255, + backgroundColor[2] / 255, 1.0); + } else { + gl.clearColor(0, 0, 0, 0); + } + gl.clear(gl.COLOR_BUFFER_BIT); + + var coordsBuffer = gl.createBuffer(); + gl.bindBuffer(gl.ARRAY_BUFFER, coordsBuffer); + gl.bufferData(gl.ARRAY_BUFFER, coords, gl.STATIC_DRAW); + gl.enableVertexAttribArray(cache.positionLocation); + gl.vertexAttribPointer(cache.positionLocation, 2, gl.FLOAT, false, 0, 0); + + var colorsBuffer = gl.createBuffer(); + gl.bindBuffer(gl.ARRAY_BUFFER, colorsBuffer); + gl.bufferData(gl.ARRAY_BUFFER, colors, gl.STATIC_DRAW); + gl.enableVertexAttribArray(cache.colorLocation); + gl.vertexAttribPointer(cache.colorLocation, 3, gl.UNSIGNED_BYTE, false, + 0, 0); + + gl.uniform2f(cache.scaleLocation, context.scaleX, context.scaleY); + gl.uniform2f(cache.offsetLocation, context.offsetX, context.offsetY); + + gl.drawArrays(gl.TRIANGLES, 0, count); + + gl.flush(); + + gl.deleteBuffer(coordsBuffer); + gl.deleteBuffer(colorsBuffer); + + return canvas; + } + + function cleanup() { + if (smaskCache && smaskCache.canvas) { + smaskCache.canvas.width = 0; + smaskCache.canvas.height = 0; + } + if (figuresCache && figuresCache.canvas) { + figuresCache.canvas.width = 0; + figuresCache.canvas.height = 0; + } + smaskCache = null; + figuresCache = null; + } + + return { + get isEnabled() { + if (PDFJS.disableWebGL) { + return false; + } + var enabled = false; + try { + generateGL(); + enabled = !!currentGL; + } catch (e) { } + return shadow(this, 'isEnabled', enabled); + }, + composeSMask: composeSMask, + drawFigures: drawFigures, + clear: cleanup + }; +})(); + +exports.WebGLUtils = WebGLUtils; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayAnnotationLayer = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayDOMUtils); + } +}(this, function (exports, sharedUtil, displayDOMUtils) { + +var AnnotationBorderStyleType = sharedUtil.AnnotationBorderStyleType; +var AnnotationType = sharedUtil.AnnotationType; +var Util = sharedUtil.Util; +var addLinkAttributes = displayDOMUtils.addLinkAttributes; +var getFilenameFromUrl = displayDOMUtils.getFilenameFromUrl; +var warn = sharedUtil.warn; +var CustomStyle = displayDOMUtils.CustomStyle; + +/** + * @typedef {Object} AnnotationElementParameters + * @property {Object} data + * @property {HTMLDivElement} layer + * @property {PDFPage} page + * @property {PageViewport} viewport + * @property {IPDFLinkService} linkService + * @property {DownloadManager} downloadManager + */ + +/** + * @class + * @alias AnnotationElementFactory + */ +function AnnotationElementFactory() {} +AnnotationElementFactory.prototype = + /** @lends AnnotationElementFactory.prototype */ { + /** + * @param {AnnotationElementParameters} parameters + * @returns {AnnotationElement} + */ + create: function AnnotationElementFactory_create(parameters) { + var subtype = parameters.data.annotationType; + + switch (subtype) { + case AnnotationType.LINK: + return new LinkAnnotationElement(parameters); + + case AnnotationType.TEXT: + return new TextAnnotationElement(parameters); + + case AnnotationType.WIDGET: + return new WidgetAnnotationElement(parameters); + + case AnnotationType.POPUP: + return new PopupAnnotationElement(parameters); + + case AnnotationType.HIGHLIGHT: + return new HighlightAnnotationElement(parameters); + + case AnnotationType.UNDERLINE: + return new UnderlineAnnotationElement(parameters); + + case AnnotationType.SQUIGGLY: + return new SquigglyAnnotationElement(parameters); + + case AnnotationType.STRIKEOUT: + return new StrikeOutAnnotationElement(parameters); + + case AnnotationType.FILEATTACHMENT: + return new FileAttachmentAnnotationElement(parameters); + + default: + return new AnnotationElement(parameters); + } + } +}; + +/** + * @class + * @alias AnnotationElement + */ +var AnnotationElement = (function AnnotationElementClosure() { + function AnnotationElement(parameters, isRenderable) { + this.isRenderable = isRenderable || false; + this.data = parameters.data; + this.layer = parameters.layer; + this.page = parameters.page; + this.viewport = parameters.viewport; + this.linkService = parameters.linkService; + this.downloadManager = parameters.downloadManager; + + if (isRenderable) { + this.container = this._createContainer(); + } + } + + AnnotationElement.prototype = /** @lends AnnotationElement.prototype */ { + /** + * Create an empty container for the annotation's HTML element. + * + * @private + * @memberof AnnotationElement + * @returns {HTMLSectionElement} + */ + _createContainer: function AnnotationElement_createContainer() { + var data = this.data, page = this.page, viewport = this.viewport; + var container = document.createElement('section'); + var width = data.rect[2] - data.rect[0]; + var height = data.rect[3] - data.rect[1]; + + container.setAttribute('data-annotation-id', data.id); + + // Do *not* modify `data.rect`, since that will corrupt the annotation + // position on subsequent calls to `_createContainer` (see issue 6804). + var rect = Util.normalizeRect([ + data.rect[0], + page.view[3] - data.rect[1] + page.view[1], + data.rect[2], + page.view[3] - data.rect[3] + page.view[1] + ]); + + CustomStyle.setProp('transform', container, + 'matrix(' + viewport.transform.join(',') + ')'); + CustomStyle.setProp('transformOrigin', container, + -rect[0] + 'px ' + -rect[1] + 'px'); + + if (data.borderStyle.width > 0) { + container.style.borderWidth = data.borderStyle.width + 'px'; + if (data.borderStyle.style !== AnnotationBorderStyleType.UNDERLINE) { + // Underline styles only have a bottom border, so we do not need + // to adjust for all borders. This yields a similar result as + // Adobe Acrobat/Reader. + width = width - 2 * data.borderStyle.width; + height = height - 2 * data.borderStyle.width; + } + + var horizontalRadius = data.borderStyle.horizontalCornerRadius; + var verticalRadius = data.borderStyle.verticalCornerRadius; + if (horizontalRadius > 0 || verticalRadius > 0) { + var radius = horizontalRadius + 'px / ' + verticalRadius + 'px'; + CustomStyle.setProp('borderRadius', container, radius); + } + + switch (data.borderStyle.style) { + case AnnotationBorderStyleType.SOLID: + container.style.borderStyle = 'solid'; + break; + + case AnnotationBorderStyleType.DASHED: + container.style.borderStyle = 'dashed'; + break; + + case AnnotationBorderStyleType.BEVELED: + warn('Unimplemented border style: beveled'); + break; + + case AnnotationBorderStyleType.INSET: + warn('Unimplemented border style: inset'); + break; + + case AnnotationBorderStyleType.UNDERLINE: + container.style.borderBottomStyle = 'solid'; + break; + + default: + break; + } + + if (data.color) { + container.style.borderColor = + Util.makeCssRgb(data.color[0] | 0, + data.color[1] | 0, + data.color[2] | 0); + } else { + // Transparent (invisible) border, so do not draw it at all. + container.style.borderWidth = 0; + } + } + + container.style.left = rect[0] + 'px'; + container.style.top = rect[1] + 'px'; + + container.style.width = width + 'px'; + container.style.height = height + 'px'; + + return container; + }, + + /** + * Create a popup for the annotation's HTML element. This is used for + * annotations that do not have a Popup entry in the dictionary, but + * are of a type that works with popups (such as Highlight annotations). + * + * @private + * @param {HTMLSectionElement} container + * @param {HTMLDivElement|HTMLImageElement|null} trigger + * @param {Object} data + * @memberof AnnotationElement + */ + _createPopup: + function AnnotationElement_createPopup(container, trigger, data) { + // If no trigger element is specified, create it. + if (!trigger) { + trigger = document.createElement('div'); + trigger.style.height = container.style.height; + trigger.style.width = container.style.width; + container.appendChild(trigger); + } + + var popupElement = new PopupElement({ + container: container, + trigger: trigger, + color: data.color, + title: data.title, + contents: data.contents, + hideWrapper: true + }); + var popup = popupElement.render(); + + // Position the popup next to the annotation's container. + popup.style.left = container.style.width; + + container.appendChild(popup); + }, + + /** + * Render the annotation's HTML element in the empty container. + * + * @public + * @memberof AnnotationElement + */ + render: function AnnotationElement_render() { + throw new Error('Abstract method AnnotationElement.render called'); + } + }; + + return AnnotationElement; +})(); + +/** + * @class + * @alias LinkAnnotationElement + */ +var LinkAnnotationElement = (function LinkAnnotationElementClosure() { + function LinkAnnotationElement(parameters) { + AnnotationElement.call(this, parameters, true); + } + + Util.inherit(LinkAnnotationElement, AnnotationElement, { + /** + * Render the link annotation's HTML element in the empty container. + * + * @public + * @memberof LinkAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function LinkAnnotationElement_render() { + this.container.className = 'linkAnnotation'; + + var link = document.createElement('a'); + addLinkAttributes(link, { url: this.data.url }); + + if (!this.data.url) { + if (this.data.action) { + this._bindNamedAction(link, this.data.action); + } else { + this._bindLink(link, ('dest' in this.data) ? this.data.dest : null); + } + } + + this.container.appendChild(link); + return this.container; + }, + + /** + * Bind internal links to the link element. + * + * @private + * @param {Object} link + * @param {Object} destination + * @memberof LinkAnnotationElement + */ + _bindLink: function LinkAnnotationElement_bindLink(link, destination) { + var self = this; + + link.href = this.linkService.getDestinationHash(destination); + link.onclick = function() { + if (destination) { + self.linkService.navigateTo(destination); + } + return false; + }; + if (destination) { + link.className = 'internalLink'; + } + }, + + /** + * Bind named actions to the link element. + * + * @private + * @param {Object} link + * @param {Object} action + * @memberof LinkAnnotationElement + */ + _bindNamedAction: + function LinkAnnotationElement_bindNamedAction(link, action) { + var self = this; + + link.href = this.linkService.getAnchorUrl(''); + link.onclick = function() { + self.linkService.executeNamedAction(action); + return false; + }; + link.className = 'internalLink'; + } + }); + + return LinkAnnotationElement; +})(); + +/** + * @class + * @alias TextAnnotationElement + */ +var TextAnnotationElement = (function TextAnnotationElementClosure() { + function TextAnnotationElement(parameters) { + var isRenderable = !!(parameters.data.hasPopup || + parameters.data.title || parameters.data.contents); + AnnotationElement.call(this, parameters, isRenderable); + } + + Util.inherit(TextAnnotationElement, AnnotationElement, { + /** + * Render the text annotation's HTML element in the empty container. + * + * @public + * @memberof TextAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function TextAnnotationElement_render() { + this.container.className = 'textAnnotation'; + + var image = document.createElement('img'); + image.style.height = this.container.style.height; + image.style.width = this.container.style.width; + image.src = PDFJS.imageResourcesPath + 'annotation-' + + this.data.name.toLowerCase() + '.svg'; + image.alt = '[{{type}} Annotation]'; + image.dataset.l10nId = 'text_annotation_type'; + image.dataset.l10nArgs = JSON.stringify({type: this.data.name}); + + if (!this.data.hasPopup) { + this._createPopup(this.container, image, this.data); + } + + this.container.appendChild(image); + return this.container; + } + }); + + return TextAnnotationElement; +})(); + +/** + * @class + * @alias WidgetAnnotationElement + */ +var WidgetAnnotationElement = (function WidgetAnnotationElementClosure() { + function WidgetAnnotationElement(parameters) { + var isRenderable = !parameters.data.hasAppearance && + !!parameters.data.fieldValue; + AnnotationElement.call(this, parameters, isRenderable); + } + + Util.inherit(WidgetAnnotationElement, AnnotationElement, { + /** + * Render the widget annotation's HTML element in the empty container. + * + * @public + * @memberof WidgetAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function WidgetAnnotationElement_render() { + var content = document.createElement('div'); + content.textContent = this.data.fieldValue; + var textAlignment = this.data.textAlignment; + content.style.textAlign = ['left', 'center', 'right'][textAlignment]; + content.style.verticalAlign = 'middle'; + content.style.display = 'table-cell'; + + var font = (this.data.fontRefName ? + this.page.commonObjs.getData(this.data.fontRefName) : null); + this._setTextStyle(content, font); + + this.container.appendChild(content); + return this.container; + }, + + /** + * Apply text styles to the text in the element. + * + * @private + * @param {HTMLDivElement} element + * @param {Object} font + * @memberof WidgetAnnotationElement + */ + _setTextStyle: + function WidgetAnnotationElement_setTextStyle(element, font) { + // TODO: This duplicates some of the logic in CanvasGraphics.setFont(). + var style = element.style; + style.fontSize = this.data.fontSize + 'px'; + style.direction = (this.data.fontDirection < 0 ? 'rtl': 'ltr'); + + if (!font) { + return; + } + + style.fontWeight = (font.black ? + (font.bold ? '900' : 'bold') : + (font.bold ? 'bold' : 'normal')); + style.fontStyle = (font.italic ? 'italic' : 'normal'); + + // Use a reasonable default font if the font doesn't specify a fallback. + var fontFamily = font.loadedName ? '"' + font.loadedName + '", ' : ''; + var fallbackName = font.fallbackName || 'Helvetica, sans-serif'; + style.fontFamily = fontFamily + fallbackName; + } + }); + + return WidgetAnnotationElement; +})(); + +/** + * @class + * @alias PopupAnnotationElement + */ +var PopupAnnotationElement = (function PopupAnnotationElementClosure() { + function PopupAnnotationElement(parameters) { + var isRenderable = !!(parameters.data.title || parameters.data.contents); + AnnotationElement.call(this, parameters, isRenderable); + } + + Util.inherit(PopupAnnotationElement, AnnotationElement, { + /** + * Render the popup annotation's HTML element in the empty container. + * + * @public + * @memberof PopupAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function PopupAnnotationElement_render() { + this.container.className = 'popupAnnotation'; + + var selector = '[data-annotation-id="' + this.data.parentId + '"]'; + var parentElement = this.layer.querySelector(selector); + if (!parentElement) { + return this.container; + } + + var popup = new PopupElement({ + container: this.container, + trigger: parentElement, + color: this.data.color, + title: this.data.title, + contents: this.data.contents + }); + + // Position the popup next to the parent annotation's container. + // PDF viewers ignore a popup annotation's rectangle. + var parentLeft = parseFloat(parentElement.style.left); + var parentWidth = parseFloat(parentElement.style.width); + CustomStyle.setProp('transformOrigin', this.container, + -(parentLeft + parentWidth) + 'px -' + + parentElement.style.top); + this.container.style.left = (parentLeft + parentWidth) + 'px'; + + this.container.appendChild(popup.render()); + return this.container; + } + }); + + return PopupAnnotationElement; +})(); + +/** + * @class + * @alias PopupElement + */ +var PopupElement = (function PopupElementClosure() { + var BACKGROUND_ENLIGHT = 0.7; + + function PopupElement(parameters) { + this.container = parameters.container; + this.trigger = parameters.trigger; + this.color = parameters.color; + this.title = parameters.title; + this.contents = parameters.contents; + this.hideWrapper = parameters.hideWrapper || false; + + this.pinned = false; + } + + PopupElement.prototype = /** @lends PopupElement.prototype */ { + /** + * Render the popup's HTML element. + * + * @public + * @memberof PopupElement + * @returns {HTMLSectionElement} + */ + render: function PopupElement_render() { + var wrapper = document.createElement('div'); + wrapper.className = 'popupWrapper'; + + // For Popup annotations we hide the entire section because it contains + // only the popup. However, for Text annotations without a separate Popup + // annotation, we cannot hide the entire container as the image would + // disappear too. In that special case, hiding the wrapper suffices. + this.hideElement = (this.hideWrapper ? wrapper : this.container); + this.hideElement.setAttribute('hidden', true); + + var popup = document.createElement('div'); + popup.className = 'popup'; + + var color = this.color; + if (color) { + // Enlighten the color. + var r = BACKGROUND_ENLIGHT * (255 - color[0]) + color[0]; + var g = BACKGROUND_ENLIGHT * (255 - color[1]) + color[1]; + var b = BACKGROUND_ENLIGHT * (255 - color[2]) + color[2]; + popup.style.backgroundColor = Util.makeCssRgb(r | 0, g | 0, b | 0); + } + + var contents = this._formatContents(this.contents); + var title = document.createElement('h1'); + title.textContent = this.title; + + // Attach the event listeners to the trigger element. + this.trigger.addEventListener('click', this._toggle.bind(this)); + this.trigger.addEventListener('mouseover', this._show.bind(this, false)); + this.trigger.addEventListener('mouseout', this._hide.bind(this, false)); + popup.addEventListener('click', this._hide.bind(this, true)); + + popup.appendChild(title); + popup.appendChild(contents); + wrapper.appendChild(popup); + return wrapper; + }, + + /** + * Format the contents of the popup by adding newlines where necessary. + * + * @private + * @param {string} contents + * @memberof PopupElement + * @returns {HTMLParagraphElement} + */ + _formatContents: function PopupElement_formatContents(contents) { + var p = document.createElement('p'); + var lines = contents.split(/(?:\r\n?|\n)/); + for (var i = 0, ii = lines.length; i < ii; ++i) { + var line = lines[i]; + p.appendChild(document.createTextNode(line)); + if (i < (ii - 1)) { + p.appendChild(document.createElement('br')); + } + } + return p; + }, + + /** + * Toggle the visibility of the popup. + * + * @private + * @memberof PopupElement + */ + _toggle: function PopupElement_toggle() { + if (this.pinned) { + this._hide(true); + } else { + this._show(true); + } + }, + + /** + * Show the popup. + * + * @private + * @param {boolean} pin + * @memberof PopupElement + */ + _show: function PopupElement_show(pin) { + if (pin) { + this.pinned = true; + } + if (this.hideElement.hasAttribute('hidden')) { + this.hideElement.removeAttribute('hidden'); + this.container.style.zIndex += 1; + } + }, + + /** + * Hide the popup. + * + * @private + * @param {boolean} unpin + * @memberof PopupElement + */ + _hide: function PopupElement_hide(unpin) { + if (unpin) { + this.pinned = false; + } + if (!this.hideElement.hasAttribute('hidden') && !this.pinned) { + this.hideElement.setAttribute('hidden', true); + this.container.style.zIndex -= 1; + } + } + }; + + return PopupElement; +})(); + +/** + * @class + * @alias HighlightAnnotationElement + */ +var HighlightAnnotationElement = ( + function HighlightAnnotationElementClosure() { + function HighlightAnnotationElement(parameters) { + var isRenderable = !!(parameters.data.hasPopup || + parameters.data.title || parameters.data.contents); + AnnotationElement.call(this, parameters, isRenderable); + } + + Util.inherit(HighlightAnnotationElement, AnnotationElement, { + /** + * Render the highlight annotation's HTML element in the empty container. + * + * @public + * @memberof HighlightAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function HighlightAnnotationElement_render() { + this.container.className = 'highlightAnnotation'; + + if (!this.data.hasPopup) { + this._createPopup(this.container, null, this.data); + } + + return this.container; + } + }); + + return HighlightAnnotationElement; +})(); + +/** + * @class + * @alias UnderlineAnnotationElement + */ +var UnderlineAnnotationElement = ( + function UnderlineAnnotationElementClosure() { + function UnderlineAnnotationElement(parameters) { + var isRenderable = !!(parameters.data.hasPopup || + parameters.data.title || parameters.data.contents); + AnnotationElement.call(this, parameters, isRenderable); + } + + Util.inherit(UnderlineAnnotationElement, AnnotationElement, { + /** + * Render the underline annotation's HTML element in the empty container. + * + * @public + * @memberof UnderlineAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function UnderlineAnnotationElement_render() { + this.container.className = 'underlineAnnotation'; + + if (!this.data.hasPopup) { + this._createPopup(this.container, null, this.data); + } + + return this.container; + } + }); + + return UnderlineAnnotationElement; +})(); + +/** + * @class + * @alias SquigglyAnnotationElement + */ +var SquigglyAnnotationElement = (function SquigglyAnnotationElementClosure() { + function SquigglyAnnotationElement(parameters) { + var isRenderable = !!(parameters.data.hasPopup || + parameters.data.title || parameters.data.contents); + AnnotationElement.call(this, parameters, isRenderable); + } + + Util.inherit(SquigglyAnnotationElement, AnnotationElement, { + /** + * Render the squiggly annotation's HTML element in the empty container. + * + * @public + * @memberof SquigglyAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function SquigglyAnnotationElement_render() { + this.container.className = 'squigglyAnnotation'; + + if (!this.data.hasPopup) { + this._createPopup(this.container, null, this.data); + } + + return this.container; + } + }); + + return SquigglyAnnotationElement; +})(); + +/** + * @class + * @alias StrikeOutAnnotationElement + */ +var StrikeOutAnnotationElement = ( + function StrikeOutAnnotationElementClosure() { + function StrikeOutAnnotationElement(parameters) { + var isRenderable = !!(parameters.data.hasPopup || + parameters.data.title || parameters.data.contents); + AnnotationElement.call(this, parameters, isRenderable); + } + + Util.inherit(StrikeOutAnnotationElement, AnnotationElement, { + /** + * Render the strikeout annotation's HTML element in the empty container. + * + * @public + * @memberof StrikeOutAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function StrikeOutAnnotationElement_render() { + this.container.className = 'strikeoutAnnotation'; + + if (!this.data.hasPopup) { + this._createPopup(this.container, null, this.data); + } + + return this.container; + } + }); + + return StrikeOutAnnotationElement; +})(); + +/** + * @class + * @alias FileAttachmentAnnotationElement + */ +var FileAttachmentAnnotationElement = ( + function FileAttachmentAnnotationElementClosure() { + function FileAttachmentAnnotationElement(parameters) { + AnnotationElement.call(this, parameters, true); + + this.filename = getFilenameFromUrl(parameters.data.file.filename); + this.content = parameters.data.file.content; + } + + Util.inherit(FileAttachmentAnnotationElement, AnnotationElement, { + /** + * Render the file attachment annotation's HTML element in the empty + * container. + * + * @public + * @memberof FileAttachmentAnnotationElement + * @returns {HTMLSectionElement} + */ + render: function FileAttachmentAnnotationElement_render() { + this.container.className = 'fileAttachmentAnnotation'; + + var trigger = document.createElement('div'); + trigger.style.height = this.container.style.height; + trigger.style.width = this.container.style.width; + trigger.addEventListener('dblclick', this._download.bind(this)); + + if (!this.data.hasPopup && (this.data.title || this.data.contents)) { + this._createPopup(this.container, trigger, this.data); + } + + this.container.appendChild(trigger); + return this.container; + }, + + /** + * Download the file attachment associated with this annotation. + * + * @private + * @memberof FileAttachmentAnnotationElement + */ + _download: function FileAttachmentAnnotationElement_download() { + if (!this.downloadManager) { + warn('Download cannot be started due to unavailable download manager'); + return; + } + this.downloadManager.downloadData(this.content, this.filename, ''); + } + }); + + return FileAttachmentAnnotationElement; +})(); + +/** + * @typedef {Object} AnnotationLayerParameters + * @property {PageViewport} viewport + * @property {HTMLDivElement} div + * @property {Array} annotations + * @property {PDFPage} page + * @property {IPDFLinkService} linkService + */ + +/** + * @class + * @alias AnnotationLayer + */ +var AnnotationLayer = (function AnnotationLayerClosure() { + return { + /** + * Render a new annotation layer with all annotation elements. + * + * @public + * @param {AnnotationLayerParameters} parameters + * @memberof AnnotationLayer + */ + render: function AnnotationLayer_render(parameters) { + var annotationElementFactory = new AnnotationElementFactory(); + + for (var i = 0, ii = parameters.annotations.length; i < ii; i++) { + var data = parameters.annotations[i]; + if (!data) { + continue; + } + + var properties = { + data: data, + layer: parameters.div, + page: parameters.page, + viewport: parameters.viewport, + linkService: parameters.linkService, + downloadManager: parameters.downloadManager + }; + var element = annotationElementFactory.create(properties); + if (element.isRenderable) { + parameters.div.appendChild(element.render()); + } + } + }, + + /** + * Update the annotation elements on existing annotation layer. + * + * @public + * @param {AnnotationLayerParameters} parameters + * @memberof AnnotationLayer + */ + update: function AnnotationLayer_update(parameters) { + for (var i = 0, ii = parameters.annotations.length; i < ii; i++) { + var data = parameters.annotations[i]; + var element = parameters.div.querySelector( + '[data-annotation-id="' + data.id + '"]'); + if (element) { + CustomStyle.setProp('transform', element, + 'matrix(' + parameters.viewport.transform.join(',') + ')'); + } + } + parameters.div.removeAttribute('hidden'); + } + }; +})(); + +PDFJS.AnnotationLayer = AnnotationLayer; + +exports.AnnotationLayer = AnnotationLayer; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayPatternHelper = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayWebGL); + } +}(this, function (exports, sharedUtil, displayWebGL) { + +var Util = sharedUtil.Util; +var info = sharedUtil.info; +var isArray = sharedUtil.isArray; +var error = sharedUtil.error; +var WebGLUtils = displayWebGL.WebGLUtils; + +var ShadingIRs = {}; + +ShadingIRs.RadialAxial = { + fromIR: function RadialAxial_fromIR(raw) { + var type = raw[1]; + var colorStops = raw[2]; + var p0 = raw[3]; + var p1 = raw[4]; + var r0 = raw[5]; + var r1 = raw[6]; + return { + type: 'Pattern', + getPattern: function RadialAxial_getPattern(ctx) { + var grad; + if (type === 'axial') { + grad = ctx.createLinearGradient(p0[0], p0[1], p1[0], p1[1]); + } else if (type === 'radial') { + grad = ctx.createRadialGradient(p0[0], p0[1], r0, p1[0], p1[1], r1); + } + + for (var i = 0, ii = colorStops.length; i < ii; ++i) { + var c = colorStops[i]; + grad.addColorStop(c[0], c[1]); + } + return grad; + } + }; + } +}; + +var createMeshCanvas = (function createMeshCanvasClosure() { + function drawTriangle(data, context, p1, p2, p3, c1, c2, c3) { + // Very basic Gouraud-shaded triangle rasterization algorithm. + var coords = context.coords, colors = context.colors; + var bytes = data.data, rowSize = data.width * 4; + var tmp; + if (coords[p1 + 1] > coords[p2 + 1]) { + tmp = p1; p1 = p2; p2 = tmp; tmp = c1; c1 = c2; c2 = tmp; + } + if (coords[p2 + 1] > coords[p3 + 1]) { + tmp = p2; p2 = p3; p3 = tmp; tmp = c2; c2 = c3; c3 = tmp; + } + if (coords[p1 + 1] > coords[p2 + 1]) { + tmp = p1; p1 = p2; p2 = tmp; tmp = c1; c1 = c2; c2 = tmp; + } + var x1 = (coords[p1] + context.offsetX) * context.scaleX; + var y1 = (coords[p1 + 1] + context.offsetY) * context.scaleY; + var x2 = (coords[p2] + context.offsetX) * context.scaleX; + var y2 = (coords[p2 + 1] + context.offsetY) * context.scaleY; + var x3 = (coords[p3] + context.offsetX) * context.scaleX; + var y3 = (coords[p3 + 1] + context.offsetY) * context.scaleY; + if (y1 >= y3) { + return; + } + var c1r = colors[c1], c1g = colors[c1 + 1], c1b = colors[c1 + 2]; + var c2r = colors[c2], c2g = colors[c2 + 1], c2b = colors[c2 + 2]; + var c3r = colors[c3], c3g = colors[c3 + 1], c3b = colors[c3 + 2]; + + var minY = Math.round(y1), maxY = Math.round(y3); + var xa, car, cag, cab; + var xb, cbr, cbg, cbb; + var k; + for (var y = minY; y <= maxY; y++) { + if (y < y2) { + k = y < y1 ? 0 : y1 === y2 ? 1 : (y1 - y) / (y1 - y2); + xa = x1 - (x1 - x2) * k; + car = c1r - (c1r - c2r) * k; + cag = c1g - (c1g - c2g) * k; + cab = c1b - (c1b - c2b) * k; + } else { + k = y > y3 ? 1 : y2 === y3 ? 0 : (y2 - y) / (y2 - y3); + xa = x2 - (x2 - x3) * k; + car = c2r - (c2r - c3r) * k; + cag = c2g - (c2g - c3g) * k; + cab = c2b - (c2b - c3b) * k; + } + k = y < y1 ? 0 : y > y3 ? 1 : (y1 - y) / (y1 - y3); + xb = x1 - (x1 - x3) * k; + cbr = c1r - (c1r - c3r) * k; + cbg = c1g - (c1g - c3g) * k; + cbb = c1b - (c1b - c3b) * k; + var x1_ = Math.round(Math.min(xa, xb)); + var x2_ = Math.round(Math.max(xa, xb)); + var j = rowSize * y + x1_ * 4; + for (var x = x1_; x <= x2_; x++) { + k = (xa - x) / (xa - xb); + k = k < 0 ? 0 : k > 1 ? 1 : k; + bytes[j++] = (car - (car - cbr) * k) | 0; + bytes[j++] = (cag - (cag - cbg) * k) | 0; + bytes[j++] = (cab - (cab - cbb) * k) | 0; + bytes[j++] = 255; + } + } + } + + function drawFigure(data, figure, context) { + var ps = figure.coords; + var cs = figure.colors; + var i, ii; + switch (figure.type) { + case 'lattice': + var verticesPerRow = figure.verticesPerRow; + var rows = Math.floor(ps.length / verticesPerRow) - 1; + var cols = verticesPerRow - 1; + for (i = 0; i < rows; i++) { + var q = i * verticesPerRow; + for (var j = 0; j < cols; j++, q++) { + drawTriangle(data, context, + ps[q], ps[q + 1], ps[q + verticesPerRow], + cs[q], cs[q + 1], cs[q + verticesPerRow]); + drawTriangle(data, context, + ps[q + verticesPerRow + 1], ps[q + 1], ps[q + verticesPerRow], + cs[q + verticesPerRow + 1], cs[q + 1], cs[q + verticesPerRow]); + } + } + break; + case 'triangles': + for (i = 0, ii = ps.length; i < ii; i += 3) { + drawTriangle(data, context, + ps[i], ps[i + 1], ps[i + 2], + cs[i], cs[i + 1], cs[i + 2]); + } + break; + default: + error('illigal figure'); + break; + } + } + + function createMeshCanvas(bounds, combinesScale, coords, colors, figures, + backgroundColor, cachedCanvases) { + // we will increase scale on some weird factor to let antialiasing take + // care of "rough" edges + var EXPECTED_SCALE = 1.1; + // MAX_PATTERN_SIZE is used to avoid OOM situation. + var MAX_PATTERN_SIZE = 3000; // 10in @ 300dpi shall be enough + + var offsetX = Math.floor(bounds[0]); + var offsetY = Math.floor(bounds[1]); + var boundsWidth = Math.ceil(bounds[2]) - offsetX; + var boundsHeight = Math.ceil(bounds[3]) - offsetY; + + var width = Math.min(Math.ceil(Math.abs(boundsWidth * combinesScale[0] * + EXPECTED_SCALE)), MAX_PATTERN_SIZE); + var height = Math.min(Math.ceil(Math.abs(boundsHeight * combinesScale[1] * + EXPECTED_SCALE)), MAX_PATTERN_SIZE); + var scaleX = boundsWidth / width; + var scaleY = boundsHeight / height; + + var context = { + coords: coords, + colors: colors, + offsetX: -offsetX, + offsetY: -offsetY, + scaleX: 1 / scaleX, + scaleY: 1 / scaleY + }; + + var canvas, tmpCanvas, i, ii; + if (WebGLUtils.isEnabled) { + canvas = WebGLUtils.drawFigures(width, height, backgroundColor, + figures, context); + + // https://bugzilla.mozilla.org/show_bug.cgi?id=972126 + tmpCanvas = cachedCanvases.getCanvas('mesh', width, height, false); + tmpCanvas.context.drawImage(canvas, 0, 0); + canvas = tmpCanvas.canvas; + } else { + tmpCanvas = cachedCanvases.getCanvas('mesh', width, height, false); + var tmpCtx = tmpCanvas.context; + + var data = tmpCtx.createImageData(width, height); + if (backgroundColor) { + var bytes = data.data; + for (i = 0, ii = bytes.length; i < ii; i += 4) { + bytes[i] = backgroundColor[0]; + bytes[i + 1] = backgroundColor[1]; + bytes[i + 2] = backgroundColor[2]; + bytes[i + 3] = 255; + } + } + for (i = 0; i < figures.length; i++) { + drawFigure(data, figures[i], context); + } + tmpCtx.putImageData(data, 0, 0); + canvas = tmpCanvas.canvas; + } + + return {canvas: canvas, offsetX: offsetX, offsetY: offsetY, + scaleX: scaleX, scaleY: scaleY}; + } + return createMeshCanvas; +})(); + +ShadingIRs.Mesh = { + fromIR: function Mesh_fromIR(raw) { + //var type = raw[1]; + var coords = raw[2]; + var colors = raw[3]; + var figures = raw[4]; + var bounds = raw[5]; + var matrix = raw[6]; + //var bbox = raw[7]; + var background = raw[8]; + return { + type: 'Pattern', + getPattern: function Mesh_getPattern(ctx, owner, shadingFill) { + var scale; + if (shadingFill) { + scale = Util.singularValueDecompose2dScale(ctx.mozCurrentTransform); + } else { + // Obtain scale from matrix and current transformation matrix. + scale = Util.singularValueDecompose2dScale(owner.baseTransform); + if (matrix) { + var matrixScale = Util.singularValueDecompose2dScale(matrix); + scale = [scale[0] * matrixScale[0], + scale[1] * matrixScale[1]]; + } + } + + + // Rasterizing on the main thread since sending/queue large canvases + // might cause OOM. + var temporaryPatternCanvas = createMeshCanvas(bounds, scale, coords, + colors, figures, shadingFill ? null : background, + owner.cachedCanvases); + + if (!shadingFill) { + ctx.setTransform.apply(ctx, owner.baseTransform); + if (matrix) { + ctx.transform.apply(ctx, matrix); + } + } + + ctx.translate(temporaryPatternCanvas.offsetX, + temporaryPatternCanvas.offsetY); + ctx.scale(temporaryPatternCanvas.scaleX, + temporaryPatternCanvas.scaleY); + + return ctx.createPattern(temporaryPatternCanvas.canvas, 'no-repeat'); + } + }; + } +}; + +ShadingIRs.Dummy = { + fromIR: function Dummy_fromIR() { + return { + type: 'Pattern', + getPattern: function Dummy_fromIR_getPattern() { + return 'hotpink'; + } + }; + } +}; + +function getShadingPatternFromIR(raw) { + var shadingIR = ShadingIRs[raw[0]]; + if (!shadingIR) { + error('Unknown IR type: ' + raw[0]); + } + return shadingIR.fromIR(raw); +} + +var TilingPattern = (function TilingPatternClosure() { + var PaintType = { + COLORED: 1, + UNCOLORED: 2 + }; + + var MAX_PATTERN_SIZE = 3000; // 10in @ 300dpi shall be enough + + function TilingPattern(IR, color, ctx, canvasGraphicsFactory, baseTransform) { + this.operatorList = IR[2]; + this.matrix = IR[3] || [1, 0, 0, 1, 0, 0]; + this.bbox = IR[4]; + this.xstep = IR[5]; + this.ystep = IR[6]; + this.paintType = IR[7]; + this.tilingType = IR[8]; + this.color = color; + this.canvasGraphicsFactory = canvasGraphicsFactory; + this.baseTransform = baseTransform; + this.type = 'Pattern'; + this.ctx = ctx; + } + + TilingPattern.prototype = { + createPatternCanvas: function TilinPattern_createPatternCanvas(owner) { + var operatorList = this.operatorList; + var bbox = this.bbox; + var xstep = this.xstep; + var ystep = this.ystep; + var paintType = this.paintType; + var tilingType = this.tilingType; + var color = this.color; + var canvasGraphicsFactory = this.canvasGraphicsFactory; + + info('TilingType: ' + tilingType); + + var x0 = bbox[0], y0 = bbox[1], x1 = bbox[2], y1 = bbox[3]; + + var topLeft = [x0, y0]; + // we want the canvas to be as large as the step size + var botRight = [x0 + xstep, y0 + ystep]; + + var width = botRight[0] - topLeft[0]; + var height = botRight[1] - topLeft[1]; + + // Obtain scale from matrix and current transformation matrix. + var matrixScale = Util.singularValueDecompose2dScale(this.matrix); + var curMatrixScale = Util.singularValueDecompose2dScale( + this.baseTransform); + var combinedScale = [matrixScale[0] * curMatrixScale[0], + matrixScale[1] * curMatrixScale[1]]; + + // MAX_PATTERN_SIZE is used to avoid OOM situation. + // Use width and height values that are as close as possible to the end + // result when the pattern is used. Too low value makes the pattern look + // blurry. Too large value makes it look too crispy. + width = Math.min(Math.ceil(Math.abs(width * combinedScale[0])), + MAX_PATTERN_SIZE); + + height = Math.min(Math.ceil(Math.abs(height * combinedScale[1])), + MAX_PATTERN_SIZE); + + var tmpCanvas = owner.cachedCanvases.getCanvas('pattern', + width, height, true); + var tmpCtx = tmpCanvas.context; + var graphics = canvasGraphicsFactory.createCanvasGraphics(tmpCtx); + graphics.groupLevel = owner.groupLevel; + + this.setFillAndStrokeStyleToContext(tmpCtx, paintType, color); + + this.setScale(width, height, xstep, ystep); + this.transformToScale(graphics); + + // transform coordinates to pattern space + var tmpTranslate = [1, 0, 0, 1, -topLeft[0], -topLeft[1]]; + graphics.transform.apply(graphics, tmpTranslate); + + this.clipBbox(graphics, bbox, x0, y0, x1, y1); + + graphics.executeOperatorList(operatorList); + return tmpCanvas.canvas; + }, + + setScale: function TilingPattern_setScale(width, height, xstep, ystep) { + this.scale = [width / xstep, height / ystep]; + }, + + transformToScale: function TilingPattern_transformToScale(graphics) { + var scale = this.scale; + var tmpScale = [scale[0], 0, 0, scale[1], 0, 0]; + graphics.transform.apply(graphics, tmpScale); + }, + + scaleToContext: function TilingPattern_scaleToContext() { + var scale = this.scale; + this.ctx.scale(1 / scale[0], 1 / scale[1]); + }, + + clipBbox: function clipBbox(graphics, bbox, x0, y0, x1, y1) { + if (bbox && isArray(bbox) && bbox.length === 4) { + var bboxWidth = x1 - x0; + var bboxHeight = y1 - y0; + graphics.ctx.rect(x0, y0, bboxWidth, bboxHeight); + graphics.clip(); + graphics.endPath(); + } + }, + + setFillAndStrokeStyleToContext: + function setFillAndStrokeStyleToContext(context, paintType, color) { + switch (paintType) { + case PaintType.COLORED: + var ctx = this.ctx; + context.fillStyle = ctx.fillStyle; + context.strokeStyle = ctx.strokeStyle; + break; + case PaintType.UNCOLORED: + var cssColor = Util.makeCssRgb(color[0], color[1], color[2]); + context.fillStyle = cssColor; + context.strokeStyle = cssColor; + break; + default: + error('Unsupported paint type: ' + paintType); + } + }, + + getPattern: function TilingPattern_getPattern(ctx, owner) { + var temporaryPatternCanvas = this.createPatternCanvas(owner); + + ctx = this.ctx; + ctx.setTransform.apply(ctx, this.baseTransform); + ctx.transform.apply(ctx, this.matrix); + this.scaleToContext(); + + return ctx.createPattern(temporaryPatternCanvas, 'repeat'); + } + }; + + return TilingPattern; +})(); + +exports.getShadingPatternFromIR = getShadingPatternFromIR; +exports.TilingPattern = TilingPattern; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayTextLayer = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayDOMUtils, root.pdfjsDisplayGlobal); + } +}(this, function (exports, sharedUtil, displayDOMUtils, displayGlobal) { + +var Util = sharedUtil.Util; +var createPromiseCapability = sharedUtil.createPromiseCapability; +var CustomStyle = displayDOMUtils.CustomStyle; +var PDFJS = displayGlobal.PDFJS; + +/** + * Text layer render parameters. + * + * @typedef {Object} TextLayerRenderParameters + * @property {TextContent} textContent - Text content to render (the object is + * returned by the page's getTextContent() method). + * @property {HTMLElement} container - HTML element that will contain text runs. + * @property {PDFJS.PageViewport} viewport - The target viewport to properly + * layout the text runs. + * @property {Array} textDivs - (optional) HTML elements that are correspond + * the text items of the textContent input. This is output and shall be + * initially be set to empty array. + * @property {number} timeout - (optional) Delay in milliseconds before + * rendering of the text runs occurs. + */ +var renderTextLayer = (function renderTextLayerClosure() { + var MAX_TEXT_DIVS_TO_RENDER = 100000; + + var NonWhitespaceRegexp = /\S/; + + function isAllWhitespace(str) { + return !NonWhitespaceRegexp.test(str); + } + + function appendText(textDivs, viewport, geom, styles) { + var style = styles[geom.fontName]; + var textDiv = document.createElement('div'); + textDivs.push(textDiv); + if (isAllWhitespace(geom.str)) { + textDiv.dataset.isWhitespace = true; + return; + } + var tx = Util.transform(viewport.transform, geom.transform); + var angle = Math.atan2(tx[1], tx[0]); + if (style.vertical) { + angle += Math.PI / 2; + } + var fontHeight = Math.sqrt((tx[2] * tx[2]) + (tx[3] * tx[3])); + var fontAscent = fontHeight; + if (style.ascent) { + fontAscent = style.ascent * fontAscent; + } else if (style.descent) { + fontAscent = (1 + style.descent) * fontAscent; + } + + var left; + var top; + if (angle === 0) { + left = tx[4]; + top = tx[5] - fontAscent; + } else { + left = tx[4] + (fontAscent * Math.sin(angle)); + top = tx[5] - (fontAscent * Math.cos(angle)); + } + textDiv.style.left = left + 'px'; + textDiv.style.top = top + 'px'; + textDiv.style.fontSize = fontHeight + 'px'; + textDiv.style.fontFamily = style.fontFamily; + + textDiv.textContent = geom.str; + // |fontName| is only used by the Font Inspector. This test will succeed + // when e.g. the Font Inspector is off but the Stepper is on, but it's + // not worth the effort to do a more accurate test. + if (PDFJS.pdfBug) { + textDiv.dataset.fontName = geom.fontName; + } + // Storing into dataset will convert number into string. + if (angle !== 0) { + textDiv.dataset.angle = angle * (180 / Math.PI); + } + // We don't bother scaling single-char text divs, because it has very + // little effect on text highlighting. This makes scrolling on docs with + // lots of such divs a lot faster. + if (geom.str.length > 1) { + if (style.vertical) { + textDiv.dataset.canvasWidth = geom.height * viewport.scale; + } else { + textDiv.dataset.canvasWidth = geom.width * viewport.scale; + } + } + } + + function render(task) { + if (task._canceled) { + return; + } + var textLayerFrag = task._container; + var textDivs = task._textDivs; + var capability = task._capability; + var textDivsLength = textDivs.length; + + // No point in rendering many divs as it would make the browser + // unusable even after the divs are rendered. + if (textDivsLength > MAX_TEXT_DIVS_TO_RENDER) { + capability.resolve(); + return; + } + + var canvas = document.createElement('canvas'); + canvas.mozOpaque = true; + var ctx = canvas.getContext('2d', {alpha: false}); + + var lastFontSize; + var lastFontFamily; + for (var i = 0; i < textDivsLength; i++) { + var textDiv = textDivs[i]; + if (textDiv.dataset.isWhitespace !== undefined) { + continue; + } + + var fontSize = textDiv.style.fontSize; + var fontFamily = textDiv.style.fontFamily; + + // Only build font string and set to context if different from last. + if (fontSize !== lastFontSize || fontFamily !== lastFontFamily) { + ctx.font = fontSize + ' ' + fontFamily; + lastFontSize = fontSize; + lastFontFamily = fontFamily; + } + + var width = ctx.measureText(textDiv.textContent).width; + if (width > 0) { + textLayerFrag.appendChild(textDiv); + var transform; + if (textDiv.dataset.canvasWidth !== undefined) { + // Dataset values come of type string. + var textScale = textDiv.dataset.canvasWidth / width; + transform = 'scaleX(' + textScale + ')'; + } else { + transform = ''; + } + var rotation = textDiv.dataset.angle; + if (rotation) { + transform = 'rotate(' + rotation + 'deg) ' + transform; + } + if (transform) { + CustomStyle.setProp('transform' , textDiv, transform); + } + } + } + capability.resolve(); + } + + /** + * Text layer rendering task. + * + * @param {TextContent} textContent + * @param {HTMLElement} container + * @param {PDFJS.PageViewport} viewport + * @param {Array} textDivs + * @private + */ + function TextLayerRenderTask(textContent, container, viewport, textDivs) { + this._textContent = textContent; + this._container = container; + this._viewport = viewport; + textDivs = textDivs || []; + this._textDivs = textDivs; + this._canceled = false; + this._capability = createPromiseCapability(); + this._renderTimer = null; + } + TextLayerRenderTask.prototype = { + get promise() { + return this._capability.promise; + }, + + cancel: function TextLayer_cancel() { + this._canceled = true; + if (this._renderTimer !== null) { + clearTimeout(this._renderTimer); + this._renderTimer = null; + } + this._capability.reject('canceled'); + }, + + _render: function TextLayer_render(timeout) { + var textItems = this._textContent.items; + var styles = this._textContent.styles; + var textDivs = this._textDivs; + var viewport = this._viewport; + for (var i = 0, len = textItems.length; i < len; i++) { + appendText(textDivs, viewport, textItems[i], styles); + } + + if (!timeout) { // Render right away + render(this); + } else { // Schedule + var self = this; + this._renderTimer = setTimeout(function() { + render(self); + self._renderTimer = null; + }, timeout); + } + } + }; + + + /** + * Starts rendering of the text layer. + * + * @param {TextLayerRenderParameters} renderParameters + * @returns {TextLayerRenderTask} + */ + function renderTextLayer(renderParameters) { + var task = new TextLayerRenderTask(renderParameters.textContent, + renderParameters.container, + renderParameters.viewport, + renderParameters.textDivs); + task._render(renderParameters.timeout); + return task; + } + + return renderTextLayer; +})(); + +PDFJS.renderTextLayer = renderTextLayer; + +exports.renderTextLayer = renderTextLayer; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayCanvas = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayDOMUtils, root.pdfjsDisplayPatternHelper, + root.pdfjsDisplayWebGL); + } +}(this, function (exports, sharedUtil, displayDOMUtils, displayPatternHelper, + displayWebGL) { + +var FONT_IDENTITY_MATRIX = sharedUtil.FONT_IDENTITY_MATRIX; +var IDENTITY_MATRIX = sharedUtil.IDENTITY_MATRIX; +var ImageKind = sharedUtil.ImageKind; +var OPS = sharedUtil.OPS; +var TextRenderingMode = sharedUtil.TextRenderingMode; +var Uint32ArrayView = sharedUtil.Uint32ArrayView; +var Util = sharedUtil.Util; +var assert = sharedUtil.assert; +var info = sharedUtil.info; +var isNum = sharedUtil.isNum; +var isArray = sharedUtil.isArray; +var error = sharedUtil.error; +var shadow = sharedUtil.shadow; +var warn = sharedUtil.warn; +var TilingPattern = displayPatternHelper.TilingPattern; +var getShadingPatternFromIR = displayPatternHelper.getShadingPatternFromIR; +var WebGLUtils = displayWebGL.WebGLUtils; + +// contexts store most of the state we need natively. +// However, PDF needs a bit more state, which we store here. + +// Minimal font size that would be used during canvas fillText operations. +var MIN_FONT_SIZE = 16; +// Maximum font size that would be used during canvas fillText operations. +var MAX_FONT_SIZE = 100; +var MAX_GROUP_SIZE = 4096; + +// Heuristic value used when enforcing minimum line widths. +var MIN_WIDTH_FACTOR = 0.65; + +var COMPILE_TYPE3_GLYPHS = true; +var MAX_SIZE_TO_COMPILE = 1000; + +var FULL_CHUNK_HEIGHT = 16; + +function createScratchCanvas(width, height) { + var canvas = document.createElement('canvas'); + canvas.width = width; + canvas.height = height; + return canvas; +} + +function addContextCurrentTransform(ctx) { + // If the context doesn't expose a `mozCurrentTransform`, add a JS based one. + if (!ctx.mozCurrentTransform) { + ctx._originalSave = ctx.save; + ctx._originalRestore = ctx.restore; + ctx._originalRotate = ctx.rotate; + ctx._originalScale = ctx.scale; + ctx._originalTranslate = ctx.translate; + ctx._originalTransform = ctx.transform; + ctx._originalSetTransform = ctx.setTransform; + + ctx._transformMatrix = ctx._transformMatrix || [1, 0, 0, 1, 0, 0]; + ctx._transformStack = []; + + Object.defineProperty(ctx, 'mozCurrentTransform', { + get: function getCurrentTransform() { + return this._transformMatrix; + } + }); + + Object.defineProperty(ctx, 'mozCurrentTransformInverse', { + get: function getCurrentTransformInverse() { + // Calculation done using WolframAlpha: + // http://www.wolframalpha.com/input/? + // i=Inverse+{{a%2C+c%2C+e}%2C+{b%2C+d%2C+f}%2C+{0%2C+0%2C+1}} + + var m = this._transformMatrix; + var a = m[0], b = m[1], c = m[2], d = m[3], e = m[4], f = m[5]; + + var ad_bc = a * d - b * c; + var bc_ad = b * c - a * d; + + return [ + d / ad_bc, + b / bc_ad, + c / bc_ad, + a / ad_bc, + (d * e - c * f) / bc_ad, + (b * e - a * f) / ad_bc + ]; + } + }); + + ctx.save = function ctxSave() { + var old = this._transformMatrix; + this._transformStack.push(old); + this._transformMatrix = old.slice(0, 6); + + this._originalSave(); + }; + + ctx.restore = function ctxRestore() { + var prev = this._transformStack.pop(); + if (prev) { + this._transformMatrix = prev; + this._originalRestore(); + } + }; + + ctx.translate = function ctxTranslate(x, y) { + var m = this._transformMatrix; + m[4] = m[0] * x + m[2] * y + m[4]; + m[5] = m[1] * x + m[3] * y + m[5]; + + this._originalTranslate(x, y); + }; + + ctx.scale = function ctxScale(x, y) { + var m = this._transformMatrix; + m[0] = m[0] * x; + m[1] = m[1] * x; + m[2] = m[2] * y; + m[3] = m[3] * y; + + this._originalScale(x, y); + }; + + ctx.transform = function ctxTransform(a, b, c, d, e, f) { + var m = this._transformMatrix; + this._transformMatrix = [ + m[0] * a + m[2] * b, + m[1] * a + m[3] * b, + m[0] * c + m[2] * d, + m[1] * c + m[3] * d, + m[0] * e + m[2] * f + m[4], + m[1] * e + m[3] * f + m[5] + ]; + + ctx._originalTransform(a, b, c, d, e, f); + }; + + ctx.setTransform = function ctxSetTransform(a, b, c, d, e, f) { + this._transformMatrix = [a, b, c, d, e, f]; + + ctx._originalSetTransform(a, b, c, d, e, f); + }; + + ctx.rotate = function ctxRotate(angle) { + var cosValue = Math.cos(angle); + var sinValue = Math.sin(angle); + + var m = this._transformMatrix; + this._transformMatrix = [ + m[0] * cosValue + m[2] * sinValue, + m[1] * cosValue + m[3] * sinValue, + m[0] * (-sinValue) + m[2] * cosValue, + m[1] * (-sinValue) + m[3] * cosValue, + m[4], + m[5] + ]; + + this._originalRotate(angle); + }; + } +} + +var CachedCanvases = (function CachedCanvasesClosure() { + function CachedCanvases() { + this.cache = Object.create(null); + } + CachedCanvases.prototype = { + getCanvas: function CachedCanvases_getCanvas(id, width, height, + trackTransform) { + var canvasEntry; + if (this.cache[id] !== undefined) { + canvasEntry = this.cache[id]; + canvasEntry.canvas.width = width; + canvasEntry.canvas.height = height; + // reset canvas transform for emulated mozCurrentTransform, if needed + canvasEntry.context.setTransform(1, 0, 0, 1, 0, 0); + } else { + var canvas = createScratchCanvas(width, height); + var ctx = canvas.getContext('2d'); + if (trackTransform) { + addContextCurrentTransform(ctx); + } + this.cache[id] = canvasEntry = {canvas: canvas, context: ctx}; + } + return canvasEntry; + }, + clear: function () { + for (var id in this.cache) { + var canvasEntry = this.cache[id]; + // Zeroing the width and height causes Firefox to release graphics + // resources immediately, which can greatly reduce memory consumption. + canvasEntry.canvas.width = 0; + canvasEntry.canvas.height = 0; + delete this.cache[id]; + } + } + }; + return CachedCanvases; +})(); + +function compileType3Glyph(imgData) { + var POINT_TO_PROCESS_LIMIT = 1000; + + var width = imgData.width, height = imgData.height; + var i, j, j0, width1 = width + 1; + var points = new Uint8Array(width1 * (height + 1)); + var POINT_TYPES = + new Uint8Array([0, 2, 4, 0, 1, 0, 5, 4, 8, 10, 0, 8, 0, 2, 1, 0]); + + // decodes bit-packed mask data + var lineSize = (width + 7) & ~7, data0 = imgData.data; + var data = new Uint8Array(lineSize * height), pos = 0, ii; + for (i = 0, ii = data0.length; i < ii; i++) { + var mask = 128, elem = data0[i]; + while (mask > 0) { + data[pos++] = (elem & mask) ? 0 : 255; + mask >>= 1; + } + } + + // finding iteresting points: every point is located between mask pixels, + // so there will be points of the (width + 1)x(height + 1) grid. Every point + // will have flags assigned based on neighboring mask pixels: + // 4 | 8 + // --P-- + // 2 | 1 + // We are interested only in points with the flags: + // - outside corners: 1, 2, 4, 8; + // - inside corners: 7, 11, 13, 14; + // - and, intersections: 5, 10. + var count = 0; + pos = 0; + if (data[pos] !== 0) { + points[0] = 1; + ++count; + } + for (j = 1; j < width; j++) { + if (data[pos] !== data[pos + 1]) { + points[j] = data[pos] ? 2 : 1; + ++count; + } + pos++; + } + if (data[pos] !== 0) { + points[j] = 2; + ++count; + } + for (i = 1; i < height; i++) { + pos = i * lineSize; + j0 = i * width1; + if (data[pos - lineSize] !== data[pos]) { + points[j0] = data[pos] ? 1 : 8; + ++count; + } + // 'sum' is the position of the current pixel configuration in the 'TYPES' + // array (in order 8-1-2-4, so we can use '>>2' to shift the column). + var sum = (data[pos] ? 4 : 0) + (data[pos - lineSize] ? 8 : 0); + for (j = 1; j < width; j++) { + sum = (sum >> 2) + (data[pos + 1] ? 4 : 0) + + (data[pos - lineSize + 1] ? 8 : 0); + if (POINT_TYPES[sum]) { + points[j0 + j] = POINT_TYPES[sum]; + ++count; + } + pos++; + } + if (data[pos - lineSize] !== data[pos]) { + points[j0 + j] = data[pos] ? 2 : 4; + ++count; + } + + if (count > POINT_TO_PROCESS_LIMIT) { + return null; + } + } + + pos = lineSize * (height - 1); + j0 = i * width1; + if (data[pos] !== 0) { + points[j0] = 8; + ++count; + } + for (j = 1; j < width; j++) { + if (data[pos] !== data[pos + 1]) { + points[j0 + j] = data[pos] ? 4 : 8; + ++count; + } + pos++; + } + if (data[pos] !== 0) { + points[j0 + j] = 4; + ++count; + } + if (count > POINT_TO_PROCESS_LIMIT) { + return null; + } + + // building outlines + var steps = new Int32Array([0, width1, -1, 0, -width1, 0, 0, 0, 1]); + var outlines = []; + for (i = 0; count && i <= height; i++) { + var p = i * width1; + var end = p + width; + while (p < end && !points[p]) { + p++; + } + if (p === end) { + continue; + } + var coords = [p % width1, i]; + + var type = points[p], p0 = p, pp; + do { + var step = steps[type]; + do { + p += step; + } while (!points[p]); + + pp = points[p]; + if (pp !== 5 && pp !== 10) { + // set new direction + type = pp; + // delete mark + points[p] = 0; + } else { // type is 5 or 10, ie, a crossing + // set new direction + type = pp & ((0x33 * type) >> 4); + // set new type for "future hit" + points[p] &= (type >> 2 | type << 2); + } + + coords.push(p % width1); + coords.push((p / width1) | 0); + --count; + } while (p0 !== p); + outlines.push(coords); + --i; + } + + var drawOutline = function(c) { + c.save(); + // the path shall be painted in [0..1]x[0..1] space + c.scale(1 / width, -1 / height); + c.translate(0, -height); + c.beginPath(); + for (var i = 0, ii = outlines.length; i < ii; i++) { + var o = outlines[i]; + c.moveTo(o[0], o[1]); + for (var j = 2, jj = o.length; j < jj; j += 2) { + c.lineTo(o[j], o[j+1]); + } + } + c.fill(); + c.beginPath(); + c.restore(); + }; + + return drawOutline; +} + +var CanvasExtraState = (function CanvasExtraStateClosure() { + function CanvasExtraState(old) { + // Are soft masks and alpha values shapes or opacities? + this.alphaIsShape = false; + this.fontSize = 0; + this.fontSizeScale = 1; + this.textMatrix = IDENTITY_MATRIX; + this.textMatrixScale = 1; + this.fontMatrix = FONT_IDENTITY_MATRIX; + this.leading = 0; + // Current point (in user coordinates) + this.x = 0; + this.y = 0; + // Start of text line (in text coordinates) + this.lineX = 0; + this.lineY = 0; + // Character and word spacing + this.charSpacing = 0; + this.wordSpacing = 0; + this.textHScale = 1; + this.textRenderingMode = TextRenderingMode.FILL; + this.textRise = 0; + // Default fore and background colors + this.fillColor = '#000000'; + this.strokeColor = '#000000'; + this.patternFill = false; + // Note: fill alpha applies to all non-stroking operations + this.fillAlpha = 1; + this.strokeAlpha = 1; + this.lineWidth = 1; + this.activeSMask = null; // nonclonable field (see the save method below) + + this.old = old; + } + + CanvasExtraState.prototype = { + clone: function CanvasExtraState_clone() { + return Object.create(this); + }, + setCurrentPoint: function CanvasExtraState_setCurrentPoint(x, y) { + this.x = x; + this.y = y; + } + }; + return CanvasExtraState; +})(); + +var CanvasGraphics = (function CanvasGraphicsClosure() { + // Defines the time the executeOperatorList is going to be executing + // before it stops and shedules a continue of execution. + var EXECUTION_TIME = 15; + // Defines the number of steps before checking the execution time + var EXECUTION_STEPS = 10; + + function CanvasGraphics(canvasCtx, commonObjs, objs, imageLayer) { + this.ctx = canvasCtx; + this.current = new CanvasExtraState(); + this.stateStack = []; + this.pendingClip = null; + this.pendingEOFill = false; + this.res = null; + this.xobjs = null; + this.commonObjs = commonObjs; + this.objs = objs; + this.imageLayer = imageLayer; + this.groupStack = []; + this.processingType3 = null; + // Patterns are painted relative to the initial page/form transform, see pdf + // spec 8.7.2 NOTE 1. + this.baseTransform = null; + this.baseTransformStack = []; + this.groupLevel = 0; + this.smaskStack = []; + this.smaskCounter = 0; + this.tempSMask = null; + this.cachedCanvases = new CachedCanvases(); + if (canvasCtx) { + // NOTE: if mozCurrentTransform is polyfilled, then the current state of + // the transformation must already be set in canvasCtx._transformMatrix. + addContextCurrentTransform(canvasCtx); + } + this.cachedGetSinglePixelWidth = null; + } + + function putBinaryImageData(ctx, imgData) { + if (typeof ImageData !== 'undefined' && imgData instanceof ImageData) { + ctx.putImageData(imgData, 0, 0); + return; + } + + // Put the image data to the canvas in chunks, rather than putting the + // whole image at once. This saves JS memory, because the ImageData object + // is smaller. It also possibly saves C++ memory within the implementation + // of putImageData(). (E.g. in Firefox we make two short-lived copies of + // the data passed to putImageData()). |n| shouldn't be too small, however, + // because too many putImageData() calls will slow things down. + // + // Note: as written, if the last chunk is partial, the putImageData() call + // will (conceptually) put pixels past the bounds of the canvas. But + // that's ok; any such pixels are ignored. + + var height = imgData.height, width = imgData.width; + var partialChunkHeight = height % FULL_CHUNK_HEIGHT; + var fullChunks = (height - partialChunkHeight) / FULL_CHUNK_HEIGHT; + var totalChunks = partialChunkHeight === 0 ? fullChunks : fullChunks + 1; + + var chunkImgData = ctx.createImageData(width, FULL_CHUNK_HEIGHT); + var srcPos = 0, destPos; + var src = imgData.data; + var dest = chunkImgData.data; + var i, j, thisChunkHeight, elemsInThisChunk; + + // There are multiple forms in which the pixel data can be passed, and + // imgData.kind tells us which one this is. + if (imgData.kind === ImageKind.GRAYSCALE_1BPP) { + // Grayscale, 1 bit per pixel (i.e. black-and-white). + var srcLength = src.byteLength; + var dest32 = PDFJS.hasCanvasTypedArrays ? new Uint32Array(dest.buffer) : + new Uint32ArrayView(dest); + var dest32DataLength = dest32.length; + var fullSrcDiff = (width + 7) >> 3; + var white = 0xFFFFFFFF; + var black = (PDFJS.isLittleEndian || !PDFJS.hasCanvasTypedArrays) ? + 0xFF000000 : 0x000000FF; + for (i = 0; i < totalChunks; i++) { + thisChunkHeight = + (i < fullChunks) ? FULL_CHUNK_HEIGHT : partialChunkHeight; + destPos = 0; + for (j = 0; j < thisChunkHeight; j++) { + var srcDiff = srcLength - srcPos; + var k = 0; + var kEnd = (srcDiff > fullSrcDiff) ? width : srcDiff * 8 - 7; + var kEndUnrolled = kEnd & ~7; + var mask = 0; + var srcByte = 0; + for (; k < kEndUnrolled; k += 8) { + srcByte = src[srcPos++]; + dest32[destPos++] = (srcByte & 128) ? white : black; + dest32[destPos++] = (srcByte & 64) ? white : black; + dest32[destPos++] = (srcByte & 32) ? white : black; + dest32[destPos++] = (srcByte & 16) ? white : black; + dest32[destPos++] = (srcByte & 8) ? white : black; + dest32[destPos++] = (srcByte & 4) ? white : black; + dest32[destPos++] = (srcByte & 2) ? white : black; + dest32[destPos++] = (srcByte & 1) ? white : black; + } + for (; k < kEnd; k++) { + if (mask === 0) { + srcByte = src[srcPos++]; + mask = 128; + } + + dest32[destPos++] = (srcByte & mask) ? white : black; + mask >>= 1; + } + } + // We ran out of input. Make all remaining pixels transparent. + while (destPos < dest32DataLength) { + dest32[destPos++] = 0; + } + + ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT); + } + } else if (imgData.kind === ImageKind.RGBA_32BPP) { + // RGBA, 32-bits per pixel. + + j = 0; + elemsInThisChunk = width * FULL_CHUNK_HEIGHT * 4; + for (i = 0; i < fullChunks; i++) { + dest.set(src.subarray(srcPos, srcPos + elemsInThisChunk)); + srcPos += elemsInThisChunk; + + ctx.putImageData(chunkImgData, 0, j); + j += FULL_CHUNK_HEIGHT; + } + if (i < totalChunks) { + elemsInThisChunk = width * partialChunkHeight * 4; + dest.set(src.subarray(srcPos, srcPos + elemsInThisChunk)); + ctx.putImageData(chunkImgData, 0, j); + } + + } else if (imgData.kind === ImageKind.RGB_24BPP) { + // RGB, 24-bits per pixel. + thisChunkHeight = FULL_CHUNK_HEIGHT; + elemsInThisChunk = width * thisChunkHeight; + for (i = 0; i < totalChunks; i++) { + if (i >= fullChunks) { + thisChunkHeight = partialChunkHeight; + elemsInThisChunk = width * thisChunkHeight; + } + + destPos = 0; + for (j = elemsInThisChunk; j--;) { + dest[destPos++] = src[srcPos++]; + dest[destPos++] = src[srcPos++]; + dest[destPos++] = src[srcPos++]; + dest[destPos++] = 255; + } + ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT); + } + } else { + error('bad image kind: ' + imgData.kind); + } + } + + function putBinaryImageMask(ctx, imgData) { + var height = imgData.height, width = imgData.width; + var partialChunkHeight = height % FULL_CHUNK_HEIGHT; + var fullChunks = (height - partialChunkHeight) / FULL_CHUNK_HEIGHT; + var totalChunks = partialChunkHeight === 0 ? fullChunks : fullChunks + 1; + + var chunkImgData = ctx.createImageData(width, FULL_CHUNK_HEIGHT); + var srcPos = 0; + var src = imgData.data; + var dest = chunkImgData.data; + + for (var i = 0; i < totalChunks; i++) { + var thisChunkHeight = + (i < fullChunks) ? FULL_CHUNK_HEIGHT : partialChunkHeight; + + // Expand the mask so it can be used by the canvas. Any required + // inversion has already been handled. + var destPos = 3; // alpha component offset + for (var j = 0; j < thisChunkHeight; j++) { + var mask = 0; + for (var k = 0; k < width; k++) { + if (!mask) { + var elem = src[srcPos++]; + mask = 128; + } + dest[destPos] = (elem & mask) ? 0 : 255; + destPos += 4; + mask >>= 1; + } + } + ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT); + } + } + + function copyCtxState(sourceCtx, destCtx) { + var properties = ['strokeStyle', 'fillStyle', 'fillRule', 'globalAlpha', + 'lineWidth', 'lineCap', 'lineJoin', 'miterLimit', + 'globalCompositeOperation', 'font']; + for (var i = 0, ii = properties.length; i < ii; i++) { + var property = properties[i]; + if (sourceCtx[property] !== undefined) { + destCtx[property] = sourceCtx[property]; + } + } + if (sourceCtx.setLineDash !== undefined) { + destCtx.setLineDash(sourceCtx.getLineDash()); + destCtx.lineDashOffset = sourceCtx.lineDashOffset; + } else if (sourceCtx.mozDashOffset !== undefined) { + destCtx.mozDash = sourceCtx.mozDash; + destCtx.mozDashOffset = sourceCtx.mozDashOffset; + } + } + + function composeSMaskBackdrop(bytes, r0, g0, b0) { + var length = bytes.length; + for (var i = 3; i < length; i += 4) { + var alpha = bytes[i]; + if (alpha === 0) { + bytes[i - 3] = r0; + bytes[i - 2] = g0; + bytes[i - 1] = b0; + } else if (alpha < 255) { + var alpha_ = 255 - alpha; + bytes[i - 3] = (bytes[i - 3] * alpha + r0 * alpha_) >> 8; + bytes[i - 2] = (bytes[i - 2] * alpha + g0 * alpha_) >> 8; + bytes[i - 1] = (bytes[i - 1] * alpha + b0 * alpha_) >> 8; + } + } + } + + function composeSMaskAlpha(maskData, layerData, transferMap) { + var length = maskData.length; + var scale = 1 / 255; + for (var i = 3; i < length; i += 4) { + var alpha = transferMap ? transferMap[maskData[i]] : maskData[i]; + layerData[i] = (layerData[i] * alpha * scale) | 0; + } + } + + function composeSMaskLuminosity(maskData, layerData, transferMap) { + var length = maskData.length; + for (var i = 3; i < length; i += 4) { + var y = (maskData[i - 3] * 77) + // * 0.3 / 255 * 0x10000 + (maskData[i - 2] * 152) + // * 0.59 .... + (maskData[i - 1] * 28); // * 0.11 .... + layerData[i] = transferMap ? + (layerData[i] * transferMap[y >> 8]) >> 8 : + (layerData[i] * y) >> 16; + } + } + + function genericComposeSMask(maskCtx, layerCtx, width, height, + subtype, backdrop, transferMap) { + var hasBackdrop = !!backdrop; + var r0 = hasBackdrop ? backdrop[0] : 0; + var g0 = hasBackdrop ? backdrop[1] : 0; + var b0 = hasBackdrop ? backdrop[2] : 0; + + var composeFn; + if (subtype === 'Luminosity') { + composeFn = composeSMaskLuminosity; + } else { + composeFn = composeSMaskAlpha; + } + + // processing image in chunks to save memory + var PIXELS_TO_PROCESS = 1048576; + var chunkSize = Math.min(height, Math.ceil(PIXELS_TO_PROCESS / width)); + for (var row = 0; row < height; row += chunkSize) { + var chunkHeight = Math.min(chunkSize, height - row); + var maskData = maskCtx.getImageData(0, row, width, chunkHeight); + var layerData = layerCtx.getImageData(0, row, width, chunkHeight); + + if (hasBackdrop) { + composeSMaskBackdrop(maskData.data, r0, g0, b0); + } + composeFn(maskData.data, layerData.data, transferMap); + + maskCtx.putImageData(layerData, 0, row); + } + } + + function composeSMask(ctx, smask, layerCtx) { + var mask = smask.canvas; + var maskCtx = smask.context; + + ctx.setTransform(smask.scaleX, 0, 0, smask.scaleY, + smask.offsetX, smask.offsetY); + + var backdrop = smask.backdrop || null; + if (!smask.transferMap && WebGLUtils.isEnabled) { + var composed = WebGLUtils.composeSMask(layerCtx.canvas, mask, + {subtype: smask.subtype, backdrop: backdrop}); + ctx.setTransform(1, 0, 0, 1, 0, 0); + ctx.drawImage(composed, smask.offsetX, smask.offsetY); + return; + } + genericComposeSMask(maskCtx, layerCtx, mask.width, mask.height, + smask.subtype, backdrop, smask.transferMap); + ctx.drawImage(mask, 0, 0); + } + + var LINE_CAP_STYLES = ['butt', 'round', 'square']; + var LINE_JOIN_STYLES = ['miter', 'round', 'bevel']; + var NORMAL_CLIP = {}; + var EO_CLIP = {}; + + CanvasGraphics.prototype = { + + beginDrawing: function CanvasGraphics_beginDrawing(transform, viewport, + transparency) { + // For pdfs that use blend modes we have to clear the canvas else certain + // blend modes can look wrong since we'd be blending with a white + // backdrop. The problem with a transparent backdrop though is we then + // don't get sub pixel anti aliasing on text, creating temporary + // transparent canvas when we have blend modes. + var width = this.ctx.canvas.width; + var height = this.ctx.canvas.height; + + this.ctx.save(); + this.ctx.fillStyle = 'rgb(255, 255, 255)'; + this.ctx.fillRect(0, 0, width, height); + this.ctx.restore(); + + if (transparency) { + var transparentCanvas = this.cachedCanvases.getCanvas( + 'transparent', width, height, true); + this.compositeCtx = this.ctx; + this.transparentCanvas = transparentCanvas.canvas; + this.ctx = transparentCanvas.context; + this.ctx.save(); + // The transform can be applied before rendering, transferring it to + // the new canvas. + this.ctx.transform.apply(this.ctx, + this.compositeCtx.mozCurrentTransform); + } + + this.ctx.save(); + if (transform) { + this.ctx.transform.apply(this.ctx, transform); + } + this.ctx.transform.apply(this.ctx, viewport.transform); + + this.baseTransform = this.ctx.mozCurrentTransform.slice(); + + if (this.imageLayer) { + this.imageLayer.beginLayout(); + } + }, + + executeOperatorList: function CanvasGraphics_executeOperatorList( + operatorList, + executionStartIdx, continueCallback, + stepper) { + var argsArray = operatorList.argsArray; + var fnArray = operatorList.fnArray; + var i = executionStartIdx || 0; + var argsArrayLen = argsArray.length; + + // Sometimes the OperatorList to execute is empty. + if (argsArrayLen === i) { + return i; + } + + var chunkOperations = (argsArrayLen - i > EXECUTION_STEPS && + typeof continueCallback === 'function'); + var endTime = chunkOperations ? Date.now() + EXECUTION_TIME : 0; + var steps = 0; + + var commonObjs = this.commonObjs; + var objs = this.objs; + var fnId; + + while (true) { + if (stepper !== undefined && i === stepper.nextBreakPoint) { + stepper.breakIt(i, continueCallback); + return i; + } + + fnId = fnArray[i]; + + if (fnId !== OPS.dependency) { + this[fnId].apply(this, argsArray[i]); + } else { + var deps = argsArray[i]; + for (var n = 0, nn = deps.length; n < nn; n++) { + var depObjId = deps[n]; + var common = depObjId[0] === 'g' && depObjId[1] === '_'; + var objsPool = common ? commonObjs : objs; + + // If the promise isn't resolved yet, add the continueCallback + // to the promise and bail out. + if (!objsPool.isResolved(depObjId)) { + objsPool.get(depObjId, continueCallback); + return i; + } + } + } + + i++; + + // If the entire operatorList was executed, stop as were done. + if (i === argsArrayLen) { + return i; + } + + // If the execution took longer then a certain amount of time and + // `continueCallback` is specified, interrupt the execution. + if (chunkOperations && ++steps > EXECUTION_STEPS) { + if (Date.now() > endTime) { + continueCallback(); + return i; + } + steps = 0; + } + + // If the operatorList isn't executed completely yet OR the execution + // time was short enough, do another execution round. + } + }, + + endDrawing: function CanvasGraphics_endDrawing() { + this.ctx.restore(); + + if (this.transparentCanvas) { + this.ctx = this.compositeCtx; + this.ctx.save(); + this.ctx.setTransform(1, 0, 0, 1, 0, 0); // Avoid apply transform twice + this.ctx.drawImage(this.transparentCanvas, 0, 0); + this.ctx.restore(); + this.transparentCanvas = null; + } + + this.cachedCanvases.clear(); + WebGLUtils.clear(); + + if (this.imageLayer) { + this.imageLayer.endLayout(); + } + }, + + // Graphics state + setLineWidth: function CanvasGraphics_setLineWidth(width) { + this.current.lineWidth = width; + this.ctx.lineWidth = width; + }, + setLineCap: function CanvasGraphics_setLineCap(style) { + this.ctx.lineCap = LINE_CAP_STYLES[style]; + }, + setLineJoin: function CanvasGraphics_setLineJoin(style) { + this.ctx.lineJoin = LINE_JOIN_STYLES[style]; + }, + setMiterLimit: function CanvasGraphics_setMiterLimit(limit) { + this.ctx.miterLimit = limit; + }, + setDash: function CanvasGraphics_setDash(dashArray, dashPhase) { + var ctx = this.ctx; + if (ctx.setLineDash !== undefined) { + ctx.setLineDash(dashArray); + ctx.lineDashOffset = dashPhase; + } else { + ctx.mozDash = dashArray; + ctx.mozDashOffset = dashPhase; + } + }, + setRenderingIntent: function CanvasGraphics_setRenderingIntent(intent) { + // Maybe if we one day fully support color spaces this will be important + // for now we can ignore. + // TODO set rendering intent? + }, + setFlatness: function CanvasGraphics_setFlatness(flatness) { + // There's no way to control this with canvas, but we can safely ignore. + // TODO set flatness? + }, + setGState: function CanvasGraphics_setGState(states) { + for (var i = 0, ii = states.length; i < ii; i++) { + var state = states[i]; + var key = state[0]; + var value = state[1]; + + switch (key) { + case 'LW': + this.setLineWidth(value); + break; + case 'LC': + this.setLineCap(value); + break; + case 'LJ': + this.setLineJoin(value); + break; + case 'ML': + this.setMiterLimit(value); + break; + case 'D': + this.setDash(value[0], value[1]); + break; + case 'RI': + this.setRenderingIntent(value); + break; + case 'FL': + this.setFlatness(value); + break; + case 'Font': + this.setFont(value[0], value[1]); + break; + case 'CA': + this.current.strokeAlpha = state[1]; + break; + case 'ca': + this.current.fillAlpha = state[1]; + this.ctx.globalAlpha = state[1]; + break; + case 'BM': + if (value && value.name && (value.name !== 'Normal')) { + var mode = value.name.replace(/([A-Z])/g, + function(c) { + return '-' + c.toLowerCase(); + } + ).substring(1); + this.ctx.globalCompositeOperation = mode; + if (this.ctx.globalCompositeOperation !== mode) { + warn('globalCompositeOperation "' + mode + + '" is not supported'); + } + } else { + this.ctx.globalCompositeOperation = 'source-over'; + } + break; + case 'SMask': + if (this.current.activeSMask) { + this.endSMaskGroup(); + } + this.current.activeSMask = value ? this.tempSMask : null; + if (this.current.activeSMask) { + this.beginSMaskGroup(); + } + this.tempSMask = null; + break; + } + } + }, + beginSMaskGroup: function CanvasGraphics_beginSMaskGroup() { + + var activeSMask = this.current.activeSMask; + var drawnWidth = activeSMask.canvas.width; + var drawnHeight = activeSMask.canvas.height; + var cacheId = 'smaskGroupAt' + this.groupLevel; + var scratchCanvas = this.cachedCanvases.getCanvas( + cacheId, drawnWidth, drawnHeight, true); + + var currentCtx = this.ctx; + var currentTransform = currentCtx.mozCurrentTransform; + this.ctx.save(); + + var groupCtx = scratchCanvas.context; + groupCtx.scale(1 / activeSMask.scaleX, 1 / activeSMask.scaleY); + groupCtx.translate(-activeSMask.offsetX, -activeSMask.offsetY); + groupCtx.transform.apply(groupCtx, currentTransform); + + copyCtxState(currentCtx, groupCtx); + this.ctx = groupCtx; + this.setGState([ + ['BM', 'Normal'], + ['ca', 1], + ['CA', 1] + ]); + this.groupStack.push(currentCtx); + this.groupLevel++; + }, + endSMaskGroup: function CanvasGraphics_endSMaskGroup() { + var groupCtx = this.ctx; + this.groupLevel--; + this.ctx = this.groupStack.pop(); + + composeSMask(this.ctx, this.current.activeSMask, groupCtx); + this.ctx.restore(); + copyCtxState(groupCtx, this.ctx); + }, + save: function CanvasGraphics_save() { + this.ctx.save(); + var old = this.current; + this.stateStack.push(old); + this.current = old.clone(); + this.current.activeSMask = null; + }, + restore: function CanvasGraphics_restore() { + if (this.stateStack.length !== 0) { + if (this.current.activeSMask !== null) { + this.endSMaskGroup(); + } + + this.current = this.stateStack.pop(); + this.ctx.restore(); + + // Ensure that the clipping path is reset (fixes issue6413.pdf). + this.pendingClip = null; + + this.cachedGetSinglePixelWidth = null; + } + }, + transform: function CanvasGraphics_transform(a, b, c, d, e, f) { + this.ctx.transform(a, b, c, d, e, f); + + this.cachedGetSinglePixelWidth = null; + }, + + // Path + constructPath: function CanvasGraphics_constructPath(ops, args) { + var ctx = this.ctx; + var current = this.current; + var x = current.x, y = current.y; + for (var i = 0, j = 0, ii = ops.length; i < ii; i++) { + switch (ops[i] | 0) { + case OPS.rectangle: + x = args[j++]; + y = args[j++]; + var width = args[j++]; + var height = args[j++]; + if (width === 0) { + width = this.getSinglePixelWidth(); + } + if (height === 0) { + height = this.getSinglePixelWidth(); + } + var xw = x + width; + var yh = y + height; + this.ctx.moveTo(x, y); + this.ctx.lineTo(xw, y); + this.ctx.lineTo(xw, yh); + this.ctx.lineTo(x, yh); + this.ctx.lineTo(x, y); + this.ctx.closePath(); + break; + case OPS.moveTo: + x = args[j++]; + y = args[j++]; + ctx.moveTo(x, y); + break; + case OPS.lineTo: + x = args[j++]; + y = args[j++]; + ctx.lineTo(x, y); + break; + case OPS.curveTo: + x = args[j + 4]; + y = args[j + 5]; + ctx.bezierCurveTo(args[j], args[j + 1], args[j + 2], args[j + 3], + x, y); + j += 6; + break; + case OPS.curveTo2: + ctx.bezierCurveTo(x, y, args[j], args[j + 1], + args[j + 2], args[j + 3]); + x = args[j + 2]; + y = args[j + 3]; + j += 4; + break; + case OPS.curveTo3: + x = args[j + 2]; + y = args[j + 3]; + ctx.bezierCurveTo(args[j], args[j + 1], x, y, x, y); + j += 4; + break; + case OPS.closePath: + ctx.closePath(); + break; + } + } + current.setCurrentPoint(x, y); + }, + closePath: function CanvasGraphics_closePath() { + this.ctx.closePath(); + }, + stroke: function CanvasGraphics_stroke(consumePath) { + consumePath = typeof consumePath !== 'undefined' ? consumePath : true; + var ctx = this.ctx; + var strokeColor = this.current.strokeColor; + // Prevent drawing too thin lines by enforcing a minimum line width. + ctx.lineWidth = Math.max(this.getSinglePixelWidth() * MIN_WIDTH_FACTOR, + this.current.lineWidth); + // For stroke we want to temporarily change the global alpha to the + // stroking alpha. + ctx.globalAlpha = this.current.strokeAlpha; + if (strokeColor && strokeColor.hasOwnProperty('type') && + strokeColor.type === 'Pattern') { + // for patterns, we transform to pattern space, calculate + // the pattern, call stroke, and restore to user space + ctx.save(); + ctx.strokeStyle = strokeColor.getPattern(ctx, this); + ctx.stroke(); + ctx.restore(); + } else { + ctx.stroke(); + } + if (consumePath) { + this.consumePath(); + } + // Restore the global alpha to the fill alpha + ctx.globalAlpha = this.current.fillAlpha; + }, + closeStroke: function CanvasGraphics_closeStroke() { + this.closePath(); + this.stroke(); + }, + fill: function CanvasGraphics_fill(consumePath) { + consumePath = typeof consumePath !== 'undefined' ? consumePath : true; + var ctx = this.ctx; + var fillColor = this.current.fillColor; + var isPatternFill = this.current.patternFill; + var needRestore = false; + + if (isPatternFill) { + ctx.save(); + if (this.baseTransform) { + ctx.setTransform.apply(ctx, this.baseTransform); + } + ctx.fillStyle = fillColor.getPattern(ctx, this); + needRestore = true; + } + + if (this.pendingEOFill) { + if (ctx.mozFillRule !== undefined) { + ctx.mozFillRule = 'evenodd'; + ctx.fill(); + ctx.mozFillRule = 'nonzero'; + } else { + ctx.fill('evenodd'); + } + this.pendingEOFill = false; + } else { + ctx.fill(); + } + + if (needRestore) { + ctx.restore(); + } + if (consumePath) { + this.consumePath(); + } + }, + eoFill: function CanvasGraphics_eoFill() { + this.pendingEOFill = true; + this.fill(); + }, + fillStroke: function CanvasGraphics_fillStroke() { + this.fill(false); + this.stroke(false); + + this.consumePath(); + }, + eoFillStroke: function CanvasGraphics_eoFillStroke() { + this.pendingEOFill = true; + this.fillStroke(); + }, + closeFillStroke: function CanvasGraphics_closeFillStroke() { + this.closePath(); + this.fillStroke(); + }, + closeEOFillStroke: function CanvasGraphics_closeEOFillStroke() { + this.pendingEOFill = true; + this.closePath(); + this.fillStroke(); + }, + endPath: function CanvasGraphics_endPath() { + this.consumePath(); + }, + + // Clipping + clip: function CanvasGraphics_clip() { + this.pendingClip = NORMAL_CLIP; + }, + eoClip: function CanvasGraphics_eoClip() { + this.pendingClip = EO_CLIP; + }, + + // Text + beginText: function CanvasGraphics_beginText() { + this.current.textMatrix = IDENTITY_MATRIX; + this.current.textMatrixScale = 1; + this.current.x = this.current.lineX = 0; + this.current.y = this.current.lineY = 0; + }, + endText: function CanvasGraphics_endText() { + var paths = this.pendingTextPaths; + var ctx = this.ctx; + if (paths === undefined) { + ctx.beginPath(); + return; + } + + ctx.save(); + ctx.beginPath(); + for (var i = 0; i < paths.length; i++) { + var path = paths[i]; + ctx.setTransform.apply(ctx, path.transform); + ctx.translate(path.x, path.y); + path.addToPath(ctx, path.fontSize); + } + ctx.restore(); + ctx.clip(); + ctx.beginPath(); + delete this.pendingTextPaths; + }, + setCharSpacing: function CanvasGraphics_setCharSpacing(spacing) { + this.current.charSpacing = spacing; + }, + setWordSpacing: function CanvasGraphics_setWordSpacing(spacing) { + this.current.wordSpacing = spacing; + }, + setHScale: function CanvasGraphics_setHScale(scale) { + this.current.textHScale = scale / 100; + }, + setLeading: function CanvasGraphics_setLeading(leading) { + this.current.leading = -leading; + }, + setFont: function CanvasGraphics_setFont(fontRefName, size) { + var fontObj = this.commonObjs.get(fontRefName); + var current = this.current; + + if (!fontObj) { + error('Can\'t find font for ' + fontRefName); + } + + current.fontMatrix = (fontObj.fontMatrix ? + fontObj.fontMatrix : FONT_IDENTITY_MATRIX); + + // A valid matrix needs all main diagonal elements to be non-zero + // This also ensures we bypass FF bugzilla bug #719844. + if (current.fontMatrix[0] === 0 || + current.fontMatrix[3] === 0) { + warn('Invalid font matrix for font ' + fontRefName); + } + + // The spec for Tf (setFont) says that 'size' specifies the font 'scale', + // and in some docs this can be negative (inverted x-y axes). + if (size < 0) { + size = -size; + current.fontDirection = -1; + } else { + current.fontDirection = 1; + } + + this.current.font = fontObj; + this.current.fontSize = size; + + if (fontObj.isType3Font) { + return; // we don't need ctx.font for Type3 fonts + } + + var name = fontObj.loadedName || 'sans-serif'; + var bold = fontObj.black ? (fontObj.bold ? '900' : 'bold') : + (fontObj.bold ? 'bold' : 'normal'); + + var italic = fontObj.italic ? 'italic' : 'normal'; + var typeface = '"' + name + '", ' + fontObj.fallbackName; + + // Some font backends cannot handle fonts below certain size. + // Keeping the font at minimal size and using the fontSizeScale to change + // the current transformation matrix before the fillText/strokeText. + // See https://bugzilla.mozilla.org/show_bug.cgi?id=726227 + var browserFontSize = size < MIN_FONT_SIZE ? MIN_FONT_SIZE : + size > MAX_FONT_SIZE ? MAX_FONT_SIZE : size; + this.current.fontSizeScale = size / browserFontSize; + + var rule = italic + ' ' + bold + ' ' + browserFontSize + 'px ' + typeface; + this.ctx.font = rule; + }, + setTextRenderingMode: function CanvasGraphics_setTextRenderingMode(mode) { + this.current.textRenderingMode = mode; + }, + setTextRise: function CanvasGraphics_setTextRise(rise) { + this.current.textRise = rise; + }, + moveText: function CanvasGraphics_moveText(x, y) { + this.current.x = this.current.lineX += x; + this.current.y = this.current.lineY += y; + }, + setLeadingMoveText: function CanvasGraphics_setLeadingMoveText(x, y) { + this.setLeading(-y); + this.moveText(x, y); + }, + setTextMatrix: function CanvasGraphics_setTextMatrix(a, b, c, d, e, f) { + this.current.textMatrix = [a, b, c, d, e, f]; + this.current.textMatrixScale = Math.sqrt(a * a + b * b); + + this.current.x = this.current.lineX = 0; + this.current.y = this.current.lineY = 0; + }, + nextLine: function CanvasGraphics_nextLine() { + this.moveText(0, this.current.leading); + }, + + paintChar: function CanvasGraphics_paintChar(character, x, y) { + var ctx = this.ctx; + var current = this.current; + var font = current.font; + var textRenderingMode = current.textRenderingMode; + var fontSize = current.fontSize / current.fontSizeScale; + var fillStrokeMode = textRenderingMode & + TextRenderingMode.FILL_STROKE_MASK; + var isAddToPathSet = !!(textRenderingMode & + TextRenderingMode.ADD_TO_PATH_FLAG); + + var addToPath; + if (font.disableFontFace || isAddToPathSet) { + addToPath = font.getPathGenerator(this.commonObjs, character); + } + + if (font.disableFontFace) { + ctx.save(); + ctx.translate(x, y); + ctx.beginPath(); + addToPath(ctx, fontSize); + if (fillStrokeMode === TextRenderingMode.FILL || + fillStrokeMode === TextRenderingMode.FILL_STROKE) { + ctx.fill(); + } + if (fillStrokeMode === TextRenderingMode.STROKE || + fillStrokeMode === TextRenderingMode.FILL_STROKE) { + ctx.stroke(); + } + ctx.restore(); + } else { + if (fillStrokeMode === TextRenderingMode.FILL || + fillStrokeMode === TextRenderingMode.FILL_STROKE) { + ctx.fillText(character, x, y); + } + if (fillStrokeMode === TextRenderingMode.STROKE || + fillStrokeMode === TextRenderingMode.FILL_STROKE) { + ctx.strokeText(character, x, y); + } + } + + if (isAddToPathSet) { + var paths = this.pendingTextPaths || (this.pendingTextPaths = []); + paths.push({ + transform: ctx.mozCurrentTransform, + x: x, + y: y, + fontSize: fontSize, + addToPath: addToPath + }); + } + }, + + get isFontSubpixelAAEnabled() { + // Checks if anti-aliasing is enabled when scaled text is painted. + // On Windows GDI scaled fonts looks bad. + var ctx = document.createElement('canvas').getContext('2d'); + ctx.scale(1.5, 1); + ctx.fillText('I', 0, 10); + var data = ctx.getImageData(0, 0, 10, 10).data; + var enabled = false; + for (var i = 3; i < data.length; i += 4) { + if (data[i] > 0 && data[i] < 255) { + enabled = true; + break; + } + } + return shadow(this, 'isFontSubpixelAAEnabled', enabled); + }, + + showText: function CanvasGraphics_showText(glyphs) { + var current = this.current; + var font = current.font; + if (font.isType3Font) { + return this.showType3Text(glyphs); + } + + var fontSize = current.fontSize; + if (fontSize === 0) { + return; + } + + var ctx = this.ctx; + var fontSizeScale = current.fontSizeScale; + var charSpacing = current.charSpacing; + var wordSpacing = current.wordSpacing; + var fontDirection = current.fontDirection; + var textHScale = current.textHScale * fontDirection; + var glyphsLength = glyphs.length; + var vertical = font.vertical; + var spacingDir = vertical ? 1 : -1; + var defaultVMetrics = font.defaultVMetrics; + var widthAdvanceScale = fontSize * current.fontMatrix[0]; + + var simpleFillText = + current.textRenderingMode === TextRenderingMode.FILL && + !font.disableFontFace; + + ctx.save(); + ctx.transform.apply(ctx, current.textMatrix); + ctx.translate(current.x, current.y + current.textRise); + + if (current.patternFill) { + // TODO: Some shading patterns are not applied correctly to text, + // e.g. issues 3988 and 5432, and ShowText-ShadingPattern.pdf. + ctx.fillStyle = current.fillColor.getPattern(ctx, this); + } + + if (fontDirection > 0) { + ctx.scale(textHScale, -1); + } else { + ctx.scale(textHScale, 1); + } + + var lineWidth = current.lineWidth; + var scale = current.textMatrixScale; + if (scale === 0 || lineWidth === 0) { + var fillStrokeMode = current.textRenderingMode & + TextRenderingMode.FILL_STROKE_MASK; + if (fillStrokeMode === TextRenderingMode.STROKE || + fillStrokeMode === TextRenderingMode.FILL_STROKE) { + this.cachedGetSinglePixelWidth = null; + lineWidth = this.getSinglePixelWidth() * MIN_WIDTH_FACTOR; + } + } else { + lineWidth /= scale; + } + + if (fontSizeScale !== 1.0) { + ctx.scale(fontSizeScale, fontSizeScale); + lineWidth /= fontSizeScale; + } + + ctx.lineWidth = lineWidth; + + var x = 0, i; + for (i = 0; i < glyphsLength; ++i) { + var glyph = glyphs[i]; + if (isNum(glyph)) { + x += spacingDir * glyph * fontSize / 1000; + continue; + } + + var restoreNeeded = false; + var spacing = (glyph.isSpace ? wordSpacing : 0) + charSpacing; + var character = glyph.fontChar; + var accent = glyph.accent; + var scaledX, scaledY, scaledAccentX, scaledAccentY; + var width = glyph.width; + if (vertical) { + var vmetric, vx, vy; + vmetric = glyph.vmetric || defaultVMetrics; + vx = glyph.vmetric ? vmetric[1] : width * 0.5; + vx = -vx * widthAdvanceScale; + vy = vmetric[2] * widthAdvanceScale; + + width = vmetric ? -vmetric[0] : width; + scaledX = vx / fontSizeScale; + scaledY = (x + vy) / fontSizeScale; + } else { + scaledX = x / fontSizeScale; + scaledY = 0; + } + + if (font.remeasure && width > 0) { + // Some standard fonts may not have the exact width: rescale per + // character if measured width is greater than expected glyph width + // and subpixel-aa is enabled, otherwise just center the glyph. + var measuredWidth = ctx.measureText(character).width * 1000 / + fontSize * fontSizeScale; + if (width < measuredWidth && this.isFontSubpixelAAEnabled) { + var characterScaleX = width / measuredWidth; + restoreNeeded = true; + ctx.save(); + ctx.scale(characterScaleX, 1); + scaledX /= characterScaleX; + } else if (width !== measuredWidth) { + scaledX += (width - measuredWidth) / 2000 * + fontSize / fontSizeScale; + } + } + + // Only attempt to draw the glyph if it is actually in the embedded font + // file or if there isn't a font file so the fallback font is shown. + if (glyph.isInFont || font.missingFile) { + if (simpleFillText && !accent) { + // common case + ctx.fillText(character, scaledX, scaledY); + } else { + this.paintChar(character, scaledX, scaledY); + if (accent) { + scaledAccentX = scaledX + accent.offset.x / fontSizeScale; + scaledAccentY = scaledY - accent.offset.y / fontSizeScale; + this.paintChar(accent.fontChar, scaledAccentX, scaledAccentY); + } + } + } + + var charWidth = width * widthAdvanceScale + spacing * fontDirection; + x += charWidth; + + if (restoreNeeded) { + ctx.restore(); + } + } + if (vertical) { + current.y -= x * textHScale; + } else { + current.x += x * textHScale; + } + ctx.restore(); + }, + + showType3Text: function CanvasGraphics_showType3Text(glyphs) { + // Type3 fonts - each glyph is a "mini-PDF" + var ctx = this.ctx; + var current = this.current; + var font = current.font; + var fontSize = current.fontSize; + var fontDirection = current.fontDirection; + var spacingDir = font.vertical ? 1 : -1; + var charSpacing = current.charSpacing; + var wordSpacing = current.wordSpacing; + var textHScale = current.textHScale * fontDirection; + var fontMatrix = current.fontMatrix || FONT_IDENTITY_MATRIX; + var glyphsLength = glyphs.length; + var isTextInvisible = + current.textRenderingMode === TextRenderingMode.INVISIBLE; + var i, glyph, width, spacingLength; + + if (isTextInvisible || fontSize === 0) { + return; + } + this.cachedGetSinglePixelWidth = null; + + ctx.save(); + ctx.transform.apply(ctx, current.textMatrix); + ctx.translate(current.x, current.y); + + ctx.scale(textHScale, fontDirection); + + for (i = 0; i < glyphsLength; ++i) { + glyph = glyphs[i]; + if (isNum(glyph)) { + spacingLength = spacingDir * glyph * fontSize / 1000; + this.ctx.translate(spacingLength, 0); + current.x += spacingLength * textHScale; + continue; + } + + var spacing = (glyph.isSpace ? wordSpacing : 0) + charSpacing; + var operatorList = font.charProcOperatorList[glyph.operatorListId]; + if (!operatorList) { + warn('Type3 character \"' + glyph.operatorListId + + '\" is not available'); + continue; + } + this.processingType3 = glyph; + this.save(); + ctx.scale(fontSize, fontSize); + ctx.transform.apply(ctx, fontMatrix); + this.executeOperatorList(operatorList); + this.restore(); + + var transformed = Util.applyTransform([glyph.width, 0], fontMatrix); + width = transformed[0] * fontSize + spacing; + + ctx.translate(width, 0); + current.x += width * textHScale; + } + ctx.restore(); + this.processingType3 = null; + }, + + // Type3 fonts + setCharWidth: function CanvasGraphics_setCharWidth(xWidth, yWidth) { + // We can safely ignore this since the width should be the same + // as the width in the Widths array. + }, + setCharWidthAndBounds: function CanvasGraphics_setCharWidthAndBounds(xWidth, + yWidth, + llx, + lly, + urx, + ury) { + // TODO According to the spec we're also suppose to ignore any operators + // that set color or include images while processing this type3 font. + this.ctx.rect(llx, lly, urx - llx, ury - lly); + this.clip(); + this.endPath(); + }, + + // Color + getColorN_Pattern: function CanvasGraphics_getColorN_Pattern(IR) { + var pattern; + if (IR[0] === 'TilingPattern') { + var color = IR[1]; + var baseTransform = this.baseTransform || + this.ctx.mozCurrentTransform.slice(); + var self = this; + var canvasGraphicsFactory = { + createCanvasGraphics: function (ctx) { + return new CanvasGraphics(ctx, self.commonObjs, self.objs); + } + }; + pattern = new TilingPattern(IR, color, this.ctx, canvasGraphicsFactory, + baseTransform); + } else { + pattern = getShadingPatternFromIR(IR); + } + return pattern; + }, + setStrokeColorN: function CanvasGraphics_setStrokeColorN(/*...*/) { + this.current.strokeColor = this.getColorN_Pattern(arguments); + }, + setFillColorN: function CanvasGraphics_setFillColorN(/*...*/) { + this.current.fillColor = this.getColorN_Pattern(arguments); + this.current.patternFill = true; + }, + setStrokeRGBColor: function CanvasGraphics_setStrokeRGBColor(r, g, b) { + var color = Util.makeCssRgb(r, g, b); + this.ctx.strokeStyle = color; + this.current.strokeColor = color; + }, + setFillRGBColor: function CanvasGraphics_setFillRGBColor(r, g, b) { + var color = Util.makeCssRgb(r, g, b); + this.ctx.fillStyle = color; + this.current.fillColor = color; + this.current.patternFill = false; + }, + + shadingFill: function CanvasGraphics_shadingFill(patternIR) { + var ctx = this.ctx; + + this.save(); + var pattern = getShadingPatternFromIR(patternIR); + ctx.fillStyle = pattern.getPattern(ctx, this, true); + + var inv = ctx.mozCurrentTransformInverse; + if (inv) { + var canvas = ctx.canvas; + var width = canvas.width; + var height = canvas.height; + + var bl = Util.applyTransform([0, 0], inv); + var br = Util.applyTransform([0, height], inv); + var ul = Util.applyTransform([width, 0], inv); + var ur = Util.applyTransform([width, height], inv); + + var x0 = Math.min(bl[0], br[0], ul[0], ur[0]); + var y0 = Math.min(bl[1], br[1], ul[1], ur[1]); + var x1 = Math.max(bl[0], br[0], ul[0], ur[0]); + var y1 = Math.max(bl[1], br[1], ul[1], ur[1]); + + this.ctx.fillRect(x0, y0, x1 - x0, y1 - y0); + } else { + // HACK to draw the gradient onto an infinite rectangle. + // PDF gradients are drawn across the entire image while + // Canvas only allows gradients to be drawn in a rectangle + // The following bug should allow us to remove this. + // https://bugzilla.mozilla.org/show_bug.cgi?id=664884 + + this.ctx.fillRect(-1e10, -1e10, 2e10, 2e10); + } + + this.restore(); + }, + + // Images + beginInlineImage: function CanvasGraphics_beginInlineImage() { + error('Should not call beginInlineImage'); + }, + beginImageData: function CanvasGraphics_beginImageData() { + error('Should not call beginImageData'); + }, + + paintFormXObjectBegin: function CanvasGraphics_paintFormXObjectBegin(matrix, + bbox) { + this.save(); + this.baseTransformStack.push(this.baseTransform); + + if (isArray(matrix) && 6 === matrix.length) { + this.transform.apply(this, matrix); + } + + this.baseTransform = this.ctx.mozCurrentTransform; + + if (isArray(bbox) && 4 === bbox.length) { + var width = bbox[2] - bbox[0]; + var height = bbox[3] - bbox[1]; + this.ctx.rect(bbox[0], bbox[1], width, height); + this.clip(); + this.endPath(); + } + }, + + paintFormXObjectEnd: function CanvasGraphics_paintFormXObjectEnd() { + this.restore(); + this.baseTransform = this.baseTransformStack.pop(); + }, + + beginGroup: function CanvasGraphics_beginGroup(group) { + this.save(); + var currentCtx = this.ctx; + // TODO non-isolated groups - according to Rik at adobe non-isolated + // group results aren't usually that different and they even have tools + // that ignore this setting. Notes from Rik on implmenting: + // - When you encounter an transparency group, create a new canvas with + // the dimensions of the bbox + // - copy the content from the previous canvas to the new canvas + // - draw as usual + // - remove the backdrop alpha: + // alphaNew = 1 - (1 - alpha)/(1 - alphaBackdrop) with 'alpha' the alpha + // value of your transparency group and 'alphaBackdrop' the alpha of the + // backdrop + // - remove background color: + // colorNew = color - alphaNew *colorBackdrop /(1 - alphaNew) + if (!group.isolated) { + info('TODO: Support non-isolated groups.'); + } + + // TODO knockout - supposedly possible with the clever use of compositing + // modes. + if (group.knockout) { + warn('Knockout groups not supported.'); + } + + var currentTransform = currentCtx.mozCurrentTransform; + if (group.matrix) { + currentCtx.transform.apply(currentCtx, group.matrix); + } + assert(group.bbox, 'Bounding box is required.'); + + // Based on the current transform figure out how big the bounding box + // will actually be. + var bounds = Util.getAxialAlignedBoundingBox( + group.bbox, + currentCtx.mozCurrentTransform); + // Clip the bounding box to the current canvas. + var canvasBounds = [0, + 0, + currentCtx.canvas.width, + currentCtx.canvas.height]; + bounds = Util.intersect(bounds, canvasBounds) || [0, 0, 0, 0]; + // Use ceil in case we're between sizes so we don't create canvas that is + // too small and make the canvas at least 1x1 pixels. + var offsetX = Math.floor(bounds[0]); + var offsetY = Math.floor(bounds[1]); + var drawnWidth = Math.max(Math.ceil(bounds[2]) - offsetX, 1); + var drawnHeight = Math.max(Math.ceil(bounds[3]) - offsetY, 1); + var scaleX = 1, scaleY = 1; + if (drawnWidth > MAX_GROUP_SIZE) { + scaleX = drawnWidth / MAX_GROUP_SIZE; + drawnWidth = MAX_GROUP_SIZE; + } + if (drawnHeight > MAX_GROUP_SIZE) { + scaleY = drawnHeight / MAX_GROUP_SIZE; + drawnHeight = MAX_GROUP_SIZE; + } + + var cacheId = 'groupAt' + this.groupLevel; + if (group.smask) { + // Using two cache entries is case if masks are used one after another. + cacheId += '_smask_' + ((this.smaskCounter++) % 2); + } + var scratchCanvas = this.cachedCanvases.getCanvas( + cacheId, drawnWidth, drawnHeight, true); + var groupCtx = scratchCanvas.context; + + // Since we created a new canvas that is just the size of the bounding box + // we have to translate the group ctx. + groupCtx.scale(1 / scaleX, 1 / scaleY); + groupCtx.translate(-offsetX, -offsetY); + groupCtx.transform.apply(groupCtx, currentTransform); + + if (group.smask) { + // Saving state and cached mask to be used in setGState. + this.smaskStack.push({ + canvas: scratchCanvas.canvas, + context: groupCtx, + offsetX: offsetX, + offsetY: offsetY, + scaleX: scaleX, + scaleY: scaleY, + subtype: group.smask.subtype, + backdrop: group.smask.backdrop, + transferMap: group.smask.transferMap || null + }); + } else { + // Setup the current ctx so when the group is popped we draw it at the + // right location. + currentCtx.setTransform(1, 0, 0, 1, 0, 0); + currentCtx.translate(offsetX, offsetY); + currentCtx.scale(scaleX, scaleY); + } + // The transparency group inherits all off the current graphics state + // except the blend mode, soft mask, and alpha constants. + copyCtxState(currentCtx, groupCtx); + this.ctx = groupCtx; + this.setGState([ + ['BM', 'Normal'], + ['ca', 1], + ['CA', 1] + ]); + this.groupStack.push(currentCtx); + this.groupLevel++; + }, + + endGroup: function CanvasGraphics_endGroup(group) { + this.groupLevel--; + var groupCtx = this.ctx; + this.ctx = this.groupStack.pop(); + // Turn off image smoothing to avoid sub pixel interpolation which can + // look kind of blurry for some pdfs. + if (this.ctx.imageSmoothingEnabled !== undefined) { + this.ctx.imageSmoothingEnabled = false; + } else { + this.ctx.mozImageSmoothingEnabled = false; + } + if (group.smask) { + this.tempSMask = this.smaskStack.pop(); + } else { + this.ctx.drawImage(groupCtx.canvas, 0, 0); + } + this.restore(); + }, + + beginAnnotations: function CanvasGraphics_beginAnnotations() { + this.save(); + this.current = new CanvasExtraState(); + + if (this.baseTransform) { + this.ctx.setTransform.apply(this.ctx, this.baseTransform); + } + }, + + endAnnotations: function CanvasGraphics_endAnnotations() { + this.restore(); + }, + + beginAnnotation: function CanvasGraphics_beginAnnotation(rect, transform, + matrix) { + this.save(); + + if (isArray(rect) && 4 === rect.length) { + var width = rect[2] - rect[0]; + var height = rect[3] - rect[1]; + this.ctx.rect(rect[0], rect[1], width, height); + this.clip(); + this.endPath(); + } + + this.transform.apply(this, transform); + this.transform.apply(this, matrix); + }, + + endAnnotation: function CanvasGraphics_endAnnotation() { + this.restore(); + }, + + paintJpegXObject: function CanvasGraphics_paintJpegXObject(objId, w, h) { + var domImage = this.objs.get(objId); + if (!domImage) { + warn('Dependent image isn\'t ready yet'); + return; + } + + this.save(); + + var ctx = this.ctx; + // scale the image to the unit square + ctx.scale(1 / w, -1 / h); + + ctx.drawImage(domImage, 0, 0, domImage.width, domImage.height, + 0, -h, w, h); + if (this.imageLayer) { + var currentTransform = ctx.mozCurrentTransformInverse; + var position = this.getCanvasPosition(0, 0); + + this.imageLayer.appendImage({ + objId: objId, + left: position[0], + top: position[1], + width: w / currentTransform[0], + height: h / currentTransform[3] + }); + } + this.restore(); + }, + + paintImageMaskXObject: function CanvasGraphics_paintImageMaskXObject(img) { + var ctx = this.ctx; + var width = img.width, height = img.height; + var fillColor = this.current.fillColor; + var isPatternFill = this.current.patternFill; + + var glyph = this.processingType3; + + if (COMPILE_TYPE3_GLYPHS && glyph && glyph.compiled === undefined) { + if (width <= MAX_SIZE_TO_COMPILE && height <= MAX_SIZE_TO_COMPILE) { + glyph.compiled = + compileType3Glyph({data: img.data, width: width, height: height}); + } else { + glyph.compiled = null; + } + } + + if (glyph && glyph.compiled) { + glyph.compiled(ctx); + return; + } + + var maskCanvas = this.cachedCanvases.getCanvas('maskCanvas', + width, height); + var maskCtx = maskCanvas.context; + maskCtx.save(); + + putBinaryImageMask(maskCtx, img); + + maskCtx.globalCompositeOperation = 'source-in'; + + maskCtx.fillStyle = isPatternFill ? + fillColor.getPattern(maskCtx, this) : fillColor; + maskCtx.fillRect(0, 0, width, height); + + maskCtx.restore(); + + this.paintInlineImageXObject(maskCanvas.canvas); + }, + + paintImageMaskXObjectRepeat: + function CanvasGraphics_paintImageMaskXObjectRepeat(imgData, scaleX, + scaleY, positions) { + var width = imgData.width; + var height = imgData.height; + var fillColor = this.current.fillColor; + var isPatternFill = this.current.patternFill; + + var maskCanvas = this.cachedCanvases.getCanvas('maskCanvas', + width, height); + var maskCtx = maskCanvas.context; + maskCtx.save(); + + putBinaryImageMask(maskCtx, imgData); + + maskCtx.globalCompositeOperation = 'source-in'; + + maskCtx.fillStyle = isPatternFill ? + fillColor.getPattern(maskCtx, this) : fillColor; + maskCtx.fillRect(0, 0, width, height); + + maskCtx.restore(); + + var ctx = this.ctx; + for (var i = 0, ii = positions.length; i < ii; i += 2) { + ctx.save(); + ctx.transform(scaleX, 0, 0, scaleY, positions[i], positions[i + 1]); + ctx.scale(1, -1); + ctx.drawImage(maskCanvas.canvas, 0, 0, width, height, + 0, -1, 1, 1); + ctx.restore(); + } + }, + + paintImageMaskXObjectGroup: + function CanvasGraphics_paintImageMaskXObjectGroup(images) { + var ctx = this.ctx; + + var fillColor = this.current.fillColor; + var isPatternFill = this.current.patternFill; + for (var i = 0, ii = images.length; i < ii; i++) { + var image = images[i]; + var width = image.width, height = image.height; + + var maskCanvas = this.cachedCanvases.getCanvas('maskCanvas', + width, height); + var maskCtx = maskCanvas.context; + maskCtx.save(); + + putBinaryImageMask(maskCtx, image); + + maskCtx.globalCompositeOperation = 'source-in'; + + maskCtx.fillStyle = isPatternFill ? + fillColor.getPattern(maskCtx, this) : fillColor; + maskCtx.fillRect(0, 0, width, height); + + maskCtx.restore(); + + ctx.save(); + ctx.transform.apply(ctx, image.transform); + ctx.scale(1, -1); + ctx.drawImage(maskCanvas.canvas, 0, 0, width, height, + 0, -1, 1, 1); + ctx.restore(); + } + }, + + paintImageXObject: function CanvasGraphics_paintImageXObject(objId) { + var imgData = this.objs.get(objId); + if (!imgData) { + warn('Dependent image isn\'t ready yet'); + return; + } + + this.paintInlineImageXObject(imgData); + }, + + paintImageXObjectRepeat: + function CanvasGraphics_paintImageXObjectRepeat(objId, scaleX, scaleY, + positions) { + var imgData = this.objs.get(objId); + if (!imgData) { + warn('Dependent image isn\'t ready yet'); + return; + } + + var width = imgData.width; + var height = imgData.height; + var map = []; + for (var i = 0, ii = positions.length; i < ii; i += 2) { + map.push({transform: [scaleX, 0, 0, scaleY, positions[i], + positions[i + 1]], x: 0, y: 0, w: width, h: height}); + } + this.paintInlineImageXObjectGroup(imgData, map); + }, + + paintInlineImageXObject: + function CanvasGraphics_paintInlineImageXObject(imgData) { + var width = imgData.width; + var height = imgData.height; + var ctx = this.ctx; + + this.save(); + // scale the image to the unit square + ctx.scale(1 / width, -1 / height); + + var currentTransform = ctx.mozCurrentTransformInverse; + var a = currentTransform[0], b = currentTransform[1]; + var widthScale = Math.max(Math.sqrt(a * a + b * b), 1); + var c = currentTransform[2], d = currentTransform[3]; + var heightScale = Math.max(Math.sqrt(c * c + d * d), 1); + + var imgToPaint, tmpCanvas; + // instanceof HTMLElement does not work in jsdom node.js module + if (imgData instanceof HTMLElement || !imgData.data) { + imgToPaint = imgData; + } else { + tmpCanvas = this.cachedCanvases.getCanvas('inlineImage', + width, height); + var tmpCtx = tmpCanvas.context; + putBinaryImageData(tmpCtx, imgData); + imgToPaint = tmpCanvas.canvas; + } + + var paintWidth = width, paintHeight = height; + var tmpCanvasId = 'prescale1'; + // Vertial or horizontal scaling shall not be more than 2 to not loose the + // pixels during drawImage operation, painting on the temporary canvas(es) + // that are twice smaller in size + while ((widthScale > 2 && paintWidth > 1) || + (heightScale > 2 && paintHeight > 1)) { + var newWidth = paintWidth, newHeight = paintHeight; + if (widthScale > 2 && paintWidth > 1) { + newWidth = Math.ceil(paintWidth / 2); + widthScale /= paintWidth / newWidth; + } + if (heightScale > 2 && paintHeight > 1) { + newHeight = Math.ceil(paintHeight / 2); + heightScale /= paintHeight / newHeight; + } + tmpCanvas = this.cachedCanvases.getCanvas(tmpCanvasId, + newWidth, newHeight); + tmpCtx = tmpCanvas.context; + tmpCtx.clearRect(0, 0, newWidth, newHeight); + tmpCtx.drawImage(imgToPaint, 0, 0, paintWidth, paintHeight, + 0, 0, newWidth, newHeight); + imgToPaint = tmpCanvas.canvas; + paintWidth = newWidth; + paintHeight = newHeight; + tmpCanvasId = tmpCanvasId === 'prescale1' ? 'prescale2' : 'prescale1'; + } + ctx.drawImage(imgToPaint, 0, 0, paintWidth, paintHeight, + 0, -height, width, height); + + if (this.imageLayer) { + var position = this.getCanvasPosition(0, -height); + this.imageLayer.appendImage({ + imgData: imgData, + left: position[0], + top: position[1], + width: width / currentTransform[0], + height: height / currentTransform[3] + }); + } + this.restore(); + }, + + paintInlineImageXObjectGroup: + function CanvasGraphics_paintInlineImageXObjectGroup(imgData, map) { + var ctx = this.ctx; + var w = imgData.width; + var h = imgData.height; + + var tmpCanvas = this.cachedCanvases.getCanvas('inlineImage', w, h); + var tmpCtx = tmpCanvas.context; + putBinaryImageData(tmpCtx, imgData); + + for (var i = 0, ii = map.length; i < ii; i++) { + var entry = map[i]; + ctx.save(); + ctx.transform.apply(ctx, entry.transform); + ctx.scale(1, -1); + ctx.drawImage(tmpCanvas.canvas, entry.x, entry.y, entry.w, entry.h, + 0, -1, 1, 1); + if (this.imageLayer) { + var position = this.getCanvasPosition(entry.x, entry.y); + this.imageLayer.appendImage({ + imgData: imgData, + left: position[0], + top: position[1], + width: w, + height: h + }); + } + ctx.restore(); + } + }, + + paintSolidColorImageMask: + function CanvasGraphics_paintSolidColorImageMask() { + this.ctx.fillRect(0, 0, 1, 1); + }, + + paintXObject: function CanvasGraphics_paintXObject() { + warn('Unsupported \'paintXObject\' command.'); + }, + + // Marked content + + markPoint: function CanvasGraphics_markPoint(tag) { + // TODO Marked content. + }, + markPointProps: function CanvasGraphics_markPointProps(tag, properties) { + // TODO Marked content. + }, + beginMarkedContent: function CanvasGraphics_beginMarkedContent(tag) { + // TODO Marked content. + }, + beginMarkedContentProps: function CanvasGraphics_beginMarkedContentProps( + tag, properties) { + // TODO Marked content. + }, + endMarkedContent: function CanvasGraphics_endMarkedContent() { + // TODO Marked content. + }, + + // Compatibility + + beginCompat: function CanvasGraphics_beginCompat() { + // TODO ignore undefined operators (should we do that anyway?) + }, + endCompat: function CanvasGraphics_endCompat() { + // TODO stop ignoring undefined operators + }, + + // Helper functions + + consumePath: function CanvasGraphics_consumePath() { + var ctx = this.ctx; + if (this.pendingClip) { + if (this.pendingClip === EO_CLIP) { + if (ctx.mozFillRule !== undefined) { + ctx.mozFillRule = 'evenodd'; + ctx.clip(); + ctx.mozFillRule = 'nonzero'; + } else { + ctx.clip('evenodd'); + } + } else { + ctx.clip(); + } + this.pendingClip = null; + } + ctx.beginPath(); + }, + getSinglePixelWidth: function CanvasGraphics_getSinglePixelWidth(scale) { + if (this.cachedGetSinglePixelWidth === null) { + var inverse = this.ctx.mozCurrentTransformInverse; + // max of the current horizontal and vertical scale + this.cachedGetSinglePixelWidth = Math.sqrt(Math.max( + (inverse[0] * inverse[0] + inverse[1] * inverse[1]), + (inverse[2] * inverse[2] + inverse[3] * inverse[3]))); + } + return this.cachedGetSinglePixelWidth; + }, + getCanvasPosition: function CanvasGraphics_getCanvasPosition(x, y) { + var transform = this.ctx.mozCurrentTransform; + //var transform = this.ctx.mozCurrentTransformInverse; + return [ + transform[0] * x + transform[2] * y + transform[4], + transform[1] * x + transform[3] * y + transform[5] + ]; + } + }; + + for (var op in OPS) { + CanvasGraphics.prototype[OPS[op]] = CanvasGraphics.prototype[op]; + } + + return CanvasGraphics; +})(); + +exports.CanvasGraphics = CanvasGraphics; +exports.createScratchCanvas = createScratchCanvas; +})); + + +(function (root, factory) { + { + factory((root.pdfjsDisplayAPI = {}), root.pdfjsSharedUtil, + root.pdfjsDisplayFontLoader, root.pdfjsDisplayCanvas, + root.pdfjsDisplayMetadata, root.pdfjsDisplayDOMUtils, + root.pdfjsDisplayGlobal); + } +}(this, function (exports, sharedUtil, displayFontLoader, displayCanvas, + displayMetadata, displayDOMUtils, displayGlobal, amdRequire) { + +var InvalidPDFException = sharedUtil.InvalidPDFException; +var MessageHandler = sharedUtil.MessageHandler; +var MissingPDFException = sharedUtil.MissingPDFException; +var PasswordResponses = sharedUtil.PasswordResponses; +var PasswordException = sharedUtil.PasswordException; +var StatTimer = sharedUtil.StatTimer; +var UnexpectedResponseException = sharedUtil.UnexpectedResponseException; +var UnknownErrorException = sharedUtil.UnknownErrorException; +var Util = sharedUtil.Util; +var createPromiseCapability = sharedUtil.createPromiseCapability; +var combineUrl = sharedUtil.combineUrl; +var error = sharedUtil.error; +var deprecated = sharedUtil.deprecated; +var getVerbosityLevel = sharedUtil.getVerbosityLevel; +var info = sharedUtil.info; +var isArrayBuffer = sharedUtil.isArrayBuffer; +var isSameOrigin = sharedUtil.isSameOrigin; +var loadJpegStream = sharedUtil.loadJpegStream; +var stringToBytes = sharedUtil.stringToBytes; +var warn = sharedUtil.warn; +var FontFaceObject = displayFontLoader.FontFaceObject; +var FontLoader = displayFontLoader.FontLoader; +var CanvasGraphics = displayCanvas.CanvasGraphics; +var createScratchCanvas = displayCanvas.createScratchCanvas; +var Metadata = displayMetadata.Metadata; +var PDFJS = displayGlobal.PDFJS; +var globalScope = displayGlobal.globalScope; + +var DEFAULT_RANGE_CHUNK_SIZE = 65536; // 2^16 = 65536 + + +var useRequireEnsure = false; +if (typeof module !== 'undefined' && module.require) { + // node.js - disable worker and set require.ensure. + PDFJS.disableWorker = true; + if (typeof require.ensure === 'undefined') { + require.ensure = require('node-ensure'); + } + useRequireEnsure = true; +} +if (typeof __webpack_require__ !== 'undefined') { + // Webpack - get/bundle pdf.worker.js as additional file. + PDFJS.workerSrc = require('entry?name=[hash]-worker.js!./pdf.worker.js'); + useRequireEnsure = true; +} +if (typeof requirejs !== 'undefined' && requirejs.toUrl) { + PDFJS.workerSrc = requirejs.toUrl('pdfjs-dist/build/pdf.worker.js'); +} +var fakeWorkerFilesLoader = useRequireEnsure ? (function (callback) { + require.ensure([], function () { + var worker = require('./pdf.worker.js'); + callback(worker.WorkerMessageHandler); + }); +}) : (typeof requirejs !== 'undefined') ? (function (callback) { + requirejs(['pdfjs-dist/build/pdf.worker'], function (worker) { + callback(worker.WorkerMessageHandler); + }); +}) : null; + + +/** + * The maximum allowed image size in total pixels e.g. width * height. Images + * above this value will not be drawn. Use -1 for no limit. + * @var {number} + */ +PDFJS.maxImageSize = (PDFJS.maxImageSize === undefined ? + -1 : PDFJS.maxImageSize); + +/** + * The url of where the predefined Adobe CMaps are located. Include trailing + * slash. + * @var {string} + */ +PDFJS.cMapUrl = (PDFJS.cMapUrl === undefined ? null : PDFJS.cMapUrl); + +/** + * Specifies if CMaps are binary packed. + * @var {boolean} + */ +PDFJS.cMapPacked = PDFJS.cMapPacked === undefined ? false : PDFJS.cMapPacked; + +/** + * By default fonts are converted to OpenType fonts and loaded via font face + * rules. If disabled, the font will be rendered using a built in font renderer + * that constructs the glyphs with primitive path commands. + * @var {boolean} + */ +PDFJS.disableFontFace = (PDFJS.disableFontFace === undefined ? + false : PDFJS.disableFontFace); + +/** + * Path for image resources, mainly for annotation icons. Include trailing + * slash. + * @var {string} + */ +PDFJS.imageResourcesPath = (PDFJS.imageResourcesPath === undefined ? + '' : PDFJS.imageResourcesPath); + +/** + * Disable the web worker and run all code on the main thread. This will happen + * automatically if the browser doesn't support workers or sending typed arrays + * to workers. + * @var {boolean} + */ +PDFJS.disableWorker = (PDFJS.disableWorker === undefined ? + false : PDFJS.disableWorker); + +/** + * Path and filename of the worker file. Required when the worker is enabled in + * development mode. If unspecified in the production build, the worker will be + * loaded based on the location of the pdf.js file. It is recommended that + * the workerSrc is set in a custom application to prevent issues caused by + * third-party frameworks and libraries. + * @var {string} + */ +PDFJS.workerSrc = (PDFJS.workerSrc === undefined ? null : PDFJS.workerSrc); + +/** + * Disable range request loading of PDF files. When enabled and if the server + * supports partial content requests then the PDF will be fetched in chunks. + * Enabled (false) by default. + * @var {boolean} + */ +PDFJS.disableRange = (PDFJS.disableRange === undefined ? + false : PDFJS.disableRange); + +/** + * Disable streaming of PDF file data. By default PDF.js attempts to load PDF + * in chunks. This default behavior can be disabled. + * @var {boolean} + */ +PDFJS.disableStream = (PDFJS.disableStream === undefined ? + false : PDFJS.disableStream); + +/** + * Disable pre-fetching of PDF file data. When range requests are enabled PDF.js + * will automatically keep fetching more data even if it isn't needed to display + * the current page. This default behavior can be disabled. + * + * NOTE: It is also necessary to disable streaming, see above, + * in order for disabling of pre-fetching to work correctly. + * @var {boolean} + */ +PDFJS.disableAutoFetch = (PDFJS.disableAutoFetch === undefined ? + false : PDFJS.disableAutoFetch); + +/** + * Enables special hooks for debugging PDF.js. + * @var {boolean} + */ +PDFJS.pdfBug = (PDFJS.pdfBug === undefined ? false : PDFJS.pdfBug); + +/** + * Enables transfer usage in postMessage for ArrayBuffers. + * @var {boolean} + */ +PDFJS.postMessageTransfers = (PDFJS.postMessageTransfers === undefined ? + true : PDFJS.postMessageTransfers); + +/** + * Disables URL.createObjectURL usage. + * @var {boolean} + */ +PDFJS.disableCreateObjectURL = (PDFJS.disableCreateObjectURL === undefined ? + false : PDFJS.disableCreateObjectURL); + +/** + * Disables WebGL usage. + * @var {boolean} + */ +PDFJS.disableWebGL = (PDFJS.disableWebGL === undefined ? + true : PDFJS.disableWebGL); + +/** + * Disables fullscreen support, and by extension Presentation Mode, + * in browsers which support the fullscreen API. + * @var {boolean} + */ +PDFJS.disableFullscreen = (PDFJS.disableFullscreen === undefined ? + false : PDFJS.disableFullscreen); + +/** + * Enables CSS only zooming. + * @var {boolean} + */ +PDFJS.useOnlyCssZoom = (PDFJS.useOnlyCssZoom === undefined ? + false : PDFJS.useOnlyCssZoom); + +/** + * The maximum supported canvas size in total pixels e.g. width * height. + * The default value is 4096 * 4096. Use -1 for no limit. + * @var {number} + */ +PDFJS.maxCanvasPixels = (PDFJS.maxCanvasPixels === undefined ? + 16777216 : PDFJS.maxCanvasPixels); + +/** + * (Deprecated) Opens external links in a new window if enabled. + * The default behavior opens external links in the PDF.js window. + * + * NOTE: This property has been deprecated, please use + * `PDFJS.externalLinkTarget = PDFJS.LinkTarget.BLANK` instead. + * @var {boolean} + */ +PDFJS.openExternalLinksInNewWindow = ( + PDFJS.openExternalLinksInNewWindow === undefined ? + false : PDFJS.openExternalLinksInNewWindow); + +/** + * Specifies the |target| attribute for external links. + * The constants from PDFJS.LinkTarget should be used: + * - NONE [default] + * - SELF + * - BLANK + * - PARENT + * - TOP + * @var {number} + */ +PDFJS.externalLinkTarget = (PDFJS.externalLinkTarget === undefined ? + PDFJS.LinkTarget.NONE : PDFJS.externalLinkTarget); + +/** + * Specifies the |rel| attribute for external links. Defaults to stripping + * the referrer. + * @var {string} + */ +PDFJS.externalLinkRel = (PDFJS.externalLinkRel === undefined ? + 'noreferrer' : PDFJS.externalLinkRel); + +/** + * Determines if we can eval strings as JS. Primarily used to improve + * performance for font rendering. + * @var {boolean} + */ +PDFJS.isEvalSupported = (PDFJS.isEvalSupported === undefined ? + true : PDFJS.isEvalSupported); + +/** + * Document initialization / loading parameters object. + * + * @typedef {Object} DocumentInitParameters + * @property {string} url - The URL of the PDF. + * @property {TypedArray|Array|string} data - Binary PDF data. Use typed arrays + * (Uint8Array) to improve the memory usage. If PDF data is BASE64-encoded, + * use atob() to convert it to a binary string first. + * @property {Object} httpHeaders - Basic authentication headers. + * @property {boolean} withCredentials - Indicates whether or not cross-site + * Access-Control requests should be made using credentials such as cookies + * or authorization headers. The default is false. + * @property {string} password - For decrypting password-protected PDFs. + * @property {TypedArray} initialData - A typed array with the first portion or + * all of the pdf data. Used by the extension since some data is already + * loaded before the switch to range requests. + * @property {number} length - The PDF file length. It's used for progress + * reports and range requests operations. + * @property {PDFDataRangeTransport} range + * @property {number} rangeChunkSize - Optional parameter to specify + * maximum number of bytes fetched per range request. The default value is + * 2^16 = 65536. + * @property {PDFWorker} worker - The worker that will be used for the loading + * and parsing of the PDF data. + */ + +/** + * @typedef {Object} PDFDocumentStats + * @property {Array} streamTypes - Used stream types in the document (an item + * is set to true if specific stream ID was used in the document). + * @property {Array} fontTypes - Used font type in the document (an item is set + * to true if specific font ID was used in the document). + */ + +/** + * This is the main entry point for loading a PDF and interacting with it. + * NOTE: If a URL is used to fetch the PDF data a standard XMLHttpRequest(XHR) + * is used, which means it must follow the same origin rules that any XHR does + * e.g. No cross domain requests without CORS. + * + * @param {string|TypedArray|DocumentInitParameters|PDFDataRangeTransport} src + * Can be a url to where a PDF is located, a typed array (Uint8Array) + * already populated with data or parameter object. + * + * @param {PDFDataRangeTransport} pdfDataRangeTransport (deprecated) It is used + * if you want to manually serve range requests for data in the PDF. + * + * @param {function} passwordCallback (deprecated) It is used to request a + * password if wrong or no password was provided. The callback receives two + * parameters: function that needs to be called with new password and reason + * (see {PasswordResponses}). + * + * @param {function} progressCallback (deprecated) It is used to be able to + * monitor the loading progress of the PDF file (necessary to implement e.g. + * a loading bar). The callback receives an {Object} with the properties: + * {number} loaded and {number} total. + * + * @return {PDFDocumentLoadingTask} + */ +PDFJS.getDocument = function getDocument(src, + pdfDataRangeTransport, + passwordCallback, + progressCallback) { + var task = new PDFDocumentLoadingTask(); + + // Support of the obsolete arguments (for compatibility with API v1.0) + if (arguments.length > 1) { + deprecated('getDocument is called with pdfDataRangeTransport, ' + + 'passwordCallback or progressCallback argument'); + } + if (pdfDataRangeTransport) { + if (!(pdfDataRangeTransport instanceof PDFDataRangeTransport)) { + // Not a PDFDataRangeTransport instance, trying to add missing properties. + pdfDataRangeTransport = Object.create(pdfDataRangeTransport); + pdfDataRangeTransport.length = src.length; + pdfDataRangeTransport.initialData = src.initialData; + if (!pdfDataRangeTransport.abort) { + pdfDataRangeTransport.abort = function () {}; + } + } + src = Object.create(src); + src.range = pdfDataRangeTransport; + } + task.onPassword = passwordCallback || null; + task.onProgress = progressCallback || null; + + var source; + if (typeof src === 'string') { + source = { url: src }; + } else if (isArrayBuffer(src)) { + source = { data: src }; + } else if (src instanceof PDFDataRangeTransport) { + source = { range: src }; + } else { + if (typeof src !== 'object') { + error('Invalid parameter in getDocument, need either Uint8Array, ' + + 'string or a parameter object'); + } + if (!src.url && !src.data && !src.range) { + error('Invalid parameter object: need either .data, .range or .url'); + } + + source = src; + } + + var params = {}; + var rangeTransport = null; + var worker = null; + for (var key in source) { + if (key === 'url' && typeof window !== 'undefined') { + // The full path is required in the 'url' field. + params[key] = combineUrl(window.location.href, source[key]); + continue; + } else if (key === 'range') { + rangeTransport = source[key]; + continue; + } else if (key === 'worker') { + worker = source[key]; + continue; + } else if (key === 'data' && !(source[key] instanceof Uint8Array)) { + // Converting string or array-like data to Uint8Array. + var pdfBytes = source[key]; + if (typeof pdfBytes === 'string') { + params[key] = stringToBytes(pdfBytes); + } else if (typeof pdfBytes === 'object' && pdfBytes !== null && + !isNaN(pdfBytes.length)) { + params[key] = new Uint8Array(pdfBytes); + } else if (isArrayBuffer(pdfBytes)) { + params[key] = new Uint8Array(pdfBytes); + } else { + error('Invalid PDF binary data: either typed array, string or ' + + 'array-like object is expected in the data property.'); + } + continue; + } + params[key] = source[key]; + } + + params.rangeChunkSize = params.rangeChunkSize || DEFAULT_RANGE_CHUNK_SIZE; + + if (!worker) { + // Worker was not provided -- creating and owning our own. + worker = new PDFWorker(); + task._worker = worker; + } + var docId = task.docId; + worker.promise.then(function () { + if (task.destroyed) { + throw new Error('Loading aborted'); + } + return _fetchDocument(worker, params, rangeTransport, docId).then( + function (workerId) { + if (task.destroyed) { + throw new Error('Loading aborted'); + } + var messageHandler = new MessageHandler(docId, workerId, worker.port); + var transport = new WorkerTransport(messageHandler, task, rangeTransport); + task._transport = transport; + messageHandler.send('Ready', null); + }); + }).catch(task._capability.reject); + + return task; +}; + +/** + * Starts fetching of specified PDF document/data. + * @param {PDFWorker} worker + * @param {Object} source + * @param {PDFDataRangeTransport} pdfDataRangeTransport + * @param {string} docId Unique document id, used as MessageHandler id. + * @returns {Promise} The promise, which is resolved when worker id of + * MessageHandler is known. + * @private + */ +function _fetchDocument(worker, source, pdfDataRangeTransport, docId) { + if (worker.destroyed) { + return Promise.reject(new Error('Worker was destroyed')); + } + + source.disableAutoFetch = PDFJS.disableAutoFetch; + source.disableStream = PDFJS.disableStream; + source.chunkedViewerLoading = !!pdfDataRangeTransport; + if (pdfDataRangeTransport) { + source.length = pdfDataRangeTransport.length; + source.initialData = pdfDataRangeTransport.initialData; + } + return worker.messageHandler.sendWithPromise('GetDocRequest', { + docId: docId, + source: source, + disableRange: PDFJS.disableRange, + maxImageSize: PDFJS.maxImageSize, + cMapUrl: PDFJS.cMapUrl, + cMapPacked: PDFJS.cMapPacked, + disableFontFace: PDFJS.disableFontFace, + disableCreateObjectURL: PDFJS.disableCreateObjectURL, + postMessageTransfers: PDFJS.postMessageTransfers, + }).then(function (workerId) { + if (worker.destroyed) { + throw new Error('Worker was destroyed'); + } + return workerId; + }); +} + +/** + * PDF document loading operation. + * @class + * @alias PDFDocumentLoadingTask + */ +var PDFDocumentLoadingTask = (function PDFDocumentLoadingTaskClosure() { + var nextDocumentId = 0; + + /** @constructs PDFDocumentLoadingTask */ + function PDFDocumentLoadingTask() { + this._capability = createPromiseCapability(); + this._transport = null; + this._worker = null; + + /** + * Unique document loading task id -- used in MessageHandlers. + * @type {string} + */ + this.docId = 'd' + (nextDocumentId++); + + /** + * Shows if loading task is destroyed. + * @type {boolean} + */ + this.destroyed = false; + + /** + * Callback to request a password if wrong or no password was provided. + * The callback receives two parameters: function that needs to be called + * with new password and reason (see {PasswordResponses}). + */ + this.onPassword = null; + + /** + * Callback to be able to monitor the loading progress of the PDF file + * (necessary to implement e.g. a loading bar). The callback receives + * an {Object} with the properties: {number} loaded and {number} total. + */ + this.onProgress = null; + + /** + * Callback to when unsupported feature is used. The callback receives + * an {PDFJS.UNSUPPORTED_FEATURES} argument. + */ + this.onUnsupportedFeature = null; + } + + PDFDocumentLoadingTask.prototype = + /** @lends PDFDocumentLoadingTask.prototype */ { + /** + * @return {Promise} + */ + get promise() { + return this._capability.promise; + }, + + /** + * Aborts all network requests and destroys worker. + * @return {Promise} A promise that is resolved after destruction activity + * is completed. + */ + destroy: function () { + this.destroyed = true; + + var transportDestroyed = !this._transport ? Promise.resolve() : + this._transport.destroy(); + return transportDestroyed.then(function () { + this._transport = null; + if (this._worker) { + this._worker.destroy(); + this._worker = null; + } + }.bind(this)); + }, + + /** + * Registers callbacks to indicate the document loading completion. + * + * @param {function} onFulfilled The callback for the loading completion. + * @param {function} onRejected The callback for the loading failure. + * @return {Promise} A promise that is resolved after the onFulfilled or + * onRejected callback. + */ + then: function PDFDocumentLoadingTask_then(onFulfilled, onRejected) { + return this.promise.then.apply(this.promise, arguments); + } + }; + + return PDFDocumentLoadingTask; +})(); + +/** + * Abstract class to support range requests file loading. + * @class + * @alias PDFJS.PDFDataRangeTransport + * @param {number} length + * @param {Uint8Array} initialData + */ +var PDFDataRangeTransport = (function pdfDataRangeTransportClosure() { + function PDFDataRangeTransport(length, initialData) { + this.length = length; + this.initialData = initialData; + + this._rangeListeners = []; + this._progressListeners = []; + this._progressiveReadListeners = []; + this._readyCapability = createPromiseCapability(); + } + PDFDataRangeTransport.prototype = + /** @lends PDFDataRangeTransport.prototype */ { + addRangeListener: + function PDFDataRangeTransport_addRangeListener(listener) { + this._rangeListeners.push(listener); + }, + + addProgressListener: + function PDFDataRangeTransport_addProgressListener(listener) { + this._progressListeners.push(listener); + }, + + addProgressiveReadListener: + function PDFDataRangeTransport_addProgressiveReadListener(listener) { + this._progressiveReadListeners.push(listener); + }, + + onDataRange: function PDFDataRangeTransport_onDataRange(begin, chunk) { + var listeners = this._rangeListeners; + for (var i = 0, n = listeners.length; i < n; ++i) { + listeners[i](begin, chunk); + } + }, + + onDataProgress: function PDFDataRangeTransport_onDataProgress(loaded) { + this._readyCapability.promise.then(function () { + var listeners = this._progressListeners; + for (var i = 0, n = listeners.length; i < n; ++i) { + listeners[i](loaded); + } + }.bind(this)); + }, + + onDataProgressiveRead: + function PDFDataRangeTransport_onDataProgress(chunk) { + this._readyCapability.promise.then(function () { + var listeners = this._progressiveReadListeners; + for (var i = 0, n = listeners.length; i < n; ++i) { + listeners[i](chunk); + } + }.bind(this)); + }, + + transportReady: function PDFDataRangeTransport_transportReady() { + this._readyCapability.resolve(); + }, + + requestDataRange: + function PDFDataRangeTransport_requestDataRange(begin, end) { + throw new Error('Abstract method PDFDataRangeTransport.requestDataRange'); + }, + + abort: function PDFDataRangeTransport_abort() { + } + }; + return PDFDataRangeTransport; +})(); + +PDFJS.PDFDataRangeTransport = PDFDataRangeTransport; + +/** + * Proxy to a PDFDocument in the worker thread. Also, contains commonly used + * properties that can be read synchronously. + * @class + * @alias PDFDocumentProxy + */ +var PDFDocumentProxy = (function PDFDocumentProxyClosure() { + function PDFDocumentProxy(pdfInfo, transport, loadingTask) { + this.pdfInfo = pdfInfo; + this.transport = transport; + this.loadingTask = loadingTask; + } + PDFDocumentProxy.prototype = /** @lends PDFDocumentProxy.prototype */ { + /** + * @return {number} Total number of pages the PDF contains. + */ + get numPages() { + return this.pdfInfo.numPages; + }, + /** + * @return {string} A unique ID to identify a PDF. Not guaranteed to be + * unique. + */ + get fingerprint() { + return this.pdfInfo.fingerprint; + }, + /** + * @param {number} pageNumber The page number to get. The first page is 1. + * @return {Promise} A promise that is resolved with a {@link PDFPageProxy} + * object. + */ + getPage: function PDFDocumentProxy_getPage(pageNumber) { + return this.transport.getPage(pageNumber); + }, + /** + * @param {{num: number, gen: number}} ref The page reference. Must have + * the 'num' and 'gen' properties. + * @return {Promise} A promise that is resolved with the page index that is + * associated with the reference. + */ + getPageIndex: function PDFDocumentProxy_getPageIndex(ref) { + return this.transport.getPageIndex(ref); + }, + /** + * @return {Promise} A promise that is resolved with a lookup table for + * mapping named destinations to reference numbers. + * + * This can be slow for large documents: use getDestination instead + */ + getDestinations: function PDFDocumentProxy_getDestinations() { + return this.transport.getDestinations(); + }, + /** + * @param {string} id The named destination to get. + * @return {Promise} A promise that is resolved with all information + * of the given named destination. + */ + getDestination: function PDFDocumentProxy_getDestination(id) { + return this.transport.getDestination(id); + }, + /** + * @return {Promise} A promise that is resolved with: + * an Array containing the pageLabels that correspond to the pageIndexes, + * or `null` when no pageLabels are present in the PDF file. + */ + getPageLabels: function PDFDocumentProxy_getPageLabels() { + return this.transport.getPageLabels(); + }, + /** + * @return {Promise} A promise that is resolved with a lookup table for + * mapping named attachments to their content. + */ + getAttachments: function PDFDocumentProxy_getAttachments() { + return this.transport.getAttachments(); + }, + /** + * @return {Promise} A promise that is resolved with an array of all the + * JavaScript strings in the name tree. + */ + getJavaScript: function PDFDocumentProxy_getJavaScript() { + return this.transport.getJavaScript(); + }, + /** + * @return {Promise} A promise that is resolved with an {Array} that is a + * tree outline (if it has one) of the PDF. The tree is in the format of: + * [ + * { + * title: string, + * bold: boolean, + * italic: boolean, + * color: rgb Uint8Array, + * dest: dest obj, + * url: string, + * items: array of more items like this + * }, + * ... + * ]. + */ + getOutline: function PDFDocumentProxy_getOutline() { + return this.transport.getOutline(); + }, + /** + * @return {Promise} A promise that is resolved with an {Object} that has + * info and metadata properties. Info is an {Object} filled with anything + * available in the information dictionary and similarly metadata is a + * {Metadata} object with information from the metadata section of the PDF. + */ + getMetadata: function PDFDocumentProxy_getMetadata() { + return this.transport.getMetadata(); + }, + /** + * @return {Promise} A promise that is resolved with a TypedArray that has + * the raw data from the PDF. + */ + getData: function PDFDocumentProxy_getData() { + return this.transport.getData(); + }, + /** + * @return {Promise} A promise that is resolved when the document's data + * is loaded. It is resolved with an {Object} that contains the length + * property that indicates size of the PDF data in bytes. + */ + getDownloadInfo: function PDFDocumentProxy_getDownloadInfo() { + return this.transport.downloadInfoCapability.promise; + }, + /** + * @return {Promise} A promise this is resolved with current stats about + * document structures (see {@link PDFDocumentStats}). + */ + getStats: function PDFDocumentProxy_getStats() { + return this.transport.getStats(); + }, + /** + * Cleans up resources allocated by the document, e.g. created @font-face. + */ + cleanup: function PDFDocumentProxy_cleanup() { + this.transport.startCleanup(); + }, + /** + * Destroys current document instance and terminates worker. + */ + destroy: function PDFDocumentProxy_destroy() { + return this.loadingTask.destroy(); + } + }; + return PDFDocumentProxy; +})(); + +/** + * Page getTextContent parameters. + * + * @typedef {Object} getTextContentParameters + * @param {boolean} normalizeWhitespace - replaces all occurrences of + * whitespace with standard spaces (0x20). The default value is `false`. + */ + +/** + * Page text content. + * + * @typedef {Object} TextContent + * @property {array} items - array of {@link TextItem} + * @property {Object} styles - {@link TextStyles} objects, indexed by font + * name. + */ + +/** + * Page text content part. + * + * @typedef {Object} TextItem + * @property {string} str - text content. + * @property {string} dir - text direction: 'ttb', 'ltr' or 'rtl'. + * @property {array} transform - transformation matrix. + * @property {number} width - width in device space. + * @property {number} height - height in device space. + * @property {string} fontName - font name used by pdf.js for converted font. + */ + +/** + * Text style. + * + * @typedef {Object} TextStyle + * @property {number} ascent - font ascent. + * @property {number} descent - font descent. + * @property {boolean} vertical - text is in vertical mode. + * @property {string} fontFamily - possible font family + */ + +/** + * Page annotation parameters. + * + * @typedef {Object} GetAnnotationsParameters + * @param {string} intent - Determines the annotations that will be fetched, + * can be either 'display' (viewable annotations) or 'print' + * (printable annotations). + * If the parameter is omitted, all annotations are fetched. + */ + +/** + * Page render parameters. + * + * @typedef {Object} RenderParameters + * @property {Object} canvasContext - A 2D context of a DOM Canvas object. + * @property {PDFJS.PageViewport} viewport - Rendering viewport obtained by + * calling of PDFPage.getViewport method. + * @property {string} intent - Rendering intent, can be 'display' or 'print' + * (default value is 'display'). + * @property {Array} transform - (optional) Additional transform, applied + * just before viewport transform. + * @property {Object} imageLayer - (optional) An object that has beginLayout, + * endLayout and appendImage functions. + * @property {function} continueCallback - (deprecated) A function that will be + * called each time the rendering is paused. To continue + * rendering call the function that is the first argument + * to the callback. + */ + +/** + * PDF page operator list. + * + * @typedef {Object} PDFOperatorList + * @property {Array} fnArray - Array containing the operator functions. + * @property {Array} argsArray - Array containing the arguments of the + * functions. + */ + +/** + * Proxy to a PDFPage in the worker thread. + * @class + * @alias PDFPageProxy + */ +var PDFPageProxy = (function PDFPageProxyClosure() { + function PDFPageProxy(pageIndex, pageInfo, transport) { + this.pageIndex = pageIndex; + this.pageInfo = pageInfo; + this.transport = transport; + this.stats = new StatTimer(); + this.stats.enabled = !!globalScope.PDFJS.enableStats; + this.commonObjs = transport.commonObjs; + this.objs = new PDFObjects(); + this.cleanupAfterRender = false; + this.pendingCleanup = false; + this.intentStates = Object.create(null); + this.destroyed = false; + } + PDFPageProxy.prototype = /** @lends PDFPageProxy.prototype */ { + /** + * @return {number} Page number of the page. First page is 1. + */ + get pageNumber() { + return this.pageIndex + 1; + }, + /** + * @return {number} The number of degrees the page is rotated clockwise. + */ + get rotate() { + return this.pageInfo.rotate; + }, + /** + * @return {Object} The reference that points to this page. It has 'num' and + * 'gen' properties. + */ + get ref() { + return this.pageInfo.ref; + }, + /** + * @return {Array} An array of the visible portion of the PDF page in the + * user space units - [x1, y1, x2, y2]. + */ + get view() { + return this.pageInfo.view; + }, + /** + * @param {number} scale The desired scale of the viewport. + * @param {number} rotate Degrees to rotate the viewport. If omitted this + * defaults to the page rotation. + * @return {PDFJS.PageViewport} Contains 'width' and 'height' properties + * along with transforms required for rendering. + */ + getViewport: function PDFPageProxy_getViewport(scale, rotate) { + if (arguments.length < 2) { + rotate = this.rotate; + } + return new PDFJS.PageViewport(this.view, scale, rotate, 0, 0); + }, + /** + * @param {GetAnnotationsParameters} params - Annotation parameters. + * @return {Promise} A promise that is resolved with an {Array} of the + * annotation objects. + */ + getAnnotations: function PDFPageProxy_getAnnotations(params) { + var intent = (params && params.intent) || null; + + if (!this.annotationsPromise || this.annotationsIntent !== intent) { + this.annotationsPromise = this.transport.getAnnotations(this.pageIndex, + intent); + this.annotationsIntent = intent; + } + return this.annotationsPromise; + }, + /** + * Begins the process of rendering a page to the desired context. + * @param {RenderParameters} params Page render parameters. + * @return {RenderTask} An object that contains the promise, which + * is resolved when the page finishes rendering. + */ + render: function PDFPageProxy_render(params) { + var stats = this.stats; + stats.time('Overall'); + + // If there was a pending destroy cancel it so no cleanup happens during + // this call to render. + this.pendingCleanup = false; + + var renderingIntent = (params.intent === 'print' ? 'print' : 'display'); + + if (!this.intentStates[renderingIntent]) { + this.intentStates[renderingIntent] = Object.create(null); + } + var intentState = this.intentStates[renderingIntent]; + + // If there's no displayReadyCapability yet, then the operatorList + // was never requested before. Make the request and create the promise. + if (!intentState.displayReadyCapability) { + intentState.receivingOperatorList = true; + intentState.displayReadyCapability = createPromiseCapability(); + intentState.operatorList = { + fnArray: [], + argsArray: [], + lastChunk: false + }; + + this.stats.time('Page Request'); + this.transport.messageHandler.send('RenderPageRequest', { + pageIndex: this.pageNumber - 1, + intent: renderingIntent + }); + } + + var internalRenderTask = new InternalRenderTask(complete, params, + this.objs, + this.commonObjs, + intentState.operatorList, + this.pageNumber); + internalRenderTask.useRequestAnimationFrame = renderingIntent !== 'print'; + if (!intentState.renderTasks) { + intentState.renderTasks = []; + } + intentState.renderTasks.push(internalRenderTask); + var renderTask = internalRenderTask.task; + + // Obsolete parameter support + if (params.continueCallback) { + deprecated('render is used with continueCallback parameter'); + renderTask.onContinue = params.continueCallback; + } + + var self = this; + intentState.displayReadyCapability.promise.then( + function pageDisplayReadyPromise(transparency) { + if (self.pendingCleanup) { + complete(); + return; + } + stats.time('Rendering'); + internalRenderTask.initalizeGraphics(transparency); + internalRenderTask.operatorListChanged(); + }, + function pageDisplayReadPromiseError(reason) { + complete(reason); + } + ); + + function complete(error) { + var i = intentState.renderTasks.indexOf(internalRenderTask); + if (i >= 0) { + intentState.renderTasks.splice(i, 1); + } + + if (self.cleanupAfterRender) { + self.pendingCleanup = true; + } + self._tryCleanup(); + + if (error) { + internalRenderTask.capability.reject(error); + } else { + internalRenderTask.capability.resolve(); + } + stats.timeEnd('Rendering'); + stats.timeEnd('Overall'); + } + + return renderTask; + }, + + /** + * @return {Promise} A promise resolved with an {@link PDFOperatorList} + * object that represents page's operator list. + */ + getOperatorList: function PDFPageProxy_getOperatorList() { + function operatorListChanged() { + if (intentState.operatorList.lastChunk) { + intentState.opListReadCapability.resolve(intentState.operatorList); + + var i = intentState.renderTasks.indexOf(opListTask); + if (i >= 0) { + intentState.renderTasks.splice(i, 1); + } + } + } + + var renderingIntent = 'oplist'; + if (!this.intentStates[renderingIntent]) { + this.intentStates[renderingIntent] = Object.create(null); + } + var intentState = this.intentStates[renderingIntent]; + var opListTask; + + if (!intentState.opListReadCapability) { + opListTask = {}; + opListTask.operatorListChanged = operatorListChanged; + intentState.receivingOperatorList = true; + intentState.opListReadCapability = createPromiseCapability(); + intentState.renderTasks = []; + intentState.renderTasks.push(opListTask); + intentState.operatorList = { + fnArray: [], + argsArray: [], + lastChunk: false + }; + + this.transport.messageHandler.send('RenderPageRequest', { + pageIndex: this.pageIndex, + intent: renderingIntent + }); + } + return intentState.opListReadCapability.promise; + }, + + /** + * @param {getTextContentParameters} params - getTextContent parameters. + * @return {Promise} That is resolved a {@link TextContent} + * object that represent the page text content. + */ + getTextContent: function PDFPageProxy_getTextContent(params) { + var normalizeWhitespace = (params && params.normalizeWhitespace) || false; + + return this.transport.messageHandler.sendWithPromise('GetTextContent', { + pageIndex: this.pageNumber - 1, + normalizeWhitespace: normalizeWhitespace, + }); + }, + + /** + * Destroys page object. + */ + _destroy: function PDFPageProxy_destroy() { + this.destroyed = true; + this.transport.pageCache[this.pageIndex] = null; + + var waitOn = []; + Object.keys(this.intentStates).forEach(function(intent) { + if (intent === 'oplist') { + // Avoid errors below, since the renderTasks are just stubs. + return; + } + var intentState = this.intentStates[intent]; + intentState.renderTasks.forEach(function(renderTask) { + var renderCompleted = renderTask.capability.promise. + catch(function () {}); // ignoring failures + waitOn.push(renderCompleted); + renderTask.cancel(); + }); + }, this); + this.objs.clear(); + this.annotationsPromise = null; + this.pendingCleanup = false; + return Promise.all(waitOn); + }, + + /** + * Cleans up resources allocated by the page. (deprecated) + */ + destroy: function() { + deprecated('page destroy method, use cleanup() instead'); + this.cleanup(); + }, + + /** + * Cleans up resources allocated by the page. + */ + cleanup: function PDFPageProxy_cleanup() { + this.pendingCleanup = true; + this._tryCleanup(); + }, + /** + * For internal use only. Attempts to clean up if rendering is in a state + * where that's possible. + * @ignore + */ + _tryCleanup: function PDFPageProxy_tryCleanup() { + if (!this.pendingCleanup || + Object.keys(this.intentStates).some(function(intent) { + var intentState = this.intentStates[intent]; + return (intentState.renderTasks.length !== 0 || + intentState.receivingOperatorList); + }, this)) { + return; + } + + Object.keys(this.intentStates).forEach(function(intent) { + delete this.intentStates[intent]; + }, this); + this.objs.clear(); + this.annotationsPromise = null; + this.pendingCleanup = false; + }, + /** + * For internal use only. + * @ignore + */ + _startRenderPage: function PDFPageProxy_startRenderPage(transparency, + intent) { + var intentState = this.intentStates[intent]; + // TODO Refactor RenderPageRequest to separate rendering + // and operator list logic + if (intentState.displayReadyCapability) { + intentState.displayReadyCapability.resolve(transparency); + } + }, + /** + * For internal use only. + * @ignore + */ + _renderPageChunk: function PDFPageProxy_renderPageChunk(operatorListChunk, + intent) { + var intentState = this.intentStates[intent]; + var i, ii; + // Add the new chunk to the current operator list. + for (i = 0, ii = operatorListChunk.length; i < ii; i++) { + intentState.operatorList.fnArray.push(operatorListChunk.fnArray[i]); + intentState.operatorList.argsArray.push( + operatorListChunk.argsArray[i]); + } + intentState.operatorList.lastChunk = operatorListChunk.lastChunk; + + // Notify all the rendering tasks there are more operators to be consumed. + for (i = 0; i < intentState.renderTasks.length; i++) { + intentState.renderTasks[i].operatorListChanged(); + } + + if (operatorListChunk.lastChunk) { + intentState.receivingOperatorList = false; + this._tryCleanup(); + } + } + }; + return PDFPageProxy; +})(); + +/** + * PDF.js web worker abstraction, it controls instantiation of PDF documents and + * WorkerTransport for them. If creation of a web worker is not possible, + * a "fake" worker will be used instead. + * @class + */ +var PDFWorker = (function PDFWorkerClosure() { + var nextFakeWorkerId = 0; + + function getWorkerSrc() { + if (PDFJS.workerSrc) { + return PDFJS.workerSrc; + } + if (pdfjsFilePath) { + return pdfjsFilePath.replace(/\.js$/i, '.worker.js'); + } + error('No PDFJS.workerSrc specified'); + } + + var fakeWorkerFilesLoadedCapability; + + // Loads worker code into main thread. + function setupFakeWorkerGlobal() { + var WorkerMessageHandler; + if (!fakeWorkerFilesLoadedCapability) { + fakeWorkerFilesLoadedCapability = createPromiseCapability(); + // In the developer build load worker_loader which in turn loads all the + // other files and resolves the promise. In production only the + // pdf.worker.js file is needed. + var loader = fakeWorkerFilesLoader || function (callback) { + Util.loadScript(getWorkerSrc(), function () { + callback(window.pdfjsDistBuildPdfWorker.WorkerMessageHandler); + }); + }; + loader(fakeWorkerFilesLoadedCapability.resolve); + } + return fakeWorkerFilesLoadedCapability.promise; + } + + function createCDNWrapper(url) { + // We will rely on blob URL's property to specify origin. + // We want this function to fail in case if createObjectURL or Blob do not + // exist or fail for some reason -- our Worker creation will fail anyway. + var wrapper = 'importScripts(\'' + url + '\');'; + return URL.createObjectURL(new Blob([wrapper])); + } + + function PDFWorker(name) { + this.name = name; + this.destroyed = false; + + this._readyCapability = createPromiseCapability(); + this._port = null; + this._webWorker = null; + this._messageHandler = null; + this._initialize(); + } + + PDFWorker.prototype = /** @lends PDFWorker.prototype */ { + get promise() { + return this._readyCapability.promise; + }, + + get port() { + return this._port; + }, + + get messageHandler() { + return this._messageHandler; + }, + + _initialize: function PDFWorker_initialize() { + // If worker support isn't disabled explicit and the browser has worker + // support, create a new web worker and test if it/the browser fulfills + // all requirements to run parts of pdf.js in a web worker. + // Right now, the requirement is, that an Uint8Array is still an + // Uint8Array as it arrives on the worker. (Chrome added this with v.15.) + if (!globalScope.PDFJS.disableWorker && typeof Worker !== 'undefined') { + var workerSrc = getWorkerSrc(); + + try { + // Wraps workerSrc path into blob URL, if the former does not belong + // to the same origin. + if (!isSameOrigin(window.location.href, workerSrc)) { + workerSrc = createCDNWrapper( + combineUrl(window.location.href, workerSrc)); + } + // Some versions of FF can't create a worker on localhost, see: + // https://bugzilla.mozilla.org/show_bug.cgi?id=683280 + var worker = new Worker(workerSrc); + var messageHandler = new MessageHandler('main', 'worker', worker); + var terminateEarly = function() { + worker.removeEventListener('error', onWorkerError); + messageHandler.destroy(); + worker.terminate(); + if (this.destroyed) { + this._readyCapability.reject(new Error('Worker was destroyed')); + } else { + // Fall back to fake worker if the termination is caused by an + // error (e.g. NetworkError / SecurityError). + this._setupFakeWorker(); + } + }.bind(this); + + var onWorkerError = function(event) { + if (!this._webWorker) { + // Worker failed to initialize due to an error. Clean up and fall + // back to the fake worker. + terminateEarly(); + } + }.bind(this); + worker.addEventListener('error', onWorkerError); + + messageHandler.on('test', function PDFWorker_test(data) { + worker.removeEventListener('error', onWorkerError); + if (this.destroyed) { + terminateEarly(); + return; // worker was destroyed + } + var supportTypedArray = data && data.supportTypedArray; + if (supportTypedArray) { + this._messageHandler = messageHandler; + this._port = worker; + this._webWorker = worker; + if (!data.supportTransfers) { + PDFJS.postMessageTransfers = false; + } + this._readyCapability.resolve(); + // Send global PDFJS setting, e.g. verbosity level. + messageHandler.send('configure', { + verbosity: getVerbosityLevel() + }); + } else { + this._setupFakeWorker(); + messageHandler.destroy(); + worker.terminate(); + } + }.bind(this)); + + messageHandler.on('console_log', function (data) { + console.log.apply(console, data); + }); + messageHandler.on('console_error', function (data) { + console.error.apply(console, data); + }); + + messageHandler.on('ready', function (data) { + worker.removeEventListener('error', onWorkerError); + if (this.destroyed) { + terminateEarly(); + return; // worker was destroyed + } + try { + sendTest(); + } catch (e) { + // We need fallback to a faked worker. + this._setupFakeWorker(); + } + }.bind(this)); + + var sendTest = function () { + var testObj = new Uint8Array( + [PDFJS.postMessageTransfers ? 255 : 0]); + // Some versions of Opera throw a DATA_CLONE_ERR on serializing the + // typed array. Also, checking if we can use transfers. + try { + messageHandler.send('test', testObj, [testObj.buffer]); + } catch (ex) { + info('Cannot use postMessage transfers'); + testObj[0] = 0; + messageHandler.send('test', testObj); + } + }; + + // It might take time for worker to initialize (especially when AMD + // loader is used). We will try to send test immediately, and then + // when 'ready' message will arrive. The worker shall process only + // first received 'test'. + sendTest(); + return; + } catch (e) { + info('The worker has been disabled.'); + } + } + // Either workers are disabled, not supported or have thrown an exception. + // Thus, we fallback to a faked worker. + this._setupFakeWorker(); + }, + + _setupFakeWorker: function PDFWorker_setupFakeWorker() { + if (!globalScope.PDFJS.disableWorker) { + warn('Setting up fake worker.'); + globalScope.PDFJS.disableWorker = true; + } + + setupFakeWorkerGlobal().then(function (WorkerMessageHandler) { + if (this.destroyed) { + this._readyCapability.reject(new Error('Worker was destroyed')); + return; + } + + // If we don't use a worker, just post/sendMessage to the main thread. + var port = { + _listeners: [], + postMessage: function (obj) { + var e = {data: obj}; + this._listeners.forEach(function (listener) { + listener.call(this, e); + }, this); + }, + addEventListener: function (name, listener) { + this._listeners.push(listener); + }, + removeEventListener: function (name, listener) { + var i = this._listeners.indexOf(listener); + this._listeners.splice(i, 1); + }, + terminate: function () {} + }; + this._port = port; + + // All fake workers use the same port, making id unique. + var id = 'fake' + (nextFakeWorkerId++); + + // If the main thread is our worker, setup the handling for the + // messages -- the main thread sends to it self. + var workerHandler = new MessageHandler(id + '_worker', id, port); + WorkerMessageHandler.setup(workerHandler, port); + + var messageHandler = new MessageHandler(id, id + '_worker', port); + this._messageHandler = messageHandler; + this._readyCapability.resolve(); + }.bind(this)); + }, + + /** + * Destroys the worker instance. + */ + destroy: function PDFWorker_destroy() { + this.destroyed = true; + if (this._webWorker) { + // We need to terminate only web worker created resource. + this._webWorker.terminate(); + this._webWorker = null; + } + this._port = null; + if (this._messageHandler) { + this._messageHandler.destroy(); + this._messageHandler = null; + } + } + }; + + return PDFWorker; +})(); +PDFJS.PDFWorker = PDFWorker; + +/** + * For internal use only. + * @ignore + */ +var WorkerTransport = (function WorkerTransportClosure() { + function WorkerTransport(messageHandler, loadingTask, pdfDataRangeTransport) { + this.messageHandler = messageHandler; + this.loadingTask = loadingTask; + this.pdfDataRangeTransport = pdfDataRangeTransport; + this.commonObjs = new PDFObjects(); + this.fontLoader = new FontLoader(loadingTask.docId); + + this.destroyed = false; + this.destroyCapability = null; + + this.pageCache = []; + this.pagePromises = []; + this.downloadInfoCapability = createPromiseCapability(); + + this.setupMessageHandler(); + } + WorkerTransport.prototype = { + destroy: function WorkerTransport_destroy() { + if (this.destroyCapability) { + return this.destroyCapability.promise; + } + + this.destroyed = true; + this.destroyCapability = createPromiseCapability(); + + var waitOn = []; + // We need to wait for all renderings to be completed, e.g. + // timeout/rAF can take a long time. + this.pageCache.forEach(function (page) { + if (page) { + waitOn.push(page._destroy()); + } + }); + this.pageCache = []; + this.pagePromises = []; + var self = this; + // We also need to wait for the worker to finish its long running tasks. + var terminated = this.messageHandler.sendWithPromise('Terminate', null); + waitOn.push(terminated); + Promise.all(waitOn).then(function () { + self.fontLoader.clear(); + if (self.pdfDataRangeTransport) { + self.pdfDataRangeTransport.abort(); + self.pdfDataRangeTransport = null; + } + if (self.messageHandler) { + self.messageHandler.destroy(); + self.messageHandler = null; + } + self.destroyCapability.resolve(); + }, this.destroyCapability.reject); + return this.destroyCapability.promise; + }, + + setupMessageHandler: + function WorkerTransport_setupMessageHandler() { + var messageHandler = this.messageHandler; + + function updatePassword(password) { + messageHandler.send('UpdatePassword', password); + } + + var pdfDataRangeTransport = this.pdfDataRangeTransport; + if (pdfDataRangeTransport) { + pdfDataRangeTransport.addRangeListener(function(begin, chunk) { + messageHandler.send('OnDataRange', { + begin: begin, + chunk: chunk + }); + }); + + pdfDataRangeTransport.addProgressListener(function(loaded) { + messageHandler.send('OnDataProgress', { + loaded: loaded + }); + }); + + pdfDataRangeTransport.addProgressiveReadListener(function(chunk) { + messageHandler.send('OnDataRange', { + chunk: chunk + }); + }); + + messageHandler.on('RequestDataRange', + function transportDataRange(data) { + pdfDataRangeTransport.requestDataRange(data.begin, data.end); + }, this); + } + + messageHandler.on('GetDoc', function transportDoc(data) { + var pdfInfo = data.pdfInfo; + this.numPages = data.pdfInfo.numPages; + var loadingTask = this.loadingTask; + var pdfDocument = new PDFDocumentProxy(pdfInfo, this, loadingTask); + this.pdfDocument = pdfDocument; + loadingTask._capability.resolve(pdfDocument); + }, this); + + messageHandler.on('NeedPassword', + function transportNeedPassword(exception) { + var loadingTask = this.loadingTask; + if (loadingTask.onPassword) { + return loadingTask.onPassword(updatePassword, + PasswordResponses.NEED_PASSWORD); + } + loadingTask._capability.reject( + new PasswordException(exception.message, exception.code)); + }, this); + + messageHandler.on('IncorrectPassword', + function transportIncorrectPassword(exception) { + var loadingTask = this.loadingTask; + if (loadingTask.onPassword) { + return loadingTask.onPassword(updatePassword, + PasswordResponses.INCORRECT_PASSWORD); + } + loadingTask._capability.reject( + new PasswordException(exception.message, exception.code)); + }, this); + + messageHandler.on('InvalidPDF', function transportInvalidPDF(exception) { + this.loadingTask._capability.reject( + new InvalidPDFException(exception.message)); + }, this); + + messageHandler.on('MissingPDF', function transportMissingPDF(exception) { + this.loadingTask._capability.reject( + new MissingPDFException(exception.message)); + }, this); + + messageHandler.on('UnexpectedResponse', + function transportUnexpectedResponse(exception) { + this.loadingTask._capability.reject( + new UnexpectedResponseException(exception.message, exception.status)); + }, this); + + messageHandler.on('UnknownError', + function transportUnknownError(exception) { + this.loadingTask._capability.reject( + new UnknownErrorException(exception.message, exception.details)); + }, this); + + messageHandler.on('DataLoaded', function transportPage(data) { + this.downloadInfoCapability.resolve(data); + }, this); + + messageHandler.on('PDFManagerReady', function transportPage(data) { + if (this.pdfDataRangeTransport) { + this.pdfDataRangeTransport.transportReady(); + } + }, this); + + messageHandler.on('StartRenderPage', function transportRender(data) { + if (this.destroyed) { + return; // Ignore any pending requests if the worker was terminated. + } + var page = this.pageCache[data.pageIndex]; + + page.stats.timeEnd('Page Request'); + page._startRenderPage(data.transparency, data.intent); + }, this); + + messageHandler.on('RenderPageChunk', function transportRender(data) { + if (this.destroyed) { + return; // Ignore any pending requests if the worker was terminated. + } + var page = this.pageCache[data.pageIndex]; + + page._renderPageChunk(data.operatorList, data.intent); + }, this); + + messageHandler.on('commonobj', function transportObj(data) { + if (this.destroyed) { + return; // Ignore any pending requests if the worker was terminated. + } + + var id = data[0]; + var type = data[1]; + if (this.commonObjs.hasData(id)) { + return; + } + + switch (type) { + case 'Font': + var exportedData = data[2]; + + var font; + if ('error' in exportedData) { + var error = exportedData.error; + warn('Error during font loading: ' + error); + this.commonObjs.resolve(id, error); + break; + } else { + font = new FontFaceObject(exportedData); + } + + this.fontLoader.bind( + [font], + function fontReady(fontObjs) { + this.commonObjs.resolve(id, font); + }.bind(this) + ); + break; + case 'FontPath': + this.commonObjs.resolve(id, data[2]); + break; + default: + error('Got unknown common object type ' + type); + } + }, this); + + messageHandler.on('obj', function transportObj(data) { + if (this.destroyed) { + return; // Ignore any pending requests if the worker was terminated. + } + + var id = data[0]; + var pageIndex = data[1]; + var type = data[2]; + var pageProxy = this.pageCache[pageIndex]; + var imageData; + if (pageProxy.objs.hasData(id)) { + return; + } + + switch (type) { + case 'JpegStream': + imageData = data[3]; + loadJpegStream(id, imageData, pageProxy.objs); + break; + case 'Image': + imageData = data[3]; + pageProxy.objs.resolve(id, imageData); + + // heuristics that will allow not to store large data + var MAX_IMAGE_SIZE_TO_STORE = 8000000; + if (imageData && 'data' in imageData && + imageData.data.length > MAX_IMAGE_SIZE_TO_STORE) { + pageProxy.cleanupAfterRender = true; + } + break; + default: + error('Got unknown object type ' + type); + } + }, this); + + messageHandler.on('DocProgress', function transportDocProgress(data) { + if (this.destroyed) { + return; // Ignore any pending requests if the worker was terminated. + } + + var loadingTask = this.loadingTask; + if (loadingTask.onProgress) { + loadingTask.onProgress({ + loaded: data.loaded, + total: data.total + }); + } + }, this); + + messageHandler.on('PageError', function transportError(data) { + if (this.destroyed) { + return; // Ignore any pending requests if the worker was terminated. + } + + var page = this.pageCache[data.pageNum - 1]; + var intentState = page.intentStates[data.intent]; + + if (intentState.displayReadyCapability) { + intentState.displayReadyCapability.reject(data.error); + } else { + error(data.error); + } + + if (intentState.operatorList) { + // Mark operator list as complete. + intentState.operatorList.lastChunk = true; + for (var i = 0; i < intentState.renderTasks.length; i++) { + intentState.renderTasks[i].operatorListChanged(); + } + } + }, this); + + messageHandler.on('UnsupportedFeature', + function transportUnsupportedFeature(data) { + if (this.destroyed) { + return; // Ignore any pending requests if the worker was terminated. + } + var featureId = data.featureId; + var loadingTask = this.loadingTask; + if (loadingTask.onUnsupportedFeature) { + loadingTask.onUnsupportedFeature(featureId); + } + PDFJS.UnsupportedManager.notify(featureId); + }, this); + + messageHandler.on('JpegDecode', function(data) { + if (this.destroyed) { + return Promise.reject('Worker was terminated'); + } + + var imageUrl = data[0]; + var components = data[1]; + if (components !== 3 && components !== 1) { + return Promise.reject( + new Error('Only 3 components or 1 component can be returned')); + } + + return new Promise(function (resolve, reject) { + var img = new Image(); + img.onload = function () { + var width = img.width; + var height = img.height; + var size = width * height; + var rgbaLength = size * 4; + var buf = new Uint8Array(size * components); + var tmpCanvas = createScratchCanvas(width, height); + var tmpCtx = tmpCanvas.getContext('2d'); + tmpCtx.drawImage(img, 0, 0); + var data = tmpCtx.getImageData(0, 0, width, height).data; + var i, j; + + if (components === 3) { + for (i = 0, j = 0; i < rgbaLength; i += 4, j += 3) { + buf[j] = data[i]; + buf[j + 1] = data[i + 1]; + buf[j + 2] = data[i + 2]; + } + } else if (components === 1) { + for (i = 0, j = 0; i < rgbaLength; i += 4, j++) { + buf[j] = data[i]; + } + } + resolve({ data: buf, width: width, height: height}); + }; + img.onerror = function () { + reject(new Error('JpegDecode failed to load image')); + }; + img.src = imageUrl; + }); + }, this); + }, + + getData: function WorkerTransport_getData() { + return this.messageHandler.sendWithPromise('GetData', null); + }, + + getPage: function WorkerTransport_getPage(pageNumber, capability) { + if (pageNumber <= 0 || pageNumber > this.numPages || + (pageNumber|0) !== pageNumber) { + return Promise.reject(new Error('Invalid page request')); + } + + var pageIndex = pageNumber - 1; + if (pageIndex in this.pagePromises) { + return this.pagePromises[pageIndex]; + } + var promise = this.messageHandler.sendWithPromise('GetPage', { + pageIndex: pageIndex + }).then(function (pageInfo) { + if (this.destroyed) { + throw new Error('Transport destroyed'); + } + var page = new PDFPageProxy(pageIndex, pageInfo, this); + this.pageCache[pageIndex] = page; + return page; + }.bind(this)); + this.pagePromises[pageIndex] = promise; + return promise; + }, + + getPageIndex: function WorkerTransport_getPageIndexByRef(ref) { + return this.messageHandler.sendWithPromise('GetPageIndex', { ref: ref }); + }, + + getAnnotations: function WorkerTransport_getAnnotations(pageIndex, intent) { + return this.messageHandler.sendWithPromise('GetAnnotations', { + pageIndex: pageIndex, + intent: intent, + }); + }, + + getDestinations: function WorkerTransport_getDestinations() { + return this.messageHandler.sendWithPromise('GetDestinations', null); + }, + + getDestination: function WorkerTransport_getDestination(id) { + return this.messageHandler.sendWithPromise('GetDestination', { id: id }); + }, + + getPageLabels: function WorkerTransport_getPageLabels() { + return this.messageHandler.sendWithPromise('GetPageLabels', null); + }, + + getAttachments: function WorkerTransport_getAttachments() { + return this.messageHandler.sendWithPromise('GetAttachments', null); + }, + + getJavaScript: function WorkerTransport_getJavaScript() { + return this.messageHandler.sendWithPromise('GetJavaScript', null); + }, + + getOutline: function WorkerTransport_getOutline() { + return this.messageHandler.sendWithPromise('GetOutline', null); + }, + + getMetadata: function WorkerTransport_getMetadata() { + return this.messageHandler.sendWithPromise('GetMetadata', null). + then(function transportMetadata(results) { + return { + info: results[0], + metadata: (results[1] ? new Metadata(results[1]) : null) + }; + }); + }, + + getStats: function WorkerTransport_getStats() { + return this.messageHandler.sendWithPromise('GetStats', null); + }, + + startCleanup: function WorkerTransport_startCleanup() { + this.messageHandler.sendWithPromise('Cleanup', null). + then(function endCleanup() { + for (var i = 0, ii = this.pageCache.length; i < ii; i++) { + var page = this.pageCache[i]; + if (page) { + page.cleanup(); + } + } + this.commonObjs.clear(); + this.fontLoader.clear(); + }.bind(this)); + } + }; + return WorkerTransport; + +})(); + +/** + * A PDF document and page is built of many objects. E.g. there are objects + * for fonts, images, rendering code and such. These objects might get processed + * inside of a worker. The `PDFObjects` implements some basic functions to + * manage these objects. + * @ignore + */ +var PDFObjects = (function PDFObjectsClosure() { + function PDFObjects() { + this.objs = Object.create(null); + } + + PDFObjects.prototype = { + /** + * Internal function. + * Ensures there is an object defined for `objId`. + */ + ensureObj: function PDFObjects_ensureObj(objId) { + if (this.objs[objId]) { + return this.objs[objId]; + } + + var obj = { + capability: createPromiseCapability(), + data: null, + resolved: false + }; + this.objs[objId] = obj; + + return obj; + }, + + /** + * If called *without* callback, this returns the data of `objId` but the + * object needs to be resolved. If it isn't, this function throws. + * + * If called *with* a callback, the callback is called with the data of the + * object once the object is resolved. That means, if you call this + * function and the object is already resolved, the callback gets called + * right away. + */ + get: function PDFObjects_get(objId, callback) { + // If there is a callback, then the get can be async and the object is + // not required to be resolved right now + if (callback) { + this.ensureObj(objId).capability.promise.then(callback); + return null; + } + + // If there isn't a callback, the user expects to get the resolved data + // directly. + var obj = this.objs[objId]; + + // If there isn't an object yet or the object isn't resolved, then the + // data isn't ready yet! + if (!obj || !obj.resolved) { + error('Requesting object that isn\'t resolved yet ' + objId); + } + + return obj.data; + }, + + /** + * Resolves the object `objId` with optional `data`. + */ + resolve: function PDFObjects_resolve(objId, data) { + var obj = this.ensureObj(objId); + + obj.resolved = true; + obj.data = data; + obj.capability.resolve(data); + }, + + isResolved: function PDFObjects_isResolved(objId) { + var objs = this.objs; + + if (!objs[objId]) { + return false; + } else { + return objs[objId].resolved; + } + }, + + hasData: function PDFObjects_hasData(objId) { + return this.isResolved(objId); + }, + + /** + * Returns the data of `objId` if object exists, null otherwise. + */ + getData: function PDFObjects_getData(objId) { + var objs = this.objs; + if (!objs[objId] || !objs[objId].resolved) { + return null; + } else { + return objs[objId].data; + } + }, + + clear: function PDFObjects_clear() { + this.objs = Object.create(null); + } + }; + return PDFObjects; +})(); + +/** + * Allows controlling of the rendering tasks. + * @class + * @alias RenderTask + */ +var RenderTask = (function RenderTaskClosure() { + function RenderTask(internalRenderTask) { + this._internalRenderTask = internalRenderTask; + + /** + * Callback for incremental rendering -- a function that will be called + * each time the rendering is paused. To continue rendering call the + * function that is the first argument to the callback. + * @type {function} + */ + this.onContinue = null; + } + + RenderTask.prototype = /** @lends RenderTask.prototype */ { + /** + * Promise for rendering task completion. + * @return {Promise} + */ + get promise() { + return this._internalRenderTask.capability.promise; + }, + + /** + * Cancels the rendering task. If the task is currently rendering it will + * not be cancelled until graphics pauses with a timeout. The promise that + * this object extends will resolved when cancelled. + */ + cancel: function RenderTask_cancel() { + this._internalRenderTask.cancel(); + }, + + /** + * Registers callbacks to indicate the rendering task completion. + * + * @param {function} onFulfilled The callback for the rendering completion. + * @param {function} onRejected The callback for the rendering failure. + * @return {Promise} A promise that is resolved after the onFulfilled or + * onRejected callback. + */ + then: function RenderTask_then(onFulfilled, onRejected) { + return this.promise.then.apply(this.promise, arguments); + } + }; + + return RenderTask; +})(); + +/** + * For internal use only. + * @ignore + */ +var InternalRenderTask = (function InternalRenderTaskClosure() { + + function InternalRenderTask(callback, params, objs, commonObjs, operatorList, + pageNumber) { + this.callback = callback; + this.params = params; + this.objs = objs; + this.commonObjs = commonObjs; + this.operatorListIdx = null; + this.operatorList = operatorList; + this.pageNumber = pageNumber; + this.running = false; + this.graphicsReadyCallback = null; + this.graphicsReady = false; + this.useRequestAnimationFrame = false; + this.cancelled = false; + this.capability = createPromiseCapability(); + this.task = new RenderTask(this); + // caching this-bound methods + this._continueBound = this._continue.bind(this); + this._scheduleNextBound = this._scheduleNext.bind(this); + this._nextBound = this._next.bind(this); + } + + InternalRenderTask.prototype = { + + initalizeGraphics: + function InternalRenderTask_initalizeGraphics(transparency) { + + if (this.cancelled) { + return; + } + if (PDFJS.pdfBug && 'StepperManager' in globalScope && + globalScope.StepperManager.enabled) { + this.stepper = globalScope.StepperManager.create(this.pageNumber - 1); + this.stepper.init(this.operatorList); + this.stepper.nextBreakPoint = this.stepper.getNextBreakPoint(); + } + + var params = this.params; + this.gfx = new CanvasGraphics(params.canvasContext, this.commonObjs, + this.objs, params.imageLayer); + + this.gfx.beginDrawing(params.transform, params.viewport, transparency); + this.operatorListIdx = 0; + this.graphicsReady = true; + if (this.graphicsReadyCallback) { + this.graphicsReadyCallback(); + } + }, + + cancel: function InternalRenderTask_cancel() { + this.running = false; + this.cancelled = true; + this.callback('cancelled'); + }, + + operatorListChanged: function InternalRenderTask_operatorListChanged() { + if (!this.graphicsReady) { + if (!this.graphicsReadyCallback) { + this.graphicsReadyCallback = this._continueBound; + } + return; + } + + if (this.stepper) { + this.stepper.updateOperatorList(this.operatorList); + } + + if (this.running) { + return; + } + this._continue(); + }, + + _continue: function InternalRenderTask__continue() { + this.running = true; + if (this.cancelled) { + return; + } + if (this.task.onContinue) { + this.task.onContinue.call(this.task, this._scheduleNextBound); + } else { + this._scheduleNext(); + } + }, + + _scheduleNext: function InternalRenderTask__scheduleNext() { + if (this.useRequestAnimationFrame) { + window.requestAnimationFrame(this._nextBound); + } else { + Promise.resolve(undefined).then(this._nextBound); + } + }, + + _next: function InternalRenderTask__next() { + if (this.cancelled) { + return; + } + this.operatorListIdx = this.gfx.executeOperatorList(this.operatorList, + this.operatorListIdx, + this._continueBound, + this.stepper); + if (this.operatorListIdx === this.operatorList.argsArray.length) { + this.running = false; + if (this.operatorList.lastChunk) { + this.gfx.endDrawing(); + this.callback(); + } + } + } + + }; + + return InternalRenderTask; +})(); + +/** + * (Deprecated) Global observer of unsupported feature usages. Use + * onUnsupportedFeature callback of the {PDFDocumentLoadingTask} instance. + */ +PDFJS.UnsupportedManager = (function UnsupportedManagerClosure() { + var listeners = []; + return { + listen: function (cb) { + deprecated('Global UnsupportedManager.listen is used: ' + + ' use PDFDocumentLoadingTask.onUnsupportedFeature instead'); + listeners.push(cb); + }, + notify: function (featureId) { + for (var i = 0, ii = listeners.length; i < ii; i++) { + listeners[i](featureId); + } + } + }; +})(); + +exports.getDocument = PDFJS.getDocument; +exports.PDFDataRangeTransport = PDFDataRangeTransport; +exports.PDFDocumentProxy = PDFDocumentProxy; +exports.PDFPageProxy = PDFPageProxy; +})); + + + }).call(pdfjsLibs); + + exports.PDFJS = pdfjsLibs.pdfjsDisplayGlobal.PDFJS; + exports.getDocument = pdfjsLibs.pdfjsDisplayAPI.getDocument; + exports.PDFDataRangeTransport = + pdfjsLibs.pdfjsDisplayAPI.PDFDataRangeTransport; + exports.renderTextLayer = pdfjsLibs.pdfjsDisplayTextLayer.renderTextLayer; + exports.AnnotationLayer = + pdfjsLibs.pdfjsDisplayAnnotationLayer.AnnotationLayer; + exports.CustomStyle = pdfjsLibs.pdfjsDisplayDOMUtils.CustomStyle; + exports.PasswordResponses = pdfjsLibs.pdfjsSharedUtil.PasswordResponses; + exports.InvalidPDFException = pdfjsLibs.pdfjsSharedUtil.InvalidPDFException; + exports.MissingPDFException = pdfjsLibs.pdfjsSharedUtil.MissingPDFException; + exports.UnexpectedResponseException = + pdfjsLibs.pdfjsSharedUtil.UnexpectedResponseException; +})); + + diff --git a/static/pdf.js/pdf.mjs b/static/pdf.js/pdf.mjs deleted file mode 100644 index e5f01085..00000000 --- a/static/pdf.js/pdf.mjs +++ /dev/null @@ -1,24454 +0,0 @@ -/** - * @licstart The following is the entire license notice for the - * JavaScript code in this page - * - * Copyright 2023 Mozilla Foundation - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * @licend The above is the entire license notice for the - * JavaScript code in this page - */ - -/******/ var __webpack_modules__ = ({ - -/***/ 9306: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isCallable = __webpack_require__(4901); -var tryToString = __webpack_require__(6823); - -var $TypeError = TypeError; - -// `Assert: IsCallable(argument) is true` -module.exports = function (argument) { - if (isCallable(argument)) return argument; - throw new $TypeError(tryToString(argument) + ' is not a function'); -}; - - -/***/ }), - -/***/ 3506: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isPossiblePrototype = __webpack_require__(3925); - -var $String = String; -var $TypeError = TypeError; - -module.exports = function (argument) { - if (isPossiblePrototype(argument)) return argument; - throw new $TypeError("Can't set " + $String(argument) + ' as a prototype'); -}; - - -/***/ }), - -/***/ 7080: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var has = (__webpack_require__(4402).has); - -// Perform ? RequireInternalSlot(M, [[SetData]]) -module.exports = function (it) { - has(it); - return it; -}; - - -/***/ }), - -/***/ 679: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isPrototypeOf = __webpack_require__(1625); - -var $TypeError = TypeError; - -module.exports = function (it, Prototype) { - if (isPrototypeOf(Prototype, it)) return it; - throw new $TypeError('Incorrect invocation'); -}; - - -/***/ }), - -/***/ 8551: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isObject = __webpack_require__(34); - -var $String = String; -var $TypeError = TypeError; - -// `Assert: Type(argument) is Object` -module.exports = function (argument) { - if (isObject(argument)) return argument; - throw new $TypeError($String(argument) + ' is not an object'); -}; - - -/***/ }), - -/***/ 7811: -/***/ ((module) => { - - -// eslint-disable-next-line es/no-typed-arrays -- safe -module.exports = typeof ArrayBuffer != 'undefined' && typeof DataView != 'undefined'; - - -/***/ }), - -/***/ 7394: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThisAccessor = __webpack_require__(6706); -var classof = __webpack_require__(4576); - -var $TypeError = TypeError; - -// Includes -// - Perform ? RequireInternalSlot(O, [[ArrayBufferData]]). -// - If IsSharedArrayBuffer(O) is true, throw a TypeError exception. -module.exports = uncurryThisAccessor(ArrayBuffer.prototype, 'byteLength', 'get') || function (O) { - if (classof(O) !== 'ArrayBuffer') throw new $TypeError('ArrayBuffer expected'); - return O.byteLength; -}; - - -/***/ }), - -/***/ 3238: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var arrayBufferByteLength = __webpack_require__(7394); - -var slice = uncurryThis(ArrayBuffer.prototype.slice); - -module.exports = function (O) { - if (arrayBufferByteLength(O) !== 0) return false; - try { - slice(O, 0, 0); - return false; - } catch (error) { - return true; - } -}; - - -/***/ }), - -/***/ 5636: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var uncurryThis = __webpack_require__(9504); -var uncurryThisAccessor = __webpack_require__(6706); -var toIndex = __webpack_require__(7696); -var isDetached = __webpack_require__(3238); -var arrayBufferByteLength = __webpack_require__(7394); -var detachTransferable = __webpack_require__(4483); -var PROPER_STRUCTURED_CLONE_TRANSFER = __webpack_require__(1548); - -var structuredClone = global.structuredClone; -var ArrayBuffer = global.ArrayBuffer; -var DataView = global.DataView; -var TypeError = global.TypeError; -var min = Math.min; -var ArrayBufferPrototype = ArrayBuffer.prototype; -var DataViewPrototype = DataView.prototype; -var slice = uncurryThis(ArrayBufferPrototype.slice); -var isResizable = uncurryThisAccessor(ArrayBufferPrototype, 'resizable', 'get'); -var maxByteLength = uncurryThisAccessor(ArrayBufferPrototype, 'maxByteLength', 'get'); -var getInt8 = uncurryThis(DataViewPrototype.getInt8); -var setInt8 = uncurryThis(DataViewPrototype.setInt8); - -module.exports = (PROPER_STRUCTURED_CLONE_TRANSFER || detachTransferable) && function (arrayBuffer, newLength, preserveResizability) { - var byteLength = arrayBufferByteLength(arrayBuffer); - var newByteLength = newLength === undefined ? byteLength : toIndex(newLength); - var fixedLength = !isResizable || !isResizable(arrayBuffer); - var newBuffer; - if (isDetached(arrayBuffer)) throw new TypeError('ArrayBuffer is detached'); - if (PROPER_STRUCTURED_CLONE_TRANSFER) { - arrayBuffer = structuredClone(arrayBuffer, { transfer: [arrayBuffer] }); - if (byteLength === newByteLength && (preserveResizability || fixedLength)) return arrayBuffer; - } - if (byteLength >= newByteLength && (!preserveResizability || fixedLength)) { - newBuffer = slice(arrayBuffer, 0, newByteLength); - } else { - var options = preserveResizability && !fixedLength && maxByteLength ? { maxByteLength: maxByteLength(arrayBuffer) } : undefined; - newBuffer = new ArrayBuffer(newByteLength, options); - var a = new DataView(arrayBuffer); - var b = new DataView(newBuffer); - var copyLength = min(newByteLength, byteLength); - for (var i = 0; i < copyLength; i++) setInt8(b, i, getInt8(a, i)); - } - if (!PROPER_STRUCTURED_CLONE_TRANSFER) detachTransferable(arrayBuffer); - return newBuffer; -}; - - -/***/ }), - -/***/ 4644: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var NATIVE_ARRAY_BUFFER = __webpack_require__(7811); -var DESCRIPTORS = __webpack_require__(3724); -var global = __webpack_require__(4475); -var isCallable = __webpack_require__(4901); -var isObject = __webpack_require__(34); -var hasOwn = __webpack_require__(9297); -var classof = __webpack_require__(6955); -var tryToString = __webpack_require__(6823); -var createNonEnumerableProperty = __webpack_require__(6699); -var defineBuiltIn = __webpack_require__(6840); -var defineBuiltInAccessor = __webpack_require__(2106); -var isPrototypeOf = __webpack_require__(1625); -var getPrototypeOf = __webpack_require__(2787); -var setPrototypeOf = __webpack_require__(2967); -var wellKnownSymbol = __webpack_require__(8227); -var uid = __webpack_require__(3392); -var InternalStateModule = __webpack_require__(1181); - -var enforceInternalState = InternalStateModule.enforce; -var getInternalState = InternalStateModule.get; -var Int8Array = global.Int8Array; -var Int8ArrayPrototype = Int8Array && Int8Array.prototype; -var Uint8ClampedArray = global.Uint8ClampedArray; -var Uint8ClampedArrayPrototype = Uint8ClampedArray && Uint8ClampedArray.prototype; -var TypedArray = Int8Array && getPrototypeOf(Int8Array); -var TypedArrayPrototype = Int8ArrayPrototype && getPrototypeOf(Int8ArrayPrototype); -var ObjectPrototype = Object.prototype; -var TypeError = global.TypeError; - -var TO_STRING_TAG = wellKnownSymbol('toStringTag'); -var TYPED_ARRAY_TAG = uid('TYPED_ARRAY_TAG'); -var TYPED_ARRAY_CONSTRUCTOR = 'TypedArrayConstructor'; -// Fixing native typed arrays in Opera Presto crashes the browser, see #595 -var NATIVE_ARRAY_BUFFER_VIEWS = NATIVE_ARRAY_BUFFER && !!setPrototypeOf && classof(global.opera) !== 'Opera'; -var TYPED_ARRAY_TAG_REQUIRED = false; -var NAME, Constructor, Prototype; - -var TypedArrayConstructorsList = { - Int8Array: 1, - Uint8Array: 1, - Uint8ClampedArray: 1, - Int16Array: 2, - Uint16Array: 2, - Int32Array: 4, - Uint32Array: 4, - Float32Array: 4, - Float64Array: 8 -}; - -var BigIntArrayConstructorsList = { - BigInt64Array: 8, - BigUint64Array: 8 -}; - -var isView = function isView(it) { - if (!isObject(it)) return false; - var klass = classof(it); - return klass === 'DataView' - || hasOwn(TypedArrayConstructorsList, klass) - || hasOwn(BigIntArrayConstructorsList, klass); -}; - -var getTypedArrayConstructor = function (it) { - var proto = getPrototypeOf(it); - if (!isObject(proto)) return; - var state = getInternalState(proto); - return (state && hasOwn(state, TYPED_ARRAY_CONSTRUCTOR)) ? state[TYPED_ARRAY_CONSTRUCTOR] : getTypedArrayConstructor(proto); -}; - -var isTypedArray = function (it) { - if (!isObject(it)) return false; - var klass = classof(it); - return hasOwn(TypedArrayConstructorsList, klass) - || hasOwn(BigIntArrayConstructorsList, klass); -}; - -var aTypedArray = function (it) { - if (isTypedArray(it)) return it; - throw new TypeError('Target is not a typed array'); -}; - -var aTypedArrayConstructor = function (C) { - if (isCallable(C) && (!setPrototypeOf || isPrototypeOf(TypedArray, C))) return C; - throw new TypeError(tryToString(C) + ' is not a typed array constructor'); -}; - -var exportTypedArrayMethod = function (KEY, property, forced, options) { - if (!DESCRIPTORS) return; - if (forced) for (var ARRAY in TypedArrayConstructorsList) { - var TypedArrayConstructor = global[ARRAY]; - if (TypedArrayConstructor && hasOwn(TypedArrayConstructor.prototype, KEY)) try { - delete TypedArrayConstructor.prototype[KEY]; - } catch (error) { - // old WebKit bug - some methods are non-configurable - try { - TypedArrayConstructor.prototype[KEY] = property; - } catch (error2) { /* empty */ } - } - } - if (!TypedArrayPrototype[KEY] || forced) { - defineBuiltIn(TypedArrayPrototype, KEY, forced ? property - : NATIVE_ARRAY_BUFFER_VIEWS && Int8ArrayPrototype[KEY] || property, options); - } -}; - -var exportTypedArrayStaticMethod = function (KEY, property, forced) { - var ARRAY, TypedArrayConstructor; - if (!DESCRIPTORS) return; - if (setPrototypeOf) { - if (forced) for (ARRAY in TypedArrayConstructorsList) { - TypedArrayConstructor = global[ARRAY]; - if (TypedArrayConstructor && hasOwn(TypedArrayConstructor, KEY)) try { - delete TypedArrayConstructor[KEY]; - } catch (error) { /* empty */ } - } - if (!TypedArray[KEY] || forced) { - // V8 ~ Chrome 49-50 `%TypedArray%` methods are non-writable non-configurable - try { - return defineBuiltIn(TypedArray, KEY, forced ? property : NATIVE_ARRAY_BUFFER_VIEWS && TypedArray[KEY] || property); - } catch (error) { /* empty */ } - } else return; - } - for (ARRAY in TypedArrayConstructorsList) { - TypedArrayConstructor = global[ARRAY]; - if (TypedArrayConstructor && (!TypedArrayConstructor[KEY] || forced)) { - defineBuiltIn(TypedArrayConstructor, KEY, property); - } - } -}; - -for (NAME in TypedArrayConstructorsList) { - Constructor = global[NAME]; - Prototype = Constructor && Constructor.prototype; - if (Prototype) enforceInternalState(Prototype)[TYPED_ARRAY_CONSTRUCTOR] = Constructor; - else NATIVE_ARRAY_BUFFER_VIEWS = false; -} - -for (NAME in BigIntArrayConstructorsList) { - Constructor = global[NAME]; - Prototype = Constructor && Constructor.prototype; - if (Prototype) enforceInternalState(Prototype)[TYPED_ARRAY_CONSTRUCTOR] = Constructor; -} - -// WebKit bug - typed arrays constructors prototype is Object.prototype -if (!NATIVE_ARRAY_BUFFER_VIEWS || !isCallable(TypedArray) || TypedArray === Function.prototype) { - // eslint-disable-next-line no-shadow -- safe - TypedArray = function TypedArray() { - throw new TypeError('Incorrect invocation'); - }; - if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) { - if (global[NAME]) setPrototypeOf(global[NAME], TypedArray); - } -} - -if (!NATIVE_ARRAY_BUFFER_VIEWS || !TypedArrayPrototype || TypedArrayPrototype === ObjectPrototype) { - TypedArrayPrototype = TypedArray.prototype; - if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) { - if (global[NAME]) setPrototypeOf(global[NAME].prototype, TypedArrayPrototype); - } -} - -// WebKit bug - one more object in Uint8ClampedArray prototype chain -if (NATIVE_ARRAY_BUFFER_VIEWS && getPrototypeOf(Uint8ClampedArrayPrototype) !== TypedArrayPrototype) { - setPrototypeOf(Uint8ClampedArrayPrototype, TypedArrayPrototype); -} - -if (DESCRIPTORS && !hasOwn(TypedArrayPrototype, TO_STRING_TAG)) { - TYPED_ARRAY_TAG_REQUIRED = true; - defineBuiltInAccessor(TypedArrayPrototype, TO_STRING_TAG, { - configurable: true, - get: function () { - return isObject(this) ? this[TYPED_ARRAY_TAG] : undefined; - } - }); - for (NAME in TypedArrayConstructorsList) if (global[NAME]) { - createNonEnumerableProperty(global[NAME], TYPED_ARRAY_TAG, NAME); - } -} - -module.exports = { - NATIVE_ARRAY_BUFFER_VIEWS: NATIVE_ARRAY_BUFFER_VIEWS, - TYPED_ARRAY_TAG: TYPED_ARRAY_TAG_REQUIRED && TYPED_ARRAY_TAG, - aTypedArray: aTypedArray, - aTypedArrayConstructor: aTypedArrayConstructor, - exportTypedArrayMethod: exportTypedArrayMethod, - exportTypedArrayStaticMethod: exportTypedArrayStaticMethod, - getTypedArrayConstructor: getTypedArrayConstructor, - isView: isView, - isTypedArray: isTypedArray, - TypedArray: TypedArray, - TypedArrayPrototype: TypedArrayPrototype -}; - - -/***/ }), - -/***/ 5370: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var lengthOfArrayLike = __webpack_require__(6198); - -module.exports = function (Constructor, list, $length) { - var index = 0; - var length = arguments.length > 2 ? $length : lengthOfArrayLike(list); - var result = new Constructor(length); - while (length > index) result[index] = list[index++]; - return result; -}; - - -/***/ }), - -/***/ 9617: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toIndexedObject = __webpack_require__(5397); -var toAbsoluteIndex = __webpack_require__(5610); -var lengthOfArrayLike = __webpack_require__(6198); - -// `Array.prototype.{ indexOf, includes }` methods implementation -var createMethod = function (IS_INCLUDES) { - return function ($this, el, fromIndex) { - var O = toIndexedObject($this); - var length = lengthOfArrayLike(O); - if (length === 0) return !IS_INCLUDES && -1; - var index = toAbsoluteIndex(fromIndex, length); - var value; - // Array#includes uses SameValueZero equality algorithm - // eslint-disable-next-line no-self-compare -- NaN check - if (IS_INCLUDES && el !== el) while (length > index) { - value = O[index++]; - // eslint-disable-next-line no-self-compare -- NaN check - if (value !== value) return true; - // Array#indexOf ignores holes, Array#includes - not - } else for (;length > index; index++) { - if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0; - } return !IS_INCLUDES && -1; - }; -}; - -module.exports = { - // `Array.prototype.includes` method - // https://tc39.es/ecma262/#sec-array.prototype.includes - includes: createMethod(true), - // `Array.prototype.indexOf` method - // https://tc39.es/ecma262/#sec-array.prototype.indexof - indexOf: createMethod(false) -}; - - -/***/ }), - -/***/ 4527: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var isArray = __webpack_require__(4376); - -var $TypeError = TypeError; -// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe -var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; - -// Safari < 13 does not throw an error in this case -var SILENT_ON_NON_WRITABLE_LENGTH_SET = DESCRIPTORS && !function () { - // makes no sense without proper strict mode support - if (this !== undefined) return true; - try { - // eslint-disable-next-line es/no-object-defineproperty -- safe - Object.defineProperty([], 'length', { writable: false }).length = 1; - } catch (error) { - return error instanceof TypeError; - } -}(); - -module.exports = SILENT_ON_NON_WRITABLE_LENGTH_SET ? function (O, length) { - if (isArray(O) && !getOwnPropertyDescriptor(O, 'length').writable) { - throw new $TypeError('Cannot set read only .length'); - } return O.length = length; -} : function (O, length) { - return O.length = length; -}; - - -/***/ }), - -/***/ 7628: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var lengthOfArrayLike = __webpack_require__(6198); - -// https://tc39.es/proposal-change-array-by-copy/#sec-array.prototype.toReversed -// https://tc39.es/proposal-change-array-by-copy/#sec-%typedarray%.prototype.toReversed -module.exports = function (O, C) { - var len = lengthOfArrayLike(O); - var A = new C(len); - var k = 0; - for (; k < len; k++) A[k] = O[len - k - 1]; - return A; -}; - - -/***/ }), - -/***/ 9928: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var lengthOfArrayLike = __webpack_require__(6198); -var toIntegerOrInfinity = __webpack_require__(1291); - -var $RangeError = RangeError; - -// https://tc39.es/proposal-change-array-by-copy/#sec-array.prototype.with -// https://tc39.es/proposal-change-array-by-copy/#sec-%typedarray%.prototype.with -module.exports = function (O, C, index, value) { - var len = lengthOfArrayLike(O); - var relativeIndex = toIntegerOrInfinity(index); - var actualIndex = relativeIndex < 0 ? len + relativeIndex : relativeIndex; - if (actualIndex >= len || actualIndex < 0) throw new $RangeError('Incorrect index'); - var A = new C(len); - var k = 0; - for (; k < len; k++) A[k] = k === actualIndex ? value : O[k]; - return A; -}; - - -/***/ }), - -/***/ 6319: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var anObject = __webpack_require__(8551); -var iteratorClose = __webpack_require__(9539); - -// call something on iterator step with safe closing on error -module.exports = function (iterator, fn, value, ENTRIES) { - try { - return ENTRIES ? fn(anObject(value)[0], value[1]) : fn(value); - } catch (error) { - iteratorClose(iterator, 'throw', error); - } -}; - - -/***/ }), - -/***/ 4576: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); - -var toString = uncurryThis({}.toString); -var stringSlice = uncurryThis(''.slice); - -module.exports = function (it) { - return stringSlice(toString(it), 8, -1); -}; - - -/***/ }), - -/***/ 6955: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var TO_STRING_TAG_SUPPORT = __webpack_require__(2140); -var isCallable = __webpack_require__(4901); -var classofRaw = __webpack_require__(4576); -var wellKnownSymbol = __webpack_require__(8227); - -var TO_STRING_TAG = wellKnownSymbol('toStringTag'); -var $Object = Object; - -// ES3 wrong here -var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments'; - -// fallback for IE11 Script Access Denied error -var tryGet = function (it, key) { - try { - return it[key]; - } catch (error) { /* empty */ } -}; - -// getting tag from ES6+ `Object.prototype.toString` -module.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) { - var O, tag, result; - return it === undefined ? 'Undefined' : it === null ? 'Null' - // @@toStringTag case - : typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag - // builtinTag case - : CORRECT_ARGUMENTS ? classofRaw(O) - // ES3 arguments fallback - : (result = classofRaw(O)) === 'Object' && isCallable(O.callee) ? 'Arguments' : result; -}; - - -/***/ }), - -/***/ 7740: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var hasOwn = __webpack_require__(9297); -var ownKeys = __webpack_require__(5031); -var getOwnPropertyDescriptorModule = __webpack_require__(7347); -var definePropertyModule = __webpack_require__(4913); - -module.exports = function (target, source, exceptions) { - var keys = ownKeys(source); - var defineProperty = definePropertyModule.f; - var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f; - for (var i = 0; i < keys.length; i++) { - var key = keys[i]; - if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) { - defineProperty(target, key, getOwnPropertyDescriptor(source, key)); - } - } -}; - - -/***/ }), - -/***/ 2211: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var fails = __webpack_require__(9039); - -module.exports = !fails(function () { - function F() { /* empty */ } - F.prototype.constructor = null; - // eslint-disable-next-line es/no-object-getprototypeof -- required for testing - return Object.getPrototypeOf(new F()) !== F.prototype; -}); - - -/***/ }), - -/***/ 2529: -/***/ ((module) => { - - -// `CreateIterResultObject` abstract operation -// https://tc39.es/ecma262/#sec-createiterresultobject -module.exports = function (value, done) { - return { value: value, done: done }; -}; - - -/***/ }), - -/***/ 6699: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var definePropertyModule = __webpack_require__(4913); -var createPropertyDescriptor = __webpack_require__(6980); - -module.exports = DESCRIPTORS ? function (object, key, value) { - return definePropertyModule.f(object, key, createPropertyDescriptor(1, value)); -} : function (object, key, value) { - object[key] = value; - return object; -}; - - -/***/ }), - -/***/ 6980: -/***/ ((module) => { - - -module.exports = function (bitmap, value) { - return { - enumerable: !(bitmap & 1), - configurable: !(bitmap & 2), - writable: !(bitmap & 4), - value: value - }; -}; - - -/***/ }), - -/***/ 4659: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var definePropertyModule = __webpack_require__(4913); -var createPropertyDescriptor = __webpack_require__(6980); - -module.exports = function (object, key, value) { - if (DESCRIPTORS) definePropertyModule.f(object, key, createPropertyDescriptor(0, value)); - else object[key] = value; -}; - - -/***/ }), - -/***/ 2106: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var makeBuiltIn = __webpack_require__(283); -var defineProperty = __webpack_require__(4913); - -module.exports = function (target, name, descriptor) { - if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true }); - if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true }); - return defineProperty.f(target, name, descriptor); -}; - - -/***/ }), - -/***/ 6840: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isCallable = __webpack_require__(4901); -var definePropertyModule = __webpack_require__(4913); -var makeBuiltIn = __webpack_require__(283); -var defineGlobalProperty = __webpack_require__(9433); - -module.exports = function (O, key, value, options) { - if (!options) options = {}; - var simple = options.enumerable; - var name = options.name !== undefined ? options.name : key; - if (isCallable(value)) makeBuiltIn(value, name, options); - if (options.global) { - if (simple) O[key] = value; - else defineGlobalProperty(key, value); - } else { - try { - if (!options.unsafe) delete O[key]; - else if (O[key]) simple = true; - } catch (error) { /* empty */ } - if (simple) O[key] = value; - else definePropertyModule.f(O, key, { - value: value, - enumerable: false, - configurable: !options.nonConfigurable, - writable: !options.nonWritable - }); - } return O; -}; - - -/***/ }), - -/***/ 6279: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var defineBuiltIn = __webpack_require__(6840); - -module.exports = function (target, src, options) { - for (var key in src) defineBuiltIn(target, key, src[key], options); - return target; -}; - - -/***/ }), - -/***/ 9433: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); - -// eslint-disable-next-line es/no-object-defineproperty -- safe -var defineProperty = Object.defineProperty; - -module.exports = function (key, value) { - try { - defineProperty(global, key, { value: value, configurable: true, writable: true }); - } catch (error) { - global[key] = value; - } return value; -}; - - -/***/ }), - -/***/ 3724: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var fails = __webpack_require__(9039); - -// Detect IE8's incomplete defineProperty implementation -module.exports = !fails(function () { - // eslint-disable-next-line es/no-object-defineproperty -- required for testing - return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7; -}); - - -/***/ }), - -/***/ 4483: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var tryNodeRequire = __webpack_require__(9714); -var PROPER_STRUCTURED_CLONE_TRANSFER = __webpack_require__(1548); - -var structuredClone = global.structuredClone; -var $ArrayBuffer = global.ArrayBuffer; -var $MessageChannel = global.MessageChannel; -var detach = false; -var WorkerThreads, channel, buffer, $detach; - -if (PROPER_STRUCTURED_CLONE_TRANSFER) { - detach = function (transferable) { - structuredClone(transferable, { transfer: [transferable] }); - }; -} else if ($ArrayBuffer) try { - if (!$MessageChannel) { - WorkerThreads = tryNodeRequire('worker_threads'); - if (WorkerThreads) $MessageChannel = WorkerThreads.MessageChannel; - } - - if ($MessageChannel) { - channel = new $MessageChannel(); - buffer = new $ArrayBuffer(2); - - $detach = function (transferable) { - channel.port1.postMessage(null, [transferable]); - }; - - if (buffer.byteLength === 2) { - $detach(buffer); - if (buffer.byteLength === 0) detach = $detach; - } - } -} catch (error) { /* empty */ } - -module.exports = detach; - - -/***/ }), - -/***/ 4055: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var isObject = __webpack_require__(34); - -var document = global.document; -// typeof document.createElement is 'object' in old IE -var EXISTS = isObject(document) && isObject(document.createElement); - -module.exports = function (it) { - return EXISTS ? document.createElement(it) : {}; -}; - - -/***/ }), - -/***/ 6837: -/***/ ((module) => { - - -var $TypeError = TypeError; -var MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991 - -module.exports = function (it) { - if (it > MAX_SAFE_INTEGER) throw $TypeError('Maximum allowed index exceeded'); - return it; -}; - - -/***/ }), - -/***/ 5002: -/***/ ((module) => { - - -module.exports = { - IndexSizeError: { s: 'INDEX_SIZE_ERR', c: 1, m: 1 }, - DOMStringSizeError: { s: 'DOMSTRING_SIZE_ERR', c: 2, m: 0 }, - HierarchyRequestError: { s: 'HIERARCHY_REQUEST_ERR', c: 3, m: 1 }, - WrongDocumentError: { s: 'WRONG_DOCUMENT_ERR', c: 4, m: 1 }, - InvalidCharacterError: { s: 'INVALID_CHARACTER_ERR', c: 5, m: 1 }, - NoDataAllowedError: { s: 'NO_DATA_ALLOWED_ERR', c: 6, m: 0 }, - NoModificationAllowedError: { s: 'NO_MODIFICATION_ALLOWED_ERR', c: 7, m: 1 }, - NotFoundError: { s: 'NOT_FOUND_ERR', c: 8, m: 1 }, - NotSupportedError: { s: 'NOT_SUPPORTED_ERR', c: 9, m: 1 }, - InUseAttributeError: { s: 'INUSE_ATTRIBUTE_ERR', c: 10, m: 1 }, - InvalidStateError: { s: 'INVALID_STATE_ERR', c: 11, m: 1 }, - SyntaxError: { s: 'SYNTAX_ERR', c: 12, m: 1 }, - InvalidModificationError: { s: 'INVALID_MODIFICATION_ERR', c: 13, m: 1 }, - NamespaceError: { s: 'NAMESPACE_ERR', c: 14, m: 1 }, - InvalidAccessError: { s: 'INVALID_ACCESS_ERR', c: 15, m: 1 }, - ValidationError: { s: 'VALIDATION_ERR', c: 16, m: 0 }, - TypeMismatchError: { s: 'TYPE_MISMATCH_ERR', c: 17, m: 1 }, - SecurityError: { s: 'SECURITY_ERR', c: 18, m: 1 }, - NetworkError: { s: 'NETWORK_ERR', c: 19, m: 1 }, - AbortError: { s: 'ABORT_ERR', c: 20, m: 1 }, - URLMismatchError: { s: 'URL_MISMATCH_ERR', c: 21, m: 1 }, - QuotaExceededError: { s: 'QUOTA_EXCEEDED_ERR', c: 22, m: 1 }, - TimeoutError: { s: 'TIMEOUT_ERR', c: 23, m: 1 }, - InvalidNodeTypeError: { s: 'INVALID_NODE_TYPE_ERR', c: 24, m: 1 }, - DataCloneError: { s: 'DATA_CLONE_ERR', c: 25, m: 1 } -}; - - -/***/ }), - -/***/ 7290: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var IS_DENO = __webpack_require__(516); -var IS_NODE = __webpack_require__(9088); - -module.exports = !IS_DENO && !IS_NODE - && typeof window == 'object' - && typeof document == 'object'; - - -/***/ }), - -/***/ 516: -/***/ ((module) => { - - -/* global Deno -- Deno case */ -module.exports = typeof Deno == 'object' && Deno && typeof Deno.version == 'object'; - - -/***/ }), - -/***/ 9088: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var classof = __webpack_require__(4576); - -module.exports = classof(global.process) === 'process'; - - -/***/ }), - -/***/ 9392: -/***/ ((module) => { - - -module.exports = typeof navigator != 'undefined' && String(navigator.userAgent) || ''; - - -/***/ }), - -/***/ 7388: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var userAgent = __webpack_require__(9392); - -var process = global.process; -var Deno = global.Deno; -var versions = process && process.versions || Deno && Deno.version; -var v8 = versions && versions.v8; -var match, version; - -if (v8) { - match = v8.split('.'); - // in old Chrome, versions of V8 isn't V8 = Chrome / 10 - // but their correct versions are not interesting for us - version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]); -} - -// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0` -// so check `userAgent` even if `.v8` exists, but 0 -if (!version && userAgent) { - match = userAgent.match(/Edge\/(\d+)/); - if (!match || match[1] >= 74) { - match = userAgent.match(/Chrome\/(\d+)/); - if (match) version = +match[1]; - } -} - -module.exports = version; - - -/***/ }), - -/***/ 8727: -/***/ ((module) => { - - -// IE8- don't enum bug keys -module.exports = [ - 'constructor', - 'hasOwnProperty', - 'isPrototypeOf', - 'propertyIsEnumerable', - 'toLocaleString', - 'toString', - 'valueOf' -]; - - -/***/ }), - -/***/ 6193: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); - -var $Error = Error; -var replace = uncurryThis(''.replace); - -var TEST = (function (arg) { return String(new $Error(arg).stack); })('zxcasd'); -// eslint-disable-next-line redos/no-vulnerable -- safe -var V8_OR_CHAKRA_STACK_ENTRY = /\n\s*at [^:]*:[^\n]*/; -var IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST); - -module.exports = function (stack, dropEntries) { - if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string' && !$Error.prepareStackTrace) { - while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, ''); - } return stack; -}; - - -/***/ }), - -/***/ 6518: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var getOwnPropertyDescriptor = (__webpack_require__(7347).f); -var createNonEnumerableProperty = __webpack_require__(6699); -var defineBuiltIn = __webpack_require__(6840); -var defineGlobalProperty = __webpack_require__(9433); -var copyConstructorProperties = __webpack_require__(7740); -var isForced = __webpack_require__(2796); - -/* - options.target - name of the target object - options.global - target is the global object - options.stat - export as static methods of target - options.proto - export as prototype methods of target - options.real - real prototype method for the `pure` version - options.forced - export even if the native feature is available - options.bind - bind methods to the target, required for the `pure` version - options.wrap - wrap constructors to preventing global pollution, required for the `pure` version - options.unsafe - use the simple assignment of property instead of delete + defineProperty - options.sham - add a flag to not completely full polyfills - options.enumerable - export as enumerable property - options.dontCallGetSet - prevent calling a getter on target - options.name - the .name of the function if it does not match the key -*/ -module.exports = function (options, source) { - var TARGET = options.target; - var GLOBAL = options.global; - var STATIC = options.stat; - var FORCED, target, key, targetProperty, sourceProperty, descriptor; - if (GLOBAL) { - target = global; - } else if (STATIC) { - target = global[TARGET] || defineGlobalProperty(TARGET, {}); - } else { - target = global[TARGET] && global[TARGET].prototype; - } - if (target) for (key in source) { - sourceProperty = source[key]; - if (options.dontCallGetSet) { - descriptor = getOwnPropertyDescriptor(target, key); - targetProperty = descriptor && descriptor.value; - } else targetProperty = target[key]; - FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced); - // contained in target - if (!FORCED && targetProperty !== undefined) { - if (typeof sourceProperty == typeof targetProperty) continue; - copyConstructorProperties(sourceProperty, targetProperty); - } - // add a flag to not completely full polyfills - if (options.sham || (targetProperty && targetProperty.sham)) { - createNonEnumerableProperty(sourceProperty, 'sham', true); - } - defineBuiltIn(target, key, sourceProperty, options); - } -}; - - -/***/ }), - -/***/ 9039: -/***/ ((module) => { - - -module.exports = function (exec) { - try { - return !!exec(); - } catch (error) { - return true; - } -}; - - -/***/ }), - -/***/ 6080: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(7476); -var aCallable = __webpack_require__(9306); -var NATIVE_BIND = __webpack_require__(616); - -var bind = uncurryThis(uncurryThis.bind); - -// optional / simple context binding -module.exports = function (fn, that) { - aCallable(fn); - return that === undefined ? fn : NATIVE_BIND ? bind(fn, that) : function (/* ...args */) { - return fn.apply(that, arguments); - }; -}; - - -/***/ }), - -/***/ 616: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var fails = __webpack_require__(9039); - -module.exports = !fails(function () { - // eslint-disable-next-line es/no-function-prototype-bind -- safe - var test = (function () { /* empty */ }).bind(); - // eslint-disable-next-line no-prototype-builtins -- safe - return typeof test != 'function' || test.hasOwnProperty('prototype'); -}); - - -/***/ }), - -/***/ 9565: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var NATIVE_BIND = __webpack_require__(616); - -var call = Function.prototype.call; - -module.exports = NATIVE_BIND ? call.bind(call) : function () { - return call.apply(call, arguments); -}; - - -/***/ }), - -/***/ 350: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var hasOwn = __webpack_require__(9297); - -var FunctionPrototype = Function.prototype; -// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe -var getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor; - -var EXISTS = hasOwn(FunctionPrototype, 'name'); -// additional protection from minified / mangled / dropped function names -var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something'; -var CONFIGURABLE = EXISTS && (!DESCRIPTORS || (DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable)); - -module.exports = { - EXISTS: EXISTS, - PROPER: PROPER, - CONFIGURABLE: CONFIGURABLE -}; - - -/***/ }), - -/***/ 6706: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var aCallable = __webpack_require__(9306); - -module.exports = function (object, key, method) { - try { - // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe - return uncurryThis(aCallable(Object.getOwnPropertyDescriptor(object, key)[method])); - } catch (error) { /* empty */ } -}; - - -/***/ }), - -/***/ 7476: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var classofRaw = __webpack_require__(4576); -var uncurryThis = __webpack_require__(9504); - -module.exports = function (fn) { - // Nashorn bug: - // https://github.com/zloirock/core-js/issues/1128 - // https://github.com/zloirock/core-js/issues/1130 - if (classofRaw(fn) === 'Function') return uncurryThis(fn); -}; - - -/***/ }), - -/***/ 9504: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var NATIVE_BIND = __webpack_require__(616); - -var FunctionPrototype = Function.prototype; -var call = FunctionPrototype.call; -var uncurryThisWithBind = NATIVE_BIND && FunctionPrototype.bind.bind(call, call); - -module.exports = NATIVE_BIND ? uncurryThisWithBind : function (fn) { - return function () { - return call.apply(fn, arguments); - }; -}; - - -/***/ }), - -/***/ 7751: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var isCallable = __webpack_require__(4901); - -var aFunction = function (argument) { - return isCallable(argument) ? argument : undefined; -}; - -module.exports = function (namespace, method) { - return arguments.length < 2 ? aFunction(global[namespace]) : global[namespace] && global[namespace][method]; -}; - - -/***/ }), - -/***/ 1767: -/***/ ((module) => { - - -// `GetIteratorDirect(obj)` abstract operation -// https://tc39.es/proposal-iterator-helpers/#sec-getiteratordirect -module.exports = function (obj) { - return { - iterator: obj, - next: obj.next, - done: false - }; -}; - - -/***/ }), - -/***/ 8646: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var call = __webpack_require__(9565); -var anObject = __webpack_require__(8551); -var getIteratorDirect = __webpack_require__(1767); -var getIteratorMethod = __webpack_require__(851); - -module.exports = function (obj, stringHandling) { - if (!stringHandling || typeof obj !== 'string') anObject(obj); - var method = getIteratorMethod(obj); - return getIteratorDirect(anObject(method !== undefined ? call(method, obj) : obj)); -}; - - -/***/ }), - -/***/ 851: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var classof = __webpack_require__(6955); -var getMethod = __webpack_require__(5966); -var isNullOrUndefined = __webpack_require__(4117); -var Iterators = __webpack_require__(6269); -var wellKnownSymbol = __webpack_require__(8227); - -var ITERATOR = wellKnownSymbol('iterator'); - -module.exports = function (it) { - if (!isNullOrUndefined(it)) return getMethod(it, ITERATOR) - || getMethod(it, '@@iterator') - || Iterators[classof(it)]; -}; - - -/***/ }), - -/***/ 81: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var call = __webpack_require__(9565); -var aCallable = __webpack_require__(9306); -var anObject = __webpack_require__(8551); -var tryToString = __webpack_require__(6823); -var getIteratorMethod = __webpack_require__(851); - -var $TypeError = TypeError; - -module.exports = function (argument, usingIterator) { - var iteratorMethod = arguments.length < 2 ? getIteratorMethod(argument) : usingIterator; - if (aCallable(iteratorMethod)) return anObject(call(iteratorMethod, argument)); - throw new $TypeError(tryToString(argument) + ' is not iterable'); -}; - - -/***/ }), - -/***/ 5966: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aCallable = __webpack_require__(9306); -var isNullOrUndefined = __webpack_require__(4117); - -// `GetMethod` abstract operation -// https://tc39.es/ecma262/#sec-getmethod -module.exports = function (V, P) { - var func = V[P]; - return isNullOrUndefined(func) ? undefined : aCallable(func); -}; - - -/***/ }), - -/***/ 3789: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aCallable = __webpack_require__(9306); -var anObject = __webpack_require__(8551); -var call = __webpack_require__(9565); -var toIntegerOrInfinity = __webpack_require__(1291); -var getIteratorDirect = __webpack_require__(1767); - -var INVALID_SIZE = 'Invalid size'; -var $RangeError = RangeError; -var $TypeError = TypeError; -var max = Math.max; - -var SetRecord = function (set, intSize) { - this.set = set; - this.size = max(intSize, 0); - this.has = aCallable(set.has); - this.keys = aCallable(set.keys); -}; - -SetRecord.prototype = { - getIterator: function () { - return getIteratorDirect(anObject(call(this.keys, this.set))); - }, - includes: function (it) { - return call(this.has, this.set, it); - } -}; - -// `GetSetRecord` abstract operation -// https://tc39.es/proposal-set-methods/#sec-getsetrecord -module.exports = function (obj) { - anObject(obj); - var numSize = +obj.size; - // NOTE: If size is undefined, then numSize will be NaN - // eslint-disable-next-line no-self-compare -- NaN check - if (numSize !== numSize) throw new $TypeError(INVALID_SIZE); - var intSize = toIntegerOrInfinity(numSize); - if (intSize < 0) throw new $RangeError(INVALID_SIZE); - return new SetRecord(obj, intSize); -}; - - -/***/ }), - -/***/ 4475: -/***/ (function(module) { - - -var check = function (it) { - return it && it.Math === Math && it; -}; - -// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028 -module.exports = - // eslint-disable-next-line es/no-global-this -- safe - check(typeof globalThis == 'object' && globalThis) || - check(typeof window == 'object' && window) || - // eslint-disable-next-line no-restricted-globals -- safe - check(typeof self == 'object' && self) || - check(typeof global == 'object' && global) || - check(typeof this == 'object' && this) || - // eslint-disable-next-line no-new-func -- fallback - (function () { return this; })() || Function('return this')(); - - -/***/ }), - -/***/ 9297: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var toObject = __webpack_require__(8981); - -var hasOwnProperty = uncurryThis({}.hasOwnProperty); - -// `HasOwnProperty` abstract operation -// https://tc39.es/ecma262/#sec-hasownproperty -// eslint-disable-next-line es/no-object-hasown -- safe -module.exports = Object.hasOwn || function hasOwn(it, key) { - return hasOwnProperty(toObject(it), key); -}; - - -/***/ }), - -/***/ 421: -/***/ ((module) => { - - -module.exports = {}; - - -/***/ }), - -/***/ 397: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var getBuiltIn = __webpack_require__(7751); - -module.exports = getBuiltIn('document', 'documentElement'); - - -/***/ }), - -/***/ 5917: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var fails = __webpack_require__(9039); -var createElement = __webpack_require__(4055); - -// Thanks to IE8 for its funny defineProperty -module.exports = !DESCRIPTORS && !fails(function () { - // eslint-disable-next-line es/no-object-defineproperty -- required for testing - return Object.defineProperty(createElement('div'), 'a', { - get: function () { return 7; } - }).a !== 7; -}); - - -/***/ }), - -/***/ 7055: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var fails = __webpack_require__(9039); -var classof = __webpack_require__(4576); - -var $Object = Object; -var split = uncurryThis(''.split); - -// fallback for non-array-like ES3 and non-enumerable old V8 strings -module.exports = fails(function () { - // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346 - // eslint-disable-next-line no-prototype-builtins -- safe - return !$Object('z').propertyIsEnumerable(0); -}) ? function (it) { - return classof(it) === 'String' ? split(it, '') : $Object(it); -} : $Object; - - -/***/ }), - -/***/ 3167: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isCallable = __webpack_require__(4901); -var isObject = __webpack_require__(34); -var setPrototypeOf = __webpack_require__(2967); - -// makes subclassing work correct for wrapped built-ins -module.exports = function ($this, dummy, Wrapper) { - var NewTarget, NewTargetPrototype; - if ( - // it can work only with native `setPrototypeOf` - setPrototypeOf && - // we haven't completely correct pre-ES6 way for getting `new.target`, so use this - isCallable(NewTarget = dummy.constructor) && - NewTarget !== Wrapper && - isObject(NewTargetPrototype = NewTarget.prototype) && - NewTargetPrototype !== Wrapper.prototype - ) setPrototypeOf($this, NewTargetPrototype); - return $this; -}; - - -/***/ }), - -/***/ 3706: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var isCallable = __webpack_require__(4901); -var store = __webpack_require__(7629); - -var functionToString = uncurryThis(Function.toString); - -// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper -if (!isCallable(store.inspectSource)) { - store.inspectSource = function (it) { - return functionToString(it); - }; -} - -module.exports = store.inspectSource; - - -/***/ }), - -/***/ 1181: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var NATIVE_WEAK_MAP = __webpack_require__(8622); -var global = __webpack_require__(4475); -var isObject = __webpack_require__(34); -var createNonEnumerableProperty = __webpack_require__(6699); -var hasOwn = __webpack_require__(9297); -var shared = __webpack_require__(7629); -var sharedKey = __webpack_require__(6119); -var hiddenKeys = __webpack_require__(421); - -var OBJECT_ALREADY_INITIALIZED = 'Object already initialized'; -var TypeError = global.TypeError; -var WeakMap = global.WeakMap; -var set, get, has; - -var enforce = function (it) { - return has(it) ? get(it) : set(it, {}); -}; - -var getterFor = function (TYPE) { - return function (it) { - var state; - if (!isObject(it) || (state = get(it)).type !== TYPE) { - throw new TypeError('Incompatible receiver, ' + TYPE + ' required'); - } return state; - }; -}; - -if (NATIVE_WEAK_MAP || shared.state) { - var store = shared.state || (shared.state = new WeakMap()); - /* eslint-disable no-self-assign -- prototype methods protection */ - store.get = store.get; - store.has = store.has; - store.set = store.set; - /* eslint-enable no-self-assign -- prototype methods protection */ - set = function (it, metadata) { - if (store.has(it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED); - metadata.facade = it; - store.set(it, metadata); - return metadata; - }; - get = function (it) { - return store.get(it) || {}; - }; - has = function (it) { - return store.has(it); - }; -} else { - var STATE = sharedKey('state'); - hiddenKeys[STATE] = true; - set = function (it, metadata) { - if (hasOwn(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED); - metadata.facade = it; - createNonEnumerableProperty(it, STATE, metadata); - return metadata; - }; - get = function (it) { - return hasOwn(it, STATE) ? it[STATE] : {}; - }; - has = function (it) { - return hasOwn(it, STATE); - }; -} - -module.exports = { - set: set, - get: get, - has: has, - enforce: enforce, - getterFor: getterFor -}; - - -/***/ }), - -/***/ 4209: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var wellKnownSymbol = __webpack_require__(8227); -var Iterators = __webpack_require__(6269); - -var ITERATOR = wellKnownSymbol('iterator'); -var ArrayPrototype = Array.prototype; - -// check on default Array iterator -module.exports = function (it) { - return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it); -}; - - -/***/ }), - -/***/ 4376: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var classof = __webpack_require__(4576); - -// `IsArray` abstract operation -// https://tc39.es/ecma262/#sec-isarray -// eslint-disable-next-line es/no-array-isarray -- safe -module.exports = Array.isArray || function isArray(argument) { - return classof(argument) === 'Array'; -}; - - -/***/ }), - -/***/ 1108: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var classof = __webpack_require__(6955); - -module.exports = function (it) { - var klass = classof(it); - return klass === 'BigInt64Array' || klass === 'BigUint64Array'; -}; - - -/***/ }), - -/***/ 4901: -/***/ ((module) => { - - -// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot -var documentAll = typeof document == 'object' && document.all; - -// `IsCallable` abstract operation -// https://tc39.es/ecma262/#sec-iscallable -// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing -module.exports = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) { - return typeof argument == 'function' || argument === documentAll; -} : function (argument) { - return typeof argument == 'function'; -}; - - -/***/ }), - -/***/ 2796: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var fails = __webpack_require__(9039); -var isCallable = __webpack_require__(4901); - -var replacement = /#|\.prototype\./; - -var isForced = function (feature, detection) { - var value = data[normalize(feature)]; - return value === POLYFILL ? true - : value === NATIVE ? false - : isCallable(detection) ? fails(detection) - : !!detection; -}; - -var normalize = isForced.normalize = function (string) { - return String(string).replace(replacement, '.').toLowerCase(); -}; - -var data = isForced.data = {}; -var NATIVE = isForced.NATIVE = 'N'; -var POLYFILL = isForced.POLYFILL = 'P'; - -module.exports = isForced; - - -/***/ }), - -/***/ 4117: -/***/ ((module) => { - - -// we can't use just `it == null` since of `document.all` special case -// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec -module.exports = function (it) { - return it === null || it === undefined; -}; - - -/***/ }), - -/***/ 34: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isCallable = __webpack_require__(4901); - -module.exports = function (it) { - return typeof it == 'object' ? it !== null : isCallable(it); -}; - - -/***/ }), - -/***/ 3925: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isObject = __webpack_require__(34); - -module.exports = function (argument) { - return isObject(argument) || argument === null; -}; - - -/***/ }), - -/***/ 6395: -/***/ ((module) => { - - -module.exports = false; - - -/***/ }), - -/***/ 757: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var getBuiltIn = __webpack_require__(7751); -var isCallable = __webpack_require__(4901); -var isPrototypeOf = __webpack_require__(1625); -var USE_SYMBOL_AS_UID = __webpack_require__(7040); - -var $Object = Object; - -module.exports = USE_SYMBOL_AS_UID ? function (it) { - return typeof it == 'symbol'; -} : function (it) { - var $Symbol = getBuiltIn('Symbol'); - return isCallable($Symbol) && isPrototypeOf($Symbol.prototype, $Object(it)); -}; - - -/***/ }), - -/***/ 507: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var call = __webpack_require__(9565); - -module.exports = function (record, fn, ITERATOR_INSTEAD_OF_RECORD) { - var iterator = ITERATOR_INSTEAD_OF_RECORD ? record : record.iterator; - var next = record.next; - var step, result; - while (!(step = call(next, iterator)).done) { - result = fn(step.value); - if (result !== undefined) return result; - } -}; - - -/***/ }), - -/***/ 2652: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var bind = __webpack_require__(6080); -var call = __webpack_require__(9565); -var anObject = __webpack_require__(8551); -var tryToString = __webpack_require__(6823); -var isArrayIteratorMethod = __webpack_require__(4209); -var lengthOfArrayLike = __webpack_require__(6198); -var isPrototypeOf = __webpack_require__(1625); -var getIterator = __webpack_require__(81); -var getIteratorMethod = __webpack_require__(851); -var iteratorClose = __webpack_require__(9539); - -var $TypeError = TypeError; - -var Result = function (stopped, result) { - this.stopped = stopped; - this.result = result; -}; - -var ResultPrototype = Result.prototype; - -module.exports = function (iterable, unboundFunction, options) { - var that = options && options.that; - var AS_ENTRIES = !!(options && options.AS_ENTRIES); - var IS_RECORD = !!(options && options.IS_RECORD); - var IS_ITERATOR = !!(options && options.IS_ITERATOR); - var INTERRUPTED = !!(options && options.INTERRUPTED); - var fn = bind(unboundFunction, that); - var iterator, iterFn, index, length, result, next, step; - - var stop = function (condition) { - if (iterator) iteratorClose(iterator, 'normal', condition); - return new Result(true, condition); - }; - - var callFn = function (value) { - if (AS_ENTRIES) { - anObject(value); - return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]); - } return INTERRUPTED ? fn(value, stop) : fn(value); - }; - - if (IS_RECORD) { - iterator = iterable.iterator; - } else if (IS_ITERATOR) { - iterator = iterable; - } else { - iterFn = getIteratorMethod(iterable); - if (!iterFn) throw new $TypeError(tryToString(iterable) + ' is not iterable'); - // optimisation for array iterators - if (isArrayIteratorMethod(iterFn)) { - for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) { - result = callFn(iterable[index]); - if (result && isPrototypeOf(ResultPrototype, result)) return result; - } return new Result(false); - } - iterator = getIterator(iterable, iterFn); - } - - next = IS_RECORD ? iterable.next : iterator.next; - while (!(step = call(next, iterator)).done) { - try { - result = callFn(step.value); - } catch (error) { - iteratorClose(iterator, 'throw', error); - } - if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result; - } return new Result(false); -}; - - -/***/ }), - -/***/ 9539: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var call = __webpack_require__(9565); -var anObject = __webpack_require__(8551); -var getMethod = __webpack_require__(5966); - -module.exports = function (iterator, kind, value) { - var innerResult, innerError; - anObject(iterator); - try { - innerResult = getMethod(iterator, 'return'); - if (!innerResult) { - if (kind === 'throw') throw value; - return value; - } - innerResult = call(innerResult, iterator); - } catch (error) { - innerError = true; - innerResult = error; - } - if (kind === 'throw') throw value; - if (innerError) throw innerResult; - anObject(innerResult); - return value; -}; - - -/***/ }), - -/***/ 9462: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var call = __webpack_require__(9565); -var create = __webpack_require__(2360); -var createNonEnumerableProperty = __webpack_require__(6699); -var defineBuiltIns = __webpack_require__(6279); -var wellKnownSymbol = __webpack_require__(8227); -var InternalStateModule = __webpack_require__(1181); -var getMethod = __webpack_require__(5966); -var IteratorPrototype = (__webpack_require__(7657).IteratorPrototype); -var createIterResultObject = __webpack_require__(2529); -var iteratorClose = __webpack_require__(9539); - -var TO_STRING_TAG = wellKnownSymbol('toStringTag'); -var ITERATOR_HELPER = 'IteratorHelper'; -var WRAP_FOR_VALID_ITERATOR = 'WrapForValidIterator'; -var setInternalState = InternalStateModule.set; - -var createIteratorProxyPrototype = function (IS_ITERATOR) { - var getInternalState = InternalStateModule.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER); - - return defineBuiltIns(create(IteratorPrototype), { - next: function next() { - var state = getInternalState(this); - // for simplification: - // for `%WrapForValidIteratorPrototype%.next` our `nextHandler` returns `IterResultObject` - // for `%IteratorHelperPrototype%.next` - just a value - if (IS_ITERATOR) return state.nextHandler(); - try { - var result = state.done ? undefined : state.nextHandler(); - return createIterResultObject(result, state.done); - } catch (error) { - state.done = true; - throw error; - } - }, - 'return': function () { - var state = getInternalState(this); - var iterator = state.iterator; - state.done = true; - if (IS_ITERATOR) { - var returnMethod = getMethod(iterator, 'return'); - return returnMethod ? call(returnMethod, iterator) : createIterResultObject(undefined, true); - } - if (state.inner) try { - iteratorClose(state.inner.iterator, 'normal'); - } catch (error) { - return iteratorClose(iterator, 'throw', error); - } - iteratorClose(iterator, 'normal'); - return createIterResultObject(undefined, true); - } - }); -}; - -var WrapForValidIteratorPrototype = createIteratorProxyPrototype(true); -var IteratorHelperPrototype = createIteratorProxyPrototype(false); - -createNonEnumerableProperty(IteratorHelperPrototype, TO_STRING_TAG, 'Iterator Helper'); - -module.exports = function (nextHandler, IS_ITERATOR) { - var IteratorProxy = function Iterator(record, state) { - if (state) { - state.iterator = record.iterator; - state.next = record.next; - } else state = record; - state.type = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER; - state.nextHandler = nextHandler; - state.counter = 0; - state.done = false; - setInternalState(this, state); - }; - - IteratorProxy.prototype = IS_ITERATOR ? WrapForValidIteratorPrototype : IteratorHelperPrototype; - - return IteratorProxy; -}; - - -/***/ }), - -/***/ 713: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var call = __webpack_require__(9565); -var aCallable = __webpack_require__(9306); -var anObject = __webpack_require__(8551); -var getIteratorDirect = __webpack_require__(1767); -var createIteratorProxy = __webpack_require__(9462); -var callWithSafeIterationClosing = __webpack_require__(6319); - -var IteratorProxy = createIteratorProxy(function () { - var iterator = this.iterator; - var result = anObject(call(this.next, iterator)); - var done = this.done = !!result.done; - if (!done) return callWithSafeIterationClosing(iterator, this.mapper, [result.value, this.counter++], true); -}); - -// `Iterator.prototype.map` method -// https://github.com/tc39/proposal-iterator-helpers -module.exports = function map(mapper) { - anObject(this); - aCallable(mapper); - return new IteratorProxy(getIteratorDirect(this), { - mapper: mapper - }); -}; - - -/***/ }), - -/***/ 7657: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var fails = __webpack_require__(9039); -var isCallable = __webpack_require__(4901); -var isObject = __webpack_require__(34); -var create = __webpack_require__(2360); -var getPrototypeOf = __webpack_require__(2787); -var defineBuiltIn = __webpack_require__(6840); -var wellKnownSymbol = __webpack_require__(8227); -var IS_PURE = __webpack_require__(6395); - -var ITERATOR = wellKnownSymbol('iterator'); -var BUGGY_SAFARI_ITERATORS = false; - -// `%IteratorPrototype%` object -// https://tc39.es/ecma262/#sec-%iteratorprototype%-object -var IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator; - -/* eslint-disable es/no-array-prototype-keys -- safe */ -if ([].keys) { - arrayIterator = [].keys(); - // Safari 8 has buggy iterators w/o `next` - if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true; - else { - PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator)); - if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype; - } -} - -var NEW_ITERATOR_PROTOTYPE = !isObject(IteratorPrototype) || fails(function () { - var test = {}; - // FF44- legacy iterators case - return IteratorPrototype[ITERATOR].call(test) !== test; -}); - -if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {}; -else if (IS_PURE) IteratorPrototype = create(IteratorPrototype); - -// `%IteratorPrototype%[@@iterator]()` method -// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator -if (!isCallable(IteratorPrototype[ITERATOR])) { - defineBuiltIn(IteratorPrototype, ITERATOR, function () { - return this; - }); -} - -module.exports = { - IteratorPrototype: IteratorPrototype, - BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS -}; - - -/***/ }), - -/***/ 6269: -/***/ ((module) => { - - -module.exports = {}; - - -/***/ }), - -/***/ 6198: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toLength = __webpack_require__(8014); - -// `LengthOfArrayLike` abstract operation -// https://tc39.es/ecma262/#sec-lengthofarraylike -module.exports = function (obj) { - return toLength(obj.length); -}; - - -/***/ }), - -/***/ 283: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var fails = __webpack_require__(9039); -var isCallable = __webpack_require__(4901); -var hasOwn = __webpack_require__(9297); -var DESCRIPTORS = __webpack_require__(3724); -var CONFIGURABLE_FUNCTION_NAME = (__webpack_require__(350).CONFIGURABLE); -var inspectSource = __webpack_require__(3706); -var InternalStateModule = __webpack_require__(1181); - -var enforceInternalState = InternalStateModule.enforce; -var getInternalState = InternalStateModule.get; -var $String = String; -// eslint-disable-next-line es/no-object-defineproperty -- safe -var defineProperty = Object.defineProperty; -var stringSlice = uncurryThis(''.slice); -var replace = uncurryThis(''.replace); -var join = uncurryThis([].join); - -var CONFIGURABLE_LENGTH = DESCRIPTORS && !fails(function () { - return defineProperty(function () { /* empty */ }, 'length', { value: 8 }).length !== 8; -}); - -var TEMPLATE = String(String).split('String'); - -var makeBuiltIn = module.exports = function (value, name, options) { - if (stringSlice($String(name), 0, 7) === 'Symbol(') { - name = '[' + replace($String(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']'; - } - if (options && options.getter) name = 'get ' + name; - if (options && options.setter) name = 'set ' + name; - if (!hasOwn(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) { - if (DESCRIPTORS) defineProperty(value, 'name', { value: name, configurable: true }); - else value.name = name; - } - if (CONFIGURABLE_LENGTH && options && hasOwn(options, 'arity') && value.length !== options.arity) { - defineProperty(value, 'length', { value: options.arity }); - } - try { - if (options && hasOwn(options, 'constructor') && options.constructor) { - if (DESCRIPTORS) defineProperty(value, 'prototype', { writable: false }); - // in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable - } else if (value.prototype) value.prototype = undefined; - } catch (error) { /* empty */ } - var state = enforceInternalState(value); - if (!hasOwn(state, 'source')) { - state.source = join(TEMPLATE, typeof name == 'string' ? name : ''); - } return value; -}; - -// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative -// eslint-disable-next-line no-extend-native -- required -Function.prototype.toString = makeBuiltIn(function toString() { - return isCallable(this) && getInternalState(this).source || inspectSource(this); -}, 'toString'); - - -/***/ }), - -/***/ 741: -/***/ ((module) => { - - -var ceil = Math.ceil; -var floor = Math.floor; - -// `Math.trunc` method -// https://tc39.es/ecma262/#sec-math.trunc -// eslint-disable-next-line es/no-math-trunc -- safe -module.exports = Math.trunc || function trunc(x) { - var n = +x; - return (n > 0 ? floor : ceil)(n); -}; - - -/***/ }), - -/***/ 6043: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aCallable = __webpack_require__(9306); - -var $TypeError = TypeError; - -var PromiseCapability = function (C) { - var resolve, reject; - this.promise = new C(function ($$resolve, $$reject) { - if (resolve !== undefined || reject !== undefined) throw new $TypeError('Bad Promise constructor'); - resolve = $$resolve; - reject = $$reject; - }); - this.resolve = aCallable(resolve); - this.reject = aCallable(reject); -}; - -// `NewPromiseCapability` abstract operation -// https://tc39.es/ecma262/#sec-newpromisecapability -module.exports.f = function (C) { - return new PromiseCapability(C); -}; - - -/***/ }), - -/***/ 2603: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toString = __webpack_require__(655); - -module.exports = function (argument, $default) { - return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument); -}; - - -/***/ }), - -/***/ 4149: -/***/ ((module) => { - - -var $RangeError = RangeError; - -module.exports = function (it) { - // eslint-disable-next-line no-self-compare -- NaN check - if (it === it) return it; - throw new $RangeError('NaN is not allowed'); -}; - - -/***/ }), - -/***/ 2360: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -/* global ActiveXObject -- old IE, WSH */ -var anObject = __webpack_require__(8551); -var definePropertiesModule = __webpack_require__(6801); -var enumBugKeys = __webpack_require__(8727); -var hiddenKeys = __webpack_require__(421); -var html = __webpack_require__(397); -var documentCreateElement = __webpack_require__(4055); -var sharedKey = __webpack_require__(6119); - -var GT = '>'; -var LT = '<'; -var PROTOTYPE = 'prototype'; -var SCRIPT = 'script'; -var IE_PROTO = sharedKey('IE_PROTO'); - -var EmptyConstructor = function () { /* empty */ }; - -var scriptTag = function (content) { - return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT; -}; - -// Create object with fake `null` prototype: use ActiveX Object with cleared prototype -var NullProtoObjectViaActiveX = function (activeXDocument) { - activeXDocument.write(scriptTag('')); - activeXDocument.close(); - var temp = activeXDocument.parentWindow.Object; - activeXDocument = null; // avoid memory leak - return temp; -}; - -// Create object with fake `null` prototype: use iframe Object with cleared prototype -var NullProtoObjectViaIFrame = function () { - // Thrash, waste and sodomy: IE GC bug - var iframe = documentCreateElement('iframe'); - var JS = 'java' + SCRIPT + ':'; - var iframeDocument; - iframe.style.display = 'none'; - html.appendChild(iframe); - // https://github.com/zloirock/core-js/issues/475 - iframe.src = String(JS); - iframeDocument = iframe.contentWindow.document; - iframeDocument.open(); - iframeDocument.write(scriptTag('document.F=Object')); - iframeDocument.close(); - return iframeDocument.F; -}; - -// Check for document.domain and active x support -// No need to use active x approach when document.domain is not set -// see https://github.com/es-shims/es5-shim/issues/150 -// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346 -// avoid IE GC bug -var activeXDocument; -var NullProtoObject = function () { - try { - activeXDocument = new ActiveXObject('htmlfile'); - } catch (error) { /* ignore */ } - NullProtoObject = typeof document != 'undefined' - ? document.domain && activeXDocument - ? NullProtoObjectViaActiveX(activeXDocument) // old IE - : NullProtoObjectViaIFrame() - : NullProtoObjectViaActiveX(activeXDocument); // WSH - var length = enumBugKeys.length; - while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]]; - return NullProtoObject(); -}; - -hiddenKeys[IE_PROTO] = true; - -// `Object.create` method -// https://tc39.es/ecma262/#sec-object.create -// eslint-disable-next-line es/no-object-create -- safe -module.exports = Object.create || function create(O, Properties) { - var result; - if (O !== null) { - EmptyConstructor[PROTOTYPE] = anObject(O); - result = new EmptyConstructor(); - EmptyConstructor[PROTOTYPE] = null; - // add "__proto__" for Object.getPrototypeOf polyfill - result[IE_PROTO] = O; - } else result = NullProtoObject(); - return Properties === undefined ? result : definePropertiesModule.f(result, Properties); -}; - - -/***/ }), - -/***/ 6801: -/***/ ((__unused_webpack_module, exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var V8_PROTOTYPE_DEFINE_BUG = __webpack_require__(8686); -var definePropertyModule = __webpack_require__(4913); -var anObject = __webpack_require__(8551); -var toIndexedObject = __webpack_require__(5397); -var objectKeys = __webpack_require__(1072); - -// `Object.defineProperties` method -// https://tc39.es/ecma262/#sec-object.defineproperties -// eslint-disable-next-line es/no-object-defineproperties -- safe -exports.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) { - anObject(O); - var props = toIndexedObject(Properties); - var keys = objectKeys(Properties); - var length = keys.length; - var index = 0; - var key; - while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]); - return O; -}; - - -/***/ }), - -/***/ 4913: -/***/ ((__unused_webpack_module, exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var IE8_DOM_DEFINE = __webpack_require__(5917); -var V8_PROTOTYPE_DEFINE_BUG = __webpack_require__(8686); -var anObject = __webpack_require__(8551); -var toPropertyKey = __webpack_require__(6969); - -var $TypeError = TypeError; -// eslint-disable-next-line es/no-object-defineproperty -- safe -var $defineProperty = Object.defineProperty; -// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe -var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; -var ENUMERABLE = 'enumerable'; -var CONFIGURABLE = 'configurable'; -var WRITABLE = 'writable'; - -// `Object.defineProperty` method -// https://tc39.es/ecma262/#sec-object.defineproperty -exports.f = DESCRIPTORS ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) { - anObject(O); - P = toPropertyKey(P); - anObject(Attributes); - if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) { - var current = $getOwnPropertyDescriptor(O, P); - if (current && current[WRITABLE]) { - O[P] = Attributes.value; - Attributes = { - configurable: CONFIGURABLE in Attributes ? Attributes[CONFIGURABLE] : current[CONFIGURABLE], - enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE], - writable: false - }; - } - } return $defineProperty(O, P, Attributes); -} : $defineProperty : function defineProperty(O, P, Attributes) { - anObject(O); - P = toPropertyKey(P); - anObject(Attributes); - if (IE8_DOM_DEFINE) try { - return $defineProperty(O, P, Attributes); - } catch (error) { /* empty */ } - if ('get' in Attributes || 'set' in Attributes) throw new $TypeError('Accessors not supported'); - if ('value' in Attributes) O[P] = Attributes.value; - return O; -}; - - -/***/ }), - -/***/ 7347: -/***/ ((__unused_webpack_module, exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var call = __webpack_require__(9565); -var propertyIsEnumerableModule = __webpack_require__(8773); -var createPropertyDescriptor = __webpack_require__(6980); -var toIndexedObject = __webpack_require__(5397); -var toPropertyKey = __webpack_require__(6969); -var hasOwn = __webpack_require__(9297); -var IE8_DOM_DEFINE = __webpack_require__(5917); - -// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe -var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; - -// `Object.getOwnPropertyDescriptor` method -// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor -exports.f = DESCRIPTORS ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) { - O = toIndexedObject(O); - P = toPropertyKey(P); - if (IE8_DOM_DEFINE) try { - return $getOwnPropertyDescriptor(O, P); - } catch (error) { /* empty */ } - if (hasOwn(O, P)) return createPropertyDescriptor(!call(propertyIsEnumerableModule.f, O, P), O[P]); -}; - - -/***/ }), - -/***/ 8480: -/***/ ((__unused_webpack_module, exports, __webpack_require__) => { - - -var internalObjectKeys = __webpack_require__(1828); -var enumBugKeys = __webpack_require__(8727); - -var hiddenKeys = enumBugKeys.concat('length', 'prototype'); - -// `Object.getOwnPropertyNames` method -// https://tc39.es/ecma262/#sec-object.getownpropertynames -// eslint-disable-next-line es/no-object-getownpropertynames -- safe -exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) { - return internalObjectKeys(O, hiddenKeys); -}; - - -/***/ }), - -/***/ 3717: -/***/ ((__unused_webpack_module, exports) => { - - -// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe -exports.f = Object.getOwnPropertySymbols; - - -/***/ }), - -/***/ 2787: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var hasOwn = __webpack_require__(9297); -var isCallable = __webpack_require__(4901); -var toObject = __webpack_require__(8981); -var sharedKey = __webpack_require__(6119); -var CORRECT_PROTOTYPE_GETTER = __webpack_require__(2211); - -var IE_PROTO = sharedKey('IE_PROTO'); -var $Object = Object; -var ObjectPrototype = $Object.prototype; - -// `Object.getPrototypeOf` method -// https://tc39.es/ecma262/#sec-object.getprototypeof -// eslint-disable-next-line es/no-object-getprototypeof -- safe -module.exports = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) { - var object = toObject(O); - if (hasOwn(object, IE_PROTO)) return object[IE_PROTO]; - var constructor = object.constructor; - if (isCallable(constructor) && object instanceof constructor) { - return constructor.prototype; - } return object instanceof $Object ? ObjectPrototype : null; -}; - - -/***/ }), - -/***/ 1625: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); - -module.exports = uncurryThis({}.isPrototypeOf); - - -/***/ }), - -/***/ 1828: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var hasOwn = __webpack_require__(9297); -var toIndexedObject = __webpack_require__(5397); -var indexOf = (__webpack_require__(9617).indexOf); -var hiddenKeys = __webpack_require__(421); - -var push = uncurryThis([].push); - -module.exports = function (object, names) { - var O = toIndexedObject(object); - var i = 0; - var result = []; - var key; - for (key in O) !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key); - // Don't enum bug & hidden keys - while (names.length > i) if (hasOwn(O, key = names[i++])) { - ~indexOf(result, key) || push(result, key); - } - return result; -}; - - -/***/ }), - -/***/ 1072: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var internalObjectKeys = __webpack_require__(1828); -var enumBugKeys = __webpack_require__(8727); - -// `Object.keys` method -// https://tc39.es/ecma262/#sec-object.keys -// eslint-disable-next-line es/no-object-keys -- safe -module.exports = Object.keys || function keys(O) { - return internalObjectKeys(O, enumBugKeys); -}; - - -/***/ }), - -/***/ 8773: -/***/ ((__unused_webpack_module, exports) => { - - -var $propertyIsEnumerable = {}.propertyIsEnumerable; -// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe -var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; - -// Nashorn ~ JDK8 bug -var NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({ 1: 2 }, 1); - -// `Object.prototype.propertyIsEnumerable` method implementation -// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable -exports.f = NASHORN_BUG ? function propertyIsEnumerable(V) { - var descriptor = getOwnPropertyDescriptor(this, V); - return !!descriptor && descriptor.enumerable; -} : $propertyIsEnumerable; - - -/***/ }), - -/***/ 2967: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -/* eslint-disable no-proto -- safe */ -var uncurryThisAccessor = __webpack_require__(6706); -var isObject = __webpack_require__(34); -var requireObjectCoercible = __webpack_require__(7750); -var aPossiblePrototype = __webpack_require__(3506); - -// `Object.setPrototypeOf` method -// https://tc39.es/ecma262/#sec-object.setprototypeof -// Works with __proto__ only. Old v8 can't work with null proto objects. -// eslint-disable-next-line es/no-object-setprototypeof -- safe -module.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () { - var CORRECT_SETTER = false; - var test = {}; - var setter; - try { - setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set'); - setter(test, []); - CORRECT_SETTER = test instanceof Array; - } catch (error) { /* empty */ } - return function setPrototypeOf(O, proto) { - requireObjectCoercible(O); - aPossiblePrototype(proto); - if (!isObject(O)) return O; - if (CORRECT_SETTER) setter(O, proto); - else O.__proto__ = proto; - return O; - }; -}() : undefined); - - -/***/ }), - -/***/ 4270: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var call = __webpack_require__(9565); -var isCallable = __webpack_require__(4901); -var isObject = __webpack_require__(34); - -var $TypeError = TypeError; - -// `OrdinaryToPrimitive` abstract operation -// https://tc39.es/ecma262/#sec-ordinarytoprimitive -module.exports = function (input, pref) { - var fn, val; - if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val; - if (isCallable(fn = input.valueOf) && !isObject(val = call(fn, input))) return val; - if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val; - throw new $TypeError("Can't convert object to primitive value"); -}; - - -/***/ }), - -/***/ 5031: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var getBuiltIn = __webpack_require__(7751); -var uncurryThis = __webpack_require__(9504); -var getOwnPropertyNamesModule = __webpack_require__(8480); -var getOwnPropertySymbolsModule = __webpack_require__(3717); -var anObject = __webpack_require__(8551); - -var concat = uncurryThis([].concat); - -// all object keys, includes non-enumerable and symbols -module.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) { - var keys = getOwnPropertyNamesModule.f(anObject(it)); - var getOwnPropertySymbols = getOwnPropertySymbolsModule.f; - return getOwnPropertySymbols ? concat(keys, getOwnPropertySymbols(it)) : keys; -}; - - -/***/ }), - -/***/ 8235: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var hasOwn = __webpack_require__(9297); - -var $SyntaxError = SyntaxError; -var $parseInt = parseInt; -var fromCharCode = String.fromCharCode; -var at = uncurryThis(''.charAt); -var slice = uncurryThis(''.slice); -var exec = uncurryThis(/./.exec); - -var codePoints = { - '\\"': '"', - '\\\\': '\\', - '\\/': '/', - '\\b': '\b', - '\\f': '\f', - '\\n': '\n', - '\\r': '\r', - '\\t': '\t' -}; - -var IS_4_HEX_DIGITS = /^[\da-f]{4}$/i; -// eslint-disable-next-line regexp/no-control-character -- safe -var IS_C0_CONTROL_CODE = /^[\u0000-\u001F]$/; - -module.exports = function (source, i) { - var unterminated = true; - var value = ''; - while (i < source.length) { - var chr = at(source, i); - if (chr === '\\') { - var twoChars = slice(source, i, i + 2); - if (hasOwn(codePoints, twoChars)) { - value += codePoints[twoChars]; - i += 2; - } else if (twoChars === '\\u') { - i += 2; - var fourHexDigits = slice(source, i, i + 4); - if (!exec(IS_4_HEX_DIGITS, fourHexDigits)) throw new $SyntaxError('Bad Unicode escape at: ' + i); - value += fromCharCode($parseInt(fourHexDigits, 16)); - i += 4; - } else throw new $SyntaxError('Unknown escape sequence: "' + twoChars + '"'); - } else if (chr === '"') { - unterminated = false; - i++; - break; - } else { - if (exec(IS_C0_CONTROL_CODE, chr)) throw new $SyntaxError('Bad control character in string literal at: ' + i); - value += chr; - i++; - } - } - if (unterminated) throw new $SyntaxError('Unterminated string at: ' + i); - return { value: value, end: i }; -}; - - -/***/ }), - -/***/ 7750: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var isNullOrUndefined = __webpack_require__(4117); - -var $TypeError = TypeError; - -// `RequireObjectCoercible` abstract operation -// https://tc39.es/ecma262/#sec-requireobjectcoercible -module.exports = function (it) { - if (isNullOrUndefined(it)) throw new $TypeError("Can't call method on " + it); - return it; -}; - - -/***/ }), - -/***/ 9286: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var SetHelpers = __webpack_require__(4402); -var iterate = __webpack_require__(8469); - -var Set = SetHelpers.Set; -var add = SetHelpers.add; - -module.exports = function (set) { - var result = new Set(); - iterate(set, function (it) { - add(result, it); - }); - return result; -}; - - -/***/ }), - -/***/ 3440: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aSet = __webpack_require__(7080); -var SetHelpers = __webpack_require__(4402); -var clone = __webpack_require__(9286); -var size = __webpack_require__(5170); -var getSetRecord = __webpack_require__(3789); -var iterateSet = __webpack_require__(8469); -var iterateSimple = __webpack_require__(507); - -var has = SetHelpers.has; -var remove = SetHelpers.remove; - -// `Set.prototype.difference` method -// https://github.com/tc39/proposal-set-methods -module.exports = function difference(other) { - var O = aSet(this); - var otherRec = getSetRecord(other); - var result = clone(O); - if (size(O) <= otherRec.size) iterateSet(O, function (e) { - if (otherRec.includes(e)) remove(result, e); - }); - else iterateSimple(otherRec.getIterator(), function (e) { - if (has(O, e)) remove(result, e); - }); - return result; -}; - - -/***/ }), - -/***/ 4402: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); - -// eslint-disable-next-line es/no-set -- safe -var SetPrototype = Set.prototype; - -module.exports = { - // eslint-disable-next-line es/no-set -- safe - Set: Set, - add: uncurryThis(SetPrototype.add), - has: uncurryThis(SetPrototype.has), - remove: uncurryThis(SetPrototype['delete']), - proto: SetPrototype -}; - - -/***/ }), - -/***/ 8750: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aSet = __webpack_require__(7080); -var SetHelpers = __webpack_require__(4402); -var size = __webpack_require__(5170); -var getSetRecord = __webpack_require__(3789); -var iterateSet = __webpack_require__(8469); -var iterateSimple = __webpack_require__(507); - -var Set = SetHelpers.Set; -var add = SetHelpers.add; -var has = SetHelpers.has; - -// `Set.prototype.intersection` method -// https://github.com/tc39/proposal-set-methods -module.exports = function intersection(other) { - var O = aSet(this); - var otherRec = getSetRecord(other); - var result = new Set(); - - if (size(O) > otherRec.size) { - iterateSimple(otherRec.getIterator(), function (e) { - if (has(O, e)) add(result, e); - }); - } else { - iterateSet(O, function (e) { - if (otherRec.includes(e)) add(result, e); - }); - } - - return result; -}; - - -/***/ }), - -/***/ 4449: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aSet = __webpack_require__(7080); -var has = (__webpack_require__(4402).has); -var size = __webpack_require__(5170); -var getSetRecord = __webpack_require__(3789); -var iterateSet = __webpack_require__(8469); -var iterateSimple = __webpack_require__(507); -var iteratorClose = __webpack_require__(9539); - -// `Set.prototype.isDisjointFrom` method -// https://tc39.github.io/proposal-set-methods/#Set.prototype.isDisjointFrom -module.exports = function isDisjointFrom(other) { - var O = aSet(this); - var otherRec = getSetRecord(other); - if (size(O) <= otherRec.size) return iterateSet(O, function (e) { - if (otherRec.includes(e)) return false; - }, true) !== false; - var iterator = otherRec.getIterator(); - return iterateSimple(iterator, function (e) { - if (has(O, e)) return iteratorClose(iterator, 'normal', false); - }) !== false; -}; - - -/***/ }), - -/***/ 3838: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aSet = __webpack_require__(7080); -var size = __webpack_require__(5170); -var iterate = __webpack_require__(8469); -var getSetRecord = __webpack_require__(3789); - -// `Set.prototype.isSubsetOf` method -// https://tc39.github.io/proposal-set-methods/#Set.prototype.isSubsetOf -module.exports = function isSubsetOf(other) { - var O = aSet(this); - var otherRec = getSetRecord(other); - if (size(O) > otherRec.size) return false; - return iterate(O, function (e) { - if (!otherRec.includes(e)) return false; - }, true) !== false; -}; - - -/***/ }), - -/***/ 8527: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aSet = __webpack_require__(7080); -var has = (__webpack_require__(4402).has); -var size = __webpack_require__(5170); -var getSetRecord = __webpack_require__(3789); -var iterateSimple = __webpack_require__(507); -var iteratorClose = __webpack_require__(9539); - -// `Set.prototype.isSupersetOf` method -// https://tc39.github.io/proposal-set-methods/#Set.prototype.isSupersetOf -module.exports = function isSupersetOf(other) { - var O = aSet(this); - var otherRec = getSetRecord(other); - if (size(O) < otherRec.size) return false; - var iterator = otherRec.getIterator(); - return iterateSimple(iterator, function (e) { - if (!has(O, e)) return iteratorClose(iterator, 'normal', false); - }) !== false; -}; - - -/***/ }), - -/***/ 8469: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); -var iterateSimple = __webpack_require__(507); -var SetHelpers = __webpack_require__(4402); - -var Set = SetHelpers.Set; -var SetPrototype = SetHelpers.proto; -var forEach = uncurryThis(SetPrototype.forEach); -var keys = uncurryThis(SetPrototype.keys); -var next = keys(new Set()).next; - -module.exports = function (set, fn, interruptible) { - return interruptible ? iterateSimple({ iterator: keys(set), next: next }, fn) : forEach(set, fn); -}; - - -/***/ }), - -/***/ 4916: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var getBuiltIn = __webpack_require__(7751); - -var createSetLike = function (size) { - return { - size: size, - has: function () { - return false; - }, - keys: function () { - return { - next: function () { - return { done: true }; - } - }; - } - }; -}; - -module.exports = function (name) { - var Set = getBuiltIn('Set'); - try { - new Set()[name](createSetLike(0)); - try { - // late spec change, early WebKit ~ Safari 17.0 beta implementation does not pass it - // https://github.com/tc39/proposal-set-methods/pull/88 - new Set()[name](createSetLike(-1)); - return false; - } catch (error2) { - return true; - } - } catch (error) { - return false; - } -}; - - -/***/ }), - -/***/ 5170: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThisAccessor = __webpack_require__(6706); -var SetHelpers = __webpack_require__(4402); - -module.exports = uncurryThisAccessor(SetHelpers.proto, 'size', 'get') || function (set) { - return set.size; -}; - - -/***/ }), - -/***/ 3650: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aSet = __webpack_require__(7080); -var SetHelpers = __webpack_require__(4402); -var clone = __webpack_require__(9286); -var getSetRecord = __webpack_require__(3789); -var iterateSimple = __webpack_require__(507); - -var add = SetHelpers.add; -var has = SetHelpers.has; -var remove = SetHelpers.remove; - -// `Set.prototype.symmetricDifference` method -// https://github.com/tc39/proposal-set-methods -module.exports = function symmetricDifference(other) { - var O = aSet(this); - var keysIter = getSetRecord(other).getIterator(); - var result = clone(O); - iterateSimple(keysIter, function (e) { - if (has(O, e)) remove(result, e); - else add(result, e); - }); - return result; -}; - - -/***/ }), - -/***/ 4204: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var aSet = __webpack_require__(7080); -var add = (__webpack_require__(4402).add); -var clone = __webpack_require__(9286); -var getSetRecord = __webpack_require__(3789); -var iterateSimple = __webpack_require__(507); - -// `Set.prototype.union` method -// https://github.com/tc39/proposal-set-methods -module.exports = function union(other) { - var O = aSet(this); - var keysIter = getSetRecord(other).getIterator(); - var result = clone(O); - iterateSimple(keysIter, function (it) { - add(result, it); - }); - return result; -}; - - -/***/ }), - -/***/ 6119: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var shared = __webpack_require__(5745); -var uid = __webpack_require__(3392); - -var keys = shared('keys'); - -module.exports = function (key) { - return keys[key] || (keys[key] = uid(key)); -}; - - -/***/ }), - -/***/ 7629: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var IS_PURE = __webpack_require__(6395); -var globalThis = __webpack_require__(4475); -var defineGlobalProperty = __webpack_require__(9433); - -var SHARED = '__core-js_shared__'; -var store = module.exports = globalThis[SHARED] || defineGlobalProperty(SHARED, {}); - -(store.versions || (store.versions = [])).push({ - version: '3.37.1', - mode: IS_PURE ? 'pure' : 'global', - copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)', - license: 'https://github.com/zloirock/core-js/blob/v3.37.1/LICENSE', - source: 'https://github.com/zloirock/core-js' -}); - - -/***/ }), - -/***/ 5745: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var store = __webpack_require__(7629); - -module.exports = function (key, value) { - return store[key] || (store[key] = value || {}); -}; - - -/***/ }), - -/***/ 1548: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var fails = __webpack_require__(9039); -var V8 = __webpack_require__(7388); -var IS_BROWSER = __webpack_require__(7290); -var IS_DENO = __webpack_require__(516); -var IS_NODE = __webpack_require__(9088); - -var structuredClone = global.structuredClone; - -module.exports = !!structuredClone && !fails(function () { - // prevent V8 ArrayBufferDetaching protector cell invalidation and performance degradation - // https://github.com/zloirock/core-js/issues/679 - if ((IS_DENO && V8 > 92) || (IS_NODE && V8 > 94) || (IS_BROWSER && V8 > 97)) return false; - var buffer = new ArrayBuffer(8); - var clone = structuredClone(buffer, { transfer: [buffer] }); - return buffer.byteLength !== 0 || clone.byteLength !== 8; -}); - - -/***/ }), - -/***/ 4495: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -/* eslint-disable es/no-symbol -- required for testing */ -var V8_VERSION = __webpack_require__(7388); -var fails = __webpack_require__(9039); -var global = __webpack_require__(4475); - -var $String = global.String; - -// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing -module.exports = !!Object.getOwnPropertySymbols && !fails(function () { - var symbol = Symbol('symbol detection'); - // Chrome 38 Symbol has incorrect toString conversion - // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances - // nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will, - // of course, fail. - return !$String(symbol) || !(Object(symbol) instanceof Symbol) || - // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances - !Symbol.sham && V8_VERSION && V8_VERSION < 41; -}); - - -/***/ }), - -/***/ 5610: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toIntegerOrInfinity = __webpack_require__(1291); - -var max = Math.max; -var min = Math.min; - -// Helper for a popular repeating case of the spec: -// Let integer be ? ToInteger(index). -// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length). -module.exports = function (index, length) { - var integer = toIntegerOrInfinity(index); - return integer < 0 ? max(integer + length, 0) : min(integer, length); -}; - - -/***/ }), - -/***/ 5854: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toPrimitive = __webpack_require__(2777); - -var $TypeError = TypeError; - -// `ToBigInt` abstract operation -// https://tc39.es/ecma262/#sec-tobigint -module.exports = function (argument) { - var prim = toPrimitive(argument, 'number'); - if (typeof prim == 'number') throw new $TypeError("Can't convert number to bigint"); - // eslint-disable-next-line es/no-bigint -- safe - return BigInt(prim); -}; - - -/***/ }), - -/***/ 7696: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toIntegerOrInfinity = __webpack_require__(1291); -var toLength = __webpack_require__(8014); - -var $RangeError = RangeError; - -// `ToIndex` abstract operation -// https://tc39.es/ecma262/#sec-toindex -module.exports = function (it) { - if (it === undefined) return 0; - var number = toIntegerOrInfinity(it); - var length = toLength(number); - if (number !== length) throw new $RangeError('Wrong length or index'); - return length; -}; - - -/***/ }), - -/***/ 5397: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -// toObject with fallback for non-array-like ES3 strings -var IndexedObject = __webpack_require__(7055); -var requireObjectCoercible = __webpack_require__(7750); - -module.exports = function (it) { - return IndexedObject(requireObjectCoercible(it)); -}; - - -/***/ }), - -/***/ 1291: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var trunc = __webpack_require__(741); - -// `ToIntegerOrInfinity` abstract operation -// https://tc39.es/ecma262/#sec-tointegerorinfinity -module.exports = function (argument) { - var number = +argument; - // eslint-disable-next-line no-self-compare -- NaN check - return number !== number || number === 0 ? 0 : trunc(number); -}; - - -/***/ }), - -/***/ 8014: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toIntegerOrInfinity = __webpack_require__(1291); - -var min = Math.min; - -// `ToLength` abstract operation -// https://tc39.es/ecma262/#sec-tolength -module.exports = function (argument) { - var len = toIntegerOrInfinity(argument); - return len > 0 ? min(len, 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991 -}; - - -/***/ }), - -/***/ 8981: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var requireObjectCoercible = __webpack_require__(7750); - -var $Object = Object; - -// `ToObject` abstract operation -// https://tc39.es/ecma262/#sec-toobject -module.exports = function (argument) { - return $Object(requireObjectCoercible(argument)); -}; - - -/***/ }), - -/***/ 9590: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toIntegerOrInfinity = __webpack_require__(1291); - -var $RangeError = RangeError; - -module.exports = function (it) { - var result = toIntegerOrInfinity(it); - if (result < 0) throw new $RangeError("The argument can't be less than 0"); - return result; -}; - - -/***/ }), - -/***/ 2777: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var call = __webpack_require__(9565); -var isObject = __webpack_require__(34); -var isSymbol = __webpack_require__(757); -var getMethod = __webpack_require__(5966); -var ordinaryToPrimitive = __webpack_require__(4270); -var wellKnownSymbol = __webpack_require__(8227); - -var $TypeError = TypeError; -var TO_PRIMITIVE = wellKnownSymbol('toPrimitive'); - -// `ToPrimitive` abstract operation -// https://tc39.es/ecma262/#sec-toprimitive -module.exports = function (input, pref) { - if (!isObject(input) || isSymbol(input)) return input; - var exoticToPrim = getMethod(input, TO_PRIMITIVE); - var result; - if (exoticToPrim) { - if (pref === undefined) pref = 'default'; - result = call(exoticToPrim, input, pref); - if (!isObject(result) || isSymbol(result)) return result; - throw new $TypeError("Can't convert object to primitive value"); - } - if (pref === undefined) pref = 'number'; - return ordinaryToPrimitive(input, pref); -}; - - -/***/ }), - -/***/ 6969: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var toPrimitive = __webpack_require__(2777); -var isSymbol = __webpack_require__(757); - -// `ToPropertyKey` abstract operation -// https://tc39.es/ecma262/#sec-topropertykey -module.exports = function (argument) { - var key = toPrimitive(argument, 'string'); - return isSymbol(key) ? key : key + ''; -}; - - -/***/ }), - -/***/ 2140: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var wellKnownSymbol = __webpack_require__(8227); - -var TO_STRING_TAG = wellKnownSymbol('toStringTag'); -var test = {}; - -test[TO_STRING_TAG] = 'z'; - -module.exports = String(test) === '[object z]'; - - -/***/ }), - -/***/ 655: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var classof = __webpack_require__(6955); - -var $String = String; - -module.exports = function (argument) { - if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string'); - return $String(argument); -}; - - -/***/ }), - -/***/ 9714: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var IS_NODE = __webpack_require__(9088); - -module.exports = function (name) { - try { - // eslint-disable-next-line no-new-func -- safe - if (IS_NODE) return Function('return require("' + name + '")')(); - } catch (error) { /* empty */ } -}; - - -/***/ }), - -/***/ 6823: -/***/ ((module) => { - - -var $String = String; - -module.exports = function (argument) { - try { - return $String(argument); - } catch (error) { - return 'Object'; - } -}; - - -/***/ }), - -/***/ 3392: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var uncurryThis = __webpack_require__(9504); - -var id = 0; -var postfix = Math.random(); -var toString = uncurryThis(1.0.toString); - -module.exports = function (key) { - return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36); -}; - - -/***/ }), - -/***/ 7040: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -/* eslint-disable es/no-symbol -- required for testing */ -var NATIVE_SYMBOL = __webpack_require__(4495); - -module.exports = NATIVE_SYMBOL - && !Symbol.sham - && typeof Symbol.iterator == 'symbol'; - - -/***/ }), - -/***/ 8686: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var fails = __webpack_require__(9039); - -// V8 ~ Chrome 36- -// https://bugs.chromium.org/p/v8/issues/detail?id=3334 -module.exports = DESCRIPTORS && fails(function () { - // eslint-disable-next-line es/no-object-defineproperty -- required for testing - return Object.defineProperty(function () { /* empty */ }, 'prototype', { - value: 42, - writable: false - }).prototype !== 42; -}); - - -/***/ }), - -/***/ 2812: -/***/ ((module) => { - - -var $TypeError = TypeError; - -module.exports = function (passed, required) { - if (passed < required) throw new $TypeError('Not enough arguments'); - return passed; -}; - - -/***/ }), - -/***/ 8622: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var isCallable = __webpack_require__(4901); - -var WeakMap = global.WeakMap; - -module.exports = isCallable(WeakMap) && /native code/.test(String(WeakMap)); - - -/***/ }), - -/***/ 8227: -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - - -var global = __webpack_require__(4475); -var shared = __webpack_require__(5745); -var hasOwn = __webpack_require__(9297); -var uid = __webpack_require__(3392); -var NATIVE_SYMBOL = __webpack_require__(4495); -var USE_SYMBOL_AS_UID = __webpack_require__(7040); - -var Symbol = global.Symbol; -var WellKnownSymbolsStore = shared('wks'); -var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol['for'] || Symbol : Symbol && Symbol.withoutSetter || uid; - -module.exports = function (name) { - if (!hasOwn(WellKnownSymbolsStore, name)) { - WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn(Symbol, name) - ? Symbol[name] - : createWellKnownSymbol('Symbol.' + name); - } return WellKnownSymbolsStore[name]; -}; - - -/***/ }), - -/***/ 6573: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var defineBuiltInAccessor = __webpack_require__(2106); -var isDetached = __webpack_require__(3238); - -var ArrayBufferPrototype = ArrayBuffer.prototype; - -if (DESCRIPTORS && !('detached' in ArrayBufferPrototype)) { - defineBuiltInAccessor(ArrayBufferPrototype, 'detached', { - configurable: true, - get: function detached() { - return isDetached(this); - } - }); -} - - -/***/ }), - -/***/ 7936: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var $transfer = __webpack_require__(5636); - -// `ArrayBuffer.prototype.transferToFixedLength` method -// https://tc39.es/proposal-arraybuffer-transfer/#sec-arraybuffer.prototype.transfertofixedlength -if ($transfer) $({ target: 'ArrayBuffer', proto: true }, { - transferToFixedLength: function transferToFixedLength() { - return $transfer(this, arguments.length ? arguments[0] : undefined, false); - } -}); - - -/***/ }), - -/***/ 8100: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var $transfer = __webpack_require__(5636); - -// `ArrayBuffer.prototype.transfer` method -// https://tc39.es/proposal-arraybuffer-transfer/#sec-arraybuffer.prototype.transfer -if ($transfer) $({ target: 'ArrayBuffer', proto: true }, { - transfer: function transfer() { - return $transfer(this, arguments.length ? arguments[0] : undefined, true); - } -}); - - -/***/ }), - -/***/ 4114: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var toObject = __webpack_require__(8981); -var lengthOfArrayLike = __webpack_require__(6198); -var setArrayLength = __webpack_require__(4527); -var doesNotExceedSafeInteger = __webpack_require__(6837); -var fails = __webpack_require__(9039); - -var INCORRECT_TO_LENGTH = fails(function () { - return [].push.call({ length: 0x100000000 }, 1) !== 4294967297; -}); - -// V8 <= 121 and Safari <= 15.4; FF < 23 throws InternalError -// https://bugs.chromium.org/p/v8/issues/detail?id=12681 -var properErrorOnNonWritableLength = function () { - try { - // eslint-disable-next-line es/no-object-defineproperty -- safe - Object.defineProperty([], 'length', { writable: false }).push(); - } catch (error) { - return error instanceof TypeError; - } -}; - -var FORCED = INCORRECT_TO_LENGTH || !properErrorOnNonWritableLength(); - -// `Array.prototype.push` method -// https://tc39.es/ecma262/#sec-array.prototype.push -$({ target: 'Array', proto: true, arity: 1, forced: FORCED }, { - // eslint-disable-next-line no-unused-vars -- required for `.length` - push: function push(item) { - var O = toObject(this); - var len = lengthOfArrayLike(O); - var argCount = arguments.length; - doesNotExceedSafeInteger(len + argCount); - for (var i = 0; i < argCount; i++) { - O[len] = arguments[i]; - len++; - } - setArrayLength(O, len); - return len; - } -}); - - -/***/ }), - -/***/ 4628: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var newPromiseCapabilityModule = __webpack_require__(6043); - -// `Promise.withResolvers` method -// https://github.com/tc39/proposal-promise-with-resolvers -$({ target: 'Promise', stat: true }, { - withResolvers: function withResolvers() { - var promiseCapability = newPromiseCapabilityModule.f(this); - return { - promise: promiseCapability.promise, - resolve: promiseCapability.resolve, - reject: promiseCapability.reject - }; - } -}); - - -/***/ }), - -/***/ 7642: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var difference = __webpack_require__(3440); -var setMethodAcceptSetLike = __webpack_require__(4916); - -// `Set.prototype.difference` method -// https://github.com/tc39/proposal-set-methods -$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('difference') }, { - difference: difference -}); - - -/***/ }), - -/***/ 8004: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var fails = __webpack_require__(9039); -var intersection = __webpack_require__(8750); -var setMethodAcceptSetLike = __webpack_require__(4916); - -var INCORRECT = !setMethodAcceptSetLike('intersection') || fails(function () { - // eslint-disable-next-line es/no-array-from, es/no-set -- testing - return String(Array.from(new Set([1, 2, 3]).intersection(new Set([3, 2])))) !== '3,2'; -}); - -// `Set.prototype.intersection` method -// https://github.com/tc39/proposal-set-methods -$({ target: 'Set', proto: true, real: true, forced: INCORRECT }, { - intersection: intersection -}); - - -/***/ }), - -/***/ 3853: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var isDisjointFrom = __webpack_require__(4449); -var setMethodAcceptSetLike = __webpack_require__(4916); - -// `Set.prototype.isDisjointFrom` method -// https://github.com/tc39/proposal-set-methods -$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isDisjointFrom') }, { - isDisjointFrom: isDisjointFrom -}); - - -/***/ }), - -/***/ 5876: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var isSubsetOf = __webpack_require__(3838); -var setMethodAcceptSetLike = __webpack_require__(4916); - -// `Set.prototype.isSubsetOf` method -// https://github.com/tc39/proposal-set-methods -$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isSubsetOf') }, { - isSubsetOf: isSubsetOf -}); - - -/***/ }), - -/***/ 2475: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var isSupersetOf = __webpack_require__(8527); -var setMethodAcceptSetLike = __webpack_require__(4916); - -// `Set.prototype.isSupersetOf` method -// https://github.com/tc39/proposal-set-methods -$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isSupersetOf') }, { - isSupersetOf: isSupersetOf -}); - - -/***/ }), - -/***/ 5024: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var symmetricDifference = __webpack_require__(3650); -var setMethodAcceptSetLike = __webpack_require__(4916); - -// `Set.prototype.symmetricDifference` method -// https://github.com/tc39/proposal-set-methods -$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('symmetricDifference') }, { - symmetricDifference: symmetricDifference -}); - - -/***/ }), - -/***/ 1698: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var union = __webpack_require__(4204); -var setMethodAcceptSetLike = __webpack_require__(4916); - -// `Set.prototype.union` method -// https://github.com/tc39/proposal-set-methods -$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('union') }, { - union: union -}); - - -/***/ }), - -/***/ 7467: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var arrayToReversed = __webpack_require__(7628); -var ArrayBufferViewCore = __webpack_require__(4644); - -var aTypedArray = ArrayBufferViewCore.aTypedArray; -var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod; -var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor; - -// `%TypedArray%.prototype.toReversed` method -// https://tc39.es/ecma262/#sec-%typedarray%.prototype.toreversed -exportTypedArrayMethod('toReversed', function toReversed() { - return arrayToReversed(aTypedArray(this), getTypedArrayConstructor(this)); -}); - - -/***/ }), - -/***/ 4732: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var ArrayBufferViewCore = __webpack_require__(4644); -var uncurryThis = __webpack_require__(9504); -var aCallable = __webpack_require__(9306); -var arrayFromConstructorAndList = __webpack_require__(5370); - -var aTypedArray = ArrayBufferViewCore.aTypedArray; -var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor; -var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod; -var sort = uncurryThis(ArrayBufferViewCore.TypedArrayPrototype.sort); - -// `%TypedArray%.prototype.toSorted` method -// https://tc39.es/ecma262/#sec-%typedarray%.prototype.tosorted -exportTypedArrayMethod('toSorted', function toSorted(compareFn) { - if (compareFn !== undefined) aCallable(compareFn); - var O = aTypedArray(this); - var A = arrayFromConstructorAndList(getTypedArrayConstructor(O), O); - return sort(A, compareFn); -}); - - -/***/ }), - -/***/ 9577: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var arrayWith = __webpack_require__(9928); -var ArrayBufferViewCore = __webpack_require__(4644); -var isBigIntArray = __webpack_require__(1108); -var toIntegerOrInfinity = __webpack_require__(1291); -var toBigInt = __webpack_require__(5854); - -var aTypedArray = ArrayBufferViewCore.aTypedArray; -var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor; -var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod; - -var PROPER_ORDER = !!function () { - try { - // eslint-disable-next-line no-throw-literal, es/no-typed-arrays, es/no-array-prototype-with -- required for testing - new Int8Array(1)['with'](2, { valueOf: function () { throw 8; } }); - } catch (error) { - // some early implementations, like WebKit, does not follow the final semantic - // https://github.com/tc39/proposal-change-array-by-copy/pull/86 - return error === 8; - } -}(); - -// `%TypedArray%.prototype.with` method -// https://tc39.es/ecma262/#sec-%typedarray%.prototype.with -exportTypedArrayMethod('with', { 'with': function (index, value) { - var O = aTypedArray(this); - var relativeIndex = toIntegerOrInfinity(index); - var actualValue = isBigIntArray(O) ? toBigInt(value) : +value; - return arrayWith(O, getTypedArrayConstructor(O), relativeIndex, actualValue); -} }['with'], !PROPER_ORDER); - - -/***/ }), - -/***/ 8992: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var global = __webpack_require__(4475); -var anInstance = __webpack_require__(679); -var anObject = __webpack_require__(8551); -var isCallable = __webpack_require__(4901); -var getPrototypeOf = __webpack_require__(2787); -var defineBuiltInAccessor = __webpack_require__(2106); -var createProperty = __webpack_require__(4659); -var fails = __webpack_require__(9039); -var hasOwn = __webpack_require__(9297); -var wellKnownSymbol = __webpack_require__(8227); -var IteratorPrototype = (__webpack_require__(7657).IteratorPrototype); -var DESCRIPTORS = __webpack_require__(3724); -var IS_PURE = __webpack_require__(6395); - -var CONSTRUCTOR = 'constructor'; -var ITERATOR = 'Iterator'; -var TO_STRING_TAG = wellKnownSymbol('toStringTag'); - -var $TypeError = TypeError; -var NativeIterator = global[ITERATOR]; - -// FF56- have non-standard global helper `Iterator` -var FORCED = IS_PURE - || !isCallable(NativeIterator) - || NativeIterator.prototype !== IteratorPrototype - // FF44- non-standard `Iterator` passes previous tests - || !fails(function () { NativeIterator({}); }); - -var IteratorConstructor = function Iterator() { - anInstance(this, IteratorPrototype); - if (getPrototypeOf(this) === IteratorPrototype) throw new $TypeError('Abstract class Iterator not directly constructable'); -}; - -var defineIteratorPrototypeAccessor = function (key, value) { - if (DESCRIPTORS) { - defineBuiltInAccessor(IteratorPrototype, key, { - configurable: true, - get: function () { - return value; - }, - set: function (replacement) { - anObject(this); - if (this === IteratorPrototype) throw new $TypeError("You can't redefine this property"); - if (hasOwn(this, key)) this[key] = replacement; - else createProperty(this, key, replacement); - } - }); - } else IteratorPrototype[key] = value; -}; - -if (!hasOwn(IteratorPrototype, TO_STRING_TAG)) defineIteratorPrototypeAccessor(TO_STRING_TAG, ITERATOR); - -if (FORCED || !hasOwn(IteratorPrototype, CONSTRUCTOR) || IteratorPrototype[CONSTRUCTOR] === Object) { - defineIteratorPrototypeAccessor(CONSTRUCTOR, IteratorConstructor); -} - -IteratorConstructor.prototype = IteratorPrototype; - -// `Iterator` constructor -// https://github.com/tc39/proposal-iterator-helpers -$({ global: true, constructor: true, forced: FORCED }, { - Iterator: IteratorConstructor -}); - - -/***/ }), - -/***/ 4743: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var call = __webpack_require__(9565); -var anObject = __webpack_require__(8551); -var getIteratorDirect = __webpack_require__(1767); -var notANaN = __webpack_require__(4149); -var toPositiveInteger = __webpack_require__(9590); -var createIteratorProxy = __webpack_require__(9462); -var IS_PURE = __webpack_require__(6395); - -var IteratorProxy = createIteratorProxy(function () { - var iterator = this.iterator; - var next = this.next; - var result, done; - while (this.remaining) { - this.remaining--; - result = anObject(call(next, iterator)); - done = this.done = !!result.done; - if (done) return; - } - result = anObject(call(next, iterator)); - done = this.done = !!result.done; - if (!done) return result.value; -}); - -// `Iterator.prototype.drop` method -// https://github.com/tc39/proposal-iterator-helpers -$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, { - drop: function drop(limit) { - anObject(this); - var remaining = toPositiveInteger(notANaN(+limit)); - return new IteratorProxy(getIteratorDirect(this), { - remaining: remaining - }); - } -}); - - -/***/ }), - -/***/ 3215: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var iterate = __webpack_require__(2652); -var aCallable = __webpack_require__(9306); -var anObject = __webpack_require__(8551); -var getIteratorDirect = __webpack_require__(1767); - -// `Iterator.prototype.every` method -// https://github.com/tc39/proposal-iterator-helpers -$({ target: 'Iterator', proto: true, real: true }, { - every: function every(predicate) { - anObject(this); - aCallable(predicate); - var record = getIteratorDirect(this); - var counter = 0; - return !iterate(record, function (value, stop) { - if (!predicate(value, counter++)) return stop(); - }, { IS_RECORD: true, INTERRUPTED: true }).stopped; - } -}); - - -/***/ }), - -/***/ 4520: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var call = __webpack_require__(9565); -var aCallable = __webpack_require__(9306); -var anObject = __webpack_require__(8551); -var getIteratorDirect = __webpack_require__(1767); -var createIteratorProxy = __webpack_require__(9462); -var callWithSafeIterationClosing = __webpack_require__(6319); -var IS_PURE = __webpack_require__(6395); - -var IteratorProxy = createIteratorProxy(function () { - var iterator = this.iterator; - var predicate = this.predicate; - var next = this.next; - var result, done, value; - while (true) { - result = anObject(call(next, iterator)); - done = this.done = !!result.done; - if (done) return; - value = result.value; - if (callWithSafeIterationClosing(iterator, predicate, [value, this.counter++], true)) return value; - } -}); - -// `Iterator.prototype.filter` method -// https://github.com/tc39/proposal-iterator-helpers -$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, { - filter: function filter(predicate) { - anObject(this); - aCallable(predicate); - return new IteratorProxy(getIteratorDirect(this), { - predicate: predicate - }); - } -}); - - -/***/ }), - -/***/ 670: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var call = __webpack_require__(9565); -var aCallable = __webpack_require__(9306); -var anObject = __webpack_require__(8551); -var getIteratorDirect = __webpack_require__(1767); -var getIteratorFlattenable = __webpack_require__(8646); -var createIteratorProxy = __webpack_require__(9462); -var iteratorClose = __webpack_require__(9539); -var IS_PURE = __webpack_require__(6395); - -var IteratorProxy = createIteratorProxy(function () { - var iterator = this.iterator; - var mapper = this.mapper; - var result, inner; - - while (true) { - if (inner = this.inner) try { - result = anObject(call(inner.next, inner.iterator)); - if (!result.done) return result.value; - this.inner = null; - } catch (error) { iteratorClose(iterator, 'throw', error); } - - result = anObject(call(this.next, iterator)); - - if (this.done = !!result.done) return; - - try { - this.inner = getIteratorFlattenable(mapper(result.value, this.counter++), false); - } catch (error) { iteratorClose(iterator, 'throw', error); } - } -}); - -// `Iterator.prototype.flatMap` method -// https://github.com/tc39/proposal-iterator-helpers -$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, { - flatMap: function flatMap(mapper) { - anObject(this); - aCallable(mapper); - return new IteratorProxy(getIteratorDirect(this), { - mapper: mapper, - inner: null - }); - } -}); - - -/***/ }), - -/***/ 1454: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var map = __webpack_require__(713); -var IS_PURE = __webpack_require__(6395); - -// `Iterator.prototype.map` method -// https://github.com/tc39/proposal-iterator-helpers -$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, { - map: map -}); - - -/***/ }), - -/***/ 7550: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var iterate = __webpack_require__(2652); -var aCallable = __webpack_require__(9306); -var anObject = __webpack_require__(8551); -var getIteratorDirect = __webpack_require__(1767); - -// `Iterator.prototype.some` method -// https://github.com/tc39/proposal-iterator-helpers -$({ target: 'Iterator', proto: true, real: true }, { - some: function some(predicate) { - anObject(this); - aCallable(predicate); - var record = getIteratorDirect(this); - var counter = 0; - return iterate(record, function (value, stop) { - if (predicate(value, counter++)) return stop(); - }, { IS_RECORD: true, INTERRUPTED: true }).stopped; - } -}); - - -/***/ }), - -/***/ 8335: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var DESCRIPTORS = __webpack_require__(3724); -var global = __webpack_require__(4475); -var getBuiltIn = __webpack_require__(7751); -var uncurryThis = __webpack_require__(9504); -var call = __webpack_require__(9565); -var isCallable = __webpack_require__(4901); -var isObject = __webpack_require__(34); -var isArray = __webpack_require__(4376); -var hasOwn = __webpack_require__(9297); -var toString = __webpack_require__(655); -var lengthOfArrayLike = __webpack_require__(6198); -var createProperty = __webpack_require__(4659); -var fails = __webpack_require__(9039); -var parseJSONString = __webpack_require__(8235); -var NATIVE_SYMBOL = __webpack_require__(4495); - -var JSON = global.JSON; -var Number = global.Number; -var SyntaxError = global.SyntaxError; -var nativeParse = JSON && JSON.parse; -var enumerableOwnProperties = getBuiltIn('Object', 'keys'); -// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe -var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; -var at = uncurryThis(''.charAt); -var slice = uncurryThis(''.slice); -var exec = uncurryThis(/./.exec); -var push = uncurryThis([].push); - -var IS_DIGIT = /^\d$/; -var IS_NON_ZERO_DIGIT = /^[1-9]$/; -var IS_NUMBER_START = /^(?:-|\d)$/; -var IS_WHITESPACE = /^[\t\n\r ]$/; - -var PRIMITIVE = 0; -var OBJECT = 1; - -var $parse = function (source, reviver) { - source = toString(source); - var context = new Context(source, 0, ''); - var root = context.parse(); - var value = root.value; - var endIndex = context.skip(IS_WHITESPACE, root.end); - if (endIndex < source.length) { - throw new SyntaxError('Unexpected extra character: "' + at(source, endIndex) + '" after the parsed data at: ' + endIndex); - } - return isCallable(reviver) ? internalize({ '': value }, '', reviver, root) : value; -}; - -var internalize = function (holder, name, reviver, node) { - var val = holder[name]; - var unmodified = node && val === node.value; - var context = unmodified && typeof node.source == 'string' ? { source: node.source } : {}; - var elementRecordsLen, keys, len, i, P; - if (isObject(val)) { - var nodeIsArray = isArray(val); - var nodes = unmodified ? node.nodes : nodeIsArray ? [] : {}; - if (nodeIsArray) { - elementRecordsLen = nodes.length; - len = lengthOfArrayLike(val); - for (i = 0; i < len; i++) { - internalizeProperty(val, i, internalize(val, '' + i, reviver, i < elementRecordsLen ? nodes[i] : undefined)); - } - } else { - keys = enumerableOwnProperties(val); - len = lengthOfArrayLike(keys); - for (i = 0; i < len; i++) { - P = keys[i]; - internalizeProperty(val, P, internalize(val, P, reviver, hasOwn(nodes, P) ? nodes[P] : undefined)); - } - } - } - return call(reviver, holder, name, val, context); -}; - -var internalizeProperty = function (object, key, value) { - if (DESCRIPTORS) { - var descriptor = getOwnPropertyDescriptor(object, key); - if (descriptor && !descriptor.configurable) return; - } - if (value === undefined) delete object[key]; - else createProperty(object, key, value); -}; - -var Node = function (value, end, source, nodes) { - this.value = value; - this.end = end; - this.source = source; - this.nodes = nodes; -}; - -var Context = function (source, index) { - this.source = source; - this.index = index; -}; - -// https://www.json.org/json-en.html -Context.prototype = { - fork: function (nextIndex) { - return new Context(this.source, nextIndex); - }, - parse: function () { - var source = this.source; - var i = this.skip(IS_WHITESPACE, this.index); - var fork = this.fork(i); - var chr = at(source, i); - if (exec(IS_NUMBER_START, chr)) return fork.number(); - switch (chr) { - case '{': - return fork.object(); - case '[': - return fork.array(); - case '"': - return fork.string(); - case 't': - return fork.keyword(true); - case 'f': - return fork.keyword(false); - case 'n': - return fork.keyword(null); - } throw new SyntaxError('Unexpected character: "' + chr + '" at: ' + i); - }, - node: function (type, value, start, end, nodes) { - return new Node(value, end, type ? null : slice(this.source, start, end), nodes); - }, - object: function () { - var source = this.source; - var i = this.index + 1; - var expectKeypair = false; - var object = {}; - var nodes = {}; - while (i < source.length) { - i = this.until(['"', '}'], i); - if (at(source, i) === '}' && !expectKeypair) { - i++; - break; - } - // Parsing the key - var result = this.fork(i).string(); - var key = result.value; - i = result.end; - i = this.until([':'], i) + 1; - // Parsing value - i = this.skip(IS_WHITESPACE, i); - result = this.fork(i).parse(); - createProperty(nodes, key, result); - createProperty(object, key, result.value); - i = this.until([',', '}'], result.end); - var chr = at(source, i); - if (chr === ',') { - expectKeypair = true; - i++; - } else if (chr === '}') { - i++; - break; - } - } - return this.node(OBJECT, object, this.index, i, nodes); - }, - array: function () { - var source = this.source; - var i = this.index + 1; - var expectElement = false; - var array = []; - var nodes = []; - while (i < source.length) { - i = this.skip(IS_WHITESPACE, i); - if (at(source, i) === ']' && !expectElement) { - i++; - break; - } - var result = this.fork(i).parse(); - push(nodes, result); - push(array, result.value); - i = this.until([',', ']'], result.end); - if (at(source, i) === ',') { - expectElement = true; - i++; - } else if (at(source, i) === ']') { - i++; - break; - } - } - return this.node(OBJECT, array, this.index, i, nodes); - }, - string: function () { - var index = this.index; - var parsed = parseJSONString(this.source, this.index + 1); - return this.node(PRIMITIVE, parsed.value, index, parsed.end); - }, - number: function () { - var source = this.source; - var startIndex = this.index; - var i = startIndex; - if (at(source, i) === '-') i++; - if (at(source, i) === '0') i++; - else if (exec(IS_NON_ZERO_DIGIT, at(source, i))) i = this.skip(IS_DIGIT, ++i); - else throw new SyntaxError('Failed to parse number at: ' + i); - if (at(source, i) === '.') i = this.skip(IS_DIGIT, ++i); - if (at(source, i) === 'e' || at(source, i) === 'E') { - i++; - if (at(source, i) === '+' || at(source, i) === '-') i++; - var exponentStartIndex = i; - i = this.skip(IS_DIGIT, i); - if (exponentStartIndex === i) throw new SyntaxError("Failed to parse number's exponent value at: " + i); - } - return this.node(PRIMITIVE, Number(slice(source, startIndex, i)), startIndex, i); - }, - keyword: function (value) { - var keyword = '' + value; - var index = this.index; - var endIndex = index + keyword.length; - if (slice(this.source, index, endIndex) !== keyword) throw new SyntaxError('Failed to parse value at: ' + index); - return this.node(PRIMITIVE, value, index, endIndex); - }, - skip: function (regex, i) { - var source = this.source; - for (; i < source.length; i++) if (!exec(regex, at(source, i))) break; - return i; - }, - until: function (array, i) { - i = this.skip(IS_WHITESPACE, i); - var chr = at(this.source, i); - for (var j = 0; j < array.length; j++) if (array[j] === chr) return i; - throw new SyntaxError('Unexpected character: "' + chr + '" at: ' + i); - } -}; - -var NO_SOURCE_SUPPORT = fails(function () { - var unsafeInt = '9007199254740993'; - var source; - nativeParse(unsafeInt, function (key, value, context) { - source = context.source; - }); - return source !== unsafeInt; -}); - -var PROPER_BASE_PARSE = NATIVE_SYMBOL && !fails(function () { - // Safari 9 bug - return 1 / nativeParse('-0 \t') !== -Infinity; -}); - -// `JSON.parse` method -// https://tc39.es/ecma262/#sec-json.parse -// https://github.com/tc39/proposal-json-parse-with-source -$({ target: 'JSON', stat: true, forced: NO_SOURCE_SUPPORT }, { - parse: function parse(text, reviver) { - return PROPER_BASE_PARSE && !isCallable(reviver) ? nativeParse(text) : $parse(text, reviver); - } -}); - - -/***/ }), - -/***/ 3375: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -// TODO: Remove from `core-js@4` -__webpack_require__(7642); - - -/***/ }), - -/***/ 9225: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -// TODO: Remove from `core-js@4` -__webpack_require__(8004); - - -/***/ }), - -/***/ 3972: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -// TODO: Remove from `core-js@4` -__webpack_require__(3853); - - -/***/ }), - -/***/ 9209: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -// TODO: Remove from `core-js@4` -__webpack_require__(5876); - - -/***/ }), - -/***/ 5714: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -// TODO: Remove from `core-js@4` -__webpack_require__(2475); - - -/***/ }), - -/***/ 7561: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -// TODO: Remove from `core-js@4` -__webpack_require__(5024); - - -/***/ }), - -/***/ 6197: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -// TODO: Remove from `core-js@4` -__webpack_require__(1698); - - -/***/ }), - -/***/ 4979: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var $ = __webpack_require__(6518); -var global = __webpack_require__(4475); -var getBuiltIn = __webpack_require__(7751); -var createPropertyDescriptor = __webpack_require__(6980); -var defineProperty = (__webpack_require__(4913).f); -var hasOwn = __webpack_require__(9297); -var anInstance = __webpack_require__(679); -var inheritIfRequired = __webpack_require__(3167); -var normalizeStringArgument = __webpack_require__(2603); -var DOMExceptionConstants = __webpack_require__(5002); -var clearErrorStack = __webpack_require__(6193); -var DESCRIPTORS = __webpack_require__(3724); -var IS_PURE = __webpack_require__(6395); - -var DOM_EXCEPTION = 'DOMException'; -var Error = getBuiltIn('Error'); -var NativeDOMException = getBuiltIn(DOM_EXCEPTION); - -var $DOMException = function DOMException() { - anInstance(this, DOMExceptionPrototype); - var argumentsLength = arguments.length; - var message = normalizeStringArgument(argumentsLength < 1 ? undefined : arguments[0]); - var name = normalizeStringArgument(argumentsLength < 2 ? undefined : arguments[1], 'Error'); - var that = new NativeDOMException(message, name); - var error = new Error(message); - error.name = DOM_EXCEPTION; - defineProperty(that, 'stack', createPropertyDescriptor(1, clearErrorStack(error.stack, 1))); - inheritIfRequired(that, this, $DOMException); - return that; -}; - -var DOMExceptionPrototype = $DOMException.prototype = NativeDOMException.prototype; - -var ERROR_HAS_STACK = 'stack' in new Error(DOM_EXCEPTION); -var DOM_EXCEPTION_HAS_STACK = 'stack' in new NativeDOMException(1, 2); - -// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe -var descriptor = NativeDOMException && DESCRIPTORS && Object.getOwnPropertyDescriptor(global, DOM_EXCEPTION); - -// Bun ~ 0.1.1 DOMException have incorrect descriptor and we can't redefine it -// https://github.com/Jarred-Sumner/bun/issues/399 -var BUGGY_DESCRIPTOR = !!descriptor && !(descriptor.writable && descriptor.configurable); - -var FORCED_CONSTRUCTOR = ERROR_HAS_STACK && !BUGGY_DESCRIPTOR && !DOM_EXCEPTION_HAS_STACK; - -// `DOMException` constructor patch for `.stack` where it's required -// https://webidl.spec.whatwg.org/#es-DOMException-specialness -$({ global: true, constructor: true, forced: IS_PURE || FORCED_CONSTRUCTOR }, { // TODO: fix export logic - DOMException: FORCED_CONSTRUCTOR ? $DOMException : NativeDOMException -}); - -var PolyfilledDOMException = getBuiltIn(DOM_EXCEPTION); -var PolyfilledDOMExceptionPrototype = PolyfilledDOMException.prototype; - -if (PolyfilledDOMExceptionPrototype.constructor !== PolyfilledDOMException) { - if (!IS_PURE) { - defineProperty(PolyfilledDOMExceptionPrototype, 'constructor', createPropertyDescriptor(1, PolyfilledDOMException)); - } - - for (var key in DOMExceptionConstants) if (hasOwn(DOMExceptionConstants, key)) { - var constant = DOMExceptionConstants[key]; - var constantName = constant.s; - if (!hasOwn(PolyfilledDOMException, constantName)) { - defineProperty(PolyfilledDOMException, constantName, createPropertyDescriptor(6, constant.c)); - } - } -} - - -/***/ }), - -/***/ 4603: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var defineBuiltIn = __webpack_require__(6840); -var uncurryThis = __webpack_require__(9504); -var toString = __webpack_require__(655); -var validateArgumentsLength = __webpack_require__(2812); - -var $URLSearchParams = URLSearchParams; -var URLSearchParamsPrototype = $URLSearchParams.prototype; -var append = uncurryThis(URLSearchParamsPrototype.append); -var $delete = uncurryThis(URLSearchParamsPrototype['delete']); -var forEach = uncurryThis(URLSearchParamsPrototype.forEach); -var push = uncurryThis([].push); -var params = new $URLSearchParams('a=1&a=2&b=3'); - -params['delete']('a', 1); -// `undefined` case is a Chromium 117 bug -// https://bugs.chromium.org/p/v8/issues/detail?id=14222 -params['delete']('b', undefined); - -if (params + '' !== 'a=2') { - defineBuiltIn(URLSearchParamsPrototype, 'delete', function (name /* , value */) { - var length = arguments.length; - var $value = length < 2 ? undefined : arguments[1]; - if (length && $value === undefined) return $delete(this, name); - var entries = []; - forEach(this, function (v, k) { // also validates `this` - push(entries, { key: k, value: v }); - }); - validateArgumentsLength(length, 1); - var key = toString(name); - var value = toString($value); - var index = 0; - var dindex = 0; - var found = false; - var entriesLength = entries.length; - var entry; - while (index < entriesLength) { - entry = entries[index++]; - if (found || entry.key === key) { - found = true; - $delete(this, entry.key); - } else dindex++; - } - while (dindex < entriesLength) { - entry = entries[dindex++]; - if (!(entry.key === key && entry.value === value)) append(this, entry.key, entry.value); - } - }, { enumerable: true, unsafe: true }); -} - - -/***/ }), - -/***/ 7566: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var defineBuiltIn = __webpack_require__(6840); -var uncurryThis = __webpack_require__(9504); -var toString = __webpack_require__(655); -var validateArgumentsLength = __webpack_require__(2812); - -var $URLSearchParams = URLSearchParams; -var URLSearchParamsPrototype = $URLSearchParams.prototype; -var getAll = uncurryThis(URLSearchParamsPrototype.getAll); -var $has = uncurryThis(URLSearchParamsPrototype.has); -var params = new $URLSearchParams('a=1'); - -// `undefined` case is a Chromium 117 bug -// https://bugs.chromium.org/p/v8/issues/detail?id=14222 -if (params.has('a', 2) || !params.has('a', undefined)) { - defineBuiltIn(URLSearchParamsPrototype, 'has', function has(name /* , value */) { - var length = arguments.length; - var $value = length < 2 ? undefined : arguments[1]; - if (length && $value === undefined) return $has(this, name); - var values = getAll(this, name); // also validates `this` - validateArgumentsLength(length, 1); - var value = toString($value); - var index = 0; - while (index < values.length) { - if (values[index++] === value) return true; - } return false; - }, { enumerable: true, unsafe: true }); -} - - -/***/ }), - -/***/ 8721: -/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { - - -var DESCRIPTORS = __webpack_require__(3724); -var uncurryThis = __webpack_require__(9504); -var defineBuiltInAccessor = __webpack_require__(2106); - -var URLSearchParamsPrototype = URLSearchParams.prototype; -var forEach = uncurryThis(URLSearchParamsPrototype.forEach); - -// `URLSearchParams.prototype.size` getter -// https://github.com/whatwg/url/pull/734 -if (DESCRIPTORS && !('size' in URLSearchParamsPrototype)) { - defineBuiltInAccessor(URLSearchParamsPrototype, 'size', { - get: function size() { - var count = 0; - forEach(this, function () { count++; }); - return count; - }, - configurable: true, - enumerable: true - }); -} - - -/***/ }) - -/******/ }); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/define property getters */ -/******/ (() => { -/******/ // define getter functions for harmony exports -/******/ __webpack_require__.d = (exports, definition) => { -/******/ for(var key in definition) { -/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { -/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); -/******/ } -/******/ } -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = globalThis.pdfjsLib = {}; -// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. -(() => { - -// EXPORTS -__webpack_require__.d(__webpack_exports__, { - AbortException: () => (/* reexport */ AbortException), - AnnotationEditorLayer: () => (/* reexport */ AnnotationEditorLayer), - AnnotationEditorParamsType: () => (/* reexport */ AnnotationEditorParamsType), - AnnotationEditorType: () => (/* reexport */ AnnotationEditorType), - AnnotationEditorUIManager: () => (/* reexport */ AnnotationEditorUIManager), - AnnotationLayer: () => (/* reexport */ AnnotationLayer), - AnnotationMode: () => (/* reexport */ AnnotationMode), - CMapCompressionType: () => (/* reexport */ CMapCompressionType), - ColorPicker: () => (/* reexport */ ColorPicker), - DOMSVGFactory: () => (/* reexport */ DOMSVGFactory), - DrawLayer: () => (/* reexport */ DrawLayer), - FeatureTest: () => (/* reexport */ util_FeatureTest), - GlobalWorkerOptions: () => (/* reexport */ GlobalWorkerOptions), - ImageKind: () => (/* reexport */ util_ImageKind), - InvalidPDFException: () => (/* reexport */ InvalidPDFException), - MissingPDFException: () => (/* reexport */ MissingPDFException), - OPS: () => (/* reexport */ OPS), - Outliner: () => (/* reexport */ Outliner), - PDFDataRangeTransport: () => (/* reexport */ PDFDataRangeTransport), - PDFDateString: () => (/* reexport */ PDFDateString), - PDFWorker: () => (/* reexport */ PDFWorker), - PasswordResponses: () => (/* reexport */ PasswordResponses), - PermissionFlag: () => (/* reexport */ PermissionFlag), - PixelsPerInch: () => (/* reexport */ PixelsPerInch), - RenderingCancelledException: () => (/* reexport */ RenderingCancelledException), - TextLayer: () => (/* reexport */ TextLayer), - UnexpectedResponseException: () => (/* reexport */ UnexpectedResponseException), - Util: () => (/* reexport */ Util), - VerbosityLevel: () => (/* reexport */ VerbosityLevel), - XfaLayer: () => (/* reexport */ XfaLayer), - build: () => (/* reexport */ build), - createValidAbsoluteUrl: () => (/* reexport */ createValidAbsoluteUrl), - fetchData: () => (/* reexport */ fetchData), - getDocument: () => (/* reexport */ getDocument), - getFilenameFromUrl: () => (/* reexport */ getFilenameFromUrl), - getPdfFilenameFromUrl: () => (/* reexport */ getPdfFilenameFromUrl), - getXfaPageViewport: () => (/* reexport */ getXfaPageViewport), - isDataScheme: () => (/* reexport */ isDataScheme), - isPdfFile: () => (/* reexport */ isPdfFile), - noContextMenu: () => (/* reexport */ noContextMenu), - normalizeUnicode: () => (/* reexport */ normalizeUnicode), - renderTextLayer: () => (/* reexport */ renderTextLayer), - setLayerDimensions: () => (/* reexport */ setLayerDimensions), - shadow: () => (/* reexport */ shadow), - updateTextLayer: () => (/* reexport */ updateTextLayer), - version: () => (/* reexport */ version) -}); - -// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js -var es_array_push = __webpack_require__(4114); -// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array-buffer.detached.js -var es_array_buffer_detached = __webpack_require__(6573); -// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array-buffer.transfer.js -var es_array_buffer_transfer = __webpack_require__(8100); -// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array-buffer.transfer-to-fixed-length.js -var es_array_buffer_transfer_to_fixed_length = __webpack_require__(7936); -// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-reversed.js -var es_typed_array_to_reversed = __webpack_require__(7467); -// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-sorted.js -var es_typed_array_to_sorted = __webpack_require__(4732); -// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.with.js -var es_typed_array_with = __webpack_require__(9577); -// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.delete.js -var web_url_search_params_delete = __webpack_require__(4603); -// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.has.js -var web_url_search_params_has = __webpack_require__(7566); -// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.size.js -var web_url_search_params_size = __webpack_require__(8721); -;// CONCATENATED MODULE: ./src/shared/util.js - - - - - - - - - - -const isNodeJS = typeof process === "object" && process + "" === "[object process]" && !process.versions.nw && !(process.versions.electron && process.type && process.type !== "browser"); -const IDENTITY_MATRIX = [1, 0, 0, 1, 0, 0]; -const FONT_IDENTITY_MATRIX = [0.001, 0, 0, 0.001, 0, 0]; -const MAX_IMAGE_SIZE_TO_CACHE = 10e6; -const LINE_FACTOR = 1.35; -const LINE_DESCENT_FACTOR = 0.35; -const BASELINE_FACTOR = LINE_DESCENT_FACTOR / LINE_FACTOR; -const RenderingIntentFlag = { - ANY: 0x01, - DISPLAY: 0x02, - PRINT: 0x04, - SAVE: 0x08, - ANNOTATIONS_FORMS: 0x10, - ANNOTATIONS_STORAGE: 0x20, - ANNOTATIONS_DISABLE: 0x40, - OPLIST: 0x100 -}; -const AnnotationMode = { - DISABLE: 0, - ENABLE: 1, - ENABLE_FORMS: 2, - ENABLE_STORAGE: 3 -}; -const AnnotationEditorPrefix = "pdfjs_internal_editor_"; -const AnnotationEditorType = { - DISABLE: -1, - NONE: 0, - FREETEXT: 3, - HIGHLIGHT: 9, - STAMP: 13, - INK: 15 -}; -const AnnotationEditorParamsType = { - RESIZE: 1, - CREATE: 2, - FREETEXT_SIZE: 11, - FREETEXT_COLOR: 12, - FREETEXT_OPACITY: 13, - INK_COLOR: 21, - INK_THICKNESS: 22, - INK_OPACITY: 23, - HIGHLIGHT_COLOR: 31, - HIGHLIGHT_DEFAULT_COLOR: 32, - HIGHLIGHT_THICKNESS: 33, - HIGHLIGHT_FREE: 34, - HIGHLIGHT_SHOW_ALL: 35 -}; -const PermissionFlag = { - PRINT: 0x04, - MODIFY_CONTENTS: 0x08, - COPY: 0x10, - MODIFY_ANNOTATIONS: 0x20, - FILL_INTERACTIVE_FORMS: 0x100, - COPY_FOR_ACCESSIBILITY: 0x200, - ASSEMBLE: 0x400, - PRINT_HIGH_QUALITY: 0x800 -}; -const TextRenderingMode = { - FILL: 0, - STROKE: 1, - FILL_STROKE: 2, - INVISIBLE: 3, - FILL_ADD_TO_PATH: 4, - STROKE_ADD_TO_PATH: 5, - FILL_STROKE_ADD_TO_PATH: 6, - ADD_TO_PATH: 7, - FILL_STROKE_MASK: 3, - ADD_TO_PATH_FLAG: 4 -}; -const util_ImageKind = { - GRAYSCALE_1BPP: 1, - RGB_24BPP: 2, - RGBA_32BPP: 3 -}; -const AnnotationType = { - TEXT: 1, - LINK: 2, - FREETEXT: 3, - LINE: 4, - SQUARE: 5, - CIRCLE: 6, - POLYGON: 7, - POLYLINE: 8, - HIGHLIGHT: 9, - UNDERLINE: 10, - SQUIGGLY: 11, - STRIKEOUT: 12, - STAMP: 13, - CARET: 14, - INK: 15, - POPUP: 16, - FILEATTACHMENT: 17, - SOUND: 18, - MOVIE: 19, - WIDGET: 20, - SCREEN: 21, - PRINTERMARK: 22, - TRAPNET: 23, - WATERMARK: 24, - THREED: 25, - REDACT: 26 -}; -const AnnotationReplyType = { - GROUP: "Group", - REPLY: "R" -}; -const AnnotationFlag = { - INVISIBLE: 0x01, - HIDDEN: 0x02, - PRINT: 0x04, - NOZOOM: 0x08, - NOROTATE: 0x10, - NOVIEW: 0x20, - READONLY: 0x40, - LOCKED: 0x80, - TOGGLENOVIEW: 0x100, - LOCKEDCONTENTS: 0x200 -}; -const AnnotationFieldFlag = { - READONLY: 0x0000001, - REQUIRED: 0x0000002, - NOEXPORT: 0x0000004, - MULTILINE: 0x0001000, - PASSWORD: 0x0002000, - NOTOGGLETOOFF: 0x0004000, - RADIO: 0x0008000, - PUSHBUTTON: 0x0010000, - COMBO: 0x0020000, - EDIT: 0x0040000, - SORT: 0x0080000, - FILESELECT: 0x0100000, - MULTISELECT: 0x0200000, - DONOTSPELLCHECK: 0x0400000, - DONOTSCROLL: 0x0800000, - COMB: 0x1000000, - RICHTEXT: 0x2000000, - RADIOSINUNISON: 0x2000000, - COMMITONSELCHANGE: 0x4000000 -}; -const AnnotationBorderStyleType = { - SOLID: 1, - DASHED: 2, - BEVELED: 3, - INSET: 4, - UNDERLINE: 5 -}; -const AnnotationActionEventType = { - E: "Mouse Enter", - X: "Mouse Exit", - D: "Mouse Down", - U: "Mouse Up", - Fo: "Focus", - Bl: "Blur", - PO: "PageOpen", - PC: "PageClose", - PV: "PageVisible", - PI: "PageInvisible", - K: "Keystroke", - F: "Format", - V: "Validate", - C: "Calculate" -}; -const DocumentActionEventType = { - WC: "WillClose", - WS: "WillSave", - DS: "DidSave", - WP: "WillPrint", - DP: "DidPrint" -}; -const PageActionEventType = { - O: "PageOpen", - C: "PageClose" -}; -const VerbosityLevel = { - ERRORS: 0, - WARNINGS: 1, - INFOS: 5 -}; -const CMapCompressionType = { - NONE: 0, - BINARY: 1 -}; -const OPS = { - dependency: 1, - setLineWidth: 2, - setLineCap: 3, - setLineJoin: 4, - setMiterLimit: 5, - setDash: 6, - setRenderingIntent: 7, - setFlatness: 8, - setGState: 9, - save: 10, - restore: 11, - transform: 12, - moveTo: 13, - lineTo: 14, - curveTo: 15, - curveTo2: 16, - curveTo3: 17, - closePath: 18, - rectangle: 19, - stroke: 20, - closeStroke: 21, - fill: 22, - eoFill: 23, - fillStroke: 24, - eoFillStroke: 25, - closeFillStroke: 26, - closeEOFillStroke: 27, - endPath: 28, - clip: 29, - eoClip: 30, - beginText: 31, - endText: 32, - setCharSpacing: 33, - setWordSpacing: 34, - setHScale: 35, - setLeading: 36, - setFont: 37, - setTextRenderingMode: 38, - setTextRise: 39, - moveText: 40, - setLeadingMoveText: 41, - setTextMatrix: 42, - nextLine: 43, - showText: 44, - showSpacedText: 45, - nextLineShowText: 46, - nextLineSetSpacingShowText: 47, - setCharWidth: 48, - setCharWidthAndBounds: 49, - setStrokeColorSpace: 50, - setFillColorSpace: 51, - setStrokeColor: 52, - setStrokeColorN: 53, - setFillColor: 54, - setFillColorN: 55, - setStrokeGray: 56, - setFillGray: 57, - setStrokeRGBColor: 58, - setFillRGBColor: 59, - setStrokeCMYKColor: 60, - setFillCMYKColor: 61, - shadingFill: 62, - beginInlineImage: 63, - beginImageData: 64, - endInlineImage: 65, - paintXObject: 66, - markPoint: 67, - markPointProps: 68, - beginMarkedContent: 69, - beginMarkedContentProps: 70, - endMarkedContent: 71, - beginCompat: 72, - endCompat: 73, - paintFormXObjectBegin: 74, - paintFormXObjectEnd: 75, - beginGroup: 76, - endGroup: 77, - beginAnnotation: 80, - endAnnotation: 81, - paintImageMaskXObject: 83, - paintImageMaskXObjectGroup: 84, - paintImageXObject: 85, - paintInlineImageXObject: 86, - paintInlineImageXObjectGroup: 87, - paintImageXObjectRepeat: 88, - paintImageMaskXObjectRepeat: 89, - paintSolidColorImageMask: 90, - constructPath: 91 -}; -const PasswordResponses = { - NEED_PASSWORD: 1, - INCORRECT_PASSWORD: 2 -}; -let verbosity = VerbosityLevel.WARNINGS; -function setVerbosityLevel(level) { - if (Number.isInteger(level)) { - verbosity = level; - } -} -function getVerbosityLevel() { - return verbosity; -} -function info(msg) { - if (verbosity >= VerbosityLevel.INFOS) { - console.log(`Info: ${msg}`); - } -} -function warn(msg) { - if (verbosity >= VerbosityLevel.WARNINGS) { - console.log(`Warning: ${msg}`); - } -} -function unreachable(msg) { - throw new Error(msg); -} -function assert(cond, msg) { - if (!cond) { - unreachable(msg); - } -} -function _isValidProtocol(url) { - switch (url?.protocol) { - case "http:": - case "https:": - case "ftp:": - case "mailto:": - case "tel:": - return true; - default: - return false; - } -} -function createValidAbsoluteUrl(url, baseUrl = null, options = null) { - if (!url) { - return null; - } - try { - if (options && typeof url === "string") { - if (options.addDefaultProtocol && url.startsWith("www.")) { - const dots = url.match(/\./g); - if (dots?.length >= 2) { - url = `http://${url}`; - } - } - if (options.tryConvertEncoding) { - try { - url = stringToUTF8String(url); - } catch {} - } - } - const absoluteUrl = baseUrl ? new URL(url, baseUrl) : new URL(url); - if (_isValidProtocol(absoluteUrl)) { - return absoluteUrl; - } - } catch {} - return null; -} -function shadow(obj, prop, value, nonSerializable = false) { - Object.defineProperty(obj, prop, { - value, - enumerable: !nonSerializable, - configurable: true, - writable: false - }); - return value; -} -const BaseException = function BaseExceptionClosure() { - function BaseException(message, name) { - if (this.constructor === BaseException) { - unreachable("Cannot initialize BaseException."); - } - this.message = message; - this.name = name; - } - BaseException.prototype = new Error(); - BaseException.constructor = BaseException; - return BaseException; -}(); -class PasswordException extends BaseException { - constructor(msg, code) { - super(msg, "PasswordException"); - this.code = code; - } -} -class UnknownErrorException extends BaseException { - constructor(msg, details) { - super(msg, "UnknownErrorException"); - this.details = details; - } -} -class InvalidPDFException extends BaseException { - constructor(msg) { - super(msg, "InvalidPDFException"); - } -} -class MissingPDFException extends BaseException { - constructor(msg) { - super(msg, "MissingPDFException"); - } -} -class UnexpectedResponseException extends BaseException { - constructor(msg, status) { - super(msg, "UnexpectedResponseException"); - this.status = status; - } -} -class FormatError extends BaseException { - constructor(msg) { - super(msg, "FormatError"); - } -} -class AbortException extends BaseException { - constructor(msg) { - super(msg, "AbortException"); - } -} -function bytesToString(bytes) { - if (typeof bytes !== "object" || bytes?.length === undefined) { - unreachable("Invalid argument for bytesToString"); - } - const length = bytes.length; - const MAX_ARGUMENT_COUNT = 8192; - if (length < MAX_ARGUMENT_COUNT) { - return String.fromCharCode.apply(null, bytes); - } - const strBuf = []; - for (let i = 0; i < length; i += MAX_ARGUMENT_COUNT) { - const chunkEnd = Math.min(i + MAX_ARGUMENT_COUNT, length); - const chunk = bytes.subarray(i, chunkEnd); - strBuf.push(String.fromCharCode.apply(null, chunk)); - } - return strBuf.join(""); -} -function stringToBytes(str) { - if (typeof str !== "string") { - unreachable("Invalid argument for stringToBytes"); - } - const length = str.length; - const bytes = new Uint8Array(length); - for (let i = 0; i < length; ++i) { - bytes[i] = str.charCodeAt(i) & 0xff; - } - return bytes; -} -function string32(value) { - return String.fromCharCode(value >> 24 & 0xff, value >> 16 & 0xff, value >> 8 & 0xff, value & 0xff); -} -function objectSize(obj) { - return Object.keys(obj).length; -} -function objectFromMap(map) { - const obj = Object.create(null); - for (const [key, value] of map) { - obj[key] = value; - } - return obj; -} -function isLittleEndian() { - const buffer8 = new Uint8Array(4); - buffer8[0] = 1; - const view32 = new Uint32Array(buffer8.buffer, 0, 1); - return view32[0] === 1; -} -function isEvalSupported() { - try { - new Function(""); - return true; - } catch { - return false; - } -} -class util_FeatureTest { - static get isLittleEndian() { - return shadow(this, "isLittleEndian", isLittleEndian()); - } - static get isEvalSupported() { - return shadow(this, "isEvalSupported", isEvalSupported()); - } - static get isOffscreenCanvasSupported() { - return shadow(this, "isOffscreenCanvasSupported", typeof OffscreenCanvas !== "undefined"); - } - static get platform() { - if (typeof navigator !== "undefined" && typeof navigator?.platform === "string") { - return shadow(this, "platform", { - isMac: navigator.platform.includes("Mac") - }); - } - return shadow(this, "platform", { - isMac: false - }); - } - static get isCSSRoundSupported() { - return shadow(this, "isCSSRoundSupported", globalThis.CSS?.supports?.("width: round(1.5px, 1px)")); - } -} -const hexNumbers = Array.from(Array(256).keys(), n => n.toString(16).padStart(2, "0")); -class Util { - static makeHexColor(r, g, b) { - return `#${hexNumbers[r]}${hexNumbers[g]}${hexNumbers[b]}`; - } - static scaleMinMax(transform, minMax) { - let temp; - if (transform[0]) { - if (transform[0] < 0) { - temp = minMax[0]; - minMax[0] = minMax[2]; - minMax[2] = temp; - } - minMax[0] *= transform[0]; - minMax[2] *= transform[0]; - if (transform[3] < 0) { - temp = minMax[1]; - minMax[1] = minMax[3]; - minMax[3] = temp; - } - minMax[1] *= transform[3]; - minMax[3] *= transform[3]; - } else { - temp = minMax[0]; - minMax[0] = minMax[1]; - minMax[1] = temp; - temp = minMax[2]; - minMax[2] = minMax[3]; - minMax[3] = temp; - if (transform[1] < 0) { - temp = minMax[1]; - minMax[1] = minMax[3]; - minMax[3] = temp; - } - minMax[1] *= transform[1]; - minMax[3] *= transform[1]; - if (transform[2] < 0) { - temp = minMax[0]; - minMax[0] = minMax[2]; - minMax[2] = temp; - } - minMax[0] *= transform[2]; - minMax[2] *= transform[2]; - } - minMax[0] += transform[4]; - minMax[1] += transform[5]; - minMax[2] += transform[4]; - minMax[3] += transform[5]; - } - static transform(m1, m2) { - return [m1[0] * m2[0] + m1[2] * m2[1], m1[1] * m2[0] + m1[3] * m2[1], m1[0] * m2[2] + m1[2] * m2[3], m1[1] * m2[2] + m1[3] * m2[3], m1[0] * m2[4] + m1[2] * m2[5] + m1[4], m1[1] * m2[4] + m1[3] * m2[5] + m1[5]]; - } - static applyTransform(p, m) { - const xt = p[0] * m[0] + p[1] * m[2] + m[4]; - const yt = p[0] * m[1] + p[1] * m[3] + m[5]; - return [xt, yt]; - } - static applyInverseTransform(p, m) { - const d = m[0] * m[3] - m[1] * m[2]; - const xt = (p[0] * m[3] - p[1] * m[2] + m[2] * m[5] - m[4] * m[3]) / d; - const yt = (-p[0] * m[1] + p[1] * m[0] + m[4] * m[1] - m[5] * m[0]) / d; - return [xt, yt]; - } - static getAxialAlignedBoundingBox(r, m) { - const p1 = this.applyTransform(r, m); - const p2 = this.applyTransform(r.slice(2, 4), m); - const p3 = this.applyTransform([r[0], r[3]], m); - const p4 = this.applyTransform([r[2], r[1]], m); - return [Math.min(p1[0], p2[0], p3[0], p4[0]), Math.min(p1[1], p2[1], p3[1], p4[1]), Math.max(p1[0], p2[0], p3[0], p4[0]), Math.max(p1[1], p2[1], p3[1], p4[1])]; - } - static inverseTransform(m) { - const d = m[0] * m[3] - m[1] * m[2]; - return [m[3] / d, -m[1] / d, -m[2] / d, m[0] / d, (m[2] * m[5] - m[4] * m[3]) / d, (m[4] * m[1] - m[5] * m[0]) / d]; - } - static singularValueDecompose2dScale(m) { - const transpose = [m[0], m[2], m[1], m[3]]; - const a = m[0] * transpose[0] + m[1] * transpose[2]; - const b = m[0] * transpose[1] + m[1] * transpose[3]; - const c = m[2] * transpose[0] + m[3] * transpose[2]; - const d = m[2] * transpose[1] + m[3] * transpose[3]; - const first = (a + d) / 2; - const second = Math.sqrt((a + d) ** 2 - 4 * (a * d - c * b)) / 2; - const sx = first + second || 1; - const sy = first - second || 1; - return [Math.sqrt(sx), Math.sqrt(sy)]; - } - static normalizeRect(rect) { - const r = rect.slice(0); - if (rect[0] > rect[2]) { - r[0] = rect[2]; - r[2] = rect[0]; - } - if (rect[1] > rect[3]) { - r[1] = rect[3]; - r[3] = rect[1]; - } - return r; - } - static intersect(rect1, rect2) { - const xLow = Math.max(Math.min(rect1[0], rect1[2]), Math.min(rect2[0], rect2[2])); - const xHigh = Math.min(Math.max(rect1[0], rect1[2]), Math.max(rect2[0], rect2[2])); - if (xLow > xHigh) { - return null; - } - const yLow = Math.max(Math.min(rect1[1], rect1[3]), Math.min(rect2[1], rect2[3])); - const yHigh = Math.min(Math.max(rect1[1], rect1[3]), Math.max(rect2[1], rect2[3])); - if (yLow > yHigh) { - return null; - } - return [xLow, yLow, xHigh, yHigh]; - } - static #getExtremumOnCurve(x0, x1, x2, x3, y0, y1, y2, y3, t, minMax) { - if (t <= 0 || t >= 1) { - return; - } - const mt = 1 - t; - const tt = t * t; - const ttt = tt * t; - const x = mt * (mt * (mt * x0 + 3 * t * x1) + 3 * tt * x2) + ttt * x3; - const y = mt * (mt * (mt * y0 + 3 * t * y1) + 3 * tt * y2) + ttt * y3; - minMax[0] = Math.min(minMax[0], x); - minMax[1] = Math.min(minMax[1], y); - minMax[2] = Math.max(minMax[2], x); - minMax[3] = Math.max(minMax[3], y); - } - static #getExtremum(x0, x1, x2, x3, y0, y1, y2, y3, a, b, c, minMax) { - if (Math.abs(a) < 1e-12) { - if (Math.abs(b) >= 1e-12) { - this.#getExtremumOnCurve(x0, x1, x2, x3, y0, y1, y2, y3, -c / b, minMax); - } - return; - } - const delta = b ** 2 - 4 * c * a; - if (delta < 0) { - return; - } - const sqrtDelta = Math.sqrt(delta); - const a2 = 2 * a; - this.#getExtremumOnCurve(x0, x1, x2, x3, y0, y1, y2, y3, (-b + sqrtDelta) / a2, minMax); - this.#getExtremumOnCurve(x0, x1, x2, x3, y0, y1, y2, y3, (-b - sqrtDelta) / a2, minMax); - } - static bezierBoundingBox(x0, y0, x1, y1, x2, y2, x3, y3, minMax) { - if (minMax) { - minMax[0] = Math.min(minMax[0], x0, x3); - minMax[1] = Math.min(minMax[1], y0, y3); - minMax[2] = Math.max(minMax[2], x0, x3); - minMax[3] = Math.max(minMax[3], y0, y3); - } else { - minMax = [Math.min(x0, x3), Math.min(y0, y3), Math.max(x0, x3), Math.max(y0, y3)]; - } - this.#getExtremum(x0, x1, x2, x3, y0, y1, y2, y3, 3 * (-x0 + 3 * (x1 - x2) + x3), 6 * (x0 - 2 * x1 + x2), 3 * (x1 - x0), minMax); - this.#getExtremum(x0, x1, x2, x3, y0, y1, y2, y3, 3 * (-y0 + 3 * (y1 - y2) + y3), 6 * (y0 - 2 * y1 + y2), 3 * (y1 - y0), minMax); - return minMax; - } -} -const PDFStringTranslateTable = (/* unused pure expression or super */ null && ([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x2d8, 0x2c7, 0x2c6, 0x2d9, 0x2dd, 0x2db, 0x2da, 0x2dc, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x2022, 0x2020, 0x2021, 0x2026, 0x2014, 0x2013, 0x192, 0x2044, 0x2039, 0x203a, 0x2212, 0x2030, 0x201e, 0x201c, 0x201d, 0x2018, 0x2019, 0x201a, 0x2122, 0xfb01, 0xfb02, 0x141, 0x152, 0x160, 0x178, 0x17d, 0x131, 0x142, 0x153, 0x161, 0x17e, 0, 0x20ac])); -function stringToPDFString(str) { - if (str[0] >= "\xEF") { - let encoding; - if (str[0] === "\xFE" && str[1] === "\xFF") { - encoding = "utf-16be"; - if (str.length % 2 === 1) { - str = str.slice(0, -1); - } - } else if (str[0] === "\xFF" && str[1] === "\xFE") { - encoding = "utf-16le"; - if (str.length % 2 === 1) { - str = str.slice(0, -1); - } - } else if (str[0] === "\xEF" && str[1] === "\xBB" && str[2] === "\xBF") { - encoding = "utf-8"; - } - if (encoding) { - try { - const decoder = new TextDecoder(encoding, { - fatal: true - }); - const buffer = stringToBytes(str); - const decoded = decoder.decode(buffer); - if (!decoded.includes("\x1b")) { - return decoded; - } - return decoded.replaceAll(/\x1b[^\x1b]*(?:\x1b|$)/g, ""); - } catch (ex) { - warn(`stringToPDFString: "${ex}".`); - } - } - } - const strBuf = []; - for (let i = 0, ii = str.length; i < ii; i++) { - const charCode = str.charCodeAt(i); - if (charCode === 0x1b) { - while (++i < ii && str.charCodeAt(i) !== 0x1b) {} - continue; - } - const code = PDFStringTranslateTable[charCode]; - strBuf.push(code ? String.fromCharCode(code) : str.charAt(i)); - } - return strBuf.join(""); -} -function stringToUTF8String(str) { - return decodeURIComponent(escape(str)); -} -function utf8StringToString(str) { - return unescape(encodeURIComponent(str)); -} -function isArrayEqual(arr1, arr2) { - if (arr1.length !== arr2.length) { - return false; - } - for (let i = 0, ii = arr1.length; i < ii; i++) { - if (arr1[i] !== arr2[i]) { - return false; - } - } - return true; -} -function getModificationDate(date = new Date()) { - const buffer = [date.getUTCFullYear().toString(), (date.getUTCMonth() + 1).toString().padStart(2, "0"), date.getUTCDate().toString().padStart(2, "0"), date.getUTCHours().toString().padStart(2, "0"), date.getUTCMinutes().toString().padStart(2, "0"), date.getUTCSeconds().toString().padStart(2, "0")]; - return buffer.join(""); -} -let NormalizeRegex = null; -let NormalizationMap = null; -function normalizeUnicode(str) { - if (!NormalizeRegex) { - NormalizeRegex = /([\u00a0\u00b5\u037e\u0eb3\u2000-\u200a\u202f\u2126\ufb00-\ufb04\ufb06\ufb20-\ufb36\ufb38-\ufb3c\ufb3e\ufb40-\ufb41\ufb43-\ufb44\ufb46-\ufba1\ufba4-\ufba9\ufbae-\ufbb1\ufbd3-\ufbdc\ufbde-\ufbe7\ufbea-\ufbf8\ufbfc-\ufbfd\ufc00-\ufc5d\ufc64-\ufcf1\ufcf5-\ufd3d\ufd88\ufdf4\ufdfa-\ufdfb\ufe71\ufe77\ufe79\ufe7b\ufe7d]+)|(\ufb05+)/gu; - NormalizationMap = new Map([["ſt", "ſt"]]); - } - return str.replaceAll(NormalizeRegex, (_, p1, p2) => p1 ? p1.normalize("NFKC") : NormalizationMap.get(p2)); -} -function getUuid() { - if (typeof crypto !== "undefined" && typeof crypto?.randomUUID === "function") { - return crypto.randomUUID(); - } - const buf = new Uint8Array(32); - if (typeof crypto !== "undefined" && typeof crypto?.getRandomValues === "function") { - crypto.getRandomValues(buf); - } else { - for (let i = 0; i < 32; i++) { - buf[i] = Math.floor(Math.random() * 255); - } - } - return bytesToString(buf); -} -const AnnotationPrefix = "pdfjs_internal_id_"; -const FontRenderOps = { - BEZIER_CURVE_TO: 0, - MOVE_TO: 1, - LINE_TO: 2, - QUADRATIC_CURVE_TO: 3, - RESTORE: 4, - SAVE: 5, - SCALE: 6, - TRANSFORM: 7, - TRANSLATE: 8 -}; - -// EXTERNAL MODULE: ./node_modules/core-js/modules/es.promise.with-resolvers.js -var es_promise_with_resolvers = __webpack_require__(4628); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.map.js -var esnext_iterator_map = __webpack_require__(1454); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.set.difference.v2.js -var esnext_set_difference_v2 = __webpack_require__(3375); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.set.intersection.v2.js -var esnext_set_intersection_v2 = __webpack_require__(9225); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.set.is-disjoint-from.v2.js -var esnext_set_is_disjoint_from_v2 = __webpack_require__(3972); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.set.is-subset-of.v2.js -var esnext_set_is_subset_of_v2 = __webpack_require__(9209); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.set.is-superset-of.v2.js -var esnext_set_is_superset_of_v2 = __webpack_require__(5714); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.set.symmetric-difference.v2.js -var esnext_set_symmetric_difference_v2 = __webpack_require__(7561); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.set.union.v2.js -var esnext_set_union_v2 = __webpack_require__(6197); -// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-exception.stack.js -var web_dom_exception_stack = __webpack_require__(4979); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.constructor.js -var esnext_iterator_constructor = __webpack_require__(8992); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.drop.js -var esnext_iterator_drop = __webpack_require__(4743); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.every.js -var esnext_iterator_every = __webpack_require__(3215); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.some.js -var esnext_iterator_some = __webpack_require__(7550); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.json.parse.js -var esnext_json_parse = __webpack_require__(8335); -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.filter.js -var esnext_iterator_filter = __webpack_require__(4520); -;// CONCATENATED MODULE: ./src/display/base_factory.js - -class BaseFilterFactory { - constructor() { - if (this.constructor === BaseFilterFactory) { - unreachable("Cannot initialize BaseFilterFactory."); - } - } - addFilter(maps) { - return "none"; - } - addHCMFilter(fgColor, bgColor) { - return "none"; - } - addAlphaFilter(map) { - return "none"; - } - addLuminosityFilter(map) { - return "none"; - } - addHighlightHCMFilter(filterName, fgColor, bgColor, newFgColor, newBgColor) { - return "none"; - } - destroy(keepHCM = false) {} -} -class BaseCanvasFactory { - #enableHWA = false; - constructor({ - enableHWA = false - } = {}) { - if (this.constructor === BaseCanvasFactory) { - unreachable("Cannot initialize BaseCanvasFactory."); - } - this.#enableHWA = enableHWA; - } - create(width, height) { - if (width <= 0 || height <= 0) { - throw new Error("Invalid canvas size"); - } - const canvas = this._createCanvas(width, height); - return { - canvas, - context: canvas.getContext("2d", { - willReadFrequently: !this.#enableHWA - }) - }; - } - reset(canvasAndContext, width, height) { - if (!canvasAndContext.canvas) { - throw new Error("Canvas is not specified"); - } - if (width <= 0 || height <= 0) { - throw new Error("Invalid canvas size"); - } - canvasAndContext.canvas.width = width; - canvasAndContext.canvas.height = height; - } - destroy(canvasAndContext) { - if (!canvasAndContext.canvas) { - throw new Error("Canvas is not specified"); - } - canvasAndContext.canvas.width = 0; - canvasAndContext.canvas.height = 0; - canvasAndContext.canvas = null; - canvasAndContext.context = null; - } - _createCanvas(width, height) { - unreachable("Abstract method `_createCanvas` called."); - } -} -class BaseCMapReaderFactory { - constructor({ - baseUrl = null, - isCompressed = true - }) { - if (this.constructor === BaseCMapReaderFactory) { - unreachable("Cannot initialize BaseCMapReaderFactory."); - } - this.baseUrl = baseUrl; - this.isCompressed = isCompressed; - } - async fetch({ - name - }) { - if (!this.baseUrl) { - throw new Error('The CMap "baseUrl" parameter must be specified, ensure that ' + 'the "cMapUrl" and "cMapPacked" API parameters are provided.'); - } - if (!name) { - throw new Error("CMap name must be specified."); - } - const url = this.baseUrl + name + (this.isCompressed ? ".bcmap" : ""); - const compressionType = this.isCompressed ? CMapCompressionType.BINARY : CMapCompressionType.NONE; - return this._fetchData(url, compressionType).catch(reason => { - throw new Error(`Unable to load ${this.isCompressed ? "binary " : ""}CMap at: ${url}`); - }); - } - _fetchData(url, compressionType) { - unreachable("Abstract method `_fetchData` called."); - } -} -class BaseStandardFontDataFactory { - constructor({ - baseUrl = null - }) { - if (this.constructor === BaseStandardFontDataFactory) { - unreachable("Cannot initialize BaseStandardFontDataFactory."); - } - this.baseUrl = baseUrl; - } - async fetch({ - filename - }) { - if (!this.baseUrl) { - throw new Error('The standard font "baseUrl" parameter must be specified, ensure that ' + 'the "standardFontDataUrl" API parameter is provided.'); - } - if (!filename) { - throw new Error("Font filename must be specified."); - } - const url = `${this.baseUrl}${filename}`; - return this._fetchData(url).catch(reason => { - throw new Error(`Unable to load font data at: ${url}`); - }); - } - _fetchData(url) { - unreachable("Abstract method `_fetchData` called."); - } -} -class BaseSVGFactory { - constructor() { - if (this.constructor === BaseSVGFactory) { - unreachable("Cannot initialize BaseSVGFactory."); - } - } - create(width, height, skipDimensions = false) { - if (width <= 0 || height <= 0) { - throw new Error("Invalid SVG dimensions"); - } - const svg = this._createSVG("svg:svg"); - svg.setAttribute("version", "1.1"); - if (!skipDimensions) { - svg.setAttribute("width", `${width}px`); - svg.setAttribute("height", `${height}px`); - } - svg.setAttribute("preserveAspectRatio", "none"); - svg.setAttribute("viewBox", `0 0 ${width} ${height}`); - return svg; - } - createElement(type) { - if (typeof type !== "string") { - throw new Error("Invalid SVG element type"); - } - return this._createSVG(type); - } - _createSVG(type) { - unreachable("Abstract method `_createSVG` called."); - } -} - -;// CONCATENATED MODULE: ./src/display/display_utils.js - - - - - - - - - - - - - - - -const SVG_NS = "http://www.w3.org/2000/svg"; -class PixelsPerInch { - static CSS = 96.0; - static PDF = 72.0; - static PDF_TO_CSS_UNITS = this.CSS / this.PDF; -} -class DOMFilterFactory extends BaseFilterFactory { - #_cache; - #_defs; - #docId; - #document; - #_hcmCache; - #id = 0; - constructor({ - docId, - ownerDocument = globalThis.document - } = {}) { - super(); - this.#docId = docId; - this.#document = ownerDocument; - } - get #cache() { - return this.#_cache ||= new Map(); - } - get #hcmCache() { - return this.#_hcmCache ||= new Map(); - } - get #defs() { - if (!this.#_defs) { - const div = this.#document.createElement("div"); - const { - style - } = div; - style.visibility = "hidden"; - style.contain = "strict"; - style.width = style.height = 0; - style.position = "absolute"; - style.top = style.left = 0; - style.zIndex = -1; - const svg = this.#document.createElementNS(SVG_NS, "svg"); - svg.setAttribute("width", 0); - svg.setAttribute("height", 0); - this.#_defs = this.#document.createElementNS(SVG_NS, "defs"); - div.append(svg); - svg.append(this.#_defs); - this.#document.body.append(div); - } - return this.#_defs; - } - #createTables(maps) { - if (maps.length === 1) { - const mapR = maps[0]; - const buffer = new Array(256); - for (let i = 0; i < 256; i++) { - buffer[i] = mapR[i] / 255; - } - const table = buffer.join(","); - return [table, table, table]; - } - const [mapR, mapG, mapB] = maps; - const bufferR = new Array(256); - const bufferG = new Array(256); - const bufferB = new Array(256); - for (let i = 0; i < 256; i++) { - bufferR[i] = mapR[i] / 255; - bufferG[i] = mapG[i] / 255; - bufferB[i] = mapB[i] / 255; - } - return [bufferR.join(","), bufferG.join(","), bufferB.join(",")]; - } - addFilter(maps) { - if (!maps) { - return "none"; - } - let value = this.#cache.get(maps); - if (value) { - return value; - } - const [tableR, tableG, tableB] = this.#createTables(maps); - const key = maps.length === 1 ? tableR : `${tableR}${tableG}${tableB}`; - value = this.#cache.get(key); - if (value) { - this.#cache.set(maps, value); - return value; - } - const id = `g_${this.#docId}_transfer_map_${this.#id++}`; - const url = `url(#${id})`; - this.#cache.set(maps, url); - this.#cache.set(key, url); - const filter = this.#createFilter(id); - this.#addTransferMapConversion(tableR, tableG, tableB, filter); - return url; - } - addHCMFilter(fgColor, bgColor) { - const key = `${fgColor}-${bgColor}`; - const filterName = "base"; - let info = this.#hcmCache.get(filterName); - if (info?.key === key) { - return info.url; - } - if (info) { - info.filter?.remove(); - info.key = key; - info.url = "none"; - info.filter = null; - } else { - info = { - key, - url: "none", - filter: null - }; - this.#hcmCache.set(filterName, info); - } - if (!fgColor || !bgColor) { - return info.url; - } - const fgRGB = this.#getRGB(fgColor); - fgColor = Util.makeHexColor(...fgRGB); - const bgRGB = this.#getRGB(bgColor); - bgColor = Util.makeHexColor(...bgRGB); - this.#defs.style.color = ""; - if (fgColor === "#000000" && bgColor === "#ffffff" || fgColor === bgColor) { - return info.url; - } - const map = new Array(256); - for (let i = 0; i <= 255; i++) { - const x = i / 255; - map[i] = x <= 0.03928 ? x / 12.92 : ((x + 0.055) / 1.055) ** 2.4; - } - const table = map.join(","); - const id = `g_${this.#docId}_hcm_filter`; - const filter = info.filter = this.#createFilter(id); - this.#addTransferMapConversion(table, table, table, filter); - this.#addGrayConversion(filter); - const getSteps = (c, n) => { - const start = fgRGB[c] / 255; - const end = bgRGB[c] / 255; - const arr = new Array(n + 1); - for (let i = 0; i <= n; i++) { - arr[i] = start + i / n * (end - start); - } - return arr.join(","); - }; - this.#addTransferMapConversion(getSteps(0, 5), getSteps(1, 5), getSteps(2, 5), filter); - info.url = `url(#${id})`; - return info.url; - } - addAlphaFilter(map) { - let value = this.#cache.get(map); - if (value) { - return value; - } - const [tableA] = this.#createTables([map]); - const key = `alpha_${tableA}`; - value = this.#cache.get(key); - if (value) { - this.#cache.set(map, value); - return value; - } - const id = `g_${this.#docId}_alpha_map_${this.#id++}`; - const url = `url(#${id})`; - this.#cache.set(map, url); - this.#cache.set(key, url); - const filter = this.#createFilter(id); - this.#addTransferMapAlphaConversion(tableA, filter); - return url; - } - addLuminosityFilter(map) { - let value = this.#cache.get(map || "luminosity"); - if (value) { - return value; - } - let tableA, key; - if (map) { - [tableA] = this.#createTables([map]); - key = `luminosity_${tableA}`; - } else { - key = "luminosity"; - } - value = this.#cache.get(key); - if (value) { - this.#cache.set(map, value); - return value; - } - const id = `g_${this.#docId}_luminosity_map_${this.#id++}`; - const url = `url(#${id})`; - this.#cache.set(map, url); - this.#cache.set(key, url); - const filter = this.#createFilter(id); - this.#addLuminosityConversion(filter); - if (map) { - this.#addTransferMapAlphaConversion(tableA, filter); - } - return url; - } - addHighlightHCMFilter(filterName, fgColor, bgColor, newFgColor, newBgColor) { - const key = `${fgColor}-${bgColor}-${newFgColor}-${newBgColor}`; - let info = this.#hcmCache.get(filterName); - if (info?.key === key) { - return info.url; - } - if (info) { - info.filter?.remove(); - info.key = key; - info.url = "none"; - info.filter = null; - } else { - info = { - key, - url: "none", - filter: null - }; - this.#hcmCache.set(filterName, info); - } - if (!fgColor || !bgColor) { - return info.url; - } - const [fgRGB, bgRGB] = [fgColor, bgColor].map(this.#getRGB.bind(this)); - let fgGray = Math.round(0.2126 * fgRGB[0] + 0.7152 * fgRGB[1] + 0.0722 * fgRGB[2]); - let bgGray = Math.round(0.2126 * bgRGB[0] + 0.7152 * bgRGB[1] + 0.0722 * bgRGB[2]); - let [newFgRGB, newBgRGB] = [newFgColor, newBgColor].map(this.#getRGB.bind(this)); - if (bgGray < fgGray) { - [fgGray, bgGray, newFgRGB, newBgRGB] = [bgGray, fgGray, newBgRGB, newFgRGB]; - } - this.#defs.style.color = ""; - const getSteps = (fg, bg, n) => { - const arr = new Array(256); - const step = (bgGray - fgGray) / n; - const newStart = fg / 255; - const newStep = (bg - fg) / (255 * n); - let prev = 0; - for (let i = 0; i <= n; i++) { - const k = Math.round(fgGray + i * step); - const value = newStart + i * newStep; - for (let j = prev; j <= k; j++) { - arr[j] = value; - } - prev = k + 1; - } - for (let i = prev; i < 256; i++) { - arr[i] = arr[prev - 1]; - } - return arr.join(","); - }; - const id = `g_${this.#docId}_hcm_${filterName}_filter`; - const filter = info.filter = this.#createFilter(id); - this.#addGrayConversion(filter); - this.#addTransferMapConversion(getSteps(newFgRGB[0], newBgRGB[0], 5), getSteps(newFgRGB[1], newBgRGB[1], 5), getSteps(newFgRGB[2], newBgRGB[2], 5), filter); - info.url = `url(#${id})`; - return info.url; - } - destroy(keepHCM = false) { - if (keepHCM && this.#hcmCache.size !== 0) { - return; - } - if (this.#_defs) { - this.#_defs.parentNode.parentNode.remove(); - this.#_defs = null; - } - if (this.#_cache) { - this.#_cache.clear(); - this.#_cache = null; - } - this.#id = 0; - } - #addLuminosityConversion(filter) { - const feColorMatrix = this.#document.createElementNS(SVG_NS, "feColorMatrix"); - feColorMatrix.setAttribute("type", "matrix"); - feColorMatrix.setAttribute("values", "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.3 0.59 0.11 0 0"); - filter.append(feColorMatrix); - } - #addGrayConversion(filter) { - const feColorMatrix = this.#document.createElementNS(SVG_NS, "feColorMatrix"); - feColorMatrix.setAttribute("type", "matrix"); - feColorMatrix.setAttribute("values", "0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0 0 0 1 0"); - filter.append(feColorMatrix); - } - #createFilter(id) { - const filter = this.#document.createElementNS(SVG_NS, "filter"); - filter.setAttribute("color-interpolation-filters", "sRGB"); - filter.setAttribute("id", id); - this.#defs.append(filter); - return filter; - } - #appendFeFunc(feComponentTransfer, func, table) { - const feFunc = this.#document.createElementNS(SVG_NS, func); - feFunc.setAttribute("type", "discrete"); - feFunc.setAttribute("tableValues", table); - feComponentTransfer.append(feFunc); - } - #addTransferMapConversion(rTable, gTable, bTable, filter) { - const feComponentTransfer = this.#document.createElementNS(SVG_NS, "feComponentTransfer"); - filter.append(feComponentTransfer); - this.#appendFeFunc(feComponentTransfer, "feFuncR", rTable); - this.#appendFeFunc(feComponentTransfer, "feFuncG", gTable); - this.#appendFeFunc(feComponentTransfer, "feFuncB", bTable); - } - #addTransferMapAlphaConversion(aTable, filter) { - const feComponentTransfer = this.#document.createElementNS(SVG_NS, "feComponentTransfer"); - filter.append(feComponentTransfer); - this.#appendFeFunc(feComponentTransfer, "feFuncA", aTable); - } - #getRGB(color) { - this.#defs.style.color = color; - return getRGB(getComputedStyle(this.#defs).getPropertyValue("color")); - } -} -class DOMCanvasFactory extends BaseCanvasFactory { - constructor({ - ownerDocument = globalThis.document, - enableHWA = false - } = {}) { - super({ - enableHWA - }); - this._document = ownerDocument; - } - _createCanvas(width, height) { - const canvas = this._document.createElement("canvas"); - canvas.width = width; - canvas.height = height; - return canvas; - } -} -async function fetchData(url, type = "text") { - if (isValidFetchUrl(url, document.baseURI)) { - const response = await fetch(url); - if (!response.ok) { - throw new Error(response.statusText); - } - switch (type) { - case "arraybuffer": - return response.arrayBuffer(); - case "blob": - return response.blob(); - case "json": - return response.json(); - } - return response.text(); - } - return new Promise((resolve, reject) => { - const request = new XMLHttpRequest(); - request.open("GET", url, true); - request.responseType = type; - request.onreadystatechange = () => { - if (request.readyState !== XMLHttpRequest.DONE) { - return; - } - if (request.status === 200 || request.status === 0) { - switch (type) { - case "arraybuffer": - case "blob": - case "json": - resolve(request.response); - return; - } - resolve(request.responseText); - return; - } - reject(new Error(request.statusText)); - }; - request.send(null); - }); -} -class DOMCMapReaderFactory extends BaseCMapReaderFactory { - _fetchData(url, compressionType) { - return fetchData(url, this.isCompressed ? "arraybuffer" : "text").then(data => ({ - cMapData: data instanceof ArrayBuffer ? new Uint8Array(data) : stringToBytes(data), - compressionType - })); - } -} -class DOMStandardFontDataFactory extends BaseStandardFontDataFactory { - _fetchData(url) { - return fetchData(url, "arraybuffer").then(data => new Uint8Array(data)); - } -} -class DOMSVGFactory extends BaseSVGFactory { - _createSVG(type) { - return document.createElementNS(SVG_NS, type); - } -} -class PageViewport { - constructor({ - viewBox, - scale, - rotation, - offsetX = 0, - offsetY = 0, - dontFlip = false - }) { - this.viewBox = viewBox; - this.scale = scale; - this.rotation = rotation; - this.offsetX = offsetX; - this.offsetY = offsetY; - const centerX = (viewBox[2] + viewBox[0]) / 2; - const centerY = (viewBox[3] + viewBox[1]) / 2; - let rotateA, rotateB, rotateC, rotateD; - rotation %= 360; - if (rotation < 0) { - rotation += 360; - } - switch (rotation) { - case 180: - rotateA = -1; - rotateB = 0; - rotateC = 0; - rotateD = 1; - break; - case 90: - rotateA = 0; - rotateB = 1; - rotateC = 1; - rotateD = 0; - break; - case 270: - rotateA = 0; - rotateB = -1; - rotateC = -1; - rotateD = 0; - break; - case 0: - rotateA = 1; - rotateB = 0; - rotateC = 0; - rotateD = -1; - break; - default: - throw new Error("PageViewport: Invalid rotation, must be a multiple of 90 degrees."); - } - if (dontFlip) { - rotateC = -rotateC; - rotateD = -rotateD; - } - let offsetCanvasX, offsetCanvasY; - let width, height; - if (rotateA === 0) { - offsetCanvasX = Math.abs(centerY - viewBox[1]) * scale + offsetX; - offsetCanvasY = Math.abs(centerX - viewBox[0]) * scale + offsetY; - width = (viewBox[3] - viewBox[1]) * scale; - height = (viewBox[2] - viewBox[0]) * scale; - } else { - offsetCanvasX = Math.abs(centerX - viewBox[0]) * scale + offsetX; - offsetCanvasY = Math.abs(centerY - viewBox[1]) * scale + offsetY; - width = (viewBox[2] - viewBox[0]) * scale; - height = (viewBox[3] - viewBox[1]) * scale; - } - this.transform = [rotateA * scale, rotateB * scale, rotateC * scale, rotateD * scale, offsetCanvasX - rotateA * scale * centerX - rotateC * scale * centerY, offsetCanvasY - rotateB * scale * centerX - rotateD * scale * centerY]; - this.width = width; - this.height = height; - } - get rawDims() { - const { - viewBox - } = this; - return shadow(this, "rawDims", { - pageWidth: viewBox[2] - viewBox[0], - pageHeight: viewBox[3] - viewBox[1], - pageX: viewBox[0], - pageY: viewBox[1] - }); - } - clone({ - scale = this.scale, - rotation = this.rotation, - offsetX = this.offsetX, - offsetY = this.offsetY, - dontFlip = false - } = {}) { - return new PageViewport({ - viewBox: this.viewBox.slice(), - scale, - rotation, - offsetX, - offsetY, - dontFlip - }); - } - convertToViewportPoint(x, y) { - return Util.applyTransform([x, y], this.transform); - } - convertToViewportRectangle(rect) { - const topLeft = Util.applyTransform([rect[0], rect[1]], this.transform); - const bottomRight = Util.applyTransform([rect[2], rect[3]], this.transform); - return [topLeft[0], topLeft[1], bottomRight[0], bottomRight[1]]; - } - convertToPdfPoint(x, y) { - return Util.applyInverseTransform([x, y], this.transform); - } -} -class RenderingCancelledException extends BaseException { - constructor(msg, extraDelay = 0) { - super(msg, "RenderingCancelledException"); - this.extraDelay = extraDelay; - } -} -function isDataScheme(url) { - const ii = url.length; - let i = 0; - while (i < ii && url[i].trim() === "") { - i++; - } - return url.substring(i, i + 5).toLowerCase() === "data:"; -} -function isPdfFile(filename) { - return typeof filename === "string" && /\.pdf$/i.test(filename); -} -function getFilenameFromUrl(url) { - [url] = url.split(/[#?]/, 1); - return url.substring(url.lastIndexOf("/") + 1); -} -function getPdfFilenameFromUrl(url, defaultFilename = "document.pdf") { - if (typeof url !== "string") { - return defaultFilename; - } - if (isDataScheme(url)) { - warn('getPdfFilenameFromUrl: ignore "data:"-URL for performance reasons.'); - return defaultFilename; - } - const reURI = /^(?:(?:[^:]+:)?\/\/[^/]+)?([^?#]*)(\?[^#]*)?(#.*)?$/; - const reFilename = /[^/?#=]+\.pdf\b(?!.*\.pdf\b)/i; - const splitURI = reURI.exec(url); - let suggestedFilename = reFilename.exec(splitURI[1]) || reFilename.exec(splitURI[2]) || reFilename.exec(splitURI[3]); - if (suggestedFilename) { - suggestedFilename = suggestedFilename[0]; - if (suggestedFilename.includes("%")) { - try { - suggestedFilename = reFilename.exec(decodeURIComponent(suggestedFilename))[0]; - } catch {} - } - } - return suggestedFilename || defaultFilename; -} -class StatTimer { - started = Object.create(null); - times = []; - time(name) { - if (name in this.started) { - warn(`Timer is already running for ${name}`); - } - this.started[name] = Date.now(); - } - timeEnd(name) { - if (!(name in this.started)) { - warn(`Timer has not been started for ${name}`); - } - this.times.push({ - name, - start: this.started[name], - end: Date.now() - }); - delete this.started[name]; - } - toString() { - const outBuf = []; - let longest = 0; - for (const { - name - } of this.times) { - longest = Math.max(name.length, longest); - } - for (const { - name, - start, - end - } of this.times) { - outBuf.push(`${name.padEnd(longest)} ${end - start}ms\n`); - } - return outBuf.join(""); - } -} -function isValidFetchUrl(url, baseUrl) { - try { - const { - protocol - } = baseUrl ? new URL(url, baseUrl) : new URL(url); - return protocol === "http:" || protocol === "https:"; - } catch { - return false; - } -} -function noContextMenu(e) { - e.preventDefault(); -} -function deprecated(details) { - console.log("Deprecated API usage: " + details); -} -let pdfDateStringRegex; -class PDFDateString { - static toDateObject(input) { - if (!input || typeof input !== "string") { - return null; - } - pdfDateStringRegex ||= new RegExp("^D:" + "(\\d{4})" + "(\\d{2})?" + "(\\d{2})?" + "(\\d{2})?" + "(\\d{2})?" + "(\\d{2})?" + "([Z|+|-])?" + "(\\d{2})?" + "'?" + "(\\d{2})?" + "'?"); - const matches = pdfDateStringRegex.exec(input); - if (!matches) { - return null; - } - const year = parseInt(matches[1], 10); - let month = parseInt(matches[2], 10); - month = month >= 1 && month <= 12 ? month - 1 : 0; - let day = parseInt(matches[3], 10); - day = day >= 1 && day <= 31 ? day : 1; - let hour = parseInt(matches[4], 10); - hour = hour >= 0 && hour <= 23 ? hour : 0; - let minute = parseInt(matches[5], 10); - minute = minute >= 0 && minute <= 59 ? minute : 0; - let second = parseInt(matches[6], 10); - second = second >= 0 && second <= 59 ? second : 0; - const universalTimeRelation = matches[7] || "Z"; - let offsetHour = parseInt(matches[8], 10); - offsetHour = offsetHour >= 0 && offsetHour <= 23 ? offsetHour : 0; - let offsetMinute = parseInt(matches[9], 10) || 0; - offsetMinute = offsetMinute >= 0 && offsetMinute <= 59 ? offsetMinute : 0; - if (universalTimeRelation === "-") { - hour += offsetHour; - minute += offsetMinute; - } else if (universalTimeRelation === "+") { - hour -= offsetHour; - minute -= offsetMinute; - } - return new Date(Date.UTC(year, month, day, hour, minute, second)); - } -} -function getXfaPageViewport(xfaPage, { - scale = 1, - rotation = 0 -}) { - const { - width, - height - } = xfaPage.attributes.style; - const viewBox = [0, 0, parseInt(width), parseInt(height)]; - return new PageViewport({ - viewBox, - scale, - rotation - }); -} -function getRGB(color) { - if (color.startsWith("#")) { - const colorRGB = parseInt(color.slice(1), 16); - return [(colorRGB & 0xff0000) >> 16, (colorRGB & 0x00ff00) >> 8, colorRGB & 0x0000ff]; - } - if (color.startsWith("rgb(")) { - return color.slice(4, -1).split(",").map(x => parseInt(x)); - } - if (color.startsWith("rgba(")) { - return color.slice(5, -1).split(",").map(x => parseInt(x)).slice(0, 3); - } - warn(`Not a valid color format: "${color}"`); - return [0, 0, 0]; -} -function getColorValues(colors) { - const span = document.createElement("span"); - span.style.visibility = "hidden"; - document.body.append(span); - for (const name of colors.keys()) { - span.style.color = name; - const computedColor = window.getComputedStyle(span).color; - colors.set(name, getRGB(computedColor)); - } - span.remove(); -} -function getCurrentTransform(ctx) { - const { - a, - b, - c, - d, - e, - f - } = ctx.getTransform(); - return [a, b, c, d, e, f]; -} -function getCurrentTransformInverse(ctx) { - const { - a, - b, - c, - d, - e, - f - } = ctx.getTransform().invertSelf(); - return [a, b, c, d, e, f]; -} -function setLayerDimensions(div, viewport, mustFlip = false, mustRotate = true) { - if (viewport instanceof PageViewport) { - const { - pageWidth, - pageHeight - } = viewport.rawDims; - const { - style - } = div; - const useRound = util_FeatureTest.isCSSRoundSupported; - const w = `var(--scale-factor) * ${pageWidth}px`, - h = `var(--scale-factor) * ${pageHeight}px`; - const widthStr = useRound ? `round(${w}, 1px)` : `calc(${w})`, - heightStr = useRound ? `round(${h}, 1px)` : `calc(${h})`; - if (!mustFlip || viewport.rotation % 180 === 0) { - style.width = widthStr; - style.height = heightStr; - } else { - style.width = heightStr; - style.height = widthStr; - } - } - if (mustRotate) { - div.setAttribute("data-main-rotation", viewport.rotation); - } -} - -;// CONCATENATED MODULE: ./src/display/editor/toolbar.js - -class EditorToolbar { - #toolbar = null; - #colorPicker = null; - #editor; - #buttons = null; - constructor(editor) { - this.#editor = editor; - } - render() { - const editToolbar = this.#toolbar = document.createElement("div"); - editToolbar.className = "editToolbar"; - editToolbar.setAttribute("role", "toolbar"); - editToolbar.addEventListener("contextmenu", noContextMenu); - editToolbar.addEventListener("pointerdown", EditorToolbar.#pointerDown); - const buttons = this.#buttons = document.createElement("div"); - buttons.className = "buttons"; - editToolbar.append(buttons); - const position = this.#editor.toolbarPosition; - if (position) { - const { - style - } = editToolbar; - const x = this.#editor._uiManager.direction === "ltr" ? 1 - position[0] : position[0]; - style.insetInlineEnd = `${100 * x}%`; - style.top = `calc(${100 * position[1]}% + var(--editor-toolbar-vert-offset))`; - } - this.#addDeleteButton(); - return editToolbar; - } - static #pointerDown(e) { - e.stopPropagation(); - } - #focusIn(e) { - this.#editor._focusEventsAllowed = false; - e.preventDefault(); - e.stopPropagation(); - } - #focusOut(e) { - this.#editor._focusEventsAllowed = true; - e.preventDefault(); - e.stopPropagation(); - } - #addListenersToElement(element) { - element.addEventListener("focusin", this.#focusIn.bind(this), { - capture: true - }); - element.addEventListener("focusout", this.#focusOut.bind(this), { - capture: true - }); - element.addEventListener("contextmenu", noContextMenu); - } - hide() { - this.#toolbar.classList.add("hidden"); - this.#colorPicker?.hideDropdown(); - } - show() { - this.#toolbar.classList.remove("hidden"); - } - #addDeleteButton() { - const button = document.createElement("button"); - button.className = "delete"; - button.tabIndex = 0; - button.setAttribute("data-l10n-id", `pdfjs-editor-remove-${this.#editor.editorType}-button`); - this.#addListenersToElement(button); - button.addEventListener("click", e => { - this.#editor._uiManager.delete(); - }); - this.#buttons.append(button); - } - get #divider() { - const divider = document.createElement("div"); - divider.className = "divider"; - return divider; - } - addAltTextButton(button) { - this.#addListenersToElement(button); - this.#buttons.prepend(button, this.#divider); - } - addColorPicker(colorPicker) { - this.#colorPicker = colorPicker; - const button = colorPicker.renderButton(); - this.#addListenersToElement(button); - this.#buttons.prepend(button, this.#divider); - } - remove() { - this.#toolbar.remove(); - this.#colorPicker?.destroy(); - this.#colorPicker = null; - } -} -class HighlightToolbar { - #buttons = null; - #toolbar = null; - #uiManager; - constructor(uiManager) { - this.#uiManager = uiManager; - } - #render() { - const editToolbar = this.#toolbar = document.createElement("div"); - editToolbar.className = "editToolbar"; - editToolbar.setAttribute("role", "toolbar"); - editToolbar.addEventListener("contextmenu", noContextMenu); - const buttons = this.#buttons = document.createElement("div"); - buttons.className = "buttons"; - editToolbar.append(buttons); - this.#addHighlightButton(); - return editToolbar; - } - #getLastPoint(boxes, isLTR) { - let lastY = 0; - let lastX = 0; - for (const box of boxes) { - const y = box.y + box.height; - if (y < lastY) { - continue; - } - const x = box.x + (isLTR ? box.width : 0); - if (y > lastY) { - lastX = x; - lastY = y; - continue; - } - if (isLTR) { - if (x > lastX) { - lastX = x; - } - } else if (x < lastX) { - lastX = x; - } - } - return [isLTR ? 1 - lastX : lastX, lastY]; - } - show(parent, boxes, isLTR) { - const [x, y] = this.#getLastPoint(boxes, isLTR); - const { - style - } = this.#toolbar ||= this.#render(); - parent.append(this.#toolbar); - style.insetInlineEnd = `${100 * x}%`; - style.top = `calc(${100 * y}% + var(--editor-toolbar-vert-offset))`; - } - hide() { - this.#toolbar.remove(); - } - #addHighlightButton() { - const button = document.createElement("button"); - button.className = "highlightButton"; - button.tabIndex = 0; - button.setAttribute("data-l10n-id", `pdfjs-highlight-floating-button1`); - const span = document.createElement("span"); - button.append(span); - span.className = "visuallyHidden"; - span.setAttribute("data-l10n-id", "pdfjs-highlight-floating-button-label"); - button.addEventListener("contextmenu", noContextMenu); - button.addEventListener("click", () => { - this.#uiManager.highlightSelection("floating_button"); - }); - this.#buttons.append(button); - } -} - -;// CONCATENATED MODULE: ./src/display/editor/tools.js - - - - - - - - - - - - - - - - - - - - - - - -function bindEvents(obj, element, names) { - for (const name of names) { - element.addEventListener(name, obj[name].bind(obj)); - } -} -function opacityToHex(opacity) { - return Math.round(Math.min(255, Math.max(1, 255 * opacity))).toString(16).padStart(2, "0"); -} -class IdManager { - #id = 0; - get id() { - return `${AnnotationEditorPrefix}${this.#id++}`; - } -} -class ImageManager { - #baseId = getUuid(); - #id = 0; - #cache = null; - static get _isSVGFittingCanvas() { - const svg = `data:image/svg+xml;charset=UTF-8,`; - const canvas = new OffscreenCanvas(1, 3); - const ctx = canvas.getContext("2d", { - willReadFrequently: true - }); - const image = new Image(); - image.src = svg; - const promise = image.decode().then(() => { - ctx.drawImage(image, 0, 0, 1, 1, 0, 0, 1, 3); - return new Uint32Array(ctx.getImageData(0, 0, 1, 1).data.buffer)[0] === 0; - }); - return shadow(this, "_isSVGFittingCanvas", promise); - } - async #get(key, rawData) { - this.#cache ||= new Map(); - let data = this.#cache.get(key); - if (data === null) { - return null; - } - if (data?.bitmap) { - data.refCounter += 1; - return data; - } - try { - data ||= { - bitmap: null, - id: `image_${this.#baseId}_${this.#id++}`, - refCounter: 0, - isSvg: false - }; - let image; - if (typeof rawData === "string") { - data.url = rawData; - image = await fetchData(rawData, "blob"); - } else { - image = data.file = rawData; - } - if (image.type === "image/svg+xml") { - const mustRemoveAspectRatioPromise = ImageManager._isSVGFittingCanvas; - const fileReader = new FileReader(); - const imageElement = new Image(); - const imagePromise = new Promise((resolve, reject) => { - imageElement.onload = () => { - data.bitmap = imageElement; - data.isSvg = true; - resolve(); - }; - fileReader.onload = async () => { - const url = data.svgUrl = fileReader.result; - imageElement.src = (await mustRemoveAspectRatioPromise) ? `${url}#svgView(preserveAspectRatio(none))` : url; - }; - imageElement.onerror = fileReader.onerror = reject; - }); - fileReader.readAsDataURL(image); - await imagePromise; - } else { - data.bitmap = await createImageBitmap(image); - } - data.refCounter = 1; - } catch (e) { - console.error(e); - data = null; - } - this.#cache.set(key, data); - if (data) { - this.#cache.set(data.id, data); - } - return data; - } - async getFromFile(file) { - const { - lastModified, - name, - size, - type - } = file; - return this.#get(`${lastModified}_${name}_${size}_${type}`, file); - } - async getFromUrl(url) { - return this.#get(url, url); - } - async getFromId(id) { - this.#cache ||= new Map(); - const data = this.#cache.get(id); - if (!data) { - return null; - } - if (data.bitmap) { - data.refCounter += 1; - return data; - } - if (data.file) { - return this.getFromFile(data.file); - } - return this.getFromUrl(data.url); - } - getSvgUrl(id) { - const data = this.#cache.get(id); - if (!data?.isSvg) { - return null; - } - return data.svgUrl; - } - deleteId(id) { - this.#cache ||= new Map(); - const data = this.#cache.get(id); - if (!data) { - return; - } - data.refCounter -= 1; - if (data.refCounter !== 0) { - return; - } - data.bitmap = null; - } - isValidId(id) { - return id.startsWith(`image_${this.#baseId}_`); - } -} -class CommandManager { - #commands = []; - #locked = false; - #maxSize; - #position = -1; - constructor(maxSize = 128) { - this.#maxSize = maxSize; - } - add({ - cmd, - undo, - post, - mustExec, - type = NaN, - overwriteIfSameType = false, - keepUndo = false - }) { - if (mustExec) { - cmd(); - } - if (this.#locked) { - return; - } - const save = { - cmd, - undo, - post, - type - }; - if (this.#position === -1) { - if (this.#commands.length > 0) { - this.#commands.length = 0; - } - this.#position = 0; - this.#commands.push(save); - return; - } - if (overwriteIfSameType && this.#commands[this.#position].type === type) { - if (keepUndo) { - save.undo = this.#commands[this.#position].undo; - } - this.#commands[this.#position] = save; - return; - } - const next = this.#position + 1; - if (next === this.#maxSize) { - this.#commands.splice(0, 1); - } else { - this.#position = next; - if (next < this.#commands.length) { - this.#commands.splice(next); - } - } - this.#commands.push(save); - } - undo() { - if (this.#position === -1) { - return; - } - this.#locked = true; - const { - undo, - post - } = this.#commands[this.#position]; - undo(); - post?.(); - this.#locked = false; - this.#position -= 1; - } - redo() { - if (this.#position < this.#commands.length - 1) { - this.#position += 1; - this.#locked = true; - const { - cmd, - post - } = this.#commands[this.#position]; - cmd(); - post?.(); - this.#locked = false; - } - } - hasSomethingToUndo() { - return this.#position !== -1; - } - hasSomethingToRedo() { - return this.#position < this.#commands.length - 1; - } - destroy() { - this.#commands = null; - } -} -class KeyboardManager { - constructor(callbacks) { - this.buffer = []; - this.callbacks = new Map(); - this.allKeys = new Set(); - const { - isMac - } = util_FeatureTest.platform; - for (const [keys, callback, options = {}] of callbacks) { - for (const key of keys) { - const isMacKey = key.startsWith("mac+"); - if (isMac && isMacKey) { - this.callbacks.set(key.slice(4), { - callback, - options - }); - this.allKeys.add(key.split("+").at(-1)); - } else if (!isMac && !isMacKey) { - this.callbacks.set(key, { - callback, - options - }); - this.allKeys.add(key.split("+").at(-1)); - } - } - } - } - #serialize(event) { - if (event.altKey) { - this.buffer.push("alt"); - } - if (event.ctrlKey) { - this.buffer.push("ctrl"); - } - if (event.metaKey) { - this.buffer.push("meta"); - } - if (event.shiftKey) { - this.buffer.push("shift"); - } - this.buffer.push(event.key); - const str = this.buffer.join("+"); - this.buffer.length = 0; - return str; - } - exec(self, event) { - if (!this.allKeys.has(event.key)) { - return; - } - const info = this.callbacks.get(this.#serialize(event)); - if (!info) { - return; - } - const { - callback, - options: { - bubbles = false, - args = [], - checker = null - } - } = info; - if (checker && !checker(self, event)) { - return; - } - callback.bind(self, ...args, event)(); - if (!bubbles) { - event.stopPropagation(); - event.preventDefault(); - } - } -} -class ColorManager { - static _colorsMapping = new Map([["CanvasText", [0, 0, 0]], ["Canvas", [255, 255, 255]]]); - get _colors() { - const colors = new Map([["CanvasText", null], ["Canvas", null]]); - getColorValues(colors); - return shadow(this, "_colors", colors); - } - convert(color) { - const rgb = getRGB(color); - if (!window.matchMedia("(forced-colors: active)").matches) { - return rgb; - } - for (const [name, RGB] of this._colors) { - if (RGB.every((x, i) => x === rgb[i])) { - return ColorManager._colorsMapping.get(name); - } - } - return rgb; - } - getHexCode(name) { - const rgb = this._colors.get(name); - if (!rgb) { - return name; - } - return Util.makeHexColor(...rgb); - } -} -class AnnotationEditorUIManager { - #activeEditor = null; - #allEditors = new Map(); - #allLayers = new Map(); - #altTextManager = null; - #annotationStorage = null; - #changedExistingAnnotations = null; - #commandManager = new CommandManager(); - #currentPageIndex = 0; - #deletedAnnotationsElementIds = new Set(); - #draggingEditors = null; - #editorTypes = null; - #editorsToRescale = new Set(); - #enableHighlightFloatingButton = false; - #filterFactory = null; - #focusMainContainerTimeoutId = null; - #highlightColors = null; - #highlightWhenShiftUp = false; - #highlightToolbar = null; - #idManager = new IdManager(); - #isEnabled = false; - #isWaiting = false; - #lastActiveElement = null; - #mainHighlightColorPicker = null; - #mlManager = null; - #mode = AnnotationEditorType.NONE; - #selectedEditors = new Set(); - #selectedTextNode = null; - #pageColors = null; - #showAllStates = null; - #boundBlur = this.blur.bind(this); - #boundFocus = this.focus.bind(this); - #boundCopy = this.copy.bind(this); - #boundCut = this.cut.bind(this); - #boundDragOver = this.dragOver.bind(this); - #boundDrop = this.drop.bind(this); - #boundPaste = this.paste.bind(this); - #boundKeydown = this.keydown.bind(this); - #boundKeyup = this.keyup.bind(this); - #boundOnEditingAction = this.onEditingAction.bind(this); - #boundOnPageChanging = this.onPageChanging.bind(this); - #boundOnScaleChanging = this.onScaleChanging.bind(this); - #boundSelectionChange = this.#selectionChange.bind(this); - #boundOnRotationChanging = this.onRotationChanging.bind(this); - #previousStates = { - isEditing: false, - isEmpty: true, - hasSomethingToUndo: false, - hasSomethingToRedo: false, - hasSelectedEditor: false, - hasSelectedText: false - }; - #translation = [0, 0]; - #translationTimeoutId = null; - #container = null; - #viewer = null; - static TRANSLATE_SMALL = 1; - static TRANSLATE_BIG = 10; - static get _keyboardManager() { - const proto = AnnotationEditorUIManager.prototype; - const arrowChecker = self => self.#container.contains(document.activeElement) && document.activeElement.tagName !== "BUTTON" && self.hasSomethingToControl(); - const textInputChecker = (_self, { - target: el - }) => { - if (el instanceof HTMLInputElement) { - const { - type - } = el; - return type !== "text" && type !== "number"; - } - return true; - }; - const small = this.TRANSLATE_SMALL; - const big = this.TRANSLATE_BIG; - return shadow(this, "_keyboardManager", new KeyboardManager([[["ctrl+a", "mac+meta+a"], proto.selectAll, { - checker: textInputChecker - }], [["ctrl+z", "mac+meta+z"], proto.undo, { - checker: textInputChecker - }], [["ctrl+y", "ctrl+shift+z", "mac+meta+shift+z", "ctrl+shift+Z", "mac+meta+shift+Z"], proto.redo, { - checker: textInputChecker - }], [["Backspace", "alt+Backspace", "ctrl+Backspace", "shift+Backspace", "mac+Backspace", "mac+alt+Backspace", "mac+ctrl+Backspace", "Delete", "ctrl+Delete", "shift+Delete", "mac+Delete"], proto.delete, { - checker: textInputChecker - }], [["Enter", "mac+Enter"], proto.addNewEditorFromKeyboard, { - checker: (self, { - target: el - }) => !(el instanceof HTMLButtonElement) && self.#container.contains(el) && !self.isEnterHandled - }], [[" ", "mac+ "], proto.addNewEditorFromKeyboard, { - checker: (self, { - target: el - }) => !(el instanceof HTMLButtonElement) && self.#container.contains(document.activeElement) - }], [["Escape", "mac+Escape"], proto.unselectAll], [["ArrowLeft", "mac+ArrowLeft"], proto.translateSelectedEditors, { - args: [-small, 0], - checker: arrowChecker - }], [["ctrl+ArrowLeft", "mac+shift+ArrowLeft"], proto.translateSelectedEditors, { - args: [-big, 0], - checker: arrowChecker - }], [["ArrowRight", "mac+ArrowRight"], proto.translateSelectedEditors, { - args: [small, 0], - checker: arrowChecker - }], [["ctrl+ArrowRight", "mac+shift+ArrowRight"], proto.translateSelectedEditors, { - args: [big, 0], - checker: arrowChecker - }], [["ArrowUp", "mac+ArrowUp"], proto.translateSelectedEditors, { - args: [0, -small], - checker: arrowChecker - }], [["ctrl+ArrowUp", "mac+shift+ArrowUp"], proto.translateSelectedEditors, { - args: [0, -big], - checker: arrowChecker - }], [["ArrowDown", "mac+ArrowDown"], proto.translateSelectedEditors, { - args: [0, small], - checker: arrowChecker - }], [["ctrl+ArrowDown", "mac+shift+ArrowDown"], proto.translateSelectedEditors, { - args: [0, big], - checker: arrowChecker - }]])); - } - constructor(container, viewer, altTextManager, eventBus, pdfDocument, pageColors, highlightColors, enableHighlightFloatingButton, mlManager) { - this.#container = container; - this.#viewer = viewer; - this.#altTextManager = altTextManager; - this._eventBus = eventBus; - this._eventBus._on("editingaction", this.#boundOnEditingAction); - this._eventBus._on("pagechanging", this.#boundOnPageChanging); - this._eventBus._on("scalechanging", this.#boundOnScaleChanging); - this._eventBus._on("rotationchanging", this.#boundOnRotationChanging); - this.#addSelectionListener(); - this.#addDragAndDropListeners(); - this.#addKeyboardManager(); - this.#annotationStorage = pdfDocument.annotationStorage; - this.#filterFactory = pdfDocument.filterFactory; - this.#pageColors = pageColors; - this.#highlightColors = highlightColors || null; - this.#enableHighlightFloatingButton = enableHighlightFloatingButton; - this.#mlManager = mlManager || null; - this.viewParameters = { - realScale: PixelsPerInch.PDF_TO_CSS_UNITS, - rotation: 0 - }; - this.isShiftKeyDown = false; - } - destroy() { - this.#removeDragAndDropListeners(); - this.#removeKeyboardManager(); - this.#removeFocusManager(); - this._eventBus._off("editingaction", this.#boundOnEditingAction); - this._eventBus._off("pagechanging", this.#boundOnPageChanging); - this._eventBus._off("scalechanging", this.#boundOnScaleChanging); - this._eventBus._off("rotationchanging", this.#boundOnRotationChanging); - for (const layer of this.#allLayers.values()) { - layer.destroy(); - } - this.#allLayers.clear(); - this.#allEditors.clear(); - this.#editorsToRescale.clear(); - this.#activeEditor = null; - this.#selectedEditors.clear(); - this.#commandManager.destroy(); - this.#altTextManager?.destroy(); - this.#highlightToolbar?.hide(); - this.#highlightToolbar = null; - if (this.#focusMainContainerTimeoutId) { - clearTimeout(this.#focusMainContainerTimeoutId); - this.#focusMainContainerTimeoutId = null; - } - if (this.#translationTimeoutId) { - clearTimeout(this.#translationTimeoutId); - this.#translationTimeoutId = null; - } - this.#removeSelectionListener(); - } - async mlGuess(data) { - return this.#mlManager?.guess(data) || null; - } - get hasMLManager() { - return !!this.#mlManager; - } - get hcmFilter() { - return shadow(this, "hcmFilter", this.#pageColors ? this.#filterFactory.addHCMFilter(this.#pageColors.foreground, this.#pageColors.background) : "none"); - } - get direction() { - return shadow(this, "direction", getComputedStyle(this.#container).direction); - } - get highlightColors() { - return shadow(this, "highlightColors", this.#highlightColors ? new Map(this.#highlightColors.split(",").map(pair => pair.split("=").map(x => x.trim()))) : null); - } - get highlightColorNames() { - return shadow(this, "highlightColorNames", this.highlightColors ? new Map(Array.from(this.highlightColors, e => e.reverse())) : null); - } - setMainHighlightColorPicker(colorPicker) { - this.#mainHighlightColorPicker = colorPicker; - } - editAltText(editor) { - this.#altTextManager?.editAltText(this, editor); - } - onPageChanging({ - pageNumber - }) { - this.#currentPageIndex = pageNumber - 1; - } - focusMainContainer() { - this.#container.focus(); - } - findParent(x, y) { - for (const layer of this.#allLayers.values()) { - const { - x: layerX, - y: layerY, - width, - height - } = layer.div.getBoundingClientRect(); - if (x >= layerX && x <= layerX + width && y >= layerY && y <= layerY + height) { - return layer; - } - } - return null; - } - disableUserSelect(value = false) { - this.#viewer.classList.toggle("noUserSelect", value); - } - addShouldRescale(editor) { - this.#editorsToRescale.add(editor); - } - removeShouldRescale(editor) { - this.#editorsToRescale.delete(editor); - } - onScaleChanging({ - scale - }) { - this.commitOrRemove(); - this.viewParameters.realScale = scale * PixelsPerInch.PDF_TO_CSS_UNITS; - for (const editor of this.#editorsToRescale) { - editor.onScaleChanging(); - } - } - onRotationChanging({ - pagesRotation - }) { - this.commitOrRemove(); - this.viewParameters.rotation = pagesRotation; - } - #getAnchorElementForSelection({ - anchorNode - }) { - return anchorNode.nodeType === Node.TEXT_NODE ? anchorNode.parentElement : anchorNode; - } - highlightSelection(methodOfCreation = "") { - const selection = document.getSelection(); - if (!selection || selection.isCollapsed) { - return; - } - const { - anchorNode, - anchorOffset, - focusNode, - focusOffset - } = selection; - const text = selection.toString(); - const anchorElement = this.#getAnchorElementForSelection(selection); - const textLayer = anchorElement.closest(".textLayer"); - const boxes = this.getSelectionBoxes(textLayer); - if (!boxes) { - return; - } - selection.empty(); - if (this.#mode === AnnotationEditorType.NONE) { - this._eventBus.dispatch("showannotationeditorui", { - source: this, - mode: AnnotationEditorType.HIGHLIGHT - }); - this.showAllEditors("highlight", true, true); - } - for (const layer of this.#allLayers.values()) { - if (layer.hasTextLayer(textLayer)) { - layer.createAndAddNewEditor({ - x: 0, - y: 0 - }, false, { - methodOfCreation, - boxes, - anchorNode, - anchorOffset, - focusNode, - focusOffset, - text - }); - break; - } - } - } - #displayHighlightToolbar() { - const selection = document.getSelection(); - if (!selection || selection.isCollapsed) { - return; - } - const anchorElement = this.#getAnchorElementForSelection(selection); - const textLayer = anchorElement.closest(".textLayer"); - const boxes = this.getSelectionBoxes(textLayer); - if (!boxes) { - return; - } - this.#highlightToolbar ||= new HighlightToolbar(this); - this.#highlightToolbar.show(textLayer, boxes, this.direction === "ltr"); - } - addToAnnotationStorage(editor) { - if (!editor.isEmpty() && this.#annotationStorage && !this.#annotationStorage.has(editor.id)) { - this.#annotationStorage.setValue(editor.id, editor); - } - } - #selectionChange() { - const selection = document.getSelection(); - if (!selection || selection.isCollapsed) { - if (this.#selectedTextNode) { - this.#highlightToolbar?.hide(); - this.#selectedTextNode = null; - this.#dispatchUpdateStates({ - hasSelectedText: false - }); - } - return; - } - const { - anchorNode - } = selection; - if (anchorNode === this.#selectedTextNode) { - return; - } - const anchorElement = this.#getAnchorElementForSelection(selection); - const textLayer = anchorElement.closest(".textLayer"); - if (!textLayer) { - if (this.#selectedTextNode) { - this.#highlightToolbar?.hide(); - this.#selectedTextNode = null; - this.#dispatchUpdateStates({ - hasSelectedText: false - }); - } - return; - } - this.#highlightToolbar?.hide(); - this.#selectedTextNode = anchorNode; - this.#dispatchUpdateStates({ - hasSelectedText: true - }); - if (this.#mode !== AnnotationEditorType.HIGHLIGHT && this.#mode !== AnnotationEditorType.NONE) { - return; - } - if (this.#mode === AnnotationEditorType.HIGHLIGHT) { - this.showAllEditors("highlight", true, true); - } - this.#highlightWhenShiftUp = this.isShiftKeyDown; - if (!this.isShiftKeyDown) { - const pointerup = e => { - if (e.type === "pointerup" && e.button !== 0) { - return; - } - window.removeEventListener("pointerup", pointerup); - window.removeEventListener("blur", pointerup); - if (e.type === "pointerup") { - this.#onSelectEnd("main_toolbar"); - } - }; - window.addEventListener("pointerup", pointerup); - window.addEventListener("blur", pointerup); - } - } - #onSelectEnd(methodOfCreation = "") { - if (this.#mode === AnnotationEditorType.HIGHLIGHT) { - this.highlightSelection(methodOfCreation); - } else if (this.#enableHighlightFloatingButton) { - this.#displayHighlightToolbar(); - } - } - #addSelectionListener() { - document.addEventListener("selectionchange", this.#boundSelectionChange); - } - #removeSelectionListener() { - document.removeEventListener("selectionchange", this.#boundSelectionChange); - } - #addFocusManager() { - window.addEventListener("focus", this.#boundFocus); - window.addEventListener("blur", this.#boundBlur); - } - #removeFocusManager() { - window.removeEventListener("focus", this.#boundFocus); - window.removeEventListener("blur", this.#boundBlur); - } - blur() { - this.isShiftKeyDown = false; - if (this.#highlightWhenShiftUp) { - this.#highlightWhenShiftUp = false; - this.#onSelectEnd("main_toolbar"); - } - if (!this.hasSelection) { - return; - } - const { - activeElement - } = document; - for (const editor of this.#selectedEditors) { - if (editor.div.contains(activeElement)) { - this.#lastActiveElement = [editor, activeElement]; - editor._focusEventsAllowed = false; - break; - } - } - } - focus() { - if (!this.#lastActiveElement) { - return; - } - const [lastEditor, lastActiveElement] = this.#lastActiveElement; - this.#lastActiveElement = null; - lastActiveElement.addEventListener("focusin", () => { - lastEditor._focusEventsAllowed = true; - }, { - once: true - }); - lastActiveElement.focus(); - } - #addKeyboardManager() { - window.addEventListener("keydown", this.#boundKeydown); - window.addEventListener("keyup", this.#boundKeyup); - } - #removeKeyboardManager() { - window.removeEventListener("keydown", this.#boundKeydown); - window.removeEventListener("keyup", this.#boundKeyup); - } - #addCopyPasteListeners() { - document.addEventListener("copy", this.#boundCopy); - document.addEventListener("cut", this.#boundCut); - document.addEventListener("paste", this.#boundPaste); - } - #removeCopyPasteListeners() { - document.removeEventListener("copy", this.#boundCopy); - document.removeEventListener("cut", this.#boundCut); - document.removeEventListener("paste", this.#boundPaste); - } - #addDragAndDropListeners() { - document.addEventListener("dragover", this.#boundDragOver); - document.addEventListener("drop", this.#boundDrop); - } - #removeDragAndDropListeners() { - document.removeEventListener("dragover", this.#boundDragOver); - document.removeEventListener("drop", this.#boundDrop); - } - addEditListeners() { - this.#addKeyboardManager(); - this.#addCopyPasteListeners(); - } - removeEditListeners() { - this.#removeKeyboardManager(); - this.#removeCopyPasteListeners(); - } - dragOver(event) { - for (const { - type - } of event.dataTransfer.items) { - for (const editorType of this.#editorTypes) { - if (editorType.isHandlingMimeForPasting(type)) { - event.dataTransfer.dropEffect = "copy"; - event.preventDefault(); - return; - } - } - } - } - drop(event) { - for (const item of event.dataTransfer.items) { - for (const editorType of this.#editorTypes) { - if (editorType.isHandlingMimeForPasting(item.type)) { - editorType.paste(item, this.currentLayer); - event.preventDefault(); - return; - } - } - } - } - copy(event) { - event.preventDefault(); - this.#activeEditor?.commitOrRemove(); - if (!this.hasSelection) { - return; - } - const editors = []; - for (const editor of this.#selectedEditors) { - const serialized = editor.serialize(true); - if (serialized) { - editors.push(serialized); - } - } - if (editors.length === 0) { - return; - } - event.clipboardData.setData("application/pdfjs", JSON.stringify(editors)); - } - cut(event) { - this.copy(event); - this.delete(); - } - paste(event) { - event.preventDefault(); - const { - clipboardData - } = event; - for (const item of clipboardData.items) { - for (const editorType of this.#editorTypes) { - if (editorType.isHandlingMimeForPasting(item.type)) { - editorType.paste(item, this.currentLayer); - return; - } - } - } - let data = clipboardData.getData("application/pdfjs"); - if (!data) { - return; - } - try { - data = JSON.parse(data); - } catch (ex) { - warn(`paste: "${ex.message}".`); - return; - } - if (!Array.isArray(data)) { - return; - } - this.unselectAll(); - const layer = this.currentLayer; - try { - const newEditors = []; - for (const editor of data) { - const deserializedEditor = layer.deserialize(editor); - if (!deserializedEditor) { - return; - } - newEditors.push(deserializedEditor); - } - const cmd = () => { - for (const editor of newEditors) { - this.#addEditorToLayer(editor); - } - this.#selectEditors(newEditors); - }; - const undo = () => { - for (const editor of newEditors) { - editor.remove(); - } - }; - this.addCommands({ - cmd, - undo, - mustExec: true - }); - } catch (ex) { - warn(`paste: "${ex.message}".`); - } - } - keydown(event) { - if (!this.isShiftKeyDown && event.key === "Shift") { - this.isShiftKeyDown = true; - } - if (this.#mode !== AnnotationEditorType.NONE && !this.isEditorHandlingKeyboard) { - AnnotationEditorUIManager._keyboardManager.exec(this, event); - } - } - keyup(event) { - if (this.isShiftKeyDown && event.key === "Shift") { - this.isShiftKeyDown = false; - if (this.#highlightWhenShiftUp) { - this.#highlightWhenShiftUp = false; - this.#onSelectEnd("main_toolbar"); - } - } - } - onEditingAction({ - name - }) { - switch (name) { - case "undo": - case "redo": - case "delete": - case "selectAll": - this[name](); - break; - case "highlightSelection": - this.highlightSelection("context_menu"); - break; - } - } - #dispatchUpdateStates(details) { - const hasChanged = Object.entries(details).some(([key, value]) => this.#previousStates[key] !== value); - if (hasChanged) { - this._eventBus.dispatch("annotationeditorstateschanged", { - source: this, - details: Object.assign(this.#previousStates, details) - }); - if (this.#mode === AnnotationEditorType.HIGHLIGHT && details.hasSelectedEditor === false) { - this.#dispatchUpdateUI([[AnnotationEditorParamsType.HIGHLIGHT_FREE, true]]); - } - } - } - #dispatchUpdateUI(details) { - this._eventBus.dispatch("annotationeditorparamschanged", { - source: this, - details - }); - } - setEditingState(isEditing) { - if (isEditing) { - this.#addFocusManager(); - this.#addCopyPasteListeners(); - this.#dispatchUpdateStates({ - isEditing: this.#mode !== AnnotationEditorType.NONE, - isEmpty: this.#isEmpty(), - hasSomethingToUndo: this.#commandManager.hasSomethingToUndo(), - hasSomethingToRedo: this.#commandManager.hasSomethingToRedo(), - hasSelectedEditor: false - }); - } else { - this.#removeFocusManager(); - this.#removeCopyPasteListeners(); - this.#dispatchUpdateStates({ - isEditing: false - }); - this.disableUserSelect(false); - } - } - registerEditorTypes(types) { - if (this.#editorTypes) { - return; - } - this.#editorTypes = types; - for (const editorType of this.#editorTypes) { - this.#dispatchUpdateUI(editorType.defaultPropertiesToUpdate); - } - } - getId() { - return this.#idManager.id; - } - get currentLayer() { - return this.#allLayers.get(this.#currentPageIndex); - } - getLayer(pageIndex) { - return this.#allLayers.get(pageIndex); - } - get currentPageIndex() { - return this.#currentPageIndex; - } - addLayer(layer) { - this.#allLayers.set(layer.pageIndex, layer); - if (this.#isEnabled) { - layer.enable(); - } else { - layer.disable(); - } - } - removeLayer(layer) { - this.#allLayers.delete(layer.pageIndex); - } - updateMode(mode, editId = null, isFromKeyboard = false) { - if (this.#mode === mode) { - return; - } - this.#mode = mode; - if (mode === AnnotationEditorType.NONE) { - this.setEditingState(false); - this.#disableAll(); - return; - } - this.setEditingState(true); - this.#enableAll(); - this.unselectAll(); - for (const layer of this.#allLayers.values()) { - layer.updateMode(mode); - } - if (!editId && isFromKeyboard) { - this.addNewEditorFromKeyboard(); - return; - } - if (!editId) { - return; - } - for (const editor of this.#allEditors.values()) { - if (editor.annotationElementId === editId) { - this.setSelected(editor); - editor.enterInEditMode(); - break; - } - } - } - addNewEditorFromKeyboard() { - if (this.currentLayer.canCreateNewEmptyEditor()) { - this.currentLayer.addNewEditor(); - } - } - updateToolbar(mode) { - if (mode === this.#mode) { - return; - } - this._eventBus.dispatch("switchannotationeditormode", { - source: this, - mode - }); - } - updateParams(type, value) { - if (!this.#editorTypes) { - return; - } - switch (type) { - case AnnotationEditorParamsType.CREATE: - this.currentLayer.addNewEditor(); - return; - case AnnotationEditorParamsType.HIGHLIGHT_DEFAULT_COLOR: - this.#mainHighlightColorPicker?.updateColor(value); - break; - case AnnotationEditorParamsType.HIGHLIGHT_SHOW_ALL: - this._eventBus.dispatch("reporttelemetry", { - source: this, - details: { - type: "editing", - data: { - type: "highlight", - action: "toggle_visibility" - } - } - }); - (this.#showAllStates ||= new Map()).set(type, value); - this.showAllEditors("highlight", value); - break; - } - for (const editor of this.#selectedEditors) { - editor.updateParams(type, value); - } - for (const editorType of this.#editorTypes) { - editorType.updateDefaultParams(type, value); - } - } - showAllEditors(type, visible, updateButton = false) { - for (const editor of this.#allEditors.values()) { - if (editor.editorType === type) { - editor.show(visible); - } - } - const state = this.#showAllStates?.get(AnnotationEditorParamsType.HIGHLIGHT_SHOW_ALL) ?? true; - if (state !== visible) { - this.#dispatchUpdateUI([[AnnotationEditorParamsType.HIGHLIGHT_SHOW_ALL, visible]]); - } - } - enableWaiting(mustWait = false) { - if (this.#isWaiting === mustWait) { - return; - } - this.#isWaiting = mustWait; - for (const layer of this.#allLayers.values()) { - if (mustWait) { - layer.disableClick(); - } else { - layer.enableClick(); - } - layer.div.classList.toggle("waiting", mustWait); - } - } - #enableAll() { - if (!this.#isEnabled) { - this.#isEnabled = true; - for (const layer of this.#allLayers.values()) { - layer.enable(); - } - for (const editor of this.#allEditors.values()) { - editor.enable(); - } - } - } - #disableAll() { - this.unselectAll(); - if (this.#isEnabled) { - this.#isEnabled = false; - for (const layer of this.#allLayers.values()) { - layer.disable(); - } - for (const editor of this.#allEditors.values()) { - editor.disable(); - } - } - } - getEditors(pageIndex) { - const editors = []; - for (const editor of this.#allEditors.values()) { - if (editor.pageIndex === pageIndex) { - editors.push(editor); - } - } - return editors; - } - getEditor(id) { - return this.#allEditors.get(id); - } - addEditor(editor) { - this.#allEditors.set(editor.id, editor); - } - removeEditor(editor) { - if (editor.div.contains(document.activeElement)) { - if (this.#focusMainContainerTimeoutId) { - clearTimeout(this.#focusMainContainerTimeoutId); - } - this.#focusMainContainerTimeoutId = setTimeout(() => { - this.focusMainContainer(); - this.#focusMainContainerTimeoutId = null; - }, 0); - } - this.#allEditors.delete(editor.id); - this.unselect(editor); - if (!editor.annotationElementId || !this.#deletedAnnotationsElementIds.has(editor.annotationElementId)) { - this.#annotationStorage?.remove(editor.id); - } - } - addDeletedAnnotationElement(editor) { - this.#deletedAnnotationsElementIds.add(editor.annotationElementId); - this.addChangedExistingAnnotation(editor); - editor.deleted = true; - } - isDeletedAnnotationElement(annotationElementId) { - return this.#deletedAnnotationsElementIds.has(annotationElementId); - } - removeDeletedAnnotationElement(editor) { - this.#deletedAnnotationsElementIds.delete(editor.annotationElementId); - this.removeChangedExistingAnnotation(editor); - editor.deleted = false; - } - #addEditorToLayer(editor) { - const layer = this.#allLayers.get(editor.pageIndex); - if (layer) { - layer.addOrRebuild(editor); - } else { - this.addEditor(editor); - this.addToAnnotationStorage(editor); - } - } - setActiveEditor(editor) { - if (this.#activeEditor === editor) { - return; - } - this.#activeEditor = editor; - if (editor) { - this.#dispatchUpdateUI(editor.propertiesToUpdate); - } - } - get #lastSelectedEditor() { - let ed = null; - for (ed of this.#selectedEditors) {} - return ed; - } - updateUI(editor) { - if (this.#lastSelectedEditor === editor) { - this.#dispatchUpdateUI(editor.propertiesToUpdate); - } - } - toggleSelected(editor) { - if (this.#selectedEditors.has(editor)) { - this.#selectedEditors.delete(editor); - editor.unselect(); - this.#dispatchUpdateStates({ - hasSelectedEditor: this.hasSelection - }); - return; - } - this.#selectedEditors.add(editor); - editor.select(); - this.#dispatchUpdateUI(editor.propertiesToUpdate); - this.#dispatchUpdateStates({ - hasSelectedEditor: true - }); - } - setSelected(editor) { - for (const ed of this.#selectedEditors) { - if (ed !== editor) { - ed.unselect(); - } - } - this.#selectedEditors.clear(); - this.#selectedEditors.add(editor); - editor.select(); - this.#dispatchUpdateUI(editor.propertiesToUpdate); - this.#dispatchUpdateStates({ - hasSelectedEditor: true - }); - } - isSelected(editor) { - return this.#selectedEditors.has(editor); - } - get firstSelectedEditor() { - return this.#selectedEditors.values().next().value; - } - unselect(editor) { - editor.unselect(); - this.#selectedEditors.delete(editor); - this.#dispatchUpdateStates({ - hasSelectedEditor: this.hasSelection - }); - } - get hasSelection() { - return this.#selectedEditors.size !== 0; - } - get isEnterHandled() { - return this.#selectedEditors.size === 1 && this.firstSelectedEditor.isEnterHandled; - } - undo() { - this.#commandManager.undo(); - this.#dispatchUpdateStates({ - hasSomethingToUndo: this.#commandManager.hasSomethingToUndo(), - hasSomethingToRedo: true, - isEmpty: this.#isEmpty() - }); - } - redo() { - this.#commandManager.redo(); - this.#dispatchUpdateStates({ - hasSomethingToUndo: true, - hasSomethingToRedo: this.#commandManager.hasSomethingToRedo(), - isEmpty: this.#isEmpty() - }); - } - addCommands(params) { - this.#commandManager.add(params); - this.#dispatchUpdateStates({ - hasSomethingToUndo: true, - hasSomethingToRedo: false, - isEmpty: this.#isEmpty() - }); - } - #isEmpty() { - if (this.#allEditors.size === 0) { - return true; - } - if (this.#allEditors.size === 1) { - for (const editor of this.#allEditors.values()) { - return editor.isEmpty(); - } - } - return false; - } - delete() { - this.commitOrRemove(); - if (!this.hasSelection) { - return; - } - const editors = [...this.#selectedEditors]; - const cmd = () => { - for (const editor of editors) { - editor.remove(); - } - }; - const undo = () => { - for (const editor of editors) { - this.#addEditorToLayer(editor); - } - }; - this.addCommands({ - cmd, - undo, - mustExec: true - }); - } - commitOrRemove() { - this.#activeEditor?.commitOrRemove(); - } - hasSomethingToControl() { - return this.#activeEditor || this.hasSelection; - } - #selectEditors(editors) { - for (const editor of this.#selectedEditors) { - editor.unselect(); - } - this.#selectedEditors.clear(); - for (const editor of editors) { - if (editor.isEmpty()) { - continue; - } - this.#selectedEditors.add(editor); - editor.select(); - } - this.#dispatchUpdateStates({ - hasSelectedEditor: this.hasSelection - }); - } - selectAll() { - for (const editor of this.#selectedEditors) { - editor.commit(); - } - this.#selectEditors(this.#allEditors.values()); - } - unselectAll() { - if (this.#activeEditor) { - this.#activeEditor.commitOrRemove(); - if (this.#mode !== AnnotationEditorType.NONE) { - return; - } - } - if (!this.hasSelection) { - return; - } - for (const editor of this.#selectedEditors) { - editor.unselect(); - } - this.#selectedEditors.clear(); - this.#dispatchUpdateStates({ - hasSelectedEditor: false - }); - } - translateSelectedEditors(x, y, noCommit = false) { - if (!noCommit) { - this.commitOrRemove(); - } - if (!this.hasSelection) { - return; - } - this.#translation[0] += x; - this.#translation[1] += y; - const [totalX, totalY] = this.#translation; - const editors = [...this.#selectedEditors]; - const TIME_TO_WAIT = 1000; - if (this.#translationTimeoutId) { - clearTimeout(this.#translationTimeoutId); - } - this.#translationTimeoutId = setTimeout(() => { - this.#translationTimeoutId = null; - this.#translation[0] = this.#translation[1] = 0; - this.addCommands({ - cmd: () => { - for (const editor of editors) { - if (this.#allEditors.has(editor.id)) { - editor.translateInPage(totalX, totalY); - } - } - }, - undo: () => { - for (const editor of editors) { - if (this.#allEditors.has(editor.id)) { - editor.translateInPage(-totalX, -totalY); - } - } - }, - mustExec: false - }); - }, TIME_TO_WAIT); - for (const editor of editors) { - editor.translateInPage(x, y); - } - } - setUpDragSession() { - if (!this.hasSelection) { - return; - } - this.disableUserSelect(true); - this.#draggingEditors = new Map(); - for (const editor of this.#selectedEditors) { - this.#draggingEditors.set(editor, { - savedX: editor.x, - savedY: editor.y, - savedPageIndex: editor.pageIndex, - newX: 0, - newY: 0, - newPageIndex: -1 - }); - } - } - endDragSession() { - if (!this.#draggingEditors) { - return false; - } - this.disableUserSelect(false); - const map = this.#draggingEditors; - this.#draggingEditors = null; - let mustBeAddedInUndoStack = false; - for (const [{ - x, - y, - pageIndex - }, value] of map) { - value.newX = x; - value.newY = y; - value.newPageIndex = pageIndex; - mustBeAddedInUndoStack ||= x !== value.savedX || y !== value.savedY || pageIndex !== value.savedPageIndex; - } - if (!mustBeAddedInUndoStack) { - return false; - } - const move = (editor, x, y, pageIndex) => { - if (this.#allEditors.has(editor.id)) { - const parent = this.#allLayers.get(pageIndex); - if (parent) { - editor._setParentAndPosition(parent, x, y); - } else { - editor.pageIndex = pageIndex; - editor.x = x; - editor.y = y; - } - } - }; - this.addCommands({ - cmd: () => { - for (const [editor, { - newX, - newY, - newPageIndex - }] of map) { - move(editor, newX, newY, newPageIndex); - } - }, - undo: () => { - for (const [editor, { - savedX, - savedY, - savedPageIndex - }] of map) { - move(editor, savedX, savedY, savedPageIndex); - } - }, - mustExec: true - }); - return true; - } - dragSelectedEditors(tx, ty) { - if (!this.#draggingEditors) { - return; - } - for (const editor of this.#draggingEditors.keys()) { - editor.drag(tx, ty); - } - } - rebuild(editor) { - if (editor.parent === null) { - const parent = this.getLayer(editor.pageIndex); - if (parent) { - parent.changeParent(editor); - parent.addOrRebuild(editor); - } else { - this.addEditor(editor); - this.addToAnnotationStorage(editor); - editor.rebuild(); - } - } else { - editor.parent.addOrRebuild(editor); - } - } - get isEditorHandlingKeyboard() { - return this.getActive()?.shouldGetKeyboardEvents() || this.#selectedEditors.size === 1 && this.firstSelectedEditor.shouldGetKeyboardEvents(); - } - isActive(editor) { - return this.#activeEditor === editor; - } - getActive() { - return this.#activeEditor; - } - getMode() { - return this.#mode; - } - get imageManager() { - return shadow(this, "imageManager", new ImageManager()); - } - getSelectionBoxes(textLayer) { - if (!textLayer) { - return null; - } - const selection = document.getSelection(); - for (let i = 0, ii = selection.rangeCount; i < ii; i++) { - if (!textLayer.contains(selection.getRangeAt(i).commonAncestorContainer)) { - return null; - } - } - const { - x: layerX, - y: layerY, - width: parentWidth, - height: parentHeight - } = textLayer.getBoundingClientRect(); - let rotator; - switch (textLayer.getAttribute("data-main-rotation")) { - case "90": - rotator = (x, y, w, h) => ({ - x: (y - layerY) / parentHeight, - y: 1 - (x + w - layerX) / parentWidth, - width: h / parentHeight, - height: w / parentWidth - }); - break; - case "180": - rotator = (x, y, w, h) => ({ - x: 1 - (x + w - layerX) / parentWidth, - y: 1 - (y + h - layerY) / parentHeight, - width: w / parentWidth, - height: h / parentHeight - }); - break; - case "270": - rotator = (x, y, w, h) => ({ - x: 1 - (y + h - layerY) / parentHeight, - y: (x - layerX) / parentWidth, - width: h / parentHeight, - height: w / parentWidth - }); - break; - default: - rotator = (x, y, w, h) => ({ - x: (x - layerX) / parentWidth, - y: (y - layerY) / parentHeight, - width: w / parentWidth, - height: h / parentHeight - }); - break; - } - const boxes = []; - for (let i = 0, ii = selection.rangeCount; i < ii; i++) { - const range = selection.getRangeAt(i); - if (range.collapsed) { - continue; - } - for (const { - x, - y, - width, - height - } of range.getClientRects()) { - if (width === 0 || height === 0) { - continue; - } - boxes.push(rotator(x, y, width, height)); - } - } - return boxes.length === 0 ? null : boxes; - } - addChangedExistingAnnotation({ - annotationElementId, - id - }) { - (this.#changedExistingAnnotations ||= new Map()).set(annotationElementId, id); - } - removeChangedExistingAnnotation({ - annotationElementId - }) { - this.#changedExistingAnnotations?.delete(annotationElementId); - } - renderAnnotationElement(annotation) { - const editorId = this.#changedExistingAnnotations?.get(annotation.data.id); - if (!editorId) { - return; - } - const editor = this.#annotationStorage.getRawValue(editorId); - if (!editor) { - return; - } - if (this.#mode === AnnotationEditorType.NONE && !editor.hasBeenModified) { - return; - } - editor.renderAnnotationElement(annotation); - } -} - -;// CONCATENATED MODULE: ./src/display/editor/alt_text.js - -class AltText { - #altText = ""; - #altTextDecorative = false; - #altTextButton = null; - #altTextTooltip = null; - #altTextTooltipTimeout = null; - #altTextWasFromKeyBoard = false; - #editor = null; - static _l10nPromise = null; - constructor(editor) { - this.#editor = editor; - } - static initialize(l10nPromise) { - AltText._l10nPromise ||= l10nPromise; - } - async render() { - const altText = this.#altTextButton = document.createElement("button"); - altText.className = "altText"; - const msg = await AltText._l10nPromise.get("pdfjs-editor-alt-text-button-label"); - altText.textContent = msg; - altText.setAttribute("aria-label", msg); - altText.tabIndex = "0"; - altText.addEventListener("contextmenu", noContextMenu); - altText.addEventListener("pointerdown", event => event.stopPropagation()); - const onClick = event => { - event.preventDefault(); - this.#editor._uiManager.editAltText(this.#editor); - }; - altText.addEventListener("click", onClick, { - capture: true - }); - altText.addEventListener("keydown", event => { - if (event.target === altText && event.key === "Enter") { - this.#altTextWasFromKeyBoard = true; - onClick(event); - } - }); - await this.#setState(); - return altText; - } - finish() { - if (!this.#altTextButton) { - return; - } - this.#altTextButton.focus({ - focusVisible: this.#altTextWasFromKeyBoard - }); - this.#altTextWasFromKeyBoard = false; - } - isEmpty() { - return !this.#altText && !this.#altTextDecorative; - } - get data() { - return { - altText: this.#altText, - decorative: this.#altTextDecorative - }; - } - set data({ - altText, - decorative - }) { - if (this.#altText === altText && this.#altTextDecorative === decorative) { - return; - } - this.#altText = altText; - this.#altTextDecorative = decorative; - this.#setState(); - } - toggle(enabled = false) { - if (!this.#altTextButton) { - return; - } - if (!enabled && this.#altTextTooltipTimeout) { - clearTimeout(this.#altTextTooltipTimeout); - this.#altTextTooltipTimeout = null; - } - this.#altTextButton.disabled = !enabled; - } - destroy() { - this.#altTextButton?.remove(); - this.#altTextButton = null; - this.#altTextTooltip = null; - } - async #setState() { - const button = this.#altTextButton; - if (!button) { - return; - } - if (!this.#altText && !this.#altTextDecorative) { - button.classList.remove("done"); - this.#altTextTooltip?.remove(); - return; - } - button.classList.add("done"); - AltText._l10nPromise.get("pdfjs-editor-alt-text-edit-button-label").then(msg => { - button.setAttribute("aria-label", msg); - }); - let tooltip = this.#altTextTooltip; - if (!tooltip) { - this.#altTextTooltip = tooltip = document.createElement("span"); - tooltip.className = "tooltip"; - tooltip.setAttribute("role", "tooltip"); - const id = tooltip.id = `alt-text-tooltip-${this.#editor.id}`; - button.setAttribute("aria-describedby", id); - const DELAY_TO_SHOW_TOOLTIP = 100; - button.addEventListener("mouseenter", () => { - this.#altTextTooltipTimeout = setTimeout(() => { - this.#altTextTooltipTimeout = null; - this.#altTextTooltip.classList.add("show"); - this.#editor._reportTelemetry({ - action: "alt_text_tooltip" - }); - }, DELAY_TO_SHOW_TOOLTIP); - }); - button.addEventListener("mouseleave", () => { - if (this.#altTextTooltipTimeout) { - clearTimeout(this.#altTextTooltipTimeout); - this.#altTextTooltipTimeout = null; - } - this.#altTextTooltip?.classList.remove("show"); - }); - } - tooltip.innerText = this.#altTextDecorative ? await AltText._l10nPromise.get("pdfjs-editor-alt-text-decorative-tooltip") : this.#altText; - if (!tooltip.parentNode) { - button.append(tooltip); - } - const element = this.#editor.getImageForAltText(); - element?.setAttribute("aria-describedby", tooltip.id); - } -} - -;// CONCATENATED MODULE: ./src/display/editor/editor.js - - - - - -class AnnotationEditor { - #allResizerDivs = null; - #altText = null; - #disabled = false; - #keepAspectRatio = false; - #resizersDiv = null; - #savedDimensions = null; - #boundFocusin = this.focusin.bind(this); - #boundFocusout = this.focusout.bind(this); - #editToolbar = null; - #focusedResizerName = ""; - #hasBeenClicked = false; - #initialPosition = null; - #isEditing = false; - #isInEditMode = false; - #isResizerEnabledForKeyboard = false; - #moveInDOMTimeout = null; - #prevDragX = 0; - #prevDragY = 0; - #telemetryTimeouts = null; - _initialOptions = Object.create(null); - _isVisible = true; - _uiManager = null; - _focusEventsAllowed = true; - _l10nPromise = null; - #isDraggable = false; - #zIndex = AnnotationEditor._zIndex++; - static _borderLineWidth = -1; - static _colorManager = new ColorManager(); - static _zIndex = 1; - static _telemetryTimeout = 1000; - static get _resizerKeyboardManager() { - const resize = AnnotationEditor.prototype._resizeWithKeyboard; - const small = AnnotationEditorUIManager.TRANSLATE_SMALL; - const big = AnnotationEditorUIManager.TRANSLATE_BIG; - return shadow(this, "_resizerKeyboardManager", new KeyboardManager([[["ArrowLeft", "mac+ArrowLeft"], resize, { - args: [-small, 0] - }], [["ctrl+ArrowLeft", "mac+shift+ArrowLeft"], resize, { - args: [-big, 0] - }], [["ArrowRight", "mac+ArrowRight"], resize, { - args: [small, 0] - }], [["ctrl+ArrowRight", "mac+shift+ArrowRight"], resize, { - args: [big, 0] - }], [["ArrowUp", "mac+ArrowUp"], resize, { - args: [0, -small] - }], [["ctrl+ArrowUp", "mac+shift+ArrowUp"], resize, { - args: [0, -big] - }], [["ArrowDown", "mac+ArrowDown"], resize, { - args: [0, small] - }], [["ctrl+ArrowDown", "mac+shift+ArrowDown"], resize, { - args: [0, big] - }], [["Escape", "mac+Escape"], AnnotationEditor.prototype._stopResizingWithKeyboard]])); - } - constructor(parameters) { - if (this.constructor === AnnotationEditor) { - unreachable("Cannot initialize AnnotationEditor."); - } - this.parent = parameters.parent; - this.id = parameters.id; - this.width = this.height = null; - this.pageIndex = parameters.parent.pageIndex; - this.name = parameters.name; - this.div = null; - this._uiManager = parameters.uiManager; - this.annotationElementId = null; - this._willKeepAspectRatio = false; - this._initialOptions.isCentered = parameters.isCentered; - this._structTreeParentId = null; - const { - rotation, - rawDims: { - pageWidth, - pageHeight, - pageX, - pageY - } - } = this.parent.viewport; - this.rotation = rotation; - this.pageRotation = (360 + rotation - this._uiManager.viewParameters.rotation) % 360; - this.pageDimensions = [pageWidth, pageHeight]; - this.pageTranslation = [pageX, pageY]; - const [width, height] = this.parentDimensions; - this.x = parameters.x / width; - this.y = parameters.y / height; - this.isAttachedToDOM = false; - this.deleted = false; - } - get editorType() { - return Object.getPrototypeOf(this).constructor._type; - } - static get _defaultLineColor() { - return shadow(this, "_defaultLineColor", this._colorManager.getHexCode("CanvasText")); - } - static deleteAnnotationElement(editor) { - const fakeEditor = new FakeEditor({ - id: editor.parent.getNextId(), - parent: editor.parent, - uiManager: editor._uiManager - }); - fakeEditor.annotationElementId = editor.annotationElementId; - fakeEditor.deleted = true; - fakeEditor._uiManager.addToAnnotationStorage(fakeEditor); - } - static initialize(l10n, _uiManager, options) { - AnnotationEditor._l10nPromise ||= new Map(["pdfjs-editor-alt-text-button-label", "pdfjs-editor-alt-text-edit-button-label", "pdfjs-editor-alt-text-decorative-tooltip", "pdfjs-editor-resizer-label-topLeft", "pdfjs-editor-resizer-label-topMiddle", "pdfjs-editor-resizer-label-topRight", "pdfjs-editor-resizer-label-middleRight", "pdfjs-editor-resizer-label-bottomRight", "pdfjs-editor-resizer-label-bottomMiddle", "pdfjs-editor-resizer-label-bottomLeft", "pdfjs-editor-resizer-label-middleLeft"].map(str => [str, l10n.get(str.replaceAll(/([A-Z])/g, c => `-${c.toLowerCase()}`))])); - if (options?.strings) { - for (const str of options.strings) { - AnnotationEditor._l10nPromise.set(str, l10n.get(str)); - } - } - if (AnnotationEditor._borderLineWidth !== -1) { - return; - } - const style = getComputedStyle(document.documentElement); - AnnotationEditor._borderLineWidth = parseFloat(style.getPropertyValue("--outline-width")) || 0; - } - static updateDefaultParams(_type, _value) {} - static get defaultPropertiesToUpdate() { - return []; - } - static isHandlingMimeForPasting(mime) { - return false; - } - static paste(item, parent) { - unreachable("Not implemented"); - } - get propertiesToUpdate() { - return []; - } - get _isDraggable() { - return this.#isDraggable; - } - set _isDraggable(value) { - this.#isDraggable = value; - this.div?.classList.toggle("draggable", value); - } - get isEnterHandled() { - return true; - } - center() { - const [pageWidth, pageHeight] = this.pageDimensions; - switch (this.parentRotation) { - case 90: - this.x -= this.height * pageHeight / (pageWidth * 2); - this.y += this.width * pageWidth / (pageHeight * 2); - break; - case 180: - this.x += this.width / 2; - this.y += this.height / 2; - break; - case 270: - this.x += this.height * pageHeight / (pageWidth * 2); - this.y -= this.width * pageWidth / (pageHeight * 2); - break; - default: - this.x -= this.width / 2; - this.y -= this.height / 2; - break; - } - this.fixAndSetPosition(); - } - addCommands(params) { - this._uiManager.addCommands(params); - } - get currentLayer() { - return this._uiManager.currentLayer; - } - setInBackground() { - this.div.style.zIndex = 0; - } - setInForeground() { - this.div.style.zIndex = this.#zIndex; - } - setParent(parent) { - if (parent !== null) { - this.pageIndex = parent.pageIndex; - this.pageDimensions = parent.pageDimensions; - } else { - this.#stopResizing(); - } - this.parent = parent; - } - focusin(event) { - if (!this._focusEventsAllowed) { - return; - } - if (!this.#hasBeenClicked) { - this.parent.setSelected(this); - } else { - this.#hasBeenClicked = false; - } - } - focusout(event) { - if (!this._focusEventsAllowed) { - return; - } - if (!this.isAttachedToDOM) { - return; - } - const target = event.relatedTarget; - if (target?.closest(`#${this.id}`)) { - return; - } - event.preventDefault(); - if (!this.parent?.isMultipleSelection) { - this.commitOrRemove(); - } - } - commitOrRemove() { - if (this.isEmpty()) { - this.remove(); - } else { - this.commit(); - } - } - commit() { - this.addToAnnotationStorage(); - } - addToAnnotationStorage() { - this._uiManager.addToAnnotationStorage(this); - } - setAt(x, y, tx, ty) { - const [width, height] = this.parentDimensions; - [tx, ty] = this.screenToPageTranslation(tx, ty); - this.x = (x + tx) / width; - this.y = (y + ty) / height; - this.fixAndSetPosition(); - } - #translate([width, height], x, y) { - [x, y] = this.screenToPageTranslation(x, y); - this.x += x / width; - this.y += y / height; - this.fixAndSetPosition(); - } - translate(x, y) { - this.#translate(this.parentDimensions, x, y); - } - translateInPage(x, y) { - this.#initialPosition ||= [this.x, this.y]; - this.#translate(this.pageDimensions, x, y); - this.div.scrollIntoView({ - block: "nearest" - }); - } - drag(tx, ty) { - this.#initialPosition ||= [this.x, this.y]; - const [parentWidth, parentHeight] = this.parentDimensions; - this.x += tx / parentWidth; - this.y += ty / parentHeight; - if (this.parent && (this.x < 0 || this.x > 1 || this.y < 0 || this.y > 1)) { - const { - x, - y - } = this.div.getBoundingClientRect(); - if (this.parent.findNewParent(this, x, y)) { - this.x -= Math.floor(this.x); - this.y -= Math.floor(this.y); - } - } - let { - x, - y - } = this; - const [bx, by] = this.getBaseTranslation(); - x += bx; - y += by; - this.div.style.left = `${(100 * x).toFixed(2)}%`; - this.div.style.top = `${(100 * y).toFixed(2)}%`; - this.div.scrollIntoView({ - block: "nearest" - }); - } - get _hasBeenMoved() { - return !!this.#initialPosition && (this.#initialPosition[0] !== this.x || this.#initialPosition[1] !== this.y); - } - getBaseTranslation() { - const [parentWidth, parentHeight] = this.parentDimensions; - const { - _borderLineWidth - } = AnnotationEditor; - const x = _borderLineWidth / parentWidth; - const y = _borderLineWidth / parentHeight; - switch (this.rotation) { - case 90: - return [-x, y]; - case 180: - return [x, y]; - case 270: - return [x, -y]; - default: - return [-x, -y]; - } - } - get _mustFixPosition() { - return true; - } - fixAndSetPosition(rotation = this.rotation) { - const [pageWidth, pageHeight] = this.pageDimensions; - let { - x, - y, - width, - height - } = this; - width *= pageWidth; - height *= pageHeight; - x *= pageWidth; - y *= pageHeight; - if (this._mustFixPosition) { - switch (rotation) { - case 0: - x = Math.max(0, Math.min(pageWidth - width, x)); - y = Math.max(0, Math.min(pageHeight - height, y)); - break; - case 90: - x = Math.max(0, Math.min(pageWidth - height, x)); - y = Math.min(pageHeight, Math.max(width, y)); - break; - case 180: - x = Math.min(pageWidth, Math.max(width, x)); - y = Math.min(pageHeight, Math.max(height, y)); - break; - case 270: - x = Math.min(pageWidth, Math.max(height, x)); - y = Math.max(0, Math.min(pageHeight - width, y)); - break; - } - } - this.x = x /= pageWidth; - this.y = y /= pageHeight; - const [bx, by] = this.getBaseTranslation(); - x += bx; - y += by; - const { - style - } = this.div; - style.left = `${(100 * x).toFixed(2)}%`; - style.top = `${(100 * y).toFixed(2)}%`; - this.moveInDOM(); - } - static #rotatePoint(x, y, angle) { - switch (angle) { - case 90: - return [y, -x]; - case 180: - return [-x, -y]; - case 270: - return [-y, x]; - default: - return [x, y]; - } - } - screenToPageTranslation(x, y) { - return AnnotationEditor.#rotatePoint(x, y, this.parentRotation); - } - pageTranslationToScreen(x, y) { - return AnnotationEditor.#rotatePoint(x, y, 360 - this.parentRotation); - } - #getRotationMatrix(rotation) { - switch (rotation) { - case 90: - { - const [pageWidth, pageHeight] = this.pageDimensions; - return [0, -pageWidth / pageHeight, pageHeight / pageWidth, 0]; - } - case 180: - return [-1, 0, 0, -1]; - case 270: - { - const [pageWidth, pageHeight] = this.pageDimensions; - return [0, pageWidth / pageHeight, -pageHeight / pageWidth, 0]; - } - default: - return [1, 0, 0, 1]; - } - } - get parentScale() { - return this._uiManager.viewParameters.realScale; - } - get parentRotation() { - return (this._uiManager.viewParameters.rotation + this.pageRotation) % 360; - } - get parentDimensions() { - const { - parentScale, - pageDimensions: [pageWidth, pageHeight] - } = this; - const scaledWidth = pageWidth * parentScale; - const scaledHeight = pageHeight * parentScale; - return util_FeatureTest.isCSSRoundSupported ? [Math.round(scaledWidth), Math.round(scaledHeight)] : [scaledWidth, scaledHeight]; - } - setDims(width, height) { - const [parentWidth, parentHeight] = this.parentDimensions; - this.div.style.width = `${(100 * width / parentWidth).toFixed(2)}%`; - if (!this.#keepAspectRatio) { - this.div.style.height = `${(100 * height / parentHeight).toFixed(2)}%`; - } - } - fixDims() { - const { - style - } = this.div; - const { - height, - width - } = style; - const widthPercent = width.endsWith("%"); - const heightPercent = !this.#keepAspectRatio && height.endsWith("%"); - if (widthPercent && heightPercent) { - return; - } - const [parentWidth, parentHeight] = this.parentDimensions; - if (!widthPercent) { - style.width = `${(100 * parseFloat(width) / parentWidth).toFixed(2)}%`; - } - if (!this.#keepAspectRatio && !heightPercent) { - style.height = `${(100 * parseFloat(height) / parentHeight).toFixed(2)}%`; - } - } - getInitialTranslation() { - return [0, 0]; - } - #createResizers() { - if (this.#resizersDiv) { - return; - } - this.#resizersDiv = document.createElement("div"); - this.#resizersDiv.classList.add("resizers"); - const classes = this._willKeepAspectRatio ? ["topLeft", "topRight", "bottomRight", "bottomLeft"] : ["topLeft", "topMiddle", "topRight", "middleRight", "bottomRight", "bottomMiddle", "bottomLeft", "middleLeft"]; - for (const name of classes) { - const div = document.createElement("div"); - this.#resizersDiv.append(div); - div.classList.add("resizer", name); - div.setAttribute("data-resizer-name", name); - div.addEventListener("pointerdown", this.#resizerPointerdown.bind(this, name)); - div.addEventListener("contextmenu", noContextMenu); - div.tabIndex = -1; - } - this.div.prepend(this.#resizersDiv); - } - #resizerPointerdown(name, event) { - event.preventDefault(); - const { - isMac - } = util_FeatureTest.platform; - if (event.button !== 0 || event.ctrlKey && isMac) { - return; - } - this.#altText?.toggle(false); - const boundResizerPointermove = this.#resizerPointermove.bind(this, name); - const savedDraggable = this._isDraggable; - this._isDraggable = false; - const pointerMoveOptions = { - passive: true, - capture: true - }; - this.parent.togglePointerEvents(false); - window.addEventListener("pointermove", boundResizerPointermove, pointerMoveOptions); - window.addEventListener("contextmenu", noContextMenu); - const savedX = this.x; - const savedY = this.y; - const savedWidth = this.width; - const savedHeight = this.height; - const savedParentCursor = this.parent.div.style.cursor; - const savedCursor = this.div.style.cursor; - this.div.style.cursor = this.parent.div.style.cursor = window.getComputedStyle(event.target).cursor; - const pointerUpCallback = () => { - this.parent.togglePointerEvents(true); - this.#altText?.toggle(true); - this._isDraggable = savedDraggable; - window.removeEventListener("pointerup", pointerUpCallback); - window.removeEventListener("blur", pointerUpCallback); - window.removeEventListener("pointermove", boundResizerPointermove, pointerMoveOptions); - window.removeEventListener("contextmenu", noContextMenu); - this.parent.div.style.cursor = savedParentCursor; - this.div.style.cursor = savedCursor; - this.#addResizeToUndoStack(savedX, savedY, savedWidth, savedHeight); - }; - window.addEventListener("pointerup", pointerUpCallback); - window.addEventListener("blur", pointerUpCallback); - } - #addResizeToUndoStack(savedX, savedY, savedWidth, savedHeight) { - const newX = this.x; - const newY = this.y; - const newWidth = this.width; - const newHeight = this.height; - if (newX === savedX && newY === savedY && newWidth === savedWidth && newHeight === savedHeight) { - return; - } - this.addCommands({ - cmd: () => { - this.width = newWidth; - this.height = newHeight; - this.x = newX; - this.y = newY; - const [parentWidth, parentHeight] = this.parentDimensions; - this.setDims(parentWidth * newWidth, parentHeight * newHeight); - this.fixAndSetPosition(); - }, - undo: () => { - this.width = savedWidth; - this.height = savedHeight; - this.x = savedX; - this.y = savedY; - const [parentWidth, parentHeight] = this.parentDimensions; - this.setDims(parentWidth * savedWidth, parentHeight * savedHeight); - this.fixAndSetPosition(); - }, - mustExec: true - }); - } - #resizerPointermove(name, event) { - const [parentWidth, parentHeight] = this.parentDimensions; - const savedX = this.x; - const savedY = this.y; - const savedWidth = this.width; - const savedHeight = this.height; - const minWidth = AnnotationEditor.MIN_SIZE / parentWidth; - const minHeight = AnnotationEditor.MIN_SIZE / parentHeight; - const round = x => Math.round(x * 10000) / 10000; - const rotationMatrix = this.#getRotationMatrix(this.rotation); - const transf = (x, y) => [rotationMatrix[0] * x + rotationMatrix[2] * y, rotationMatrix[1] * x + rotationMatrix[3] * y]; - const invRotationMatrix = this.#getRotationMatrix(360 - this.rotation); - const invTransf = (x, y) => [invRotationMatrix[0] * x + invRotationMatrix[2] * y, invRotationMatrix[1] * x + invRotationMatrix[3] * y]; - let getPoint; - let getOpposite; - let isDiagonal = false; - let isHorizontal = false; - switch (name) { - case "topLeft": - isDiagonal = true; - getPoint = (w, h) => [0, 0]; - getOpposite = (w, h) => [w, h]; - break; - case "topMiddle": - getPoint = (w, h) => [w / 2, 0]; - getOpposite = (w, h) => [w / 2, h]; - break; - case "topRight": - isDiagonal = true; - getPoint = (w, h) => [w, 0]; - getOpposite = (w, h) => [0, h]; - break; - case "middleRight": - isHorizontal = true; - getPoint = (w, h) => [w, h / 2]; - getOpposite = (w, h) => [0, h / 2]; - break; - case "bottomRight": - isDiagonal = true; - getPoint = (w, h) => [w, h]; - getOpposite = (w, h) => [0, 0]; - break; - case "bottomMiddle": - getPoint = (w, h) => [w / 2, h]; - getOpposite = (w, h) => [w / 2, 0]; - break; - case "bottomLeft": - isDiagonal = true; - getPoint = (w, h) => [0, h]; - getOpposite = (w, h) => [w, 0]; - break; - case "middleLeft": - isHorizontal = true; - getPoint = (w, h) => [0, h / 2]; - getOpposite = (w, h) => [w, h / 2]; - break; - } - const point = getPoint(savedWidth, savedHeight); - const oppositePoint = getOpposite(savedWidth, savedHeight); - let transfOppositePoint = transf(...oppositePoint); - const oppositeX = round(savedX + transfOppositePoint[0]); - const oppositeY = round(savedY + transfOppositePoint[1]); - let ratioX = 1; - let ratioY = 1; - let [deltaX, deltaY] = this.screenToPageTranslation(event.movementX, event.movementY); - [deltaX, deltaY] = invTransf(deltaX / parentWidth, deltaY / parentHeight); - if (isDiagonal) { - const oldDiag = Math.hypot(savedWidth, savedHeight); - ratioX = ratioY = Math.max(Math.min(Math.hypot(oppositePoint[0] - point[0] - deltaX, oppositePoint[1] - point[1] - deltaY) / oldDiag, 1 / savedWidth, 1 / savedHeight), minWidth / savedWidth, minHeight / savedHeight); - } else if (isHorizontal) { - ratioX = Math.max(minWidth, Math.min(1, Math.abs(oppositePoint[0] - point[0] - deltaX))) / savedWidth; - } else { - ratioY = Math.max(minHeight, Math.min(1, Math.abs(oppositePoint[1] - point[1] - deltaY))) / savedHeight; - } - const newWidth = round(savedWidth * ratioX); - const newHeight = round(savedHeight * ratioY); - transfOppositePoint = transf(...getOpposite(newWidth, newHeight)); - const newX = oppositeX - transfOppositePoint[0]; - const newY = oppositeY - transfOppositePoint[1]; - this.width = newWidth; - this.height = newHeight; - this.x = newX; - this.y = newY; - this.setDims(parentWidth * newWidth, parentHeight * newHeight); - this.fixAndSetPosition(); - } - altTextFinish() { - this.#altText?.finish(); - } - async addEditToolbar() { - if (this.#editToolbar || this.#isInEditMode) { - return this.#editToolbar; - } - this.#editToolbar = new EditorToolbar(this); - this.div.append(this.#editToolbar.render()); - if (this.#altText) { - this.#editToolbar.addAltTextButton(await this.#altText.render()); - } - return this.#editToolbar; - } - removeEditToolbar() { - if (!this.#editToolbar) { - return; - } - this.#editToolbar.remove(); - this.#editToolbar = null; - this.#altText?.destroy(); - } - getClientDimensions() { - return this.div.getBoundingClientRect(); - } - async addAltTextButton() { - if (this.#altText) { - return; - } - AltText.initialize(AnnotationEditor._l10nPromise); - this.#altText = new AltText(this); - await this.addEditToolbar(); - } - get altTextData() { - return this.#altText?.data; - } - set altTextData(data) { - if (!this.#altText) { - return; - } - this.#altText.data = data; - } - hasAltText() { - return !this.#altText?.isEmpty(); - } - render() { - this.div = document.createElement("div"); - this.div.setAttribute("data-editor-rotation", (360 - this.rotation) % 360); - this.div.className = this.name; - this.div.setAttribute("id", this.id); - this.div.tabIndex = this.#disabled ? -1 : 0; - if (!this._isVisible) { - this.div.classList.add("hidden"); - } - this.setInForeground(); - this.div.addEventListener("focusin", this.#boundFocusin); - this.div.addEventListener("focusout", this.#boundFocusout); - const [parentWidth, parentHeight] = this.parentDimensions; - if (this.parentRotation % 180 !== 0) { - this.div.style.maxWidth = `${(100 * parentHeight / parentWidth).toFixed(2)}%`; - this.div.style.maxHeight = `${(100 * parentWidth / parentHeight).toFixed(2)}%`; - } - const [tx, ty] = this.getInitialTranslation(); - this.translate(tx, ty); - bindEvents(this, this.div, ["pointerdown"]); - return this.div; - } - pointerdown(event) { - const { - isMac - } = util_FeatureTest.platform; - if (event.button !== 0 || event.ctrlKey && isMac) { - event.preventDefault(); - return; - } - this.#hasBeenClicked = true; - if (this._isDraggable) { - this.#setUpDragSession(event); - return; - } - this.#selectOnPointerEvent(event); - } - #selectOnPointerEvent(event) { - const { - isMac - } = util_FeatureTest.platform; - if (event.ctrlKey && !isMac || event.shiftKey || event.metaKey && isMac) { - this.parent.toggleSelected(this); - } else { - this.parent.setSelected(this); - } - } - #setUpDragSession(event) { - const isSelected = this._uiManager.isSelected(this); - this._uiManager.setUpDragSession(); - let pointerMoveOptions, pointerMoveCallback; - if (isSelected) { - this.div.classList.add("moving"); - pointerMoveOptions = { - passive: true, - capture: true - }; - this.#prevDragX = event.clientX; - this.#prevDragY = event.clientY; - pointerMoveCallback = e => { - const { - clientX: x, - clientY: y - } = e; - const [tx, ty] = this.screenToPageTranslation(x - this.#prevDragX, y - this.#prevDragY); - this.#prevDragX = x; - this.#prevDragY = y; - this._uiManager.dragSelectedEditors(tx, ty); - }; - window.addEventListener("pointermove", pointerMoveCallback, pointerMoveOptions); - } - const pointerUpCallback = () => { - window.removeEventListener("pointerup", pointerUpCallback); - window.removeEventListener("blur", pointerUpCallback); - if (isSelected) { - this.div.classList.remove("moving"); - window.removeEventListener("pointermove", pointerMoveCallback, pointerMoveOptions); - } - this.#hasBeenClicked = false; - if (!this._uiManager.endDragSession()) { - this.#selectOnPointerEvent(event); - } - }; - window.addEventListener("pointerup", pointerUpCallback); - window.addEventListener("blur", pointerUpCallback); - } - moveInDOM() { - if (this.#moveInDOMTimeout) { - clearTimeout(this.#moveInDOMTimeout); - } - this.#moveInDOMTimeout = setTimeout(() => { - this.#moveInDOMTimeout = null; - this.parent?.moveEditorInDOM(this); - }, 0); - } - _setParentAndPosition(parent, x, y) { - parent.changeParent(this); - this.x = x; - this.y = y; - this.fixAndSetPosition(); - } - getRect(tx, ty, rotation = this.rotation) { - const scale = this.parentScale; - const [pageWidth, pageHeight] = this.pageDimensions; - const [pageX, pageY] = this.pageTranslation; - const shiftX = tx / scale; - const shiftY = ty / scale; - const x = this.x * pageWidth; - const y = this.y * pageHeight; - const width = this.width * pageWidth; - const height = this.height * pageHeight; - switch (rotation) { - case 0: - return [x + shiftX + pageX, pageHeight - y - shiftY - height + pageY, x + shiftX + width + pageX, pageHeight - y - shiftY + pageY]; - case 90: - return [x + shiftY + pageX, pageHeight - y + shiftX + pageY, x + shiftY + height + pageX, pageHeight - y + shiftX + width + pageY]; - case 180: - return [x - shiftX - width + pageX, pageHeight - y + shiftY + pageY, x - shiftX + pageX, pageHeight - y + shiftY + height + pageY]; - case 270: - return [x - shiftY - height + pageX, pageHeight - y - shiftX - width + pageY, x - shiftY + pageX, pageHeight - y - shiftX + pageY]; - default: - throw new Error("Invalid rotation"); - } - } - getRectInCurrentCoords(rect, pageHeight) { - const [x1, y1, x2, y2] = rect; - const width = x2 - x1; - const height = y2 - y1; - switch (this.rotation) { - case 0: - return [x1, pageHeight - y2, width, height]; - case 90: - return [x1, pageHeight - y1, height, width]; - case 180: - return [x2, pageHeight - y1, width, height]; - case 270: - return [x2, pageHeight - y2, height, width]; - default: - throw new Error("Invalid rotation"); - } - } - onceAdded() {} - isEmpty() { - return false; - } - enableEditMode() { - this.#isInEditMode = true; - } - disableEditMode() { - this.#isInEditMode = false; - } - isInEditMode() { - return this.#isInEditMode; - } - shouldGetKeyboardEvents() { - return this.#isResizerEnabledForKeyboard; - } - needsToBeRebuilt() { - return this.div && !this.isAttachedToDOM; - } - rebuild() { - this.div?.addEventListener("focusin", this.#boundFocusin); - this.div?.addEventListener("focusout", this.#boundFocusout); - } - rotate(_angle) {} - serialize(isForCopying = false, context = null) { - unreachable("An editor must be serializable"); - } - static deserialize(data, parent, uiManager) { - const editor = new this.prototype.constructor({ - parent, - id: parent.getNextId(), - uiManager - }); - editor.rotation = data.rotation; - const [pageWidth, pageHeight] = editor.pageDimensions; - const [x, y, width, height] = editor.getRectInCurrentCoords(data.rect, pageHeight); - editor.x = x / pageWidth; - editor.y = y / pageHeight; - editor.width = width / pageWidth; - editor.height = height / pageHeight; - return editor; - } - get hasBeenModified() { - return !!this.annotationElementId && (this.deleted || this.serialize() !== null); - } - remove() { - this.div.removeEventListener("focusin", this.#boundFocusin); - this.div.removeEventListener("focusout", this.#boundFocusout); - if (!this.isEmpty()) { - this.commit(); - } - if (this.parent) { - this.parent.remove(this); - } else { - this._uiManager.removeEditor(this); - } - if (this.#moveInDOMTimeout) { - clearTimeout(this.#moveInDOMTimeout); - this.#moveInDOMTimeout = null; - } - this.#stopResizing(); - this.removeEditToolbar(); - if (this.#telemetryTimeouts) { - for (const timeout of this.#telemetryTimeouts.values()) { - clearTimeout(timeout); - } - this.#telemetryTimeouts = null; - } - this.parent = null; - } - get isResizable() { - return false; - } - makeResizable() { - if (this.isResizable) { - this.#createResizers(); - this.#resizersDiv.classList.remove("hidden"); - bindEvents(this, this.div, ["keydown"]); - } - } - get toolbarPosition() { - return null; - } - keydown(event) { - if (!this.isResizable || event.target !== this.div || event.key !== "Enter") { - return; - } - this._uiManager.setSelected(this); - this.#savedDimensions = { - savedX: this.x, - savedY: this.y, - savedWidth: this.width, - savedHeight: this.height - }; - const children = this.#resizersDiv.children; - if (!this.#allResizerDivs) { - this.#allResizerDivs = Array.from(children); - const boundResizerKeydown = this.#resizerKeydown.bind(this); - const boundResizerBlur = this.#resizerBlur.bind(this); - for (const div of this.#allResizerDivs) { - const name = div.getAttribute("data-resizer-name"); - div.setAttribute("role", "spinbutton"); - div.addEventListener("keydown", boundResizerKeydown); - div.addEventListener("blur", boundResizerBlur); - div.addEventListener("focus", this.#resizerFocus.bind(this, name)); - AnnotationEditor._l10nPromise.get(`pdfjs-editor-resizer-label-${name}`).then(msg => div.setAttribute("aria-label", msg)); - } - } - const first = this.#allResizerDivs[0]; - let firstPosition = 0; - for (const div of children) { - if (div === first) { - break; - } - firstPosition++; - } - const nextFirstPosition = (360 - this.rotation + this.parentRotation) % 360 / 90 * (this.#allResizerDivs.length / 4); - if (nextFirstPosition !== firstPosition) { - if (nextFirstPosition < firstPosition) { - for (let i = 0; i < firstPosition - nextFirstPosition; i++) { - this.#resizersDiv.append(this.#resizersDiv.firstChild); - } - } else if (nextFirstPosition > firstPosition) { - for (let i = 0; i < nextFirstPosition - firstPosition; i++) { - this.#resizersDiv.firstChild.before(this.#resizersDiv.lastChild); - } - } - let i = 0; - for (const child of children) { - const div = this.#allResizerDivs[i++]; - const name = div.getAttribute("data-resizer-name"); - AnnotationEditor._l10nPromise.get(`pdfjs-editor-resizer-label-${name}`).then(msg => child.setAttribute("aria-label", msg)); - } - } - this.#setResizerTabIndex(0); - this.#isResizerEnabledForKeyboard = true; - this.#resizersDiv.firstChild.focus({ - focusVisible: true - }); - event.preventDefault(); - event.stopImmediatePropagation(); - } - #resizerKeydown(event) { - AnnotationEditor._resizerKeyboardManager.exec(this, event); - } - #resizerBlur(event) { - if (this.#isResizerEnabledForKeyboard && event.relatedTarget?.parentNode !== this.#resizersDiv) { - this.#stopResizing(); - } - } - #resizerFocus(name) { - this.#focusedResizerName = this.#isResizerEnabledForKeyboard ? name : ""; - } - #setResizerTabIndex(value) { - if (!this.#allResizerDivs) { - return; - } - for (const div of this.#allResizerDivs) { - div.tabIndex = value; - } - } - _resizeWithKeyboard(x, y) { - if (!this.#isResizerEnabledForKeyboard) { - return; - } - this.#resizerPointermove(this.#focusedResizerName, { - movementX: x, - movementY: y - }); - } - #stopResizing() { - this.#isResizerEnabledForKeyboard = false; - this.#setResizerTabIndex(-1); - if (this.#savedDimensions) { - const { - savedX, - savedY, - savedWidth, - savedHeight - } = this.#savedDimensions; - this.#addResizeToUndoStack(savedX, savedY, savedWidth, savedHeight); - this.#savedDimensions = null; - } - } - _stopResizingWithKeyboard() { - this.#stopResizing(); - this.div.focus(); - } - select() { - this.makeResizable(); - this.div?.classList.add("selectedEditor"); - if (!this.#editToolbar) { - this.addEditToolbar().then(() => { - if (this.div?.classList.contains("selectedEditor")) { - this.#editToolbar?.show(); - } - }); - return; - } - this.#editToolbar?.show(); - } - unselect() { - this.#resizersDiv?.classList.add("hidden"); - this.div?.classList.remove("selectedEditor"); - if (this.div?.contains(document.activeElement)) { - this._uiManager.currentLayer.div.focus({ - preventScroll: true - }); - } - this.#editToolbar?.hide(); - } - updateParams(type, value) {} - disableEditing() {} - enableEditing() {} - enterInEditMode() {} - getImageForAltText() { - return null; - } - get contentDiv() { - return this.div; - } - get isEditing() { - return this.#isEditing; - } - set isEditing(value) { - this.#isEditing = value; - if (!this.parent) { - return; - } - if (value) { - this.parent.setSelected(this); - this.parent.setActiveEditor(this); - } else { - this.parent.setActiveEditor(null); - } - } - setAspectRatio(width, height) { - this.#keepAspectRatio = true; - const aspectRatio = width / height; - const { - style - } = this.div; - style.aspectRatio = aspectRatio; - style.height = "auto"; - } - static get MIN_SIZE() { - return 16; - } - static canCreateNewEmptyEditor() { - return true; - } - get telemetryInitialData() { - return { - action: "added" - }; - } - get telemetryFinalData() { - return null; - } - _reportTelemetry(data, mustWait = false) { - if (mustWait) { - this.#telemetryTimeouts ||= new Map(); - const { - action - } = data; - let timeout = this.#telemetryTimeouts.get(action); - if (timeout) { - clearTimeout(timeout); - } - timeout = setTimeout(() => { - this._reportTelemetry(data); - this.#telemetryTimeouts.delete(action); - if (this.#telemetryTimeouts.size === 0) { - this.#telemetryTimeouts = null; - } - }, AnnotationEditor._telemetryTimeout); - this.#telemetryTimeouts.set(action, timeout); - return; - } - data.type ||= this.editorType; - this._uiManager._eventBus.dispatch("reporttelemetry", { - source: this, - details: { - type: "editing", - data - } - }); - } - show(visible = this._isVisible) { - this.div.classList.toggle("hidden", !visible); - this._isVisible = visible; - } - enable() { - if (this.div) { - this.div.tabIndex = 0; - } - this.#disabled = false; - } - disable() { - if (this.div) { - this.div.tabIndex = -1; - } - this.#disabled = true; - } - renderAnnotationElement(annotation) { - let content = annotation.container.querySelector(".annotationContent"); - if (!content) { - content = document.createElement("div"); - content.classList.add("annotationContent", this.editorType); - annotation.container.prepend(content); - } else if (content.nodeName === "CANVAS") { - const canvas = content; - content = document.createElement("div"); - content.classList.add("annotationContent", this.editorType); - canvas.before(content); - } - return content; - } - resetAnnotationElement(annotation) { - const { - firstChild - } = annotation.container; - if (firstChild.nodeName === "DIV" && firstChild.classList.contains("annotationContent")) { - firstChild.remove(); - } - } -} -class FakeEditor extends AnnotationEditor { - constructor(params) { - super(params); - this.annotationElementId = params.annotationElementId; - this.deleted = true; - } - serialize() { - return { - id: this.annotationElementId, - deleted: true, - pageIndex: this.pageIndex - }; - } -} - -;// CONCATENATED MODULE: ./src/shared/murmurhash3.js - - - - - - -const SEED = 0xc3d2e1f0; -const MASK_HIGH = 0xffff0000; -const MASK_LOW = 0xffff; -class MurmurHash3_64 { - constructor(seed) { - this.h1 = seed ? seed & 0xffffffff : SEED; - this.h2 = seed ? seed & 0xffffffff : SEED; - } - update(input) { - let data, length; - if (typeof input === "string") { - data = new Uint8Array(input.length * 2); - length = 0; - for (let i = 0, ii = input.length; i < ii; i++) { - const code = input.charCodeAt(i); - if (code <= 0xff) { - data[length++] = code; - } else { - data[length++] = code >>> 8; - data[length++] = code & 0xff; - } - } - } else if (ArrayBuffer.isView(input)) { - data = input.slice(); - length = data.byteLength; - } else { - throw new Error("Invalid data format, must be a string or TypedArray."); - } - const blockCounts = length >> 2; - const tailLength = length - blockCounts * 4; - const dataUint32 = new Uint32Array(data.buffer, 0, blockCounts); - let k1 = 0, - k2 = 0; - let h1 = this.h1, - h2 = this.h2; - const C1 = 0xcc9e2d51, - C2 = 0x1b873593; - const C1_LOW = C1 & MASK_LOW, - C2_LOW = C2 & MASK_LOW; - for (let i = 0; i < blockCounts; i++) { - if (i & 1) { - k1 = dataUint32[i]; - k1 = k1 * C1 & MASK_HIGH | k1 * C1_LOW & MASK_LOW; - k1 = k1 << 15 | k1 >>> 17; - k1 = k1 * C2 & MASK_HIGH | k1 * C2_LOW & MASK_LOW; - h1 ^= k1; - h1 = h1 << 13 | h1 >>> 19; - h1 = h1 * 5 + 0xe6546b64; - } else { - k2 = dataUint32[i]; - k2 = k2 * C1 & MASK_HIGH | k2 * C1_LOW & MASK_LOW; - k2 = k2 << 15 | k2 >>> 17; - k2 = k2 * C2 & MASK_HIGH | k2 * C2_LOW & MASK_LOW; - h2 ^= k2; - h2 = h2 << 13 | h2 >>> 19; - h2 = h2 * 5 + 0xe6546b64; - } - } - k1 = 0; - switch (tailLength) { - case 3: - k1 ^= data[blockCounts * 4 + 2] << 16; - case 2: - k1 ^= data[blockCounts * 4 + 1] << 8; - case 1: - k1 ^= data[blockCounts * 4]; - k1 = k1 * C1 & MASK_HIGH | k1 * C1_LOW & MASK_LOW; - k1 = k1 << 15 | k1 >>> 17; - k1 = k1 * C2 & MASK_HIGH | k1 * C2_LOW & MASK_LOW; - if (blockCounts & 1) { - h1 ^= k1; - } else { - h2 ^= k1; - } - } - this.h1 = h1; - this.h2 = h2; - } - hexdigest() { - let h1 = this.h1, - h2 = this.h2; - h1 ^= h2 >>> 1; - h1 = h1 * 0xed558ccd & MASK_HIGH | h1 * 0x8ccd & MASK_LOW; - h2 = h2 * 0xff51afd7 & MASK_HIGH | ((h2 << 16 | h1 >>> 16) * 0xafd7ed55 & MASK_HIGH) >>> 16; - h1 ^= h2 >>> 1; - h1 = h1 * 0x1a85ec53 & MASK_HIGH | h1 * 0xec53 & MASK_LOW; - h2 = h2 * 0xc4ceb9fe & MASK_HIGH | ((h2 << 16 | h1 >>> 16) * 0xb9fe1a85 & MASK_HIGH) >>> 16; - h1 ^= h2 >>> 1; - return (h1 >>> 0).toString(16).padStart(8, "0") + (h2 >>> 0).toString(16).padStart(8, "0"); - } -} - -;// CONCATENATED MODULE: ./src/display/annotation_storage.js - - - - - - -const SerializableEmpty = Object.freeze({ - map: null, - hash: "", - transfer: undefined -}); -class AnnotationStorage { - #modified = false; - #storage = new Map(); - constructor() { - this.onSetModified = null; - this.onResetModified = null; - this.onAnnotationEditor = null; - } - getValue(key, defaultValue) { - const value = this.#storage.get(key); - if (value === undefined) { - return defaultValue; - } - return Object.assign(defaultValue, value); - } - getRawValue(key) { - return this.#storage.get(key); - } - remove(key) { - this.#storage.delete(key); - if (this.#storage.size === 0) { - this.resetModified(); - } - if (typeof this.onAnnotationEditor === "function") { - for (const value of this.#storage.values()) { - if (value instanceof AnnotationEditor) { - return; - } - } - this.onAnnotationEditor(null); - } - } - setValue(key, value) { - const obj = this.#storage.get(key); - let modified = false; - if (obj !== undefined) { - for (const [entry, val] of Object.entries(value)) { - if (obj[entry] !== val) { - modified = true; - obj[entry] = val; - } - } - } else { - modified = true; - this.#storage.set(key, value); - } - if (modified) { - this.#setModified(); - } - if (value instanceof AnnotationEditor && typeof this.onAnnotationEditor === "function") { - this.onAnnotationEditor(value.constructor._type); - } - } - has(key) { - return this.#storage.has(key); - } - getAll() { - return this.#storage.size > 0 ? objectFromMap(this.#storage) : null; - } - setAll(obj) { - for (const [key, val] of Object.entries(obj)) { - this.setValue(key, val); - } - } - get size() { - return this.#storage.size; - } - #setModified() { - if (!this.#modified) { - this.#modified = true; - if (typeof this.onSetModified === "function") { - this.onSetModified(); - } - } - } - resetModified() { - if (this.#modified) { - this.#modified = false; - if (typeof this.onResetModified === "function") { - this.onResetModified(); - } - } - } - get print() { - return new PrintAnnotationStorage(this); - } - get serializable() { - if (this.#storage.size === 0) { - return SerializableEmpty; - } - const map = new Map(), - hash = new MurmurHash3_64(), - transfer = []; - const context = Object.create(null); - let hasBitmap = false; - for (const [key, val] of this.#storage) { - const serialized = val instanceof AnnotationEditor ? val.serialize(false, context) : val; - if (serialized) { - map.set(key, serialized); - hash.update(`${key}:${JSON.stringify(serialized)}`); - hasBitmap ||= !!serialized.bitmap; - } - } - if (hasBitmap) { - for (const value of map.values()) { - if (value.bitmap) { - transfer.push(value.bitmap); - } - } - } - return map.size > 0 ? { - map, - hash: hash.hexdigest(), - transfer - } : SerializableEmpty; - } - get editorStats() { - let stats = null; - const typeToEditor = new Map(); - for (const value of this.#storage.values()) { - if (!(value instanceof AnnotationEditor)) { - continue; - } - const editorStats = value.telemetryFinalData; - if (!editorStats) { - continue; - } - const { - type - } = editorStats; - if (!typeToEditor.has(type)) { - typeToEditor.set(type, Object.getPrototypeOf(value).constructor); - } - stats ||= Object.create(null); - const map = stats[type] ||= new Map(); - for (const [key, val] of Object.entries(editorStats)) { - if (key === "type") { - continue; - } - let counters = map.get(key); - if (!counters) { - counters = new Map(); - map.set(key, counters); - } - const count = counters.get(val) ?? 0; - counters.set(val, count + 1); - } - } - for (const [type, editor] of typeToEditor) { - stats[type] = editor.computeTelemetryFinalData(stats[type]); - } - return stats; - } -} -class PrintAnnotationStorage extends AnnotationStorage { - #serializable; - constructor(parent) { - super(); - const { - map, - hash, - transfer - } = parent.serializable; - const clone = structuredClone(map, transfer ? { - transfer - } : null); - this.#serializable = { - map: clone, - hash, - transfer - }; - } - get print() { - unreachable("Should not call PrintAnnotationStorage.print"); - } - get serializable() { - return this.#serializable; - } -} - -;// CONCATENATED MODULE: ./src/display/font_loader.js - - - - - - - - - - -class FontLoader { - #systemFonts = new Set(); - constructor({ - ownerDocument = globalThis.document, - styleElement = null - }) { - this._document = ownerDocument; - this.nativeFontFaces = new Set(); - this.styleElement = null; - this.loadingRequests = []; - this.loadTestFontId = 0; - } - addNativeFontFace(nativeFontFace) { - this.nativeFontFaces.add(nativeFontFace); - this._document.fonts.add(nativeFontFace); - } - removeNativeFontFace(nativeFontFace) { - this.nativeFontFaces.delete(nativeFontFace); - this._document.fonts.delete(nativeFontFace); - } - insertRule(rule) { - if (!this.styleElement) { - this.styleElement = this._document.createElement("style"); - this._document.documentElement.getElementsByTagName("head")[0].append(this.styleElement); - } - const styleSheet = this.styleElement.sheet; - styleSheet.insertRule(rule, styleSheet.cssRules.length); - } - clear() { - for (const nativeFontFace of this.nativeFontFaces) { - this._document.fonts.delete(nativeFontFace); - } - this.nativeFontFaces.clear(); - this.#systemFonts.clear(); - if (this.styleElement) { - this.styleElement.remove(); - this.styleElement = null; - } - } - async loadSystemFont({ - systemFontInfo: info, - _inspectFont - }) { - if (!info || this.#systemFonts.has(info.loadedName)) { - return; - } - assert(!this.disableFontFace, "loadSystemFont shouldn't be called when `disableFontFace` is set."); - if (this.isFontLoadingAPISupported) { - const { - loadedName, - src, - style - } = info; - const fontFace = new FontFace(loadedName, src, style); - this.addNativeFontFace(fontFace); - try { - await fontFace.load(); - this.#systemFonts.add(loadedName); - _inspectFont?.(info); - } catch { - warn(`Cannot load system font: ${info.baseFontName}, installing it could help to improve PDF rendering.`); - this.removeNativeFontFace(fontFace); - } - return; - } - unreachable("Not implemented: loadSystemFont without the Font Loading API."); - } - async bind(font) { - if (font.attached || font.missingFile && !font.systemFontInfo) { - return; - } - font.attached = true; - if (font.systemFontInfo) { - await this.loadSystemFont(font); - return; - } - if (this.isFontLoadingAPISupported) { - const nativeFontFace = font.createNativeFontFace(); - if (nativeFontFace) { - this.addNativeFontFace(nativeFontFace); - try { - await nativeFontFace.loaded; - } catch (ex) { - warn(`Failed to load font '${nativeFontFace.family}': '${ex}'.`); - font.disableFontFace = true; - throw ex; - } - } - return; - } - const rule = font.createFontFaceRule(); - if (rule) { - this.insertRule(rule); - if (this.isSyncFontLoadingSupported) { - return; - } - await new Promise(resolve => { - const request = this._queueLoadingCallback(resolve); - this._prepareFontLoadEvent(font, request); - }); - } - } - get isFontLoadingAPISupported() { - const hasFonts = !!this._document?.fonts; - return shadow(this, "isFontLoadingAPISupported", hasFonts); - } - get isSyncFontLoadingSupported() { - let supported = false; - if (isNodeJS) { - supported = true; - } else if (typeof navigator !== "undefined" && typeof navigator?.userAgent === "string" && /Mozilla\/5.0.*?rv:\d+.*? Gecko/.test(navigator.userAgent)) { - supported = true; - } - return shadow(this, "isSyncFontLoadingSupported", supported); - } - _queueLoadingCallback(callback) { - function completeRequest() { - assert(!request.done, "completeRequest() cannot be called twice."); - request.done = true; - while (loadingRequests.length > 0 && loadingRequests[0].done) { - const otherRequest = loadingRequests.shift(); - setTimeout(otherRequest.callback, 0); - } - } - const { - loadingRequests - } = this; - const request = { - done: false, - complete: completeRequest, - callback - }; - loadingRequests.push(request); - return request; - } - get _loadTestFont() { - const testFont = atob("T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQA" + "FQAABDgAA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AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" + "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAA" + "AAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQAC" + "AQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3" + "Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTj" + "FQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA=="); - return shadow(this, "_loadTestFont", testFont); - } - _prepareFontLoadEvent(font, request) { - function int32(data, offset) { - return data.charCodeAt(offset) << 24 | data.charCodeAt(offset + 1) << 16 | data.charCodeAt(offset + 2) << 8 | data.charCodeAt(offset + 3) & 0xff; - } - function spliceString(s, offset, remove, insert) { - const chunk1 = s.substring(0, offset); - const chunk2 = s.substring(offset + remove); - return chunk1 + insert + chunk2; - } - let i, ii; - const canvas = this._document.createElement("canvas"); - canvas.width = 1; - canvas.height = 1; - const ctx = canvas.getContext("2d"); - let called = 0; - function isFontReady(name, callback) { - if (++called > 30) { - warn("Load test font never loaded."); - callback(); - return; - } - ctx.font = "30px " + name; - ctx.fillText(".", 0, 20); - const imageData = ctx.getImageData(0, 0, 1, 1); - if (imageData.data[3] > 0) { - callback(); - return; - } - setTimeout(isFontReady.bind(null, name, callback)); - } - const loadTestFontId = `lt${Date.now()}${this.loadTestFontId++}`; - let data = this._loadTestFont; - const COMMENT_OFFSET = 976; - data = spliceString(data, COMMENT_OFFSET, loadTestFontId.length, loadTestFontId); - const CFF_CHECKSUM_OFFSET = 16; - const XXXX_VALUE = 0x58585858; - let checksum = int32(data, CFF_CHECKSUM_OFFSET); - for (i = 0, ii = loadTestFontId.length - 3; i < ii; i += 4) { - checksum = checksum - XXXX_VALUE + int32(loadTestFontId, i) | 0; - } - if (i < loadTestFontId.length) { - checksum = checksum - XXXX_VALUE + int32(loadTestFontId + "XXX", i) | 0; - } - data = spliceString(data, CFF_CHECKSUM_OFFSET, 4, string32(checksum)); - const url = `url(data:font/opentype;base64,${btoa(data)});`; - const rule = `@font-face {font-family:"${loadTestFontId}";src:${url}}`; - this.insertRule(rule); - const div = this._document.createElement("div"); - div.style.visibility = "hidden"; - div.style.width = div.style.height = "10px"; - div.style.position = "absolute"; - div.style.top = div.style.left = "0px"; - for (const name of [font.loadedName, loadTestFontId]) { - const span = this._document.createElement("span"); - span.textContent = "Hi"; - span.style.fontFamily = name; - div.append(span); - } - this._document.body.append(div); - isFontReady(loadTestFontId, () => { - div.remove(); - request.complete(); - }); - } -} -class FontFaceObject { - constructor(translatedData, { - disableFontFace = false, - inspectFont = null - }) { - this.compiledGlyphs = Object.create(null); - for (const i in translatedData) { - this[i] = translatedData[i]; - } - this.disableFontFace = disableFontFace === true; - this._inspectFont = inspectFont; - } - createNativeFontFace() { - if (!this.data || this.disableFontFace) { - return null; - } - let nativeFontFace; - if (!this.cssFontInfo) { - nativeFontFace = new FontFace(this.loadedName, this.data, {}); - } else { - const css = { - weight: this.cssFontInfo.fontWeight - }; - if (this.cssFontInfo.italicAngle) { - css.style = `oblique ${this.cssFontInfo.italicAngle}deg`; - } - nativeFontFace = new FontFace(this.cssFontInfo.fontFamily, this.data, css); - } - this._inspectFont?.(this); - return nativeFontFace; - } - createFontFaceRule() { - if (!this.data || this.disableFontFace) { - return null; - } - const data = bytesToString(this.data); - const url = `url(data:${this.mimetype};base64,${btoa(data)});`; - let rule; - if (!this.cssFontInfo) { - rule = `@font-face {font-family:"${this.loadedName}";src:${url}}`; - } else { - let css = `font-weight: ${this.cssFontInfo.fontWeight};`; - if (this.cssFontInfo.italicAngle) { - css += `font-style: oblique ${this.cssFontInfo.italicAngle}deg;`; - } - rule = `@font-face {font-family:"${this.cssFontInfo.fontFamily}";${css}src:${url}}`; - } - this._inspectFont?.(this, url); - return rule; - } - getPathGenerator(objs, character) { - if (this.compiledGlyphs[character] !== undefined) { - return this.compiledGlyphs[character]; - } - let cmds; - try { - cmds = objs.get(this.loadedName + "_path_" + character); - } catch (ex) { - warn(`getPathGenerator - ignoring character: "${ex}".`); - } - if (!Array.isArray(cmds) || cmds.length === 0) { - return this.compiledGlyphs[character] = function (c, size) {}; - } - const commands = []; - for (let i = 0, ii = cmds.length; i < ii;) { - switch (cmds[i++]) { - case FontRenderOps.BEZIER_CURVE_TO: - { - const [a, b, c, d, e, f] = cmds.slice(i, i + 6); - commands.push(ctx => ctx.bezierCurveTo(a, b, c, d, e, f)); - i += 6; - } - break; - case FontRenderOps.MOVE_TO: - { - const [a, b] = cmds.slice(i, i + 2); - commands.push(ctx => ctx.moveTo(a, b)); - i += 2; - } - break; - case FontRenderOps.LINE_TO: - { - const [a, b] = cmds.slice(i, i + 2); - commands.push(ctx => ctx.lineTo(a, b)); - i += 2; - } - break; - case FontRenderOps.QUADRATIC_CURVE_TO: - { - const [a, b, c, d] = cmds.slice(i, i + 4); - commands.push(ctx => ctx.quadraticCurveTo(a, b, c, d)); - i += 4; - } - break; - case FontRenderOps.RESTORE: - commands.push(ctx => ctx.restore()); - break; - case FontRenderOps.SAVE: - commands.push(ctx => ctx.save()); - break; - case FontRenderOps.SCALE: - assert(commands.length === 2, "Scale command is only valid at the third position."); - break; - case FontRenderOps.TRANSFORM: - { - const [a, b, c, d, e, f] = cmds.slice(i, i + 6); - commands.push(ctx => ctx.transform(a, b, c, d, e, f)); - i += 6; - } - break; - case FontRenderOps.TRANSLATE: - { - const [a, b] = cmds.slice(i, i + 2); - commands.push(ctx => ctx.translate(a, b)); - i += 2; - } - break; - } - } - return this.compiledGlyphs[character] = function glyphDrawer(ctx, size) { - commands[0](ctx); - commands[1](ctx); - ctx.scale(size, -size); - for (let i = 2, ii = commands.length; i < ii; i++) { - commands[i](ctx); - } - }; - } -} - -;// CONCATENATED MODULE: ./src/display/node_utils.js - - - - - - - - - -if (isNodeJS) { - var packageCapability = Promise.withResolvers(); - var packageMap = null; - const loadPackages = async () => { - const fs = await import( /*webpackIgnore: true*/"fs"), - http = await import( /*webpackIgnore: true*/"http"), - https = await import( /*webpackIgnore: true*/"https"), - url = await import( /*webpackIgnore: true*/"url"); - let canvas, path2d; - try { - canvas = await import( /*webpackIgnore: true*/"canvas"); - } catch {} - try { - path2d = await import( /*webpackIgnore: true*/"path2d"); - } catch {} - return new Map(Object.entries({ - fs, - http, - https, - url, - canvas, - path2d - })); - }; - loadPackages().then(map => { - packageMap = map; - packageCapability.resolve(); - if (!globalThis.DOMMatrix) { - const DOMMatrix = map.get("canvas")?.DOMMatrix; - if (DOMMatrix) { - globalThis.DOMMatrix = DOMMatrix; - } else { - warn("Cannot polyfill `DOMMatrix`, rendering may be broken."); - } - } - if (!globalThis.Path2D) { - const CanvasRenderingContext2D = map.get("canvas")?.CanvasRenderingContext2D; - const applyPath2DToCanvasRenderingContext = map.get("path2d")?.applyPath2DToCanvasRenderingContext; - const Path2D = map.get("path2d")?.Path2D; - if (CanvasRenderingContext2D && applyPath2DToCanvasRenderingContext && Path2D) { - applyPath2DToCanvasRenderingContext(CanvasRenderingContext2D); - globalThis.Path2D = Path2D; - } else { - warn("Cannot polyfill `Path2D`, rendering may be broken."); - } - } - }, reason => { - warn(`loadPackages: ${reason}`); - packageMap = new Map(); - packageCapability.resolve(); - }); -} -class NodePackages { - static get promise() { - return packageCapability.promise; - } - static get(name) { - return packageMap?.get(name); - } -} -const node_utils_fetchData = function (url) { - const fs = NodePackages.get("fs"); - return fs.promises.readFile(url).then(data => new Uint8Array(data)); -}; -class NodeFilterFactory extends BaseFilterFactory {} -class NodeCanvasFactory extends BaseCanvasFactory { - _createCanvas(width, height) { - const canvas = NodePackages.get("canvas"); - return canvas.createCanvas(width, height); - } -} -class NodeCMapReaderFactory extends BaseCMapReaderFactory { - _fetchData(url, compressionType) { - return node_utils_fetchData(url).then(data => ({ - cMapData: data, - compressionType - })); - } -} -class NodeStandardFontDataFactory extends BaseStandardFontDataFactory { - _fetchData(url) { - return node_utils_fetchData(url); - } -} - -;// CONCATENATED MODULE: ./src/display/pattern_helper.js - - -const PathType = { - FILL: "Fill", - STROKE: "Stroke", - SHADING: "Shading" -}; -function applyBoundingBox(ctx, bbox) { - if (!bbox) { - return; - } - const width = bbox[2] - bbox[0]; - const height = bbox[3] - bbox[1]; - const region = new Path2D(); - region.rect(bbox[0], bbox[1], width, height); - ctx.clip(region); -} -class BaseShadingPattern { - constructor() { - if (this.constructor === BaseShadingPattern) { - unreachable("Cannot initialize BaseShadingPattern."); - } - } - getPattern() { - unreachable("Abstract method `getPattern` called."); - } -} -class RadialAxialShadingPattern extends BaseShadingPattern { - constructor(IR) { - super(); - this._type = IR[1]; - this._bbox = IR[2]; - this._colorStops = IR[3]; - this._p0 = IR[4]; - this._p1 = IR[5]; - this._r0 = IR[6]; - this._r1 = IR[7]; - this.matrix = null; - } - _createGradient(ctx) { - let grad; - if (this._type === "axial") { - grad = ctx.createLinearGradient(this._p0[0], this._p0[1], this._p1[0], this._p1[1]); - } else if (this._type === "radial") { - grad = ctx.createRadialGradient(this._p0[0], this._p0[1], this._r0, this._p1[0], this._p1[1], this._r1); - } - for (const colorStop of this._colorStops) { - grad.addColorStop(colorStop[0], colorStop[1]); - } - return grad; - } - getPattern(ctx, owner, inverse, pathType) { - let pattern; - if (pathType === PathType.STROKE || pathType === PathType.FILL) { - const ownerBBox = owner.current.getClippedPathBoundingBox(pathType, getCurrentTransform(ctx)) || [0, 0, 0, 0]; - const width = Math.ceil(ownerBBox[2] - ownerBBox[0]) || 1; - const height = Math.ceil(ownerBBox[3] - ownerBBox[1]) || 1; - const tmpCanvas = owner.cachedCanvases.getCanvas("pattern", width, height, true); - const tmpCtx = tmpCanvas.context; - tmpCtx.clearRect(0, 0, tmpCtx.canvas.width, tmpCtx.canvas.height); - tmpCtx.beginPath(); - tmpCtx.rect(0, 0, tmpCtx.canvas.width, tmpCtx.canvas.height); - tmpCtx.translate(-ownerBBox[0], -ownerBBox[1]); - inverse = Util.transform(inverse, [1, 0, 0, 1, ownerBBox[0], ownerBBox[1]]); - tmpCtx.transform(...owner.baseTransform); - if (this.matrix) { - tmpCtx.transform(...this.matrix); - } - applyBoundingBox(tmpCtx, this._bbox); - tmpCtx.fillStyle = this._createGradient(tmpCtx); - tmpCtx.fill(); - pattern = ctx.createPattern(tmpCanvas.canvas, "no-repeat"); - const domMatrix = new DOMMatrix(inverse); - pattern.setTransform(domMatrix); - } else { - applyBoundingBox(ctx, this._bbox); - pattern = this._createGradient(ctx); - } - return pattern; - } -} -function drawTriangle(data, context, p1, p2, p3, c1, c2, c3) { - const coords = context.coords, - colors = context.colors; - const bytes = data.data, - rowSize = data.width * 4; - let tmp; - if (coords[p1 + 1] > coords[p2 + 1]) { - tmp = p1; - p1 = p2; - p2 = tmp; - tmp = c1; - c1 = c2; - c2 = tmp; - } - if (coords[p2 + 1] > coords[p3 + 1]) { - tmp = p2; - p2 = p3; - p3 = tmp; - tmp = c2; - c2 = c3; - c3 = tmp; - } - if (coords[p1 + 1] > coords[p2 + 1]) { - tmp = p1; - p1 = p2; - p2 = tmp; - tmp = c1; - c1 = c2; - c2 = tmp; - } - const x1 = (coords[p1] + context.offsetX) * context.scaleX; - const y1 = (coords[p1 + 1] + context.offsetY) * context.scaleY; - const x2 = (coords[p2] + context.offsetX) * context.scaleX; - const y2 = (coords[p2 + 1] + context.offsetY) * context.scaleY; - const x3 = (coords[p3] + context.offsetX) * context.scaleX; - const y3 = (coords[p3 + 1] + context.offsetY) * context.scaleY; - if (y1 >= y3) { - return; - } - const c1r = colors[c1], - c1g = colors[c1 + 1], - c1b = colors[c1 + 2]; - const c2r = colors[c2], - c2g = colors[c2 + 1], - c2b = colors[c2 + 2]; - const c3r = colors[c3], - c3g = colors[c3 + 1], - c3b = colors[c3 + 2]; - const minY = Math.round(y1), - maxY = Math.round(y3); - let xa, car, cag, cab; - let xb, cbr, cbg, cbb; - for (let y = minY; y <= maxY; y++) { - if (y < y2) { - const k = y < y1 ? 0 : (y1 - y) / (y1 - y2); - xa = x1 - (x1 - x2) * k; - car = c1r - (c1r - c2r) * k; - cag = c1g - (c1g - c2g) * k; - cab = c1b - (c1b - c2b) * k; - } else { - let k; - if (y > y3) { - k = 1; - } else if (y2 === y3) { - k = 0; - } else { - k = (y2 - y) / (y2 - y3); - } - xa = x2 - (x2 - x3) * k; - car = c2r - (c2r - c3r) * k; - cag = c2g - (c2g - c3g) * k; - cab = c2b - (c2b - c3b) * k; - } - let k; - if (y < y1) { - k = 0; - } else if (y > y3) { - k = 1; - } else { - k = (y1 - y) / (y1 - y3); - } - xb = x1 - (x1 - x3) * k; - cbr = c1r - (c1r - c3r) * k; - cbg = c1g - (c1g - c3g) * k; - cbb = c1b - (c1b - c3b) * k; - const x1_ = Math.round(Math.min(xa, xb)); - const x2_ = Math.round(Math.max(xa, xb)); - let j = rowSize * y + x1_ * 4; - for (let x = x1_; x <= x2_; x++) { - k = (xa - x) / (xa - xb); - if (k < 0) { - k = 0; - } else if (k > 1) { - k = 1; - } - bytes[j++] = car - (car - cbr) * k | 0; - bytes[j++] = cag - (cag - cbg) * k | 0; - bytes[j++] = cab - (cab - cbb) * k | 0; - bytes[j++] = 255; - } - } -} -function drawFigure(data, figure, context) { - const ps = figure.coords; - const cs = figure.colors; - let i, ii; - switch (figure.type) { - case "lattice": - const verticesPerRow = figure.verticesPerRow; - const rows = Math.floor(ps.length / verticesPerRow) - 1; - const cols = verticesPerRow - 1; - for (i = 0; i < rows; i++) { - let q = i * verticesPerRow; - for (let j = 0; j < cols; j++, q++) { - drawTriangle(data, context, ps[q], ps[q + 1], ps[q + verticesPerRow], cs[q], cs[q + 1], cs[q + verticesPerRow]); - drawTriangle(data, context, ps[q + verticesPerRow + 1], ps[q + 1], ps[q + verticesPerRow], cs[q + verticesPerRow + 1], cs[q + 1], cs[q + verticesPerRow]); - } - } - break; - case "triangles": - for (i = 0, ii = ps.length; i < ii; i += 3) { - drawTriangle(data, context, ps[i], ps[i + 1], ps[i + 2], cs[i], cs[i + 1], cs[i + 2]); - } - break; - default: - throw new Error("illegal figure"); - } -} -class MeshShadingPattern extends BaseShadingPattern { - constructor(IR) { - super(); - this._coords = IR[2]; - this._colors = IR[3]; - this._figures = IR[4]; - this._bounds = IR[5]; - this._bbox = IR[7]; - this._background = IR[8]; - this.matrix = null; - } - _createMeshCanvas(combinedScale, backgroundColor, cachedCanvases) { - const EXPECTED_SCALE = 1.1; - const MAX_PATTERN_SIZE = 3000; - const BORDER_SIZE = 2; - const offsetX = Math.floor(this._bounds[0]); - const offsetY = Math.floor(this._bounds[1]); - const boundsWidth = Math.ceil(this._bounds[2]) - offsetX; - const boundsHeight = Math.ceil(this._bounds[3]) - offsetY; - const width = Math.min(Math.ceil(Math.abs(boundsWidth * combinedScale[0] * EXPECTED_SCALE)), MAX_PATTERN_SIZE); - const height = Math.min(Math.ceil(Math.abs(boundsHeight * combinedScale[1] * EXPECTED_SCALE)), MAX_PATTERN_SIZE); - const scaleX = boundsWidth / width; - const scaleY = boundsHeight / height; - const context = { - coords: this._coords, - colors: this._colors, - offsetX: -offsetX, - offsetY: -offsetY, - scaleX: 1 / scaleX, - scaleY: 1 / scaleY - }; - const paddedWidth = width + BORDER_SIZE * 2; - const paddedHeight = height + BORDER_SIZE * 2; - const tmpCanvas = cachedCanvases.getCanvas("mesh", paddedWidth, paddedHeight, false); - const tmpCtx = tmpCanvas.context; - const data = tmpCtx.createImageData(width, height); - if (backgroundColor) { - const bytes = data.data; - for (let i = 0, ii = bytes.length; i < ii; i += 4) { - bytes[i] = backgroundColor[0]; - bytes[i + 1] = backgroundColor[1]; - bytes[i + 2] = backgroundColor[2]; - bytes[i + 3] = 255; - } - } - for (const figure of this._figures) { - drawFigure(data, figure, context); - } - tmpCtx.putImageData(data, BORDER_SIZE, BORDER_SIZE); - const canvas = tmpCanvas.canvas; - return { - canvas, - offsetX: offsetX - BORDER_SIZE * scaleX, - offsetY: offsetY - BORDER_SIZE * scaleY, - scaleX, - scaleY - }; - } - getPattern(ctx, owner, inverse, pathType) { - applyBoundingBox(ctx, this._bbox); - let scale; - if (pathType === PathType.SHADING) { - scale = Util.singularValueDecompose2dScale(getCurrentTransform(ctx)); - } else { - scale = Util.singularValueDecompose2dScale(owner.baseTransform); - if (this.matrix) { - const matrixScale = Util.singularValueDecompose2dScale(this.matrix); - scale = [scale[0] * matrixScale[0], scale[1] * matrixScale[1]]; - } - } - const temporaryPatternCanvas = this._createMeshCanvas(scale, pathType === PathType.SHADING ? null : this._background, owner.cachedCanvases); - if (pathType !== PathType.SHADING) { - ctx.setTransform(...owner.baseTransform); - if (this.matrix) { - ctx.transform(...this.matrix); - } - } - ctx.translate(temporaryPatternCanvas.offsetX, temporaryPatternCanvas.offsetY); - ctx.scale(temporaryPatternCanvas.scaleX, temporaryPatternCanvas.scaleY); - return ctx.createPattern(temporaryPatternCanvas.canvas, "no-repeat"); - } -} -class DummyShadingPattern extends BaseShadingPattern { - getPattern() { - return "hotpink"; - } -} -function getShadingPattern(IR) { - switch (IR[0]) { - case "RadialAxial": - return new RadialAxialShadingPattern(IR); - case "Mesh": - return new MeshShadingPattern(IR); - case "Dummy": - return new DummyShadingPattern(); - } - throw new Error(`Unknown IR type: ${IR[0]}`); -} -const PaintType = { - COLORED: 1, - UNCOLORED: 2 -}; -class TilingPattern { - static MAX_PATTERN_SIZE = 3000; - constructor(IR, color, ctx, canvasGraphicsFactory, baseTransform) { - this.operatorList = IR[2]; - this.matrix = IR[3]; - this.bbox = IR[4]; - this.xstep = IR[5]; - this.ystep = IR[6]; - this.paintType = IR[7]; - this.tilingType = IR[8]; - this.color = color; - this.ctx = ctx; - this.canvasGraphicsFactory = canvasGraphicsFactory; - this.baseTransform = baseTransform; - } - createPatternCanvas(owner) { - const operatorList = this.operatorList; - const bbox = this.bbox; - const xstep = this.xstep; - const ystep = this.ystep; - const paintType = this.paintType; - const tilingType = this.tilingType; - const color = this.color; - const canvasGraphicsFactory = this.canvasGraphicsFactory; - info("TilingType: " + tilingType); - const x0 = bbox[0], - y0 = bbox[1], - x1 = bbox[2], - y1 = bbox[3]; - const matrixScale = Util.singularValueDecompose2dScale(this.matrix); - const curMatrixScale = Util.singularValueDecompose2dScale(this.baseTransform); - const combinedScale = [matrixScale[0] * curMatrixScale[0], matrixScale[1] * curMatrixScale[1]]; - const dimx = this.getSizeAndScale(xstep, this.ctx.canvas.width, combinedScale[0]); - const dimy = this.getSizeAndScale(ystep, this.ctx.canvas.height, combinedScale[1]); - const tmpCanvas = owner.cachedCanvases.getCanvas("pattern", dimx.size, dimy.size, true); - const tmpCtx = tmpCanvas.context; - const graphics = canvasGraphicsFactory.createCanvasGraphics(tmpCtx); - graphics.groupLevel = owner.groupLevel; - this.setFillAndStrokeStyleToContext(graphics, paintType, color); - let adjustedX0 = x0; - let adjustedY0 = y0; - let adjustedX1 = x1; - let adjustedY1 = y1; - if (x0 < 0) { - adjustedX0 = 0; - adjustedX1 += Math.abs(x0); - } - if (y0 < 0) { - adjustedY0 = 0; - adjustedY1 += Math.abs(y0); - } - tmpCtx.translate(-(dimx.scale * adjustedX0), -(dimy.scale * adjustedY0)); - graphics.transform(dimx.scale, 0, 0, dimy.scale, 0, 0); - tmpCtx.save(); - this.clipBbox(graphics, adjustedX0, adjustedY0, adjustedX1, adjustedY1); - graphics.baseTransform = getCurrentTransform(graphics.ctx); - graphics.executeOperatorList(operatorList); - graphics.endDrawing(); - return { - canvas: tmpCanvas.canvas, - scaleX: dimx.scale, - scaleY: dimy.scale, - offsetX: adjustedX0, - offsetY: adjustedY0 - }; - } - getSizeAndScale(step, realOutputSize, scale) { - step = Math.abs(step); - const maxSize = Math.max(TilingPattern.MAX_PATTERN_SIZE, realOutputSize); - let size = Math.ceil(step * scale); - if (size >= maxSize) { - size = maxSize; - } else { - scale = size / step; - } - return { - scale, - size - }; - } - clipBbox(graphics, x0, y0, x1, y1) { - const bboxWidth = x1 - x0; - const bboxHeight = y1 - y0; - graphics.ctx.rect(x0, y0, bboxWidth, bboxHeight); - graphics.current.updateRectMinMax(getCurrentTransform(graphics.ctx), [x0, y0, x1, y1]); - graphics.clip(); - graphics.endPath(); - } - setFillAndStrokeStyleToContext(graphics, paintType, color) { - const context = graphics.ctx, - current = graphics.current; - switch (paintType) { - case PaintType.COLORED: - const ctx = this.ctx; - context.fillStyle = ctx.fillStyle; - context.strokeStyle = ctx.strokeStyle; - current.fillColor = ctx.fillStyle; - current.strokeColor = ctx.strokeStyle; - break; - case PaintType.UNCOLORED: - const cssColor = Util.makeHexColor(color[0], color[1], color[2]); - context.fillStyle = cssColor; - context.strokeStyle = cssColor; - current.fillColor = cssColor; - current.strokeColor = cssColor; - break; - default: - throw new FormatError(`Unsupported paint type: ${paintType}`); - } - } - getPattern(ctx, owner, inverse, pathType) { - let matrix = inverse; - if (pathType !== PathType.SHADING) { - matrix = Util.transform(matrix, owner.baseTransform); - if (this.matrix) { - matrix = Util.transform(matrix, this.matrix); - } - } - const temporaryPatternCanvas = this.createPatternCanvas(owner); - let domMatrix = new DOMMatrix(matrix); - domMatrix = domMatrix.translate(temporaryPatternCanvas.offsetX, temporaryPatternCanvas.offsetY); - domMatrix = domMatrix.scale(1 / temporaryPatternCanvas.scaleX, 1 / temporaryPatternCanvas.scaleY); - const pattern = ctx.createPattern(temporaryPatternCanvas.canvas, "repeat"); - pattern.setTransform(domMatrix); - return pattern; - } -} - -;// CONCATENATED MODULE: ./src/shared/image_utils.js - - - - - - - -function convertToRGBA(params) { - switch (params.kind) { - case ImageKind.GRAYSCALE_1BPP: - return convertBlackAndWhiteToRGBA(params); - case ImageKind.RGB_24BPP: - return convertRGBToRGBA(params); - } - return null; -} -function convertBlackAndWhiteToRGBA({ - src, - srcPos = 0, - dest, - width, - height, - nonBlackColor = 0xffffffff, - inverseDecode = false -}) { - const black = util_FeatureTest.isLittleEndian ? 0xff000000 : 0x000000ff; - const [zeroMapping, oneMapping] = inverseDecode ? [nonBlackColor, black] : [black, nonBlackColor]; - const widthInSource = width >> 3; - const widthRemainder = width & 7; - const srcLength = src.length; - dest = new Uint32Array(dest.buffer); - let destPos = 0; - for (let i = 0; i < height; i++) { - for (const max = srcPos + widthInSource; srcPos < max; srcPos++) { - const elem = srcPos < srcLength ? src[srcPos] : 255; - dest[destPos++] = elem & 0b10000000 ? oneMapping : zeroMapping; - dest[destPos++] = elem & 0b1000000 ? oneMapping : zeroMapping; - dest[destPos++] = elem & 0b100000 ? oneMapping : zeroMapping; - dest[destPos++] = elem & 0b10000 ? oneMapping : zeroMapping; - dest[destPos++] = elem & 0b1000 ? oneMapping : zeroMapping; - dest[destPos++] = elem & 0b100 ? oneMapping : zeroMapping; - dest[destPos++] = elem & 0b10 ? oneMapping : zeroMapping; - dest[destPos++] = elem & 0b1 ? oneMapping : zeroMapping; - } - if (widthRemainder === 0) { - continue; - } - const elem = srcPos < srcLength ? src[srcPos++] : 255; - for (let j = 0; j < widthRemainder; j++) { - dest[destPos++] = elem & 1 << 7 - j ? oneMapping : zeroMapping; - } - } - return { - srcPos, - destPos - }; -} -function convertRGBToRGBA({ - src, - srcPos = 0, - dest, - destPos = 0, - width, - height -}) { - let i = 0; - const len32 = src.length >> 2; - const src32 = new Uint32Array(src.buffer, srcPos, len32); - if (FeatureTest.isLittleEndian) { - for (; i < len32 - 2; i += 3, destPos += 4) { - const s1 = src32[i]; - const s2 = src32[i + 1]; - const s3 = src32[i + 2]; - dest[destPos] = s1 | 0xff000000; - dest[destPos + 1] = s1 >>> 24 | s2 << 8 | 0xff000000; - dest[destPos + 2] = s2 >>> 16 | s3 << 16 | 0xff000000; - dest[destPos + 3] = s3 >>> 8 | 0xff000000; - } - for (let j = i * 4, jj = src.length; j < jj; j += 3) { - dest[destPos++] = src[j] | src[j + 1] << 8 | src[j + 2] << 16 | 0xff000000; - } - } else { - for (; i < len32 - 2; i += 3, destPos += 4) { - const s1 = src32[i]; - const s2 = src32[i + 1]; - const s3 = src32[i + 2]; - dest[destPos] = s1 | 0xff; - dest[destPos + 1] = s1 << 24 | s2 >>> 8 | 0xff; - dest[destPos + 2] = s2 << 16 | s3 >>> 16 | 0xff; - dest[destPos + 3] = s3 << 8 | 0xff; - } - for (let j = i * 4, jj = src.length; j < jj; j += 3) { - dest[destPos++] = src[j] << 24 | src[j + 1] << 16 | src[j + 2] << 8 | 0xff; - } - } - return { - srcPos, - destPos - }; -} -function grayToRGBA(src, dest) { - if (FeatureTest.isLittleEndian) { - for (let i = 0, ii = src.length; i < ii; i++) { - dest[i] = src[i] * 0x10101 | 0xff000000; - } - } else { - for (let i = 0, ii = src.length; i < ii; i++) { - dest[i] = src[i] * 0x1010100 | 0x000000ff; - } - } -} - -;// CONCATENATED MODULE: ./src/display/canvas.js - - - - - - - - - - - - - - - -const MIN_FONT_SIZE = 16; -const MAX_FONT_SIZE = 100; -const EXECUTION_TIME = 15; -const EXECUTION_STEPS = 10; -const MAX_SIZE_TO_COMPILE = 1000; -const FULL_CHUNK_HEIGHT = 16; -function mirrorContextOperations(ctx, destCtx) { - if (ctx._removeMirroring) { - throw new Error("Context is already forwarding operations."); - } - ctx.__originalSave = ctx.save; - ctx.__originalRestore = ctx.restore; - ctx.__originalRotate = ctx.rotate; - ctx.__originalScale = ctx.scale; - ctx.__originalTranslate = ctx.translate; - ctx.__originalTransform = ctx.transform; - ctx.__originalSetTransform = ctx.setTransform; - ctx.__originalResetTransform = ctx.resetTransform; - ctx.__originalClip = ctx.clip; - ctx.__originalMoveTo = ctx.moveTo; - ctx.__originalLineTo = ctx.lineTo; - ctx.__originalBezierCurveTo = ctx.bezierCurveTo; - ctx.__originalRect = ctx.rect; - ctx.__originalClosePath = ctx.closePath; - ctx.__originalBeginPath = ctx.beginPath; - ctx._removeMirroring = () => { - ctx.save = ctx.__originalSave; - ctx.restore = ctx.__originalRestore; - ctx.rotate = ctx.__originalRotate; - ctx.scale = ctx.__originalScale; - ctx.translate = ctx.__originalTranslate; - ctx.transform = ctx.__originalTransform; - ctx.setTransform = ctx.__originalSetTransform; - ctx.resetTransform = ctx.__originalResetTransform; - ctx.clip = ctx.__originalClip; - ctx.moveTo = ctx.__originalMoveTo; - ctx.lineTo = ctx.__originalLineTo; - ctx.bezierCurveTo = ctx.__originalBezierCurveTo; - ctx.rect = ctx.__originalRect; - ctx.closePath = ctx.__originalClosePath; - ctx.beginPath = ctx.__originalBeginPath; - delete ctx._removeMirroring; - }; - ctx.save = function ctxSave() { - destCtx.save(); - this.__originalSave(); - }; - ctx.restore = function ctxRestore() { - destCtx.restore(); - this.__originalRestore(); - }; - ctx.translate = function ctxTranslate(x, y) { - destCtx.translate(x, y); - this.__originalTranslate(x, y); - }; - ctx.scale = function ctxScale(x, y) { - destCtx.scale(x, y); - this.__originalScale(x, y); - }; - ctx.transform = function ctxTransform(a, b, c, d, e, f) { - destCtx.transform(a, b, c, d, e, f); - this.__originalTransform(a, b, c, d, e, f); - }; - ctx.setTransform = function ctxSetTransform(a, b, c, d, e, f) { - destCtx.setTransform(a, b, c, d, e, f); - this.__originalSetTransform(a, b, c, d, e, f); - }; - ctx.resetTransform = function ctxResetTransform() { - destCtx.resetTransform(); - this.__originalResetTransform(); - }; - ctx.rotate = function ctxRotate(angle) { - destCtx.rotate(angle); - this.__originalRotate(angle); - }; - ctx.clip = function ctxRotate(rule) { - destCtx.clip(rule); - this.__originalClip(rule); - }; - ctx.moveTo = function (x, y) { - destCtx.moveTo(x, y); - this.__originalMoveTo(x, y); - }; - ctx.lineTo = function (x, y) { - destCtx.lineTo(x, y); - this.__originalLineTo(x, y); - }; - ctx.bezierCurveTo = function (cp1x, cp1y, cp2x, cp2y, x, y) { - destCtx.bezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y); - this.__originalBezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y); - }; - ctx.rect = function (x, y, width, height) { - destCtx.rect(x, y, width, height); - this.__originalRect(x, y, width, height); - }; - ctx.closePath = function () { - destCtx.closePath(); - this.__originalClosePath(); - }; - ctx.beginPath = function () { - destCtx.beginPath(); - this.__originalBeginPath(); - }; -} -class CachedCanvases { - constructor(canvasFactory) { - this.canvasFactory = canvasFactory; - this.cache = Object.create(null); - } - getCanvas(id, width, height) { - let canvasEntry; - if (this.cache[id] !== undefined) { - canvasEntry = this.cache[id]; - this.canvasFactory.reset(canvasEntry, width, height); - } else { - canvasEntry = this.canvasFactory.create(width, height); - this.cache[id] = canvasEntry; - } - return canvasEntry; - } - delete(id) { - delete this.cache[id]; - } - clear() { - for (const id in this.cache) { - const canvasEntry = this.cache[id]; - this.canvasFactory.destroy(canvasEntry); - delete this.cache[id]; - } - } -} -function drawImageAtIntegerCoords(ctx, srcImg, srcX, srcY, srcW, srcH, destX, destY, destW, destH) { - const [a, b, c, d, tx, ty] = getCurrentTransform(ctx); - if (b === 0 && c === 0) { - const tlX = destX * a + tx; - const rTlX = Math.round(tlX); - const tlY = destY * d + ty; - const rTlY = Math.round(tlY); - const brX = (destX + destW) * a + tx; - const rWidth = Math.abs(Math.round(brX) - rTlX) || 1; - const brY = (destY + destH) * d + ty; - const rHeight = Math.abs(Math.round(brY) - rTlY) || 1; - ctx.setTransform(Math.sign(a), 0, 0, Math.sign(d), rTlX, rTlY); - ctx.drawImage(srcImg, srcX, srcY, srcW, srcH, 0, 0, rWidth, rHeight); - ctx.setTransform(a, b, c, d, tx, ty); - return [rWidth, rHeight]; - } - if (a === 0 && d === 0) { - const tlX = destY * c + tx; - const rTlX = Math.round(tlX); - const tlY = destX * b + ty; - const rTlY = Math.round(tlY); - const brX = (destY + destH) * c + tx; - const rWidth = Math.abs(Math.round(brX) - rTlX) || 1; - const brY = (destX + destW) * b + ty; - const rHeight = Math.abs(Math.round(brY) - rTlY) || 1; - ctx.setTransform(0, Math.sign(b), Math.sign(c), 0, rTlX, rTlY); - ctx.drawImage(srcImg, srcX, srcY, srcW, srcH, 0, 0, rHeight, rWidth); - ctx.setTransform(a, b, c, d, tx, ty); - return [rHeight, rWidth]; - } - ctx.drawImage(srcImg, srcX, srcY, srcW, srcH, destX, destY, destW, destH); - const scaleX = Math.hypot(a, b); - const scaleY = Math.hypot(c, d); - return [scaleX * destW, scaleY * destH]; -} -function compileType3Glyph(imgData) { - const { - width, - height - } = imgData; - if (width > MAX_SIZE_TO_COMPILE || height > MAX_SIZE_TO_COMPILE) { - return null; - } - const POINT_TO_PROCESS_LIMIT = 1000; - const POINT_TYPES = new Uint8Array([0, 2, 4, 0, 1, 0, 5, 4, 8, 10, 0, 8, 0, 2, 1, 0]); - const width1 = width + 1; - let points = new Uint8Array(width1 * (height + 1)); - let i, j, j0; - const lineSize = width + 7 & ~7; - let data = new Uint8Array(lineSize * height), - pos = 0; - for (const elem of imgData.data) { - let mask = 128; - while (mask > 0) { - data[pos++] = elem & mask ? 0 : 255; - mask >>= 1; - } - } - let count = 0; - pos = 0; - if (data[pos] !== 0) { - points[0] = 1; - ++count; - } - for (j = 1; j < width; j++) { - if (data[pos] !== data[pos + 1]) { - points[j] = data[pos] ? 2 : 1; - ++count; - } - pos++; - } - if (data[pos] !== 0) { - points[j] = 2; - ++count; - } - for (i = 1; i < height; i++) { - pos = i * lineSize; - j0 = i * width1; - if (data[pos - lineSize] !== data[pos]) { - points[j0] = data[pos] ? 1 : 8; - ++count; - } - let sum = (data[pos] ? 4 : 0) + (data[pos - lineSize] ? 8 : 0); - for (j = 1; j < width; j++) { - sum = (sum >> 2) + (data[pos + 1] ? 4 : 0) + (data[pos - lineSize + 1] ? 8 : 0); - if (POINT_TYPES[sum]) { - points[j0 + j] = POINT_TYPES[sum]; - ++count; - } - pos++; - } - if (data[pos - lineSize] !== data[pos]) { - points[j0 + j] = data[pos] ? 2 : 4; - ++count; - } - if (count > POINT_TO_PROCESS_LIMIT) { - return null; - } - } - pos = lineSize * (height - 1); - j0 = i * width1; - if (data[pos] !== 0) { - points[j0] = 8; - ++count; - } - for (j = 1; j < width; j++) { - if (data[pos] !== data[pos + 1]) { - points[j0 + j] = data[pos] ? 4 : 8; - ++count; - } - pos++; - } - if (data[pos] !== 0) { - points[j0 + j] = 4; - ++count; - } - if (count > POINT_TO_PROCESS_LIMIT) { - return null; - } - const steps = new Int32Array([0, width1, -1, 0, -width1, 0, 0, 0, 1]); - const path = new Path2D(); - for (i = 0; count && i <= height; i++) { - let p = i * width1; - const end = p + width; - while (p < end && !points[p]) { - p++; - } - if (p === end) { - continue; - } - path.moveTo(p % width1, i); - const p0 = p; - let type = points[p]; - do { - const step = steps[type]; - do { - p += step; - } while (!points[p]); - const pp = points[p]; - if (pp !== 5 && pp !== 10) { - type = pp; - points[p] = 0; - } else { - type = pp & 0x33 * type >> 4; - points[p] &= type >> 2 | type << 2; - } - path.lineTo(p % width1, p / width1 | 0); - if (!points[p]) { - --count; - } - } while (p0 !== p); - --i; - } - data = null; - points = null; - const drawOutline = function (c) { - c.save(); - c.scale(1 / width, -1 / height); - c.translate(0, -height); - c.fill(path); - c.beginPath(); - c.restore(); - }; - return drawOutline; -} -class CanvasExtraState { - constructor(width, height) { - this.alphaIsShape = false; - this.fontSize = 0; - this.fontSizeScale = 1; - this.textMatrix = IDENTITY_MATRIX; - this.textMatrixScale = 1; - this.fontMatrix = FONT_IDENTITY_MATRIX; - this.leading = 0; - this.x = 0; - this.y = 0; - this.lineX = 0; - this.lineY = 0; - this.charSpacing = 0; - this.wordSpacing = 0; - this.textHScale = 1; - this.textRenderingMode = TextRenderingMode.FILL; - this.textRise = 0; - this.fillColor = "#000000"; - this.strokeColor = "#000000"; - this.patternFill = false; - this.fillAlpha = 1; - this.strokeAlpha = 1; - this.lineWidth = 1; - this.activeSMask = null; - this.transferMaps = "none"; - this.startNewPathAndClipBox([0, 0, width, height]); - } - clone() { - const clone = Object.create(this); - clone.clipBox = this.clipBox.slice(); - return clone; - } - setCurrentPoint(x, y) { - this.x = x; - this.y = y; - } - updatePathMinMax(transform, x, y) { - [x, y] = Util.applyTransform([x, y], transform); - this.minX = Math.min(this.minX, x); - this.minY = Math.min(this.minY, y); - this.maxX = Math.max(this.maxX, x); - this.maxY = Math.max(this.maxY, y); - } - updateRectMinMax(transform, rect) { - const p1 = Util.applyTransform(rect, transform); - const p2 = Util.applyTransform(rect.slice(2), transform); - const p3 = Util.applyTransform([rect[0], rect[3]], transform); - const p4 = Util.applyTransform([rect[2], rect[1]], transform); - this.minX = Math.min(this.minX, p1[0], p2[0], p3[0], p4[0]); - this.minY = Math.min(this.minY, p1[1], p2[1], p3[1], p4[1]); - this.maxX = Math.max(this.maxX, p1[0], p2[0], p3[0], p4[0]); - this.maxY = Math.max(this.maxY, p1[1], p2[1], p3[1], p4[1]); - } - updateScalingPathMinMax(transform, minMax) { - Util.scaleMinMax(transform, minMax); - this.minX = Math.min(this.minX, minMax[0]); - this.minY = Math.min(this.minY, minMax[1]); - this.maxX = Math.max(this.maxX, minMax[2]); - this.maxY = Math.max(this.maxY, minMax[3]); - } - updateCurvePathMinMax(transform, x0, y0, x1, y1, x2, y2, x3, y3, minMax) { - const box = Util.bezierBoundingBox(x0, y0, x1, y1, x2, y2, x3, y3, minMax); - if (minMax) { - return; - } - this.updateRectMinMax(transform, box); - } - getPathBoundingBox(pathType = PathType.FILL, transform = null) { - const box = [this.minX, this.minY, this.maxX, this.maxY]; - if (pathType === PathType.STROKE) { - if (!transform) { - unreachable("Stroke bounding box must include transform."); - } - const scale = Util.singularValueDecompose2dScale(transform); - const xStrokePad = scale[0] * this.lineWidth / 2; - const yStrokePad = scale[1] * this.lineWidth / 2; - box[0] -= xStrokePad; - box[1] -= yStrokePad; - box[2] += xStrokePad; - box[3] += yStrokePad; - } - return box; - } - updateClipFromPath() { - const intersect = Util.intersect(this.clipBox, this.getPathBoundingBox()); - this.startNewPathAndClipBox(intersect || [0, 0, 0, 0]); - } - isEmptyClip() { - return this.minX === Infinity; - } - startNewPathAndClipBox(box) { - this.clipBox = box; - this.minX = Infinity; - this.minY = Infinity; - this.maxX = 0; - this.maxY = 0; - } - getClippedPathBoundingBox(pathType = PathType.FILL, transform = null) { - return Util.intersect(this.clipBox, this.getPathBoundingBox(pathType, transform)); - } -} -function putBinaryImageData(ctx, imgData) { - if (typeof ImageData !== "undefined" && imgData instanceof ImageData) { - ctx.putImageData(imgData, 0, 0); - return; - } - const height = imgData.height, - width = imgData.width; - const partialChunkHeight = height % FULL_CHUNK_HEIGHT; - const fullChunks = (height - partialChunkHeight) / FULL_CHUNK_HEIGHT; - const totalChunks = partialChunkHeight === 0 ? fullChunks : fullChunks + 1; - const chunkImgData = ctx.createImageData(width, FULL_CHUNK_HEIGHT); - let srcPos = 0, - destPos; - const src = imgData.data; - const dest = chunkImgData.data; - let i, j, thisChunkHeight, elemsInThisChunk; - if (imgData.kind === util_ImageKind.GRAYSCALE_1BPP) { - const srcLength = src.byteLength; - const dest32 = new Uint32Array(dest.buffer, 0, dest.byteLength >> 2); - const dest32DataLength = dest32.length; - const fullSrcDiff = width + 7 >> 3; - const white = 0xffffffff; - const black = util_FeatureTest.isLittleEndian ? 0xff000000 : 0x000000ff; - for (i = 0; i < totalChunks; i++) { - thisChunkHeight = i < fullChunks ? FULL_CHUNK_HEIGHT : partialChunkHeight; - destPos = 0; - for (j = 0; j < thisChunkHeight; j++) { - const srcDiff = srcLength - srcPos; - let k = 0; - const kEnd = srcDiff > fullSrcDiff ? width : srcDiff * 8 - 7; - const kEndUnrolled = kEnd & ~7; - let mask = 0; - let srcByte = 0; - for (; k < kEndUnrolled; k += 8) { - srcByte = src[srcPos++]; - dest32[destPos++] = srcByte & 128 ? white : black; - dest32[destPos++] = srcByte & 64 ? white : black; - dest32[destPos++] = srcByte & 32 ? white : black; - dest32[destPos++] = srcByte & 16 ? white : black; - dest32[destPos++] = srcByte & 8 ? white : black; - dest32[destPos++] = srcByte & 4 ? white : black; - dest32[destPos++] = srcByte & 2 ? white : black; - dest32[destPos++] = srcByte & 1 ? white : black; - } - for (; k < kEnd; k++) { - if (mask === 0) { - srcByte = src[srcPos++]; - mask = 128; - } - dest32[destPos++] = srcByte & mask ? white : black; - mask >>= 1; - } - } - while (destPos < dest32DataLength) { - dest32[destPos++] = 0; - } - ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT); - } - } else if (imgData.kind === util_ImageKind.RGBA_32BPP) { - j = 0; - elemsInThisChunk = width * FULL_CHUNK_HEIGHT * 4; - for (i = 0; i < fullChunks; i++) { - dest.set(src.subarray(srcPos, srcPos + elemsInThisChunk)); - srcPos += elemsInThisChunk; - ctx.putImageData(chunkImgData, 0, j); - j += FULL_CHUNK_HEIGHT; - } - if (i < totalChunks) { - elemsInThisChunk = width * partialChunkHeight * 4; - dest.set(src.subarray(srcPos, srcPos + elemsInThisChunk)); - ctx.putImageData(chunkImgData, 0, j); - } - } else if (imgData.kind === util_ImageKind.RGB_24BPP) { - thisChunkHeight = FULL_CHUNK_HEIGHT; - elemsInThisChunk = width * thisChunkHeight; - for (i = 0; i < totalChunks; i++) { - if (i >= fullChunks) { - thisChunkHeight = partialChunkHeight; - elemsInThisChunk = width * thisChunkHeight; - } - destPos = 0; - for (j = elemsInThisChunk; j--;) { - dest[destPos++] = src[srcPos++]; - dest[destPos++] = src[srcPos++]; - dest[destPos++] = src[srcPos++]; - dest[destPos++] = 255; - } - ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT); - } - } else { - throw new Error(`bad image kind: ${imgData.kind}`); - } -} -function putBinaryImageMask(ctx, imgData) { - if (imgData.bitmap) { - ctx.drawImage(imgData.bitmap, 0, 0); - return; - } - const height = imgData.height, - width = imgData.width; - const partialChunkHeight = height % FULL_CHUNK_HEIGHT; - const fullChunks = (height - partialChunkHeight) / FULL_CHUNK_HEIGHT; - const totalChunks = partialChunkHeight === 0 ? fullChunks : fullChunks + 1; - const chunkImgData = ctx.createImageData(width, FULL_CHUNK_HEIGHT); - let srcPos = 0; - const src = imgData.data; - const dest = chunkImgData.data; - for (let i = 0; i < totalChunks; i++) { - const thisChunkHeight = i < fullChunks ? FULL_CHUNK_HEIGHT : partialChunkHeight; - ({ - srcPos - } = convertBlackAndWhiteToRGBA({ - src, - srcPos, - dest, - width, - height: thisChunkHeight, - nonBlackColor: 0 - })); - ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT); - } -} -function copyCtxState(sourceCtx, destCtx) { - const properties = ["strokeStyle", "fillStyle", "fillRule", "globalAlpha", "lineWidth", "lineCap", "lineJoin", "miterLimit", "globalCompositeOperation", "font", "filter"]; - for (const property of properties) { - if (sourceCtx[property] !== undefined) { - destCtx[property] = sourceCtx[property]; - } - } - if (sourceCtx.setLineDash !== undefined) { - destCtx.setLineDash(sourceCtx.getLineDash()); - destCtx.lineDashOffset = sourceCtx.lineDashOffset; - } -} -function resetCtxToDefault(ctx) { - ctx.strokeStyle = ctx.fillStyle = "#000000"; - ctx.fillRule = "nonzero"; - ctx.globalAlpha = 1; - ctx.lineWidth = 1; - ctx.lineCap = "butt"; - ctx.lineJoin = "miter"; - ctx.miterLimit = 10; - ctx.globalCompositeOperation = "source-over"; - ctx.font = "10px sans-serif"; - if (ctx.setLineDash !== undefined) { - ctx.setLineDash([]); - ctx.lineDashOffset = 0; - } - if (!isNodeJS) { - const { - filter - } = ctx; - if (filter !== "none" && filter !== "") { - ctx.filter = "none"; - } - } -} -function getImageSmoothingEnabled(transform, interpolate) { - if (interpolate) { - return true; - } - const scale = Util.singularValueDecompose2dScale(transform); - scale[0] = Math.fround(scale[0]); - scale[1] = Math.fround(scale[1]); - const actualScale = Math.fround((globalThis.devicePixelRatio || 1) * PixelsPerInch.PDF_TO_CSS_UNITS); - return scale[0] <= actualScale && scale[1] <= actualScale; -} -const LINE_CAP_STYLES = ["butt", "round", "square"]; -const LINE_JOIN_STYLES = ["miter", "round", "bevel"]; -const NORMAL_CLIP = {}; -const EO_CLIP = {}; -class CanvasGraphics { - constructor(canvasCtx, commonObjs, objs, canvasFactory, filterFactory, { - optionalContentConfig, - markedContentStack = null - }, annotationCanvasMap, pageColors) { - this.ctx = canvasCtx; - this.current = new CanvasExtraState(this.ctx.canvas.width, this.ctx.canvas.height); - this.stateStack = []; - this.pendingClip = null; - this.pendingEOFill = false; - this.res = null; - this.xobjs = null; - this.commonObjs = commonObjs; - this.objs = objs; - this.canvasFactory = canvasFactory; - this.filterFactory = filterFactory; - this.groupStack = []; - this.processingType3 = null; - this.baseTransform = null; - this.baseTransformStack = []; - this.groupLevel = 0; - this.smaskStack = []; - this.smaskCounter = 0; - this.tempSMask = null; - this.suspendedCtx = null; - this.contentVisible = true; - this.markedContentStack = markedContentStack || []; - this.optionalContentConfig = optionalContentConfig; - this.cachedCanvases = new CachedCanvases(this.canvasFactory); - this.cachedPatterns = new Map(); - this.annotationCanvasMap = annotationCanvasMap; - this.viewportScale = 1; - this.outputScaleX = 1; - this.outputScaleY = 1; - this.pageColors = pageColors; - this._cachedScaleForStroking = [-1, 0]; - this._cachedGetSinglePixelWidth = null; - this._cachedBitmapsMap = new Map(); - } - getObject(data, fallback = null) { - if (typeof data === "string") { - return data.startsWith("g_") ? this.commonObjs.get(data) : this.objs.get(data); - } - return fallback; - } - beginDrawing({ - transform, - viewport, - transparency = false, - background = null - }) { - const width = this.ctx.canvas.width; - const height = this.ctx.canvas.height; - const savedFillStyle = this.ctx.fillStyle; - this.ctx.fillStyle = background || "#ffffff"; - this.ctx.fillRect(0, 0, width, height); - this.ctx.fillStyle = savedFillStyle; - if (transparency) { - const transparentCanvas = this.cachedCanvases.getCanvas("transparent", width, height); - this.compositeCtx = this.ctx; - this.transparentCanvas = transparentCanvas.canvas; - this.ctx = transparentCanvas.context; - this.ctx.save(); - this.ctx.transform(...getCurrentTransform(this.compositeCtx)); - } - this.ctx.save(); - resetCtxToDefault(this.ctx); - if (transform) { - this.ctx.transform(...transform); - this.outputScaleX = transform[0]; - this.outputScaleY = transform[0]; - } - this.ctx.transform(...viewport.transform); - this.viewportScale = viewport.scale; - this.baseTransform = getCurrentTransform(this.ctx); - } - executeOperatorList(operatorList, executionStartIdx, continueCallback, stepper) { - const argsArray = operatorList.argsArray; - const fnArray = operatorList.fnArray; - let i = executionStartIdx || 0; - const argsArrayLen = argsArray.length; - if (argsArrayLen === i) { - return i; - } - const chunkOperations = argsArrayLen - i > EXECUTION_STEPS && typeof continueCallback === "function"; - const endTime = chunkOperations ? Date.now() + EXECUTION_TIME : 0; - let steps = 0; - const commonObjs = this.commonObjs; - const objs = this.objs; - let fnId; - while (true) { - if (stepper !== undefined && i === stepper.nextBreakPoint) { - stepper.breakIt(i, continueCallback); - return i; - } - fnId = fnArray[i]; - if (fnId !== OPS.dependency) { - this[fnId].apply(this, argsArray[i]); - } else { - for (const depObjId of argsArray[i]) { - const objsPool = depObjId.startsWith("g_") ? commonObjs : objs; - if (!objsPool.has(depObjId)) { - objsPool.get(depObjId, continueCallback); - return i; - } - } - } - i++; - if (i === argsArrayLen) { - return i; - } - if (chunkOperations && ++steps > EXECUTION_STEPS) { - if (Date.now() > endTime) { - continueCallback(); - return i; - } - steps = 0; - } - } - } - #restoreInitialState() { - while (this.stateStack.length || this.inSMaskMode) { - this.restore(); - } - this.ctx.restore(); - if (this.transparentCanvas) { - this.ctx = this.compositeCtx; - this.ctx.save(); - this.ctx.setTransform(1, 0, 0, 1, 0, 0); - this.ctx.drawImage(this.transparentCanvas, 0, 0); - this.ctx.restore(); - this.transparentCanvas = null; - } - } - endDrawing() { - this.#restoreInitialState(); - this.cachedCanvases.clear(); - this.cachedPatterns.clear(); - for (const cache of this._cachedBitmapsMap.values()) { - for (const canvas of cache.values()) { - if (typeof HTMLCanvasElement !== "undefined" && canvas instanceof HTMLCanvasElement) { - canvas.width = canvas.height = 0; - } - } - cache.clear(); - } - this._cachedBitmapsMap.clear(); - this.#drawFilter(); - } - #drawFilter() { - if (this.pageColors) { - const hcmFilterId = this.filterFactory.addHCMFilter(this.pageColors.foreground, this.pageColors.background); - if (hcmFilterId !== "none") { - const savedFilter = this.ctx.filter; - this.ctx.filter = hcmFilterId; - this.ctx.drawImage(this.ctx.canvas, 0, 0); - this.ctx.filter = savedFilter; - } - } - } - _scaleImage(img, inverseTransform) { - const width = img.width; - const height = img.height; - let widthScale = Math.max(Math.hypot(inverseTransform[0], inverseTransform[1]), 1); - let heightScale = Math.max(Math.hypot(inverseTransform[2], inverseTransform[3]), 1); - let paintWidth = width, - paintHeight = height; - let tmpCanvasId = "prescale1"; - let tmpCanvas, tmpCtx; - while (widthScale > 2 && paintWidth > 1 || heightScale > 2 && paintHeight > 1) { - let newWidth = paintWidth, - newHeight = paintHeight; - if (widthScale > 2 && paintWidth > 1) { - newWidth = paintWidth >= 16384 ? Math.floor(paintWidth / 2) - 1 || 1 : Math.ceil(paintWidth / 2); - widthScale /= paintWidth / newWidth; - } - if (heightScale > 2 && paintHeight > 1) { - newHeight = paintHeight >= 16384 ? Math.floor(paintHeight / 2) - 1 || 1 : Math.ceil(paintHeight) / 2; - heightScale /= paintHeight / newHeight; - } - tmpCanvas = this.cachedCanvases.getCanvas(tmpCanvasId, newWidth, newHeight); - tmpCtx = tmpCanvas.context; - tmpCtx.clearRect(0, 0, newWidth, newHeight); - tmpCtx.drawImage(img, 0, 0, paintWidth, paintHeight, 0, 0, newWidth, newHeight); - img = tmpCanvas.canvas; - paintWidth = newWidth; - paintHeight = newHeight; - tmpCanvasId = tmpCanvasId === "prescale1" ? "prescale2" : "prescale1"; - } - return { - img, - paintWidth, - paintHeight - }; - } - _createMaskCanvas(img) { - const ctx = this.ctx; - const { - width, - height - } = img; - const fillColor = this.current.fillColor; - const isPatternFill = this.current.patternFill; - const currentTransform = getCurrentTransform(ctx); - let cache, cacheKey, scaled, maskCanvas; - if ((img.bitmap || img.data) && img.count > 1) { - const mainKey = img.bitmap || img.data.buffer; - cacheKey = JSON.stringify(isPatternFill ? currentTransform : [currentTransform.slice(0, 4), fillColor]); - cache = this._cachedBitmapsMap.get(mainKey); - if (!cache) { - cache = new Map(); - this._cachedBitmapsMap.set(mainKey, cache); - } - const cachedImage = cache.get(cacheKey); - if (cachedImage && !isPatternFill) { - const offsetX = Math.round(Math.min(currentTransform[0], currentTransform[2]) + currentTransform[4]); - const offsetY = Math.round(Math.min(currentTransform[1], currentTransform[3]) + currentTransform[5]); - return { - canvas: cachedImage, - offsetX, - offsetY - }; - } - scaled = cachedImage; - } - if (!scaled) { - maskCanvas = this.cachedCanvases.getCanvas("maskCanvas", width, height); - putBinaryImageMask(maskCanvas.context, img); - } - let maskToCanvas = Util.transform(currentTransform, [1 / width, 0, 0, -1 / height, 0, 0]); - maskToCanvas = Util.transform(maskToCanvas, [1, 0, 0, 1, 0, -height]); - const [minX, minY, maxX, maxY] = Util.getAxialAlignedBoundingBox([0, 0, width, height], maskToCanvas); - const drawnWidth = Math.round(maxX - minX) || 1; - const drawnHeight = Math.round(maxY - minY) || 1; - const fillCanvas = this.cachedCanvases.getCanvas("fillCanvas", drawnWidth, drawnHeight); - const fillCtx = fillCanvas.context; - const offsetX = minX; - const offsetY = minY; - fillCtx.translate(-offsetX, -offsetY); - fillCtx.transform(...maskToCanvas); - if (!scaled) { - scaled = this._scaleImage(maskCanvas.canvas, getCurrentTransformInverse(fillCtx)); - scaled = scaled.img; - if (cache && isPatternFill) { - cache.set(cacheKey, scaled); - } - } - fillCtx.imageSmoothingEnabled = getImageSmoothingEnabled(getCurrentTransform(fillCtx), img.interpolate); - drawImageAtIntegerCoords(fillCtx, scaled, 0, 0, scaled.width, scaled.height, 0, 0, width, height); - fillCtx.globalCompositeOperation = "source-in"; - const inverse = Util.transform(getCurrentTransformInverse(fillCtx), [1, 0, 0, 1, -offsetX, -offsetY]); - fillCtx.fillStyle = isPatternFill ? fillColor.getPattern(ctx, this, inverse, PathType.FILL) : fillColor; - fillCtx.fillRect(0, 0, width, height); - if (cache && !isPatternFill) { - this.cachedCanvases.delete("fillCanvas"); - cache.set(cacheKey, fillCanvas.canvas); - } - return { - canvas: fillCanvas.canvas, - offsetX: Math.round(offsetX), - offsetY: Math.round(offsetY) - }; - } - setLineWidth(width) { - if (width !== this.current.lineWidth) { - this._cachedScaleForStroking[0] = -1; - } - this.current.lineWidth = width; - this.ctx.lineWidth = width; - } - setLineCap(style) { - this.ctx.lineCap = LINE_CAP_STYLES[style]; - } - setLineJoin(style) { - this.ctx.lineJoin = LINE_JOIN_STYLES[style]; - } - setMiterLimit(limit) { - this.ctx.miterLimit = limit; - } - setDash(dashArray, dashPhase) { - const ctx = this.ctx; - if (ctx.setLineDash !== undefined) { - ctx.setLineDash(dashArray); - ctx.lineDashOffset = dashPhase; - } - } - setRenderingIntent(intent) {} - setFlatness(flatness) {} - setGState(states) { - for (const [key, value] of states) { - switch (key) { - case "LW": - this.setLineWidth(value); - break; - case "LC": - this.setLineCap(value); - break; - case "LJ": - this.setLineJoin(value); - break; - case "ML": - this.setMiterLimit(value); - break; - case "D": - this.setDash(value[0], value[1]); - break; - case "RI": - this.setRenderingIntent(value); - break; - case "FL": - this.setFlatness(value); - break; - case "Font": - this.setFont(value[0], value[1]); - break; - case "CA": - this.current.strokeAlpha = value; - break; - case "ca": - this.current.fillAlpha = value; - this.ctx.globalAlpha = value; - break; - case "BM": - this.ctx.globalCompositeOperation = value; - break; - case "SMask": - this.current.activeSMask = value ? this.tempSMask : null; - this.tempSMask = null; - this.checkSMaskState(); - break; - case "TR": - this.ctx.filter = this.current.transferMaps = this.filterFactory.addFilter(value); - break; - } - } - } - get inSMaskMode() { - return !!this.suspendedCtx; - } - checkSMaskState() { - const inSMaskMode = this.inSMaskMode; - if (this.current.activeSMask && !inSMaskMode) { - this.beginSMaskMode(); - } else if (!this.current.activeSMask && inSMaskMode) { - this.endSMaskMode(); - } - } - beginSMaskMode() { - if (this.inSMaskMode) { - throw new Error("beginSMaskMode called while already in smask mode"); - } - const drawnWidth = this.ctx.canvas.width; - const drawnHeight = this.ctx.canvas.height; - const cacheId = "smaskGroupAt" + this.groupLevel; - const scratchCanvas = this.cachedCanvases.getCanvas(cacheId, drawnWidth, drawnHeight); - this.suspendedCtx = this.ctx; - this.ctx = scratchCanvas.context; - const ctx = this.ctx; - ctx.setTransform(...getCurrentTransform(this.suspendedCtx)); - copyCtxState(this.suspendedCtx, ctx); - mirrorContextOperations(ctx, this.suspendedCtx); - this.setGState([["BM", "source-over"], ["ca", 1], ["CA", 1]]); - } - endSMaskMode() { - if (!this.inSMaskMode) { - throw new Error("endSMaskMode called while not in smask mode"); - } - this.ctx._removeMirroring(); - copyCtxState(this.ctx, this.suspendedCtx); - this.ctx = this.suspendedCtx; - this.suspendedCtx = null; - } - compose(dirtyBox) { - if (!this.current.activeSMask) { - return; - } - if (!dirtyBox) { - dirtyBox = [0, 0, this.ctx.canvas.width, this.ctx.canvas.height]; - } else { - dirtyBox[0] = Math.floor(dirtyBox[0]); - dirtyBox[1] = Math.floor(dirtyBox[1]); - dirtyBox[2] = Math.ceil(dirtyBox[2]); - dirtyBox[3] = Math.ceil(dirtyBox[3]); - } - const smask = this.current.activeSMask; - const suspendedCtx = this.suspendedCtx; - this.composeSMask(suspendedCtx, smask, this.ctx, dirtyBox); - this.ctx.save(); - this.ctx.setTransform(1, 0, 0, 1, 0, 0); - this.ctx.clearRect(0, 0, this.ctx.canvas.width, this.ctx.canvas.height); - this.ctx.restore(); - } - composeSMask(ctx, smask, layerCtx, layerBox) { - const layerOffsetX = layerBox[0]; - const layerOffsetY = layerBox[1]; - const layerWidth = layerBox[2] - layerOffsetX; - const layerHeight = layerBox[3] - layerOffsetY; - if (layerWidth === 0 || layerHeight === 0) { - return; - } - this.genericComposeSMask(smask.context, layerCtx, layerWidth, layerHeight, smask.subtype, smask.backdrop, smask.transferMap, layerOffsetX, layerOffsetY, smask.offsetX, smask.offsetY); - ctx.save(); - ctx.globalAlpha = 1; - ctx.globalCompositeOperation = "source-over"; - ctx.setTransform(1, 0, 0, 1, 0, 0); - ctx.drawImage(layerCtx.canvas, 0, 0); - ctx.restore(); - } - genericComposeSMask(maskCtx, layerCtx, width, height, subtype, backdrop, transferMap, layerOffsetX, layerOffsetY, maskOffsetX, maskOffsetY) { - let maskCanvas = maskCtx.canvas; - let maskX = layerOffsetX - maskOffsetX; - let maskY = layerOffsetY - maskOffsetY; - if (backdrop) { - if (maskX < 0 || maskY < 0 || maskX + width > maskCanvas.width || maskY + height > maskCanvas.height) { - const canvas = this.cachedCanvases.getCanvas("maskExtension", width, height); - const ctx = canvas.context; - ctx.drawImage(maskCanvas, -maskX, -maskY); - if (backdrop.some(c => c !== 0)) { - ctx.globalCompositeOperation = "destination-atop"; - ctx.fillStyle = Util.makeHexColor(...backdrop); - ctx.fillRect(0, 0, width, height); - ctx.globalCompositeOperation = "source-over"; - } - maskCanvas = canvas.canvas; - maskX = maskY = 0; - } else if (backdrop.some(c => c !== 0)) { - maskCtx.save(); - maskCtx.globalAlpha = 1; - maskCtx.setTransform(1, 0, 0, 1, 0, 0); - const clip = new Path2D(); - clip.rect(maskX, maskY, width, height); - maskCtx.clip(clip); - maskCtx.globalCompositeOperation = "destination-atop"; - maskCtx.fillStyle = Util.makeHexColor(...backdrop); - maskCtx.fillRect(maskX, maskY, width, height); - maskCtx.restore(); - } - } - layerCtx.save(); - layerCtx.globalAlpha = 1; - layerCtx.setTransform(1, 0, 0, 1, 0, 0); - if (subtype === "Alpha" && transferMap) { - layerCtx.filter = this.filterFactory.addAlphaFilter(transferMap); - } else if (subtype === "Luminosity") { - layerCtx.filter = this.filterFactory.addLuminosityFilter(transferMap); - } - const clip = new Path2D(); - clip.rect(layerOffsetX, layerOffsetY, width, height); - layerCtx.clip(clip); - layerCtx.globalCompositeOperation = "destination-in"; - layerCtx.drawImage(maskCanvas, maskX, maskY, width, height, layerOffsetX, layerOffsetY, width, height); - layerCtx.restore(); - } - save() { - if (this.inSMaskMode) { - copyCtxState(this.ctx, this.suspendedCtx); - this.suspendedCtx.save(); - } else { - this.ctx.save(); - } - const old = this.current; - this.stateStack.push(old); - this.current = old.clone(); - } - restore() { - if (this.stateStack.length === 0 && this.inSMaskMode) { - this.endSMaskMode(); - } - if (this.stateStack.length !== 0) { - this.current = this.stateStack.pop(); - if (this.inSMaskMode) { - this.suspendedCtx.restore(); - copyCtxState(this.suspendedCtx, this.ctx); - } else { - this.ctx.restore(); - } - this.checkSMaskState(); - this.pendingClip = null; - this._cachedScaleForStroking[0] = -1; - this._cachedGetSinglePixelWidth = null; - } - } - transform(a, b, c, d, e, f) { - this.ctx.transform(a, b, c, d, e, f); - this._cachedScaleForStroking[0] = -1; - this._cachedGetSinglePixelWidth = null; - } - constructPath(ops, args, minMax) { - const ctx = this.ctx; - const current = this.current; - let x = current.x, - y = current.y; - let startX, startY; - const currentTransform = getCurrentTransform(ctx); - const isScalingMatrix = currentTransform[0] === 0 && currentTransform[3] === 0 || currentTransform[1] === 0 && currentTransform[2] === 0; - const minMaxForBezier = isScalingMatrix ? minMax.slice(0) : null; - for (let i = 0, j = 0, ii = ops.length; i < ii; i++) { - switch (ops[i] | 0) { - case OPS.rectangle: - x = args[j++]; - y = args[j++]; - const width = args[j++]; - const height = args[j++]; - const xw = x + width; - const yh = y + height; - ctx.moveTo(x, y); - if (width === 0 || height === 0) { - ctx.lineTo(xw, yh); - } else { - ctx.lineTo(xw, y); - ctx.lineTo(xw, yh); - ctx.lineTo(x, yh); - } - if (!isScalingMatrix) { - current.updateRectMinMax(currentTransform, [x, y, xw, yh]); - } - ctx.closePath(); - break; - case OPS.moveTo: - x = args[j++]; - y = args[j++]; - ctx.moveTo(x, y); - if (!isScalingMatrix) { - current.updatePathMinMax(currentTransform, x, y); - } - break; - case OPS.lineTo: - x = args[j++]; - y = args[j++]; - ctx.lineTo(x, y); - if (!isScalingMatrix) { - current.updatePathMinMax(currentTransform, x, y); - } - break; - case OPS.curveTo: - startX = x; - startY = y; - x = args[j + 4]; - y = args[j + 5]; - ctx.bezierCurveTo(args[j], args[j + 1], args[j + 2], args[j + 3], x, y); - current.updateCurvePathMinMax(currentTransform, startX, startY, args[j], args[j + 1], args[j + 2], args[j + 3], x, y, minMaxForBezier); - j += 6; - break; - case OPS.curveTo2: - startX = x; - startY = y; - ctx.bezierCurveTo(x, y, args[j], args[j + 1], args[j + 2], args[j + 3]); - current.updateCurvePathMinMax(currentTransform, startX, startY, x, y, args[j], args[j + 1], args[j + 2], args[j + 3], minMaxForBezier); - x = args[j + 2]; - y = args[j + 3]; - j += 4; - break; - case OPS.curveTo3: - startX = x; - startY = y; - x = args[j + 2]; - y = args[j + 3]; - ctx.bezierCurveTo(args[j], args[j + 1], x, y, x, y); - current.updateCurvePathMinMax(currentTransform, startX, startY, args[j], args[j + 1], x, y, x, y, minMaxForBezier); - j += 4; - break; - case OPS.closePath: - ctx.closePath(); - break; - } - } - if (isScalingMatrix) { - current.updateScalingPathMinMax(currentTransform, minMaxForBezier); - } - current.setCurrentPoint(x, y); - } - closePath() { - this.ctx.closePath(); - } - stroke(consumePath = true) { - const ctx = this.ctx; - const strokeColor = this.current.strokeColor; - ctx.globalAlpha = this.current.strokeAlpha; - if (this.contentVisible) { - if (typeof strokeColor === "object" && strokeColor?.getPattern) { - ctx.save(); - ctx.strokeStyle = strokeColor.getPattern(ctx, this, getCurrentTransformInverse(ctx), PathType.STROKE); - this.rescaleAndStroke(false); - ctx.restore(); - } else { - this.rescaleAndStroke(true); - } - } - if (consumePath) { - this.consumePath(this.current.getClippedPathBoundingBox()); - } - ctx.globalAlpha = this.current.fillAlpha; - } - closeStroke() { - this.closePath(); - this.stroke(); - } - fill(consumePath = true) { - const ctx = this.ctx; - const fillColor = this.current.fillColor; - const isPatternFill = this.current.patternFill; - let needRestore = false; - if (isPatternFill) { - ctx.save(); - ctx.fillStyle = fillColor.getPattern(ctx, this, getCurrentTransformInverse(ctx), PathType.FILL); - needRestore = true; - } - const intersect = this.current.getClippedPathBoundingBox(); - if (this.contentVisible && intersect !== null) { - if (this.pendingEOFill) { - ctx.fill("evenodd"); - this.pendingEOFill = false; - } else { - ctx.fill(); - } - } - if (needRestore) { - ctx.restore(); - } - if (consumePath) { - this.consumePath(intersect); - } - } - eoFill() { - this.pendingEOFill = true; - this.fill(); - } - fillStroke() { - this.fill(false); - this.stroke(false); - this.consumePath(); - } - eoFillStroke() { - this.pendingEOFill = true; - this.fillStroke(); - } - closeFillStroke() { - this.closePath(); - this.fillStroke(); - } - closeEOFillStroke() { - this.pendingEOFill = true; - this.closePath(); - this.fillStroke(); - } - endPath() { - this.consumePath(); - } - clip() { - this.pendingClip = NORMAL_CLIP; - } - eoClip() { - this.pendingClip = EO_CLIP; - } - beginText() { - this.current.textMatrix = IDENTITY_MATRIX; - this.current.textMatrixScale = 1; - this.current.x = this.current.lineX = 0; - this.current.y = this.current.lineY = 0; - } - endText() { - const paths = this.pendingTextPaths; - const ctx = this.ctx; - if (paths === undefined) { - ctx.beginPath(); - return; - } - ctx.save(); - ctx.beginPath(); - for (const path of paths) { - ctx.setTransform(...path.transform); - ctx.translate(path.x, path.y); - path.addToPath(ctx, path.fontSize); - } - ctx.restore(); - ctx.clip(); - ctx.beginPath(); - delete this.pendingTextPaths; - } - setCharSpacing(spacing) { - this.current.charSpacing = spacing; - } - setWordSpacing(spacing) { - this.current.wordSpacing = spacing; - } - setHScale(scale) { - this.current.textHScale = scale / 100; - } - setLeading(leading) { - this.current.leading = -leading; - } - setFont(fontRefName, size) { - const fontObj = this.commonObjs.get(fontRefName); - const current = this.current; - if (!fontObj) { - throw new Error(`Can't find font for ${fontRefName}`); - } - current.fontMatrix = fontObj.fontMatrix || FONT_IDENTITY_MATRIX; - if (current.fontMatrix[0] === 0 || current.fontMatrix[3] === 0) { - warn("Invalid font matrix for font " + fontRefName); - } - if (size < 0) { - size = -size; - current.fontDirection = -1; - } else { - current.fontDirection = 1; - } - this.current.font = fontObj; - this.current.fontSize = size; - if (fontObj.isType3Font) { - return; - } - const name = fontObj.loadedName || "sans-serif"; - const typeface = fontObj.systemFontInfo?.css || `"${name}", ${fontObj.fallbackName}`; - let bold = "normal"; - if (fontObj.black) { - bold = "900"; - } else if (fontObj.bold) { - bold = "bold"; - } - const italic = fontObj.italic ? "italic" : "normal"; - let browserFontSize = size; - if (size < MIN_FONT_SIZE) { - browserFontSize = MIN_FONT_SIZE; - } else if (size > MAX_FONT_SIZE) { - browserFontSize = MAX_FONT_SIZE; - } - this.current.fontSizeScale = size / browserFontSize; - this.ctx.font = `${italic} ${bold} ${browserFontSize}px ${typeface}`; - } - setTextRenderingMode(mode) { - this.current.textRenderingMode = mode; - } - setTextRise(rise) { - this.current.textRise = rise; - } - moveText(x, y) { - this.current.x = this.current.lineX += x; - this.current.y = this.current.lineY += y; - } - setLeadingMoveText(x, y) { - this.setLeading(-y); - this.moveText(x, y); - } - setTextMatrix(a, b, c, d, e, f) { - this.current.textMatrix = [a, b, c, d, e, f]; - this.current.textMatrixScale = Math.hypot(a, b); - this.current.x = this.current.lineX = 0; - this.current.y = this.current.lineY = 0; - } - nextLine() { - this.moveText(0, this.current.leading); - } - paintChar(character, x, y, patternTransform) { - const ctx = this.ctx; - const current = this.current; - const font = current.font; - const textRenderingMode = current.textRenderingMode; - const fontSize = current.fontSize / current.fontSizeScale; - const fillStrokeMode = textRenderingMode & TextRenderingMode.FILL_STROKE_MASK; - const isAddToPathSet = !!(textRenderingMode & TextRenderingMode.ADD_TO_PATH_FLAG); - const patternFill = current.patternFill && !font.missingFile; - let addToPath; - if (font.disableFontFace || isAddToPathSet || patternFill) { - addToPath = font.getPathGenerator(this.commonObjs, character); - } - if (font.disableFontFace || patternFill) { - ctx.save(); - ctx.translate(x, y); - ctx.beginPath(); - addToPath(ctx, fontSize); - if (patternTransform) { - ctx.setTransform(...patternTransform); - } - if (fillStrokeMode === TextRenderingMode.FILL || fillStrokeMode === TextRenderingMode.FILL_STROKE) { - ctx.fill(); - } - if (fillStrokeMode === TextRenderingMode.STROKE || fillStrokeMode === TextRenderingMode.FILL_STROKE) { - ctx.stroke(); - } - ctx.restore(); - } else { - if (fillStrokeMode === TextRenderingMode.FILL || fillStrokeMode === TextRenderingMode.FILL_STROKE) { - ctx.fillText(character, x, y); - } - if (fillStrokeMode === TextRenderingMode.STROKE || fillStrokeMode === TextRenderingMode.FILL_STROKE) { - ctx.strokeText(character, x, y); - } - } - if (isAddToPathSet) { - const paths = this.pendingTextPaths ||= []; - paths.push({ - transform: getCurrentTransform(ctx), - x, - y, - fontSize, - addToPath - }); - } - } - get isFontSubpixelAAEnabled() { - const { - context: ctx - } = this.cachedCanvases.getCanvas("isFontSubpixelAAEnabled", 10, 10); - ctx.scale(1.5, 1); - ctx.fillText("I", 0, 10); - const data = ctx.getImageData(0, 0, 10, 10).data; - let enabled = false; - for (let i = 3; i < data.length; i += 4) { - if (data[i] > 0 && data[i] < 255) { - enabled = true; - break; - } - } - return shadow(this, "isFontSubpixelAAEnabled", enabled); - } - showText(glyphs) { - const current = this.current; - const font = current.font; - if (font.isType3Font) { - return this.showType3Text(glyphs); - } - const fontSize = current.fontSize; - if (fontSize === 0) { - return undefined; - } - const ctx = this.ctx; - const fontSizeScale = current.fontSizeScale; - const charSpacing = current.charSpacing; - const wordSpacing = current.wordSpacing; - const fontDirection = current.fontDirection; - const textHScale = current.textHScale * fontDirection; - const glyphsLength = glyphs.length; - const vertical = font.vertical; - const spacingDir = vertical ? 1 : -1; - const defaultVMetrics = font.defaultVMetrics; - const widthAdvanceScale = fontSize * current.fontMatrix[0]; - const simpleFillText = current.textRenderingMode === TextRenderingMode.FILL && !font.disableFontFace && !current.patternFill; - ctx.save(); - ctx.transform(...current.textMatrix); - ctx.translate(current.x, current.y + current.textRise); - if (fontDirection > 0) { - ctx.scale(textHScale, -1); - } else { - ctx.scale(textHScale, 1); - } - let patternTransform; - if (current.patternFill) { - ctx.save(); - const pattern = current.fillColor.getPattern(ctx, this, getCurrentTransformInverse(ctx), PathType.FILL); - patternTransform = getCurrentTransform(ctx); - ctx.restore(); - ctx.fillStyle = pattern; - } - let lineWidth = current.lineWidth; - const scale = current.textMatrixScale; - if (scale === 0 || lineWidth === 0) { - const fillStrokeMode = current.textRenderingMode & TextRenderingMode.FILL_STROKE_MASK; - if (fillStrokeMode === TextRenderingMode.STROKE || fillStrokeMode === TextRenderingMode.FILL_STROKE) { - lineWidth = this.getSinglePixelWidth(); - } - } else { - lineWidth /= scale; - } - if (fontSizeScale !== 1.0) { - ctx.scale(fontSizeScale, fontSizeScale); - lineWidth /= fontSizeScale; - } - ctx.lineWidth = lineWidth; - if (font.isInvalidPDFjsFont) { - const chars = []; - let width = 0; - for (const glyph of glyphs) { - chars.push(glyph.unicode); - width += glyph.width; - } - ctx.fillText(chars.join(""), 0, 0); - current.x += width * widthAdvanceScale * textHScale; - ctx.restore(); - this.compose(); - return undefined; - } - let x = 0, - i; - for (i = 0; i < glyphsLength; ++i) { - const glyph = glyphs[i]; - if (typeof glyph === "number") { - x += spacingDir * glyph * fontSize / 1000; - continue; - } - let restoreNeeded = false; - const spacing = (glyph.isSpace ? wordSpacing : 0) + charSpacing; - const character = glyph.fontChar; - const accent = glyph.accent; - let scaledX, scaledY; - let width = glyph.width; - if (vertical) { - const vmetric = glyph.vmetric || defaultVMetrics; - const vx = -(glyph.vmetric ? vmetric[1] : width * 0.5) * widthAdvanceScale; - const vy = vmetric[2] * widthAdvanceScale; - width = vmetric ? -vmetric[0] : width; - scaledX = vx / fontSizeScale; - scaledY = (x + vy) / fontSizeScale; - } else { - scaledX = x / fontSizeScale; - scaledY = 0; - } - if (font.remeasure && width > 0) { - const measuredWidth = ctx.measureText(character).width * 1000 / fontSize * fontSizeScale; - if (width < measuredWidth && this.isFontSubpixelAAEnabled) { - const characterScaleX = width / measuredWidth; - restoreNeeded = true; - ctx.save(); - ctx.scale(characterScaleX, 1); - scaledX /= characterScaleX; - } else if (width !== measuredWidth) { - scaledX += (width - measuredWidth) / 2000 * fontSize / fontSizeScale; - } - } - if (this.contentVisible && (glyph.isInFont || font.missingFile)) { - if (simpleFillText && !accent) { - ctx.fillText(character, scaledX, scaledY); - } else { - this.paintChar(character, scaledX, scaledY, patternTransform); - if (accent) { - const scaledAccentX = scaledX + fontSize * accent.offset.x / fontSizeScale; - const scaledAccentY = scaledY - fontSize * accent.offset.y / fontSizeScale; - this.paintChar(accent.fontChar, scaledAccentX, scaledAccentY, patternTransform); - } - } - } - const charWidth = vertical ? width * widthAdvanceScale - spacing * fontDirection : width * widthAdvanceScale + spacing * fontDirection; - x += charWidth; - if (restoreNeeded) { - ctx.restore(); - } - } - if (vertical) { - current.y -= x; - } else { - current.x += x * textHScale; - } - ctx.restore(); - this.compose(); - return undefined; - } - showType3Text(glyphs) { - const ctx = this.ctx; - const current = this.current; - const font = current.font; - const fontSize = current.fontSize; - const fontDirection = current.fontDirection; - const spacingDir = font.vertical ? 1 : -1; - const charSpacing = current.charSpacing; - const wordSpacing = current.wordSpacing; - const textHScale = current.textHScale * fontDirection; - const fontMatrix = current.fontMatrix || FONT_IDENTITY_MATRIX; - const glyphsLength = glyphs.length; - const isTextInvisible = current.textRenderingMode === TextRenderingMode.INVISIBLE; - let i, glyph, width, spacingLength; - if (isTextInvisible || fontSize === 0) { - return; - } - this._cachedScaleForStroking[0] = -1; - this._cachedGetSinglePixelWidth = null; - ctx.save(); - ctx.transform(...current.textMatrix); - ctx.translate(current.x, current.y); - ctx.scale(textHScale, fontDirection); - for (i = 0; i < glyphsLength; ++i) { - glyph = glyphs[i]; - if (typeof glyph === "number") { - spacingLength = spacingDir * glyph * fontSize / 1000; - this.ctx.translate(spacingLength, 0); - current.x += spacingLength * textHScale; - continue; - } - const spacing = (glyph.isSpace ? wordSpacing : 0) + charSpacing; - const operatorList = font.charProcOperatorList[glyph.operatorListId]; - if (!operatorList) { - warn(`Type3 character "${glyph.operatorListId}" is not available.`); - continue; - } - if (this.contentVisible) { - this.processingType3 = glyph; - this.save(); - ctx.scale(fontSize, fontSize); - ctx.transform(...fontMatrix); - this.executeOperatorList(operatorList); - this.restore(); - } - const transformed = Util.applyTransform([glyph.width, 0], fontMatrix); - width = transformed[0] * fontSize + spacing; - ctx.translate(width, 0); - current.x += width * textHScale; - } - ctx.restore(); - this.processingType3 = null; - } - setCharWidth(xWidth, yWidth) {} - setCharWidthAndBounds(xWidth, yWidth, llx, lly, urx, ury) { - this.ctx.rect(llx, lly, urx - llx, ury - lly); - this.ctx.clip(); - this.endPath(); - } - getColorN_Pattern(IR) { - let pattern; - if (IR[0] === "TilingPattern") { - const color = IR[1]; - const baseTransform = this.baseTransform || getCurrentTransform(this.ctx); - const canvasGraphicsFactory = { - createCanvasGraphics: ctx => new CanvasGraphics(ctx, this.commonObjs, this.objs, this.canvasFactory, this.filterFactory, { - optionalContentConfig: this.optionalContentConfig, - markedContentStack: this.markedContentStack - }) - }; - pattern = new TilingPattern(IR, color, this.ctx, canvasGraphicsFactory, baseTransform); - } else { - pattern = this._getPattern(IR[1], IR[2]); - } - return pattern; - } - setStrokeColorN() { - this.current.strokeColor = this.getColorN_Pattern(arguments); - } - setFillColorN() { - this.current.fillColor = this.getColorN_Pattern(arguments); - this.current.patternFill = true; - } - setStrokeRGBColor(r, g, b) { - const color = Util.makeHexColor(r, g, b); - this.ctx.strokeStyle = color; - this.current.strokeColor = color; - } - setFillRGBColor(r, g, b) { - const color = Util.makeHexColor(r, g, b); - this.ctx.fillStyle = color; - this.current.fillColor = color; - this.current.patternFill = false; - } - _getPattern(objId, matrix = null) { - let pattern; - if (this.cachedPatterns.has(objId)) { - pattern = this.cachedPatterns.get(objId); - } else { - pattern = getShadingPattern(this.getObject(objId)); - this.cachedPatterns.set(objId, pattern); - } - if (matrix) { - pattern.matrix = matrix; - } - return pattern; - } - shadingFill(objId) { - if (!this.contentVisible) { - return; - } - const ctx = this.ctx; - this.save(); - const pattern = this._getPattern(objId); - ctx.fillStyle = pattern.getPattern(ctx, this, getCurrentTransformInverse(ctx), PathType.SHADING); - const inv = getCurrentTransformInverse(ctx); - if (inv) { - const { - width, - height - } = ctx.canvas; - const [x0, y0, x1, y1] = Util.getAxialAlignedBoundingBox([0, 0, width, height], inv); - this.ctx.fillRect(x0, y0, x1 - x0, y1 - y0); - } else { - this.ctx.fillRect(-1e10, -1e10, 2e10, 2e10); - } - this.compose(this.current.getClippedPathBoundingBox()); - this.restore(); - } - beginInlineImage() { - unreachable("Should not call beginInlineImage"); - } - beginImageData() { - unreachable("Should not call beginImageData"); - } - paintFormXObjectBegin(matrix, bbox) { - if (!this.contentVisible) { - return; - } - this.save(); - this.baseTransformStack.push(this.baseTransform); - if (matrix) { - this.transform(...matrix); - } - this.baseTransform = getCurrentTransform(this.ctx); - if (bbox) { - const width = bbox[2] - bbox[0]; - const height = bbox[3] - bbox[1]; - this.ctx.rect(bbox[0], bbox[1], width, height); - this.current.updateRectMinMax(getCurrentTransform(this.ctx), bbox); - this.clip(); - this.endPath(); - } - } - paintFormXObjectEnd() { - if (!this.contentVisible) { - return; - } - this.restore(); - this.baseTransform = this.baseTransformStack.pop(); - } - beginGroup(group) { - if (!this.contentVisible) { - return; - } - this.save(); - if (this.inSMaskMode) { - this.endSMaskMode(); - this.current.activeSMask = null; - } - const currentCtx = this.ctx; - if (!group.isolated) { - info("TODO: Support non-isolated groups."); - } - if (group.knockout) { - warn("Knockout groups not supported."); - } - const currentTransform = getCurrentTransform(currentCtx); - if (group.matrix) { - currentCtx.transform(...group.matrix); - } - if (!group.bbox) { - throw new Error("Bounding box is required."); - } - let bounds = Util.getAxialAlignedBoundingBox(group.bbox, getCurrentTransform(currentCtx)); - const canvasBounds = [0, 0, currentCtx.canvas.width, currentCtx.canvas.height]; - bounds = Util.intersect(bounds, canvasBounds) || [0, 0, 0, 0]; - const offsetX = Math.floor(bounds[0]); - const offsetY = Math.floor(bounds[1]); - const drawnWidth = Math.max(Math.ceil(bounds[2]) - offsetX, 1); - const drawnHeight = Math.max(Math.ceil(bounds[3]) - offsetY, 1); - this.current.startNewPathAndClipBox([0, 0, drawnWidth, drawnHeight]); - let cacheId = "groupAt" + this.groupLevel; - if (group.smask) { - cacheId += "_smask_" + this.smaskCounter++ % 2; - } - const scratchCanvas = this.cachedCanvases.getCanvas(cacheId, drawnWidth, drawnHeight); - const groupCtx = scratchCanvas.context; - groupCtx.translate(-offsetX, -offsetY); - groupCtx.transform(...currentTransform); - if (group.smask) { - this.smaskStack.push({ - canvas: scratchCanvas.canvas, - context: groupCtx, - offsetX, - offsetY, - subtype: group.smask.subtype, - backdrop: group.smask.backdrop, - transferMap: group.smask.transferMap || null, - startTransformInverse: null - }); - } else { - currentCtx.setTransform(1, 0, 0, 1, 0, 0); - currentCtx.translate(offsetX, offsetY); - currentCtx.save(); - } - copyCtxState(currentCtx, groupCtx); - this.ctx = groupCtx; - this.setGState([["BM", "source-over"], ["ca", 1], ["CA", 1]]); - this.groupStack.push(currentCtx); - this.groupLevel++; - } - endGroup(group) { - if (!this.contentVisible) { - return; - } - this.groupLevel--; - const groupCtx = this.ctx; - const ctx = this.groupStack.pop(); - this.ctx = ctx; - this.ctx.imageSmoothingEnabled = false; - if (group.smask) { - this.tempSMask = this.smaskStack.pop(); - this.restore(); - } else { - this.ctx.restore(); - const currentMtx = getCurrentTransform(this.ctx); - this.restore(); - this.ctx.save(); - this.ctx.setTransform(...currentMtx); - const dirtyBox = Util.getAxialAlignedBoundingBox([0, 0, groupCtx.canvas.width, groupCtx.canvas.height], currentMtx); - this.ctx.drawImage(groupCtx.canvas, 0, 0); - this.ctx.restore(); - this.compose(dirtyBox); - } - } - beginAnnotation(id, rect, transform, matrix, hasOwnCanvas) { - this.#restoreInitialState(); - resetCtxToDefault(this.ctx); - this.ctx.save(); - this.save(); - if (this.baseTransform) { - this.ctx.setTransform(...this.baseTransform); - } - if (rect) { - const width = rect[2] - rect[0]; - const height = rect[3] - rect[1]; - if (hasOwnCanvas && this.annotationCanvasMap) { - transform = transform.slice(); - transform[4] -= rect[0]; - transform[5] -= rect[1]; - rect = rect.slice(); - rect[0] = rect[1] = 0; - rect[2] = width; - rect[3] = height; - const [scaleX, scaleY] = Util.singularValueDecompose2dScale(getCurrentTransform(this.ctx)); - const { - viewportScale - } = this; - const canvasWidth = Math.ceil(width * this.outputScaleX * viewportScale); - const canvasHeight = Math.ceil(height * this.outputScaleY * viewportScale); - this.annotationCanvas = this.canvasFactory.create(canvasWidth, canvasHeight); - const { - canvas, - context - } = this.annotationCanvas; - this.annotationCanvasMap.set(id, canvas); - this.annotationCanvas.savedCtx = this.ctx; - this.ctx = context; - this.ctx.save(); - this.ctx.setTransform(scaleX, 0, 0, -scaleY, 0, height * scaleY); - resetCtxToDefault(this.ctx); - } else { - resetCtxToDefault(this.ctx); - this.ctx.rect(rect[0], rect[1], width, height); - this.ctx.clip(); - this.endPath(); - } - } - this.current = new CanvasExtraState(this.ctx.canvas.width, this.ctx.canvas.height); - this.transform(...transform); - this.transform(...matrix); - } - endAnnotation() { - if (this.annotationCanvas) { - this.ctx.restore(); - this.#drawFilter(); - this.ctx = this.annotationCanvas.savedCtx; - delete this.annotationCanvas.savedCtx; - delete this.annotationCanvas; - } - } - paintImageMaskXObject(img) { - if (!this.contentVisible) { - return; - } - const count = img.count; - img = this.getObject(img.data, img); - img.count = count; - const ctx = this.ctx; - const glyph = this.processingType3; - if (glyph) { - if (glyph.compiled === undefined) { - glyph.compiled = compileType3Glyph(img); - } - if (glyph.compiled) { - glyph.compiled(ctx); - return; - } - } - const mask = this._createMaskCanvas(img); - const maskCanvas = mask.canvas; - ctx.save(); - ctx.setTransform(1, 0, 0, 1, 0, 0); - ctx.drawImage(maskCanvas, mask.offsetX, mask.offsetY); - ctx.restore(); - this.compose(); - } - paintImageMaskXObjectRepeat(img, scaleX, skewX = 0, skewY = 0, scaleY, positions) { - if (!this.contentVisible) { - return; - } - img = this.getObject(img.data, img); - const ctx = this.ctx; - ctx.save(); - const currentTransform = getCurrentTransform(ctx); - ctx.transform(scaleX, skewX, skewY, scaleY, 0, 0); - const mask = this._createMaskCanvas(img); - ctx.setTransform(1, 0, 0, 1, mask.offsetX - currentTransform[4], mask.offsetY - currentTransform[5]); - for (let i = 0, ii = positions.length; i < ii; i += 2) { - const trans = Util.transform(currentTransform, [scaleX, skewX, skewY, scaleY, positions[i], positions[i + 1]]); - const [x, y] = Util.applyTransform([0, 0], trans); - ctx.drawImage(mask.canvas, x, y); - } - ctx.restore(); - this.compose(); - } - paintImageMaskXObjectGroup(images) { - if (!this.contentVisible) { - return; - } - const ctx = this.ctx; - const fillColor = this.current.fillColor; - const isPatternFill = this.current.patternFill; - for (const image of images) { - const { - data, - width, - height, - transform - } = image; - const maskCanvas = this.cachedCanvases.getCanvas("maskCanvas", width, height); - const maskCtx = maskCanvas.context; - maskCtx.save(); - const img = this.getObject(data, image); - putBinaryImageMask(maskCtx, img); - maskCtx.globalCompositeOperation = "source-in"; - maskCtx.fillStyle = isPatternFill ? fillColor.getPattern(maskCtx, this, getCurrentTransformInverse(ctx), PathType.FILL) : fillColor; - maskCtx.fillRect(0, 0, width, height); - maskCtx.restore(); - ctx.save(); - ctx.transform(...transform); - ctx.scale(1, -1); - drawImageAtIntegerCoords(ctx, maskCanvas.canvas, 0, 0, width, height, 0, -1, 1, 1); - ctx.restore(); - } - this.compose(); - } - paintImageXObject(objId) { - if (!this.contentVisible) { - return; - } - const imgData = this.getObject(objId); - if (!imgData) { - warn("Dependent image isn't ready yet"); - return; - } - this.paintInlineImageXObject(imgData); - } - paintImageXObjectRepeat(objId, scaleX, scaleY, positions) { - if (!this.contentVisible) { - return; - } - const imgData = this.getObject(objId); - if (!imgData) { - warn("Dependent image isn't ready yet"); - return; - } - const width = imgData.width; - const height = imgData.height; - const map = []; - for (let i = 0, ii = positions.length; i < ii; i += 2) { - map.push({ - transform: [scaleX, 0, 0, scaleY, positions[i], positions[i + 1]], - x: 0, - y: 0, - w: width, - h: height - }); - } - this.paintInlineImageXObjectGroup(imgData, map); - } - applyTransferMapsToCanvas(ctx) { - if (this.current.transferMaps !== "none") { - ctx.filter = this.current.transferMaps; - ctx.drawImage(ctx.canvas, 0, 0); - ctx.filter = "none"; - } - return ctx.canvas; - } - applyTransferMapsToBitmap(imgData) { - if (this.current.transferMaps === "none") { - return imgData.bitmap; - } - const { - bitmap, - width, - height - } = imgData; - const tmpCanvas = this.cachedCanvases.getCanvas("inlineImage", width, height); - const tmpCtx = tmpCanvas.context; - tmpCtx.filter = this.current.transferMaps; - tmpCtx.drawImage(bitmap, 0, 0); - tmpCtx.filter = "none"; - return tmpCanvas.canvas; - } - paintInlineImageXObject(imgData) { - if (!this.contentVisible) { - return; - } - const width = imgData.width; - const height = imgData.height; - const ctx = this.ctx; - this.save(); - if (!isNodeJS) { - const { - filter - } = ctx; - if (filter !== "none" && filter !== "") { - ctx.filter = "none"; - } - } - ctx.scale(1 / width, -1 / height); - let imgToPaint; - if (imgData.bitmap) { - imgToPaint = this.applyTransferMapsToBitmap(imgData); - } else if (typeof HTMLElement === "function" && imgData instanceof HTMLElement || !imgData.data) { - imgToPaint = imgData; - } else { - const tmpCanvas = this.cachedCanvases.getCanvas("inlineImage", width, height); - const tmpCtx = tmpCanvas.context; - putBinaryImageData(tmpCtx, imgData); - imgToPaint = this.applyTransferMapsToCanvas(tmpCtx); - } - const scaled = this._scaleImage(imgToPaint, getCurrentTransformInverse(ctx)); - ctx.imageSmoothingEnabled = getImageSmoothingEnabled(getCurrentTransform(ctx), imgData.interpolate); - drawImageAtIntegerCoords(ctx, scaled.img, 0, 0, scaled.paintWidth, scaled.paintHeight, 0, -height, width, height); - this.compose(); - this.restore(); - } - paintInlineImageXObjectGroup(imgData, map) { - if (!this.contentVisible) { - return; - } - const ctx = this.ctx; - let imgToPaint; - if (imgData.bitmap) { - imgToPaint = imgData.bitmap; - } else { - const w = imgData.width; - const h = imgData.height; - const tmpCanvas = this.cachedCanvases.getCanvas("inlineImage", w, h); - const tmpCtx = tmpCanvas.context; - putBinaryImageData(tmpCtx, imgData); - imgToPaint = this.applyTransferMapsToCanvas(tmpCtx); - } - for (const entry of map) { - ctx.save(); - ctx.transform(...entry.transform); - ctx.scale(1, -1); - drawImageAtIntegerCoords(ctx, imgToPaint, entry.x, entry.y, entry.w, entry.h, 0, -1, 1, 1); - ctx.restore(); - } - this.compose(); - } - paintSolidColorImageMask() { - if (!this.contentVisible) { - return; - } - this.ctx.fillRect(0, 0, 1, 1); - this.compose(); - } - markPoint(tag) {} - markPointProps(tag, properties) {} - beginMarkedContent(tag) { - this.markedContentStack.push({ - visible: true - }); - } - beginMarkedContentProps(tag, properties) { - if (tag === "OC") { - this.markedContentStack.push({ - visible: this.optionalContentConfig.isVisible(properties) - }); - } else { - this.markedContentStack.push({ - visible: true - }); - } - this.contentVisible = this.isContentVisible(); - } - endMarkedContent() { - this.markedContentStack.pop(); - this.contentVisible = this.isContentVisible(); - } - beginCompat() {} - endCompat() {} - consumePath(clipBox) { - const isEmpty = this.current.isEmptyClip(); - if (this.pendingClip) { - this.current.updateClipFromPath(); - } - if (!this.pendingClip) { - this.compose(clipBox); - } - const ctx = this.ctx; - if (this.pendingClip) { - if (!isEmpty) { - if (this.pendingClip === EO_CLIP) { - ctx.clip("evenodd"); - } else { - ctx.clip(); - } - } - this.pendingClip = null; - } - this.current.startNewPathAndClipBox(this.current.clipBox); - ctx.beginPath(); - } - getSinglePixelWidth() { - if (!this._cachedGetSinglePixelWidth) { - const m = getCurrentTransform(this.ctx); - if (m[1] === 0 && m[2] === 0) { - this._cachedGetSinglePixelWidth = 1 / Math.min(Math.abs(m[0]), Math.abs(m[3])); - } else { - const absDet = Math.abs(m[0] * m[3] - m[2] * m[1]); - const normX = Math.hypot(m[0], m[2]); - const normY = Math.hypot(m[1], m[3]); - this._cachedGetSinglePixelWidth = Math.max(normX, normY) / absDet; - } - } - return this._cachedGetSinglePixelWidth; - } - getScaleForStroking() { - if (this._cachedScaleForStroking[0] === -1) { - const { - lineWidth - } = this.current; - const { - a, - b, - c, - d - } = this.ctx.getTransform(); - let scaleX, scaleY; - if (b === 0 && c === 0) { - const normX = Math.abs(a); - const normY = Math.abs(d); - if (normX === normY) { - if (lineWidth === 0) { - scaleX = scaleY = 1 / normX; - } else { - const scaledLineWidth = normX * lineWidth; - scaleX = scaleY = scaledLineWidth < 1 ? 1 / scaledLineWidth : 1; - } - } else if (lineWidth === 0) { - scaleX = 1 / normX; - scaleY = 1 / normY; - } else { - const scaledXLineWidth = normX * lineWidth; - const scaledYLineWidth = normY * lineWidth; - scaleX = scaledXLineWidth < 1 ? 1 / scaledXLineWidth : 1; - scaleY = scaledYLineWidth < 1 ? 1 / scaledYLineWidth : 1; - } - } else { - const absDet = Math.abs(a * d - b * c); - const normX = Math.hypot(a, b); - const normY = Math.hypot(c, d); - if (lineWidth === 0) { - scaleX = normY / absDet; - scaleY = normX / absDet; - } else { - const baseArea = lineWidth * absDet; - scaleX = normY > baseArea ? normY / baseArea : 1; - scaleY = normX > baseArea ? normX / baseArea : 1; - } - } - this._cachedScaleForStroking[0] = scaleX; - this._cachedScaleForStroking[1] = scaleY; - } - return this._cachedScaleForStroking; - } - rescaleAndStroke(saveRestore) { - const { - ctx - } = this; - const { - lineWidth - } = this.current; - const [scaleX, scaleY] = this.getScaleForStroking(); - ctx.lineWidth = lineWidth || 1; - if (scaleX === 1 && scaleY === 1) { - ctx.stroke(); - return; - } - const dashes = ctx.getLineDash(); - if (saveRestore) { - ctx.save(); - } - ctx.scale(scaleX, scaleY); - if (dashes.length > 0) { - const scale = Math.max(scaleX, scaleY); - ctx.setLineDash(dashes.map(x => x / scale)); - ctx.lineDashOffset /= scale; - } - ctx.stroke(); - if (saveRestore) { - ctx.restore(); - } - } - isContentVisible() { - for (let i = this.markedContentStack.length - 1; i >= 0; i--) { - if (!this.markedContentStack[i].visible) { - return false; - } - } - return true; - } -} -for (const op in OPS) { - if (CanvasGraphics.prototype[op] !== undefined) { - CanvasGraphics.prototype[OPS[op]] = CanvasGraphics.prototype[op]; - } -} - -;// CONCATENATED MODULE: ./src/display/worker_options.js -class GlobalWorkerOptions { - static #port = null; - static #src = ""; - static get workerPort() { - return this.#port; - } - static set workerPort(val) { - if (!(typeof Worker !== "undefined" && val instanceof Worker) && val !== null) { - throw new Error("Invalid `workerPort` type."); - } - this.#port = val; - } - static get workerSrc() { - return this.#src; - } - static set workerSrc(val) { - if (typeof val !== "string") { - throw new Error("Invalid `workerSrc` type."); - } - this.#src = val; - } -} - -;// CONCATENATED MODULE: ./src/shared/message_handler.js - - -const CallbackKind = { - UNKNOWN: 0, - DATA: 1, - ERROR: 2 -}; -const StreamKind = { - UNKNOWN: 0, - CANCEL: 1, - CANCEL_COMPLETE: 2, - CLOSE: 3, - ENQUEUE: 4, - ERROR: 5, - PULL: 6, - PULL_COMPLETE: 7, - START_COMPLETE: 8 -}; -function wrapReason(reason) { - if (!(reason instanceof Error || typeof reason === "object" && reason !== null)) { - unreachable('wrapReason: Expected "reason" to be a (possibly cloned) Error.'); - } - switch (reason.name) { - case "AbortException": - return new AbortException(reason.message); - case "MissingPDFException": - return new MissingPDFException(reason.message); - case "PasswordException": - return new PasswordException(reason.message, reason.code); - case "UnexpectedResponseException": - return new UnexpectedResponseException(reason.message, reason.status); - case "UnknownErrorException": - return new UnknownErrorException(reason.message, reason.details); - default: - return new UnknownErrorException(reason.message, reason.toString()); - } -} -class MessageHandler { - constructor(sourceName, targetName, comObj) { - this.sourceName = sourceName; - this.targetName = targetName; - this.comObj = comObj; - this.callbackId = 1; - this.streamId = 1; - this.streamSinks = Object.create(null); - this.streamControllers = Object.create(null); - this.callbackCapabilities = Object.create(null); - this.actionHandler = Object.create(null); - this._onComObjOnMessage = event => { - const data = event.data; - if (data.targetName !== this.sourceName) { - return; - } - if (data.stream) { - this.#processStreamMessage(data); - return; - } - if (data.callback) { - const callbackId = data.callbackId; - const capability = this.callbackCapabilities[callbackId]; - if (!capability) { - throw new Error(`Cannot resolve callback ${callbackId}`); - } - delete this.callbackCapabilities[callbackId]; - if (data.callback === CallbackKind.DATA) { - capability.resolve(data.data); - } else if (data.callback === CallbackKind.ERROR) { - capability.reject(wrapReason(data.reason)); - } else { - throw new Error("Unexpected callback case"); - } - return; - } - const action = this.actionHandler[data.action]; - if (!action) { - throw new Error(`Unknown action from worker: ${data.action}`); - } - if (data.callbackId) { - const cbSourceName = this.sourceName; - const cbTargetName = data.sourceName; - new Promise(function (resolve) { - resolve(action(data.data)); - }).then(function (result) { - comObj.postMessage({ - sourceName: cbSourceName, - targetName: cbTargetName, - callback: CallbackKind.DATA, - callbackId: data.callbackId, - data: result - }); - }, function (reason) { - comObj.postMessage({ - sourceName: cbSourceName, - targetName: cbTargetName, - callback: CallbackKind.ERROR, - callbackId: data.callbackId, - reason: wrapReason(reason) - }); - }); - return; - } - if (data.streamId) { - this.#createStreamSink(data); - return; - } - action(data.data); - }; - comObj.addEventListener("message", this._onComObjOnMessage); - } - on(actionName, handler) { - const ah = this.actionHandler; - if (ah[actionName]) { - throw new Error(`There is already an actionName called "${actionName}"`); - } - ah[actionName] = handler; - } - send(actionName, data, transfers) { - this.comObj.postMessage({ - sourceName: this.sourceName, - targetName: this.targetName, - action: actionName, - data - }, transfers); - } - sendWithPromise(actionName, data, transfers) { - const callbackId = this.callbackId++; - const capability = Promise.withResolvers(); - this.callbackCapabilities[callbackId] = capability; - try { - this.comObj.postMessage({ - sourceName: this.sourceName, - targetName: this.targetName, - action: actionName, - callbackId, - data - }, transfers); - } catch (ex) { - capability.reject(ex); - } - return capability.promise; - } - sendWithStream(actionName, data, queueingStrategy, transfers) { - const streamId = this.streamId++, - sourceName = this.sourceName, - targetName = this.targetName, - comObj = this.comObj; - return new ReadableStream({ - start: controller => { - const startCapability = Promise.withResolvers(); - this.streamControllers[streamId] = { - controller, - startCall: startCapability, - pullCall: null, - cancelCall: null, - isClosed: false - }; - comObj.postMessage({ - sourceName, - targetName, - action: actionName, - streamId, - data, - desiredSize: controller.desiredSize - }, transfers); - return startCapability.promise; - }, - pull: controller => { - const pullCapability = Promise.withResolvers(); - this.streamControllers[streamId].pullCall = pullCapability; - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.PULL, - streamId, - desiredSize: controller.desiredSize - }); - return pullCapability.promise; - }, - cancel: reason => { - assert(reason instanceof Error, "cancel must have a valid reason"); - const cancelCapability = Promise.withResolvers(); - this.streamControllers[streamId].cancelCall = cancelCapability; - this.streamControllers[streamId].isClosed = true; - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.CANCEL, - streamId, - reason: wrapReason(reason) - }); - return cancelCapability.promise; - } - }, queueingStrategy); - } - #createStreamSink(data) { - const streamId = data.streamId, - sourceName = this.sourceName, - targetName = data.sourceName, - comObj = this.comObj; - const self = this, - action = this.actionHandler[data.action]; - const streamSink = { - enqueue(chunk, size = 1, transfers) { - if (this.isCancelled) { - return; - } - const lastDesiredSize = this.desiredSize; - this.desiredSize -= size; - if (lastDesiredSize > 0 && this.desiredSize <= 0) { - this.sinkCapability = Promise.withResolvers(); - this.ready = this.sinkCapability.promise; - } - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.ENQUEUE, - streamId, - chunk - }, transfers); - }, - close() { - if (this.isCancelled) { - return; - } - this.isCancelled = true; - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.CLOSE, - streamId - }); - delete self.streamSinks[streamId]; - }, - error(reason) { - assert(reason instanceof Error, "error must have a valid reason"); - if (this.isCancelled) { - return; - } - this.isCancelled = true; - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.ERROR, - streamId, - reason: wrapReason(reason) - }); - }, - sinkCapability: Promise.withResolvers(), - onPull: null, - onCancel: null, - isCancelled: false, - desiredSize: data.desiredSize, - ready: null - }; - streamSink.sinkCapability.resolve(); - streamSink.ready = streamSink.sinkCapability.promise; - this.streamSinks[streamId] = streamSink; - new Promise(function (resolve) { - resolve(action(data.data, streamSink)); - }).then(function () { - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.START_COMPLETE, - streamId, - success: true - }); - }, function (reason) { - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.START_COMPLETE, - streamId, - reason: wrapReason(reason) - }); - }); - } - #processStreamMessage(data) { - const streamId = data.streamId, - sourceName = this.sourceName, - targetName = data.sourceName, - comObj = this.comObj; - const streamController = this.streamControllers[streamId], - streamSink = this.streamSinks[streamId]; - switch (data.stream) { - case StreamKind.START_COMPLETE: - if (data.success) { - streamController.startCall.resolve(); - } else { - streamController.startCall.reject(wrapReason(data.reason)); - } - break; - case StreamKind.PULL_COMPLETE: - if (data.success) { - streamController.pullCall.resolve(); - } else { - streamController.pullCall.reject(wrapReason(data.reason)); - } - break; - case StreamKind.PULL: - if (!streamSink) { - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.PULL_COMPLETE, - streamId, - success: true - }); - break; - } - if (streamSink.desiredSize <= 0 && data.desiredSize > 0) { - streamSink.sinkCapability.resolve(); - } - streamSink.desiredSize = data.desiredSize; - new Promise(function (resolve) { - resolve(streamSink.onPull?.()); - }).then(function () { - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.PULL_COMPLETE, - streamId, - success: true - }); - }, function (reason) { - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.PULL_COMPLETE, - streamId, - reason: wrapReason(reason) - }); - }); - break; - case StreamKind.ENQUEUE: - assert(streamController, "enqueue should have stream controller"); - if (streamController.isClosed) { - break; - } - streamController.controller.enqueue(data.chunk); - break; - case StreamKind.CLOSE: - assert(streamController, "close should have stream controller"); - if (streamController.isClosed) { - break; - } - streamController.isClosed = true; - streamController.controller.close(); - this.#deleteStreamController(streamController, streamId); - break; - case StreamKind.ERROR: - assert(streamController, "error should have stream controller"); - streamController.controller.error(wrapReason(data.reason)); - this.#deleteStreamController(streamController, streamId); - break; - case StreamKind.CANCEL_COMPLETE: - if (data.success) { - streamController.cancelCall.resolve(); - } else { - streamController.cancelCall.reject(wrapReason(data.reason)); - } - this.#deleteStreamController(streamController, streamId); - break; - case StreamKind.CANCEL: - if (!streamSink) { - break; - } - new Promise(function (resolve) { - resolve(streamSink.onCancel?.(wrapReason(data.reason))); - }).then(function () { - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.CANCEL_COMPLETE, - streamId, - success: true - }); - }, function (reason) { - comObj.postMessage({ - sourceName, - targetName, - stream: StreamKind.CANCEL_COMPLETE, - streamId, - reason: wrapReason(reason) - }); - }); - streamSink.sinkCapability.reject(wrapReason(data.reason)); - streamSink.isCancelled = true; - delete this.streamSinks[streamId]; - break; - default: - throw new Error("Unexpected stream case"); - } - } - async #deleteStreamController(streamController, streamId) { - await Promise.allSettled([streamController.startCall?.promise, streamController.pullCall?.promise, streamController.cancelCall?.promise]); - delete this.streamControllers[streamId]; - } - destroy() { - this.comObj.removeEventListener("message", this._onComObjOnMessage); - } -} - -;// CONCATENATED MODULE: ./src/display/metadata.js - -class Metadata { - #metadataMap; - #data; - constructor({ - parsedData, - rawData - }) { - this.#metadataMap = parsedData; - this.#data = rawData; - } - getRaw() { - return this.#data; - } - get(name) { - return this.#metadataMap.get(name) ?? null; - } - getAll() { - return objectFromMap(this.#metadataMap); - } - has(name) { - return this.#metadataMap.has(name); - } -} - -;// CONCATENATED MODULE: ./src/display/optional_content_config.js - - -const INTERNAL = Symbol("INTERNAL"); -class OptionalContentGroup { - #isDisplay = false; - #isPrint = false; - #userSet = false; - #visible = true; - constructor(renderingIntent, { - name, - intent, - usage - }) { - this.#isDisplay = !!(renderingIntent & RenderingIntentFlag.DISPLAY); - this.#isPrint = !!(renderingIntent & RenderingIntentFlag.PRINT); - this.name = name; - this.intent = intent; - this.usage = usage; - } - get visible() { - if (this.#userSet) { - return this.#visible; - } - if (!this.#visible) { - return false; - } - const { - print, - view - } = this.usage; - if (this.#isDisplay) { - return view?.viewState !== "OFF"; - } else if (this.#isPrint) { - return print?.printState !== "OFF"; - } - return true; - } - _setVisible(internal, visible, userSet = false) { - if (internal !== INTERNAL) { - unreachable("Internal method `_setVisible` called."); - } - this.#userSet = userSet; - this.#visible = visible; - } -} -class OptionalContentConfig { - #cachedGetHash = null; - #groups = new Map(); - #initialHash = null; - #order = null; - constructor(data, renderingIntent = RenderingIntentFlag.DISPLAY) { - this.renderingIntent = renderingIntent; - this.name = null; - this.creator = null; - if (data === null) { - return; - } - this.name = data.name; - this.creator = data.creator; - this.#order = data.order; - for (const group of data.groups) { - this.#groups.set(group.id, new OptionalContentGroup(renderingIntent, group)); - } - if (data.baseState === "OFF") { - for (const group of this.#groups.values()) { - group._setVisible(INTERNAL, false); - } - } - for (const on of data.on) { - this.#groups.get(on)._setVisible(INTERNAL, true); - } - for (const off of data.off) { - this.#groups.get(off)._setVisible(INTERNAL, false); - } - this.#initialHash = this.getHash(); - } - #evaluateVisibilityExpression(array) { - const length = array.length; - if (length < 2) { - return true; - } - const operator = array[0]; - for (let i = 1; i < length; i++) { - const element = array[i]; - let state; - if (Array.isArray(element)) { - state = this.#evaluateVisibilityExpression(element); - } else if (this.#groups.has(element)) { - state = this.#groups.get(element).visible; - } else { - warn(`Optional content group not found: ${element}`); - return true; - } - switch (operator) { - case "And": - if (!state) { - return false; - } - break; - case "Or": - if (state) { - return true; - } - break; - case "Not": - return !state; - default: - return true; - } - } - return operator === "And"; - } - isVisible(group) { - if (this.#groups.size === 0) { - return true; - } - if (!group) { - info("Optional content group not defined."); - return true; - } - if (group.type === "OCG") { - if (!this.#groups.has(group.id)) { - warn(`Optional content group not found: ${group.id}`); - return true; - } - return this.#groups.get(group.id).visible; - } else if (group.type === "OCMD") { - if (group.expression) { - return this.#evaluateVisibilityExpression(group.expression); - } - if (!group.policy || group.policy === "AnyOn") { - for (const id of group.ids) { - if (!this.#groups.has(id)) { - warn(`Optional content group not found: ${id}`); - return true; - } - if (this.#groups.get(id).visible) { - return true; - } - } - return false; - } else if (group.policy === "AllOn") { - for (const id of group.ids) { - if (!this.#groups.has(id)) { - warn(`Optional content group not found: ${id}`); - return true; - } - if (!this.#groups.get(id).visible) { - return false; - } - } - return true; - } else if (group.policy === "AnyOff") { - for (const id of group.ids) { - if (!this.#groups.has(id)) { - warn(`Optional content group not found: ${id}`); - return true; - } - if (!this.#groups.get(id).visible) { - return true; - } - } - return false; - } else if (group.policy === "AllOff") { - for (const id of group.ids) { - if (!this.#groups.has(id)) { - warn(`Optional content group not found: ${id}`); - return true; - } - if (this.#groups.get(id).visible) { - return false; - } - } - return true; - } - warn(`Unknown optional content policy ${group.policy}.`); - return true; - } - warn(`Unknown group type ${group.type}.`); - return true; - } - setVisibility(id, visible = true) { - const group = this.#groups.get(id); - if (!group) { - warn(`Optional content group not found: ${id}`); - return; - } - group._setVisible(INTERNAL, !!visible, true); - this.#cachedGetHash = null; - } - setOCGState({ - state, - preserveRB - }) { - let operator; - for (const elem of state) { - switch (elem) { - case "ON": - case "OFF": - case "Toggle": - operator = elem; - continue; - } - const group = this.#groups.get(elem); - if (!group) { - continue; - } - switch (operator) { - case "ON": - group._setVisible(INTERNAL, true); - break; - case "OFF": - group._setVisible(INTERNAL, false); - break; - case "Toggle": - group._setVisible(INTERNAL, !group.visible); - break; - } - } - this.#cachedGetHash = null; - } - get hasInitialVisibility() { - return this.#initialHash === null || this.getHash() === this.#initialHash; - } - getOrder() { - if (!this.#groups.size) { - return null; - } - if (this.#order) { - return this.#order.slice(); - } - return [...this.#groups.keys()]; - } - getGroups() { - return this.#groups.size > 0 ? objectFromMap(this.#groups) : null; - } - getGroup(id) { - return this.#groups.get(id) || null; - } - getHash() { - if (this.#cachedGetHash !== null) { - return this.#cachedGetHash; - } - const hash = new MurmurHash3_64(); - for (const [id, group] of this.#groups) { - hash.update(`${id}:${group.visible}`); - } - return this.#cachedGetHash = hash.hexdigest(); - } -} - -;// CONCATENATED MODULE: ./src/display/transport_stream.js - - - - - - - - - - - - -class PDFDataTransportStream { - constructor(pdfDataRangeTransport, { - disableRange = false, - disableStream = false - }) { - assert(pdfDataRangeTransport, 'PDFDataTransportStream - missing required "pdfDataRangeTransport" argument.'); - const { - length, - initialData, - progressiveDone, - contentDispositionFilename - } = pdfDataRangeTransport; - this._queuedChunks = []; - this._progressiveDone = progressiveDone; - this._contentDispositionFilename = contentDispositionFilename; - if (initialData?.length > 0) { - const buffer = initialData instanceof Uint8Array && initialData.byteLength === initialData.buffer.byteLength ? initialData.buffer : new Uint8Array(initialData).buffer; - this._queuedChunks.push(buffer); - } - this._pdfDataRangeTransport = pdfDataRangeTransport; - this._isStreamingSupported = !disableStream; - this._isRangeSupported = !disableRange; - this._contentLength = length; - this._fullRequestReader = null; - this._rangeReaders = []; - pdfDataRangeTransport.addRangeListener((begin, chunk) => { - this._onReceiveData({ - begin, - chunk - }); - }); - pdfDataRangeTransport.addProgressListener((loaded, total) => { - this._onProgress({ - loaded, - total - }); - }); - pdfDataRangeTransport.addProgressiveReadListener(chunk => { - this._onReceiveData({ - chunk - }); - }); - pdfDataRangeTransport.addProgressiveDoneListener(() => { - this._onProgressiveDone(); - }); - pdfDataRangeTransport.transportReady(); - } - _onReceiveData({ - begin, - chunk - }) { - const buffer = chunk instanceof Uint8Array && chunk.byteLength === chunk.buffer.byteLength ? chunk.buffer : new Uint8Array(chunk).buffer; - if (begin === undefined) { - if (this._fullRequestReader) { - this._fullRequestReader._enqueue(buffer); - } else { - this._queuedChunks.push(buffer); - } - } else { - const found = this._rangeReaders.some(function (rangeReader) { - if (rangeReader._begin !== begin) { - return false; - } - rangeReader._enqueue(buffer); - return true; - }); - assert(found, "_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found."); - } - } - get _progressiveDataLength() { - return this._fullRequestReader?._loaded ?? 0; - } - _onProgress(evt) { - if (evt.total === undefined) { - this._rangeReaders[0]?.onProgress?.({ - loaded: evt.loaded - }); - } else { - this._fullRequestReader?.onProgress?.({ - loaded: evt.loaded, - total: evt.total - }); - } - } - _onProgressiveDone() { - this._fullRequestReader?.progressiveDone(); - this._progressiveDone = true; - } - _removeRangeReader(reader) { - const i = this._rangeReaders.indexOf(reader); - if (i >= 0) { - this._rangeReaders.splice(i, 1); - } - } - getFullReader() { - assert(!this._fullRequestReader, "PDFDataTransportStream.getFullReader can only be called once."); - const queuedChunks = this._queuedChunks; - this._queuedChunks = null; - return new PDFDataTransportStreamReader(this, queuedChunks, this._progressiveDone, this._contentDispositionFilename); - } - getRangeReader(begin, end) { - if (end <= this._progressiveDataLength) { - return null; - } - const reader = new PDFDataTransportStreamRangeReader(this, begin, end); - this._pdfDataRangeTransport.requestDataRange(begin, end); - this._rangeReaders.push(reader); - return reader; - } - cancelAllRequests(reason) { - this._fullRequestReader?.cancel(reason); - for (const reader of this._rangeReaders.slice(0)) { - reader.cancel(reason); - } - this._pdfDataRangeTransport.abort(); - } -} -class PDFDataTransportStreamReader { - constructor(stream, queuedChunks, progressiveDone = false, contentDispositionFilename = null) { - this._stream = stream; - this._done = progressiveDone || false; - this._filename = isPdfFile(contentDispositionFilename) ? contentDispositionFilename : null; - this._queuedChunks = queuedChunks || []; - this._loaded = 0; - for (const chunk of this._queuedChunks) { - this._loaded += chunk.byteLength; - } - this._requests = []; - this._headersReady = Promise.resolve(); - stream._fullRequestReader = this; - this.onProgress = null; - } - _enqueue(chunk) { - if (this._done) { - return; - } - if (this._requests.length > 0) { - const requestCapability = this._requests.shift(); - requestCapability.resolve({ - value: chunk, - done: false - }); - } else { - this._queuedChunks.push(chunk); - } - this._loaded += chunk.byteLength; - } - get headersReady() { - return this._headersReady; - } - get filename() { - return this._filename; - } - get isRangeSupported() { - return this._stream._isRangeSupported; - } - get isStreamingSupported() { - return this._stream._isStreamingSupported; - } - get contentLength() { - return this._stream._contentLength; - } - async read() { - if (this._queuedChunks.length > 0) { - const chunk = this._queuedChunks.shift(); - return { - value: chunk, - done: false - }; - } - if (this._done) { - return { - value: undefined, - done: true - }; - } - const requestCapability = Promise.withResolvers(); - this._requests.push(requestCapability); - return requestCapability.promise; - } - cancel(reason) { - this._done = true; - for (const requestCapability of this._requests) { - requestCapability.resolve({ - value: undefined, - done: true - }); - } - this._requests.length = 0; - } - progressiveDone() { - if (this._done) { - return; - } - this._done = true; - } -} -class PDFDataTransportStreamRangeReader { - constructor(stream, begin, end) { - this._stream = stream; - this._begin = begin; - this._end = end; - this._queuedChunk = null; - this._requests = []; - this._done = false; - this.onProgress = null; - } - _enqueue(chunk) { - if (this._done) { - return; - } - if (this._requests.length === 0) { - this._queuedChunk = chunk; - } else { - const requestsCapability = this._requests.shift(); - requestsCapability.resolve({ - value: chunk, - done: false - }); - for (const requestCapability of this._requests) { - requestCapability.resolve({ - value: undefined, - done: true - }); - } - this._requests.length = 0; - } - this._done = true; - this._stream._removeRangeReader(this); - } - get isStreamingSupported() { - return false; - } - async read() { - if (this._queuedChunk) { - const chunk = this._queuedChunk; - this._queuedChunk = null; - return { - value: chunk, - done: false - }; - } - if (this._done) { - return { - value: undefined, - done: true - }; - } - const requestCapability = Promise.withResolvers(); - this._requests.push(requestCapability); - return requestCapability.promise; - } - cancel(reason) { - this._done = true; - for (const requestCapability of this._requests) { - requestCapability.resolve({ - value: undefined, - done: true - }); - } - this._requests.length = 0; - this._stream._removeRangeReader(this); - } -} - -;// CONCATENATED MODULE: ./src/display/content_disposition.js - - - -function getFilenameFromContentDispositionHeader(contentDisposition) { - let needsEncodingFixup = true; - let tmp = toParamRegExp("filename\\*", "i").exec(contentDisposition); - if (tmp) { - tmp = tmp[1]; - let filename = rfc2616unquote(tmp); - filename = unescape(filename); - filename = rfc5987decode(filename); - filename = rfc2047decode(filename); - return fixupEncoding(filename); - } - tmp = rfc2231getparam(contentDisposition); - if (tmp) { - const filename = rfc2047decode(tmp); - return fixupEncoding(filename); - } - tmp = toParamRegExp("filename", "i").exec(contentDisposition); - if (tmp) { - tmp = tmp[1]; - let filename = rfc2616unquote(tmp); - filename = rfc2047decode(filename); - return fixupEncoding(filename); - } - function toParamRegExp(attributePattern, flags) { - return new RegExp("(?:^|;)\\s*" + attributePattern + "\\s*=\\s*" + "(" + '[^";\\s][^;\\s]*' + "|" + '"(?:[^"\\\\]|\\\\"?)+"?' + ")", flags); - } - function textdecode(encoding, value) { - if (encoding) { - if (!/^[\x00-\xFF]+$/.test(value)) { - return value; - } - try { - const decoder = new TextDecoder(encoding, { - fatal: true - }); - const buffer = stringToBytes(value); - value = decoder.decode(buffer); - needsEncodingFixup = false; - } catch {} - } - return value; - } - function fixupEncoding(value) { - if (needsEncodingFixup && /[\x80-\xff]/.test(value)) { - value = textdecode("utf-8", value); - if (needsEncodingFixup) { - value = textdecode("iso-8859-1", value); - } - } - return value; - } - function rfc2231getparam(contentDispositionStr) { - const matches = []; - let match; - const iter = toParamRegExp("filename\\*((?!0\\d)\\d+)(\\*?)", "ig"); - while ((match = iter.exec(contentDispositionStr)) !== null) { - let [, n, quot, part] = match; - n = parseInt(n, 10); - if (n in matches) { - if (n === 0) { - break; - } - continue; - } - matches[n] = [quot, part]; - } - const parts = []; - for (let n = 0; n < matches.length; ++n) { - if (!(n in matches)) { - break; - } - let [quot, part] = matches[n]; - part = rfc2616unquote(part); - if (quot) { - part = unescape(part); - if (n === 0) { - part = rfc5987decode(part); - } - } - parts.push(part); - } - return parts.join(""); - } - function rfc2616unquote(value) { - if (value.startsWith('"')) { - const parts = value.slice(1).split('\\"'); - for (let i = 0; i < parts.length; ++i) { - const quotindex = parts[i].indexOf('"'); - if (quotindex !== -1) { - parts[i] = parts[i].slice(0, quotindex); - parts.length = i + 1; - } - parts[i] = parts[i].replaceAll(/\\(.)/g, "$1"); - } - value = parts.join('"'); - } - return value; - } - function rfc5987decode(extvalue) { - const encodingend = extvalue.indexOf("'"); - if (encodingend === -1) { - return extvalue; - } - const encoding = extvalue.slice(0, encodingend); - const langvalue = extvalue.slice(encodingend + 1); - const value = langvalue.replace(/^[^']*'/, ""); - return textdecode(encoding, value); - } - function rfc2047decode(value) { - if (!value.startsWith("=?") || /[\x00-\x19\x80-\xff]/.test(value)) { - return value; - } - return value.replaceAll(/=\?([\w-]*)\?([QqBb])\?((?:[^?]|\?(?!=))*)\?=/g, function (matches, charset, encoding, text) { - if (encoding === "q" || encoding === "Q") { - text = text.replaceAll("_", " "); - text = text.replaceAll(/=([0-9a-fA-F]{2})/g, function (match, hex) { - return String.fromCharCode(parseInt(hex, 16)); - }); - return textdecode(charset, text); - } - try { - text = atob(text); - } catch {} - return textdecode(charset, text); - }); - } - return ""; -} - -;// CONCATENATED MODULE: ./src/display/network_utils.js - - - -function validateRangeRequestCapabilities({ - getResponseHeader, - isHttp, - rangeChunkSize, - disableRange -}) { - const returnValues = { - allowRangeRequests: false, - suggestedLength: undefined - }; - const length = parseInt(getResponseHeader("Content-Length"), 10); - if (!Number.isInteger(length)) { - return returnValues; - } - returnValues.suggestedLength = length; - if (length <= 2 * rangeChunkSize) { - return returnValues; - } - if (disableRange || !isHttp) { - return returnValues; - } - if (getResponseHeader("Accept-Ranges") !== "bytes") { - return returnValues; - } - const contentEncoding = getResponseHeader("Content-Encoding") || "identity"; - if (contentEncoding !== "identity") { - return returnValues; - } - returnValues.allowRangeRequests = true; - return returnValues; -} -function extractFilenameFromHeader(getResponseHeader) { - const contentDisposition = getResponseHeader("Content-Disposition"); - if (contentDisposition) { - let filename = getFilenameFromContentDispositionHeader(contentDisposition); - if (filename.includes("%")) { - try { - filename = decodeURIComponent(filename); - } catch {} - } - if (isPdfFile(filename)) { - return filename; - } - } - return null; -} -function createResponseStatusError(status, url) { - if (status === 404 || status === 0 && url.startsWith("file:")) { - return new MissingPDFException('Missing PDF "' + url + '".'); - } - return new UnexpectedResponseException(`Unexpected server response (${status}) while retrieving PDF "${url}".`, status); -} -function validateResponseStatus(status) { - return status === 200 || status === 206; -} - -;// CONCATENATED MODULE: ./src/display/fetch_stream.js - - - - - - - - - - -function createFetchOptions(headers, withCredentials, abortController) { - return { - method: "GET", - headers, - signal: abortController.signal, - mode: "cors", - credentials: withCredentials ? "include" : "same-origin", - redirect: "follow" - }; -} -function createHeaders(httpHeaders) { - const headers = new Headers(); - for (const property in httpHeaders) { - const value = httpHeaders[property]; - if (value === undefined) { - continue; - } - headers.append(property, value); - } - return headers; -} -function getArrayBuffer(val) { - if (val instanceof Uint8Array) { - return val.buffer; - } - if (val instanceof ArrayBuffer) { - return val; - } - warn(`getArrayBuffer - unexpected data format: ${val}`); - return new Uint8Array(val).buffer; -} -class PDFFetchStream { - constructor(source) { - this.source = source; - this.isHttp = /^https?:/i.test(source.url); - this.httpHeaders = this.isHttp && source.httpHeaders || {}; - this._fullRequestReader = null; - this._rangeRequestReaders = []; - } - get _progressiveDataLength() { - return this._fullRequestReader?._loaded ?? 0; - } - getFullReader() { - assert(!this._fullRequestReader, "PDFFetchStream.getFullReader can only be called once."); - this._fullRequestReader = new PDFFetchStreamReader(this); - return this._fullRequestReader; - } - getRangeReader(begin, end) { - if (end <= this._progressiveDataLength) { - return null; - } - const reader = new PDFFetchStreamRangeReader(this, begin, end); - this._rangeRequestReaders.push(reader); - return reader; - } - cancelAllRequests(reason) { - this._fullRequestReader?.cancel(reason); - for (const reader of this._rangeRequestReaders.slice(0)) { - reader.cancel(reason); - } - } -} -class PDFFetchStreamReader { - constructor(stream) { - this._stream = stream; - this._reader = null; - this._loaded = 0; - this._filename = null; - const source = stream.source; - this._withCredentials = source.withCredentials || false; - this._contentLength = source.length; - this._headersCapability = Promise.withResolvers(); - this._disableRange = source.disableRange || false; - this._rangeChunkSize = source.rangeChunkSize; - if (!this._rangeChunkSize && !this._disableRange) { - this._disableRange = true; - } - this._abortController = new AbortController(); - this._isStreamingSupported = !source.disableStream; - this._isRangeSupported = !source.disableRange; - this._headers = createHeaders(this._stream.httpHeaders); - const url = source.url; - fetch(url, createFetchOptions(this._headers, this._withCredentials, this._abortController)).then(response => { - if (!validateResponseStatus(response.status)) { - throw createResponseStatusError(response.status, url); - } - this._reader = response.body.getReader(); - this._headersCapability.resolve(); - const getResponseHeader = name => response.headers.get(name); - const { - allowRangeRequests, - suggestedLength - } = validateRangeRequestCapabilities({ - getResponseHeader, - isHttp: this._stream.isHttp, - rangeChunkSize: this._rangeChunkSize, - disableRange: this._disableRange - }); - this._isRangeSupported = allowRangeRequests; - this._contentLength = suggestedLength || this._contentLength; - this._filename = extractFilenameFromHeader(getResponseHeader); - if (!this._isStreamingSupported && this._isRangeSupported) { - this.cancel(new AbortException("Streaming is disabled.")); - } - }).catch(this._headersCapability.reject); - this.onProgress = null; - } - get headersReady() { - return this._headersCapability.promise; - } - get filename() { - return this._filename; - } - get contentLength() { - return this._contentLength; - } - get isRangeSupported() { - return this._isRangeSupported; - } - get isStreamingSupported() { - return this._isStreamingSupported; - } - async read() { - await this._headersCapability.promise; - const { - value, - done - } = await this._reader.read(); - if (done) { - return { - value, - done - }; - } - this._loaded += value.byteLength; - this.onProgress?.({ - loaded: this._loaded, - total: this._contentLength - }); - return { - value: getArrayBuffer(value), - done: false - }; - } - cancel(reason) { - this._reader?.cancel(reason); - this._abortController.abort(); - } -} -class PDFFetchStreamRangeReader { - constructor(stream, begin, end) { - this._stream = stream; - this._reader = null; - this._loaded = 0; - const source = stream.source; - this._withCredentials = source.withCredentials || false; - this._readCapability = Promise.withResolvers(); - this._isStreamingSupported = !source.disableStream; - this._abortController = new AbortController(); - this._headers = createHeaders(this._stream.httpHeaders); - this._headers.append("Range", `bytes=${begin}-${end - 1}`); - const url = source.url; - fetch(url, createFetchOptions(this._headers, this._withCredentials, this._abortController)).then(response => { - if (!validateResponseStatus(response.status)) { - throw createResponseStatusError(response.status, url); - } - this._readCapability.resolve(); - this._reader = response.body.getReader(); - }).catch(this._readCapability.reject); - this.onProgress = null; - } - get isStreamingSupported() { - return this._isStreamingSupported; - } - async read() { - await this._readCapability.promise; - const { - value, - done - } = await this._reader.read(); - if (done) { - return { - value, - done - }; - } - this._loaded += value.byteLength; - this.onProgress?.({ - loaded: this._loaded - }); - return { - value: getArrayBuffer(value), - done: false - }; - } - cancel(reason) { - this._reader?.cancel(reason); - this._abortController.abort(); - } -} - -;// CONCATENATED MODULE: ./src/display/network.js - - - - -const OK_RESPONSE = 200; -const PARTIAL_CONTENT_RESPONSE = 206; -function network_getArrayBuffer(xhr) { - const data = xhr.response; - if (typeof data !== "string") { - return data; - } - return stringToBytes(data).buffer; -} -class NetworkManager { - constructor(url, args = {}) { - this.url = url; - this.isHttp = /^https?:/i.test(url); - this.httpHeaders = this.isHttp && args.httpHeaders || Object.create(null); - this.withCredentials = args.withCredentials || false; - this.currXhrId = 0; - this.pendingRequests = Object.create(null); - } - requestRange(begin, end, listeners) { - const args = { - begin, - end - }; - for (const prop in listeners) { - args[prop] = listeners[prop]; - } - return this.request(args); - } - requestFull(listeners) { - return this.request(listeners); - } - request(args) { - const xhr = new XMLHttpRequest(); - const xhrId = this.currXhrId++; - const pendingRequest = this.pendingRequests[xhrId] = { - xhr - }; - xhr.open("GET", this.url); - xhr.withCredentials = this.withCredentials; - for (const property in this.httpHeaders) { - const value = this.httpHeaders[property]; - if (value === undefined) { - continue; - } - xhr.setRequestHeader(property, value); - } - if (this.isHttp && "begin" in args && "end" in args) { - xhr.setRequestHeader("Range", `bytes=${args.begin}-${args.end - 1}`); - pendingRequest.expectedStatus = PARTIAL_CONTENT_RESPONSE; - } else { - pendingRequest.expectedStatus = OK_RESPONSE; - } - xhr.responseType = "arraybuffer"; - if (args.onError) { - xhr.onerror = function (evt) { - args.onError(xhr.status); - }; - } - xhr.onreadystatechange = this.onStateChange.bind(this, xhrId); - xhr.onprogress = this.onProgress.bind(this, xhrId); - pendingRequest.onHeadersReceived = args.onHeadersReceived; - pendingRequest.onDone = args.onDone; - pendingRequest.onError = args.onError; - pendingRequest.onProgress = args.onProgress; - xhr.send(null); - return xhrId; - } - onProgress(xhrId, evt) { - const pendingRequest = this.pendingRequests[xhrId]; - if (!pendingRequest) { - return; - } - pendingRequest.onProgress?.(evt); - } - onStateChange(xhrId, evt) { - const pendingRequest = this.pendingRequests[xhrId]; - if (!pendingRequest) { - return; - } - const xhr = pendingRequest.xhr; - if (xhr.readyState >= 2 && pendingRequest.onHeadersReceived) { - pendingRequest.onHeadersReceived(); - delete pendingRequest.onHeadersReceived; - } - if (xhr.readyState !== 4) { - return; - } - if (!(xhrId in this.pendingRequests)) { - return; - } - delete this.pendingRequests[xhrId]; - if (xhr.status === 0 && this.isHttp) { - pendingRequest.onError?.(xhr.status); - return; - } - const xhrStatus = xhr.status || OK_RESPONSE; - const ok_response_on_range_request = xhrStatus === OK_RESPONSE && pendingRequest.expectedStatus === PARTIAL_CONTENT_RESPONSE; - if (!ok_response_on_range_request && xhrStatus !== pendingRequest.expectedStatus) { - pendingRequest.onError?.(xhr.status); - return; - } - const chunk = network_getArrayBuffer(xhr); - if (xhrStatus === PARTIAL_CONTENT_RESPONSE) { - const rangeHeader = xhr.getResponseHeader("Content-Range"); - const matches = /bytes (\d+)-(\d+)\/(\d+)/.exec(rangeHeader); - pendingRequest.onDone({ - begin: parseInt(matches[1], 10), - chunk - }); - } else if (chunk) { - pendingRequest.onDone({ - begin: 0, - chunk - }); - } else { - pendingRequest.onError?.(xhr.status); - } - } - getRequestXhr(xhrId) { - return this.pendingRequests[xhrId].xhr; - } - isPendingRequest(xhrId) { - return xhrId in this.pendingRequests; - } - abortRequest(xhrId) { - const xhr = this.pendingRequests[xhrId].xhr; - delete this.pendingRequests[xhrId]; - xhr.abort(); - } -} -class PDFNetworkStream { - constructor(source) { - this._source = source; - this._manager = new NetworkManager(source.url, { - httpHeaders: source.httpHeaders, - withCredentials: source.withCredentials - }); - this._rangeChunkSize = source.rangeChunkSize; - this._fullRequestReader = null; - this._rangeRequestReaders = []; - } - _onRangeRequestReaderClosed(reader) { - const i = this._rangeRequestReaders.indexOf(reader); - if (i >= 0) { - this._rangeRequestReaders.splice(i, 1); - } - } - getFullReader() { - assert(!this._fullRequestReader, "PDFNetworkStream.getFullReader can only be called once."); - this._fullRequestReader = new PDFNetworkStreamFullRequestReader(this._manager, this._source); - return this._fullRequestReader; - } - getRangeReader(begin, end) { - const reader = new PDFNetworkStreamRangeRequestReader(this._manager, begin, end); - reader.onClosed = this._onRangeRequestReaderClosed.bind(this); - this._rangeRequestReaders.push(reader); - return reader; - } - cancelAllRequests(reason) { - this._fullRequestReader?.cancel(reason); - for (const reader of this._rangeRequestReaders.slice(0)) { - reader.cancel(reason); - } - } -} -class PDFNetworkStreamFullRequestReader { - constructor(manager, source) { - this._manager = manager; - const args = { - onHeadersReceived: this._onHeadersReceived.bind(this), - onDone: this._onDone.bind(this), - onError: this._onError.bind(this), - onProgress: this._onProgress.bind(this) - }; - this._url = source.url; - this._fullRequestId = manager.requestFull(args); - this._headersReceivedCapability = Promise.withResolvers(); - this._disableRange = source.disableRange || false; - this._contentLength = source.length; - this._rangeChunkSize = source.rangeChunkSize; - if (!this._rangeChunkSize && !this._disableRange) { - this._disableRange = true; - } - this._isStreamingSupported = false; - this._isRangeSupported = false; - this._cachedChunks = []; - this._requests = []; - this._done = false; - this._storedError = undefined; - this._filename = null; - this.onProgress = null; - } - _onHeadersReceived() { - const fullRequestXhrId = this._fullRequestId; - const fullRequestXhr = this._manager.getRequestXhr(fullRequestXhrId); - const getResponseHeader = name => fullRequestXhr.getResponseHeader(name); - const { - allowRangeRequests, - suggestedLength - } = validateRangeRequestCapabilities({ - getResponseHeader, - isHttp: this._manager.isHttp, - rangeChunkSize: this._rangeChunkSize, - disableRange: this._disableRange - }); - if (allowRangeRequests) { - this._isRangeSupported = true; - } - this._contentLength = suggestedLength || this._contentLength; - this._filename = extractFilenameFromHeader(getResponseHeader); - if (this._isRangeSupported) { - this._manager.abortRequest(fullRequestXhrId); - } - this._headersReceivedCapability.resolve(); - } - _onDone(data) { - if (data) { - if (this._requests.length > 0) { - const requestCapability = this._requests.shift(); - requestCapability.resolve({ - value: data.chunk, - done: false - }); - } else { - this._cachedChunks.push(data.chunk); - } - } - this._done = true; - if (this._cachedChunks.length > 0) { - return; - } - for (const requestCapability of this._requests) { - requestCapability.resolve({ - value: undefined, - done: true - }); - } - this._requests.length = 0; - } - _onError(status) { - this._storedError = createResponseStatusError(status, this._url); - this._headersReceivedCapability.reject(this._storedError); - for (const requestCapability of this._requests) { - requestCapability.reject(this._storedError); - } - this._requests.length = 0; - this._cachedChunks.length = 0; - } - _onProgress(evt) { - this.onProgress?.({ - loaded: evt.loaded, - total: evt.lengthComputable ? evt.total : this._contentLength - }); - } - get filename() { - return this._filename; - } - get isRangeSupported() { - return this._isRangeSupported; - } - get isStreamingSupported() { - return this._isStreamingSupported; - } - get contentLength() { - return this._contentLength; - } - get headersReady() { - return this._headersReceivedCapability.promise; - } - async read() { - if (this._storedError) { - throw this._storedError; - } - if (this._cachedChunks.length > 0) { - const chunk = this._cachedChunks.shift(); - return { - value: chunk, - done: false - }; - } - if (this._done) { - return { - value: undefined, - done: true - }; - } - const requestCapability = Promise.withResolvers(); - this._requests.push(requestCapability); - return requestCapability.promise; - } - cancel(reason) { - this._done = true; - this._headersReceivedCapability.reject(reason); - for (const requestCapability of this._requests) { - requestCapability.resolve({ - value: undefined, - done: true - }); - } - this._requests.length = 0; - if (this._manager.isPendingRequest(this._fullRequestId)) { - this._manager.abortRequest(this._fullRequestId); - } - this._fullRequestReader = null; - } -} -class PDFNetworkStreamRangeRequestReader { - constructor(manager, begin, end) { - this._manager = manager; - const args = { - onDone: this._onDone.bind(this), - onError: this._onError.bind(this), - onProgress: this._onProgress.bind(this) - }; - this._url = manager.url; - this._requestId = manager.requestRange(begin, end, args); - this._requests = []; - this._queuedChunk = null; - this._done = false; - this._storedError = undefined; - this.onProgress = null; - this.onClosed = null; - } - _close() { - this.onClosed?.(this); - } - _onDone(data) { - const chunk = data.chunk; - if (this._requests.length > 0) { - const requestCapability = this._requests.shift(); - requestCapability.resolve({ - value: chunk, - done: false - }); - } else { - this._queuedChunk = chunk; - } - this._done = true; - for (const requestCapability of this._requests) { - requestCapability.resolve({ - value: undefined, - done: true - }); - } - this._requests.length = 0; - this._close(); - } - _onError(status) { - this._storedError = createResponseStatusError(status, this._url); - for (const requestCapability of this._requests) { - requestCapability.reject(this._storedError); - } - this._requests.length = 0; - this._queuedChunk = null; - } - _onProgress(evt) { - if (!this.isStreamingSupported) { - this.onProgress?.({ - loaded: evt.loaded - }); - } - } - get isStreamingSupported() { - return false; - } - async read() { - if (this._storedError) { - throw this._storedError; - } - if (this._queuedChunk !== null) { - const chunk = this._queuedChunk; - this._queuedChunk = null; - return { - value: chunk, - done: false - }; - } - if (this._done) { - return { - value: undefined, - done: true - }; - } - const requestCapability = Promise.withResolvers(); - this._requests.push(requestCapability); - return requestCapability.promise; - } - cancel(reason) { - this._done = true; - for (const requestCapability of this._requests) { - requestCapability.resolve({ - value: undefined, - done: true - }); - } - this._requests.length = 0; - if (this._manager.isPendingRequest(this._requestId)) { - this._manager.abortRequest(this._requestId); - } - this._close(); - } -} - -;// CONCATENATED MODULE: ./src/display/node_stream.js - - - - - - - - - - - -const fileUriRegex = /^file:\/\/\/[a-zA-Z]:\//; -function parseUrl(sourceUrl) { - const url = NodePackages.get("url"); - const parsedUrl = url.parse(sourceUrl); - if (parsedUrl.protocol === "file:" || parsedUrl.host) { - return parsedUrl; - } - if (/^[a-z]:[/\\]/i.test(sourceUrl)) { - return url.parse(`file:///${sourceUrl}`); - } - if (!parsedUrl.host) { - parsedUrl.protocol = "file:"; - } - return parsedUrl; -} -class PDFNodeStream { - constructor(source) { - this.source = source; - this.url = parseUrl(source.url); - this.isHttp = this.url.protocol === "http:" || this.url.protocol === "https:"; - this.isFsUrl = this.url.protocol === "file:"; - this.httpHeaders = this.isHttp && source.httpHeaders || {}; - this._fullRequestReader = null; - this._rangeRequestReaders = []; - } - get _progressiveDataLength() { - return this._fullRequestReader?._loaded ?? 0; - } - getFullReader() { - assert(!this._fullRequestReader, "PDFNodeStream.getFullReader can only be called once."); - this._fullRequestReader = this.isFsUrl ? new PDFNodeStreamFsFullReader(this) : new PDFNodeStreamFullReader(this); - return this._fullRequestReader; - } - getRangeReader(start, end) { - if (end <= this._progressiveDataLength) { - return null; - } - const rangeReader = this.isFsUrl ? new PDFNodeStreamFsRangeReader(this, start, end) : new PDFNodeStreamRangeReader(this, start, end); - this._rangeRequestReaders.push(rangeReader); - return rangeReader; - } - cancelAllRequests(reason) { - this._fullRequestReader?.cancel(reason); - for (const reader of this._rangeRequestReaders.slice(0)) { - reader.cancel(reason); - } - } -} -class BaseFullReader { - constructor(stream) { - this._url = stream.url; - this._done = false; - this._storedError = null; - this.onProgress = null; - const source = stream.source; - this._contentLength = source.length; - this._loaded = 0; - this._filename = null; - this._disableRange = source.disableRange || false; - this._rangeChunkSize = source.rangeChunkSize; - if (!this._rangeChunkSize && !this._disableRange) { - this._disableRange = true; - } - this._isStreamingSupported = !source.disableStream; - this._isRangeSupported = !source.disableRange; - this._readableStream = null; - this._readCapability = Promise.withResolvers(); - this._headersCapability = Promise.withResolvers(); - } - get headersReady() { - return this._headersCapability.promise; - } - get filename() { - return this._filename; - } - get contentLength() { - return this._contentLength; - } - get isRangeSupported() { - return this._isRangeSupported; - } - get isStreamingSupported() { - return this._isStreamingSupported; - } - async read() { - await this._readCapability.promise; - if (this._done) { - return { - value: undefined, - done: true - }; - } - if (this._storedError) { - throw this._storedError; - } - const chunk = this._readableStream.read(); - if (chunk === null) { - this._readCapability = Promise.withResolvers(); - return this.read(); - } - this._loaded += chunk.length; - this.onProgress?.({ - loaded: this._loaded, - total: this._contentLength - }); - const buffer = new Uint8Array(chunk).buffer; - return { - value: buffer, - done: false - }; - } - cancel(reason) { - if (!this._readableStream) { - this._error(reason); - return; - } - this._readableStream.destroy(reason); - } - _error(reason) { - this._storedError = reason; - this._readCapability.resolve(); - } - _setReadableStream(readableStream) { - this._readableStream = readableStream; - readableStream.on("readable", () => { - this._readCapability.resolve(); - }); - readableStream.on("end", () => { - readableStream.destroy(); - this._done = true; - this._readCapability.resolve(); - }); - readableStream.on("error", reason => { - this._error(reason); - }); - if (!this._isStreamingSupported && this._isRangeSupported) { - this._error(new AbortException("streaming is disabled")); - } - if (this._storedError) { - this._readableStream.destroy(this._storedError); - } - } -} -class BaseRangeReader { - constructor(stream) { - this._url = stream.url; - this._done = false; - this._storedError = null; - this.onProgress = null; - this._loaded = 0; - this._readableStream = null; - this._readCapability = Promise.withResolvers(); - const source = stream.source; - this._isStreamingSupported = !source.disableStream; - } - get isStreamingSupported() { - return this._isStreamingSupported; - } - async read() { - await this._readCapability.promise; - if (this._done) { - return { - value: undefined, - done: true - }; - } - if (this._storedError) { - throw this._storedError; - } - const chunk = this._readableStream.read(); - if (chunk === null) { - this._readCapability = Promise.withResolvers(); - return this.read(); - } - this._loaded += chunk.length; - this.onProgress?.({ - loaded: this._loaded - }); - const buffer = new Uint8Array(chunk).buffer; - return { - value: buffer, - done: false - }; - } - cancel(reason) { - if (!this._readableStream) { - this._error(reason); - return; - } - this._readableStream.destroy(reason); - } - _error(reason) { - this._storedError = reason; - this._readCapability.resolve(); - } - _setReadableStream(readableStream) { - this._readableStream = readableStream; - readableStream.on("readable", () => { - this._readCapability.resolve(); - }); - readableStream.on("end", () => { - readableStream.destroy(); - this._done = true; - this._readCapability.resolve(); - }); - readableStream.on("error", reason => { - this._error(reason); - }); - if (this._storedError) { - this._readableStream.destroy(this._storedError); - } - } -} -function createRequestOptions(parsedUrl, headers) { - return { - protocol: parsedUrl.protocol, - auth: parsedUrl.auth, - host: parsedUrl.hostname, - port: parsedUrl.port, - path: parsedUrl.path, - method: "GET", - headers - }; -} -class PDFNodeStreamFullReader extends BaseFullReader { - constructor(stream) { - super(stream); - const handleResponse = response => { - if (response.statusCode === 404) { - const error = new MissingPDFException(`Missing PDF "${this._url}".`); - this._storedError = error; - this._headersCapability.reject(error); - return; - } - this._headersCapability.resolve(); - this._setReadableStream(response); - const getResponseHeader = name => this._readableStream.headers[name.toLowerCase()]; - const { - allowRangeRequests, - suggestedLength - } = validateRangeRequestCapabilities({ - getResponseHeader, - isHttp: stream.isHttp, - rangeChunkSize: this._rangeChunkSize, - disableRange: this._disableRange - }); - this._isRangeSupported = allowRangeRequests; - this._contentLength = suggestedLength || this._contentLength; - this._filename = extractFilenameFromHeader(getResponseHeader); - }; - this._request = null; - if (this._url.protocol === "http:") { - const http = NodePackages.get("http"); - this._request = http.request(createRequestOptions(this._url, stream.httpHeaders), handleResponse); - } else { - const https = NodePackages.get("https"); - this._request = https.request(createRequestOptions(this._url, stream.httpHeaders), handleResponse); - } - this._request.on("error", reason => { - this._storedError = reason; - this._headersCapability.reject(reason); - }); - this._request.end(); - } -} -class PDFNodeStreamRangeReader extends BaseRangeReader { - constructor(stream, start, end) { - super(stream); - this._httpHeaders = {}; - for (const property in stream.httpHeaders) { - const value = stream.httpHeaders[property]; - if (value === undefined) { - continue; - } - this._httpHeaders[property] = value; - } - this._httpHeaders.Range = `bytes=${start}-${end - 1}`; - const handleResponse = response => { - if (response.statusCode === 404) { - const error = new MissingPDFException(`Missing PDF "${this._url}".`); - this._storedError = error; - return; - } - this._setReadableStream(response); - }; - this._request = null; - if (this._url.protocol === "http:") { - const http = NodePackages.get("http"); - this._request = http.request(createRequestOptions(this._url, this._httpHeaders), handleResponse); - } else { - const https = NodePackages.get("https"); - this._request = https.request(createRequestOptions(this._url, this._httpHeaders), handleResponse); - } - this._request.on("error", reason => { - this._storedError = reason; - }); - this._request.end(); - } -} -class PDFNodeStreamFsFullReader extends BaseFullReader { - constructor(stream) { - super(stream); - let path = decodeURIComponent(this._url.path); - if (fileUriRegex.test(this._url.href)) { - path = path.replace(/^\//, ""); - } - const fs = NodePackages.get("fs"); - fs.promises.lstat(path).then(stat => { - this._contentLength = stat.size; - this._setReadableStream(fs.createReadStream(path)); - this._headersCapability.resolve(); - }, error => { - if (error.code === "ENOENT") { - error = new MissingPDFException(`Missing PDF "${path}".`); - } - this._storedError = error; - this._headersCapability.reject(error); - }); - } -} -class PDFNodeStreamFsRangeReader extends BaseRangeReader { - constructor(stream, start, end) { - super(stream); - let path = decodeURIComponent(this._url.path); - if (fileUriRegex.test(this._url.href)) { - path = path.replace(/^\//, ""); - } - const fs = NodePackages.get("fs"); - this._setReadableStream(fs.createReadStream(path, { - start, - end: end - 1 - })); - } -} - -;// CONCATENATED MODULE: ./src/display/text_layer.js - - - - - - - - - - - -const MAX_TEXT_DIVS_TO_RENDER = 100000; -const DEFAULT_FONT_SIZE = 30; -const DEFAULT_FONT_ASCENT = 0.8; -class TextLayer { - #capability = Promise.withResolvers(); - #container = null; - #disableProcessItems = false; - #fontInspectorEnabled = !!globalThis.FontInspector?.enabled; - #lang = null; - #layoutTextParams = null; - #pageHeight = 0; - #pageWidth = 0; - #reader = null; - #rootContainer = null; - #rotation = 0; - #scale = 0; - #styleCache = Object.create(null); - #textContentItemsStr = []; - #textContentSource = null; - #textDivs = []; - #textDivProperties = new WeakMap(); - #transform = null; - static #ascentCache = new Map(); - static #canvasContexts = new Map(); - static #pendingTextLayers = new Set(); - constructor({ - textContentSource, - container, - viewport - }) { - if (textContentSource instanceof ReadableStream) { - this.#textContentSource = textContentSource; - } else if (typeof textContentSource === "object") { - this.#textContentSource = new ReadableStream({ - start(controller) { - controller.enqueue(textContentSource); - controller.close(); - } - }); - } else { - throw new Error('No "textContentSource" parameter specified.'); - } - this.#container = this.#rootContainer = container; - this.#scale = viewport.scale * (globalThis.devicePixelRatio || 1); - this.#rotation = viewport.rotation; - this.#layoutTextParams = { - prevFontSize: null, - prevFontFamily: null, - div: null, - properties: null, - ctx: null - }; - const { - pageWidth, - pageHeight, - pageX, - pageY - } = viewport.rawDims; - this.#transform = [1, 0, 0, -1, -pageX, pageY + pageHeight]; - this.#pageWidth = pageWidth; - this.#pageHeight = pageHeight; - setLayerDimensions(container, viewport); - this.#capability.promise.catch(() => {}).then(() => { - TextLayer.#pendingTextLayers.delete(this); - this.#layoutTextParams = null; - this.#styleCache = null; - }); - } - render() { - const pump = () => { - this.#reader.read().then(({ - value, - done - }) => { - if (done) { - this.#capability.resolve(); - return; - } - this.#lang ??= value.lang; - Object.assign(this.#styleCache, value.styles); - this.#processItems(value.items); - pump(); - }, this.#capability.reject); - }; - this.#reader = this.#textContentSource.getReader(); - TextLayer.#pendingTextLayers.add(this); - pump(); - return this.#capability.promise; - } - update({ - viewport, - onBefore = null - }) { - const scale = viewport.scale * (globalThis.devicePixelRatio || 1); - const rotation = viewport.rotation; - if (rotation !== this.#rotation) { - onBefore?.(); - this.#rotation = rotation; - setLayerDimensions(this.#rootContainer, { - rotation - }); - } - if (scale !== this.#scale) { - onBefore?.(); - this.#scale = scale; - const params = { - prevFontSize: null, - prevFontFamily: null, - div: null, - properties: null, - ctx: TextLayer.#getCtx(this.#lang) - }; - for (const div of this.#textDivs) { - params.properties = this.#textDivProperties.get(div); - params.div = div; - this.#layout(params); - } - } - } - cancel() { - const abortEx = new AbortException("TextLayer task cancelled."); - this.#reader?.cancel(abortEx).catch(() => {}); - this.#reader = null; - this.#capability.reject(abortEx); - } - get textDivs() { - return this.#textDivs; - } - get textContentItemsStr() { - return this.#textContentItemsStr; - } - #processItems(items) { - if (this.#disableProcessItems) { - return; - } - this.#layoutTextParams.ctx ||= TextLayer.#getCtx(this.#lang); - const textDivs = this.#textDivs, - textContentItemsStr = this.#textContentItemsStr; - for (const item of items) { - if (textDivs.length > MAX_TEXT_DIVS_TO_RENDER) { - warn("Ignoring additional textDivs for performance reasons."); - this.#disableProcessItems = true; - return; - } - if (item.str === undefined) { - if (item.type === "beginMarkedContentProps" || item.type === "beginMarkedContent") { - const parent = this.#container; - this.#container = document.createElement("span"); - this.#container.classList.add("markedContent"); - if (item.id !== null) { - this.#container.setAttribute("id", `${item.id}`); - } - parent.append(this.#container); - } else if (item.type === "endMarkedContent") { - this.#container = this.#container.parentNode; - } - continue; - } - textContentItemsStr.push(item.str); - this.#appendText(item); - } - } - #appendText(geom) { - const textDiv = document.createElement("span"); - const textDivProperties = { - angle: 0, - canvasWidth: 0, - hasText: geom.str !== "", - hasEOL: geom.hasEOL, - fontSize: 0 - }; - this.#textDivs.push(textDiv); - const tx = Util.transform(this.#transform, geom.transform); - let angle = Math.atan2(tx[1], tx[0]); - const style = this.#styleCache[geom.fontName]; - if (style.vertical) { - angle += Math.PI / 2; - } - const fontFamily = this.#fontInspectorEnabled && style.fontSubstitution || style.fontFamily; - const fontHeight = Math.hypot(tx[2], tx[3]); - const fontAscent = fontHeight * TextLayer.#getAscent(fontFamily, this.#lang); - let left, top; - if (angle === 0) { - left = tx[4]; - top = tx[5] - fontAscent; - } else { - left = tx[4] + fontAscent * Math.sin(angle); - top = tx[5] - fontAscent * Math.cos(angle); - } - const scaleFactorStr = "calc(var(--scale-factor)*"; - const divStyle = textDiv.style; - if (this.#container === this.#rootContainer) { - divStyle.left = `${(100 * left / this.#pageWidth).toFixed(2)}%`; - divStyle.top = `${(100 * top / this.#pageHeight).toFixed(2)}%`; - } else { - divStyle.left = `${scaleFactorStr}${left.toFixed(2)}px)`; - divStyle.top = `${scaleFactorStr}${top.toFixed(2)}px)`; - } - divStyle.fontSize = `${scaleFactorStr}${fontHeight.toFixed(2)}px)`; - divStyle.fontFamily = fontFamily; - textDivProperties.fontSize = fontHeight; - textDiv.setAttribute("role", "presentation"); - textDiv.textContent = geom.str; - textDiv.dir = geom.dir; - if (this.#fontInspectorEnabled) { - textDiv.dataset.fontName = style.fontSubstitutionLoadedName || geom.fontName; - } - if (angle !== 0) { - textDivProperties.angle = angle * (180 / Math.PI); - } - let shouldScaleText = false; - if (geom.str.length > 1) { - shouldScaleText = true; - } else if (geom.str !== " " && geom.transform[0] !== geom.transform[3]) { - const absScaleX = Math.abs(geom.transform[0]), - absScaleY = Math.abs(geom.transform[3]); - if (absScaleX !== absScaleY && Math.max(absScaleX, absScaleY) / Math.min(absScaleX, absScaleY) > 1.5) { - shouldScaleText = true; - } - } - if (shouldScaleText) { - textDivProperties.canvasWidth = style.vertical ? geom.height : geom.width; - } - this.#textDivProperties.set(textDiv, textDivProperties); - this.#layoutTextParams.div = textDiv; - this.#layoutTextParams.properties = textDivProperties; - this.#layout(this.#layoutTextParams); - if (textDivProperties.hasText) { - this.#container.append(textDiv); - } - if (textDivProperties.hasEOL) { - const br = document.createElement("br"); - br.setAttribute("role", "presentation"); - this.#container.append(br); - } - } - #layout(params) { - const { - div, - properties, - ctx, - prevFontSize, - prevFontFamily - } = params; - const { - style - } = div; - let transform = ""; - if (properties.canvasWidth !== 0 && properties.hasText) { - const { - fontFamily - } = style; - const { - canvasWidth, - fontSize - } = properties; - if (prevFontSize !== fontSize || prevFontFamily !== fontFamily) { - ctx.font = `${fontSize * this.#scale}px ${fontFamily}`; - params.prevFontSize = fontSize; - params.prevFontFamily = fontFamily; - } - const { - width - } = ctx.measureText(div.textContent); - if (width > 0) { - transform = `scaleX(${canvasWidth * this.#scale / width})`; - } - } - if (properties.angle !== 0) { - transform = `rotate(${properties.angle}deg) ${transform}`; - } - if (transform.length > 0) { - style.transform = transform; - } - } - static cleanup() { - if (this.#pendingTextLayers.size > 0) { - return; - } - this.#ascentCache.clear(); - for (const { - canvas - } of this.#canvasContexts.values()) { - canvas.remove(); - } - this.#canvasContexts.clear(); - } - static #getCtx(lang = null) { - let canvasContext = this.#canvasContexts.get(lang ||= ""); - if (!canvasContext) { - const canvas = document.createElement("canvas"); - canvas.className = "hiddenCanvasElement"; - canvas.lang = lang; - document.body.append(canvas); - canvasContext = canvas.getContext("2d", { - alpha: false, - willReadFrequently: true - }); - this.#canvasContexts.set(lang, canvasContext); - } - return canvasContext; - } - static #getAscent(fontFamily, lang) { - const cachedAscent = this.#ascentCache.get(fontFamily); - if (cachedAscent) { - return cachedAscent; - } - const ctx = this.#getCtx(lang); - const savedFont = ctx.font; - ctx.canvas.width = ctx.canvas.height = DEFAULT_FONT_SIZE; - ctx.font = `${DEFAULT_FONT_SIZE}px ${fontFamily}`; - const metrics = ctx.measureText(""); - let ascent = metrics.fontBoundingBoxAscent; - let descent = Math.abs(metrics.fontBoundingBoxDescent); - if (ascent) { - const ratio = ascent / (ascent + descent); - this.#ascentCache.set(fontFamily, ratio); - ctx.canvas.width = ctx.canvas.height = 0; - ctx.font = savedFont; - return ratio; - } - ctx.strokeStyle = "red"; - ctx.clearRect(0, 0, DEFAULT_FONT_SIZE, DEFAULT_FONT_SIZE); - ctx.strokeText("g", 0, 0); - let pixels = ctx.getImageData(0, 0, DEFAULT_FONT_SIZE, DEFAULT_FONT_SIZE).data; - descent = 0; - for (let i = pixels.length - 1 - 3; i >= 0; i -= 4) { - if (pixels[i] > 0) { - descent = Math.ceil(i / 4 / DEFAULT_FONT_SIZE); - break; - } - } - ctx.clearRect(0, 0, DEFAULT_FONT_SIZE, DEFAULT_FONT_SIZE); - ctx.strokeText("A", 0, DEFAULT_FONT_SIZE); - pixels = ctx.getImageData(0, 0, DEFAULT_FONT_SIZE, DEFAULT_FONT_SIZE).data; - ascent = 0; - for (let i = 0, ii = pixels.length; i < ii; i += 4) { - if (pixels[i] > 0) { - ascent = DEFAULT_FONT_SIZE - Math.floor(i / 4 / DEFAULT_FONT_SIZE); - break; - } - } - ctx.canvas.width = ctx.canvas.height = 0; - ctx.font = savedFont; - const ratio = ascent ? ascent / (ascent + descent) : DEFAULT_FONT_ASCENT; - this.#ascentCache.set(fontFamily, ratio); - return ratio; - } -} -function renderTextLayer() { - deprecated("`renderTextLayer`, please use `TextLayer` instead."); - const { - textContentSource, - container, - viewport, - ...rest - } = arguments[0]; - const restKeys = Object.keys(rest); - if (restKeys.length > 0) { - warn("Ignoring `renderTextLayer` parameters: " + restKeys.join(", ")); - } - const textLayer = new TextLayer({ - textContentSource, - container, - viewport - }); - const { - textDivs, - textContentItemsStr - } = textLayer; - const promise = textLayer.render(); - return { - promise, - textDivs, - textContentItemsStr - }; -} -function updateTextLayer() { - deprecated("`updateTextLayer`, please use `TextLayer` instead."); -} - -;// CONCATENATED MODULE: ./src/display/xfa_text.js - -class XfaText { - static textContent(xfa) { - const items = []; - const output = { - items, - styles: Object.create(null) - }; - function walk(node) { - if (!node) { - return; - } - let str = null; - const name = node.name; - if (name === "#text") { - str = node.value; - } else if (!XfaText.shouldBuildText(name)) { - return; - } else if (node?.attributes?.textContent) { - str = node.attributes.textContent; - } else if (node.value) { - str = node.value; - } - if (str !== null) { - items.push({ - str - }); - } - if (!node.children) { - return; - } - for (const child of node.children) { - walk(child); - } - } - walk(xfa); - return output; - } - static shouldBuildText(name) { - return !(name === "textarea" || name === "input" || name === "option" || name === "select"); - } -} - -;// CONCATENATED MODULE: ./src/display/api.js - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const DEFAULT_RANGE_CHUNK_SIZE = 65536; -const RENDERING_CANCELLED_TIMEOUT = 100; -const DELAYED_CLEANUP_TIMEOUT = 5000; -const DefaultCanvasFactory = isNodeJS ? NodeCanvasFactory : DOMCanvasFactory; -const DefaultCMapReaderFactory = isNodeJS ? NodeCMapReaderFactory : DOMCMapReaderFactory; -const DefaultFilterFactory = isNodeJS ? NodeFilterFactory : DOMFilterFactory; -const DefaultStandardFontDataFactory = isNodeJS ? NodeStandardFontDataFactory : DOMStandardFontDataFactory; -function getDocument(src = {}) { - if (typeof src === "string" || src instanceof URL) { - src = { - url: src - }; - } else if (src instanceof ArrayBuffer || ArrayBuffer.isView(src)) { - src = { - data: src - }; - } - const task = new PDFDocumentLoadingTask(); - const { - docId - } = task; - const url = src.url ? getUrlProp(src.url) : null; - const data = src.data ? getDataProp(src.data) : null; - const httpHeaders = src.httpHeaders || null; - const withCredentials = src.withCredentials === true; - const password = src.password ?? null; - const rangeTransport = src.range instanceof PDFDataRangeTransport ? src.range : null; - const rangeChunkSize = Number.isInteger(src.rangeChunkSize) && src.rangeChunkSize > 0 ? src.rangeChunkSize : DEFAULT_RANGE_CHUNK_SIZE; - let worker = src.worker instanceof PDFWorker ? src.worker : null; - const verbosity = src.verbosity; - const docBaseUrl = typeof src.docBaseUrl === "string" && !isDataScheme(src.docBaseUrl) ? src.docBaseUrl : null; - const cMapUrl = typeof src.cMapUrl === "string" ? src.cMapUrl : null; - const cMapPacked = src.cMapPacked !== false; - const CMapReaderFactory = src.CMapReaderFactory || DefaultCMapReaderFactory; - const standardFontDataUrl = typeof src.standardFontDataUrl === "string" ? src.standardFontDataUrl : null; - const StandardFontDataFactory = src.StandardFontDataFactory || DefaultStandardFontDataFactory; - const ignoreErrors = src.stopAtErrors !== true; - const maxImageSize = Number.isInteger(src.maxImageSize) && src.maxImageSize > -1 ? src.maxImageSize : -1; - const isEvalSupported = src.isEvalSupported !== false; - const isOffscreenCanvasSupported = typeof src.isOffscreenCanvasSupported === "boolean" ? src.isOffscreenCanvasSupported : !isNodeJS; - const canvasMaxAreaInBytes = Number.isInteger(src.canvasMaxAreaInBytes) ? src.canvasMaxAreaInBytes : -1; - const disableFontFace = typeof src.disableFontFace === "boolean" ? src.disableFontFace : isNodeJS; - const fontExtraProperties = src.fontExtraProperties === true; - const enableXfa = src.enableXfa === true; - const ownerDocument = src.ownerDocument || globalThis.document; - const disableRange = src.disableRange === true; - const disableStream = src.disableStream === true; - const disableAutoFetch = src.disableAutoFetch === true; - const pdfBug = src.pdfBug === true; - const enableHWA = src.enableHWA === true; - const length = rangeTransport ? rangeTransport.length : src.length ?? NaN; - const useSystemFonts = typeof src.useSystemFonts === "boolean" ? src.useSystemFonts : !isNodeJS && !disableFontFace; - const useWorkerFetch = typeof src.useWorkerFetch === "boolean" ? src.useWorkerFetch : CMapReaderFactory === DOMCMapReaderFactory && StandardFontDataFactory === DOMStandardFontDataFactory && cMapUrl && standardFontDataUrl && isValidFetchUrl(cMapUrl, document.baseURI) && isValidFetchUrl(standardFontDataUrl, document.baseURI); - const canvasFactory = src.canvasFactory || new DefaultCanvasFactory({ - ownerDocument, - enableHWA - }); - const filterFactory = src.filterFactory || new DefaultFilterFactory({ - docId, - ownerDocument - }); - const styleElement = null; - setVerbosityLevel(verbosity); - const transportFactory = { - canvasFactory, - filterFactory - }; - if (!useWorkerFetch) { - transportFactory.cMapReaderFactory = new CMapReaderFactory({ - baseUrl: cMapUrl, - isCompressed: cMapPacked - }); - transportFactory.standardFontDataFactory = new StandardFontDataFactory({ - baseUrl: standardFontDataUrl - }); - } - if (!worker) { - const workerParams = { - verbosity, - port: GlobalWorkerOptions.workerPort - }; - worker = workerParams.port ? PDFWorker.fromPort(workerParams) : new PDFWorker(workerParams); - task._worker = worker; - } - const docParams = { - docId, - apiVersion: "4.4.82", - data, - password, - disableAutoFetch, - rangeChunkSize, - length, - docBaseUrl, - enableXfa, - evaluatorOptions: { - maxImageSize, - disableFontFace, - ignoreErrors, - isEvalSupported, - isOffscreenCanvasSupported, - canvasMaxAreaInBytes, - fontExtraProperties, - useSystemFonts, - cMapUrl: useWorkerFetch ? cMapUrl : null, - standardFontDataUrl: useWorkerFetch ? standardFontDataUrl : null - } - }; - const transportParams = { - disableFontFace, - fontExtraProperties, - ownerDocument, - pdfBug, - styleElement, - loadingParams: { - disableAutoFetch, - enableXfa - } - }; - worker.promise.then(function () { - if (task.destroyed) { - throw new Error("Loading aborted"); - } - if (worker.destroyed) { - throw new Error("Worker was destroyed"); - } - const workerIdPromise = worker.messageHandler.sendWithPromise("GetDocRequest", docParams, data ? [data.buffer] : null); - let networkStream; - if (rangeTransport) { - networkStream = new PDFDataTransportStream(rangeTransport, { - disableRange, - disableStream - }); - } else if (!data) { - if (!url) { - throw new Error("getDocument - no `url` parameter provided."); - } - const createPDFNetworkStream = params => { - if (isNodeJS) { - const isFetchSupported = function () { - return typeof fetch !== "undefined" && typeof Response !== "undefined" && "body" in Response.prototype; - }; - return isFetchSupported() && isValidFetchUrl(params.url) ? new PDFFetchStream(params) : new PDFNodeStream(params); - } - return isValidFetchUrl(params.url) ? new PDFFetchStream(params) : new PDFNetworkStream(params); - }; - networkStream = createPDFNetworkStream({ - url, - length, - httpHeaders, - withCredentials, - rangeChunkSize, - disableRange, - disableStream - }); - } - return workerIdPromise.then(workerId => { - if (task.destroyed) { - throw new Error("Loading aborted"); - } - if (worker.destroyed) { - throw new Error("Worker was destroyed"); - } - const messageHandler = new MessageHandler(docId, workerId, worker.port); - const transport = new WorkerTransport(messageHandler, task, networkStream, transportParams, transportFactory); - task._transport = transport; - messageHandler.send("Ready", null); - }); - }).catch(task._capability.reject); - return task; -} -function getUrlProp(val) { - if (val instanceof URL) { - return val.href; - } - try { - return new URL(val, window.location).href; - } catch { - if (isNodeJS && typeof val === "string") { - return val; - } - } - throw new Error("Invalid PDF url data: " + "either string or URL-object is expected in the url property."); -} -function getDataProp(val) { - if (isNodeJS && typeof Buffer !== "undefined" && val instanceof Buffer) { - throw new Error("Please provide binary data as `Uint8Array`, rather than `Buffer`."); - } - if (val instanceof Uint8Array && val.byteLength === val.buffer.byteLength) { - return val; - } - if (typeof val === "string") { - return stringToBytes(val); - } - if (val instanceof ArrayBuffer || ArrayBuffer.isView(val) || typeof val === "object" && !isNaN(val?.length)) { - return new Uint8Array(val); - } - throw new Error("Invalid PDF binary data: either TypedArray, " + "string, or array-like object is expected in the data property."); -} -function isRefProxy(ref) { - return typeof ref === "object" && Number.isInteger(ref?.num) && ref.num >= 0 && Number.isInteger(ref?.gen) && ref.gen >= 0; -} -class PDFDocumentLoadingTask { - static #docId = 0; - constructor() { - this._capability = Promise.withResolvers(); - this._transport = null; - this._worker = null; - this.docId = `d${PDFDocumentLoadingTask.#docId++}`; - this.destroyed = false; - this.onPassword = null; - this.onProgress = null; - } - get promise() { - return this._capability.promise; - } - async destroy() { - this.destroyed = true; - try { - if (this._worker?.port) { - this._worker._pendingDestroy = true; - } - await this._transport?.destroy(); - } catch (ex) { - if (this._worker?.port) { - delete this._worker._pendingDestroy; - } - throw ex; - } - this._transport = null; - if (this._worker) { - this._worker.destroy(); - this._worker = null; - } - } -} -class PDFDataRangeTransport { - constructor(length, initialData, progressiveDone = false, contentDispositionFilename = null) { - this.length = length; - this.initialData = initialData; - this.progressiveDone = progressiveDone; - this.contentDispositionFilename = contentDispositionFilename; - this._rangeListeners = []; - this._progressListeners = []; - this._progressiveReadListeners = []; - this._progressiveDoneListeners = []; - this._readyCapability = Promise.withResolvers(); - } - addRangeListener(listener) { - this._rangeListeners.push(listener); - } - addProgressListener(listener) { - this._progressListeners.push(listener); - } - addProgressiveReadListener(listener) { - this._progressiveReadListeners.push(listener); - } - addProgressiveDoneListener(listener) { - this._progressiveDoneListeners.push(listener); - } - onDataRange(begin, chunk) { - for (const listener of this._rangeListeners) { - listener(begin, chunk); - } - } - onDataProgress(loaded, total) { - this._readyCapability.promise.then(() => { - for (const listener of this._progressListeners) { - listener(loaded, total); - } - }); - } - onDataProgressiveRead(chunk) { - this._readyCapability.promise.then(() => { - for (const listener of this._progressiveReadListeners) { - listener(chunk); - } - }); - } - onDataProgressiveDone() { - this._readyCapability.promise.then(() => { - for (const listener of this._progressiveDoneListeners) { - listener(); - } - }); - } - transportReady() { - this._readyCapability.resolve(); - } - requestDataRange(begin, end) { - unreachable("Abstract method PDFDataRangeTransport.requestDataRange"); - } - abort() {} -} -class PDFDocumentProxy { - constructor(pdfInfo, transport) { - this._pdfInfo = pdfInfo; - this._transport = transport; - } - get annotationStorage() { - return this._transport.annotationStorage; - } - get filterFactory() { - return this._transport.filterFactory; - } - get numPages() { - return this._pdfInfo.numPages; - } - get fingerprints() { - return this._pdfInfo.fingerprints; - } - get isPureXfa() { - return shadow(this, "isPureXfa", !!this._transport._htmlForXfa); - } - get allXfaHtml() { - return this._transport._htmlForXfa; - } - getPage(pageNumber) { - return this._transport.getPage(pageNumber); - } - getPageIndex(ref) { - return this._transport.getPageIndex(ref); - } - getDestinations() { - return this._transport.getDestinations(); - } - getDestination(id) { - return this._transport.getDestination(id); - } - getPageLabels() { - return this._transport.getPageLabels(); - } - getPageLayout() { - return this._transport.getPageLayout(); - } - getPageMode() { - return this._transport.getPageMode(); - } - getViewerPreferences() { - return this._transport.getViewerPreferences(); - } - getOpenAction() { - return this._transport.getOpenAction(); - } - getAttachments() { - return this._transport.getAttachments(); - } - getJSActions() { - return this._transport.getDocJSActions(); - } - getOutline() { - return this._transport.getOutline(); - } - getOptionalContentConfig({ - intent = "display" - } = {}) { - const { - renderingIntent - } = this._transport.getRenderingIntent(intent); - return this._transport.getOptionalContentConfig(renderingIntent); - } - getPermissions() { - return this._transport.getPermissions(); - } - getMetadata() { - return this._transport.getMetadata(); - } - getMarkInfo() { - return this._transport.getMarkInfo(); - } - getData() { - return this._transport.getData(); - } - saveDocument() { - return this._transport.saveDocument(); - } - getDownloadInfo() { - return this._transport.downloadInfoCapability.promise; - } - cleanup(keepLoadedFonts = false) { - return this._transport.startCleanup(keepLoadedFonts || this.isPureXfa); - } - destroy() { - return this.loadingTask.destroy(); - } - cachedPageNumber(ref) { - return this._transport.cachedPageNumber(ref); - } - get loadingParams() { - return this._transport.loadingParams; - } - get loadingTask() { - return this._transport.loadingTask; - } - getFieldObjects() { - return this._transport.getFieldObjects(); - } - hasJSActions() { - return this._transport.hasJSActions(); - } - getCalculationOrderIds() { - return this._transport.getCalculationOrderIds(); - } -} -class PDFPageProxy { - #delayedCleanupTimeout = null; - #pendingCleanup = false; - constructor(pageIndex, pageInfo, transport, pdfBug = false) { - this._pageIndex = pageIndex; - this._pageInfo = pageInfo; - this._transport = transport; - this._stats = pdfBug ? new StatTimer() : null; - this._pdfBug = pdfBug; - this.commonObjs = transport.commonObjs; - this.objs = new PDFObjects(); - this._maybeCleanupAfterRender = false; - this._intentStates = new Map(); - this.destroyed = false; - } - get pageNumber() { - return this._pageIndex + 1; - } - get rotate() { - return this._pageInfo.rotate; - } - get ref() { - return this._pageInfo.ref; - } - get userUnit() { - return this._pageInfo.userUnit; - } - get view() { - return this._pageInfo.view; - } - getViewport({ - scale, - rotation = this.rotate, - offsetX = 0, - offsetY = 0, - dontFlip = false - } = {}) { - return new PageViewport({ - viewBox: this.view, - scale, - rotation, - offsetX, - offsetY, - dontFlip - }); - } - getAnnotations({ - intent = "display" - } = {}) { - const { - renderingIntent - } = this._transport.getRenderingIntent(intent); - return this._transport.getAnnotations(this._pageIndex, renderingIntent); - } - getJSActions() { - return this._transport.getPageJSActions(this._pageIndex); - } - get filterFactory() { - return this._transport.filterFactory; - } - get isPureXfa() { - return shadow(this, "isPureXfa", !!this._transport._htmlForXfa); - } - async getXfa() { - return this._transport._htmlForXfa?.children[this._pageIndex] || null; - } - render({ - canvasContext, - viewport, - intent = "display", - annotationMode = AnnotationMode.ENABLE, - transform = null, - background = null, - optionalContentConfigPromise = null, - annotationCanvasMap = null, - pageColors = null, - printAnnotationStorage = null - }) { - this._stats?.time("Overall"); - const intentArgs = this._transport.getRenderingIntent(intent, annotationMode, printAnnotationStorage); - const { - renderingIntent, - cacheKey - } = intentArgs; - this.#pendingCleanup = false; - this.#abortDelayedCleanup(); - optionalContentConfigPromise ||= this._transport.getOptionalContentConfig(renderingIntent); - let intentState = this._intentStates.get(cacheKey); - if (!intentState) { - intentState = Object.create(null); - this._intentStates.set(cacheKey, intentState); - } - if (intentState.streamReaderCancelTimeout) { - clearTimeout(intentState.streamReaderCancelTimeout); - intentState.streamReaderCancelTimeout = null; - } - const intentPrint = !!(renderingIntent & RenderingIntentFlag.PRINT); - if (!intentState.displayReadyCapability) { - intentState.displayReadyCapability = Promise.withResolvers(); - intentState.operatorList = { - fnArray: [], - argsArray: [], - lastChunk: false, - separateAnnots: null - }; - this._stats?.time("Page Request"); - this._pumpOperatorList(intentArgs); - } - const complete = error => { - intentState.renderTasks.delete(internalRenderTask); - if (this._maybeCleanupAfterRender || intentPrint) { - this.#pendingCleanup = true; - } - this.#tryCleanup(!intentPrint); - if (error) { - internalRenderTask.capability.reject(error); - this._abortOperatorList({ - intentState, - reason: error instanceof Error ? error : new Error(error) - }); - } else { - internalRenderTask.capability.resolve(); - } - if (this._stats) { - this._stats.timeEnd("Rendering"); - this._stats.timeEnd("Overall"); - if (globalThis.Stats?.enabled) { - globalThis.Stats.add(this.pageNumber, this._stats); - } - } - }; - const internalRenderTask = new InternalRenderTask({ - callback: complete, - params: { - canvasContext, - viewport, - transform, - background - }, - objs: this.objs, - commonObjs: this.commonObjs, - annotationCanvasMap, - operatorList: intentState.operatorList, - pageIndex: this._pageIndex, - canvasFactory: this._transport.canvasFactory, - filterFactory: this._transport.filterFactory, - useRequestAnimationFrame: !intentPrint, - pdfBug: this._pdfBug, - pageColors - }); - (intentState.renderTasks ||= new Set()).add(internalRenderTask); - const renderTask = internalRenderTask.task; - Promise.all([intentState.displayReadyCapability.promise, optionalContentConfigPromise]).then(([transparency, optionalContentConfig]) => { - if (this.destroyed) { - complete(); - return; - } - this._stats?.time("Rendering"); - if (!(optionalContentConfig.renderingIntent & renderingIntent)) { - throw new Error("Must use the same `intent`-argument when calling the `PDFPageProxy.render` " + "and `PDFDocumentProxy.getOptionalContentConfig` methods."); - } - internalRenderTask.initializeGraphics({ - transparency, - optionalContentConfig - }); - internalRenderTask.operatorListChanged(); - }).catch(complete); - return renderTask; - } - getOperatorList({ - intent = "display", - annotationMode = AnnotationMode.ENABLE, - printAnnotationStorage = null - } = {}) { - function operatorListChanged() { - if (intentState.operatorList.lastChunk) { - intentState.opListReadCapability.resolve(intentState.operatorList); - intentState.renderTasks.delete(opListTask); - } - } - const intentArgs = this._transport.getRenderingIntent(intent, annotationMode, printAnnotationStorage, true); - let intentState = this._intentStates.get(intentArgs.cacheKey); - if (!intentState) { - intentState = Object.create(null); - this._intentStates.set(intentArgs.cacheKey, intentState); - } - let opListTask; - if (!intentState.opListReadCapability) { - opListTask = Object.create(null); - opListTask.operatorListChanged = operatorListChanged; - intentState.opListReadCapability = Promise.withResolvers(); - (intentState.renderTasks ||= new Set()).add(opListTask); - intentState.operatorList = { - fnArray: [], - argsArray: [], - lastChunk: false, - separateAnnots: null - }; - this._stats?.time("Page Request"); - this._pumpOperatorList(intentArgs); - } - return intentState.opListReadCapability.promise; - } - streamTextContent({ - includeMarkedContent = false, - disableNormalization = false - } = {}) { - const TEXT_CONTENT_CHUNK_SIZE = 100; - return this._transport.messageHandler.sendWithStream("GetTextContent", { - pageIndex: this._pageIndex, - includeMarkedContent: includeMarkedContent === true, - disableNormalization: disableNormalization === true - }, { - highWaterMark: TEXT_CONTENT_CHUNK_SIZE, - size(textContent) { - return textContent.items.length; - } - }); - } - getTextContent(params = {}) { - if (this._transport._htmlForXfa) { - return this.getXfa().then(xfa => XfaText.textContent(xfa)); - } - const readableStream = this.streamTextContent(params); - return new Promise(function (resolve, reject) { - function pump() { - reader.read().then(function ({ - value, - done - }) { - if (done) { - resolve(textContent); - return; - } - textContent.lang ??= value.lang; - Object.assign(textContent.styles, value.styles); - textContent.items.push(...value.items); - pump(); - }, reject); - } - const reader = readableStream.getReader(); - const textContent = { - items: [], - styles: Object.create(null), - lang: null - }; - pump(); - }); - } - getStructTree() { - return this._transport.getStructTree(this._pageIndex); - } - _destroy() { - this.destroyed = true; - const waitOn = []; - for (const intentState of this._intentStates.values()) { - this._abortOperatorList({ - intentState, - reason: new Error("Page was destroyed."), - force: true - }); - if (intentState.opListReadCapability) { - continue; - } - for (const internalRenderTask of intentState.renderTasks) { - waitOn.push(internalRenderTask.completed); - internalRenderTask.cancel(); - } - } - this.objs.clear(); - this.#pendingCleanup = false; - this.#abortDelayedCleanup(); - return Promise.all(waitOn); - } - cleanup(resetStats = false) { - this.#pendingCleanup = true; - const success = this.#tryCleanup(false); - if (resetStats && success) { - this._stats &&= new StatTimer(); - } - return success; - } - #tryCleanup(delayed = false) { - this.#abortDelayedCleanup(); - if (!this.#pendingCleanup || this.destroyed) { - return false; - } - if (delayed) { - this.#delayedCleanupTimeout = setTimeout(() => { - this.#delayedCleanupTimeout = null; - this.#tryCleanup(false); - }, DELAYED_CLEANUP_TIMEOUT); - return false; - } - for (const { - renderTasks, - operatorList - } of this._intentStates.values()) { - if (renderTasks.size > 0 || !operatorList.lastChunk) { - return false; - } - } - this._intentStates.clear(); - this.objs.clear(); - this.#pendingCleanup = false; - return true; - } - #abortDelayedCleanup() { - if (this.#delayedCleanupTimeout) { - clearTimeout(this.#delayedCleanupTimeout); - this.#delayedCleanupTimeout = null; - } - } - _startRenderPage(transparency, cacheKey) { - const intentState = this._intentStates.get(cacheKey); - if (!intentState) { - return; - } - this._stats?.timeEnd("Page Request"); - intentState.displayReadyCapability?.resolve(transparency); - } - _renderPageChunk(operatorListChunk, intentState) { - for (let i = 0, ii = operatorListChunk.length; i < ii; i++) { - intentState.operatorList.fnArray.push(operatorListChunk.fnArray[i]); - intentState.operatorList.argsArray.push(operatorListChunk.argsArray[i]); - } - intentState.operatorList.lastChunk = operatorListChunk.lastChunk; - intentState.operatorList.separateAnnots = operatorListChunk.separateAnnots; - for (const internalRenderTask of intentState.renderTasks) { - internalRenderTask.operatorListChanged(); - } - if (operatorListChunk.lastChunk) { - this.#tryCleanup(true); - } - } - _pumpOperatorList({ - renderingIntent, - cacheKey, - annotationStorageSerializable - }) { - const { - map, - transfer - } = annotationStorageSerializable; - const readableStream = this._transport.messageHandler.sendWithStream("GetOperatorList", { - pageIndex: this._pageIndex, - intent: renderingIntent, - cacheKey, - annotationStorage: map - }, transfer); - const reader = readableStream.getReader(); - const intentState = this._intentStates.get(cacheKey); - intentState.streamReader = reader; - const pump = () => { - reader.read().then(({ - value, - done - }) => { - if (done) { - intentState.streamReader = null; - return; - } - if (this._transport.destroyed) { - return; - } - this._renderPageChunk(value, intentState); - pump(); - }, reason => { - intentState.streamReader = null; - if (this._transport.destroyed) { - return; - } - if (intentState.operatorList) { - intentState.operatorList.lastChunk = true; - for (const internalRenderTask of intentState.renderTasks) { - internalRenderTask.operatorListChanged(); - } - this.#tryCleanup(true); - } - if (intentState.displayReadyCapability) { - intentState.displayReadyCapability.reject(reason); - } else if (intentState.opListReadCapability) { - intentState.opListReadCapability.reject(reason); - } else { - throw reason; - } - }); - }; - pump(); - } - _abortOperatorList({ - intentState, - reason, - force = false - }) { - if (!intentState.streamReader) { - return; - } - if (intentState.streamReaderCancelTimeout) { - clearTimeout(intentState.streamReaderCancelTimeout); - intentState.streamReaderCancelTimeout = null; - } - if (!force) { - if (intentState.renderTasks.size > 0) { - return; - } - if (reason instanceof RenderingCancelledException) { - let delay = RENDERING_CANCELLED_TIMEOUT; - if (reason.extraDelay > 0 && reason.extraDelay < 1000) { - delay += reason.extraDelay; - } - intentState.streamReaderCancelTimeout = setTimeout(() => { - intentState.streamReaderCancelTimeout = null; - this._abortOperatorList({ - intentState, - reason, - force: true - }); - }, delay); - return; - } - } - intentState.streamReader.cancel(new AbortException(reason.message)).catch(() => {}); - intentState.streamReader = null; - if (this._transport.destroyed) { - return; - } - for (const [curCacheKey, curIntentState] of this._intentStates) { - if (curIntentState === intentState) { - this._intentStates.delete(curCacheKey); - break; - } - } - this.cleanup(); - } - get stats() { - return this._stats; - } -} -class LoopbackPort { - #listeners = new Set(); - #deferred = Promise.resolve(); - postMessage(obj, transfer) { - const event = { - data: structuredClone(obj, transfer ? { - transfer - } : null) - }; - this.#deferred.then(() => { - for (const listener of this.#listeners) { - listener.call(this, event); - } - }); - } - addEventListener(name, listener) { - this.#listeners.add(listener); - } - removeEventListener(name, listener) { - this.#listeners.delete(listener); - } - terminate() { - this.#listeners.clear(); - } -} -const PDFWorkerUtil = { - isWorkerDisabled: false, - fakeWorkerId: 0 -}; -{ - if (isNodeJS) { - PDFWorkerUtil.isWorkerDisabled = true; - GlobalWorkerOptions.workerSrc ||= "./pdf.worker.mjs"; - } - PDFWorkerUtil.isSameOrigin = function (baseUrl, otherUrl) { - let base; - try { - base = new URL(baseUrl); - if (!base.origin || base.origin === "null") { - return false; - } - } catch { - return false; - } - const other = new URL(otherUrl, base); - return base.origin === other.origin; - }; - PDFWorkerUtil.createCDNWrapper = function (url) { - const wrapper = `await import("${url}");`; - return URL.createObjectURL(new Blob([wrapper], { - type: "text/javascript" - })); - }; -} -class PDFWorker { - static #workerPorts; - constructor({ - name = null, - port = null, - verbosity = getVerbosityLevel() - } = {}) { - this.name = name; - this.destroyed = false; - this.verbosity = verbosity; - this._readyCapability = Promise.withResolvers(); - this._port = null; - this._webWorker = null; - this._messageHandler = null; - if (port) { - if (PDFWorker.#workerPorts?.has(port)) { - throw new Error("Cannot use more than one PDFWorker per port."); - } - (PDFWorker.#workerPorts ||= new WeakMap()).set(port, this); - this._initializeFromPort(port); - return; - } - this._initialize(); - } - get promise() { - if (isNodeJS) { - return Promise.all([NodePackages.promise, this._readyCapability.promise]); - } - return this._readyCapability.promise; - } - #resolve() { - this._readyCapability.resolve(); - this._messageHandler.send("configure", { - verbosity: this.verbosity - }); - } - get port() { - return this._port; - } - get messageHandler() { - return this._messageHandler; - } - _initializeFromPort(port) { - this._port = port; - this._messageHandler = new MessageHandler("main", "worker", port); - this._messageHandler.on("ready", function () {}); - this.#resolve(); - } - _initialize() { - if (PDFWorkerUtil.isWorkerDisabled || PDFWorker.#mainThreadWorkerMessageHandler) { - this._setupFakeWorker(); - return; - } - let { - workerSrc - } = PDFWorker; - try { - if (!PDFWorkerUtil.isSameOrigin(window.location.href, workerSrc)) { - workerSrc = PDFWorkerUtil.createCDNWrapper(new URL(workerSrc, window.location).href); - } - const worker = new Worker(workerSrc, { - type: "module" - }); - const messageHandler = new MessageHandler("main", "worker", worker); - const terminateEarly = () => { - ac.abort(); - messageHandler.destroy(); - worker.terminate(); - if (this.destroyed) { - this._readyCapability.reject(new Error("Worker was destroyed")); - } else { - this._setupFakeWorker(); - } - }; - const ac = new AbortController(); - worker.addEventListener("error", () => { - if (!this._webWorker) { - terminateEarly(); - } - }, { - signal: ac.signal - }); - messageHandler.on("test", data => { - ac.abort(); - if (this.destroyed || !data) { - terminateEarly(); - return; - } - this._messageHandler = messageHandler; - this._port = worker; - this._webWorker = worker; - this.#resolve(); - }); - messageHandler.on("ready", data => { - ac.abort(); - if (this.destroyed) { - terminateEarly(); - return; - } - try { - sendTest(); - } catch { - this._setupFakeWorker(); - } - }); - const sendTest = () => { - const testObj = new Uint8Array(); - messageHandler.send("test", testObj, [testObj.buffer]); - }; - sendTest(); - return; - } catch { - info("The worker has been disabled."); - } - this._setupFakeWorker(); - } - _setupFakeWorker() { - if (!PDFWorkerUtil.isWorkerDisabled) { - warn("Setting up fake worker."); - PDFWorkerUtil.isWorkerDisabled = true; - } - PDFWorker._setupFakeWorkerGlobal.then(WorkerMessageHandler => { - if (this.destroyed) { - this._readyCapability.reject(new Error("Worker was destroyed")); - return; - } - const port = new LoopbackPort(); - this._port = port; - const id = `fake${PDFWorkerUtil.fakeWorkerId++}`; - const workerHandler = new MessageHandler(id + "_worker", id, port); - WorkerMessageHandler.setup(workerHandler, port); - this._messageHandler = new MessageHandler(id, id + "_worker", port); - this.#resolve(); - }).catch(reason => { - this._readyCapability.reject(new Error(`Setting up fake worker failed: "${reason.message}".`)); - }); - } - destroy() { - this.destroyed = true; - if (this._webWorker) { - this._webWorker.terminate(); - this._webWorker = null; - } - PDFWorker.#workerPorts?.delete(this._port); - this._port = null; - if (this._messageHandler) { - this._messageHandler.destroy(); - this._messageHandler = null; - } - } - static fromPort(params) { - if (!params?.port) { - throw new Error("PDFWorker.fromPort - invalid method signature."); - } - const cachedPort = this.#workerPorts?.get(params.port); - if (cachedPort) { - if (cachedPort._pendingDestroy) { - throw new Error("PDFWorker.fromPort - the worker is being destroyed.\n" + "Please remember to await `PDFDocumentLoadingTask.destroy()`-calls."); - } - return cachedPort; - } - return new PDFWorker(params); - } - static get workerSrc() { - if (GlobalWorkerOptions.workerSrc) { - return GlobalWorkerOptions.workerSrc; - } - throw new Error('No "GlobalWorkerOptions.workerSrc" specified.'); - } - static get #mainThreadWorkerMessageHandler() { - try { - return globalThis.pdfjsWorker?.WorkerMessageHandler || null; - } catch { - return null; - } - } - static get _setupFakeWorkerGlobal() { - const loader = async () => { - if (this.#mainThreadWorkerMessageHandler) { - return this.#mainThreadWorkerMessageHandler; - } - const worker = await import( /*webpackIgnore: true*/this.workerSrc); - return worker.WorkerMessageHandler; - }; - return shadow(this, "_setupFakeWorkerGlobal", loader()); - } -} -class WorkerTransport { - #methodPromises = new Map(); - #pageCache = new Map(); - #pagePromises = new Map(); - #pageRefCache = new Map(); - #passwordCapability = null; - constructor(messageHandler, loadingTask, networkStream, params, factory) { - this.messageHandler = messageHandler; - this.loadingTask = loadingTask; - this.commonObjs = new PDFObjects(); - this.fontLoader = new FontLoader({ - ownerDocument: params.ownerDocument, - styleElement: params.styleElement - }); - this.loadingParams = params.loadingParams; - this._params = params; - this.canvasFactory = factory.canvasFactory; - this.filterFactory = factory.filterFactory; - this.cMapReaderFactory = factory.cMapReaderFactory; - this.standardFontDataFactory = factory.standardFontDataFactory; - this.destroyed = false; - this.destroyCapability = null; - this._networkStream = networkStream; - this._fullReader = null; - this._lastProgress = null; - this.downloadInfoCapability = Promise.withResolvers(); - this.setupMessageHandler(); - } - #cacheSimpleMethod(name, data = null) { - const cachedPromise = this.#methodPromises.get(name); - if (cachedPromise) { - return cachedPromise; - } - const promise = this.messageHandler.sendWithPromise(name, data); - this.#methodPromises.set(name, promise); - return promise; - } - get annotationStorage() { - return shadow(this, "annotationStorage", new AnnotationStorage()); - } - getRenderingIntent(intent, annotationMode = AnnotationMode.ENABLE, printAnnotationStorage = null, isOpList = false) { - let renderingIntent = RenderingIntentFlag.DISPLAY; - let annotationStorageSerializable = SerializableEmpty; - switch (intent) { - case "any": - renderingIntent = RenderingIntentFlag.ANY; - break; - case "display": - break; - case "print": - renderingIntent = RenderingIntentFlag.PRINT; - break; - default: - warn(`getRenderingIntent - invalid intent: ${intent}`); - } - switch (annotationMode) { - case AnnotationMode.DISABLE: - renderingIntent += RenderingIntentFlag.ANNOTATIONS_DISABLE; - break; - case AnnotationMode.ENABLE: - break; - case AnnotationMode.ENABLE_FORMS: - renderingIntent += RenderingIntentFlag.ANNOTATIONS_FORMS; - break; - case AnnotationMode.ENABLE_STORAGE: - renderingIntent += RenderingIntentFlag.ANNOTATIONS_STORAGE; - const annotationStorage = renderingIntent & RenderingIntentFlag.PRINT && printAnnotationStorage instanceof PrintAnnotationStorage ? printAnnotationStorage : this.annotationStorage; - annotationStorageSerializable = annotationStorage.serializable; - break; - default: - warn(`getRenderingIntent - invalid annotationMode: ${annotationMode}`); - } - if (isOpList) { - renderingIntent += RenderingIntentFlag.OPLIST; - } - return { - renderingIntent, - cacheKey: `${renderingIntent}_${annotationStorageSerializable.hash}`, - annotationStorageSerializable - }; - } - destroy() { - if (this.destroyCapability) { - return this.destroyCapability.promise; - } - this.destroyed = true; - this.destroyCapability = Promise.withResolvers(); - this.#passwordCapability?.reject(new Error("Worker was destroyed during onPassword callback")); - const waitOn = []; - for (const page of this.#pageCache.values()) { - waitOn.push(page._destroy()); - } - this.#pageCache.clear(); - this.#pagePromises.clear(); - this.#pageRefCache.clear(); - if (this.hasOwnProperty("annotationStorage")) { - this.annotationStorage.resetModified(); - } - const terminated = this.messageHandler.sendWithPromise("Terminate", null); - waitOn.push(terminated); - Promise.all(waitOn).then(() => { - this.commonObjs.clear(); - this.fontLoader.clear(); - this.#methodPromises.clear(); - this.filterFactory.destroy(); - TextLayer.cleanup(); - this._networkStream?.cancelAllRequests(new AbortException("Worker was terminated.")); - if (this.messageHandler) { - this.messageHandler.destroy(); - this.messageHandler = null; - } - this.destroyCapability.resolve(); - }, this.destroyCapability.reject); - return this.destroyCapability.promise; - } - setupMessageHandler() { - const { - messageHandler, - loadingTask - } = this; - messageHandler.on("GetReader", (data, sink) => { - assert(this._networkStream, "GetReader - no `IPDFStream` instance available."); - this._fullReader = this._networkStream.getFullReader(); - this._fullReader.onProgress = evt => { - this._lastProgress = { - loaded: evt.loaded, - total: evt.total - }; - }; - sink.onPull = () => { - this._fullReader.read().then(function ({ - value, - done - }) { - if (done) { - sink.close(); - return; - } - assert(value instanceof ArrayBuffer, "GetReader - expected an ArrayBuffer."); - sink.enqueue(new Uint8Array(value), 1, [value]); - }).catch(reason => { - sink.error(reason); - }); - }; - sink.onCancel = reason => { - this._fullReader.cancel(reason); - sink.ready.catch(readyReason => { - if (this.destroyed) { - return; - } - throw readyReason; - }); - }; - }); - messageHandler.on("ReaderHeadersReady", data => { - const headersCapability = Promise.withResolvers(); - const fullReader = this._fullReader; - fullReader.headersReady.then(() => { - if (!fullReader.isStreamingSupported || !fullReader.isRangeSupported) { - if (this._lastProgress) { - loadingTask.onProgress?.(this._lastProgress); - } - fullReader.onProgress = evt => { - loadingTask.onProgress?.({ - loaded: evt.loaded, - total: evt.total - }); - }; - } - headersCapability.resolve({ - isStreamingSupported: fullReader.isStreamingSupported, - isRangeSupported: fullReader.isRangeSupported, - contentLength: fullReader.contentLength - }); - }, headersCapability.reject); - return headersCapability.promise; - }); - messageHandler.on("GetRangeReader", (data, sink) => { - assert(this._networkStream, "GetRangeReader - no `IPDFStream` instance available."); - const rangeReader = this._networkStream.getRangeReader(data.begin, data.end); - if (!rangeReader) { - sink.close(); - return; - } - sink.onPull = () => { - rangeReader.read().then(function ({ - value, - done - }) { - if (done) { - sink.close(); - return; - } - assert(value instanceof ArrayBuffer, "GetRangeReader - expected an ArrayBuffer."); - sink.enqueue(new Uint8Array(value), 1, [value]); - }).catch(reason => { - sink.error(reason); - }); - }; - sink.onCancel = reason => { - rangeReader.cancel(reason); - sink.ready.catch(readyReason => { - if (this.destroyed) { - return; - } - throw readyReason; - }); - }; - }); - messageHandler.on("GetDoc", ({ - pdfInfo - }) => { - this._numPages = pdfInfo.numPages; - this._htmlForXfa = pdfInfo.htmlForXfa; - delete pdfInfo.htmlForXfa; - loadingTask._capability.resolve(new PDFDocumentProxy(pdfInfo, this)); - }); - messageHandler.on("DocException", function (ex) { - let reason; - switch (ex.name) { - case "PasswordException": - reason = new PasswordException(ex.message, ex.code); - break; - case "InvalidPDFException": - reason = new InvalidPDFException(ex.message); - break; - case "MissingPDFException": - reason = new MissingPDFException(ex.message); - break; - case "UnexpectedResponseException": - reason = new UnexpectedResponseException(ex.message, ex.status); - break; - case "UnknownErrorException": - reason = new UnknownErrorException(ex.message, ex.details); - break; - default: - unreachable("DocException - expected a valid Error."); - } - loadingTask._capability.reject(reason); - }); - messageHandler.on("PasswordRequest", exception => { - this.#passwordCapability = Promise.withResolvers(); - if (loadingTask.onPassword) { - const updatePassword = password => { - if (password instanceof Error) { - this.#passwordCapability.reject(password); - } else { - this.#passwordCapability.resolve({ - password - }); - } - }; - try { - loadingTask.onPassword(updatePassword, exception.code); - } catch (ex) { - this.#passwordCapability.reject(ex); - } - } else { - this.#passwordCapability.reject(new PasswordException(exception.message, exception.code)); - } - return this.#passwordCapability.promise; - }); - messageHandler.on("DataLoaded", data => { - loadingTask.onProgress?.({ - loaded: data.length, - total: data.length - }); - this.downloadInfoCapability.resolve(data); - }); - messageHandler.on("StartRenderPage", data => { - if (this.destroyed) { - return; - } - const page = this.#pageCache.get(data.pageIndex); - page._startRenderPage(data.transparency, data.cacheKey); - }); - messageHandler.on("commonobj", ([id, type, exportedData]) => { - if (this.destroyed) { - return null; - } - if (this.commonObjs.has(id)) { - return null; - } - switch (type) { - case "Font": - const { - disableFontFace, - fontExtraProperties, - pdfBug - } = this._params; - if ("error" in exportedData) { - const exportedError = exportedData.error; - warn(`Error during font loading: ${exportedError}`); - this.commonObjs.resolve(id, exportedError); - break; - } - const inspectFont = pdfBug && globalThis.FontInspector?.enabled ? (font, url) => globalThis.FontInspector.fontAdded(font, url) : null; - const font = new FontFaceObject(exportedData, { - disableFontFace, - inspectFont - }); - this.fontLoader.bind(font).catch(() => messageHandler.sendWithPromise("FontFallback", { - id - })).finally(() => { - if (!fontExtraProperties && font.data) { - font.data = null; - } - this.commonObjs.resolve(id, font); - }); - break; - case "CopyLocalImage": - const { - imageRef - } = exportedData; - assert(imageRef, "The imageRef must be defined."); - for (const pageProxy of this.#pageCache.values()) { - for (const [, data] of pageProxy.objs) { - if (data?.ref !== imageRef) { - continue; - } - if (!data.dataLen) { - return null; - } - this.commonObjs.resolve(id, structuredClone(data)); - return data.dataLen; - } - } - break; - case "FontPath": - case "Image": - case "Pattern": - this.commonObjs.resolve(id, exportedData); - break; - default: - throw new Error(`Got unknown common object type ${type}`); - } - return null; - }); - messageHandler.on("obj", ([id, pageIndex, type, imageData]) => { - if (this.destroyed) { - return; - } - const pageProxy = this.#pageCache.get(pageIndex); - if (pageProxy.objs.has(id)) { - return; - } - if (pageProxy._intentStates.size === 0) { - imageData?.bitmap?.close(); - return; - } - switch (type) { - case "Image": - pageProxy.objs.resolve(id, imageData); - if (imageData?.dataLen > MAX_IMAGE_SIZE_TO_CACHE) { - pageProxy._maybeCleanupAfterRender = true; - } - break; - case "Pattern": - pageProxy.objs.resolve(id, imageData); - break; - default: - throw new Error(`Got unknown object type ${type}`); - } - }); - messageHandler.on("DocProgress", data => { - if (this.destroyed) { - return; - } - loadingTask.onProgress?.({ - loaded: data.loaded, - total: data.total - }); - }); - messageHandler.on("FetchBuiltInCMap", data => { - if (this.destroyed) { - return Promise.reject(new Error("Worker was destroyed.")); - } - if (!this.cMapReaderFactory) { - return Promise.reject(new Error("CMapReaderFactory not initialized, see the `useWorkerFetch` parameter.")); - } - return this.cMapReaderFactory.fetch(data); - }); - messageHandler.on("FetchStandardFontData", data => { - if (this.destroyed) { - return Promise.reject(new Error("Worker was destroyed.")); - } - if (!this.standardFontDataFactory) { - return Promise.reject(new Error("StandardFontDataFactory not initialized, see the `useWorkerFetch` parameter.")); - } - return this.standardFontDataFactory.fetch(data); - }); - } - getData() { - return this.messageHandler.sendWithPromise("GetData", null); - } - saveDocument() { - if (this.annotationStorage.size <= 0) { - warn("saveDocument called while `annotationStorage` is empty, " + "please use the getData-method instead."); - } - const { - map, - transfer - } = this.annotationStorage.serializable; - return this.messageHandler.sendWithPromise("SaveDocument", { - isPureXfa: !!this._htmlForXfa, - numPages: this._numPages, - annotationStorage: map, - filename: this._fullReader?.filename ?? null - }, transfer).finally(() => { - this.annotationStorage.resetModified(); - }); - } - getPage(pageNumber) { - if (!Number.isInteger(pageNumber) || pageNumber <= 0 || pageNumber > this._numPages) { - return Promise.reject(new Error("Invalid page request.")); - } - const pageIndex = pageNumber - 1, - cachedPromise = this.#pagePromises.get(pageIndex); - if (cachedPromise) { - return cachedPromise; - } - const promise = this.messageHandler.sendWithPromise("GetPage", { - pageIndex - }).then(pageInfo => { - if (this.destroyed) { - throw new Error("Transport destroyed"); - } - if (pageInfo.refStr) { - this.#pageRefCache.set(pageInfo.refStr, pageNumber); - } - const page = new PDFPageProxy(pageIndex, pageInfo, this, this._params.pdfBug); - this.#pageCache.set(pageIndex, page); - return page; - }); - this.#pagePromises.set(pageIndex, promise); - return promise; - } - getPageIndex(ref) { - if (!isRefProxy(ref)) { - return Promise.reject(new Error("Invalid pageIndex request.")); - } - return this.messageHandler.sendWithPromise("GetPageIndex", { - num: ref.num, - gen: ref.gen - }); - } - getAnnotations(pageIndex, intent) { - return this.messageHandler.sendWithPromise("GetAnnotations", { - pageIndex, - intent - }); - } - getFieldObjects() { - return this.#cacheSimpleMethod("GetFieldObjects"); - } - hasJSActions() { - return this.#cacheSimpleMethod("HasJSActions"); - } - getCalculationOrderIds() { - return this.messageHandler.sendWithPromise("GetCalculationOrderIds", null); - } - getDestinations() { - return this.messageHandler.sendWithPromise("GetDestinations", null); - } - getDestination(id) { - if (typeof id !== "string") { - return Promise.reject(new Error("Invalid destination request.")); - } - return this.messageHandler.sendWithPromise("GetDestination", { - id - }); - } - getPageLabels() { - return this.messageHandler.sendWithPromise("GetPageLabels", null); - } - getPageLayout() { - return this.messageHandler.sendWithPromise("GetPageLayout", null); - } - getPageMode() { - return this.messageHandler.sendWithPromise("GetPageMode", null); - } - getViewerPreferences() { - return this.messageHandler.sendWithPromise("GetViewerPreferences", null); - } - getOpenAction() { - return this.messageHandler.sendWithPromise("GetOpenAction", null); - } - getAttachments() { - return this.messageHandler.sendWithPromise("GetAttachments", null); - } - getDocJSActions() { - return this.#cacheSimpleMethod("GetDocJSActions"); - } - getPageJSActions(pageIndex) { - return this.messageHandler.sendWithPromise("GetPageJSActions", { - pageIndex - }); - } - getStructTree(pageIndex) { - return this.messageHandler.sendWithPromise("GetStructTree", { - pageIndex - }); - } - getOutline() { - return this.messageHandler.sendWithPromise("GetOutline", null); - } - getOptionalContentConfig(renderingIntent) { - return this.#cacheSimpleMethod("GetOptionalContentConfig").then(data => new OptionalContentConfig(data, renderingIntent)); - } - getPermissions() { - return this.messageHandler.sendWithPromise("GetPermissions", null); - } - getMetadata() { - const name = "GetMetadata", - cachedPromise = this.#methodPromises.get(name); - if (cachedPromise) { - return cachedPromise; - } - const promise = this.messageHandler.sendWithPromise(name, null).then(results => ({ - info: results[0], - metadata: results[1] ? new Metadata(results[1]) : null, - contentDispositionFilename: this._fullReader?.filename ?? null, - contentLength: this._fullReader?.contentLength ?? null - })); - this.#methodPromises.set(name, promise); - return promise; - } - getMarkInfo() { - return this.messageHandler.sendWithPromise("GetMarkInfo", null); - } - async startCleanup(keepLoadedFonts = false) { - if (this.destroyed) { - return; - } - await this.messageHandler.sendWithPromise("Cleanup", null); - for (const page of this.#pageCache.values()) { - const cleanupSuccessful = page.cleanup(); - if (!cleanupSuccessful) { - throw new Error(`startCleanup: Page ${page.pageNumber} is currently rendering.`); - } - } - this.commonObjs.clear(); - if (!keepLoadedFonts) { - this.fontLoader.clear(); - } - this.#methodPromises.clear(); - this.filterFactory.destroy(true); - TextLayer.cleanup(); - } - cachedPageNumber(ref) { - if (!isRefProxy(ref)) { - return null; - } - const refStr = ref.gen === 0 ? `${ref.num}R` : `${ref.num}R${ref.gen}`; - return this.#pageRefCache.get(refStr) ?? null; - } -} -const INITIAL_DATA = Symbol("INITIAL_DATA"); -class PDFObjects { - #objs = Object.create(null); - #ensureObj(objId) { - return this.#objs[objId] ||= { - ...Promise.withResolvers(), - data: INITIAL_DATA - }; - } - get(objId, callback = null) { - if (callback) { - const obj = this.#ensureObj(objId); - obj.promise.then(() => callback(obj.data)); - return null; - } - const obj = this.#objs[objId]; - if (!obj || obj.data === INITIAL_DATA) { - throw new Error(`Requesting object that isn't resolved yet ${objId}.`); - } - return obj.data; - } - has(objId) { - const obj = this.#objs[objId]; - return !!obj && obj.data !== INITIAL_DATA; - } - resolve(objId, data = null) { - const obj = this.#ensureObj(objId); - obj.data = data; - obj.resolve(); - } - clear() { - for (const objId in this.#objs) { - const { - data - } = this.#objs[objId]; - data?.bitmap?.close(); - } - this.#objs = Object.create(null); - } - *[Symbol.iterator]() { - for (const objId in this.#objs) { - const { - data - } = this.#objs[objId]; - if (data === INITIAL_DATA) { - continue; - } - yield [objId, data]; - } - } -} -class RenderTask { - #internalRenderTask = null; - constructor(internalRenderTask) { - this.#internalRenderTask = internalRenderTask; - this.onContinue = null; - } - get promise() { - return this.#internalRenderTask.capability.promise; - } - cancel(extraDelay = 0) { - this.#internalRenderTask.cancel(null, extraDelay); - } - get separateAnnots() { - const { - separateAnnots - } = this.#internalRenderTask.operatorList; - if (!separateAnnots) { - return false; - } - const { - annotationCanvasMap - } = this.#internalRenderTask; - return separateAnnots.form || separateAnnots.canvas && annotationCanvasMap?.size > 0; - } -} -class InternalRenderTask { - static #canvasInUse = new WeakSet(); - constructor({ - callback, - params, - objs, - commonObjs, - annotationCanvasMap, - operatorList, - pageIndex, - canvasFactory, - filterFactory, - useRequestAnimationFrame = false, - pdfBug = false, - pageColors = null - }) { - this.callback = callback; - this.params = params; - this.objs = objs; - this.commonObjs = commonObjs; - this.annotationCanvasMap = annotationCanvasMap; - this.operatorListIdx = null; - this.operatorList = operatorList; - this._pageIndex = pageIndex; - this.canvasFactory = canvasFactory; - this.filterFactory = filterFactory; - this._pdfBug = pdfBug; - this.pageColors = pageColors; - this.running = false; - this.graphicsReadyCallback = null; - this.graphicsReady = false; - this._useRequestAnimationFrame = useRequestAnimationFrame === true && typeof window !== "undefined"; - this.cancelled = false; - this.capability = Promise.withResolvers(); - this.task = new RenderTask(this); - this._cancelBound = this.cancel.bind(this); - this._continueBound = this._continue.bind(this); - this._scheduleNextBound = this._scheduleNext.bind(this); - this._nextBound = this._next.bind(this); - this._canvas = params.canvasContext.canvas; - } - get completed() { - return this.capability.promise.catch(function () {}); - } - initializeGraphics({ - transparency = false, - optionalContentConfig - }) { - if (this.cancelled) { - return; - } - if (this._canvas) { - if (InternalRenderTask.#canvasInUse.has(this._canvas)) { - throw new Error("Cannot use the same canvas during multiple render() operations. " + "Use different canvas or ensure previous operations were " + "cancelled or completed."); - } - InternalRenderTask.#canvasInUse.add(this._canvas); - } - if (this._pdfBug && globalThis.StepperManager?.enabled) { - this.stepper = globalThis.StepperManager.create(this._pageIndex); - this.stepper.init(this.operatorList); - this.stepper.nextBreakPoint = this.stepper.getNextBreakPoint(); - } - const { - canvasContext, - viewport, - transform, - background - } = this.params; - this.gfx = new CanvasGraphics(canvasContext, this.commonObjs, this.objs, this.canvasFactory, this.filterFactory, { - optionalContentConfig - }, this.annotationCanvasMap, this.pageColors); - this.gfx.beginDrawing({ - transform, - viewport, - transparency, - background - }); - this.operatorListIdx = 0; - this.graphicsReady = true; - this.graphicsReadyCallback?.(); - } - cancel(error = null, extraDelay = 0) { - this.running = false; - this.cancelled = true; - this.gfx?.endDrawing(); - InternalRenderTask.#canvasInUse.delete(this._canvas); - this.callback(error || new RenderingCancelledException(`Rendering cancelled, page ${this._pageIndex + 1}`, extraDelay)); - } - operatorListChanged() { - if (!this.graphicsReady) { - this.graphicsReadyCallback ||= this._continueBound; - return; - } - this.stepper?.updateOperatorList(this.operatorList); - if (this.running) { - return; - } - this._continue(); - } - _continue() { - this.running = true; - if (this.cancelled) { - return; - } - if (this.task.onContinue) { - this.task.onContinue(this._scheduleNextBound); - } else { - this._scheduleNext(); - } - } - _scheduleNext() { - if (this._useRequestAnimationFrame) { - window.requestAnimationFrame(() => { - this._nextBound().catch(this._cancelBound); - }); - } else { - Promise.resolve().then(this._nextBound).catch(this._cancelBound); - } - } - async _next() { - if (this.cancelled) { - return; - } - this.operatorListIdx = this.gfx.executeOperatorList(this.operatorList, this.operatorListIdx, this._continueBound, this.stepper); - if (this.operatorListIdx === this.operatorList.argsArray.length) { - this.running = false; - if (this.operatorList.lastChunk) { - this.gfx.endDrawing(); - InternalRenderTask.#canvasInUse.delete(this._canvas); - this.callback(); - } - } - } -} -const version = "4.4.82"; -const build = "8c6cee28e"; - -// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.flat-map.js -var esnext_iterator_flat_map = __webpack_require__(670); -;// CONCATENATED MODULE: ./src/shared/scripting_utils.js - -function makeColorComp(n) { - return Math.floor(Math.max(0, Math.min(1, n)) * 255).toString(16).padStart(2, "0"); -} -function scaleAndClamp(x) { - return Math.max(0, Math.min(255, 255 * x)); -} -class ColorConverters { - static CMYK_G([c, y, m, k]) { - return ["G", 1 - Math.min(1, 0.3 * c + 0.59 * m + 0.11 * y + k)]; - } - static G_CMYK([g]) { - return ["CMYK", 0, 0, 0, 1 - g]; - } - static G_RGB([g]) { - return ["RGB", g, g, g]; - } - static G_rgb([g]) { - g = scaleAndClamp(g); - return [g, g, g]; - } - static G_HTML([g]) { - const G = makeColorComp(g); - return `#${G}${G}${G}`; - } - static RGB_G([r, g, b]) { - return ["G", 0.3 * r + 0.59 * g + 0.11 * b]; - } - static RGB_rgb(color) { - return color.map(scaleAndClamp); - } - static RGB_HTML(color) { - return `#${color.map(makeColorComp).join("")}`; - } - static T_HTML() { - return "#00000000"; - } - static T_rgb() { - return [null]; - } - static CMYK_RGB([c, y, m, k]) { - return ["RGB", 1 - Math.min(1, c + k), 1 - Math.min(1, m + k), 1 - Math.min(1, y + k)]; - } - static CMYK_rgb([c, y, m, k]) { - return [scaleAndClamp(1 - Math.min(1, c + k)), scaleAndClamp(1 - Math.min(1, m + k)), scaleAndClamp(1 - Math.min(1, y + k))]; - } - static CMYK_HTML(components) { - const rgb = this.CMYK_RGB(components).slice(1); - return this.RGB_HTML(rgb); - } - static RGB_CMYK([r, g, b]) { - const c = 1 - r; - const m = 1 - g; - const y = 1 - b; - const k = Math.min(c, m, y); - return ["CMYK", c, m, y, k]; - } -} - -;// CONCATENATED MODULE: ./src/display/xfa_layer.js - - -class XfaLayer { - static setupStorage(html, id, element, storage, intent) { - const storedData = storage.getValue(id, { - value: null - }); - switch (element.name) { - case "textarea": - if (storedData.value !== null) { - html.textContent = storedData.value; - } - if (intent === "print") { - break; - } - html.addEventListener("input", event => { - storage.setValue(id, { - value: event.target.value - }); - }); - break; - case "input": - if (element.attributes.type === "radio" || element.attributes.type === "checkbox") { - if (storedData.value === element.attributes.xfaOn) { - html.setAttribute("checked", true); - } else if (storedData.value === element.attributes.xfaOff) { - html.removeAttribute("checked"); - } - if (intent === "print") { - break; - } - html.addEventListener("change", event => { - storage.setValue(id, { - value: event.target.checked ? event.target.getAttribute("xfaOn") : event.target.getAttribute("xfaOff") - }); - }); - } else { - if (storedData.value !== null) { - html.setAttribute("value", storedData.value); - } - if (intent === "print") { - break; - } - html.addEventListener("input", event => { - storage.setValue(id, { - value: event.target.value - }); - }); - } - break; - case "select": - if (storedData.value !== null) { - html.setAttribute("value", storedData.value); - for (const option of element.children) { - if (option.attributes.value === storedData.value) { - option.attributes.selected = true; - } else if (option.attributes.hasOwnProperty("selected")) { - delete option.attributes.selected; - } - } - } - html.addEventListener("input", event => { - const options = event.target.options; - const value = options.selectedIndex === -1 ? "" : options[options.selectedIndex].value; - storage.setValue(id, { - value - }); - }); - break; - } - } - static setAttributes({ - html, - element, - storage = null, - intent, - linkService - }) { - const { - attributes - } = element; - const isHTMLAnchorElement = html instanceof HTMLAnchorElement; - if (attributes.type === "radio") { - attributes.name = `${attributes.name}-${intent}`; - } - for (const [key, value] of Object.entries(attributes)) { - if (value === null || value === undefined) { - continue; - } - switch (key) { - case "class": - if (value.length) { - html.setAttribute(key, value.join(" ")); - } - break; - case "dataId": - break; - case "id": - html.setAttribute("data-element-id", value); - break; - case "style": - Object.assign(html.style, value); - break; - case "textContent": - html.textContent = value; - break; - default: - if (!isHTMLAnchorElement || key !== "href" && key !== "newWindow") { - html.setAttribute(key, value); - } - } - } - if (isHTMLAnchorElement) { - linkService.addLinkAttributes(html, attributes.href, attributes.newWindow); - } - if (storage && attributes.dataId) { - this.setupStorage(html, attributes.dataId, element, storage); - } - } - static render(parameters) { - const storage = parameters.annotationStorage; - const linkService = parameters.linkService; - const root = parameters.xfaHtml; - const intent = parameters.intent || "display"; - const rootHtml = document.createElement(root.name); - if (root.attributes) { - this.setAttributes({ - html: rootHtml, - element: root, - intent, - linkService - }); - } - const isNotForRichText = intent !== "richText"; - const rootDiv = parameters.div; - rootDiv.append(rootHtml); - if (parameters.viewport) { - const transform = `matrix(${parameters.viewport.transform.join(",")})`; - rootDiv.style.transform = transform; - } - if (isNotForRichText) { - rootDiv.setAttribute("class", "xfaLayer xfaFont"); - } - const textDivs = []; - if (root.children.length === 0) { - if (root.value) { - const node = document.createTextNode(root.value); - rootHtml.append(node); - if (isNotForRichText && XfaText.shouldBuildText(root.name)) { - textDivs.push(node); - } - } - return { - textDivs - }; - } - const stack = [[root, -1, rootHtml]]; - while (stack.length > 0) { - const [parent, i, html] = stack.at(-1); - if (i + 1 === parent.children.length) { - stack.pop(); - continue; - } - const child = parent.children[++stack.at(-1)[1]]; - if (child === null) { - continue; - } - const { - name - } = child; - if (name === "#text") { - const node = document.createTextNode(child.value); - textDivs.push(node); - html.append(node); - continue; - } - const childHtml = child?.attributes?.xmlns ? document.createElementNS(child.attributes.xmlns, name) : document.createElement(name); - html.append(childHtml); - if (child.attributes) { - this.setAttributes({ - html: childHtml, - element: child, - storage, - intent, - linkService - }); - } - if (child.children?.length > 0) { - stack.push([child, -1, childHtml]); - } else if (child.value) { - const node = document.createTextNode(child.value); - if (isNotForRichText && XfaText.shouldBuildText(name)) { - textDivs.push(node); - } - childHtml.append(node); - } - } - for (const el of rootDiv.querySelectorAll(".xfaNonInteractive input, .xfaNonInteractive textarea")) { - el.setAttribute("readOnly", true); - } - return { - textDivs - }; - } - static update(parameters) { - const transform = `matrix(${parameters.viewport.transform.join(",")})`; - parameters.div.style.transform = transform; - parameters.div.hidden = false; - } -} - -;// CONCATENATED MODULE: ./src/display/annotation_layer.js - - - - - - - - - - - - - - - - -const DEFAULT_TAB_INDEX = 1000; -const annotation_layer_DEFAULT_FONT_SIZE = 9; -const GetElementsByNameSet = new WeakSet(); -function getRectDims(rect) { - return { - width: rect[2] - rect[0], - height: rect[3] - rect[1] - }; -} -class AnnotationElementFactory { - static create(parameters) { - const subtype = parameters.data.annotationType; - switch (subtype) { - case AnnotationType.LINK: - return new LinkAnnotationElement(parameters); - case AnnotationType.TEXT: - return new TextAnnotationElement(parameters); - case AnnotationType.WIDGET: - const fieldType = parameters.data.fieldType; - switch (fieldType) { - case "Tx": - return new TextWidgetAnnotationElement(parameters); - case "Btn": - if (parameters.data.radioButton) { - return new RadioButtonWidgetAnnotationElement(parameters); - } else if (parameters.data.checkBox) { - return new CheckboxWidgetAnnotationElement(parameters); - } - return new PushButtonWidgetAnnotationElement(parameters); - case "Ch": - return new ChoiceWidgetAnnotationElement(parameters); - case "Sig": - return new SignatureWidgetAnnotationElement(parameters); - } - return new WidgetAnnotationElement(parameters); - case AnnotationType.POPUP: - return new PopupAnnotationElement(parameters); - case AnnotationType.FREETEXT: - return new FreeTextAnnotationElement(parameters); - case AnnotationType.LINE: - return new LineAnnotationElement(parameters); - case AnnotationType.SQUARE: - return new SquareAnnotationElement(parameters); - case AnnotationType.CIRCLE: - return new CircleAnnotationElement(parameters); - case AnnotationType.POLYLINE: - return new PolylineAnnotationElement(parameters); - case AnnotationType.CARET: - return new CaretAnnotationElement(parameters); - case AnnotationType.INK: - return new InkAnnotationElement(parameters); - case AnnotationType.POLYGON: - return new PolygonAnnotationElement(parameters); - case AnnotationType.HIGHLIGHT: - return new HighlightAnnotationElement(parameters); - case AnnotationType.UNDERLINE: - return new UnderlineAnnotationElement(parameters); - case AnnotationType.SQUIGGLY: - return new SquigglyAnnotationElement(parameters); - case AnnotationType.STRIKEOUT: - return new StrikeOutAnnotationElement(parameters); - case AnnotationType.STAMP: - return new StampAnnotationElement(parameters); - case AnnotationType.FILEATTACHMENT: - return new FileAttachmentAnnotationElement(parameters); - default: - return new AnnotationElement(parameters); - } - } -} -class AnnotationElement { - #updates = null; - #hasBorder = false; - #popupElement = null; - constructor(parameters, { - isRenderable = false, - ignoreBorder = false, - createQuadrilaterals = false - } = {}) { - this.isRenderable = isRenderable; - this.data = parameters.data; - this.layer = parameters.layer; - this.linkService = parameters.linkService; - this.downloadManager = parameters.downloadManager; - this.imageResourcesPath = parameters.imageResourcesPath; - this.renderForms = parameters.renderForms; - this.svgFactory = parameters.svgFactory; - this.annotationStorage = parameters.annotationStorage; - this.enableScripting = parameters.enableScripting; - this.hasJSActions = parameters.hasJSActions; - this._fieldObjects = parameters.fieldObjects; - this.parent = parameters.parent; - if (isRenderable) { - this.container = this._createContainer(ignoreBorder); - } - if (createQuadrilaterals) { - this._createQuadrilaterals(); - } - } - static _hasPopupData({ - titleObj, - contentsObj, - richText - }) { - return !!(titleObj?.str || contentsObj?.str || richText?.str); - } - get hasPopupData() { - return AnnotationElement._hasPopupData(this.data); - } - updateEdited(params) { - if (!this.container) { - return; - } - this.#updates ||= { - rect: this.data.rect.slice(0) - }; - const { - rect - } = params; - if (rect) { - this.#setRectEdited(rect); - } - this.#popupElement?.popup.updateEdited(params); - } - resetEdited() { - if (!this.#updates) { - return; - } - this.#setRectEdited(this.#updates.rect); - this.#popupElement?.popup.resetEdited(); - this.#updates = null; - } - #setRectEdited(rect) { - const { - container: { - style - }, - data: { - rect: currentRect, - rotation - }, - parent: { - viewport: { - rawDims: { - pageWidth, - pageHeight, - pageX, - pageY - } - } - } - } = this; - currentRect?.splice(0, 4, ...rect); - const { - width, - height - } = getRectDims(rect); - style.left = `${100 * (rect[0] - pageX) / pageWidth}%`; - style.top = `${100 * (pageHeight - rect[3] + pageY) / pageHeight}%`; - if (rotation === 0) { - style.width = `${100 * width / pageWidth}%`; - style.height = `${100 * height / pageHeight}%`; - } else { - this.setRotation(rotation); - } - } - _createContainer(ignoreBorder) { - const { - data, - parent: { - page, - viewport - } - } = this; - const container = document.createElement("section"); - container.setAttribute("data-annotation-id", data.id); - if (!(this instanceof WidgetAnnotationElement)) { - container.tabIndex = DEFAULT_TAB_INDEX; - } - const { - style - } = container; - style.zIndex = this.parent.zIndex++; - if (data.popupRef) { - container.setAttribute("aria-haspopup", "dialog"); - } - if (data.alternativeText) { - container.title = data.alternativeText; - } - if (data.noRotate) { - container.classList.add("norotate"); - } - if (!data.rect || this instanceof PopupAnnotationElement) { - const { - rotation - } = data; - if (!data.hasOwnCanvas && rotation !== 0) { - this.setRotation(rotation, container); - } - return container; - } - const { - width, - height - } = getRectDims(data.rect); - if (!ignoreBorder && data.borderStyle.width > 0) { - style.borderWidth = `${data.borderStyle.width}px`; - const horizontalRadius = data.borderStyle.horizontalCornerRadius; - const verticalRadius = data.borderStyle.verticalCornerRadius; - if (horizontalRadius > 0 || verticalRadius > 0) { - const radius = `calc(${horizontalRadius}px * var(--scale-factor)) / calc(${verticalRadius}px * var(--scale-factor))`; - style.borderRadius = radius; - } else if (this instanceof RadioButtonWidgetAnnotationElement) { - const radius = `calc(${width}px * var(--scale-factor)) / calc(${height}px * var(--scale-factor))`; - style.borderRadius = radius; - } - switch (data.borderStyle.style) { - case AnnotationBorderStyleType.SOLID: - style.borderStyle = "solid"; - break; - case AnnotationBorderStyleType.DASHED: - style.borderStyle = "dashed"; - break; - case AnnotationBorderStyleType.BEVELED: - warn("Unimplemented border style: beveled"); - break; - case AnnotationBorderStyleType.INSET: - warn("Unimplemented border style: inset"); - break; - case AnnotationBorderStyleType.UNDERLINE: - style.borderBottomStyle = "solid"; - break; - default: - break; - } - const borderColor = data.borderColor || null; - if (borderColor) { - this.#hasBorder = true; - style.borderColor = Util.makeHexColor(borderColor[0] | 0, borderColor[1] | 0, borderColor[2] | 0); - } else { - style.borderWidth = 0; - } - } - const rect = Util.normalizeRect([data.rect[0], page.view[3] - data.rect[1] + page.view[1], data.rect[2], page.view[3] - data.rect[3] + page.view[1]]); - const { - pageWidth, - pageHeight, - pageX, - pageY - } = viewport.rawDims; - style.left = `${100 * (rect[0] - pageX) / pageWidth}%`; - style.top = `${100 * (rect[1] - pageY) / pageHeight}%`; - const { - rotation - } = data; - if (data.hasOwnCanvas || rotation === 0) { - style.width = `${100 * width / pageWidth}%`; - style.height = `${100 * height / pageHeight}%`; - } else { - this.setRotation(rotation, container); - } - return container; - } - setRotation(angle, container = this.container) { - if (!this.data.rect) { - return; - } - const { - pageWidth, - pageHeight - } = this.parent.viewport.rawDims; - const { - width, - height - } = getRectDims(this.data.rect); - let elementWidth, elementHeight; - if (angle % 180 === 0) { - elementWidth = 100 * width / pageWidth; - elementHeight = 100 * height / pageHeight; - } else { - elementWidth = 100 * height / pageWidth; - elementHeight = 100 * width / pageHeight; - } - container.style.width = `${elementWidth}%`; - container.style.height = `${elementHeight}%`; - container.setAttribute("data-main-rotation", (360 - angle) % 360); - } - get _commonActions() { - const setColor = (jsName, styleName, event) => { - const color = event.detail[jsName]; - const colorType = color[0]; - const colorArray = color.slice(1); - event.target.style[styleName] = ColorConverters[`${colorType}_HTML`](colorArray); - this.annotationStorage.setValue(this.data.id, { - [styleName]: ColorConverters[`${colorType}_rgb`](colorArray) - }); - }; - return shadow(this, "_commonActions", { - display: event => { - const { - display - } = event.detail; - const hidden = display % 2 === 1; - this.container.style.visibility = hidden ? "hidden" : "visible"; - this.annotationStorage.setValue(this.data.id, { - noView: hidden, - noPrint: display === 1 || display === 2 - }); - }, - print: event => { - this.annotationStorage.setValue(this.data.id, { - noPrint: !event.detail.print - }); - }, - hidden: event => { - const { - hidden - } = event.detail; - this.container.style.visibility = hidden ? "hidden" : "visible"; - this.annotationStorage.setValue(this.data.id, { - noPrint: hidden, - noView: hidden - }); - }, - focus: event => { - setTimeout(() => event.target.focus({ - preventScroll: false - }), 0); - }, - userName: event => { - event.target.title = event.detail.userName; - }, - readonly: event => { - event.target.disabled = event.detail.readonly; - }, - required: event => { - this._setRequired(event.target, event.detail.required); - }, - bgColor: event => { - setColor("bgColor", "backgroundColor", event); - }, - fillColor: event => { - setColor("fillColor", "backgroundColor", event); - }, - fgColor: event => { - setColor("fgColor", "color", event); - }, - textColor: event => { - setColor("textColor", "color", event); - }, - borderColor: event => { - setColor("borderColor", "borderColor", event); - }, - strokeColor: event => { - setColor("strokeColor", "borderColor", event); - }, - rotation: event => { - const angle = event.detail.rotation; - this.setRotation(angle); - this.annotationStorage.setValue(this.data.id, { - rotation: angle - }); - } - }); - } - _dispatchEventFromSandbox(actions, jsEvent) { - const commonActions = this._commonActions; - for (const name of Object.keys(jsEvent.detail)) { - const action = actions[name] || commonActions[name]; - action?.(jsEvent); - } - } - _setDefaultPropertiesFromJS(element) { - if (!this.enableScripting) { - return; - } - const storedData = this.annotationStorage.getRawValue(this.data.id); - if (!storedData) { - return; - } - const commonActions = this._commonActions; - for (const [actionName, detail] of Object.entries(storedData)) { - const action = commonActions[actionName]; - if (action) { - const eventProxy = { - detail: { - [actionName]: detail - }, - target: element - }; - action(eventProxy); - delete storedData[actionName]; - } - } - } - _createQuadrilaterals() { - if (!this.container) { - return; - } - const { - quadPoints - } = this.data; - if (!quadPoints) { - return; - } - const [rectBlX, rectBlY, rectTrX, rectTrY] = this.data.rect.map(x => Math.fround(x)); - if (quadPoints.length === 8) { - const [trX, trY, blX, blY] = quadPoints.subarray(2, 6); - if (rectTrX === trX && rectTrY === trY && rectBlX === blX && rectBlY === blY) { - return; - } - } - const { - style - } = this.container; - let svgBuffer; - if (this.#hasBorder) { - const { - borderColor, - borderWidth - } = style; - style.borderWidth = 0; - svgBuffer = ["url('data:image/svg+xml;utf8,", ``, ``]; - this.container.classList.add("hasBorder"); - } - const width = rectTrX - rectBlX; - const height = rectTrY - rectBlY; - const { - svgFactory - } = this; - const svg = svgFactory.createElement("svg"); - svg.classList.add("quadrilateralsContainer"); - svg.setAttribute("width", 0); - svg.setAttribute("height", 0); - const defs = svgFactory.createElement("defs"); - svg.append(defs); - const clipPath = svgFactory.createElement("clipPath"); - const id = `clippath_${this.data.id}`; - clipPath.setAttribute("id", id); - clipPath.setAttribute("clipPathUnits", "objectBoundingBox"); - defs.append(clipPath); - for (let i = 2, ii = quadPoints.length; i < ii; i += 8) { - const trX = quadPoints[i]; - const trY = quadPoints[i + 1]; - const blX = quadPoints[i + 2]; - const blY = quadPoints[i + 3]; - const rect = svgFactory.createElement("rect"); - const x = (blX - rectBlX) / width; - const y = (rectTrY - trY) / height; - const rectWidth = (trX - blX) / width; - const rectHeight = (trY - blY) / height; - rect.setAttribute("x", x); - rect.setAttribute("y", y); - rect.setAttribute("width", rectWidth); - rect.setAttribute("height", rectHeight); - clipPath.append(rect); - svgBuffer?.push(``); - } - if (this.#hasBorder) { - svgBuffer.push(`')`); - style.backgroundImage = svgBuffer.join(""); - } - this.container.append(svg); - this.container.style.clipPath = `url(#${id})`; - } - _createPopup() { - const { - container, - data - } = this; - container.setAttribute("aria-haspopup", "dialog"); - const popup = this.#popupElement = new PopupAnnotationElement({ - data: { - color: data.color, - titleObj: data.titleObj, - modificationDate: data.modificationDate, - contentsObj: data.contentsObj, - richText: data.richText, - parentRect: data.rect, - borderStyle: 0, - id: `popup_${data.id}`, - rotation: data.rotation - }, - parent: this.parent, - elements: [this] - }); - this.parent.div.append(popup.render()); - } - render() { - unreachable("Abstract method `AnnotationElement.render` called"); - } - _getElementsByName(name, skipId = null) { - const fields = []; - if (this._fieldObjects) { - const fieldObj = this._fieldObjects[name]; - if (fieldObj) { - for (const { - page, - id, - exportValues - } of fieldObj) { - if (page === -1) { - continue; - } - if (id === skipId) { - continue; - } - const exportValue = typeof exportValues === "string" ? exportValues : null; - const domElement = document.querySelector(`[data-element-id="${id}"]`); - if (domElement && !GetElementsByNameSet.has(domElement)) { - warn(`_getElementsByName - element not allowed: ${id}`); - continue; - } - fields.push({ - id, - exportValue, - domElement - }); - } - } - return fields; - } - for (const domElement of document.getElementsByName(name)) { - const { - exportValue - } = domElement; - const id = domElement.getAttribute("data-element-id"); - if (id === skipId) { - continue; - } - if (!GetElementsByNameSet.has(domElement)) { - continue; - } - fields.push({ - id, - exportValue, - domElement - }); - } - return fields; - } - show() { - if (this.container) { - this.container.hidden = false; - } - this.popup?.maybeShow(); - } - hide() { - if (this.container) { - this.container.hidden = true; - } - this.popup?.forceHide(); - } - getElementsToTriggerPopup() { - return this.container; - } - addHighlightArea() { - const triggers = this.getElementsToTriggerPopup(); - if (Array.isArray(triggers)) { - for (const element of triggers) { - element.classList.add("highlightArea"); - } - } else { - triggers.classList.add("highlightArea"); - } - } - get _isEditable() { - return false; - } - _editOnDoubleClick() { - if (!this._isEditable) { - return; - } - const { - annotationEditorType: mode, - data: { - id: editId - } - } = this; - this.container.addEventListener("dblclick", () => { - this.linkService.eventBus?.dispatch("switchannotationeditormode", { - source: this, - mode, - editId - }); - }); - } -} -class LinkAnnotationElement extends AnnotationElement { - constructor(parameters, options = null) { - super(parameters, { - isRenderable: true, - ignoreBorder: !!options?.ignoreBorder, - createQuadrilaterals: true - }); - this.isTooltipOnly = parameters.data.isTooltipOnly; - } - render() { - const { - data, - linkService - } = this; - const link = document.createElement("a"); - link.setAttribute("data-element-id", data.id); - let isBound = false; - if (data.url) { - linkService.addLinkAttributes(link, data.url, data.newWindow); - isBound = true; - } else if (data.action) { - this._bindNamedAction(link, data.action); - isBound = true; - } else if (data.attachment) { - this.#bindAttachment(link, data.attachment, data.attachmentDest); - isBound = true; - } else if (data.setOCGState) { - this.#bindSetOCGState(link, data.setOCGState); - isBound = true; - } else if (data.dest) { - this._bindLink(link, data.dest); - isBound = true; - } else { - if (data.actions && (data.actions.Action || data.actions["Mouse Up"] || data.actions["Mouse Down"]) && this.enableScripting && this.hasJSActions) { - this._bindJSAction(link, data); - isBound = true; - } - if (data.resetForm) { - this._bindResetFormAction(link, data.resetForm); - isBound = true; - } else if (this.isTooltipOnly && !isBound) { - this._bindLink(link, ""); - isBound = true; - } - } - this.container.classList.add("linkAnnotation"); - if (isBound) { - this.container.append(link); - } - return this.container; - } - #setInternalLink() { - this.container.setAttribute("data-internal-link", ""); - } - _bindLink(link, destination) { - link.href = this.linkService.getDestinationHash(destination); - link.onclick = () => { - if (destination) { - this.linkService.goToDestination(destination); - } - return false; - }; - if (destination || destination === "") { - this.#setInternalLink(); - } - } - _bindNamedAction(link, action) { - link.href = this.linkService.getAnchorUrl(""); - link.onclick = () => { - this.linkService.executeNamedAction(action); - return false; - }; - this.#setInternalLink(); - } - #bindAttachment(link, attachment, dest = null) { - link.href = this.linkService.getAnchorUrl(""); - if (attachment.description) { - link.title = attachment.description; - } - link.onclick = () => { - this.downloadManager?.openOrDownloadData(attachment.content, attachment.filename, dest); - return false; - }; - this.#setInternalLink(); - } - #bindSetOCGState(link, action) { - link.href = this.linkService.getAnchorUrl(""); - link.onclick = () => { - this.linkService.executeSetOCGState(action); - return false; - }; - this.#setInternalLink(); - } - _bindJSAction(link, data) { - link.href = this.linkService.getAnchorUrl(""); - const map = new Map([["Action", "onclick"], ["Mouse Up", "onmouseup"], ["Mouse Down", "onmousedown"]]); - for (const name of Object.keys(data.actions)) { - const jsName = map.get(name); - if (!jsName) { - continue; - } - link[jsName] = () => { - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id: data.id, - name - } - }); - return false; - }; - } - if (!link.onclick) { - link.onclick = () => false; - } - this.#setInternalLink(); - } - _bindResetFormAction(link, resetForm) { - const otherClickAction = link.onclick; - if (!otherClickAction) { - link.href = this.linkService.getAnchorUrl(""); - } - this.#setInternalLink(); - if (!this._fieldObjects) { - warn(`_bindResetFormAction - "resetForm" action not supported, ` + "ensure that the `fieldObjects` parameter is provided."); - if (!otherClickAction) { - link.onclick = () => false; - } - return; - } - link.onclick = () => { - otherClickAction?.(); - const { - fields: resetFormFields, - refs: resetFormRefs, - include - } = resetForm; - const allFields = []; - if (resetFormFields.length !== 0 || resetFormRefs.length !== 0) { - const fieldIds = new Set(resetFormRefs); - for (const fieldName of resetFormFields) { - const fields = this._fieldObjects[fieldName] || []; - for (const { - id - } of fields) { - fieldIds.add(id); - } - } - for (const fields of Object.values(this._fieldObjects)) { - for (const field of fields) { - if (fieldIds.has(field.id) === include) { - allFields.push(field); - } - } - } - } else { - for (const fields of Object.values(this._fieldObjects)) { - allFields.push(...fields); - } - } - const storage = this.annotationStorage; - const allIds = []; - for (const field of allFields) { - const { - id - } = field; - allIds.push(id); - switch (field.type) { - case "text": - { - const value = field.defaultValue || ""; - storage.setValue(id, { - value - }); - break; - } - case "checkbox": - case "radiobutton": - { - const value = field.defaultValue === field.exportValues; - storage.setValue(id, { - value - }); - break; - } - case "combobox": - case "listbox": - { - const value = field.defaultValue || ""; - storage.setValue(id, { - value - }); - break; - } - default: - continue; - } - const domElement = document.querySelector(`[data-element-id="${id}"]`); - if (!domElement) { - continue; - } else if (!GetElementsByNameSet.has(domElement)) { - warn(`_bindResetFormAction - element not allowed: ${id}`); - continue; - } - domElement.dispatchEvent(new Event("resetform")); - } - if (this.enableScripting) { - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id: "app", - ids: allIds, - name: "ResetForm" - } - }); - } - return false; - }; - } -} -class TextAnnotationElement extends AnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: true - }); - } - render() { - this.container.classList.add("textAnnotation"); - const image = document.createElement("img"); - image.src = this.imageResourcesPath + "annotation-" + this.data.name.toLowerCase() + ".svg"; - image.setAttribute("data-l10n-id", "pdfjs-text-annotation-type"); - image.setAttribute("data-l10n-args", JSON.stringify({ - type: this.data.name - })); - if (!this.data.popupRef && this.hasPopupData) { - this._createPopup(); - } - this.container.append(image); - return this.container; - } -} -class WidgetAnnotationElement extends AnnotationElement { - render() { - return this.container; - } - showElementAndHideCanvas(element) { - if (this.data.hasOwnCanvas) { - if (element.previousSibling?.nodeName === "CANVAS") { - element.previousSibling.hidden = true; - } - element.hidden = false; - } - } - _getKeyModifier(event) { - return util_FeatureTest.platform.isMac ? event.metaKey : event.ctrlKey; - } - _setEventListener(element, elementData, baseName, eventName, valueGetter) { - if (baseName.includes("mouse")) { - element.addEventListener(baseName, event => { - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id: this.data.id, - name: eventName, - value: valueGetter(event), - shift: event.shiftKey, - modifier: this._getKeyModifier(event) - } - }); - }); - } else { - element.addEventListener(baseName, event => { - if (baseName === "blur") { - if (!elementData.focused || !event.relatedTarget) { - return; - } - elementData.focused = false; - } else if (baseName === "focus") { - if (elementData.focused) { - return; - } - elementData.focused = true; - } - if (!valueGetter) { - return; - } - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id: this.data.id, - name: eventName, - value: valueGetter(event) - } - }); - }); - } - } - _setEventListeners(element, elementData, names, getter) { - for (const [baseName, eventName] of names) { - if (eventName === "Action" || this.data.actions?.[eventName]) { - if (eventName === "Focus" || eventName === "Blur") { - elementData ||= { - focused: false - }; - } - this._setEventListener(element, elementData, baseName, eventName, getter); - if (eventName === "Focus" && !this.data.actions?.Blur) { - this._setEventListener(element, elementData, "blur", "Blur", null); - } else if (eventName === "Blur" && !this.data.actions?.Focus) { - this._setEventListener(element, elementData, "focus", "Focus", null); - } - } - } - } - _setBackgroundColor(element) { - const color = this.data.backgroundColor || null; - element.style.backgroundColor = color === null ? "transparent" : Util.makeHexColor(color[0], color[1], color[2]); - } - _setTextStyle(element) { - const TEXT_ALIGNMENT = ["left", "center", "right"]; - const { - fontColor - } = this.data.defaultAppearanceData; - const fontSize = this.data.defaultAppearanceData.fontSize || annotation_layer_DEFAULT_FONT_SIZE; - const style = element.style; - let computedFontSize; - const BORDER_SIZE = 2; - const roundToOneDecimal = x => Math.round(10 * x) / 10; - if (this.data.multiLine) { - const height = Math.abs(this.data.rect[3] - this.data.rect[1] - BORDER_SIZE); - const numberOfLines = Math.round(height / (LINE_FACTOR * fontSize)) || 1; - const lineHeight = height / numberOfLines; - computedFontSize = Math.min(fontSize, roundToOneDecimal(lineHeight / LINE_FACTOR)); - } else { - const height = Math.abs(this.data.rect[3] - this.data.rect[1] - BORDER_SIZE); - computedFontSize = Math.min(fontSize, roundToOneDecimal(height / LINE_FACTOR)); - } - style.fontSize = `calc(${computedFontSize}px * var(--scale-factor))`; - style.color = Util.makeHexColor(fontColor[0], fontColor[1], fontColor[2]); - if (this.data.textAlignment !== null) { - style.textAlign = TEXT_ALIGNMENT[this.data.textAlignment]; - } - } - _setRequired(element, isRequired) { - if (isRequired) { - element.setAttribute("required", true); - } else { - element.removeAttribute("required"); - } - element.setAttribute("aria-required", isRequired); - } -} -class TextWidgetAnnotationElement extends WidgetAnnotationElement { - constructor(parameters) { - const isRenderable = parameters.renderForms || parameters.data.hasOwnCanvas || !parameters.data.hasAppearance && !!parameters.data.fieldValue; - super(parameters, { - isRenderable - }); - } - setPropertyOnSiblings(base, key, value, keyInStorage) { - const storage = this.annotationStorage; - for (const element of this._getElementsByName(base.name, base.id)) { - if (element.domElement) { - element.domElement[key] = value; - } - storage.setValue(element.id, { - [keyInStorage]: value - }); - } - } - render() { - const storage = this.annotationStorage; - const id = this.data.id; - this.container.classList.add("textWidgetAnnotation"); - let element = null; - if (this.renderForms) { - const storedData = storage.getValue(id, { - value: this.data.fieldValue - }); - let textContent = storedData.value || ""; - const maxLen = storage.getValue(id, { - charLimit: this.data.maxLen - }).charLimit; - if (maxLen && textContent.length > maxLen) { - textContent = textContent.slice(0, maxLen); - } - let fieldFormattedValues = storedData.formattedValue || this.data.textContent?.join("\n") || null; - if (fieldFormattedValues && this.data.comb) { - fieldFormattedValues = fieldFormattedValues.replaceAll(/\s+/g, ""); - } - const elementData = { - userValue: textContent, - formattedValue: fieldFormattedValues, - lastCommittedValue: null, - commitKey: 1, - focused: false - }; - if (this.data.multiLine) { - element = document.createElement("textarea"); - element.textContent = fieldFormattedValues ?? textContent; - if (this.data.doNotScroll) { - element.style.overflowY = "hidden"; - } - } else { - element = document.createElement("input"); - element.type = "text"; - element.setAttribute("value", fieldFormattedValues ?? textContent); - if (this.data.doNotScroll) { - element.style.overflowX = "hidden"; - } - } - if (this.data.hasOwnCanvas) { - element.hidden = true; - } - GetElementsByNameSet.add(element); - element.setAttribute("data-element-id", id); - element.disabled = this.data.readOnly; - element.name = this.data.fieldName; - element.tabIndex = DEFAULT_TAB_INDEX; - this._setRequired(element, this.data.required); - if (maxLen) { - element.maxLength = maxLen; - } - element.addEventListener("input", event => { - storage.setValue(id, { - value: event.target.value - }); - this.setPropertyOnSiblings(element, "value", event.target.value, "value"); - elementData.formattedValue = null; - }); - element.addEventListener("resetform", event => { - const defaultValue = this.data.defaultFieldValue ?? ""; - element.value = elementData.userValue = defaultValue; - elementData.formattedValue = null; - }); - let blurListener = event => { - const { - formattedValue - } = elementData; - if (formattedValue !== null && formattedValue !== undefined) { - event.target.value = formattedValue; - } - event.target.scrollLeft = 0; - }; - if (this.enableScripting && this.hasJSActions) { - element.addEventListener("focus", event => { - if (elementData.focused) { - return; - } - const { - target - } = event; - if (elementData.userValue) { - target.value = elementData.userValue; - } - elementData.lastCommittedValue = target.value; - elementData.commitKey = 1; - if (!this.data.actions?.Focus) { - elementData.focused = true; - } - }); - element.addEventListener("updatefromsandbox", jsEvent => { - this.showElementAndHideCanvas(jsEvent.target); - const actions = { - value(event) { - elementData.userValue = event.detail.value ?? ""; - storage.setValue(id, { - value: elementData.userValue.toString() - }); - event.target.value = elementData.userValue; - }, - formattedValue(event) { - const { - formattedValue - } = event.detail; - elementData.formattedValue = formattedValue; - if (formattedValue !== null && formattedValue !== undefined && event.target !== document.activeElement) { - event.target.value = formattedValue; - } - storage.setValue(id, { - formattedValue - }); - }, - selRange(event) { - event.target.setSelectionRange(...event.detail.selRange); - }, - charLimit: event => { - const { - charLimit - } = event.detail; - const { - target - } = event; - if (charLimit === 0) { - target.removeAttribute("maxLength"); - return; - } - target.setAttribute("maxLength", charLimit); - let value = elementData.userValue; - if (!value || value.length <= charLimit) { - return; - } - value = value.slice(0, charLimit); - target.value = elementData.userValue = value; - storage.setValue(id, { - value - }); - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id, - name: "Keystroke", - value, - willCommit: true, - commitKey: 1, - selStart: target.selectionStart, - selEnd: target.selectionEnd - } - }); - } - }; - this._dispatchEventFromSandbox(actions, jsEvent); - }); - element.addEventListener("keydown", event => { - elementData.commitKey = 1; - let commitKey = -1; - if (event.key === "Escape") { - commitKey = 0; - } else if (event.key === "Enter" && !this.data.multiLine) { - commitKey = 2; - } else if (event.key === "Tab") { - elementData.commitKey = 3; - } - if (commitKey === -1) { - return; - } - const { - value - } = event.target; - if (elementData.lastCommittedValue === value) { - return; - } - elementData.lastCommittedValue = value; - elementData.userValue = value; - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id, - name: "Keystroke", - value, - willCommit: true, - commitKey, - selStart: event.target.selectionStart, - selEnd: event.target.selectionEnd - } - }); - }); - const _blurListener = blurListener; - blurListener = null; - element.addEventListener("blur", event => { - if (!elementData.focused || !event.relatedTarget) { - return; - } - if (!this.data.actions?.Blur) { - elementData.focused = false; - } - const { - value - } = event.target; - elementData.userValue = value; - if (elementData.lastCommittedValue !== value) { - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id, - name: "Keystroke", - value, - willCommit: true, - commitKey: elementData.commitKey, - selStart: event.target.selectionStart, - selEnd: event.target.selectionEnd - } - }); - } - _blurListener(event); - }); - if (this.data.actions?.Keystroke) { - element.addEventListener("beforeinput", event => { - elementData.lastCommittedValue = null; - const { - data, - target - } = event; - const { - value, - selectionStart, - selectionEnd - } = target; - let selStart = selectionStart, - selEnd = selectionEnd; - switch (event.inputType) { - case "deleteWordBackward": - { - const match = value.substring(0, selectionStart).match(/\w*[^\w]*$/); - if (match) { - selStart -= match[0].length; - } - break; - } - case "deleteWordForward": - { - const match = value.substring(selectionStart).match(/^[^\w]*\w*/); - if (match) { - selEnd += match[0].length; - } - break; - } - case "deleteContentBackward": - if (selectionStart === selectionEnd) { - selStart -= 1; - } - break; - case "deleteContentForward": - if (selectionStart === selectionEnd) { - selEnd += 1; - } - break; - } - event.preventDefault(); - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id, - name: "Keystroke", - value, - change: data || "", - willCommit: false, - selStart, - selEnd - } - }); - }); - } - this._setEventListeners(element, elementData, [["focus", "Focus"], ["blur", "Blur"], ["mousedown", "Mouse Down"], ["mouseenter", "Mouse Enter"], ["mouseleave", "Mouse Exit"], ["mouseup", "Mouse Up"]], event => event.target.value); - } - if (blurListener) { - element.addEventListener("blur", blurListener); - } - if (this.data.comb) { - const fieldWidth = this.data.rect[2] - this.data.rect[0]; - const combWidth = fieldWidth / maxLen; - element.classList.add("comb"); - element.style.letterSpacing = `calc(${combWidth}px * var(--scale-factor) - 1ch)`; - } - } else { - element = document.createElement("div"); - element.textContent = this.data.fieldValue; - element.style.verticalAlign = "middle"; - element.style.display = "table-cell"; - if (this.data.hasOwnCanvas) { - element.hidden = true; - } - } - this._setTextStyle(element); - this._setBackgroundColor(element); - this._setDefaultPropertiesFromJS(element); - this.container.append(element); - return this.container; - } -} -class SignatureWidgetAnnotationElement extends WidgetAnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: !!parameters.data.hasOwnCanvas - }); - } -} -class CheckboxWidgetAnnotationElement extends WidgetAnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: parameters.renderForms - }); - } - render() { - const storage = this.annotationStorage; - const data = this.data; - const id = data.id; - let value = storage.getValue(id, { - value: data.exportValue === data.fieldValue - }).value; - if (typeof value === "string") { - value = value !== "Off"; - storage.setValue(id, { - value - }); - } - this.container.classList.add("buttonWidgetAnnotation", "checkBox"); - const element = document.createElement("input"); - GetElementsByNameSet.add(element); - element.setAttribute("data-element-id", id); - element.disabled = data.readOnly; - this._setRequired(element, this.data.required); - element.type = "checkbox"; - element.name = data.fieldName; - if (value) { - element.setAttribute("checked", true); - } - element.setAttribute("exportValue", data.exportValue); - element.tabIndex = DEFAULT_TAB_INDEX; - element.addEventListener("change", event => { - const { - name, - checked - } = event.target; - for (const checkbox of this._getElementsByName(name, id)) { - const curChecked = checked && checkbox.exportValue === data.exportValue; - if (checkbox.domElement) { - checkbox.domElement.checked = curChecked; - } - storage.setValue(checkbox.id, { - value: curChecked - }); - } - storage.setValue(id, { - value: checked - }); - }); - element.addEventListener("resetform", event => { - const defaultValue = data.defaultFieldValue || "Off"; - event.target.checked = defaultValue === data.exportValue; - }); - if (this.enableScripting && this.hasJSActions) { - element.addEventListener("updatefromsandbox", jsEvent => { - const actions = { - value(event) { - event.target.checked = event.detail.value !== "Off"; - storage.setValue(id, { - value: event.target.checked - }); - } - }; - this._dispatchEventFromSandbox(actions, jsEvent); - }); - this._setEventListeners(element, null, [["change", "Validate"], ["change", "Action"], ["focus", "Focus"], ["blur", "Blur"], ["mousedown", "Mouse Down"], ["mouseenter", "Mouse Enter"], ["mouseleave", "Mouse Exit"], ["mouseup", "Mouse Up"]], event => event.target.checked); - } - this._setBackgroundColor(element); - this._setDefaultPropertiesFromJS(element); - this.container.append(element); - return this.container; - } -} -class RadioButtonWidgetAnnotationElement extends WidgetAnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: parameters.renderForms - }); - } - render() { - this.container.classList.add("buttonWidgetAnnotation", "radioButton"); - const storage = this.annotationStorage; - const data = this.data; - const id = data.id; - let value = storage.getValue(id, { - value: data.fieldValue === data.buttonValue - }).value; - if (typeof value === "string") { - value = value !== data.buttonValue; - storage.setValue(id, { - value - }); - } - if (value) { - for (const radio of this._getElementsByName(data.fieldName, id)) { - storage.setValue(radio.id, { - value: false - }); - } - } - const element = document.createElement("input"); - GetElementsByNameSet.add(element); - element.setAttribute("data-element-id", id); - element.disabled = data.readOnly; - this._setRequired(element, this.data.required); - element.type = "radio"; - element.name = data.fieldName; - if (value) { - element.setAttribute("checked", true); - } - element.tabIndex = DEFAULT_TAB_INDEX; - element.addEventListener("change", event => { - const { - name, - checked - } = event.target; - for (const radio of this._getElementsByName(name, id)) { - storage.setValue(radio.id, { - value: false - }); - } - storage.setValue(id, { - value: checked - }); - }); - element.addEventListener("resetform", event => { - const defaultValue = data.defaultFieldValue; - event.target.checked = defaultValue !== null && defaultValue !== undefined && defaultValue === data.buttonValue; - }); - if (this.enableScripting && this.hasJSActions) { - const pdfButtonValue = data.buttonValue; - element.addEventListener("updatefromsandbox", jsEvent => { - const actions = { - value: event => { - const checked = pdfButtonValue === event.detail.value; - for (const radio of this._getElementsByName(event.target.name)) { - const curChecked = checked && radio.id === id; - if (radio.domElement) { - radio.domElement.checked = curChecked; - } - storage.setValue(radio.id, { - value: curChecked - }); - } - } - }; - this._dispatchEventFromSandbox(actions, jsEvent); - }); - this._setEventListeners(element, null, [["change", "Validate"], ["change", "Action"], ["focus", "Focus"], ["blur", "Blur"], ["mousedown", "Mouse Down"], ["mouseenter", "Mouse Enter"], ["mouseleave", "Mouse Exit"], ["mouseup", "Mouse Up"]], event => event.target.checked); - } - this._setBackgroundColor(element); - this._setDefaultPropertiesFromJS(element); - this.container.append(element); - return this.container; - } -} -class PushButtonWidgetAnnotationElement extends LinkAnnotationElement { - constructor(parameters) { - super(parameters, { - ignoreBorder: parameters.data.hasAppearance - }); - } - render() { - const container = super.render(); - container.classList.add("buttonWidgetAnnotation", "pushButton"); - const linkElement = container.lastChild; - if (this.enableScripting && this.hasJSActions && linkElement) { - this._setDefaultPropertiesFromJS(linkElement); - linkElement.addEventListener("updatefromsandbox", jsEvent => { - this._dispatchEventFromSandbox({}, jsEvent); - }); - } - return container; - } -} -class ChoiceWidgetAnnotationElement extends WidgetAnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: parameters.renderForms - }); - } - render() { - this.container.classList.add("choiceWidgetAnnotation"); - const storage = this.annotationStorage; - const id = this.data.id; - const storedData = storage.getValue(id, { - value: this.data.fieldValue - }); - const selectElement = document.createElement("select"); - GetElementsByNameSet.add(selectElement); - selectElement.setAttribute("data-element-id", id); - selectElement.disabled = this.data.readOnly; - this._setRequired(selectElement, this.data.required); - selectElement.name = this.data.fieldName; - selectElement.tabIndex = DEFAULT_TAB_INDEX; - let addAnEmptyEntry = this.data.combo && this.data.options.length > 0; - if (!this.data.combo) { - selectElement.size = this.data.options.length; - if (this.data.multiSelect) { - selectElement.multiple = true; - } - } - selectElement.addEventListener("resetform", event => { - const defaultValue = this.data.defaultFieldValue; - for (const option of selectElement.options) { - option.selected = option.value === defaultValue; - } - }); - for (const option of this.data.options) { - const optionElement = document.createElement("option"); - optionElement.textContent = option.displayValue; - optionElement.value = option.exportValue; - if (storedData.value.includes(option.exportValue)) { - optionElement.setAttribute("selected", true); - addAnEmptyEntry = false; - } - selectElement.append(optionElement); - } - let removeEmptyEntry = null; - if (addAnEmptyEntry) { - const noneOptionElement = document.createElement("option"); - noneOptionElement.value = " "; - noneOptionElement.setAttribute("hidden", true); - noneOptionElement.setAttribute("selected", true); - selectElement.prepend(noneOptionElement); - removeEmptyEntry = () => { - noneOptionElement.remove(); - selectElement.removeEventListener("input", removeEmptyEntry); - removeEmptyEntry = null; - }; - selectElement.addEventListener("input", removeEmptyEntry); - } - const getValue = isExport => { - const name = isExport ? "value" : "textContent"; - const { - options, - multiple - } = selectElement; - if (!multiple) { - return options.selectedIndex === -1 ? null : options[options.selectedIndex][name]; - } - return Array.prototype.filter.call(options, option => option.selected).map(option => option[name]); - }; - let selectedValues = getValue(false); - const getItems = event => { - const options = event.target.options; - return Array.prototype.map.call(options, option => ({ - displayValue: option.textContent, - exportValue: option.value - })); - }; - if (this.enableScripting && this.hasJSActions) { - selectElement.addEventListener("updatefromsandbox", jsEvent => { - const actions = { - value(event) { - removeEmptyEntry?.(); - const value = event.detail.value; - const values = new Set(Array.isArray(value) ? value : [value]); - for (const option of selectElement.options) { - option.selected = values.has(option.value); - } - storage.setValue(id, { - value: getValue(true) - }); - selectedValues = getValue(false); - }, - multipleSelection(event) { - selectElement.multiple = true; - }, - remove(event) { - const options = selectElement.options; - const index = event.detail.remove; - options[index].selected = false; - selectElement.remove(index); - if (options.length > 0) { - const i = Array.prototype.findIndex.call(options, option => option.selected); - if (i === -1) { - options[0].selected = true; - } - } - storage.setValue(id, { - value: getValue(true), - items: getItems(event) - }); - selectedValues = getValue(false); - }, - clear(event) { - while (selectElement.length !== 0) { - selectElement.remove(0); - } - storage.setValue(id, { - value: null, - items: [] - }); - selectedValues = getValue(false); - }, - insert(event) { - const { - index, - displayValue, - exportValue - } = event.detail.insert; - const selectChild = selectElement.children[index]; - const optionElement = document.createElement("option"); - optionElement.textContent = displayValue; - optionElement.value = exportValue; - if (selectChild) { - selectChild.before(optionElement); - } else { - selectElement.append(optionElement); - } - storage.setValue(id, { - value: getValue(true), - items: getItems(event) - }); - selectedValues = getValue(false); - }, - items(event) { - const { - items - } = event.detail; - while (selectElement.length !== 0) { - selectElement.remove(0); - } - for (const item of items) { - const { - displayValue, - exportValue - } = item; - const optionElement = document.createElement("option"); - optionElement.textContent = displayValue; - optionElement.value = exportValue; - selectElement.append(optionElement); - } - if (selectElement.options.length > 0) { - selectElement.options[0].selected = true; - } - storage.setValue(id, { - value: getValue(true), - items: getItems(event) - }); - selectedValues = getValue(false); - }, - indices(event) { - const indices = new Set(event.detail.indices); - for (const option of event.target.options) { - option.selected = indices.has(option.index); - } - storage.setValue(id, { - value: getValue(true) - }); - selectedValues = getValue(false); - }, - editable(event) { - event.target.disabled = !event.detail.editable; - } - }; - this._dispatchEventFromSandbox(actions, jsEvent); - }); - selectElement.addEventListener("input", event => { - const exportValue = getValue(true); - const change = getValue(false); - storage.setValue(id, { - value: exportValue - }); - event.preventDefault(); - this.linkService.eventBus?.dispatch("dispatcheventinsandbox", { - source: this, - detail: { - id, - name: "Keystroke", - value: selectedValues, - change, - changeEx: exportValue, - willCommit: false, - commitKey: 1, - keyDown: false - } - }); - }); - this._setEventListeners(selectElement, null, [["focus", "Focus"], ["blur", "Blur"], ["mousedown", "Mouse Down"], ["mouseenter", "Mouse Enter"], ["mouseleave", "Mouse Exit"], ["mouseup", "Mouse Up"], ["input", "Action"], ["input", "Validate"]], event => event.target.value); - } else { - selectElement.addEventListener("input", function (event) { - storage.setValue(id, { - value: getValue(true) - }); - }); - } - if (this.data.combo) { - this._setTextStyle(selectElement); - } else {} - this._setBackgroundColor(selectElement); - this._setDefaultPropertiesFromJS(selectElement); - this.container.append(selectElement); - return this.container; - } -} -class PopupAnnotationElement extends AnnotationElement { - constructor(parameters) { - const { - data, - elements - } = parameters; - super(parameters, { - isRenderable: AnnotationElement._hasPopupData(data) - }); - this.elements = elements; - this.popup = null; - } - render() { - this.container.classList.add("popupAnnotation"); - const popup = this.popup = new PopupElement({ - container: this.container, - color: this.data.color, - titleObj: this.data.titleObj, - modificationDate: this.data.modificationDate, - contentsObj: this.data.contentsObj, - richText: this.data.richText, - rect: this.data.rect, - parentRect: this.data.parentRect || null, - parent: this.parent, - elements: this.elements, - open: this.data.open - }); - const elementIds = []; - for (const element of this.elements) { - element.popup = popup; - elementIds.push(element.data.id); - element.addHighlightArea(); - } - this.container.setAttribute("aria-controls", elementIds.map(id => `${AnnotationPrefix}${id}`).join(",")); - return this.container; - } -} -class PopupElement { - #boundKeyDown = this.#keyDown.bind(this); - #boundHide = this.#hide.bind(this); - #boundShow = this.#show.bind(this); - #boundToggle = this.#toggle.bind(this); - #color = null; - #container = null; - #contentsObj = null; - #dateObj = null; - #elements = null; - #parent = null; - #parentRect = null; - #pinned = false; - #popup = null; - #position = null; - #rect = null; - #richText = null; - #titleObj = null; - #updates = null; - #wasVisible = false; - constructor({ - container, - color, - elements, - titleObj, - modificationDate, - contentsObj, - richText, - parent, - rect, - parentRect, - open - }) { - this.#container = container; - this.#titleObj = titleObj; - this.#contentsObj = contentsObj; - this.#richText = richText; - this.#parent = parent; - this.#color = color; - this.#rect = rect; - this.#parentRect = parentRect; - this.#elements = elements; - this.#dateObj = PDFDateString.toDateObject(modificationDate); - this.trigger = elements.flatMap(e => e.getElementsToTriggerPopup()); - for (const element of this.trigger) { - element.addEventListener("click", this.#boundToggle); - element.addEventListener("mouseenter", this.#boundShow); - element.addEventListener("mouseleave", this.#boundHide); - element.classList.add("popupTriggerArea"); - } - for (const element of elements) { - element.container?.addEventListener("keydown", this.#boundKeyDown); - } - this.#container.hidden = true; - if (open) { - this.#toggle(); - } - } - render() { - if (this.#popup) { - return; - } - const popup = this.#popup = document.createElement("div"); - popup.className = "popup"; - if (this.#color) { - const baseColor = popup.style.outlineColor = Util.makeHexColor(...this.#color); - if (CSS.supports("background-color", "color-mix(in srgb, red 30%, white)")) { - popup.style.backgroundColor = `color-mix(in srgb, ${baseColor} 30%, white)`; - } else { - const BACKGROUND_ENLIGHT = 0.7; - popup.style.backgroundColor = Util.makeHexColor(...this.#color.map(c => Math.floor(BACKGROUND_ENLIGHT * (255 - c) + c))); - } - } - const header = document.createElement("span"); - header.className = "header"; - const title = document.createElement("h1"); - header.append(title); - ({ - dir: title.dir, - str: title.textContent - } = this.#titleObj); - popup.append(header); - if (this.#dateObj) { - const modificationDate = document.createElement("span"); - modificationDate.classList.add("popupDate"); - modificationDate.setAttribute("data-l10n-id", "pdfjs-annotation-date-string"); - modificationDate.setAttribute("data-l10n-args", JSON.stringify({ - date: this.#dateObj.toLocaleDateString(), - time: this.#dateObj.toLocaleTimeString() - })); - header.append(modificationDate); - } - const html = this.#html; - if (html) { - XfaLayer.render({ - xfaHtml: html, - intent: "richText", - div: popup - }); - popup.lastChild.classList.add("richText", "popupContent"); - } else { - const contents = this._formatContents(this.#contentsObj); - popup.append(contents); - } - this.#container.append(popup); - } - get #html() { - const richText = this.#richText; - const contentsObj = this.#contentsObj; - if (richText?.str && (!contentsObj?.str || contentsObj.str === richText.str)) { - return this.#richText.html || null; - } - return null; - } - get #fontSize() { - return this.#html?.attributes?.style?.fontSize || 0; - } - get #fontColor() { - return this.#html?.attributes?.style?.color || null; - } - #makePopupContent(text) { - const popupLines = []; - const popupContent = { - str: text, - html: { - name: "div", - attributes: { - dir: "auto" - }, - children: [{ - name: "p", - children: popupLines - }] - } - }; - const lineAttributes = { - style: { - color: this.#fontColor, - fontSize: this.#fontSize ? `calc(${this.#fontSize}px * var(--scale-factor))` : "" - } - }; - for (const line of text.split("\n")) { - popupLines.push({ - name: "span", - value: line, - attributes: lineAttributes - }); - } - return popupContent; - } - _formatContents({ - str, - dir - }) { - const p = document.createElement("p"); - p.classList.add("popupContent"); - p.dir = dir; - const lines = str.split(/(?:\r\n?|\n)/); - for (let i = 0, ii = lines.length; i < ii; ++i) { - const line = lines[i]; - p.append(document.createTextNode(line)); - if (i < ii - 1) { - p.append(document.createElement("br")); - } - } - return p; - } - #keyDown(event) { - if (event.altKey || event.shiftKey || event.ctrlKey || event.metaKey) { - return; - } - if (event.key === "Enter" || event.key === "Escape" && this.#pinned) { - this.#toggle(); - } - } - updateEdited({ - rect, - popupContent - }) { - this.#updates ||= { - contentsObj: this.#contentsObj, - richText: this.#richText - }; - if (rect) { - this.#position = null; - } - if (popupContent) { - this.#richText = this.#makePopupContent(popupContent); - this.#contentsObj = null; - } - this.#popup?.remove(); - this.#popup = null; - } - resetEdited() { - if (!this.#updates) { - return; - } - ({ - contentsObj: this.#contentsObj, - richText: this.#richText - } = this.#updates); - this.#updates = null; - this.#popup?.remove(); - this.#popup = null; - this.#position = null; - } - #setPosition() { - if (this.#position !== null) { - return; - } - const { - page: { - view - }, - viewport: { - rawDims: { - pageWidth, - pageHeight, - pageX, - pageY - } - } - } = this.#parent; - let useParentRect = !!this.#parentRect; - let rect = useParentRect ? this.#parentRect : this.#rect; - for (const element of this.#elements) { - if (!rect || Util.intersect(element.data.rect, rect) !== null) { - rect = element.data.rect; - useParentRect = true; - break; - } - } - const normalizedRect = Util.normalizeRect([rect[0], view[3] - rect[1] + view[1], rect[2], view[3] - rect[3] + view[1]]); - const HORIZONTAL_SPACE_AFTER_ANNOTATION = 5; - const parentWidth = useParentRect ? rect[2] - rect[0] + HORIZONTAL_SPACE_AFTER_ANNOTATION : 0; - const popupLeft = normalizedRect[0] + parentWidth; - const popupTop = normalizedRect[1]; - this.#position = [100 * (popupLeft - pageX) / pageWidth, 100 * (popupTop - pageY) / pageHeight]; - const { - style - } = this.#container; - style.left = `${this.#position[0]}%`; - style.top = `${this.#position[1]}%`; - } - #toggle() { - this.#pinned = !this.#pinned; - if (this.#pinned) { - this.#show(); - this.#container.addEventListener("click", this.#boundToggle); - this.#container.addEventListener("keydown", this.#boundKeyDown); - } else { - this.#hide(); - this.#container.removeEventListener("click", this.#boundToggle); - this.#container.removeEventListener("keydown", this.#boundKeyDown); - } - } - #show() { - if (!this.#popup) { - this.render(); - } - if (!this.isVisible) { - this.#setPosition(); - this.#container.hidden = false; - this.#container.style.zIndex = parseInt(this.#container.style.zIndex) + 1000; - } else if (this.#pinned) { - this.#container.classList.add("focused"); - } - } - #hide() { - this.#container.classList.remove("focused"); - if (this.#pinned || !this.isVisible) { - return; - } - this.#container.hidden = true; - this.#container.style.zIndex = parseInt(this.#container.style.zIndex) - 1000; - } - forceHide() { - this.#wasVisible = this.isVisible; - if (!this.#wasVisible) { - return; - } - this.#container.hidden = true; - } - maybeShow() { - if (!this.#wasVisible) { - return; - } - if (!this.#popup) { - this.#show(); - } - this.#wasVisible = false; - this.#container.hidden = false; - } - get isVisible() { - return this.#container.hidden === false; - } -} -class FreeTextAnnotationElement extends AnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true - }); - this.textContent = parameters.data.textContent; - this.textPosition = parameters.data.textPosition; - this.annotationEditorType = AnnotationEditorType.FREETEXT; - } - render() { - this.container.classList.add("freeTextAnnotation"); - if (this.textContent) { - const content = document.createElement("div"); - content.classList.add("annotationTextContent"); - content.setAttribute("role", "comment"); - for (const line of this.textContent) { - const lineSpan = document.createElement("span"); - lineSpan.textContent = line; - content.append(lineSpan); - } - this.container.append(content); - } - if (!this.data.popupRef && this.hasPopupData) { - this._createPopup(); - } - this._editOnDoubleClick(); - return this.container; - } - get _isEditable() { - return this.data.hasOwnCanvas; - } -} -class LineAnnotationElement extends AnnotationElement { - #line = null; - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true - }); - } - render() { - this.container.classList.add("lineAnnotation"); - const data = this.data; - const { - width, - height - } = getRectDims(data.rect); - const svg = this.svgFactory.create(width, height, true); - const line = this.#line = this.svgFactory.createElement("svg:line"); - line.setAttribute("x1", data.rect[2] - data.lineCoordinates[0]); - line.setAttribute("y1", data.rect[3] - data.lineCoordinates[1]); - line.setAttribute("x2", data.rect[2] - data.lineCoordinates[2]); - line.setAttribute("y2", data.rect[3] - data.lineCoordinates[3]); - line.setAttribute("stroke-width", data.borderStyle.width || 1); - line.setAttribute("stroke", "transparent"); - line.setAttribute("fill", "transparent"); - svg.append(line); - this.container.append(svg); - if (!data.popupRef && this.hasPopupData) { - this._createPopup(); - } - return this.container; - } - getElementsToTriggerPopup() { - return this.#line; - } - addHighlightArea() { - this.container.classList.add("highlightArea"); - } -} -class SquareAnnotationElement extends AnnotationElement { - #square = null; - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true - }); - } - render() { - this.container.classList.add("squareAnnotation"); - const data = this.data; - const { - width, - height - } = getRectDims(data.rect); - const svg = this.svgFactory.create(width, height, true); - const borderWidth = data.borderStyle.width; - const square = this.#square = this.svgFactory.createElement("svg:rect"); - square.setAttribute("x", borderWidth / 2); - square.setAttribute("y", borderWidth / 2); - square.setAttribute("width", width - borderWidth); - square.setAttribute("height", height - borderWidth); - square.setAttribute("stroke-width", borderWidth || 1); - square.setAttribute("stroke", "transparent"); - square.setAttribute("fill", "transparent"); - svg.append(square); - this.container.append(svg); - if (!data.popupRef && this.hasPopupData) { - this._createPopup(); - } - return this.container; - } - getElementsToTriggerPopup() { - return this.#square; - } - addHighlightArea() { - this.container.classList.add("highlightArea"); - } -} -class CircleAnnotationElement extends AnnotationElement { - #circle = null; - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true - }); - } - render() { - this.container.classList.add("circleAnnotation"); - const data = this.data; - const { - width, - height - } = getRectDims(data.rect); - const svg = this.svgFactory.create(width, height, true); - const borderWidth = data.borderStyle.width; - const circle = this.#circle = this.svgFactory.createElement("svg:ellipse"); - circle.setAttribute("cx", width / 2); - circle.setAttribute("cy", height / 2); - circle.setAttribute("rx", width / 2 - borderWidth / 2); - circle.setAttribute("ry", height / 2 - borderWidth / 2); - circle.setAttribute("stroke-width", borderWidth || 1); - circle.setAttribute("stroke", "transparent"); - circle.setAttribute("fill", "transparent"); - svg.append(circle); - this.container.append(svg); - if (!data.popupRef && this.hasPopupData) { - this._createPopup(); - } - return this.container; - } - getElementsToTriggerPopup() { - return this.#circle; - } - addHighlightArea() { - this.container.classList.add("highlightArea"); - } -} -class PolylineAnnotationElement extends AnnotationElement { - #polyline = null; - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true - }); - this.containerClassName = "polylineAnnotation"; - this.svgElementName = "svg:polyline"; - } - render() { - this.container.classList.add(this.containerClassName); - const { - data: { - rect, - vertices, - borderStyle, - popupRef - } - } = this; - if (!vertices) { - return this.container; - } - const { - width, - height - } = getRectDims(rect); - const svg = this.svgFactory.create(width, height, true); - let points = []; - for (let i = 0, ii = vertices.length; i < ii; i += 2) { - const x = vertices[i] - rect[0]; - const y = rect[3] - vertices[i + 1]; - points.push(`${x},${y}`); - } - points = points.join(" "); - const polyline = this.#polyline = this.svgFactory.createElement(this.svgElementName); - polyline.setAttribute("points", points); - polyline.setAttribute("stroke-width", borderStyle.width || 1); - polyline.setAttribute("stroke", "transparent"); - polyline.setAttribute("fill", "transparent"); - svg.append(polyline); - this.container.append(svg); - if (!popupRef && this.hasPopupData) { - this._createPopup(); - } - return this.container; - } - getElementsToTriggerPopup() { - return this.#polyline; - } - addHighlightArea() { - this.container.classList.add("highlightArea"); - } -} -class PolygonAnnotationElement extends PolylineAnnotationElement { - constructor(parameters) { - super(parameters); - this.containerClassName = "polygonAnnotation"; - this.svgElementName = "svg:polygon"; - } -} -class CaretAnnotationElement extends AnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true - }); - } - render() { - this.container.classList.add("caretAnnotation"); - if (!this.data.popupRef && this.hasPopupData) { - this._createPopup(); - } - return this.container; - } -} -class InkAnnotationElement extends AnnotationElement { - #polylines = []; - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true - }); - this.containerClassName = "inkAnnotation"; - this.svgElementName = "svg:polyline"; - this.annotationEditorType = AnnotationEditorType.INK; - } - render() { - this.container.classList.add(this.containerClassName); - const { - data: { - rect, - inkLists, - borderStyle, - popupRef - } - } = this; - const { - width, - height - } = getRectDims(rect); - const svg = this.svgFactory.create(width, height, true); - for (const inkList of inkLists) { - let points = []; - for (let i = 0, ii = inkList.length; i < ii; i += 2) { - const x = inkList[i] - rect[0]; - const y = rect[3] - inkList[i + 1]; - points.push(`${x},${y}`); - } - points = points.join(" "); - const polyline = this.svgFactory.createElement(this.svgElementName); - this.#polylines.push(polyline); - polyline.setAttribute("points", points); - polyline.setAttribute("stroke-width", borderStyle.width || 1); - polyline.setAttribute("stroke", "transparent"); - polyline.setAttribute("fill", "transparent"); - if (!popupRef && this.hasPopupData) { - this._createPopup(); - } - svg.append(polyline); - } - this.container.append(svg); - return this.container; - } - getElementsToTriggerPopup() { - return this.#polylines; - } - addHighlightArea() { - this.container.classList.add("highlightArea"); - } -} -class HighlightAnnotationElement extends AnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true, - createQuadrilaterals: true - }); - } - render() { - if (!this.data.popupRef && this.hasPopupData) { - this._createPopup(); - } - this.container.classList.add("highlightAnnotation"); - return this.container; - } -} -class UnderlineAnnotationElement extends AnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true, - createQuadrilaterals: true - }); - } - render() { - if (!this.data.popupRef && this.hasPopupData) { - this._createPopup(); - } - this.container.classList.add("underlineAnnotation"); - return this.container; - } -} -class SquigglyAnnotationElement extends AnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true, - createQuadrilaterals: true - }); - } - render() { - if (!this.data.popupRef && this.hasPopupData) { - this._createPopup(); - } - this.container.classList.add("squigglyAnnotation"); - return this.container; - } -} -class StrikeOutAnnotationElement extends AnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true, - createQuadrilaterals: true - }); - } - render() { - if (!this.data.popupRef && this.hasPopupData) { - this._createPopup(); - } - this.container.classList.add("strikeoutAnnotation"); - return this.container; - } -} -class StampAnnotationElement extends AnnotationElement { - constructor(parameters) { - super(parameters, { - isRenderable: true, - ignoreBorder: true - }); - } - render() { - this.container.classList.add("stampAnnotation"); - if (!this.data.popupRef && this.hasPopupData) { - this._createPopup(); - } - return this.container; - } -} -class FileAttachmentAnnotationElement extends AnnotationElement { - #trigger = null; - constructor(parameters) { - super(parameters, { - isRenderable: true - }); - const { - file - } = this.data; - this.filename = file.filename; - this.content = file.content; - this.linkService.eventBus?.dispatch("fileattachmentannotation", { - source: this, - ...file - }); - } - render() { - this.container.classList.add("fileAttachmentAnnotation"); - const { - container, - data - } = this; - let trigger; - if (data.hasAppearance || data.fillAlpha === 0) { - trigger = document.createElement("div"); - } else { - trigger = document.createElement("img"); - trigger.src = `${this.imageResourcesPath}annotation-${/paperclip/i.test(data.name) ? "paperclip" : "pushpin"}.svg`; - if (data.fillAlpha && data.fillAlpha < 1) { - trigger.style = `filter: opacity(${Math.round(data.fillAlpha * 100)}%);`; - } - } - trigger.addEventListener("dblclick", this.#download.bind(this)); - this.#trigger = trigger; - const { - isMac - } = util_FeatureTest.platform; - container.addEventListener("keydown", evt => { - if (evt.key === "Enter" && (isMac ? evt.metaKey : evt.ctrlKey)) { - this.#download(); - } - }); - if (!data.popupRef && this.hasPopupData) { - this._createPopup(); - } else { - trigger.classList.add("popupTriggerArea"); - } - container.append(trigger); - return container; - } - getElementsToTriggerPopup() { - return this.#trigger; - } - addHighlightArea() { - this.container.classList.add("highlightArea"); - } - #download() { - this.downloadManager?.openOrDownloadData(this.content, this.filename); - } -} -class AnnotationLayer { - #accessibilityManager = null; - #annotationCanvasMap = null; - #editableAnnotations = new Map(); - constructor({ - div, - accessibilityManager, - annotationCanvasMap, - annotationEditorUIManager, - page, - viewport - }) { - this.div = div; - this.#accessibilityManager = accessibilityManager; - this.#annotationCanvasMap = annotationCanvasMap; - this.page = page; - this.viewport = viewport; - this.zIndex = 0; - this._annotationEditorUIManager = annotationEditorUIManager; - } - #appendElement(element, id) { - const contentElement = element.firstChild || element; - contentElement.id = `${AnnotationPrefix}${id}`; - this.div.append(element); - this.#accessibilityManager?.moveElementInDOM(this.div, element, contentElement, false); - } - async render(params) { - const { - annotations - } = params; - const layer = this.div; - setLayerDimensions(layer, this.viewport); - const popupToElements = new Map(); - const elementParams = { - data: null, - layer, - linkService: params.linkService, - downloadManager: params.downloadManager, - imageResourcesPath: params.imageResourcesPath || "", - renderForms: params.renderForms !== false, - svgFactory: new DOMSVGFactory(), - annotationStorage: params.annotationStorage || new AnnotationStorage(), - enableScripting: params.enableScripting === true, - hasJSActions: params.hasJSActions, - fieldObjects: params.fieldObjects, - parent: this, - elements: null - }; - for (const data of annotations) { - if (data.noHTML) { - continue; - } - const isPopupAnnotation = data.annotationType === AnnotationType.POPUP; - if (!isPopupAnnotation) { - const { - width, - height - } = getRectDims(data.rect); - if (width <= 0 || height <= 0) { - continue; - } - } else { - const elements = popupToElements.get(data.id); - if (!elements) { - continue; - } - elementParams.elements = elements; - } - elementParams.data = data; - const element = AnnotationElementFactory.create(elementParams); - if (!element.isRenderable) { - continue; - } - if (!isPopupAnnotation && data.popupRef) { - const elements = popupToElements.get(data.popupRef); - if (!elements) { - popupToElements.set(data.popupRef, [element]); - } else { - elements.push(element); - } - } - const rendered = element.render(); - if (data.hidden) { - rendered.style.visibility = "hidden"; - } - this.#appendElement(rendered, data.id); - if (element.annotationEditorType > 0) { - this.#editableAnnotations.set(element.data.id, element); - this._annotationEditorUIManager?.renderAnnotationElement(element); - } - } - this.#setAnnotationCanvasMap(); - } - update({ - viewport - }) { - const layer = this.div; - this.viewport = viewport; - setLayerDimensions(layer, { - rotation: viewport.rotation - }); - this.#setAnnotationCanvasMap(); - layer.hidden = false; - } - #setAnnotationCanvasMap() { - if (!this.#annotationCanvasMap) { - return; - } - const layer = this.div; - for (const [id, canvas] of this.#annotationCanvasMap) { - const element = layer.querySelector(`[data-annotation-id="${id}"]`); - if (!element) { - continue; - } - canvas.className = "annotationContent"; - const { - firstChild - } = element; - if (!firstChild) { - element.append(canvas); - } else if (firstChild.nodeName === "CANVAS") { - firstChild.replaceWith(canvas); - } else if (!firstChild.classList.contains("annotationContent")) { - firstChild.before(canvas); - } else { - firstChild.after(canvas); - } - } - this.#annotationCanvasMap.clear(); - } - getEditableAnnotations() { - return Array.from(this.#editableAnnotations.values()); - } - getEditableAnnotation(id) { - return this.#editableAnnotations.get(id); - } -} - -;// CONCATENATED MODULE: ./src/display/editor/freetext.js - - - - - - - -const EOL_PATTERN = /\r\n?|\n/g; -class FreeTextEditor extends AnnotationEditor { - #boundEditorDivBlur = this.editorDivBlur.bind(this); - #boundEditorDivFocus = this.editorDivFocus.bind(this); - #boundEditorDivInput = this.editorDivInput.bind(this); - #boundEditorDivKeydown = this.editorDivKeydown.bind(this); - #boundEditorDivPaste = this.editorDivPaste.bind(this); - #color; - #content = ""; - #editorDivId = `${this.id}-editor`; - #fontSize; - #initialData = null; - static _freeTextDefaultContent = ""; - static _internalPadding = 0; - static _defaultColor = null; - static _defaultFontSize = 10; - static get _keyboardManager() { - const proto = FreeTextEditor.prototype; - const arrowChecker = self => self.isEmpty(); - const small = AnnotationEditorUIManager.TRANSLATE_SMALL; - const big = AnnotationEditorUIManager.TRANSLATE_BIG; - return shadow(this, "_keyboardManager", new KeyboardManager([[["ctrl+s", "mac+meta+s", "ctrl+p", "mac+meta+p"], proto.commitOrRemove, { - bubbles: true - }], [["ctrl+Enter", "mac+meta+Enter", "Escape", "mac+Escape"], proto.commitOrRemove], [["ArrowLeft", "mac+ArrowLeft"], proto._translateEmpty, { - args: [-small, 0], - checker: arrowChecker - }], [["ctrl+ArrowLeft", "mac+shift+ArrowLeft"], proto._translateEmpty, { - args: [-big, 0], - checker: arrowChecker - }], [["ArrowRight", "mac+ArrowRight"], proto._translateEmpty, { - args: [small, 0], - checker: arrowChecker - }], [["ctrl+ArrowRight", "mac+shift+ArrowRight"], proto._translateEmpty, { - args: [big, 0], - checker: arrowChecker - }], [["ArrowUp", "mac+ArrowUp"], proto._translateEmpty, { - args: [0, -small], - checker: arrowChecker - }], [["ctrl+ArrowUp", "mac+shift+ArrowUp"], proto._translateEmpty, { - args: [0, -big], - checker: arrowChecker - }], [["ArrowDown", "mac+ArrowDown"], proto._translateEmpty, { - args: [0, small], - checker: arrowChecker - }], [["ctrl+ArrowDown", "mac+shift+ArrowDown"], proto._translateEmpty, { - args: [0, big], - checker: arrowChecker - }]])); - } - static _type = "freetext"; - static _editorType = AnnotationEditorType.FREETEXT; - constructor(params) { - super({ - ...params, - name: "freeTextEditor" - }); - this.#color = params.color || FreeTextEditor._defaultColor || AnnotationEditor._defaultLineColor; - this.#fontSize = params.fontSize || FreeTextEditor._defaultFontSize; - } - static initialize(l10n, uiManager) { - AnnotationEditor.initialize(l10n, uiManager, { - strings: ["pdfjs-free-text-default-content"] - }); - const style = getComputedStyle(document.documentElement); - this._internalPadding = parseFloat(style.getPropertyValue("--freetext-padding")); - } - static updateDefaultParams(type, value) { - switch (type) { - case AnnotationEditorParamsType.FREETEXT_SIZE: - FreeTextEditor._defaultFontSize = value; - break; - case AnnotationEditorParamsType.FREETEXT_COLOR: - FreeTextEditor._defaultColor = value; - break; - } - } - updateParams(type, value) { - switch (type) { - case AnnotationEditorParamsType.FREETEXT_SIZE: - this.#updateFontSize(value); - break; - case AnnotationEditorParamsType.FREETEXT_COLOR: - this.#updateColor(value); - break; - } - } - static get defaultPropertiesToUpdate() { - return [[AnnotationEditorParamsType.FREETEXT_SIZE, FreeTextEditor._defaultFontSize], [AnnotationEditorParamsType.FREETEXT_COLOR, FreeTextEditor._defaultColor || AnnotationEditor._defaultLineColor]]; - } - get propertiesToUpdate() { - return [[AnnotationEditorParamsType.FREETEXT_SIZE, this.#fontSize], [AnnotationEditorParamsType.FREETEXT_COLOR, this.#color]]; - } - #updateFontSize(fontSize) { - const setFontsize = size => { - this.editorDiv.style.fontSize = `calc(${size}px * var(--scale-factor))`; - this.translate(0, -(size - this.#fontSize) * this.parentScale); - this.#fontSize = size; - this.#setEditorDimensions(); - }; - const savedFontsize = this.#fontSize; - this.addCommands({ - cmd: setFontsize.bind(this, fontSize), - undo: setFontsize.bind(this, savedFontsize), - post: this._uiManager.updateUI.bind(this._uiManager, this), - mustExec: true, - type: AnnotationEditorParamsType.FREETEXT_SIZE, - overwriteIfSameType: true, - keepUndo: true - }); - } - #updateColor(color) { - const setColor = col => { - this.#color = this.editorDiv.style.color = col; - }; - const savedColor = this.#color; - this.addCommands({ - cmd: setColor.bind(this, color), - undo: setColor.bind(this, savedColor), - post: this._uiManager.updateUI.bind(this._uiManager, this), - mustExec: true, - type: AnnotationEditorParamsType.FREETEXT_COLOR, - overwriteIfSameType: true, - keepUndo: true - }); - } - _translateEmpty(x, y) { - this._uiManager.translateSelectedEditors(x, y, true); - } - getInitialTranslation() { - const scale = this.parentScale; - return [-FreeTextEditor._internalPadding * scale, -(FreeTextEditor._internalPadding + this.#fontSize) * scale]; - } - rebuild() { - if (!this.parent) { - return; - } - super.rebuild(); - if (this.div === null) { - return; - } - if (!this.isAttachedToDOM) { - this.parent.add(this); - } - } - enableEditMode() { - if (this.isInEditMode()) { - return; - } - this.parent.setEditingState(false); - this.parent.updateToolbar(AnnotationEditorType.FREETEXT); - super.enableEditMode(); - this.overlayDiv.classList.remove("enabled"); - this.editorDiv.contentEditable = true; - this._isDraggable = false; - this.div.removeAttribute("aria-activedescendant"); - this.editorDiv.addEventListener("keydown", this.#boundEditorDivKeydown); - this.editorDiv.addEventListener("focus", this.#boundEditorDivFocus); - this.editorDiv.addEventListener("blur", this.#boundEditorDivBlur); - this.editorDiv.addEventListener("input", this.#boundEditorDivInput); - this.editorDiv.addEventListener("paste", this.#boundEditorDivPaste); - } - disableEditMode() { - if (!this.isInEditMode()) { - return; - } - this.parent.setEditingState(true); - super.disableEditMode(); - this.overlayDiv.classList.add("enabled"); - this.editorDiv.contentEditable = false; - this.div.setAttribute("aria-activedescendant", this.#editorDivId); - this._isDraggable = true; - this.editorDiv.removeEventListener("keydown", this.#boundEditorDivKeydown); - this.editorDiv.removeEventListener("focus", this.#boundEditorDivFocus); - this.editorDiv.removeEventListener("blur", this.#boundEditorDivBlur); - this.editorDiv.removeEventListener("input", this.#boundEditorDivInput); - this.editorDiv.removeEventListener("paste", this.#boundEditorDivPaste); - this.div.focus({ - preventScroll: true - }); - this.isEditing = false; - this.parent.div.classList.add("freetextEditing"); - } - focusin(event) { - if (!this._focusEventsAllowed) { - return; - } - super.focusin(event); - if (event.target !== this.editorDiv) { - this.editorDiv.focus(); - } - } - onceAdded() { - if (this.width) { - return; - } - this.enableEditMode(); - this.editorDiv.focus(); - if (this._initialOptions?.isCentered) { - this.center(); - } - this._initialOptions = null; - } - isEmpty() { - return !this.editorDiv || this.editorDiv.innerText.trim() === ""; - } - remove() { - this.isEditing = false; - if (this.parent) { - this.parent.setEditingState(true); - this.parent.div.classList.add("freetextEditing"); - } - super.remove(); - } - #extractText() { - const buffer = []; - this.editorDiv.normalize(); - for (const child of this.editorDiv.childNodes) { - buffer.push(FreeTextEditor.#getNodeContent(child)); - } - return buffer.join("\n"); - } - #setEditorDimensions() { - const [parentWidth, parentHeight] = this.parentDimensions; - let rect; - if (this.isAttachedToDOM) { - rect = this.div.getBoundingClientRect(); - } else { - const { - currentLayer, - div - } = this; - const savedDisplay = div.style.display; - const savedVisibility = div.classList.contains("hidden"); - div.classList.remove("hidden"); - div.style.display = "hidden"; - currentLayer.div.append(this.div); - rect = div.getBoundingClientRect(); - div.remove(); - div.style.display = savedDisplay; - div.classList.toggle("hidden", savedVisibility); - } - if (this.rotation % 180 === this.parentRotation % 180) { - this.width = rect.width / parentWidth; - this.height = rect.height / parentHeight; - } else { - this.width = rect.height / parentWidth; - this.height = rect.width / parentHeight; - } - this.fixAndSetPosition(); - } - commit() { - if (!this.isInEditMode()) { - return; - } - super.commit(); - this.disableEditMode(); - const savedText = this.#content; - const newText = this.#content = this.#extractText().trimEnd(); - if (savedText === newText) { - return; - } - const setText = text => { - this.#content = text; - if (!text) { - this.remove(); - return; - } - this.#setContent(); - this._uiManager.rebuild(this); - this.#setEditorDimensions(); - }; - this.addCommands({ - cmd: () => { - setText(newText); - }, - undo: () => { - setText(savedText); - }, - mustExec: false - }); - this.#setEditorDimensions(); - } - shouldGetKeyboardEvents() { - return this.isInEditMode(); - } - enterInEditMode() { - this.enableEditMode(); - this.editorDiv.focus(); - } - dblclick(event) { - this.enterInEditMode(); - } - keydown(event) { - if (event.target === this.div && event.key === "Enter") { - this.enterInEditMode(); - event.preventDefault(); - } - } - editorDivKeydown(event) { - FreeTextEditor._keyboardManager.exec(this, event); - } - editorDivFocus(event) { - this.isEditing = true; - } - editorDivBlur(event) { - this.isEditing = false; - } - editorDivInput(event) { - this.parent.div.classList.toggle("freetextEditing", this.isEmpty()); - } - disableEditing() { - this.editorDiv.setAttribute("role", "comment"); - this.editorDiv.removeAttribute("aria-multiline"); - } - enableEditing() { - this.editorDiv.setAttribute("role", "textbox"); - this.editorDiv.setAttribute("aria-multiline", true); - } - render() { - if (this.div) { - return this.div; - } - let baseX, baseY; - if (this.width) { - baseX = this.x; - baseY = this.y; - } - super.render(); - this.editorDiv = document.createElement("div"); - this.editorDiv.className = "internal"; - this.editorDiv.setAttribute("id", this.#editorDivId); - this.editorDiv.setAttribute("data-l10n-id", "pdfjs-free-text"); - this.enableEditing(); - AnnotationEditor._l10nPromise.get("pdfjs-free-text-default-content").then(msg => this.editorDiv?.setAttribute("default-content", msg)); - this.editorDiv.contentEditable = true; - const { - style - } = this.editorDiv; - style.fontSize = `calc(${this.#fontSize}px * var(--scale-factor))`; - style.color = this.#color; - this.div.append(this.editorDiv); - this.overlayDiv = document.createElement("div"); - this.overlayDiv.classList.add("overlay", "enabled"); - this.div.append(this.overlayDiv); - bindEvents(this, this.div, ["dblclick", "keydown"]); - if (this.width) { - const [parentWidth, parentHeight] = this.parentDimensions; - if (this.annotationElementId) { - const { - position - } = this.#initialData; - let [tx, ty] = this.getInitialTranslation(); - [tx, ty] = this.pageTranslationToScreen(tx, ty); - const [pageWidth, pageHeight] = this.pageDimensions; - const [pageX, pageY] = this.pageTranslation; - let posX, posY; - switch (this.rotation) { - case 0: - posX = baseX + (position[0] - pageX) / pageWidth; - posY = baseY + this.height - (position[1] - pageY) / pageHeight; - break; - case 90: - posX = baseX + (position[0] - pageX) / pageWidth; - posY = baseY - (position[1] - pageY) / pageHeight; - [tx, ty] = [ty, -tx]; - break; - case 180: - posX = baseX - this.width + (position[0] - pageX) / pageWidth; - posY = baseY - (position[1] - pageY) / pageHeight; - [tx, ty] = [-tx, -ty]; - break; - case 270: - posX = baseX + (position[0] - pageX - this.height * pageHeight) / pageWidth; - posY = baseY + (position[1] - pageY - this.width * pageWidth) / pageHeight; - [tx, ty] = [-ty, tx]; - break; - } - this.setAt(posX * parentWidth, posY * parentHeight, tx, ty); - } else { - this.setAt(baseX * parentWidth, baseY * parentHeight, this.width * parentWidth, this.height * parentHeight); - } - this.#setContent(); - this._isDraggable = true; - this.editorDiv.contentEditable = false; - } else { - this._isDraggable = false; - this.editorDiv.contentEditable = true; - } - return this.div; - } - static #getNodeContent(node) { - return (node.nodeType === Node.TEXT_NODE ? node.nodeValue : node.innerText).replaceAll(EOL_PATTERN, ""); - } - editorDivPaste(event) { - const clipboardData = event.clipboardData || window.clipboardData; - const { - types - } = clipboardData; - if (types.length === 1 && types[0] === "text/plain") { - return; - } - event.preventDefault(); - const paste = FreeTextEditor.#deserializeContent(clipboardData.getData("text") || "").replaceAll(EOL_PATTERN, "\n"); - if (!paste) { - return; - } - const selection = window.getSelection(); - if (!selection.rangeCount) { - return; - } - this.editorDiv.normalize(); - selection.deleteFromDocument(); - const range = selection.getRangeAt(0); - if (!paste.includes("\n")) { - range.insertNode(document.createTextNode(paste)); - this.editorDiv.normalize(); - selection.collapseToStart(); - return; - } - const { - startContainer, - startOffset - } = range; - const bufferBefore = []; - const bufferAfter = []; - if (startContainer.nodeType === Node.TEXT_NODE) { - const parent = startContainer.parentElement; - bufferAfter.push(startContainer.nodeValue.slice(startOffset).replaceAll(EOL_PATTERN, "")); - if (parent !== this.editorDiv) { - let buffer = bufferBefore; - for (const child of this.editorDiv.childNodes) { - if (child === parent) { - buffer = bufferAfter; - continue; - } - buffer.push(FreeTextEditor.#getNodeContent(child)); - } - } - bufferBefore.push(startContainer.nodeValue.slice(0, startOffset).replaceAll(EOL_PATTERN, "")); - } else if (startContainer === this.editorDiv) { - let buffer = bufferBefore; - let i = 0; - for (const child of this.editorDiv.childNodes) { - if (i++ === startOffset) { - buffer = bufferAfter; - } - buffer.push(FreeTextEditor.#getNodeContent(child)); - } - } - this.#content = `${bufferBefore.join("\n")}${paste}${bufferAfter.join("\n")}`; - this.#setContent(); - const newRange = new Range(); - let beforeLength = bufferBefore.reduce((acc, line) => acc + line.length, 0); - for (const { - firstChild - } of this.editorDiv.childNodes) { - if (firstChild.nodeType === Node.TEXT_NODE) { - const length = firstChild.nodeValue.length; - if (beforeLength <= length) { - newRange.setStart(firstChild, beforeLength); - newRange.setEnd(firstChild, beforeLength); - break; - } - beforeLength -= length; - } - } - selection.removeAllRanges(); - selection.addRange(newRange); - } - #setContent() { - this.editorDiv.replaceChildren(); - if (!this.#content) { - return; - } - for (const line of this.#content.split("\n")) { - const div = document.createElement("div"); - div.append(line ? document.createTextNode(line) : document.createElement("br")); - this.editorDiv.append(div); - } - } - #serializeContent() { - return this.#content.replaceAll("\xa0", " "); - } - static #deserializeContent(content) { - return content.replaceAll(" ", "\xa0"); - } - get contentDiv() { - return this.editorDiv; - } - static deserialize(data, parent, uiManager) { - let initialData = null; - if (data instanceof FreeTextAnnotationElement) { - const { - data: { - defaultAppearanceData: { - fontSize, - fontColor - }, - rect, - rotation, - id - }, - textContent, - textPosition, - parent: { - page: { - pageNumber - } - } - } = data; - if (!textContent || textContent.length === 0) { - return null; - } - initialData = data = { - annotationType: AnnotationEditorType.FREETEXT, - color: Array.from(fontColor), - fontSize, - value: textContent.join("\n"), - position: textPosition, - pageIndex: pageNumber - 1, - rect: rect.slice(0), - rotation, - id, - deleted: false - }; - } - const editor = super.deserialize(data, parent, uiManager); - editor.#fontSize = data.fontSize; - editor.#color = Util.makeHexColor(...data.color); - editor.#content = FreeTextEditor.#deserializeContent(data.value); - editor.annotationElementId = data.id || null; - editor.#initialData = initialData; - return editor; - } - serialize(isForCopying = false) { - if (this.isEmpty()) { - return null; - } - if (this.deleted) { - return { - pageIndex: this.pageIndex, - id: this.annotationElementId, - deleted: true - }; - } - const padding = FreeTextEditor._internalPadding * this.parentScale; - const rect = this.getRect(padding, padding); - const color = AnnotationEditor._colorManager.convert(this.isAttachedToDOM ? getComputedStyle(this.editorDiv).color : this.#color); - const serialized = { - annotationType: AnnotationEditorType.FREETEXT, - color, - fontSize: this.#fontSize, - value: this.#serializeContent(), - pageIndex: this.pageIndex, - rect, - rotation: this.rotation, - structTreeParentId: this._structTreeParentId - }; - if (isForCopying) { - return serialized; - } - if (this.annotationElementId && !this.#hasElementChanged(serialized)) { - return null; - } - serialized.id = this.annotationElementId; - return serialized; - } - #hasElementChanged(serialized) { - const { - value, - fontSize, - color, - pageIndex - } = this.#initialData; - return this._hasBeenMoved || serialized.value !== value || serialized.fontSize !== fontSize || serialized.color.some((c, i) => c !== color[i]) || serialized.pageIndex !== pageIndex; - } - renderAnnotationElement(annotation) { - const content = super.renderAnnotationElement(annotation); - if (this.deleted) { - return content; - } - const { - style - } = content; - style.fontSize = `calc(${this.#fontSize}px * var(--scale-factor))`; - style.color = this.#color; - content.replaceChildren(); - for (const line of this.#content.split("\n")) { - const div = document.createElement("div"); - div.append(line ? document.createTextNode(line) : document.createElement("br")); - content.append(div); - } - const padding = FreeTextEditor._internalPadding * this.parentScale; - annotation.updateEdited({ - rect: this.getRect(padding, padding), - popupContent: this.#content - }); - return content; - } - resetAnnotationElement(annotation) { - super.resetAnnotationElement(annotation); - annotation.resetEdited(); - } -} - -;// CONCATENATED MODULE: ./src/display/editor/outliner.js - - - - - - - - - - - - - - - -class Outliner { - #box; - #verticalEdges = []; - #intervals = []; - constructor(boxes, borderWidth = 0, innerMargin = 0, isLTR = true) { - let minX = Infinity; - let maxX = -Infinity; - let minY = Infinity; - let maxY = -Infinity; - const NUMBER_OF_DIGITS = 4; - const EPSILON = 10 ** -NUMBER_OF_DIGITS; - for (const { - x, - y, - width, - height - } of boxes) { - const x1 = Math.floor((x - borderWidth) / EPSILON) * EPSILON; - const x2 = Math.ceil((x + width + borderWidth) / EPSILON) * EPSILON; - const y1 = Math.floor((y - borderWidth) / EPSILON) * EPSILON; - const y2 = Math.ceil((y + height + borderWidth) / EPSILON) * EPSILON; - const left = [x1, y1, y2, true]; - const right = [x2, y1, y2, false]; - this.#verticalEdges.push(left, right); - minX = Math.min(minX, x1); - maxX = Math.max(maxX, x2); - minY = Math.min(minY, y1); - maxY = Math.max(maxY, y2); - } - const bboxWidth = maxX - minX + 2 * innerMargin; - const bboxHeight = maxY - minY + 2 * innerMargin; - const shiftedMinX = minX - innerMargin; - const shiftedMinY = minY - innerMargin; - const lastEdge = this.#verticalEdges.at(isLTR ? -1 : -2); - const lastPoint = [lastEdge[0], lastEdge[2]]; - for (const edge of this.#verticalEdges) { - const [x, y1, y2] = edge; - edge[0] = (x - shiftedMinX) / bboxWidth; - edge[1] = (y1 - shiftedMinY) / bboxHeight; - edge[2] = (y2 - shiftedMinY) / bboxHeight; - } - this.#box = { - x: shiftedMinX, - y: shiftedMinY, - width: bboxWidth, - height: bboxHeight, - lastPoint - }; - } - getOutlines() { - this.#verticalEdges.sort((a, b) => a[0] - b[0] || a[1] - b[1] || a[2] - b[2]); - const outlineVerticalEdges = []; - for (const edge of this.#verticalEdges) { - if (edge[3]) { - outlineVerticalEdges.push(...this.#breakEdge(edge)); - this.#insert(edge); - } else { - this.#remove(edge); - outlineVerticalEdges.push(...this.#breakEdge(edge)); - } - } - return this.#getOutlines(outlineVerticalEdges); - } - #getOutlines(outlineVerticalEdges) { - const edges = []; - const allEdges = new Set(); - for (const edge of outlineVerticalEdges) { - const [x, y1, y2] = edge; - edges.push([x, y1, edge], [x, y2, edge]); - } - edges.sort((a, b) => a[1] - b[1] || a[0] - b[0]); - for (let i = 0, ii = edges.length; i < ii; i += 2) { - const edge1 = edges[i][2]; - const edge2 = edges[i + 1][2]; - edge1.push(edge2); - edge2.push(edge1); - allEdges.add(edge1); - allEdges.add(edge2); - } - const outlines = []; - let outline; - while (allEdges.size > 0) { - const edge = allEdges.values().next().value; - let [x, y1, y2, edge1, edge2] = edge; - allEdges.delete(edge); - let lastPointX = x; - let lastPointY = y1; - outline = [x, y2]; - outlines.push(outline); - while (true) { - let e; - if (allEdges.has(edge1)) { - e = edge1; - } else if (allEdges.has(edge2)) { - e = edge2; - } else { - break; - } - allEdges.delete(e); - [x, y1, y2, edge1, edge2] = e; - if (lastPointX !== x) { - outline.push(lastPointX, lastPointY, x, lastPointY === y1 ? y1 : y2); - lastPointX = x; - } - lastPointY = lastPointY === y1 ? y2 : y1; - } - outline.push(lastPointX, lastPointY); - } - return new HighlightOutline(outlines, this.#box); - } - #binarySearch(y) { - const array = this.#intervals; - let start = 0; - let end = array.length - 1; - while (start <= end) { - const middle = start + end >> 1; - const y1 = array[middle][0]; - if (y1 === y) { - return middle; - } - if (y1 < y) { - start = middle + 1; - } else { - end = middle - 1; - } - } - return end + 1; - } - #insert([, y1, y2]) { - const index = this.#binarySearch(y1); - this.#intervals.splice(index, 0, [y1, y2]); - } - #remove([, y1, y2]) { - const index = this.#binarySearch(y1); - for (let i = index; i < this.#intervals.length; i++) { - const [start, end] = this.#intervals[i]; - if (start !== y1) { - break; - } - if (start === y1 && end === y2) { - this.#intervals.splice(i, 1); - return; - } - } - for (let i = index - 1; i >= 0; i--) { - const [start, end] = this.#intervals[i]; - if (start !== y1) { - break; - } - if (start === y1 && end === y2) { - this.#intervals.splice(i, 1); - return; - } - } - } - #breakEdge(edge) { - const [x, y1, y2] = edge; - const results = [[x, y1, y2]]; - const index = this.#binarySearch(y2); - for (let i = 0; i < index; i++) { - const [start, end] = this.#intervals[i]; - for (let j = 0, jj = results.length; j < jj; j++) { - const [, y3, y4] = results[j]; - if (end <= y3 || y4 <= start) { - continue; - } - if (y3 >= start) { - if (y4 > end) { - results[j][1] = end; - } else { - if (jj === 1) { - return []; - } - results.splice(j, 1); - j--; - jj--; - } - continue; - } - results[j][2] = start; - if (y4 > end) { - results.push([x, end, y4]); - } - } - } - return results; - } -} -class Outline { - toSVGPath() { - throw new Error("Abstract method `toSVGPath` must be implemented."); - } - get box() { - throw new Error("Abstract getter `box` must be implemented."); - } - serialize(_bbox, _rotation) { - throw new Error("Abstract method `serialize` must be implemented."); - } - get free() { - return this instanceof FreeHighlightOutline; - } -} -class HighlightOutline extends Outline { - #box; - #outlines; - constructor(outlines, box) { - super(); - this.#outlines = outlines; - this.#box = box; - } - toSVGPath() { - const buffer = []; - for (const polygon of this.#outlines) { - let [prevX, prevY] = polygon; - buffer.push(`M${prevX} ${prevY}`); - for (let i = 2; i < polygon.length; i += 2) { - const x = polygon[i]; - const y = polygon[i + 1]; - if (x === prevX) { - buffer.push(`V${y}`); - prevY = y; - } else if (y === prevY) { - buffer.push(`H${x}`); - prevX = x; - } - } - buffer.push("Z"); - } - return buffer.join(" "); - } - serialize([blX, blY, trX, trY], _rotation) { - const outlines = []; - const width = trX - blX; - const height = trY - blY; - for (const outline of this.#outlines) { - const points = new Array(outline.length); - for (let i = 0; i < outline.length; i += 2) { - points[i] = blX + outline[i] * width; - points[i + 1] = trY - outline[i + 1] * height; - } - outlines.push(points); - } - return outlines; - } - get box() { - return this.#box; - } -} -class FreeOutliner { - #box; - #bottom = []; - #innerMargin; - #isLTR; - #top = []; - #last = new Float64Array(18); - #lastX; - #lastY; - #min; - #min_dist; - #scaleFactor; - #thickness; - #points = []; - static #MIN_DIST = 8; - static #MIN_DIFF = 2; - static #MIN = FreeOutliner.#MIN_DIST + FreeOutliner.#MIN_DIFF; - constructor({ - x, - y - }, box, scaleFactor, thickness, isLTR, innerMargin = 0) { - this.#box = box; - this.#thickness = thickness * scaleFactor; - this.#isLTR = isLTR; - this.#last.set([NaN, NaN, NaN, NaN, x, y], 6); - this.#innerMargin = innerMargin; - this.#min_dist = FreeOutliner.#MIN_DIST * scaleFactor; - this.#min = FreeOutliner.#MIN * scaleFactor; - this.#scaleFactor = scaleFactor; - this.#points.push(x, y); - } - get free() { - return true; - } - isEmpty() { - return isNaN(this.#last[8]); - } - #getLastCoords() { - const lastTop = this.#last.subarray(4, 6); - const lastBottom = this.#last.subarray(16, 18); - const [x, y, width, height] = this.#box; - return [(this.#lastX + (lastTop[0] - lastBottom[0]) / 2 - x) / width, (this.#lastY + (lastTop[1] - lastBottom[1]) / 2 - y) / height, (this.#lastX + (lastBottom[0] - lastTop[0]) / 2 - x) / width, (this.#lastY + (lastBottom[1] - lastTop[1]) / 2 - y) / height]; - } - add({ - x, - y - }) { - this.#lastX = x; - this.#lastY = y; - const [layerX, layerY, layerWidth, layerHeight] = this.#box; - let [x1, y1, x2, y2] = this.#last.subarray(8, 12); - const diffX = x - x2; - const diffY = y - y2; - const d = Math.hypot(diffX, diffY); - if (d < this.#min) { - return false; - } - const diffD = d - this.#min_dist; - const K = diffD / d; - const shiftX = K * diffX; - const shiftY = K * diffY; - let x0 = x1; - let y0 = y1; - x1 = x2; - y1 = y2; - x2 += shiftX; - y2 += shiftY; - this.#points?.push(x, y); - const nX = -shiftY / diffD; - const nY = shiftX / diffD; - const thX = nX * this.#thickness; - const thY = nY * this.#thickness; - this.#last.set(this.#last.subarray(2, 8), 0); - this.#last.set([x2 + thX, y2 + thY], 4); - this.#last.set(this.#last.subarray(14, 18), 12); - this.#last.set([x2 - thX, y2 - thY], 16); - if (isNaN(this.#last[6])) { - if (this.#top.length === 0) { - this.#last.set([x1 + thX, y1 + thY], 2); - this.#top.push(NaN, NaN, NaN, NaN, (x1 + thX - layerX) / layerWidth, (y1 + thY - layerY) / layerHeight); - this.#last.set([x1 - thX, y1 - thY], 14); - this.#bottom.push(NaN, NaN, NaN, NaN, (x1 - thX - layerX) / layerWidth, (y1 - thY - layerY) / layerHeight); - } - this.#last.set([x0, y0, x1, y1, x2, y2], 6); - return !this.isEmpty(); - } - this.#last.set([x0, y0, x1, y1, x2, y2], 6); - const angle = Math.abs(Math.atan2(y0 - y1, x0 - x1) - Math.atan2(shiftY, shiftX)); - if (angle < Math.PI / 2) { - [x1, y1, x2, y2] = this.#last.subarray(2, 6); - this.#top.push(NaN, NaN, NaN, NaN, ((x1 + x2) / 2 - layerX) / layerWidth, ((y1 + y2) / 2 - layerY) / layerHeight); - [x1, y1, x0, y0] = this.#last.subarray(14, 18); - this.#bottom.push(NaN, NaN, NaN, NaN, ((x0 + x1) / 2 - layerX) / layerWidth, ((y0 + y1) / 2 - layerY) / layerHeight); - return true; - } - [x0, y0, x1, y1, x2, y2] = this.#last.subarray(0, 6); - this.#top.push(((x0 + 5 * x1) / 6 - layerX) / layerWidth, ((y0 + 5 * y1) / 6 - layerY) / layerHeight, ((5 * x1 + x2) / 6 - layerX) / layerWidth, ((5 * y1 + y2) / 6 - layerY) / layerHeight, ((x1 + x2) / 2 - layerX) / layerWidth, ((y1 + y2) / 2 - layerY) / layerHeight); - [x2, y2, x1, y1, x0, y0] = this.#last.subarray(12, 18); - this.#bottom.push(((x0 + 5 * x1) / 6 - layerX) / layerWidth, ((y0 + 5 * y1) / 6 - layerY) / layerHeight, ((5 * x1 + x2) / 6 - layerX) / layerWidth, ((5 * y1 + y2) / 6 - layerY) / layerHeight, ((x1 + x2) / 2 - layerX) / layerWidth, ((y1 + y2) / 2 - layerY) / layerHeight); - return true; - } - toSVGPath() { - if (this.isEmpty()) { - return ""; - } - const top = this.#top; - const bottom = this.#bottom; - const lastTop = this.#last.subarray(4, 6); - const lastBottom = this.#last.subarray(16, 18); - const [x, y, width, height] = this.#box; - const [lastTopX, lastTopY, lastBottomX, lastBottomY] = this.#getLastCoords(); - if (isNaN(this.#last[6]) && !this.isEmpty()) { - return `M${(this.#last[2] - x) / width} ${(this.#last[3] - y) / height} L${(this.#last[4] - x) / width} ${(this.#last[5] - y) / height} L${lastTopX} ${lastTopY} L${lastBottomX} ${lastBottomY} L${(this.#last[16] - x) / width} ${(this.#last[17] - y) / height} L${(this.#last[14] - x) / width} ${(this.#last[15] - y) / height} Z`; - } - const buffer = []; - buffer.push(`M${top[4]} ${top[5]}`); - for (let i = 6; i < top.length; i += 6) { - if (isNaN(top[i])) { - buffer.push(`L${top[i + 4]} ${top[i + 5]}`); - } else { - buffer.push(`C${top[i]} ${top[i + 1]} ${top[i + 2]} ${top[i + 3]} ${top[i + 4]} ${top[i + 5]}`); - } - } - buffer.push(`L${(lastTop[0] - x) / width} ${(lastTop[1] - y) / height} L${lastTopX} ${lastTopY} L${lastBottomX} ${lastBottomY} L${(lastBottom[0] - x) / width} ${(lastBottom[1] - y) / height}`); - for (let i = bottom.length - 6; i >= 6; i -= 6) { - if (isNaN(bottom[i])) { - buffer.push(`L${bottom[i + 4]} ${bottom[i + 5]}`); - } else { - buffer.push(`C${bottom[i]} ${bottom[i + 1]} ${bottom[i + 2]} ${bottom[i + 3]} ${bottom[i + 4]} ${bottom[i + 5]}`); - } - } - buffer.push(`L${bottom[4]} ${bottom[5]} Z`); - return buffer.join(" "); - } - getOutlines() { - const top = this.#top; - const bottom = this.#bottom; - const last = this.#last; - const lastTop = last.subarray(4, 6); - const lastBottom = last.subarray(16, 18); - const [layerX, layerY, layerWidth, layerHeight] = this.#box; - const points = new Float64Array((this.#points?.length ?? 0) + 2); - for (let i = 0, ii = points.length - 2; i < ii; i += 2) { - points[i] = (this.#points[i] - layerX) / layerWidth; - points[i + 1] = (this.#points[i + 1] - layerY) / layerHeight; - } - points[points.length - 2] = (this.#lastX - layerX) / layerWidth; - points[points.length - 1] = (this.#lastY - layerY) / layerHeight; - const [lastTopX, lastTopY, lastBottomX, lastBottomY] = this.#getLastCoords(); - if (isNaN(last[6]) && !this.isEmpty()) { - const outline = new Float64Array(36); - outline.set([NaN, NaN, NaN, NaN, (last[2] - layerX) / layerWidth, (last[3] - layerY) / layerHeight, NaN, NaN, NaN, NaN, (last[4] - layerX) / layerWidth, (last[5] - layerY) / layerHeight, NaN, NaN, NaN, NaN, lastTopX, lastTopY, NaN, NaN, NaN, NaN, lastBottomX, lastBottomY, NaN, NaN, NaN, NaN, (last[16] - layerX) / layerWidth, (last[17] - layerY) / layerHeight, NaN, NaN, NaN, NaN, (last[14] - layerX) / layerWidth, (last[15] - layerY) / layerHeight], 0); - return new FreeHighlightOutline(outline, points, this.#box, this.#scaleFactor, this.#innerMargin, this.#isLTR); - } - const outline = new Float64Array(this.#top.length + 24 + this.#bottom.length); - let N = top.length; - for (let i = 0; i < N; i += 2) { - if (isNaN(top[i])) { - outline[i] = outline[i + 1] = NaN; - continue; - } - outline[i] = top[i]; - outline[i + 1] = top[i + 1]; - } - outline.set([NaN, NaN, NaN, NaN, (lastTop[0] - layerX) / layerWidth, (lastTop[1] - layerY) / layerHeight, NaN, NaN, NaN, NaN, lastTopX, lastTopY, NaN, NaN, NaN, NaN, lastBottomX, lastBottomY, NaN, NaN, NaN, NaN, (lastBottom[0] - layerX) / layerWidth, (lastBottom[1] - layerY) / layerHeight], N); - N += 24; - for (let i = bottom.length - 6; i >= 6; i -= 6) { - for (let j = 0; j < 6; j += 2) { - if (isNaN(bottom[i + j])) { - outline[N] = outline[N + 1] = NaN; - N += 2; - continue; - } - outline[N] = bottom[i + j]; - outline[N + 1] = bottom[i + j + 1]; - N += 2; - } - } - outline.set([NaN, NaN, NaN, NaN, bottom[4], bottom[5]], N); - return new FreeHighlightOutline(outline, points, this.#box, this.#scaleFactor, this.#innerMargin, this.#isLTR); - } -} -class FreeHighlightOutline extends Outline { - #box; - #bbox = null; - #innerMargin; - #isLTR; - #points; - #scaleFactor; - #outline; - constructor(outline, points, box, scaleFactor, innerMargin, isLTR) { - super(); - this.#outline = outline; - this.#points = points; - this.#box = box; - this.#scaleFactor = scaleFactor; - this.#innerMargin = innerMargin; - this.#isLTR = isLTR; - this.#computeMinMax(isLTR); - const { - x, - y, - width, - height - } = this.#bbox; - for (let i = 0, ii = outline.length; i < ii; i += 2) { - outline[i] = (outline[i] - x) / width; - outline[i + 1] = (outline[i + 1] - y) / height; - } - for (let i = 0, ii = points.length; i < ii; i += 2) { - points[i] = (points[i] - x) / width; - points[i + 1] = (points[i + 1] - y) / height; - } - } - toSVGPath() { - const buffer = [`M${this.#outline[4]} ${this.#outline[5]}`]; - for (let i = 6, ii = this.#outline.length; i < ii; i += 6) { - if (isNaN(this.#outline[i])) { - buffer.push(`L${this.#outline[i + 4]} ${this.#outline[i + 5]}`); - continue; - } - buffer.push(`C${this.#outline[i]} ${this.#outline[i + 1]} ${this.#outline[i + 2]} ${this.#outline[i + 3]} ${this.#outline[i + 4]} ${this.#outline[i + 5]}`); - } - buffer.push("Z"); - return buffer.join(" "); - } - serialize([blX, blY, trX, trY], rotation) { - const width = trX - blX; - const height = trY - blY; - let outline; - let points; - switch (rotation) { - case 0: - outline = this.#rescale(this.#outline, blX, trY, width, -height); - points = this.#rescale(this.#points, blX, trY, width, -height); - break; - case 90: - outline = this.#rescaleAndSwap(this.#outline, blX, blY, width, height); - points = this.#rescaleAndSwap(this.#points, blX, blY, width, height); - break; - case 180: - outline = this.#rescale(this.#outline, trX, blY, -width, height); - points = this.#rescale(this.#points, trX, blY, -width, height); - break; - case 270: - outline = this.#rescaleAndSwap(this.#outline, trX, trY, -width, -height); - points = this.#rescaleAndSwap(this.#points, trX, trY, -width, -height); - break; - } - return { - outline: Array.from(outline), - points: [Array.from(points)] - }; - } - #rescale(src, tx, ty, sx, sy) { - const dest = new Float64Array(src.length); - for (let i = 0, ii = src.length; i < ii; i += 2) { - dest[i] = tx + src[i] * sx; - dest[i + 1] = ty + src[i + 1] * sy; - } - return dest; - } - #rescaleAndSwap(src, tx, ty, sx, sy) { - const dest = new Float64Array(src.length); - for (let i = 0, ii = src.length; i < ii; i += 2) { - dest[i] = tx + src[i + 1] * sx; - dest[i + 1] = ty + src[i] * sy; - } - return dest; - } - #computeMinMax(isLTR) { - const outline = this.#outline; - let lastX = outline[4]; - let lastY = outline[5]; - let minX = lastX; - let minY = lastY; - let maxX = lastX; - let maxY = lastY; - let lastPointX = lastX; - let lastPointY = lastY; - const ltrCallback = isLTR ? Math.max : Math.min; - for (let i = 6, ii = outline.length; i < ii; i += 6) { - if (isNaN(outline[i])) { - minX = Math.min(minX, outline[i + 4]); - minY = Math.min(minY, outline[i + 5]); - maxX = Math.max(maxX, outline[i + 4]); - maxY = Math.max(maxY, outline[i + 5]); - if (lastPointY < outline[i + 5]) { - lastPointX = outline[i + 4]; - lastPointY = outline[i + 5]; - } else if (lastPointY === outline[i + 5]) { - lastPointX = ltrCallback(lastPointX, outline[i + 4]); - } - } else { - const bbox = Util.bezierBoundingBox(lastX, lastY, ...outline.slice(i, i + 6)); - minX = Math.min(minX, bbox[0]); - minY = Math.min(minY, bbox[1]); - maxX = Math.max(maxX, bbox[2]); - maxY = Math.max(maxY, bbox[3]); - if (lastPointY < bbox[3]) { - lastPointX = bbox[2]; - lastPointY = bbox[3]; - } else if (lastPointY === bbox[3]) { - lastPointX = ltrCallback(lastPointX, bbox[2]); - } - } - lastX = outline[i + 4]; - lastY = outline[i + 5]; - } - const x = minX - this.#innerMargin, - y = minY - this.#innerMargin, - width = maxX - minX + 2 * this.#innerMargin, - height = maxY - minY + 2 * this.#innerMargin; - this.#bbox = { - x, - y, - width, - height, - lastPoint: [lastPointX, lastPointY] - }; - } - get box() { - return this.#bbox; - } - getNewOutline(thickness, innerMargin) { - const { - x, - y, - width, - height - } = this.#bbox; - const [layerX, layerY, layerWidth, layerHeight] = this.#box; - const sx = width * layerWidth; - const sy = height * layerHeight; - const tx = x * layerWidth + layerX; - const ty = y * layerHeight + layerY; - const outliner = new FreeOutliner({ - x: this.#points[0] * sx + tx, - y: this.#points[1] * sy + ty - }, this.#box, this.#scaleFactor, thickness, this.#isLTR, innerMargin ?? this.#innerMargin); - for (let i = 2; i < this.#points.length; i += 2) { - outliner.add({ - x: this.#points[i] * sx + tx, - y: this.#points[i + 1] * sy + ty - }); - } - return outliner.getOutlines(); - } -} - -;// CONCATENATED MODULE: ./src/display/editor/color_picker.js - - - -class ColorPicker { - #boundKeyDown = this.#keyDown.bind(this); - #boundPointerDown = this.#pointerDown.bind(this); - #button = null; - #buttonSwatch = null; - #defaultColor; - #dropdown = null; - #dropdownWasFromKeyboard = false; - #isMainColorPicker = false; - #editor = null; - #eventBus; - #uiManager = null; - #type; - static get _keyboardManager() { - return shadow(this, "_keyboardManager", new KeyboardManager([[["Escape", "mac+Escape"], ColorPicker.prototype._hideDropdownFromKeyboard], [[" ", "mac+ "], ColorPicker.prototype._colorSelectFromKeyboard], [["ArrowDown", "ArrowRight", "mac+ArrowDown", "mac+ArrowRight"], ColorPicker.prototype._moveToNext], [["ArrowUp", "ArrowLeft", "mac+ArrowUp", "mac+ArrowLeft"], ColorPicker.prototype._moveToPrevious], [["Home", "mac+Home"], ColorPicker.prototype._moveToBeginning], [["End", "mac+End"], ColorPicker.prototype._moveToEnd]])); - } - constructor({ - editor = null, - uiManager = null - }) { - if (editor) { - this.#isMainColorPicker = false; - this.#type = AnnotationEditorParamsType.HIGHLIGHT_COLOR; - this.#editor = editor; - } else { - this.#isMainColorPicker = true; - this.#type = AnnotationEditorParamsType.HIGHLIGHT_DEFAULT_COLOR; - } - this.#uiManager = editor?._uiManager || uiManager; - this.#eventBus = this.#uiManager._eventBus; - this.#defaultColor = editor?.color || this.#uiManager?.highlightColors.values().next().value || "#FFFF98"; - } - renderButton() { - const button = this.#button = document.createElement("button"); - button.className = "colorPicker"; - button.tabIndex = "0"; - button.setAttribute("data-l10n-id", "pdfjs-editor-colorpicker-button"); - button.setAttribute("aria-haspopup", true); - button.addEventListener("click", this.#openDropdown.bind(this)); - button.addEventListener("keydown", this.#boundKeyDown); - const swatch = this.#buttonSwatch = document.createElement("span"); - swatch.className = "swatch"; - swatch.setAttribute("aria-hidden", true); - swatch.style.backgroundColor = this.#defaultColor; - button.append(swatch); - return button; - } - renderMainDropdown() { - const dropdown = this.#dropdown = this.#getDropdownRoot(); - dropdown.setAttribute("aria-orientation", "horizontal"); - dropdown.setAttribute("aria-labelledby", "highlightColorPickerLabel"); - return dropdown; - } - #getDropdownRoot() { - const div = document.createElement("div"); - div.addEventListener("contextmenu", noContextMenu); - div.className = "dropdown"; - div.role = "listbox"; - div.setAttribute("aria-multiselectable", false); - div.setAttribute("aria-orientation", "vertical"); - div.setAttribute("data-l10n-id", "pdfjs-editor-colorpicker-dropdown"); - for (const [name, color] of this.#uiManager.highlightColors) { - const button = document.createElement("button"); - button.tabIndex = "0"; - button.role = "option"; - button.setAttribute("data-color", color); - button.title = name; - button.setAttribute("data-l10n-id", `pdfjs-editor-colorpicker-${name}`); - const swatch = document.createElement("span"); - button.append(swatch); - swatch.className = "swatch"; - swatch.style.backgroundColor = color; - button.setAttribute("aria-selected", color === this.#defaultColor); - button.addEventListener("click", this.#colorSelect.bind(this, color)); - div.append(button); - } - div.addEventListener("keydown", this.#boundKeyDown); - return div; - } - #colorSelect(color, event) { - event.stopPropagation(); - this.#eventBus.dispatch("switchannotationeditorparams", { - source: this, - type: this.#type, - value: color - }); - } - _colorSelectFromKeyboard(event) { - if (event.target === this.#button) { - this.#openDropdown(event); - return; - } - const color = event.target.getAttribute("data-color"); - if (!color) { - return; - } - this.#colorSelect(color, event); - } - _moveToNext(event) { - if (!this.#isDropdownVisible) { - this.#openDropdown(event); - return; - } - if (event.target === this.#button) { - this.#dropdown.firstChild?.focus(); - return; - } - event.target.nextSibling?.focus(); - } - _moveToPrevious(event) { - if (event.target === this.#dropdown?.firstChild || event.target === this.#button) { - if (this.#isDropdownVisible) { - this._hideDropdownFromKeyboard(); - } - return; - } - if (!this.#isDropdownVisible) { - this.#openDropdown(event); - } - event.target.previousSibling?.focus(); - } - _moveToBeginning(event) { - if (!this.#isDropdownVisible) { - this.#openDropdown(event); - return; - } - this.#dropdown.firstChild?.focus(); - } - _moveToEnd(event) { - if (!this.#isDropdownVisible) { - this.#openDropdown(event); - return; - } - this.#dropdown.lastChild?.focus(); - } - #keyDown(event) { - ColorPicker._keyboardManager.exec(this, event); - } - #openDropdown(event) { - if (this.#isDropdownVisible) { - this.hideDropdown(); - return; - } - this.#dropdownWasFromKeyboard = event.detail === 0; - window.addEventListener("pointerdown", this.#boundPointerDown); - if (this.#dropdown) { - this.#dropdown.classList.remove("hidden"); - return; - } - const root = this.#dropdown = this.#getDropdownRoot(); - this.#button.append(root); - } - #pointerDown(event) { - if (this.#dropdown?.contains(event.target)) { - return; - } - this.hideDropdown(); - } - hideDropdown() { - this.#dropdown?.classList.add("hidden"); - window.removeEventListener("pointerdown", this.#boundPointerDown); - } - get #isDropdownVisible() { - return this.#dropdown && !this.#dropdown.classList.contains("hidden"); - } - _hideDropdownFromKeyboard() { - if (this.#isMainColorPicker) { - return; - } - if (!this.#isDropdownVisible) { - this.#editor?.unselect(); - return; - } - this.hideDropdown(); - this.#button.focus({ - preventScroll: true, - focusVisible: this.#dropdownWasFromKeyboard - }); - } - updateColor(color) { - if (this.#buttonSwatch) { - this.#buttonSwatch.style.backgroundColor = color; - } - if (!this.#dropdown) { - return; - } - const i = this.#uiManager.highlightColors.values(); - for (const child of this.#dropdown.children) { - child.setAttribute("aria-selected", i.next().value === color); - } - } - destroy() { - this.#button?.remove(); - this.#button = null; - this.#buttonSwatch = null; - this.#dropdown?.remove(); - this.#dropdown = null; - } -} - -;// CONCATENATED MODULE: ./src/display/editor/highlight.js - - - - - - - - - - - - - -class HighlightEditor extends AnnotationEditor { - #anchorNode = null; - #anchorOffset = 0; - #boxes; - #clipPathId = null; - #colorPicker = null; - #focusOutlines = null; - #focusNode = null; - #focusOffset = 0; - #highlightDiv = null; - #highlightOutlines = null; - #id = null; - #isFreeHighlight = false; - #boundKeydown = this.#keydown.bind(this); - #lastPoint = null; - #opacity; - #outlineId = null; - #text = ""; - #thickness; - #methodOfCreation = ""; - static _defaultColor = null; - static _defaultOpacity = 1; - static _defaultThickness = 12; - static _l10nPromise; - static _type = "highlight"; - static _editorType = AnnotationEditorType.HIGHLIGHT; - static _freeHighlightId = -1; - static _freeHighlight = null; - static _freeHighlightClipId = ""; - static get _keyboardManager() { - const proto = HighlightEditor.prototype; - return shadow(this, "_keyboardManager", new KeyboardManager([[["ArrowLeft", "mac+ArrowLeft"], proto._moveCaret, { - args: [0] - }], [["ArrowRight", "mac+ArrowRight"], proto._moveCaret, { - args: [1] - }], [["ArrowUp", "mac+ArrowUp"], proto._moveCaret, { - args: [2] - }], [["ArrowDown", "mac+ArrowDown"], proto._moveCaret, { - args: [3] - }]])); - } - constructor(params) { - super({ - ...params, - name: "highlightEditor" - }); - this.color = params.color || HighlightEditor._defaultColor; - this.#thickness = params.thickness || HighlightEditor._defaultThickness; - this.#opacity = params.opacity || HighlightEditor._defaultOpacity; - this.#boxes = params.boxes || null; - this.#methodOfCreation = params.methodOfCreation || ""; - this.#text = params.text || ""; - this._isDraggable = false; - if (params.highlightId > -1) { - this.#isFreeHighlight = true; - this.#createFreeOutlines(params); - this.#addToDrawLayer(); - } else { - this.#anchorNode = params.anchorNode; - this.#anchorOffset = params.anchorOffset; - this.#focusNode = params.focusNode; - this.#focusOffset = params.focusOffset; - this.#createOutlines(); - this.#addToDrawLayer(); - this.rotate(this.rotation); - } - } - get telemetryInitialData() { - return { - action: "added", - type: this.#isFreeHighlight ? "free_highlight" : "highlight", - color: this._uiManager.highlightColorNames.get(this.color), - thickness: this.#thickness, - methodOfCreation: this.#methodOfCreation - }; - } - get telemetryFinalData() { - return { - type: "highlight", - color: this._uiManager.highlightColorNames.get(this.color) - }; - } - static computeTelemetryFinalData(data) { - return { - numberOfColors: data.get("color").size - }; - } - #createOutlines() { - const outliner = new Outliner(this.#boxes, 0.001); - this.#highlightOutlines = outliner.getOutlines(); - ({ - x: this.x, - y: this.y, - width: this.width, - height: this.height - } = this.#highlightOutlines.box); - const outlinerForOutline = new Outliner(this.#boxes, 0.0025, 0.001, this._uiManager.direction === "ltr"); - this.#focusOutlines = outlinerForOutline.getOutlines(); - const { - lastPoint - } = this.#focusOutlines.box; - this.#lastPoint = [(lastPoint[0] - this.x) / this.width, (lastPoint[1] - this.y) / this.height]; - } - #createFreeOutlines({ - highlightOutlines, - highlightId, - clipPathId - }) { - this.#highlightOutlines = highlightOutlines; - const extraThickness = 1.5; - this.#focusOutlines = highlightOutlines.getNewOutline(this.#thickness / 2 + extraThickness, 0.0025); - if (highlightId >= 0) { - this.#id = highlightId; - this.#clipPathId = clipPathId; - this.parent.drawLayer.finalizeLine(highlightId, highlightOutlines); - this.#outlineId = this.parent.drawLayer.highlightOutline(this.#focusOutlines); - } else if (this.parent) { - const angle = this.parent.viewport.rotation; - this.parent.drawLayer.updateLine(this.#id, highlightOutlines); - this.parent.drawLayer.updateBox(this.#id, HighlightEditor.#rotateBbox(this.#highlightOutlines.box, (angle - this.rotation + 360) % 360)); - this.parent.drawLayer.updateLine(this.#outlineId, this.#focusOutlines); - this.parent.drawLayer.updateBox(this.#outlineId, HighlightEditor.#rotateBbox(this.#focusOutlines.box, angle)); - } - const { - x, - y, - width, - height - } = highlightOutlines.box; - switch (this.rotation) { - case 0: - this.x = x; - this.y = y; - this.width = width; - this.height = height; - break; - case 90: - { - const [pageWidth, pageHeight] = this.parentDimensions; - this.x = y; - this.y = 1 - x; - this.width = width * pageHeight / pageWidth; - this.height = height * pageWidth / pageHeight; - break; - } - case 180: - this.x = 1 - x; - this.y = 1 - y; - this.width = width; - this.height = height; - break; - case 270: - { - const [pageWidth, pageHeight] = this.parentDimensions; - this.x = 1 - y; - this.y = x; - this.width = width * pageHeight / pageWidth; - this.height = height * pageWidth / pageHeight; - break; - } - } - const { - lastPoint - } = this.#focusOutlines.box; - this.#lastPoint = [(lastPoint[0] - x) / width, (lastPoint[1] - y) / height]; - } - static initialize(l10n, uiManager) { - AnnotationEditor.initialize(l10n, uiManager); - HighlightEditor._defaultColor ||= uiManager.highlightColors?.values().next().value || "#fff066"; - } - static updateDefaultParams(type, value) { - switch (type) { - case AnnotationEditorParamsType.HIGHLIGHT_DEFAULT_COLOR: - HighlightEditor._defaultColor = value; - break; - case AnnotationEditorParamsType.HIGHLIGHT_THICKNESS: - HighlightEditor._defaultThickness = value; - break; - } - } - translateInPage(x, y) {} - get toolbarPosition() { - return this.#lastPoint; - } - updateParams(type, value) { - switch (type) { - case AnnotationEditorParamsType.HIGHLIGHT_COLOR: - this.#updateColor(value); - break; - case AnnotationEditorParamsType.HIGHLIGHT_THICKNESS: - this.#updateThickness(value); - break; - } - } - static get defaultPropertiesToUpdate() { - return [[AnnotationEditorParamsType.HIGHLIGHT_DEFAULT_COLOR, HighlightEditor._defaultColor], [AnnotationEditorParamsType.HIGHLIGHT_THICKNESS, HighlightEditor._defaultThickness]]; - } - get propertiesToUpdate() { - return [[AnnotationEditorParamsType.HIGHLIGHT_COLOR, this.color || HighlightEditor._defaultColor], [AnnotationEditorParamsType.HIGHLIGHT_THICKNESS, this.#thickness || HighlightEditor._defaultThickness], [AnnotationEditorParamsType.HIGHLIGHT_FREE, this.#isFreeHighlight]]; - } - #updateColor(color) { - const setColor = col => { - this.color = col; - this.parent?.drawLayer.changeColor(this.#id, col); - this.#colorPicker?.updateColor(col); - }; - const savedColor = this.color; - this.addCommands({ - cmd: setColor.bind(this, color), - undo: setColor.bind(this, savedColor), - post: this._uiManager.updateUI.bind(this._uiManager, this), - mustExec: true, - type: AnnotationEditorParamsType.HIGHLIGHT_COLOR, - overwriteIfSameType: true, - keepUndo: true - }); - this._reportTelemetry({ - action: "color_changed", - color: this._uiManager.highlightColorNames.get(color) - }, true); - } - #updateThickness(thickness) { - const savedThickness = this.#thickness; - const setThickness = th => { - this.#thickness = th; - this.#changeThickness(th); - }; - this.addCommands({ - cmd: setThickness.bind(this, thickness), - undo: setThickness.bind(this, savedThickness), - post: this._uiManager.updateUI.bind(this._uiManager, this), - mustExec: true, - type: AnnotationEditorParamsType.INK_THICKNESS, - overwriteIfSameType: true, - keepUndo: true - }); - this._reportTelemetry({ - action: "thickness_changed", - thickness - }, true); - } - async addEditToolbar() { - const toolbar = await super.addEditToolbar(); - if (!toolbar) { - return null; - } - if (this._uiManager.highlightColors) { - this.#colorPicker = new ColorPicker({ - editor: this - }); - toolbar.addColorPicker(this.#colorPicker); - } - return toolbar; - } - disableEditing() { - super.disableEditing(); - this.div.classList.toggle("disabled", true); - } - enableEditing() { - super.enableEditing(); - this.div.classList.toggle("disabled", false); - } - fixAndSetPosition() { - return super.fixAndSetPosition(this.#getRotation()); - } - getBaseTranslation() { - return [0, 0]; - } - getRect(tx, ty) { - return super.getRect(tx, ty, this.#getRotation()); - } - onceAdded() { - this.parent.addUndoableEditor(this); - this.div.focus(); - } - remove() { - this.#cleanDrawLayer(); - this._reportTelemetry({ - action: "deleted" - }); - super.remove(); - } - rebuild() { - if (!this.parent) { - return; - } - super.rebuild(); - if (this.div === null) { - return; - } - this.#addToDrawLayer(); - if (!this.isAttachedToDOM) { - this.parent.add(this); - } - } - setParent(parent) { - let mustBeSelected = false; - if (this.parent && !parent) { - this.#cleanDrawLayer(); - } else if (parent) { - this.#addToDrawLayer(parent); - mustBeSelected = !this.parent && this.div?.classList.contains("selectedEditor"); - } - super.setParent(parent); - this.show(this._isVisible); - if (mustBeSelected) { - this.select(); - } - } - #changeThickness(thickness) { - if (!this.#isFreeHighlight) { - return; - } - this.#createFreeOutlines({ - highlightOutlines: this.#highlightOutlines.getNewOutline(thickness / 2) - }); - this.fixAndSetPosition(); - const [parentWidth, parentHeight] = this.parentDimensions; - this.setDims(this.width * parentWidth, this.height * parentHeight); - } - #cleanDrawLayer() { - if (this.#id === null || !this.parent) { - return; - } - this.parent.drawLayer.remove(this.#id); - this.#id = null; - this.parent.drawLayer.remove(this.#outlineId); - this.#outlineId = null; - } - #addToDrawLayer(parent = this.parent) { - if (this.#id !== null) { - return; - } - ({ - id: this.#id, - clipPathId: this.#clipPathId - } = parent.drawLayer.highlight(this.#highlightOutlines, this.color, this.#opacity)); - this.#outlineId = parent.drawLayer.highlightOutline(this.#focusOutlines); - if (this.#highlightDiv) { - this.#highlightDiv.style.clipPath = this.#clipPathId; - } - } - static #rotateBbox({ - x, - y, - width, - height - }, angle) { - switch (angle) { - case 90: - return { - x: 1 - y - height, - y: x, - width: height, - height: width - }; - case 180: - return { - x: 1 - x - width, - y: 1 - y - height, - width, - height - }; - case 270: - return { - x: y, - y: 1 - x - width, - width: height, - height: width - }; - } - return { - x, - y, - width, - height - }; - } - rotate(angle) { - const { - drawLayer - } = this.parent; - let box; - if (this.#isFreeHighlight) { - angle = (angle - this.rotation + 360) % 360; - box = HighlightEditor.#rotateBbox(this.#highlightOutlines.box, angle); - } else { - box = HighlightEditor.#rotateBbox(this, angle); - } - drawLayer.rotate(this.#id, angle); - drawLayer.rotate(this.#outlineId, angle); - drawLayer.updateBox(this.#id, box); - drawLayer.updateBox(this.#outlineId, HighlightEditor.#rotateBbox(this.#focusOutlines.box, angle)); - } - render() { - if (this.div) { - return this.div; - } - const div = super.render(); - if (this.#text) { - div.setAttribute("aria-label", this.#text); - div.setAttribute("role", "mark"); - } - if (this.#isFreeHighlight) { - div.classList.add("free"); - } else { - this.div.addEventListener("keydown", this.#boundKeydown); - } - const highlightDiv = this.#highlightDiv = document.createElement("div"); - div.append(highlightDiv); - highlightDiv.setAttribute("aria-hidden", "true"); - highlightDiv.className = "internal"; - highlightDiv.style.clipPath = this.#clipPathId; - const [parentWidth, parentHeight] = this.parentDimensions; - this.setDims(this.width * parentWidth, this.height * parentHeight); - bindEvents(this, this.#highlightDiv, ["pointerover", "pointerleave"]); - this.enableEditing(); - return div; - } - pointerover() { - this.parent.drawLayer.addClass(this.#outlineId, "hovered"); - } - pointerleave() { - this.parent.drawLayer.removeClass(this.#outlineId, "hovered"); - } - #keydown(event) { - HighlightEditor._keyboardManager.exec(this, event); - } - _moveCaret(direction) { - this.parent.unselect(this); - switch (direction) { - case 0: - case 2: - this.#setCaret(true); - break; - case 1: - case 3: - this.#setCaret(false); - break; - } - } - #setCaret(start) { - if (!this.#anchorNode) { - return; - } - const selection = window.getSelection(); - if (start) { - selection.setPosition(this.#anchorNode, this.#anchorOffset); - } else { - selection.setPosition(this.#focusNode, this.#focusOffset); - } - } - select() { - super.select(); - if (!this.#outlineId) { - return; - } - this.parent?.drawLayer.removeClass(this.#outlineId, "hovered"); - this.parent?.drawLayer.addClass(this.#outlineId, "selected"); - } - unselect() { - super.unselect(); - if (!this.#outlineId) { - return; - } - this.parent?.drawLayer.removeClass(this.#outlineId, "selected"); - if (!this.#isFreeHighlight) { - this.#setCaret(false); - } - } - get _mustFixPosition() { - return !this.#isFreeHighlight; - } - show(visible = this._isVisible) { - super.show(visible); - if (this.parent) { - this.parent.drawLayer.show(this.#id, visible); - this.parent.drawLayer.show(this.#outlineId, visible); - } - } - #getRotation() { - return this.#isFreeHighlight ? this.rotation : 0; - } - #serializeBoxes() { - if (this.#isFreeHighlight) { - return null; - } - const [pageWidth, pageHeight] = this.pageDimensions; - const boxes = this.#boxes; - const quadPoints = new Float32Array(boxes.length * 8); - let i = 0; - for (const { - x, - y, - width, - height - } of boxes) { - const sx = x * pageWidth; - const sy = (1 - y - height) * pageHeight; - quadPoints[i] = quadPoints[i + 4] = sx; - quadPoints[i + 1] = quadPoints[i + 3] = sy; - quadPoints[i + 2] = quadPoints[i + 6] = sx + width * pageWidth; - quadPoints[i + 5] = quadPoints[i + 7] = sy + height * pageHeight; - i += 8; - } - return quadPoints; - } - #serializeOutlines(rect) { - return this.#highlightOutlines.serialize(rect, this.#getRotation()); - } - static startHighlighting(parent, isLTR, { - target: textLayer, - x, - y - }) { - const { - x: layerX, - y: layerY, - width: parentWidth, - height: parentHeight - } = textLayer.getBoundingClientRect(); - const pointerMove = e => { - this.#highlightMove(parent, e); - }; - const pointerDownOptions = { - capture: true, - passive: false - }; - const pointerDown = e => { - e.preventDefault(); - e.stopPropagation(); - }; - const pointerUpCallback = e => { - textLayer.removeEventListener("pointermove", pointerMove); - window.removeEventListener("blur", pointerUpCallback); - window.removeEventListener("pointerup", pointerUpCallback); - window.removeEventListener("pointerdown", pointerDown, pointerDownOptions); - window.removeEventListener("contextmenu", noContextMenu); - this.#endHighlight(parent, e); - }; - window.addEventListener("blur", pointerUpCallback); - window.addEventListener("pointerup", pointerUpCallback); - window.addEventListener("pointerdown", pointerDown, pointerDownOptions); - window.addEventListener("contextmenu", noContextMenu); - textLayer.addEventListener("pointermove", pointerMove); - this._freeHighlight = new FreeOutliner({ - x, - y - }, [layerX, layerY, parentWidth, parentHeight], parent.scale, this._defaultThickness / 2, isLTR, 0.001); - ({ - id: this._freeHighlightId, - clipPathId: this._freeHighlightClipId - } = parent.drawLayer.highlight(this._freeHighlight, this._defaultColor, this._defaultOpacity, true)); - } - static #highlightMove(parent, event) { - if (this._freeHighlight.add(event)) { - parent.drawLayer.updatePath(this._freeHighlightId, this._freeHighlight); - } - } - static #endHighlight(parent, event) { - if (!this._freeHighlight.isEmpty()) { - parent.createAndAddNewEditor(event, false, { - highlightId: this._freeHighlightId, - highlightOutlines: this._freeHighlight.getOutlines(), - clipPathId: this._freeHighlightClipId, - methodOfCreation: "main_toolbar" - }); - } else { - parent.drawLayer.removeFreeHighlight(this._freeHighlightId); - } - this._freeHighlightId = -1; - this._freeHighlight = null; - this._freeHighlightClipId = ""; - } - static deserialize(data, parent, uiManager) { - const editor = super.deserialize(data, parent, uiManager); - const { - rect: [blX, blY, trX, trY], - color, - quadPoints - } = data; - editor.color = Util.makeHexColor(...color); - editor.#opacity = data.opacity; - const [pageWidth, pageHeight] = editor.pageDimensions; - editor.width = (trX - blX) / pageWidth; - editor.height = (trY - blY) / pageHeight; - const boxes = editor.#boxes = []; - for (let i = 0; i < quadPoints.length; i += 8) { - boxes.push({ - x: (quadPoints[4] - trX) / pageWidth, - y: (trY - (1 - quadPoints[i + 5])) / pageHeight, - width: (quadPoints[i + 2] - quadPoints[i]) / pageWidth, - height: (quadPoints[i + 5] - quadPoints[i + 1]) / pageHeight - }); - } - editor.#createOutlines(); - return editor; - } - serialize(isForCopying = false) { - if (this.isEmpty() || isForCopying) { - return null; - } - const rect = this.getRect(0, 0); - const color = AnnotationEditor._colorManager.convert(this.color); - return { - annotationType: AnnotationEditorType.HIGHLIGHT, - color, - opacity: this.#opacity, - thickness: this.#thickness, - quadPoints: this.#serializeBoxes(), - outlines: this.#serializeOutlines(rect), - pageIndex: this.pageIndex, - rect, - rotation: this.#getRotation(), - structTreeParentId: this._structTreeParentId - }; - } - static canCreateNewEmptyEditor() { - return false; - } -} - -;// CONCATENATED MODULE: ./src/display/editor/ink.js - - - - - - - -class InkEditor extends AnnotationEditor { - #baseHeight = 0; - #baseWidth = 0; - #boundCanvasPointermove = this.canvasPointermove.bind(this); - #boundCanvasPointerleave = this.canvasPointerleave.bind(this); - #boundCanvasPointerup = this.canvasPointerup.bind(this); - #boundCanvasPointerdown = this.canvasPointerdown.bind(this); - #canvasContextMenuTimeoutId = null; - #currentPath2D = new Path2D(); - #disableEditing = false; - #hasSomethingToDraw = false; - #isCanvasInitialized = false; - #observer = null; - #realWidth = 0; - #realHeight = 0; - #requestFrameCallback = null; - static _defaultColor = null; - static _defaultOpacity = 1; - static _defaultThickness = 1; - static _type = "ink"; - static _editorType = AnnotationEditorType.INK; - constructor(params) { - super({ - ...params, - name: "inkEditor" - }); - this.color = params.color || null; - this.thickness = params.thickness || null; - this.opacity = params.opacity || null; - this.paths = []; - this.bezierPath2D = []; - this.allRawPaths = []; - this.currentPath = []; - this.scaleFactor = 1; - this.translationX = this.translationY = 0; - this.x = 0; - this.y = 0; - this._willKeepAspectRatio = true; - } - static initialize(l10n, uiManager) { - AnnotationEditor.initialize(l10n, uiManager); - } - static updateDefaultParams(type, value) { - switch (type) { - case AnnotationEditorParamsType.INK_THICKNESS: - InkEditor._defaultThickness = value; - break; - case AnnotationEditorParamsType.INK_COLOR: - InkEditor._defaultColor = value; - break; - case AnnotationEditorParamsType.INK_OPACITY: - InkEditor._defaultOpacity = value / 100; - break; - } - } - updateParams(type, value) { - switch (type) { - case AnnotationEditorParamsType.INK_THICKNESS: - this.#updateThickness(value); - break; - case AnnotationEditorParamsType.INK_COLOR: - this.#updateColor(value); - break; - case AnnotationEditorParamsType.INK_OPACITY: - this.#updateOpacity(value); - break; - } - } - static get defaultPropertiesToUpdate() { - return [[AnnotationEditorParamsType.INK_THICKNESS, InkEditor._defaultThickness], [AnnotationEditorParamsType.INK_COLOR, InkEditor._defaultColor || AnnotationEditor._defaultLineColor], [AnnotationEditorParamsType.INK_OPACITY, Math.round(InkEditor._defaultOpacity * 100)]]; - } - get propertiesToUpdate() { - return [[AnnotationEditorParamsType.INK_THICKNESS, this.thickness || InkEditor._defaultThickness], [AnnotationEditorParamsType.INK_COLOR, this.color || InkEditor._defaultColor || AnnotationEditor._defaultLineColor], [AnnotationEditorParamsType.INK_OPACITY, Math.round(100 * (this.opacity ?? InkEditor._defaultOpacity))]]; - } - #updateThickness(thickness) { - const setThickness = th => { - this.thickness = th; - this.#fitToContent(); - }; - const savedThickness = this.thickness; - this.addCommands({ - cmd: setThickness.bind(this, thickness), - undo: setThickness.bind(this, savedThickness), - post: this._uiManager.updateUI.bind(this._uiManager, this), - mustExec: true, - type: AnnotationEditorParamsType.INK_THICKNESS, - overwriteIfSameType: true, - keepUndo: true - }); - } - #updateColor(color) { - const setColor = col => { - this.color = col; - this.#redraw(); - }; - const savedColor = this.color; - this.addCommands({ - cmd: setColor.bind(this, color), - undo: setColor.bind(this, savedColor), - post: this._uiManager.updateUI.bind(this._uiManager, this), - mustExec: true, - type: AnnotationEditorParamsType.INK_COLOR, - overwriteIfSameType: true, - keepUndo: true - }); - } - #updateOpacity(opacity) { - const setOpacity = op => { - this.opacity = op; - this.#redraw(); - }; - opacity /= 100; - const savedOpacity = this.opacity; - this.addCommands({ - cmd: setOpacity.bind(this, opacity), - undo: setOpacity.bind(this, savedOpacity), - post: this._uiManager.updateUI.bind(this._uiManager, this), - mustExec: true, - type: AnnotationEditorParamsType.INK_OPACITY, - overwriteIfSameType: true, - keepUndo: true - }); - } - rebuild() { - if (!this.parent) { - return; - } - super.rebuild(); - if (this.div === null) { - return; - } - if (!this.canvas) { - this.#createCanvas(); - this.#createObserver(); - } - if (!this.isAttachedToDOM) { - this.parent.add(this); - this.#setCanvasDims(); - } - this.#fitToContent(); - } - remove() { - if (this.canvas === null) { - return; - } - if (!this.isEmpty()) { - this.commit(); - } - this.canvas.width = this.canvas.height = 0; - this.canvas.remove(); - this.canvas = null; - if (this.#canvasContextMenuTimeoutId) { - clearTimeout(this.#canvasContextMenuTimeoutId); - this.#canvasContextMenuTimeoutId = null; - } - this.#observer.disconnect(); - this.#observer = null; - super.remove(); - } - setParent(parent) { - if (!this.parent && parent) { - this._uiManager.removeShouldRescale(this); - } else if (this.parent && parent === null) { - this._uiManager.addShouldRescale(this); - } - super.setParent(parent); - } - onScaleChanging() { - const [parentWidth, parentHeight] = this.parentDimensions; - const width = this.width * parentWidth; - const height = this.height * parentHeight; - this.setDimensions(width, height); - } - enableEditMode() { - if (this.#disableEditing || this.canvas === null) { - return; - } - super.enableEditMode(); - this._isDraggable = false; - this.canvas.addEventListener("pointerdown", this.#boundCanvasPointerdown); - } - disableEditMode() { - if (!this.isInEditMode() || this.canvas === null) { - return; - } - super.disableEditMode(); - this._isDraggable = !this.isEmpty(); - this.div.classList.remove("editing"); - this.canvas.removeEventListener("pointerdown", this.#boundCanvasPointerdown); - } - onceAdded() { - this._isDraggable = !this.isEmpty(); - } - isEmpty() { - return this.paths.length === 0 || this.paths.length === 1 && this.paths[0].length === 0; - } - #getInitialBBox() { - const { - parentRotation, - parentDimensions: [width, height] - } = this; - switch (parentRotation) { - case 90: - return [0, height, height, width]; - case 180: - return [width, height, width, height]; - case 270: - return [width, 0, height, width]; - default: - return [0, 0, width, height]; - } - } - #setStroke() { - const { - ctx, - color, - opacity, - thickness, - parentScale, - scaleFactor - } = this; - ctx.lineWidth = thickness * parentScale / scaleFactor; - ctx.lineCap = "round"; - ctx.lineJoin = "round"; - ctx.miterLimit = 10; - ctx.strokeStyle = `${color}${opacityToHex(opacity)}`; - } - #startDrawing(x, y) { - this.canvas.addEventListener("contextmenu", noContextMenu); - this.canvas.addEventListener("pointerleave", this.#boundCanvasPointerleave); - this.canvas.addEventListener("pointermove", this.#boundCanvasPointermove); - this.canvas.addEventListener("pointerup", this.#boundCanvasPointerup); - this.canvas.removeEventListener("pointerdown", this.#boundCanvasPointerdown); - this.isEditing = true; - if (!this.#isCanvasInitialized) { - this.#isCanvasInitialized = true; - this.#setCanvasDims(); - this.thickness ||= InkEditor._defaultThickness; - this.color ||= InkEditor._defaultColor || AnnotationEditor._defaultLineColor; - this.opacity ??= InkEditor._defaultOpacity; - } - this.currentPath.push([x, y]); - this.#hasSomethingToDraw = false; - this.#setStroke(); - this.#requestFrameCallback = () => { - this.#drawPoints(); - if (this.#requestFrameCallback) { - window.requestAnimationFrame(this.#requestFrameCallback); - } - }; - window.requestAnimationFrame(this.#requestFrameCallback); - } - #draw(x, y) { - const [lastX, lastY] = this.currentPath.at(-1); - if (this.currentPath.length > 1 && x === lastX && y === lastY) { - return; - } - const currentPath = this.currentPath; - let path2D = this.#currentPath2D; - currentPath.push([x, y]); - this.#hasSomethingToDraw = true; - if (currentPath.length <= 2) { - path2D.moveTo(...currentPath[0]); - path2D.lineTo(x, y); - return; - } - if (currentPath.length === 3) { - this.#currentPath2D = path2D = new Path2D(); - path2D.moveTo(...currentPath[0]); - } - this.#makeBezierCurve(path2D, ...currentPath.at(-3), ...currentPath.at(-2), x, y); - } - #endPath() { - if (this.currentPath.length === 0) { - return; - } - const lastPoint = this.currentPath.at(-1); - this.#currentPath2D.lineTo(...lastPoint); - } - #stopDrawing(x, y) { - this.#requestFrameCallback = null; - x = Math.min(Math.max(x, 0), this.canvas.width); - y = Math.min(Math.max(y, 0), this.canvas.height); - this.#draw(x, y); - this.#endPath(); - let bezier; - if (this.currentPath.length !== 1) { - bezier = this.#generateBezierPoints(); - } else { - const xy = [x, y]; - bezier = [[xy, xy.slice(), xy.slice(), xy]]; - } - const path2D = this.#currentPath2D; - const currentPath = this.currentPath; - this.currentPath = []; - this.#currentPath2D = new Path2D(); - const cmd = () => { - this.allRawPaths.push(currentPath); - this.paths.push(bezier); - this.bezierPath2D.push(path2D); - this._uiManager.rebuild(this); - }; - const undo = () => { - this.allRawPaths.pop(); - this.paths.pop(); - this.bezierPath2D.pop(); - if (this.paths.length === 0) { - this.remove(); - } else { - if (!this.canvas) { - this.#createCanvas(); - this.#createObserver(); - } - this.#fitToContent(); - } - }; - this.addCommands({ - cmd, - undo, - mustExec: true - }); - } - #drawPoints() { - if (!this.#hasSomethingToDraw) { - return; - } - this.#hasSomethingToDraw = false; - const thickness = Math.ceil(this.thickness * this.parentScale); - const lastPoints = this.currentPath.slice(-3); - const x = lastPoints.map(xy => xy[0]); - const y = lastPoints.map(xy => xy[1]); - const xMin = Math.min(...x) - thickness; - const xMax = Math.max(...x) + thickness; - const yMin = Math.min(...y) - thickness; - const yMax = Math.max(...y) + thickness; - const { - ctx - } = this; - ctx.save(); - ctx.clearRect(0, 0, this.canvas.width, this.canvas.height); - for (const path of this.bezierPath2D) { - ctx.stroke(path); - } - ctx.stroke(this.#currentPath2D); - ctx.restore(); - } - #makeBezierCurve(path2D, x0, y0, x1, y1, x2, y2) { - const prevX = (x0 + x1) / 2; - const prevY = (y0 + y1) / 2; - const x3 = (x1 + x2) / 2; - const y3 = (y1 + y2) / 2; - path2D.bezierCurveTo(prevX + 2 * (x1 - prevX) / 3, prevY + 2 * (y1 - prevY) / 3, x3 + 2 * (x1 - x3) / 3, y3 + 2 * (y1 - y3) / 3, x3, y3); - } - #generateBezierPoints() { - const path = this.currentPath; - if (path.length <= 2) { - return [[path[0], path[0], path.at(-1), path.at(-1)]]; - } - const bezierPoints = []; - let i; - let [x0, y0] = path[0]; - for (i = 1; i < path.length - 2; i++) { - const [x1, y1] = path[i]; - const [x2, y2] = path[i + 1]; - const x3 = (x1 + x2) / 2; - const y3 = (y1 + y2) / 2; - const control1 = [x0 + 2 * (x1 - x0) / 3, y0 + 2 * (y1 - y0) / 3]; - const control2 = [x3 + 2 * (x1 - x3) / 3, y3 + 2 * (y1 - y3) / 3]; - bezierPoints.push([[x0, y0], control1, control2, [x3, y3]]); - [x0, y0] = [x3, y3]; - } - const [x1, y1] = path[i]; - const [x2, y2] = path[i + 1]; - const control1 = [x0 + 2 * (x1 - x0) / 3, y0 + 2 * (y1 - y0) / 3]; - const control2 = [x2 + 2 * (x1 - x2) / 3, y2 + 2 * (y1 - y2) / 3]; - bezierPoints.push([[x0, y0], control1, control2, [x2, y2]]); - return bezierPoints; - } - #redraw() { - if (this.isEmpty()) { - this.#updateTransform(); - return; - } - this.#setStroke(); - const { - canvas, - ctx - } = this; - ctx.setTransform(1, 0, 0, 1, 0, 0); - ctx.clearRect(0, 0, canvas.width, canvas.height); - this.#updateTransform(); - for (const path of this.bezierPath2D) { - ctx.stroke(path); - } - } - commit() { - if (this.#disableEditing) { - return; - } - super.commit(); - this.isEditing = false; - this.disableEditMode(); - this.setInForeground(); - this.#disableEditing = true; - this.div.classList.add("disabled"); - this.#fitToContent(true); - this.select(); - this.parent.addInkEditorIfNeeded(true); - this.moveInDOM(); - this.div.focus({ - preventScroll: true - }); - } - focusin(event) { - if (!this._focusEventsAllowed) { - return; - } - super.focusin(event); - this.enableEditMode(); - } - canvasPointerdown(event) { - if (event.button !== 0 || !this.isInEditMode() || this.#disableEditing) { - return; - } - this.setInForeground(); - event.preventDefault(); - if (!this.div.contains(document.activeElement)) { - this.div.focus({ - preventScroll: true - }); - } - this.#startDrawing(event.offsetX, event.offsetY); - } - canvasPointermove(event) { - event.preventDefault(); - this.#draw(event.offsetX, event.offsetY); - } - canvasPointerup(event) { - event.preventDefault(); - this.#endDrawing(event); - } - canvasPointerleave(event) { - this.#endDrawing(event); - } - #endDrawing(event) { - this.canvas.removeEventListener("pointerleave", this.#boundCanvasPointerleave); - this.canvas.removeEventListener("pointermove", this.#boundCanvasPointermove); - this.canvas.removeEventListener("pointerup", this.#boundCanvasPointerup); - this.canvas.addEventListener("pointerdown", this.#boundCanvasPointerdown); - if (this.#canvasContextMenuTimeoutId) { - clearTimeout(this.#canvasContextMenuTimeoutId); - } - this.#canvasContextMenuTimeoutId = setTimeout(() => { - this.#canvasContextMenuTimeoutId = null; - this.canvas.removeEventListener("contextmenu", noContextMenu); - }, 10); - this.#stopDrawing(event.offsetX, event.offsetY); - this.addToAnnotationStorage(); - this.setInBackground(); - } - #createCanvas() { - this.canvas = document.createElement("canvas"); - this.canvas.width = this.canvas.height = 0; - this.canvas.className = "inkEditorCanvas"; - this.canvas.setAttribute("data-l10n-id", "pdfjs-ink-canvas"); - this.div.append(this.canvas); - this.ctx = this.canvas.getContext("2d"); - } - #createObserver() { - this.#observer = new ResizeObserver(entries => { - const rect = entries[0].contentRect; - if (rect.width && rect.height) { - this.setDimensions(rect.width, rect.height); - } - }); - this.#observer.observe(this.div); - } - get isResizable() { - return !this.isEmpty() && this.#disableEditing; - } - render() { - if (this.div) { - return this.div; - } - let baseX, baseY; - if (this.width) { - baseX = this.x; - baseY = this.y; - } - super.render(); - this.div.setAttribute("data-l10n-id", "pdfjs-ink"); - const [x, y, w, h] = this.#getInitialBBox(); - this.setAt(x, y, 0, 0); - this.setDims(w, h); - this.#createCanvas(); - if (this.width) { - const [parentWidth, parentHeight] = this.parentDimensions; - this.setAspectRatio(this.width * parentWidth, this.height * parentHeight); - this.setAt(baseX * parentWidth, baseY * parentHeight, this.width * parentWidth, this.height * parentHeight); - this.#isCanvasInitialized = true; - this.#setCanvasDims(); - this.setDims(this.width * parentWidth, this.height * parentHeight); - this.#redraw(); - this.div.classList.add("disabled"); - } else { - this.div.classList.add("editing"); - this.enableEditMode(); - } - this.#createObserver(); - return this.div; - } - #setCanvasDims() { - if (!this.#isCanvasInitialized) { - return; - } - const [parentWidth, parentHeight] = this.parentDimensions; - this.canvas.width = Math.ceil(this.width * parentWidth); - this.canvas.height = Math.ceil(this.height * parentHeight); - this.#updateTransform(); - } - setDimensions(width, height) { - const roundedWidth = Math.round(width); - const roundedHeight = Math.round(height); - if (this.#realWidth === roundedWidth && this.#realHeight === roundedHeight) { - return; - } - this.#realWidth = roundedWidth; - this.#realHeight = roundedHeight; - this.canvas.style.visibility = "hidden"; - const [parentWidth, parentHeight] = this.parentDimensions; - this.width = width / parentWidth; - this.height = height / parentHeight; - this.fixAndSetPosition(); - if (this.#disableEditing) { - this.#setScaleFactor(width, height); - } - this.#setCanvasDims(); - this.#redraw(); - this.canvas.style.visibility = "visible"; - this.fixDims(); - } - #setScaleFactor(width, height) { - const padding = this.#getPadding(); - const scaleFactorW = (width - padding) / this.#baseWidth; - const scaleFactorH = (height - padding) / this.#baseHeight; - this.scaleFactor = Math.min(scaleFactorW, scaleFactorH); - } - #updateTransform() { - const padding = this.#getPadding() / 2; - this.ctx.setTransform(this.scaleFactor, 0, 0, this.scaleFactor, this.translationX * this.scaleFactor + padding, this.translationY * this.scaleFactor + padding); - } - static #buildPath2D(bezier) { - const path2D = new Path2D(); - for (let i = 0, ii = bezier.length; i < ii; i++) { - const [first, control1, control2, second] = bezier[i]; - if (i === 0) { - path2D.moveTo(...first); - } - path2D.bezierCurveTo(control1[0], control1[1], control2[0], control2[1], second[0], second[1]); - } - return path2D; - } - static #toPDFCoordinates(points, rect, rotation) { - const [blX, blY, trX, trY] = rect; - switch (rotation) { - case 0: - for (let i = 0, ii = points.length; i < ii; i += 2) { - points[i] += blX; - points[i + 1] = trY - points[i + 1]; - } - break; - case 90: - for (let i = 0, ii = points.length; i < ii; i += 2) { - const x = points[i]; - points[i] = points[i + 1] + blX; - points[i + 1] = x + blY; - } - break; - case 180: - for (let i = 0, ii = points.length; i < ii; i += 2) { - points[i] = trX - points[i]; - points[i + 1] += blY; - } - break; - case 270: - for (let i = 0, ii = points.length; i < ii; i += 2) { - const x = points[i]; - points[i] = trX - points[i + 1]; - points[i + 1] = trY - x; - } - break; - default: - throw new Error("Invalid rotation"); - } - return points; - } - static #fromPDFCoordinates(points, rect, rotation) { - const [blX, blY, trX, trY] = rect; - switch (rotation) { - case 0: - for (let i = 0, ii = points.length; i < ii; i += 2) { - points[i] -= blX; - points[i + 1] = trY - points[i + 1]; - } - break; - case 90: - for (let i = 0, ii = points.length; i < ii; i += 2) { - const x = points[i]; - points[i] = points[i + 1] - blY; - points[i + 1] = x - blX; - } - break; - case 180: - for (let i = 0, ii = points.length; i < ii; i += 2) { - points[i] = trX - points[i]; - points[i + 1] -= blY; - } - break; - case 270: - for (let i = 0, ii = points.length; i < ii; i += 2) { - const x = points[i]; - points[i] = trY - points[i + 1]; - points[i + 1] = trX - x; - } - break; - default: - throw new Error("Invalid rotation"); - } - return points; - } - #serializePaths(s, tx, ty, rect) { - const paths = []; - const padding = this.thickness / 2; - const shiftX = s * tx + padding; - const shiftY = s * ty + padding; - for (const bezier of this.paths) { - const buffer = []; - const points = []; - for (let j = 0, jj = bezier.length; j < jj; j++) { - const [first, control1, control2, second] = bezier[j]; - if (first[0] === second[0] && first[1] === second[1] && jj === 1) { - const p0 = s * first[0] + shiftX; - const p1 = s * first[1] + shiftY; - buffer.push(p0, p1); - points.push(p0, p1); - break; - } - const p10 = s * first[0] + shiftX; - const p11 = s * first[1] + shiftY; - const p20 = s * control1[0] + shiftX; - const p21 = s * control1[1] + shiftY; - const p30 = s * control2[0] + shiftX; - const p31 = s * control2[1] + shiftY; - const p40 = s * second[0] + shiftX; - const p41 = s * second[1] + shiftY; - if (j === 0) { - buffer.push(p10, p11); - points.push(p10, p11); - } - buffer.push(p20, p21, p30, p31, p40, p41); - points.push(p20, p21); - if (j === jj - 1) { - points.push(p40, p41); - } - } - paths.push({ - bezier: InkEditor.#toPDFCoordinates(buffer, rect, this.rotation), - points: InkEditor.#toPDFCoordinates(points, rect, this.rotation) - }); - } - return paths; - } - #getBbox() { - let xMin = Infinity; - let xMax = -Infinity; - let yMin = Infinity; - let yMax = -Infinity; - for (const path of this.paths) { - for (const [first, control1, control2, second] of path) { - const bbox = Util.bezierBoundingBox(...first, ...control1, ...control2, ...second); - xMin = Math.min(xMin, bbox[0]); - yMin = Math.min(yMin, bbox[1]); - xMax = Math.max(xMax, bbox[2]); - yMax = Math.max(yMax, bbox[3]); - } - } - return [xMin, yMin, xMax, yMax]; - } - #getPadding() { - return this.#disableEditing ? Math.ceil(this.thickness * this.parentScale) : 0; - } - #fitToContent(firstTime = false) { - if (this.isEmpty()) { - return; - } - if (!this.#disableEditing) { - this.#redraw(); - return; - } - const bbox = this.#getBbox(); - const padding = this.#getPadding(); - this.#baseWidth = Math.max(AnnotationEditor.MIN_SIZE, bbox[2] - bbox[0]); - this.#baseHeight = Math.max(AnnotationEditor.MIN_SIZE, bbox[3] - bbox[1]); - const width = Math.ceil(padding + this.#baseWidth * this.scaleFactor); - const height = Math.ceil(padding + this.#baseHeight * this.scaleFactor); - const [parentWidth, parentHeight] = this.parentDimensions; - this.width = width / parentWidth; - this.height = height / parentHeight; - this.setAspectRatio(width, height); - const prevTranslationX = this.translationX; - const prevTranslationY = this.translationY; - this.translationX = -bbox[0]; - this.translationY = -bbox[1]; - this.#setCanvasDims(); - this.#redraw(); - this.#realWidth = width; - this.#realHeight = height; - this.setDims(width, height); - const unscaledPadding = firstTime ? padding / this.scaleFactor / 2 : 0; - this.translate(prevTranslationX - this.translationX - unscaledPadding, prevTranslationY - this.translationY - unscaledPadding); - } - static deserialize(data, parent, uiManager) { - if (data instanceof InkAnnotationElement) { - return null; - } - const editor = super.deserialize(data, parent, uiManager); - editor.thickness = data.thickness; - editor.color = Util.makeHexColor(...data.color); - editor.opacity = data.opacity; - const [pageWidth, pageHeight] = editor.pageDimensions; - const width = editor.width * pageWidth; - const height = editor.height * pageHeight; - const scaleFactor = editor.parentScale; - const padding = data.thickness / 2; - editor.#disableEditing = true; - editor.#realWidth = Math.round(width); - editor.#realHeight = Math.round(height); - const { - paths, - rect, - rotation - } = data; - for (let { - bezier - } of paths) { - bezier = InkEditor.#fromPDFCoordinates(bezier, rect, rotation); - const path = []; - editor.paths.push(path); - let p0 = scaleFactor * (bezier[0] - padding); - let p1 = scaleFactor * (bezier[1] - padding); - for (let i = 2, ii = bezier.length; i < ii; i += 6) { - const p10 = scaleFactor * (bezier[i] - padding); - const p11 = scaleFactor * (bezier[i + 1] - padding); - const p20 = scaleFactor * (bezier[i + 2] - padding); - const p21 = scaleFactor * (bezier[i + 3] - padding); - const p30 = scaleFactor * (bezier[i + 4] - padding); - const p31 = scaleFactor * (bezier[i + 5] - padding); - path.push([[p0, p1], [p10, p11], [p20, p21], [p30, p31]]); - p0 = p30; - p1 = p31; - } - const path2D = this.#buildPath2D(path); - editor.bezierPath2D.push(path2D); - } - const bbox = editor.#getBbox(); - editor.#baseWidth = Math.max(AnnotationEditor.MIN_SIZE, bbox[2] - bbox[0]); - editor.#baseHeight = Math.max(AnnotationEditor.MIN_SIZE, bbox[3] - bbox[1]); - editor.#setScaleFactor(width, height); - return editor; - } - serialize() { - if (this.isEmpty()) { - return null; - } - const rect = this.getRect(0, 0); - const color = AnnotationEditor._colorManager.convert(this.ctx.strokeStyle); - return { - annotationType: AnnotationEditorType.INK, - color, - thickness: this.thickness, - opacity: this.opacity, - paths: this.#serializePaths(this.scaleFactor / this.parentScale, this.translationX, this.translationY, rect), - pageIndex: this.pageIndex, - rect, - rotation: this.rotation, - structTreeParentId: this._structTreeParentId - }; - } -} - -;// CONCATENATED MODULE: ./src/display/editor/stamp.js - - - - - - - -class StampEditor extends AnnotationEditor { - #bitmap = null; - #bitmapId = null; - #bitmapPromise = null; - #bitmapUrl = null; - #bitmapFile = null; - #bitmapFileName = ""; - #canvas = null; - #observer = null; - #resizeTimeoutId = null; - #isSvg = false; - #hasBeenAddedInUndoStack = false; - static _type = "stamp"; - static _editorType = AnnotationEditorType.STAMP; - constructor(params) { - super({ - ...params, - name: "stampEditor" - }); - this.#bitmapUrl = params.bitmapUrl; - this.#bitmapFile = params.bitmapFile; - } - static initialize(l10n, uiManager) { - AnnotationEditor.initialize(l10n, uiManager); - } - static get supportedTypes() { - const types = ["apng", "avif", "bmp", "gif", "jpeg", "png", "svg+xml", "webp", "x-icon"]; - return shadow(this, "supportedTypes", types.map(type => `image/${type}`)); - } - static get supportedTypesStr() { - return shadow(this, "supportedTypesStr", this.supportedTypes.join(",")); - } - static isHandlingMimeForPasting(mime) { - return this.supportedTypes.includes(mime); - } - static paste(item, parent) { - parent.pasteEditor(AnnotationEditorType.STAMP, { - bitmapFile: item.getAsFile() - }); - } - #getBitmapFetched(data, fromId = false) { - if (!data) { - this.remove(); - return; - } - this.#bitmap = data.bitmap; - if (!fromId) { - this.#bitmapId = data.id; - this.#isSvg = data.isSvg; - } - if (data.file) { - this.#bitmapFileName = data.file.name; - } - this.#createCanvas(); - } - #getBitmapDone() { - this.#bitmapPromise = null; - this._uiManager.enableWaiting(false); - if (this.#canvas) { - this.div.focus(); - } - } - #getBitmap() { - if (this.#bitmapId) { - this._uiManager.enableWaiting(true); - this._uiManager.imageManager.getFromId(this.#bitmapId).then(data => this.#getBitmapFetched(data, true)).finally(() => this.#getBitmapDone()); - return; - } - if (this.#bitmapUrl) { - const url = this.#bitmapUrl; - this.#bitmapUrl = null; - this._uiManager.enableWaiting(true); - this.#bitmapPromise = this._uiManager.imageManager.getFromUrl(url).then(data => this.#getBitmapFetched(data)).finally(() => this.#getBitmapDone()); - return; - } - if (this.#bitmapFile) { - const file = this.#bitmapFile; - this.#bitmapFile = null; - this._uiManager.enableWaiting(true); - this.#bitmapPromise = this._uiManager.imageManager.getFromFile(file).then(data => this.#getBitmapFetched(data)).finally(() => this.#getBitmapDone()); - return; - } - const input = document.createElement("input"); - input.type = "file"; - input.accept = StampEditor.supportedTypesStr; - this.#bitmapPromise = new Promise(resolve => { - input.addEventListener("change", async () => { - if (!input.files || input.files.length === 0) { - this.remove(); - } else { - this._uiManager.enableWaiting(true); - const data = await this._uiManager.imageManager.getFromFile(input.files[0]); - this.#getBitmapFetched(data); - } - resolve(); - }); - input.addEventListener("cancel", () => { - this.remove(); - resolve(); - }); - }).finally(() => this.#getBitmapDone()); - input.click(); - } - remove() { - if (this.#bitmapId) { - this.#bitmap = null; - this._uiManager.imageManager.deleteId(this.#bitmapId); - this.#canvas?.remove(); - this.#canvas = null; - this.#observer?.disconnect(); - this.#observer = null; - if (this.#resizeTimeoutId) { - clearTimeout(this.#resizeTimeoutId); - this.#resizeTimeoutId = null; - } - } - super.remove(); - } - rebuild() { - if (!this.parent) { - if (this.#bitmapId) { - this.#getBitmap(); - } - return; - } - super.rebuild(); - if (this.div === null) { - return; - } - if (this.#bitmapId && this.#canvas === null) { - this.#getBitmap(); - } - if (!this.isAttachedToDOM) { - this.parent.add(this); - } - } - onceAdded() { - this._isDraggable = true; - this.div.focus(); - } - isEmpty() { - return !(this.#bitmapPromise || this.#bitmap || this.#bitmapUrl || this.#bitmapFile || this.#bitmapId); - } - get isResizable() { - return true; - } - render() { - if (this.div) { - return this.div; - } - let baseX, baseY; - if (this.width) { - baseX = this.x; - baseY = this.y; - } - super.render(); - this.div.hidden = true; - this.addAltTextButton(); - if (this.#bitmap) { - this.#createCanvas(); - } else { - this.#getBitmap(); - } - if (this.width) { - const [parentWidth, parentHeight] = this.parentDimensions; - this.setAt(baseX * parentWidth, baseY * parentHeight, this.width * parentWidth, this.height * parentHeight); - } - return this.div; - } - #createCanvas() { - const { - div - } = this; - let { - width, - height - } = this.#bitmap; - const [pageWidth, pageHeight] = this.pageDimensions; - const MAX_RATIO = 0.75; - if (this.width) { - width = this.width * pageWidth; - height = this.height * pageHeight; - } else if (width > MAX_RATIO * pageWidth || height > MAX_RATIO * pageHeight) { - const factor = Math.min(MAX_RATIO * pageWidth / width, MAX_RATIO * pageHeight / height); - width *= factor; - height *= factor; - } - const [parentWidth, parentHeight] = this.parentDimensions; - this.setDims(width * parentWidth / pageWidth, height * parentHeight / pageHeight); - this._uiManager.enableWaiting(false); - const canvas = this.#canvas = document.createElement("canvas"); - div.append(canvas); - div.hidden = false; - this.#drawBitmap(width, height); - this.#createObserver(); - if (!this.#hasBeenAddedInUndoStack) { - this.parent.addUndoableEditor(this); - this.#hasBeenAddedInUndoStack = true; - } - this._reportTelemetry({ - action: "inserted_image" - }); - if (this.#bitmapFileName) { - canvas.setAttribute("aria-label", this.#bitmapFileName); - } - } - #setDimensions(width, height) { - const [parentWidth, parentHeight] = this.parentDimensions; - this.width = width / parentWidth; - this.height = height / parentHeight; - this.setDims(width, height); - if (this._initialOptions?.isCentered) { - this.center(); - } else { - this.fixAndSetPosition(); - } - this._initialOptions = null; - if (this.#resizeTimeoutId !== null) { - clearTimeout(this.#resizeTimeoutId); - } - const TIME_TO_WAIT = 200; - this.#resizeTimeoutId = setTimeout(() => { - this.#resizeTimeoutId = null; - this.#drawBitmap(width, height); - }, TIME_TO_WAIT); - } - #scaleBitmap(width, height) { - const { - width: bitmapWidth, - height: bitmapHeight - } = this.#bitmap; - let newWidth = bitmapWidth; - let newHeight = bitmapHeight; - let bitmap = this.#bitmap; - while (newWidth > 2 * width || newHeight > 2 * height) { - const prevWidth = newWidth; - const prevHeight = newHeight; - if (newWidth > 2 * width) { - newWidth = newWidth >= 16384 ? Math.floor(newWidth / 2) - 1 : Math.ceil(newWidth / 2); - } - if (newHeight > 2 * height) { - newHeight = newHeight >= 16384 ? Math.floor(newHeight / 2) - 1 : Math.ceil(newHeight / 2); - } - const offscreen = new OffscreenCanvas(newWidth, newHeight); - const ctx = offscreen.getContext("2d"); - ctx.drawImage(bitmap, 0, 0, prevWidth, prevHeight, 0, 0, newWidth, newHeight); - bitmap = offscreen.transferToImageBitmap(); - } - return bitmap; - } - #drawBitmap(width, height) { - width = Math.ceil(width); - height = Math.ceil(height); - const canvas = this.#canvas; - if (!canvas || canvas.width === width && canvas.height === height) { - return; - } - canvas.width = width; - canvas.height = height; - const bitmap = this.#isSvg ? this.#bitmap : this.#scaleBitmap(width, height); - if (this._uiManager.hasMLManager && !this.hasAltText()) { - const offscreen = new OffscreenCanvas(width, height); - const ctx = offscreen.getContext("2d"); - ctx.drawImage(bitmap, 0, 0, bitmap.width, bitmap.height, 0, 0, width, height); - this._uiManager.mlGuess({ - service: "image-to-text", - request: { - data: ctx.getImageData(0, 0, width, height).data, - width, - height, - channels: 4 - } - }).then(response => { - const altText = response?.output || ""; - if (this.parent && altText && !this.hasAltText()) { - this.altTextData = { - altText, - decorative: false - }; - } - }); - } - const ctx = canvas.getContext("2d"); - ctx.filter = this._uiManager.hcmFilter; - ctx.drawImage(bitmap, 0, 0, bitmap.width, bitmap.height, 0, 0, width, height); - } - getImageForAltText() { - return this.#canvas; - } - #serializeBitmap(toUrl) { - if (toUrl) { - if (this.#isSvg) { - const url = this._uiManager.imageManager.getSvgUrl(this.#bitmapId); - if (url) { - return url; - } - } - const canvas = document.createElement("canvas"); - ({ - width: canvas.width, - height: canvas.height - } = this.#bitmap); - const ctx = canvas.getContext("2d"); - ctx.drawImage(this.#bitmap, 0, 0); - return canvas.toDataURL(); - } - if (this.#isSvg) { - const [pageWidth, pageHeight] = this.pageDimensions; - const width = Math.round(this.width * pageWidth * PixelsPerInch.PDF_TO_CSS_UNITS); - const height = Math.round(this.height * pageHeight * PixelsPerInch.PDF_TO_CSS_UNITS); - const offscreen = new OffscreenCanvas(width, height); - const ctx = offscreen.getContext("2d"); - ctx.drawImage(this.#bitmap, 0, 0, this.#bitmap.width, this.#bitmap.height, 0, 0, width, height); - return offscreen.transferToImageBitmap(); - } - return structuredClone(this.#bitmap); - } - #createObserver() { - this.#observer = new ResizeObserver(entries => { - const rect = entries[0].contentRect; - if (rect.width && rect.height) { - this.#setDimensions(rect.width, rect.height); - } - }); - this.#observer.observe(this.div); - } - static deserialize(data, parent, uiManager) { - if (data instanceof StampAnnotationElement) { - return null; - } - const editor = super.deserialize(data, parent, uiManager); - const { - rect, - bitmapUrl, - bitmapId, - isSvg, - accessibilityData - } = data; - if (bitmapId && uiManager.imageManager.isValidId(bitmapId)) { - editor.#bitmapId = bitmapId; - } else { - editor.#bitmapUrl = bitmapUrl; - } - editor.#isSvg = isSvg; - const [parentWidth, parentHeight] = editor.pageDimensions; - editor.width = (rect[2] - rect[0]) / parentWidth; - editor.height = (rect[3] - rect[1]) / parentHeight; - if (accessibilityData) { - editor.altTextData = accessibilityData; - } - return editor; - } - serialize(isForCopying = false, context = null) { - if (this.isEmpty()) { - return null; - } - const serialized = { - annotationType: AnnotationEditorType.STAMP, - bitmapId: this.#bitmapId, - pageIndex: this.pageIndex, - rect: this.getRect(0, 0), - rotation: this.rotation, - isSvg: this.#isSvg, - structTreeParentId: this._structTreeParentId - }; - if (isForCopying) { - serialized.bitmapUrl = this.#serializeBitmap(true); - serialized.accessibilityData = this.altTextData; - return serialized; - } - const { - decorative, - altText - } = this.altTextData; - if (!decorative && altText) { - serialized.accessibilityData = { - type: "Figure", - alt: altText - }; - } - if (context === null) { - return serialized; - } - context.stamps ||= new Map(); - const area = this.#isSvg ? (serialized.rect[2] - serialized.rect[0]) * (serialized.rect[3] - serialized.rect[1]) : null; - if (!context.stamps.has(this.#bitmapId)) { - context.stamps.set(this.#bitmapId, { - area, - serialized - }); - serialized.bitmap = this.#serializeBitmap(false); - } else if (this.#isSvg) { - const prevData = context.stamps.get(this.#bitmapId); - if (area > prevData.area) { - prevData.area = area; - prevData.serialized.bitmap.close(); - prevData.serialized.bitmap = this.#serializeBitmap(false); - } - } - return serialized; - } -} - -;// CONCATENATED MODULE: ./src/display/editor/annotation_editor_layer.js - - - - - - - - - - - - - - - -class AnnotationEditorLayer { - #accessibilityManager; - #allowClick = false; - #annotationLayer = null; - #boundPointerup = null; - #boundPointerdown = null; - #boundTextLayerPointerDown = null; - #editorFocusTimeoutId = null; - #editors = new Map(); - #hadPointerDown = false; - #isCleaningUp = false; - #isDisabling = false; - #textLayer = null; - #uiManager; - static _initialized = false; - static #editorTypes = new Map([FreeTextEditor, InkEditor, StampEditor, HighlightEditor].map(type => [type._editorType, type])); - constructor({ - uiManager, - pageIndex, - div, - accessibilityManager, - annotationLayer, - drawLayer, - textLayer, - viewport, - l10n - }) { - const editorTypes = [...AnnotationEditorLayer.#editorTypes.values()]; - if (!AnnotationEditorLayer._initialized) { - AnnotationEditorLayer._initialized = true; - for (const editorType of editorTypes) { - editorType.initialize(l10n, uiManager); - } - } - uiManager.registerEditorTypes(editorTypes); - this.#uiManager = uiManager; - this.pageIndex = pageIndex; - this.div = div; - this.#accessibilityManager = accessibilityManager; - this.#annotationLayer = annotationLayer; - this.viewport = viewport; - this.#textLayer = textLayer; - this.drawLayer = drawLayer; - this.#uiManager.addLayer(this); - } - get isEmpty() { - return this.#editors.size === 0; - } - get isInvisible() { - return this.isEmpty && this.#uiManager.getMode() === AnnotationEditorType.NONE; - } - updateToolbar(mode) { - this.#uiManager.updateToolbar(mode); - } - updateMode(mode = this.#uiManager.getMode()) { - this.#cleanup(); - switch (mode) { - case AnnotationEditorType.NONE: - this.disableTextSelection(); - this.togglePointerEvents(false); - this.toggleAnnotationLayerPointerEvents(true); - this.disableClick(); - return; - case AnnotationEditorType.INK: - this.addInkEditorIfNeeded(false); - this.disableTextSelection(); - this.togglePointerEvents(true); - this.disableClick(); - break; - case AnnotationEditorType.HIGHLIGHT: - this.enableTextSelection(); - this.togglePointerEvents(false); - this.disableClick(); - break; - default: - this.disableTextSelection(); - this.togglePointerEvents(true); - this.enableClick(); - } - this.toggleAnnotationLayerPointerEvents(false); - const { - classList - } = this.div; - for (const editorType of AnnotationEditorLayer.#editorTypes.values()) { - classList.toggle(`${editorType._type}Editing`, mode === editorType._editorType); - } - this.div.hidden = false; - } - hasTextLayer(textLayer) { - return textLayer === this.#textLayer?.div; - } - addInkEditorIfNeeded(isCommitting) { - if (this.#uiManager.getMode() !== AnnotationEditorType.INK) { - return; - } - if (!isCommitting) { - for (const editor of this.#editors.values()) { - if (editor.isEmpty()) { - editor.setInBackground(); - return; - } - } - } - const editor = this.createAndAddNewEditor({ - offsetX: 0, - offsetY: 0 - }, false); - editor.setInBackground(); - } - setEditingState(isEditing) { - this.#uiManager.setEditingState(isEditing); - } - addCommands(params) { - this.#uiManager.addCommands(params); - } - togglePointerEvents(enabled = false) { - this.div.classList.toggle("disabled", !enabled); - } - toggleAnnotationLayerPointerEvents(enabled = false) { - this.#annotationLayer?.div.classList.toggle("disabled", !enabled); - } - enable() { - this.div.tabIndex = 0; - this.togglePointerEvents(true); - const annotationElementIds = new Set(); - for (const editor of this.#editors.values()) { - editor.enableEditing(); - editor.show(true); - if (editor.annotationElementId) { - this.#uiManager.removeChangedExistingAnnotation(editor); - annotationElementIds.add(editor.annotationElementId); - } - } - if (!this.#annotationLayer) { - return; - } - const editables = this.#annotationLayer.getEditableAnnotations(); - for (const editable of editables) { - editable.hide(); - if (this.#uiManager.isDeletedAnnotationElement(editable.data.id)) { - continue; - } - if (annotationElementIds.has(editable.data.id)) { - continue; - } - const editor = this.deserialize(editable); - if (!editor) { - continue; - } - this.addOrRebuild(editor); - editor.enableEditing(); - } - } - disable() { - this.#isDisabling = true; - this.div.tabIndex = -1; - this.togglePointerEvents(false); - const changedAnnotations = new Map(); - const resetAnnotations = new Map(); - for (const editor of this.#editors.values()) { - editor.disableEditing(); - if (!editor.annotationElementId) { - continue; - } - if (editor.serialize() !== null) { - changedAnnotations.set(editor.annotationElementId, editor); - continue; - } else { - resetAnnotations.set(editor.annotationElementId, editor); - } - this.getEditableAnnotation(editor.annotationElementId)?.show(); - editor.remove(); - } - if (this.#annotationLayer) { - const editables = this.#annotationLayer.getEditableAnnotations(); - for (const editable of editables) { - const { - id - } = editable.data; - if (this.#uiManager.isDeletedAnnotationElement(id)) { - continue; - } - let editor = resetAnnotations.get(id); - if (editor) { - editor.resetAnnotationElement(editable); - editor.show(false); - editable.show(); - continue; - } - editor = changedAnnotations.get(id); - if (editor) { - this.#uiManager.addChangedExistingAnnotation(editor); - editor.renderAnnotationElement(editable); - editor.show(false); - } - editable.show(); - } - } - this.#cleanup(); - if (this.isEmpty) { - this.div.hidden = true; - } - const { - classList - } = this.div; - for (const editorType of AnnotationEditorLayer.#editorTypes.values()) { - classList.remove(`${editorType._type}Editing`); - } - this.disableTextSelection(); - this.toggleAnnotationLayerPointerEvents(true); - this.#isDisabling = false; - } - getEditableAnnotation(id) { - return this.#annotationLayer?.getEditableAnnotation(id) || null; - } - setActiveEditor(editor) { - const currentActive = this.#uiManager.getActive(); - if (currentActive === editor) { - return; - } - this.#uiManager.setActiveEditor(editor); - } - enableTextSelection() { - this.div.tabIndex = -1; - if (this.#textLayer?.div && !this.#boundTextLayerPointerDown) { - this.#boundTextLayerPointerDown = this.#textLayerPointerDown.bind(this); - this.#textLayer.div.addEventListener("pointerdown", this.#boundTextLayerPointerDown); - this.#textLayer.div.classList.add("highlighting"); - } - } - disableTextSelection() { - this.div.tabIndex = 0; - if (this.#textLayer?.div && this.#boundTextLayerPointerDown) { - this.#textLayer.div.removeEventListener("pointerdown", this.#boundTextLayerPointerDown); - this.#boundTextLayerPointerDown = null; - this.#textLayer.div.classList.remove("highlighting"); - } - } - #textLayerPointerDown(event) { - this.#uiManager.unselectAll(); - if (event.target === this.#textLayer.div) { - const { - isMac - } = util_FeatureTest.platform; - if (event.button !== 0 || event.ctrlKey && isMac) { - return; - } - this.#uiManager.showAllEditors("highlight", true, true); - this.#textLayer.div.classList.add("free"); - HighlightEditor.startHighlighting(this, this.#uiManager.direction === "ltr", event); - this.#textLayer.div.addEventListener("pointerup", () => { - this.#textLayer.div.classList.remove("free"); - }, { - once: true - }); - event.preventDefault(); - } - } - enableClick() { - if (this.#boundPointerdown) { - return; - } - this.#boundPointerdown = this.pointerdown.bind(this); - this.#boundPointerup = this.pointerup.bind(this); - this.div.addEventListener("pointerdown", this.#boundPointerdown); - this.div.addEventListener("pointerup", this.#boundPointerup); - } - disableClick() { - if (!this.#boundPointerdown) { - return; - } - this.div.removeEventListener("pointerdown", this.#boundPointerdown); - this.div.removeEventListener("pointerup", this.#boundPointerup); - this.#boundPointerdown = null; - this.#boundPointerup = null; - } - attach(editor) { - this.#editors.set(editor.id, editor); - const { - annotationElementId - } = editor; - if (annotationElementId && this.#uiManager.isDeletedAnnotationElement(annotationElementId)) { - this.#uiManager.removeDeletedAnnotationElement(editor); - } - } - detach(editor) { - this.#editors.delete(editor.id); - this.#accessibilityManager?.removePointerInTextLayer(editor.contentDiv); - if (!this.#isDisabling && editor.annotationElementId) { - this.#uiManager.addDeletedAnnotationElement(editor); - } - } - remove(editor) { - this.detach(editor); - this.#uiManager.removeEditor(editor); - editor.div.remove(); - editor.isAttachedToDOM = false; - if (!this.#isCleaningUp) { - this.addInkEditorIfNeeded(false); - } - } - changeParent(editor) { - if (editor.parent === this) { - return; - } - if (editor.parent && editor.annotationElementId) { - this.#uiManager.addDeletedAnnotationElement(editor.annotationElementId); - AnnotationEditor.deleteAnnotationElement(editor); - editor.annotationElementId = null; - } - this.attach(editor); - editor.parent?.detach(editor); - editor.setParent(this); - if (editor.div && editor.isAttachedToDOM) { - editor.div.remove(); - this.div.append(editor.div); - } - } - add(editor) { - if (editor.parent === this && editor.isAttachedToDOM) { - return; - } - this.changeParent(editor); - this.#uiManager.addEditor(editor); - this.attach(editor); - if (!editor.isAttachedToDOM) { - const div = editor.render(); - this.div.append(div); - editor.isAttachedToDOM = true; - } - editor.fixAndSetPosition(); - editor.onceAdded(); - this.#uiManager.addToAnnotationStorage(editor); - editor._reportTelemetry(editor.telemetryInitialData); - } - moveEditorInDOM(editor) { - if (!editor.isAttachedToDOM) { - return; - } - const { - activeElement - } = document; - if (editor.div.contains(activeElement) && !this.#editorFocusTimeoutId) { - editor._focusEventsAllowed = false; - this.#editorFocusTimeoutId = setTimeout(() => { - this.#editorFocusTimeoutId = null; - if (!editor.div.contains(document.activeElement)) { - editor.div.addEventListener("focusin", () => { - editor._focusEventsAllowed = true; - }, { - once: true - }); - activeElement.focus(); - } else { - editor._focusEventsAllowed = true; - } - }, 0); - } - editor._structTreeParentId = this.#accessibilityManager?.moveElementInDOM(this.div, editor.div, editor.contentDiv, true); - } - addOrRebuild(editor) { - if (editor.needsToBeRebuilt()) { - editor.parent ||= this; - editor.rebuild(); - editor.show(); - } else { - this.add(editor); - } - } - addUndoableEditor(editor) { - const cmd = () => editor._uiManager.rebuild(editor); - const undo = () => { - editor.remove(); - }; - this.addCommands({ - cmd, - undo, - mustExec: false - }); - } - getNextId() { - return this.#uiManager.getId(); - } - get #currentEditorType() { - return AnnotationEditorLayer.#editorTypes.get(this.#uiManager.getMode()); - } - #createNewEditor(params) { - const editorType = this.#currentEditorType; - return editorType ? new editorType.prototype.constructor(params) : null; - } - canCreateNewEmptyEditor() { - return this.#currentEditorType?.canCreateNewEmptyEditor(); - } - pasteEditor(mode, params) { - this.#uiManager.updateToolbar(mode); - this.#uiManager.updateMode(mode); - const { - offsetX, - offsetY - } = this.#getCenterPoint(); - const id = this.getNextId(); - const editor = this.#createNewEditor({ - parent: this, - id, - x: offsetX, - y: offsetY, - uiManager: this.#uiManager, - isCentered: true, - ...params - }); - if (editor) { - this.add(editor); - } - } - deserialize(data) { - return AnnotationEditorLayer.#editorTypes.get(data.annotationType ?? data.annotationEditorType)?.deserialize(data, this, this.#uiManager) || null; - } - createAndAddNewEditor(event, isCentered, data = {}) { - const id = this.getNextId(); - const editor = this.#createNewEditor({ - parent: this, - id, - x: event.offsetX, - y: event.offsetY, - uiManager: this.#uiManager, - isCentered, - ...data - }); - if (editor) { - this.add(editor); - } - return editor; - } - #getCenterPoint() { - const { - x, - y, - width, - height - } = this.div.getBoundingClientRect(); - const tlX = Math.max(0, x); - const tlY = Math.max(0, y); - const brX = Math.min(window.innerWidth, x + width); - const brY = Math.min(window.innerHeight, y + height); - const centerX = (tlX + brX) / 2 - x; - const centerY = (tlY + brY) / 2 - y; - const [offsetX, offsetY] = this.viewport.rotation % 180 === 0 ? [centerX, centerY] : [centerY, centerX]; - return { - offsetX, - offsetY - }; - } - addNewEditor() { - this.createAndAddNewEditor(this.#getCenterPoint(), true); - } - setSelected(editor) { - this.#uiManager.setSelected(editor); - } - toggleSelected(editor) { - this.#uiManager.toggleSelected(editor); - } - isSelected(editor) { - return this.#uiManager.isSelected(editor); - } - unselect(editor) { - this.#uiManager.unselect(editor); - } - pointerup(event) { - const { - isMac - } = util_FeatureTest.platform; - if (event.button !== 0 || event.ctrlKey && isMac) { - return; - } - if (event.target !== this.div) { - return; - } - if (!this.#hadPointerDown) { - return; - } - this.#hadPointerDown = false; - if (!this.#allowClick) { - this.#allowClick = true; - return; - } - if (this.#uiManager.getMode() === AnnotationEditorType.STAMP) { - this.#uiManager.unselectAll(); - return; - } - this.createAndAddNewEditor(event, false); - } - pointerdown(event) { - if (this.#uiManager.getMode() === AnnotationEditorType.HIGHLIGHT) { - this.enableTextSelection(); - } - if (this.#hadPointerDown) { - this.#hadPointerDown = false; - return; - } - const { - isMac - } = util_FeatureTest.platform; - if (event.button !== 0 || event.ctrlKey && isMac) { - return; - } - if (event.target !== this.div) { - return; - } - this.#hadPointerDown = true; - const editor = this.#uiManager.getActive(); - this.#allowClick = !editor || editor.isEmpty(); - } - findNewParent(editor, x, y) { - const layer = this.#uiManager.findParent(x, y); - if (layer === null || layer === this) { - return false; - } - layer.changeParent(editor); - return true; - } - destroy() { - if (this.#uiManager.getActive()?.parent === this) { - this.#uiManager.commitOrRemove(); - this.#uiManager.setActiveEditor(null); - } - if (this.#editorFocusTimeoutId) { - clearTimeout(this.#editorFocusTimeoutId); - this.#editorFocusTimeoutId = null; - } - for (const editor of this.#editors.values()) { - this.#accessibilityManager?.removePointerInTextLayer(editor.contentDiv); - editor.setParent(null); - editor.isAttachedToDOM = false; - editor.div.remove(); - } - this.div = null; - this.#editors.clear(); - this.#uiManager.removeLayer(this); - } - #cleanup() { - this.#isCleaningUp = true; - for (const editor of this.#editors.values()) { - if (editor.isEmpty()) { - editor.remove(); - } - } - this.#isCleaningUp = false; - } - render({ - viewport - }) { - this.viewport = viewport; - setLayerDimensions(this.div, viewport); - for (const editor of this.#uiManager.getEditors(this.pageIndex)) { - this.add(editor); - editor.rebuild(); - } - this.updateMode(); - } - update({ - viewport - }) { - this.#uiManager.commitOrRemove(); - this.#cleanup(); - const oldRotation = this.viewport.rotation; - const rotation = viewport.rotation; - this.viewport = viewport; - setLayerDimensions(this.div, { - rotation - }); - if (oldRotation !== rotation) { - for (const editor of this.#editors.values()) { - editor.rotate(rotation); - } - } - this.addInkEditorIfNeeded(false); - } - get pageDimensions() { - const { - pageWidth, - pageHeight - } = this.viewport.rawDims; - return [pageWidth, pageHeight]; - } - get scale() { - return this.#uiManager.viewParameters.realScale; - } -} - -;// CONCATENATED MODULE: ./src/display/draw_layer.js - - -class DrawLayer { - #parent = null; - #id = 0; - #mapping = new Map(); - #toUpdate = new Map(); - constructor({ - pageIndex - }) { - this.pageIndex = pageIndex; - } - setParent(parent) { - if (!this.#parent) { - this.#parent = parent; - return; - } - if (this.#parent !== parent) { - if (this.#mapping.size > 0) { - for (const root of this.#mapping.values()) { - root.remove(); - parent.append(root); - } - } - this.#parent = parent; - } - } - static get _svgFactory() { - return shadow(this, "_svgFactory", new DOMSVGFactory()); - } - static #setBox(element, { - x = 0, - y = 0, - width = 1, - height = 1 - } = {}) { - const { - style - } = element; - style.top = `${100 * y}%`; - style.left = `${100 * x}%`; - style.width = `${100 * width}%`; - style.height = `${100 * height}%`; - } - #createSVG(box) { - const svg = DrawLayer._svgFactory.create(1, 1, true); - this.#parent.append(svg); - svg.setAttribute("aria-hidden", true); - DrawLayer.#setBox(svg, box); - return svg; - } - #createClipPath(defs, pathId) { - const clipPath = DrawLayer._svgFactory.createElement("clipPath"); - defs.append(clipPath); - const clipPathId = `clip_${pathId}`; - clipPath.setAttribute("id", clipPathId); - clipPath.setAttribute("clipPathUnits", "objectBoundingBox"); - const clipPathUse = DrawLayer._svgFactory.createElement("use"); - clipPath.append(clipPathUse); - clipPathUse.setAttribute("href", `#${pathId}`); - clipPathUse.classList.add("clip"); - return clipPathId; - } - highlight(outlines, color, opacity, isPathUpdatable = false) { - const id = this.#id++; - const root = this.#createSVG(outlines.box); - root.classList.add("highlight"); - if (outlines.free) { - root.classList.add("free"); - } - const defs = DrawLayer._svgFactory.createElement("defs"); - root.append(defs); - const path = DrawLayer._svgFactory.createElement("path"); - defs.append(path); - const pathId = `path_p${this.pageIndex}_${id}`; - path.setAttribute("id", pathId); - path.setAttribute("d", outlines.toSVGPath()); - if (isPathUpdatable) { - this.#toUpdate.set(id, path); - } - const clipPathId = this.#createClipPath(defs, pathId); - const use = DrawLayer._svgFactory.createElement("use"); - root.append(use); - root.setAttribute("fill", color); - root.setAttribute("fill-opacity", opacity); - use.setAttribute("href", `#${pathId}`); - this.#mapping.set(id, root); - return { - id, - clipPathId: `url(#${clipPathId})` - }; - } - highlightOutline(outlines) { - const id = this.#id++; - const root = this.#createSVG(outlines.box); - root.classList.add("highlightOutline"); - const defs = DrawLayer._svgFactory.createElement("defs"); - root.append(defs); - const path = DrawLayer._svgFactory.createElement("path"); - defs.append(path); - const pathId = `path_p${this.pageIndex}_${id}`; - path.setAttribute("id", pathId); - path.setAttribute("d", outlines.toSVGPath()); - path.setAttribute("vector-effect", "non-scaling-stroke"); - let maskId; - if (outlines.free) { - root.classList.add("free"); - const mask = DrawLayer._svgFactory.createElement("mask"); - defs.append(mask); - maskId = `mask_p${this.pageIndex}_${id}`; - mask.setAttribute("id", maskId); - mask.setAttribute("maskUnits", "objectBoundingBox"); - const rect = DrawLayer._svgFactory.createElement("rect"); - mask.append(rect); - rect.setAttribute("width", "1"); - rect.setAttribute("height", "1"); - rect.setAttribute("fill", "white"); - const use = DrawLayer._svgFactory.createElement("use"); - mask.append(use); - use.setAttribute("href", `#${pathId}`); - use.setAttribute("stroke", "none"); - use.setAttribute("fill", "black"); - use.setAttribute("fill-rule", "nonzero"); - use.classList.add("mask"); - } - const use1 = DrawLayer._svgFactory.createElement("use"); - root.append(use1); - use1.setAttribute("href", `#${pathId}`); - if (maskId) { - use1.setAttribute("mask", `url(#${maskId})`); - } - const use2 = use1.cloneNode(); - root.append(use2); - use1.classList.add("mainOutline"); - use2.classList.add("secondaryOutline"); - this.#mapping.set(id, root); - return id; - } - finalizeLine(id, line) { - const path = this.#toUpdate.get(id); - this.#toUpdate.delete(id); - this.updateBox(id, line.box); - path.setAttribute("d", line.toSVGPath()); - } - updateLine(id, line) { - const root = this.#mapping.get(id); - const defs = root.firstChild; - const path = defs.firstChild; - path.setAttribute("d", line.toSVGPath()); - } - removeFreeHighlight(id) { - this.remove(id); - this.#toUpdate.delete(id); - } - updatePath(id, line) { - this.#toUpdate.get(id).setAttribute("d", line.toSVGPath()); - } - updateBox(id, box) { - DrawLayer.#setBox(this.#mapping.get(id), box); - } - show(id, visible) { - this.#mapping.get(id).classList.toggle("hidden", !visible); - } - rotate(id, angle) { - this.#mapping.get(id).setAttribute("data-main-rotation", angle); - } - changeColor(id, color) { - this.#mapping.get(id).setAttribute("fill", color); - } - changeOpacity(id, opacity) { - this.#mapping.get(id).setAttribute("fill-opacity", opacity); - } - addClass(id, className) { - this.#mapping.get(id).classList.add(className); - } - removeClass(id, className) { - this.#mapping.get(id).classList.remove(className); - } - remove(id) { - if (this.#parent === null) { - return; - } - this.#mapping.get(id).remove(); - this.#mapping.delete(id); - } - destroy() { - this.#parent = null; - for (const root of this.#mapping.values()) { - root.remove(); - } - this.#mapping.clear(); - } -} - -;// CONCATENATED MODULE: ./src/pdf.js - - - - - - - - - - - - -const pdfjsVersion = "4.4.82"; -const pdfjsBuild = "8c6cee28e"; - -})(); - -var __webpack_exports__AbortException = __webpack_exports__.AbortException; -var __webpack_exports__AnnotationEditorLayer = __webpack_exports__.AnnotationEditorLayer; -var __webpack_exports__AnnotationEditorParamsType = __webpack_exports__.AnnotationEditorParamsType; -var __webpack_exports__AnnotationEditorType = __webpack_exports__.AnnotationEditorType; -var __webpack_exports__AnnotationEditorUIManager = __webpack_exports__.AnnotationEditorUIManager; -var __webpack_exports__AnnotationLayer = __webpack_exports__.AnnotationLayer; -var __webpack_exports__AnnotationMode = __webpack_exports__.AnnotationMode; -var __webpack_exports__CMapCompressionType = __webpack_exports__.CMapCompressionType; -var __webpack_exports__ColorPicker = __webpack_exports__.ColorPicker; -var __webpack_exports__DOMSVGFactory = __webpack_exports__.DOMSVGFactory; -var __webpack_exports__DrawLayer = __webpack_exports__.DrawLayer; -var __webpack_exports__FeatureTest = __webpack_exports__.FeatureTest; -var __webpack_exports__GlobalWorkerOptions = __webpack_exports__.GlobalWorkerOptions; -var __webpack_exports__ImageKind = __webpack_exports__.ImageKind; -var __webpack_exports__InvalidPDFException = __webpack_exports__.InvalidPDFException; -var __webpack_exports__MissingPDFException = __webpack_exports__.MissingPDFException; -var __webpack_exports__OPS = __webpack_exports__.OPS; -var __webpack_exports__Outliner = __webpack_exports__.Outliner; -var __webpack_exports__PDFDataRangeTransport = __webpack_exports__.PDFDataRangeTransport; -var __webpack_exports__PDFDateString = __webpack_exports__.PDFDateString; -var __webpack_exports__PDFWorker = __webpack_exports__.PDFWorker; -var __webpack_exports__PasswordResponses = __webpack_exports__.PasswordResponses; -var __webpack_exports__PermissionFlag = __webpack_exports__.PermissionFlag; -var __webpack_exports__PixelsPerInch = __webpack_exports__.PixelsPerInch; -var __webpack_exports__RenderingCancelledException = __webpack_exports__.RenderingCancelledException; -var __webpack_exports__TextLayer = __webpack_exports__.TextLayer; -var __webpack_exports__UnexpectedResponseException = __webpack_exports__.UnexpectedResponseException; -var __webpack_exports__Util = __webpack_exports__.Util; -var __webpack_exports__VerbosityLevel = __webpack_exports__.VerbosityLevel; -var __webpack_exports__XfaLayer = __webpack_exports__.XfaLayer; -var __webpack_exports__build = __webpack_exports__.build; -var __webpack_exports__createValidAbsoluteUrl = __webpack_exports__.createValidAbsoluteUrl; -var __webpack_exports__fetchData = __webpack_exports__.fetchData; -var __webpack_exports__getDocument = __webpack_exports__.getDocument; -var __webpack_exports__getFilenameFromUrl = __webpack_exports__.getFilenameFromUrl; -var __webpack_exports__getPdfFilenameFromUrl = __webpack_exports__.getPdfFilenameFromUrl; -var __webpack_exports__getXfaPageViewport = __webpack_exports__.getXfaPageViewport; -var __webpack_exports__isDataScheme = __webpack_exports__.isDataScheme; -var __webpack_exports__isPdfFile = __webpack_exports__.isPdfFile; -var __webpack_exports__noContextMenu = __webpack_exports__.noContextMenu; -var __webpack_exports__normalizeUnicode = __webpack_exports__.normalizeUnicode; -var __webpack_exports__renderTextLayer = __webpack_exports__.renderTextLayer; -var __webpack_exports__setLayerDimensions = __webpack_exports__.setLayerDimensions; -var __webpack_exports__shadow = __webpack_exports__.shadow; -var __webpack_exports__updateTextLayer = __webpack_exports__.updateTextLayer; -var __webpack_exports__version = __webpack_exports__.version; -export { __webpack_exports__AbortException as AbortException, __webpack_exports__AnnotationEditorLayer as AnnotationEditorLayer, __webpack_exports__AnnotationEditorParamsType as AnnotationEditorParamsType, __webpack_exports__AnnotationEditorType as AnnotationEditorType, __webpack_exports__AnnotationEditorUIManager as AnnotationEditorUIManager, __webpack_exports__AnnotationLayer as AnnotationLayer, __webpack_exports__AnnotationMode as AnnotationMode, __webpack_exports__CMapCompressionType as CMapCompressionType, __webpack_exports__ColorPicker as ColorPicker, __webpack_exports__DOMSVGFactory as DOMSVGFactory, __webpack_exports__DrawLayer as DrawLayer, __webpack_exports__FeatureTest as FeatureTest, __webpack_exports__GlobalWorkerOptions as GlobalWorkerOptions, __webpack_exports__ImageKind as ImageKind, __webpack_exports__InvalidPDFException as InvalidPDFException, __webpack_exports__MissingPDFException as MissingPDFException, __webpack_exports__OPS as OPS, __webpack_exports__Outliner as Outliner, __webpack_exports__PDFDataRangeTransport as PDFDataRangeTransport, __webpack_exports__PDFDateString as PDFDateString, __webpack_exports__PDFWorker as PDFWorker, __webpack_exports__PasswordResponses as PasswordResponses, __webpack_exports__PermissionFlag as PermissionFlag, __webpack_exports__PixelsPerInch as PixelsPerInch, __webpack_exports__RenderingCancelledException as RenderingCancelledException, __webpack_exports__TextLayer as TextLayer, __webpack_exports__UnexpectedResponseException as UnexpectedResponseException, __webpack_exports__Util as Util, __webpack_exports__VerbosityLevel as VerbosityLevel, __webpack_exports__XfaLayer as XfaLayer, __webpack_exports__build as build, __webpack_exports__createValidAbsoluteUrl as createValidAbsoluteUrl, __webpack_exports__fetchData as fetchData, __webpack_exports__getDocument as getDocument, __webpack_exports__getFilenameFromUrl as getFilenameFromUrl, __webpack_exports__getPdfFilenameFromUrl as getPdfFilenameFromUrl, __webpack_exports__getXfaPageViewport as getXfaPageViewport, __webpack_exports__isDataScheme as isDataScheme, __webpack_exports__isPdfFile as isPdfFile, __webpack_exports__noContextMenu as noContextMenu, __webpack_exports__normalizeUnicode as normalizeUnicode, __webpack_exports__renderTextLayer as renderTextLayer, __webpack_exports__setLayerDimensions as setLayerDimensions, __webpack_exports__shadow as shadow, __webpack_exports__updateTextLayer as updateTextLayer, __webpack_exports__version as version }; - -//# sourceMappingURL=pdf.mjs.map \ No newline at end of file diff --git a/static/pdf.js/pdf.mjs.map b/static/pdf.js/pdf.mjs.map deleted file mode 100644 index 08c6b7cf..00000000 --- a/static/pdf.js/pdf.mjs.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"pdf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ACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;AChMa;AACb,wBAAwB,mBAAO,CAAC,IAAmC;;AAEnE;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACTa;AACb,sBAAsB,mBAAO,CAAC,IAAgC;AAC9D,sBAAsB,mBAAO,CAAC,IAAgC;AAC9D,wBAAwB,mBAAO,CAAC,IAAmC;;AAEnE,sBAAsB,mBAAmB;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,WAAW,gBAAgB;AACjC;AACA,MAAM;AACN;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACjCa;AACb,kBAAkB,mBAAO,CAAC,IAA0B;AACpD,cAAc,mBAAO,CAAC,IAAuB;;AAE7C;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,0CAA0C,iBAAiB;AAC3D,IAAI;AACJ;AACA;AACA,CAAC;;AAED;AACA;AACA;AACA,IAAI;AACJ,EAAE;AACF;AACA;;;;;;;;AC1Ba;AACb,wBAAwB,mBAAO,CAAC,IAAmC;;AAEnE;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,SAAS;AAClB;AACA;;;;;;;;ACXa;AACb,wBAAwB,mBAAO,CAAC,IAAmC;AACnE,0BAA0B,mBAAO,CAAC,IAAqC;;AAEvE;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,SAAS;AAClB;AACA;;;;;;;;ACjBa;AACb,eAAe,mBAAO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AAe,mBAAO,CAAC,EAAwB;AAC/C,kCAAkC,mBAAO,CAAC,IAA6C;AACvF,aAAa,mBAAO,CAAC,IAA+B;AACpD,aAAa,mBAAO,CAAC,IAA2B;AAChD,gBAAgB,mBAAO,CAAC,IAAyB;AACjD,iBAAiB,mBAAO,CAAC,GAA0B;;AAEnD;AACA;AACA;AACA;;AAEA;AACA,uCAAuC;AACvC;;AAEA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACtEa;AACb,sBAAsB,mBAAO,CAAC,IAAgC;AAC9D,gBAAgB,mBAAO,CAAC,IAAwB;;AAEhD;AACA;;AAEA;AACA;AACA;AACA;;;;;;;;ACVa;AACb,cAAc,mBAAO,CAAC,IAA0B;;AAEhD;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACRa;AACb,cAAc,mBAAO,CAAC,IAAsB;;AAE5C;AACA;AACA;AACA;;;;;;;;ACNa;AACb;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,EAAE;AACF;AACA;;;;;;;;ACXa;AACb,YAAY,mBAAO,CAAC,IAAoB;AACxC,iBAAiB,mBAAO,CAAC,IAA0B;;AAEnD;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;;;;;;;ACtBa;AACb;AACA;AACA;AACA;AACA;;;;;;;;ACLa;AACb,iBAAiB,mBAAO,CAAC,IAA0B;;AAEnD;AACA;AACA;;;;;;;;ACLa;AACb,eAAe,mBAAO,CAAC,EAAwB;;AAE/C;AACA;AACA;;;;;;;;ACLa;AACb;;;;;;;;ACDa;AACb,iBAAiB,mBAAO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;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,CAAC;;AAED;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA;;;;;;;;AChDa;AACb;;;;;;;;ACDa;AACb,eAAe,mBAAO,CAAC,IAAwB;;AAE/C;AACA;AACA;AACA;AACA;;;;;;;;ACPa;AACb,kBAAkB,mBAAO,CAAC,IAAoC;AAC9D,YAAY,mBAAO,CAAC,IAAoB;AACxC,iBAAiB,mBAAO,CAAC,IAA0B;AACnD,aAAa,mBAAO,CAAC,IAA+B;AACpD,kBAAkB,mBAAO,CAAC,IAA0B;AACpD,iCAAiC,uCAAkD;AACnF,oBAAoB,mBAAO,CAAC,IAA6B;AACzD,0BAA0B,mBAAO,CAAC,IAA6B;;AAE/D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,sCAAsC,aAAa,cAAc,UAAU;AAC3E,CAAC;;AAED;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qDAAqD,iCAAiC;AACtF;AACA;AACA;AACA,sCAAsC,sBAAsB;AAC5D;AACA;AACA;AACA,4DAA4D,iBAAiB;AAC7E;AACA,MAAM;AACN,IAAI,gBAAgB;AACpB;AACA;AACA;AACA,IAAI;AACJ;;AAEA;AACA;AACA;AACA;AACA,CAAC;;;;;;;;ACtDY;AACb;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACVa;AACb,gBAAgB,mBAAO,CAAC,IAAyB;;AAEjD;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;;AAEA;AACA;AACA,gBAAgB;AAChB;AACA;;;;;;;;ACpBa;AACb,eAAe,mBAAO,CAAC,GAAwB;;AAE/C;AACA;AACA;;;;;;;;ACLa;AACb;;AAEA;AACA;AACA;AACA;AACA;;;;;;;;ACPa;AACb;AACA,eAAe,mBAAO,CAAC,IAAw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,mBAAO,CAAC,IAAmC;AACnE,qBAAqB,mBAAO,CAAC,IAA8B;AAC3D,YAAY,mBAAO,CAAC,IAAoB;AACxC,sBAAsB,mBAAO,CAAC,IAAgC;AAC9D,oBAAoB,mBAAO,CAAC,IAA2C;;AAEvE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6CAA6C,WAAW;AACxD;;AAEA;AACA;AACA;AACA,iEAAiE,sBAAsB;AACvF;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kBAAkB,SAAS;AAC3B;AACA;AACA,MAAM;AACN;AACA;AACA,kBAAkB,SAAS;AAC3B;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN,GAAG;AACH;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6BAA6B;AAC7B,8BAA8B;AAC9B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6BAA6B;AAC7B;AACA;AACA;AACA;AACA,QAAQ,mBAAmB;AAC3B;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAC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wE,IAAI;AAChF;AACA,CAAC;;AAED;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACnEa;AACb,oBAAoB,mBAAO,CAAC,IAA8B;AAC1D,kBAAkB,mBAAO,CAAC,IAAoC;AAC9D,eAAe,mBAAO,CAAC,GAAwB;AAC/C,8BAA8B,mBAAO,CAAC,IAAwC;;AAE9E;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,oCAAoC;AACpC,sBAAsB,kBAAkB;AACxC,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA,GAAG,IAAI,gCAAgC;AACvC;;;;;;;;AChDa;AACb,oBAAoB,mBAAO,CAAC,IAA8B;AAC1D,kBAAkB,mBAAO,CAAC,IAAoC;AAC9D,eAAe,mBAAO,CAAC,GAAwB;AAC/C,8BAA8B,mBAAO,CAAC,IAAwC;;AAE9E;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qCAAqC;AACrC;AACA;AACA;AACA;AACA;AACA,MAAM;AACN,GAAG,IAAI,gCAAgC;AACvC;;;;;;;;AC3Ba;AACb,kBAAkB,mBAAO,CAAC,IAA0B;AACpD,kBAAkB,mBAAO,CAAC,IAAoC;AAC9D,4BAA4B,mBAAO,CAAC,IAAuC;;AAE3E;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,kCAAkC,UAAU;AAC5C;AACA,KAAK;AACL;AACA;AACA,GAAG;AACH;;;;;;;SCpBA;SACA;;SAEA;SACA;SACA;SACA;SACA;SACA;SACA;SACA;SACA;SACA;SACA;SACA;SACA;;SAEA;SACA;;SAEA;SACA;SACA;;;;;UCtBA;UACA;UACA;UACA;UACA,yCAAyC,wCAAwC;UACjF;UACA;UACA;;;;;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N,SAAS,EAAE;IACzB,IAAI,CAAC,CAACwwF,OAAO,CAACtiG,GAAG,CAACoE,EAAE,CAAC,CAAC8O,SAAS,CAAC3M,MAAM,CAACuL,SAAS,CAAC;EACnD;EAEAvL,MAAMA,CAACnC,EAAE,EAAE;IACT,IAAI,IAAI,CAAC,CAACwQ,MAAM,KAAK,IAAI,EAAE;MACzB;IACF;IACA,IAAI,CAAC,CAAC0tF,OAAO,CAACtiG,GAAG,CAACoE,EAAE,CAAC,CAACmC,MAAM,CAAC,CAAC;IAC9B,IAAI,CAAC,CAAC+7F,OAAO,CAAC5uF,MAAM,CAACtP,EAAE,CAAC;EAC1B;EAEAtC,OAAOA,CAAA,EAAG;IACR,IAAI,CAAC,CAAC8S,MAAM,GAAG,IAAI;IACnB,KAAK,MAAMu9D,IAAI,IAAI,IAAI,CAAC,CAACmwB,OAAO,CAAC5hF,MAAM,CAAC,CAAC,EAAE;MACzCyxD,IAAI,CAAC5rE,MAAM,CAAC,CAAC;IACf;IACA,IAAI,CAAC,CAAC+7F,OAAO,CAACl6F,KAAK,CAAC,CAAC;EACvB;AACF;;;ACvM0B;AAOA;AAcU;AAKH;AACmD;AACd;AACN;AACD;AACX;AACc;AACV;AACN;AAGlD,MAAMo7F,YAAY,GACkB,QAAwC;AAE5E,MAAMC,UAAU,GACoB,WAAsC","sources":["webpack://pdf.js/./node_modules/core-js/internals/a-callable.js","webpack://pdf.js/./node_modules/core-js/internals/a-possible-prototype.js","webpack://pdf.js/./node_modules/core-js/internals/a-set.js","webpack://pdf.js/./node_modules/core-js/internals/an-instance.js","webpack://pdf.js/./node_modules/core-js/internals/an-object.js","webpack://pdf.js/./node_modules/core-js/internals/array-buffer-basic-detection.js","webpack://pdf.js/./node_modules/core-js/internals/array-buffer-byte-length.js","webpack://pdf.js/./node_modules/core-js/internals/array-buffer-is-detached.js","webpack://pdf.js/./node_modules/core-js/internals/array-buffer-transfer.js","webpack://pdf.js/./node_modules/core-js/internals/array-buffer-view-core.js","webpack://pdf.js/./node_modules/core-js/internals/array-from-constructor-and-list.js","webpack://pdf.js/./node_modules/core-js/internals/array-includes.js","webpack://pdf.js/./node_modules/core-js/internals/array-set-length.js","webpack://pdf.js/./node_modules/core-js/internals/array-to-reversed.js","webpack://pdf.js/./node_modules/core-js/internals/array-with.js","webpack://pdf.js/./node_modules/core-js/internals/call-with-safe-iteration-closing.js","webpack://pdf.js/./node_modules/core-js/internals/classof-raw.js","webpack://pdf.js/./node_modules/core-js/internals/classof.js","webpack://pdf.js/./node_modules/core-js/internals/copy-constructor-properties.js","webpack://pdf.js/./node_modules/core-js/internals/correct-prototype-getter.js","webpack://pdf.js/./node_modules/core-js/internals/create-iter-result-object.js","webpack://pdf.js/./node_modules/core-js/internals/create-non-enumerable-property.js","webpack://pdf.js/./node_modules/core-js/internals/create-property-descriptor.js","webpack://pdf.js/./node_modules/core-js/internals/create-property.js","webpack://pdf.js/./node_modules/core-js/internals/define-built-in-accessor.js","webpack://pdf.js/./node_modules/core-js/internals/define-built-in.js","webpack://pdf.js/./node_modules/core-js/internals/define-built-ins.js","webpack://pdf.js/./node_modules/core-js/internals/define-global-property.js","webpack://pdf.js/./node_modules/core-js/internals/descriptors.js","webpack://pdf.js/./node_modules/core-js/internals/detach-transferable.js","webpack://pdf.js/./node_modules/core-js/internals/document-create-element.js","webpack://pdf.js/./node_modules/core-js/internals/does-not-exceed-safe-integer.js","webpack://pdf.js/./node_modules/core-js/internals/dom-exception-constants.js","webpack://pdf.js/./node_modules/core-js/internals/engine-is-browser.js","webpack://pdf.js/./node_modules/core-js/internals/engine-is-deno.js","webpack://pdf.js/./node_modules/core-js/internals/engine-is-node.js","webpack://pdf.js/./node_modules/core-js/internals/engine-user-agent.js","webpack://pdf.js/./node_modules/core-js/internals/engine-v8-version.js","webpack://pdf.js/./node_modules/core-js/internals/enum-bug-keys.js","webpack://pdf.js/./node_modules/core-js/internals/error-stack-clear.js","webpack://pdf.js/./node_modules/core-js/internals/export.js","webpack://pdf.js/./node_modules/core-js/internals/fails.js","webpack://pdf.js/./node_modules/core-js/internals/function-bind-context.js","webpack://pdf.js/./node_modules/core-js/internals/function-bind-native.js","webpack://pdf.js/./node_modules/core-js/internals/function-call.js","webpack://pdf.js/./node_modules/core-js/internals/function-name.js","webpack://pdf.js/./node_modules/core-js/internals/function-uncurry-this-accessor.js","webpack://pdf.js/./node_modules/core-js/internals/function-uncurry-this-clause.js","webpack://pdf.js/./node_modules/core-js/internals/function-uncurry-this.js","webpack://pdf.js/./node_modules/core-js/internals/get-built-in.js","webpack://pdf.js/./node_modules/core-js/internals/get-iterator-direct.js","webpack://pdf.js/./node_modules/core-js/internals/get-iterator-flattenable.js","webpack://pdf.js/./node_modules/core-js/internals/get-iterator-method.js","webpack://pdf.js/./node_modules/core-js/internals/get-iterator.js","webpack://pdf.js/./node_modules/core-js/internals/get-method.js","webpack://pdf.js/./node_modules/core-js/internals/get-set-record.js","webpack://pdf.js/./node_modules/core-js/internals/global.js","webpack://pdf.js/./node_modules/core-js/internals/has-own-property.js","webpack://pdf.js/./node_modules/core-js/internals/hidden-keys.js","webpack://pdf.js/./node_modules/core-js/internals/html.js","webpack://pdf.js/./node_modules/core-js/internals/ie8-dom-define.js","webpack://pdf.js/./node_modules/core-js/internals/indexed-object.js","webpack://pdf.js/./node_modules/core-js/internals/inherit-if-required.js","webpack://pdf.js/./node_modules/core-js/internals/inspect-source.js","webpack://pdf.js/./node_modules/core-js/internals/internal-state.js","webpack://pdf.js/./node_modules/core-js/internals/is-array-iterator-method.js","webpack://pdf.js/./node_modules/core-js/internals/is-array.js","webpack://pdf.js/./node_modules/core-js/internals/is-big-int-array.js","webpack://pdf.js/./node_modules/core-js/internals/is-callable.js","webpack://pdf.js/./node_modules/core-js/internals/is-forced.js","webpack://pdf.js/./node_modules/core-js/internals/is-null-or-undefined.js","webpack://pdf.js/./node_modules/core-js/internals/is-object.js","webpack://pdf.js/./node_modules/core-js/internals/is-possible-prototype.js","webpack://pdf.js/./node_modules/core-js/internals/is-pure.js","webpack://pdf.js/./node_modules/core-js/internals/is-symbol.js","webpack://pdf.js/./node_modules/core-js/internals/iterate-simple.js","webpack://pdf.js/./node_modules/core-js/internals/iterate.js","webpack://pdf.js/./node_modules/core-js/internals/iterator-close.js","webpack://pdf.js/./node_modules/core-js/internals/iterator-create-proxy.js","webpack://pdf.js/./node_modules/core-js/internals/iterator-map.js","webpack://pdf.js/./node_modules/core-js/internals/iterators-core.js","webpack://pdf.js/./node_modules/core-js/internals/iterators.js","webpack://pdf.js/./node_modules/core-js/internals/length-of-array-like.js","webpack://pdf.js/./node_modules/core-js/internals/make-built-in.js","webpack://pdf.js/./node_modules/core-js/internals/math-trunc.js","webpack://pdf.js/./node_modules/core-js/internals/new-promise-capability.js","webpack://pdf.js/./node_modules/core-js/internals/normalize-string-argument.js","webpack://pdf.js/./node_modules/core-js/internals/not-a-nan.js","webpack://pdf.js/./node_modules/core-js/internals/object-create.js","webpack://pdf.js/./node_modules/core-js/internals/object-define-properties.js","webpack://pdf.js/./node_modules/core-js/internals/object-define-property.js","webpack://pdf.js/./node_modules/core-js/internals/object-get-own-property-descriptor.js","webpack://pdf.js/./node_modules/core-js/internals/object-get-own-property-names.js","webpack://pdf.js/./node_modules/core-js/internals/object-get-own-property-symbols.js","webpack://pdf.js/./node_modules/core-js/internals/object-get-prototype-of.js","webpack://pdf.js/./node_modules/core-js/internals/object-is-prototype-of.js","webpack://pdf.js/./node_modules/core-js/internals/object-keys-internal.js","webpack://pdf.js/./node_modules/core-js/internals/object-keys.js","webpack://pdf.js/./node_modules/core-js/internals/object-property-is-enumerable.js","webpack://pdf.js/./node_modules/core-js/internals/object-set-prototype-of.js","webpack://pdf.js/./node_modules/core-js/internals/ordinary-to-primitive.js","webpack://pdf.js/./node_modules/core-js/internals/own-keys.js","webpack://pdf.js/./node_modules/core-js/internals/parse-json-string.js","webpack://pdf.js/./node_modules/core-js/internals/require-object-coercible.js","webpack://pdf.js/./node_modules/core-js/internals/set-clone.js","webpack://pdf.js/./node_modules/core-js/internals/set-difference.js","webpack://pdf.js/./node_modules/core-js/internals/set-helpers.js","webpack://pdf.js/./node_modules/core-js/internals/set-intersection.js","webpack://pdf.js/./node_modules/core-js/internals/set-is-disjoint-from.js","webpack://pdf.js/./node_modules/core-js/internals/set-is-subset-of.js","webpack://pdf.js/./node_modules/core-js/internals/set-is-superset-of.js","webpack://pdf.js/./node_modules/core-js/internals/set-iterate.js","webpack://pdf.js/./node_modules/core-js/internals/set-method-accept-set-like.js","webpack://pdf.js/./node_modules/core-js/internals/set-size.js","webpack://pdf.js/./node_modules/core-js/internals/set-symmetric-difference.js","webpack://pdf.js/./node_modules/core-js/internals/set-union.js","webpack://pdf.js/./node_modules/core-js/internals/shared-key.js","webpack://pdf.js/./node_modules/core-js/internals/shared-store.js","webpack://pdf.js/./node_modules/core-js/internals/shared.js","webpack://pdf.js/./node_modules/core-js/internals/structured-clone-proper-transfer.js","webpack://pdf.js/./node_modules/core-js/internals/symbol-constructor-detection.js","webpack://pdf.js/./node_modules/core-js/internals/to-absolute-index.js","webpack://pdf.js/./node_modules/core-js/internals/to-big-int.js","webpack://pdf.js/./node_modules/core-js/internals/to-index.js","webpack://pdf.js/./node_modules/core-js/internals/to-indexed-object.js","webpack://pdf.js/./node_modules/core-js/internals/to-integer-or-infinity.js","webpack://pdf.js/./node_modules/core-js/internals/to-length.js","webpack://pdf.js/./node_modules/core-js/internals/to-object.js","webpack://pdf.js/./node_modules/core-js/internals/to-positive-integer.js","webpack://pdf.js/./node_modules/core-js/internals/to-primitive.js","webpack://pdf.js/./node_modules/core-js/internals/to-property-key.js","webpack://pdf.js/./node_modules/core-js/internals/to-string-tag-support.js","webpack://pdf.js/./node_modules/core-js/internals/to-string.js","webpack://pdf.js/./node_modules/core-js/internals/try-node-require.js","webpack://pdf.js/./node_modules/core-js/internals/try-to-string.js","webpack://pdf.js/./node_modules/core-js/internals/uid.js","webpack://pdf.js/./node_modules/core-js/internals/use-symbol-as-uid.js","webpack://pdf.js/./node_modules/core-js/internals/v8-prototype-define-bug.js","webpack://pdf.js/./node_modules/core-js/internals/validate-arguments-length.js","webpack://pdf.js/./node_modules/core-js/internals/weak-map-basic-detection.js","webpack://pdf.js/./node_modules/core-js/internals/well-known-symbol.js","webpack://pdf.js/./node_modules/core-js/modules/es.array-buffer.detached.js","webpack://pdf.js/./node_modules/core-js/modules/es.array-buffer.transfer-to-fixed-length.js","webpack://pdf.js/./node_modules/core-js/modules/es.array-buffer.transfer.js","webpack://pdf.js/./node_modules/core-js/modules/es.array.push.js","webpack://pdf.js/./node_modules/core-js/modules/es.promise.with-resolvers.js","webpack://pdf.js/./node_modules/core-js/modules/es.set.difference.v2.js","webpack://pdf.js/./node_modules/core-js/modules/es.set.intersection.v2.js","webpack://pdf.js/./node_modules/core-js/modules/es.set.is-disjoint-from.v2.js","webpack://pdf.js/./node_modules/core-js/modules/es.set.is-subset-of.v2.js","webpack://pdf.js/./node_modules/core-js/modules/es.set.is-superset-of.v2.js","webpack://pdf.js/./node_modules/core-js/modules/es.set.symmetric-difference.v2.js","webpack://pdf.js/./node_modules/core-js/modules/es.set.union.v2.js","webpack://pdf.js/./node_modules/core-js/modules/es.typed-array.to-reversed.js","webpack://pdf.js/./node_modules/core-js/modules/es.typed-array.to-sorted.js","webpack://pdf.js/./node_modules/core-js/modules/es.typed-array.with.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.iterator.constructor.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.iterator.drop.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.iterator.every.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.iterator.filter.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.iterator.flat-map.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.iterator.map.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.iterator.some.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.json.parse.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.set.difference.v2.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.set.intersection.v2.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.set.is-disjoint-from.v2.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.set.is-subset-of.v2.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.set.is-superset-of.v2.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.set.symmetric-difference.v2.js","webpack://pdf.js/./node_modules/core-js/modules/esnext.set.union.v2.js","webpack://pdf.js/./node_modules/core-js/modules/web.dom-exception.stack.js","webpack://pdf.js/./node_modules/core-js/modules/web.url-search-params.delete.js","webpack://pdf.js/./node_modules/core-js/modules/web.url-search-params.has.js","webpack://pdf.js/./node_modules/core-js/modules/web.url-search-params.size.js","webpack://pdf.js/webpack/bootstrap","webpack://pdf.js/webpack/runtime/define property getters","webpack://pdf.js/webpack/runtime/hasOwnProperty shorthand","webpack://pdf.js/./src/shared/util.js","webpack://pdf.js/./src/display/base_factory.js","webpack://pdf.js/./src/display/display_utils.js","webpack://pdf.js/./src/display/editor/toolbar.js","webpack://pdf.js/./src/display/editor/tools.js","webpack://pdf.js/./src/display/editor/alt_text.js","webpack://pdf.js/./src/display/editor/editor.js","webpack://pdf.js/./src/shared/murmurhash3.js","webpack://pdf.js/./src/display/annotation_storage.js","webpack://pdf.js/./src/display/font_loader.js","webpack://pdf.js/./src/display/node_utils.js","webpack://pdf.js/./src/display/pattern_helper.js","webpack://pdf.js/./src/shared/image_utils.js","webpack://pdf.js/./src/display/canvas.js","webpack://pdf.js/./src/display/worker_options.js","webpack://pdf.js/./src/shared/message_handler.js","webpack://pdf.js/./src/display/metadata.js","webpack://pdf.js/./src/display/optional_content_config.js","webpack://pdf.js/./src/display/transport_stream.js","webpack://pdf.js/./src/display/content_disposition.js","webpack://pdf.js/./src/display/network_utils.js","webpack://pdf.js/./src/display/fetch_stream.js","webpack://pdf.js/./src/display/network.js","webpack://pdf.js/./src/display/node_stream.js","webpack://pdf.js/./src/display/text_layer.js","webpack://pdf.js/./src/display/xfa_text.js","webpack://pdf.js/./src/display/api.js","webpack://pdf.js/./src/shared/scripting_utils.js","webpack://pdf.js/./src/display/xfa_layer.js","webpack://pdf.js/./src/display/annotation_layer.js","webpack://pdf.js/./src/display/editor/freetext.js","webpack://pdf.js/./src/display/editor/outliner.js","webpack://pdf.js/./src/display/editor/color_picker.js","webpack://pdf.js/./src/display/editor/highlight.js","webpack://pdf.js/./src/display/editor/ink.js","webpack://pdf.js/./src/display/editor/stamp.js","webpack://pdf.js/./src/display/editor/annotation_editor_layer.js","webpack://pdf.js/./src/display/draw_layer.js","webpack://pdf.js/./src/pdf.js"],"sourcesContent":["'use strict';\nvar isCallable = require('../internals/is-callable');\nvar tryToString = require('../internals/try-to-string');\n\nvar $TypeError = TypeError;\n\n// `Assert: IsCallable(argument) is true`\nmodule.exports = function (argument) {\n if (isCallable(argument)) return argument;\n throw new $TypeError(tryToString(argument) + ' is not a function');\n};\n","'use strict';\nvar isPossiblePrototype = require('../internals/is-possible-prototype');\n\nvar $String = String;\nvar $TypeError = TypeError;\n\nmodule.exports = function (argument) {\n if (isPossiblePrototype(argument)) return argument;\n throw new $TypeError(\"Can't set \" + $String(argument) + ' as a prototype');\n};\n","'use strict';\nvar has = require('../internals/set-helpers').has;\n\n// Perform ? RequireInternalSlot(M, [[SetData]])\nmodule.exports = function (it) {\n has(it);\n return it;\n};\n","'use strict';\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\n\nvar $TypeError = TypeError;\n\nmodule.exports = function (it, Prototype) {\n if (isPrototypeOf(Prototype, it)) return it;\n throw new $TypeError('Incorrect invocation');\n};\n","'use strict';\nvar isObject = require('../internals/is-object');\n\nvar $String = String;\nvar $TypeError = TypeError;\n\n// `Assert: Type(argument) is Object`\nmodule.exports = function (argument) {\n if (isObject(argument)) return argument;\n throw new $TypeError($String(argument) + ' is not an object');\n};\n","'use strict';\n// eslint-disable-next-line es/no-typed-arrays -- safe\nmodule.exports = typeof ArrayBuffer != 'undefined' && typeof DataView != 'undefined';\n","'use strict';\nvar uncurryThisAccessor = require('../internals/function-uncurry-this-accessor');\nvar classof = require('../internals/classof-raw');\n\nvar $TypeError = TypeError;\n\n// Includes\n// - Perform ? RequireInternalSlot(O, [[ArrayBufferData]]).\n// - If IsSharedArrayBuffer(O) is true, throw a TypeError exception.\nmodule.exports = uncurryThisAccessor(ArrayBuffer.prototype, 'byteLength', 'get') || function (O) {\n if (classof(O) !== 'ArrayBuffer') throw new $TypeError('ArrayBuffer expected');\n return O.byteLength;\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar arrayBufferByteLength = require('../internals/array-buffer-byte-length');\n\nvar slice = uncurryThis(ArrayBuffer.prototype.slice);\n\nmodule.exports = function (O) {\n if (arrayBufferByteLength(O) !== 0) return false;\n try {\n slice(O, 0, 0);\n return false;\n } catch (error) {\n return true;\n }\n};\n","'use strict';\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar uncurryThisAccessor = require('../internals/function-uncurry-this-accessor');\nvar toIndex = require('../internals/to-index');\nvar isDetached = require('../internals/array-buffer-is-detached');\nvar arrayBufferByteLength = require('../internals/array-buffer-byte-length');\nvar detachTransferable = require('../internals/detach-transferable');\nvar PROPER_STRUCTURED_CLONE_TRANSFER = require('../internals/structured-clone-proper-transfer');\n\nvar structuredClone = global.structuredClone;\nvar ArrayBuffer = global.ArrayBuffer;\nvar DataView = global.DataView;\nvar TypeError = global.TypeError;\nvar min = Math.min;\nvar ArrayBufferPrototype = ArrayBuffer.prototype;\nvar DataViewPrototype = DataView.prototype;\nvar slice = uncurryThis(ArrayBufferPrototype.slice);\nvar isResizable = uncurryThisAccessor(ArrayBufferPrototype, 'resizable', 'get');\nvar maxByteLength = uncurryThisAccessor(ArrayBufferPrototype, 'maxByteLength', 'get');\nvar getInt8 = uncurryThis(DataViewPrototype.getInt8);\nvar setInt8 = uncurryThis(DataViewPrototype.setInt8);\n\nmodule.exports = (PROPER_STRUCTURED_CLONE_TRANSFER || detachTransferable) && function (arrayBuffer, newLength, preserveResizability) {\n var byteLength = arrayBufferByteLength(arrayBuffer);\n var newByteLength = newLength === undefined ? byteLength : toIndex(newLength);\n var fixedLength = !isResizable || !isResizable(arrayBuffer);\n var newBuffer;\n if (isDetached(arrayBuffer)) throw new TypeError('ArrayBuffer is detached');\n if (PROPER_STRUCTURED_CLONE_TRANSFER) {\n arrayBuffer = structuredClone(arrayBuffer, { transfer: [arrayBuffer] });\n if (byteLength === newByteLength && (preserveResizability || fixedLength)) return arrayBuffer;\n }\n if (byteLength >= newByteLength && (!preserveResizability || fixedLength)) {\n newBuffer = slice(arrayBuffer, 0, newByteLength);\n } else {\n var options = preserveResizability && !fixedLength && maxByteLength ? { maxByteLength: maxByteLength(arrayBuffer) } : undefined;\n newBuffer = new ArrayBuffer(newByteLength, options);\n var a = new DataView(arrayBuffer);\n var b = new DataView(newBuffer);\n var copyLength = min(newByteLength, byteLength);\n for (var i = 0; i < copyLength; i++) setInt8(b, i, getInt8(a, i));\n }\n if (!PROPER_STRUCTURED_CLONE_TRANSFER) detachTransferable(arrayBuffer);\n return newBuffer;\n};\n","'use strict';\nvar NATIVE_ARRAY_BUFFER = require('../internals/array-buffer-basic-detection');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar hasOwn = require('../internals/has-own-property');\nvar classof = require('../internals/classof');\nvar tryToString = require('../internals/try-to-string');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar defineBuiltIn = require('../internals/define-built-in');\nvar defineBuiltInAccessor = require('../internals/define-built-in-accessor');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar uid = require('../internals/uid');\nvar InternalStateModule = require('../internals/internal-state');\n\nvar enforceInternalState = InternalStateModule.enforce;\nvar getInternalState = InternalStateModule.get;\nvar Int8Array = global.Int8Array;\nvar Int8ArrayPrototype = Int8Array && Int8Array.prototype;\nvar Uint8ClampedArray = global.Uint8ClampedArray;\nvar Uint8ClampedArrayPrototype = Uint8ClampedArray && Uint8ClampedArray.prototype;\nvar TypedArray = Int8Array && getPrototypeOf(Int8Array);\nvar TypedArrayPrototype = Int8ArrayPrototype && getPrototypeOf(Int8ArrayPrototype);\nvar ObjectPrototype = Object.prototype;\nvar TypeError = global.TypeError;\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar TYPED_ARRAY_TAG = uid('TYPED_ARRAY_TAG');\nvar TYPED_ARRAY_CONSTRUCTOR = 'TypedArrayConstructor';\n// Fixing native typed arrays in Opera Presto crashes the browser, see #595\nvar NATIVE_ARRAY_BUFFER_VIEWS = NATIVE_ARRAY_BUFFER && !!setPrototypeOf && classof(global.opera) !== 'Opera';\nvar TYPED_ARRAY_TAG_REQUIRED = false;\nvar NAME, Constructor, Prototype;\n\nvar TypedArrayConstructorsList = {\n Int8Array: 1,\n Uint8Array: 1,\n Uint8ClampedArray: 1,\n Int16Array: 2,\n Uint16Array: 2,\n Int32Array: 4,\n Uint32Array: 4,\n Float32Array: 4,\n Float64Array: 8\n};\n\nvar BigIntArrayConstructorsList = {\n BigInt64Array: 8,\n BigUint64Array: 8\n};\n\nvar isView = function isView(it) {\n if (!isObject(it)) return false;\n var klass = classof(it);\n return klass === 'DataView'\n || hasOwn(TypedArrayConstructorsList, klass)\n || hasOwn(BigIntArrayConstructorsList, klass);\n};\n\nvar getTypedArrayConstructor = function (it) {\n var proto = getPrototypeOf(it);\n if (!isObject(proto)) return;\n var state = getInternalState(proto);\n return (state && hasOwn(state, TYPED_ARRAY_CONSTRUCTOR)) ? state[TYPED_ARRAY_CONSTRUCTOR] : getTypedArrayConstructor(proto);\n};\n\nvar isTypedArray = function (it) {\n if (!isObject(it)) return false;\n var klass = classof(it);\n return hasOwn(TypedArrayConstructorsList, klass)\n || hasOwn(BigIntArrayConstructorsList, klass);\n};\n\nvar aTypedArray = function (it) {\n if (isTypedArray(it)) return it;\n throw new TypeError('Target is not a typed array');\n};\n\nvar aTypedArrayConstructor = function (C) {\n if (isCallable(C) && (!setPrototypeOf || isPrototypeOf(TypedArray, C))) return C;\n throw new TypeError(tryToString(C) + ' is not a typed array constructor');\n};\n\nvar exportTypedArrayMethod = function (KEY, property, forced, options) {\n if (!DESCRIPTORS) return;\n if (forced) for (var ARRAY in TypedArrayConstructorsList) {\n var TypedArrayConstructor = global[ARRAY];\n if (TypedArrayConstructor && hasOwn(TypedArrayConstructor.prototype, KEY)) try {\n delete TypedArrayConstructor.prototype[KEY];\n } catch (error) {\n // old WebKit bug - some methods are non-configurable\n try {\n TypedArrayConstructor.prototype[KEY] = property;\n } catch (error2) { /* empty */ }\n }\n }\n if (!TypedArrayPrototype[KEY] || forced) {\n defineBuiltIn(TypedArrayPrototype, KEY, forced ? property\n : NATIVE_ARRAY_BUFFER_VIEWS && Int8ArrayPrototype[KEY] || property, options);\n }\n};\n\nvar exportTypedArrayStaticMethod = function (KEY, property, forced) {\n var ARRAY, TypedArrayConstructor;\n if (!DESCRIPTORS) return;\n if (setPrototypeOf) {\n if (forced) for (ARRAY in TypedArrayConstructorsList) {\n TypedArrayConstructor = global[ARRAY];\n if (TypedArrayConstructor && hasOwn(TypedArrayConstructor, KEY)) try {\n delete TypedArrayConstructor[KEY];\n } catch (error) { /* empty */ }\n }\n if (!TypedArray[KEY] || forced) {\n // V8 ~ Chrome 49-50 `%TypedArray%` methods are non-writable non-configurable\n try {\n return defineBuiltIn(TypedArray, KEY, forced ? property : NATIVE_ARRAY_BUFFER_VIEWS && TypedArray[KEY] || property);\n } catch (error) { /* empty */ }\n } else return;\n }\n for (ARRAY in TypedArrayConstructorsList) {\n TypedArrayConstructor = global[ARRAY];\n if (TypedArrayConstructor && (!TypedArrayConstructor[KEY] || forced)) {\n defineBuiltIn(TypedArrayConstructor, KEY, property);\n }\n }\n};\n\nfor (NAME in TypedArrayConstructorsList) {\n Constructor = global[NAME];\n Prototype = Constructor && Constructor.prototype;\n if (Prototype) enforceInternalState(Prototype)[TYPED_ARRAY_CONSTRUCTOR] = Constructor;\n else NATIVE_ARRAY_BUFFER_VIEWS = false;\n}\n\nfor (NAME in BigIntArrayConstructorsList) {\n Constructor = global[NAME];\n Prototype = Constructor && Constructor.prototype;\n if (Prototype) enforceInternalState(Prototype)[TYPED_ARRAY_CONSTRUCTOR] = Constructor;\n}\n\n// WebKit bug - typed arrays constructors prototype is Object.prototype\nif (!NATIVE_ARRAY_BUFFER_VIEWS || !isCallable(TypedArray) || TypedArray === Function.prototype) {\n // eslint-disable-next-line no-shadow -- safe\n TypedArray = function TypedArray() {\n throw new TypeError('Incorrect invocation');\n };\n if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) {\n if (global[NAME]) setPrototypeOf(global[NAME], TypedArray);\n }\n}\n\nif (!NATIVE_ARRAY_BUFFER_VIEWS || !TypedArrayPrototype || TypedArrayPrototype === ObjectPrototype) {\n TypedArrayPrototype = TypedArray.prototype;\n if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) {\n if (global[NAME]) setPrototypeOf(global[NAME].prototype, TypedArrayPrototype);\n }\n}\n\n// WebKit bug - one more object in Uint8ClampedArray prototype chain\nif (NATIVE_ARRAY_BUFFER_VIEWS && getPrototypeOf(Uint8ClampedArrayPrototype) !== TypedArrayPrototype) {\n setPrototypeOf(Uint8ClampedArrayPrototype, TypedArrayPrototype);\n}\n\nif (DESCRIPTORS && !hasOwn(TypedArrayPrototype, TO_STRING_TAG)) {\n TYPED_ARRAY_TAG_REQUIRED = true;\n defineBuiltInAccessor(TypedArrayPrototype, TO_STRING_TAG, {\n configurable: true,\n get: function () {\n return isObject(this) ? this[TYPED_ARRAY_TAG] : undefined;\n }\n });\n for (NAME in TypedArrayConstructorsList) if (global[NAME]) {\n createNonEnumerableProperty(global[NAME], TYPED_ARRAY_TAG, NAME);\n }\n}\n\nmodule.exports = {\n NATIVE_ARRAY_BUFFER_VIEWS: NATIVE_ARRAY_BUFFER_VIEWS,\n TYPED_ARRAY_TAG: TYPED_ARRAY_TAG_REQUIRED && TYPED_ARRAY_TAG,\n aTypedArray: aTypedArray,\n aTypedArrayConstructor: aTypedArrayConstructor,\n exportTypedArrayMethod: exportTypedArrayMethod,\n exportTypedArrayStaticMethod: exportTypedArrayStaticMethod,\n getTypedArrayConstructor: getTypedArrayConstructor,\n isView: isView,\n isTypedArray: isTypedArray,\n TypedArray: TypedArray,\n TypedArrayPrototype: TypedArrayPrototype\n};\n","'use strict';\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\nmodule.exports = function (Constructor, list, $length) {\n var index = 0;\n var length = arguments.length > 2 ? $length : lengthOfArrayLike(list);\n var result = new Constructor(length);\n while (length > index) result[index] = list[index++];\n return result;\n};\n","'use strict';\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\n// `Array.prototype.{ indexOf, includes }` methods implementation\nvar createMethod = function (IS_INCLUDES) {\n return function ($this, el, fromIndex) {\n var O = toIndexedObject($this);\n var length = lengthOfArrayLike(O);\n if (length === 0) return !IS_INCLUDES && -1;\n var index = toAbsoluteIndex(fromIndex, length);\n var value;\n // Array#includes uses SameValueZero equality algorithm\n // eslint-disable-next-line no-self-compare -- NaN check\n if (IS_INCLUDES && el !== el) while (length > index) {\n value = O[index++];\n // eslint-disable-next-line no-self-compare -- NaN check\n if (value !== value) return true;\n // Array#indexOf ignores holes, Array#includes - not\n } else for (;length > index; index++) {\n if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.includes` method\n // https://tc39.es/ecma262/#sec-array.prototype.includes\n includes: createMethod(true),\n // `Array.prototype.indexOf` method\n // https://tc39.es/ecma262/#sec-array.prototype.indexof\n indexOf: createMethod(false)\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar isArray = require('../internals/is-array');\n\nvar $TypeError = TypeError;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// Safari < 13 does not throw an error in this case\nvar SILENT_ON_NON_WRITABLE_LENGTH_SET = DESCRIPTORS && !function () {\n // makes no sense without proper strict mode support\n if (this !== undefined) return true;\n try {\n // eslint-disable-next-line es/no-object-defineproperty -- safe\n Object.defineProperty([], 'length', { writable: false }).length = 1;\n } catch (error) {\n return error instanceof TypeError;\n }\n}();\n\nmodule.exports = SILENT_ON_NON_WRITABLE_LENGTH_SET ? function (O, length) {\n if (isArray(O) && !getOwnPropertyDescriptor(O, 'length').writable) {\n throw new $TypeError('Cannot set read only .length');\n } return O.length = length;\n} : function (O, length) {\n return O.length = length;\n};\n","'use strict';\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\n// https://tc39.es/proposal-change-array-by-copy/#sec-array.prototype.toReversed\n// https://tc39.es/proposal-change-array-by-copy/#sec-%typedarray%.prototype.toReversed\nmodule.exports = function (O, C) {\n var len = lengthOfArrayLike(O);\n var A = new C(len);\n var k = 0;\n for (; k < len; k++) A[k] = O[len - k - 1];\n return A;\n};\n","'use strict';\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar $RangeError = RangeError;\n\n// https://tc39.es/proposal-change-array-by-copy/#sec-array.prototype.with\n// https://tc39.es/proposal-change-array-by-copy/#sec-%typedarray%.prototype.with\nmodule.exports = function (O, C, index, value) {\n var len = lengthOfArrayLike(O);\n var relativeIndex = toIntegerOrInfinity(index);\n var actualIndex = relativeIndex < 0 ? len + relativeIndex : relativeIndex;\n if (actualIndex >= len || actualIndex < 0) throw new $RangeError('Incorrect index');\n var A = new C(len);\n var k = 0;\n for (; k < len; k++) A[k] = k === actualIndex ? value : O[k];\n return A;\n};\n","'use strict';\nvar anObject = require('../internals/an-object');\nvar iteratorClose = require('../internals/iterator-close');\n\n// call something on iterator step with safe closing on error\nmodule.exports = function (iterator, fn, value, ENTRIES) {\n try {\n return ENTRIES ? fn(anObject(value)[0], value[1]) : fn(value);\n } catch (error) {\n iteratorClose(iterator, 'throw', error);\n }\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar toString = uncurryThis({}.toString);\nvar stringSlice = uncurryThis(''.slice);\n\nmodule.exports = function (it) {\n return stringSlice(toString(it), 8, -1);\n};\n","'use strict';\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar isCallable = require('../internals/is-callable');\nvar classofRaw = require('../internals/classof-raw');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar $Object = Object;\n\n// ES3 wrong here\nvar CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function (it, key) {\n try {\n return it[key];\n } catch (error) { /* empty */ }\n};\n\n// getting tag from ES6+ `Object.prototype.toString`\nmodule.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {\n var O, tag, result;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag\n // builtinTag case\n : CORRECT_ARGUMENTS ? classofRaw(O)\n // ES3 arguments fallback\n : (result = classofRaw(O)) === 'Object' && isCallable(O.callee) ? 'Arguments' : result;\n};\n","'use strict';\nvar hasOwn = require('../internals/has-own-property');\nvar ownKeys = require('../internals/own-keys');\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\nvar definePropertyModule = require('../internals/object-define-property');\n\nmodule.exports = function (target, source, exceptions) {\n var keys = ownKeys(source);\n var defineProperty = definePropertyModule.f;\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) {\n defineProperty(target, key, getOwnPropertyDescriptor(source, key));\n }\n }\n};\n","'use strict';\nvar fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n function F() { /* empty */ }\n F.prototype.constructor = null;\n // eslint-disable-next-line es/no-object-getprototypeof -- required for testing\n return Object.getPrototypeOf(new F()) !== F.prototype;\n});\n","'use strict';\n// `CreateIterResultObject` abstract operation\n// https://tc39.es/ecma262/#sec-createiterresultobject\nmodule.exports = function (value, done) {\n return { value: value, done: done };\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = DESCRIPTORS ? function (object, key, value) {\n return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));\n} : function (object, key, value) {\n object[key] = value;\n return object;\n};\n","'use strict';\nmodule.exports = function (bitmap, value) {\n return {\n enumerable: !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable: !(bitmap & 4),\n value: value\n };\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = function (object, key, value) {\n if (DESCRIPTORS) definePropertyModule.f(object, key, createPropertyDescriptor(0, value));\n else object[key] = value;\n};\n","'use strict';\nvar makeBuiltIn = require('../internals/make-built-in');\nvar defineProperty = require('../internals/object-define-property');\n\nmodule.exports = function (target, name, descriptor) {\n if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });\n if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });\n return defineProperty.f(target, name, descriptor);\n};\n","'use strict';\nvar isCallable = require('../internals/is-callable');\nvar definePropertyModule = require('../internals/object-define-property');\nvar makeBuiltIn = require('../internals/make-built-in');\nvar defineGlobalProperty = require('../internals/define-global-property');\n\nmodule.exports = function (O, key, value, options) {\n if (!options) options = {};\n var simple = options.enumerable;\n var name = options.name !== undefined ? options.name : key;\n if (isCallable(value)) makeBuiltIn(value, name, options);\n if (options.global) {\n if (simple) O[key] = value;\n else defineGlobalProperty(key, value);\n } else {\n try {\n if (!options.unsafe) delete O[key];\n else if (O[key]) simple = true;\n } catch (error) { /* empty */ }\n if (simple) O[key] = value;\n else definePropertyModule.f(O, key, {\n value: value,\n enumerable: false,\n configurable: !options.nonConfigurable,\n writable: !options.nonWritable\n });\n } return O;\n};\n","'use strict';\nvar defineBuiltIn = require('../internals/define-built-in');\n\nmodule.exports = function (target, src, options) {\n for (var key in src) defineBuiltIn(target, key, src[key], options);\n return target;\n};\n","'use strict';\nvar global = require('../internals/global');\n\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar defineProperty = Object.defineProperty;\n\nmodule.exports = function (key, value) {\n try {\n defineProperty(global, key, { value: value, configurable: true, writable: true });\n } catch (error) {\n global[key] = value;\n } return value;\n};\n","'use strict';\nvar fails = require('../internals/fails');\n\n// Detect IE8's incomplete defineProperty implementation\nmodule.exports = !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;\n});\n","'use strict';\nvar global = require('../internals/global');\nvar tryNodeRequire = require('../internals/try-node-require');\nvar PROPER_STRUCTURED_CLONE_TRANSFER = require('../internals/structured-clone-proper-transfer');\n\nvar structuredClone = global.structuredClone;\nvar $ArrayBuffer = global.ArrayBuffer;\nvar $MessageChannel = global.MessageChannel;\nvar detach = false;\nvar WorkerThreads, channel, buffer, $detach;\n\nif (PROPER_STRUCTURED_CLONE_TRANSFER) {\n detach = function (transferable) {\n structuredClone(transferable, { transfer: [transferable] });\n };\n} else if ($ArrayBuffer) try {\n if (!$MessageChannel) {\n WorkerThreads = tryNodeRequire('worker_threads');\n if (WorkerThreads) $MessageChannel = WorkerThreads.MessageChannel;\n }\n\n if ($MessageChannel) {\n channel = new $MessageChannel();\n buffer = new $ArrayBuffer(2);\n\n $detach = function (transferable) {\n channel.port1.postMessage(null, [transferable]);\n };\n\n if (buffer.byteLength === 2) {\n $detach(buffer);\n if (buffer.byteLength === 0) detach = $detach;\n }\n }\n} catch (error) { /* empty */ }\n\nmodule.exports = detach;\n","'use strict';\nvar global = require('../internals/global');\nvar isObject = require('../internals/is-object');\n\nvar document = global.document;\n// typeof document.createElement is 'object' in old IE\nvar EXISTS = isObject(document) && isObject(document.createElement);\n\nmodule.exports = function (it) {\n return EXISTS ? document.createElement(it) : {};\n};\n","'use strict';\nvar $TypeError = TypeError;\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991\n\nmodule.exports = function (it) {\n if (it > MAX_SAFE_INTEGER) throw $TypeError('Maximum allowed index exceeded');\n return it;\n};\n","'use strict';\nmodule.exports = {\n IndexSizeError: { s: 'INDEX_SIZE_ERR', c: 1, m: 1 },\n DOMStringSizeError: { s: 'DOMSTRING_SIZE_ERR', c: 2, m: 0 },\n HierarchyRequestError: { s: 'HIERARCHY_REQUEST_ERR', c: 3, m: 1 },\n WrongDocumentError: { s: 'WRONG_DOCUMENT_ERR', c: 4, m: 1 },\n InvalidCharacterError: { s: 'INVALID_CHARACTER_ERR', c: 5, m: 1 },\n NoDataAllowedError: { s: 'NO_DATA_ALLOWED_ERR', c: 6, m: 0 },\n NoModificationAllowedError: { s: 'NO_MODIFICATION_ALLOWED_ERR', c: 7, m: 1 },\n NotFoundError: { s: 'NOT_FOUND_ERR', c: 8, m: 1 },\n NotSupportedError: { s: 'NOT_SUPPORTED_ERR', c: 9, m: 1 },\n InUseAttributeError: { s: 'INUSE_ATTRIBUTE_ERR', c: 10, m: 1 },\n InvalidStateError: { s: 'INVALID_STATE_ERR', c: 11, m: 1 },\n SyntaxError: { s: 'SYNTAX_ERR', c: 12, m: 1 },\n InvalidModificationError: { s: 'INVALID_MODIFICATION_ERR', c: 13, m: 1 },\n NamespaceError: { s: 'NAMESPACE_ERR', c: 14, m: 1 },\n InvalidAccessError: { s: 'INVALID_ACCESS_ERR', c: 15, m: 1 },\n ValidationError: { s: 'VALIDATION_ERR', c: 16, m: 0 },\n TypeMismatchError: { s: 'TYPE_MISMATCH_ERR', c: 17, m: 1 },\n SecurityError: { s: 'SECURITY_ERR', c: 18, m: 1 },\n NetworkError: { s: 'NETWORK_ERR', c: 19, m: 1 },\n AbortError: { s: 'ABORT_ERR', c: 20, m: 1 },\n URLMismatchError: { s: 'URL_MISMATCH_ERR', c: 21, m: 1 },\n QuotaExceededError: { s: 'QUOTA_EXCEEDED_ERR', c: 22, m: 1 },\n TimeoutError: { s: 'TIMEOUT_ERR', c: 23, m: 1 },\n InvalidNodeTypeError: { s: 'INVALID_NODE_TYPE_ERR', c: 24, m: 1 },\n DataCloneError: { s: 'DATA_CLONE_ERR', c: 25, m: 1 }\n};\n","'use strict';\nvar IS_DENO = require('../internals/engine-is-deno');\nvar IS_NODE = require('../internals/engine-is-node');\n\nmodule.exports = !IS_DENO && !IS_NODE\n && typeof window == 'object'\n && typeof document == 'object';\n","'use strict';\n/* global Deno -- Deno case */\nmodule.exports = typeof Deno == 'object' && Deno && typeof Deno.version == 'object';\n","'use strict';\nvar global = require('../internals/global');\nvar classof = require('../internals/classof-raw');\n\nmodule.exports = classof(global.process) === 'process';\n","'use strict';\nmodule.exports = typeof navigator != 'undefined' && String(navigator.userAgent) || '';\n","'use strict';\nvar global = require('../internals/global');\nvar userAgent = require('../internals/engine-user-agent');\n\nvar process = global.process;\nvar Deno = global.Deno;\nvar versions = process && process.versions || Deno && Deno.version;\nvar v8 = versions && versions.v8;\nvar match, version;\n\nif (v8) {\n match = v8.split('.');\n // in old Chrome, versions of V8 isn't V8 = Chrome / 10\n // but their correct versions are not interesting for us\n version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);\n}\n\n// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`\n// so check `userAgent` even if `.v8` exists, but 0\nif (!version && userAgent) {\n match = userAgent.match(/Edge\\/(\\d+)/);\n if (!match || match[1] >= 74) {\n match = userAgent.match(/Chrome\\/(\\d+)/);\n if (match) version = +match[1];\n }\n}\n\nmodule.exports = version;\n","'use strict';\n// IE8- don't enum bug keys\nmodule.exports = [\n 'constructor',\n 'hasOwnProperty',\n 'isPrototypeOf',\n 'propertyIsEnumerable',\n 'toLocaleString',\n 'toString',\n 'valueOf'\n];\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar $Error = Error;\nvar replace = uncurryThis(''.replace);\n\nvar TEST = (function (arg) { return String(new $Error(arg).stack); })('zxcasd');\n// eslint-disable-next-line redos/no-vulnerable -- safe\nvar V8_OR_CHAKRA_STACK_ENTRY = /\\n\\s*at [^:]*:[^\\n]*/;\nvar IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST);\n\nmodule.exports = function (stack, dropEntries) {\n if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string' && !$Error.prepareStackTrace) {\n while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, '');\n } return stack;\n};\n","'use strict';\nvar global = require('../internals/global');\nvar getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar defineBuiltIn = require('../internals/define-built-in');\nvar defineGlobalProperty = require('../internals/define-global-property');\nvar copyConstructorProperties = require('../internals/copy-constructor-properties');\nvar isForced = require('../internals/is-forced');\n\n/*\n options.target - name of the target object\n options.global - target is the global object\n options.stat - export as static methods of target\n options.proto - export as prototype methods of target\n options.real - real prototype method for the `pure` version\n options.forced - export even if the native feature is available\n options.bind - bind methods to the target, required for the `pure` version\n options.wrap - wrap constructors to preventing global pollution, required for the `pure` version\n options.unsafe - use the simple assignment of property instead of delete + defineProperty\n options.sham - add a flag to not completely full polyfills\n options.enumerable - export as enumerable property\n options.dontCallGetSet - prevent calling a getter on target\n options.name - the .name of the function if it does not match the key\n*/\nmodule.exports = function (options, source) {\n var TARGET = options.target;\n var GLOBAL = options.global;\n var STATIC = options.stat;\n var FORCED, target, key, targetProperty, sourceProperty, descriptor;\n if (GLOBAL) {\n target = global;\n } else if (STATIC) {\n target = global[TARGET] || defineGlobalProperty(TARGET, {});\n } else {\n target = global[TARGET] && global[TARGET].prototype;\n }\n if (target) for (key in source) {\n sourceProperty = source[key];\n if (options.dontCallGetSet) {\n descriptor = getOwnPropertyDescriptor(target, key);\n targetProperty = descriptor && descriptor.value;\n } else targetProperty = target[key];\n FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);\n // contained in target\n if (!FORCED && targetProperty !== undefined) {\n if (typeof sourceProperty == typeof targetProperty) continue;\n copyConstructorProperties(sourceProperty, targetProperty);\n }\n // add a flag to not completely full polyfills\n if (options.sham || (targetProperty && targetProperty.sham)) {\n createNonEnumerableProperty(sourceProperty, 'sham', true);\n }\n defineBuiltIn(target, key, sourceProperty, options);\n }\n};\n","'use strict';\nmodule.exports = function (exec) {\n try {\n return !!exec();\n } catch (error) {\n return true;\n }\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this-clause');\nvar aCallable = require('../internals/a-callable');\nvar NATIVE_BIND = require('../internals/function-bind-native');\n\nvar bind = uncurryThis(uncurryThis.bind);\n\n// optional / simple context binding\nmodule.exports = function (fn, that) {\n aCallable(fn);\n return that === undefined ? fn : NATIVE_BIND ? bind(fn, that) : function (/* ...args */) {\n return fn.apply(that, arguments);\n };\n};\n","'use strict';\nvar fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n // eslint-disable-next-line es/no-function-prototype-bind -- safe\n var test = (function () { /* empty */ }).bind();\n // eslint-disable-next-line no-prototype-builtins -- safe\n return typeof test != 'function' || test.hasOwnProperty('prototype');\n});\n","'use strict';\nvar NATIVE_BIND = require('../internals/function-bind-native');\n\nvar call = Function.prototype.call;\n\nmodule.exports = NATIVE_BIND ? call.bind(call) : function () {\n return call.apply(call, arguments);\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar hasOwn = require('../internals/has-own-property');\n\nvar FunctionPrototype = Function.prototype;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;\n\nvar EXISTS = hasOwn(FunctionPrototype, 'name');\n// additional protection from minified / mangled / dropped function names\nvar PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';\nvar CONFIGURABLE = EXISTS && (!DESCRIPTORS || (DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable));\n\nmodule.exports = {\n EXISTS: EXISTS,\n PROPER: PROPER,\n CONFIGURABLE: CONFIGURABLE\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar aCallable = require('../internals/a-callable');\n\nmodule.exports = function (object, key, method) {\n try {\n // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\n return uncurryThis(aCallable(Object.getOwnPropertyDescriptor(object, key)[method]));\n } catch (error) { /* empty */ }\n};\n","'use strict';\nvar classofRaw = require('../internals/classof-raw');\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = function (fn) {\n // Nashorn bug:\n // https://github.com/zloirock/core-js/issues/1128\n // https://github.com/zloirock/core-js/issues/1130\n if (classofRaw(fn) === 'Function') return uncurryThis(fn);\n};\n","'use strict';\nvar NATIVE_BIND = require('../internals/function-bind-native');\n\nvar FunctionPrototype = Function.prototype;\nvar call = FunctionPrototype.call;\nvar uncurryThisWithBind = NATIVE_BIND && FunctionPrototype.bind.bind(call, call);\n\nmodule.exports = NATIVE_BIND ? uncurryThisWithBind : function (fn) {\n return function () {\n return call.apply(fn, arguments);\n };\n};\n","'use strict';\nvar global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar aFunction = function (argument) {\n return isCallable(argument) ? argument : undefined;\n};\n\nmodule.exports = function (namespace, method) {\n return arguments.length < 2 ? aFunction(global[namespace]) : global[namespace] && global[namespace][method];\n};\n","'use strict';\n// `GetIteratorDirect(obj)` abstract operation\n// https://tc39.es/proposal-iterator-helpers/#sec-getiteratordirect\nmodule.exports = function (obj) {\n return {\n iterator: obj,\n next: obj.next,\n done: false\n };\n};\n","'use strict';\nvar call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar getIteratorDirect = require('../internals/get-iterator-direct');\nvar getIteratorMethod = require('../internals/get-iterator-method');\n\nmodule.exports = function (obj, stringHandling) {\n if (!stringHandling || typeof obj !== 'string') anObject(obj);\n var method = getIteratorMethod(obj);\n return getIteratorDirect(anObject(method !== undefined ? call(method, obj) : obj));\n};\n","'use strict';\nvar classof = require('../internals/classof');\nvar getMethod = require('../internals/get-method');\nvar isNullOrUndefined = require('../internals/is-null-or-undefined');\nvar Iterators = require('../internals/iterators');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\n\nmodule.exports = function (it) {\n if (!isNullOrUndefined(it)) return getMethod(it, ITERATOR)\n || getMethod(it, '@@iterator')\n || Iterators[classof(it)];\n};\n","'use strict';\nvar call = require('../internals/function-call');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar tryToString = require('../internals/try-to-string');\nvar getIteratorMethod = require('../internals/get-iterator-method');\n\nvar $TypeError = TypeError;\n\nmodule.exports = function (argument, usingIterator) {\n var iteratorMethod = arguments.length < 2 ? getIteratorMethod(argument) : usingIterator;\n if (aCallable(iteratorMethod)) return anObject(call(iteratorMethod, argument));\n throw new $TypeError(tryToString(argument) + ' is not iterable');\n};\n","'use strict';\nvar aCallable = require('../internals/a-callable');\nvar isNullOrUndefined = require('../internals/is-null-or-undefined');\n\n// `GetMethod` abstract operation\n// https://tc39.es/ecma262/#sec-getmethod\nmodule.exports = function (V, P) {\n var func = V[P];\n return isNullOrUndefined(func) ? undefined : aCallable(func);\n};\n","'use strict';\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar call = require('../internals/function-call');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar getIteratorDirect = require('../internals/get-iterator-direct');\n\nvar INVALID_SIZE = 'Invalid size';\nvar $RangeError = RangeError;\nvar $TypeError = TypeError;\nvar max = Math.max;\n\nvar SetRecord = function (set, intSize) {\n this.set = set;\n this.size = max(intSize, 0);\n this.has = aCallable(set.has);\n this.keys = aCallable(set.keys);\n};\n\nSetRecord.prototype = {\n getIterator: function () {\n return getIteratorDirect(anObject(call(this.keys, this.set)));\n },\n includes: function (it) {\n return call(this.has, this.set, it);\n }\n};\n\n// `GetSetRecord` abstract operation\n// https://tc39.es/proposal-set-methods/#sec-getsetrecord\nmodule.exports = function (obj) {\n anObject(obj);\n var numSize = +obj.size;\n // NOTE: If size is undefined, then numSize will be NaN\n // eslint-disable-next-line no-self-compare -- NaN check\n if (numSize !== numSize) throw new $TypeError(INVALID_SIZE);\n var intSize = toIntegerOrInfinity(numSize);\n if (intSize < 0) throw new $RangeError(INVALID_SIZE);\n return new SetRecord(obj, intSize);\n};\n","'use strict';\nvar check = function (it) {\n return it && it.Math === Math && it;\n};\n\n// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nmodule.exports =\n // eslint-disable-next-line es/no-global-this -- safe\n check(typeof globalThis == 'object' && globalThis) ||\n check(typeof window == 'object' && window) ||\n // eslint-disable-next-line no-restricted-globals -- safe\n check(typeof self == 'object' && self) ||\n check(typeof global == 'object' && global) ||\n check(typeof this == 'object' && this) ||\n // eslint-disable-next-line no-new-func -- fallback\n (function () { return this; })() || Function('return this')();\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toObject = require('../internals/to-object');\n\nvar hasOwnProperty = uncurryThis({}.hasOwnProperty);\n\n// `HasOwnProperty` abstract operation\n// https://tc39.es/ecma262/#sec-hasownproperty\n// eslint-disable-next-line es/no-object-hasown -- safe\nmodule.exports = Object.hasOwn || function hasOwn(it, key) {\n return hasOwnProperty(toObject(it), key);\n};\n","'use strict';\nmodule.exports = {};\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\n\nmodule.exports = getBuiltIn('document', 'documentElement');\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\nvar createElement = require('../internals/document-create-element');\n\n// Thanks to IE8 for its funny defineProperty\nmodule.exports = !DESCRIPTORS && !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(createElement('div'), 'a', {\n get: function () { return 7; }\n }).a !== 7;\n});\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar classof = require('../internals/classof-raw');\n\nvar $Object = Object;\nvar split = uncurryThis(''.split);\n\n// fallback for non-array-like ES3 and non-enumerable old V8 strings\nmodule.exports = fails(function () {\n // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346\n // eslint-disable-next-line no-prototype-builtins -- safe\n return !$Object('z').propertyIsEnumerable(0);\n}) ? function (it) {\n return classof(it) === 'String' ? split(it, '') : $Object(it);\n} : $Object;\n","'use strict';\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\n\n// makes subclassing work correct for wrapped built-ins\nmodule.exports = function ($this, dummy, Wrapper) {\n var NewTarget, NewTargetPrototype;\n if (\n // it can work only with native `setPrototypeOf`\n setPrototypeOf &&\n // we haven't completely correct pre-ES6 way for getting `new.target`, so use this\n isCallable(NewTarget = dummy.constructor) &&\n NewTarget !== Wrapper &&\n isObject(NewTargetPrototype = NewTarget.prototype) &&\n NewTargetPrototype !== Wrapper.prototype\n ) setPrototypeOf($this, NewTargetPrototype);\n return $this;\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isCallable = require('../internals/is-callable');\nvar store = require('../internals/shared-store');\n\nvar functionToString = uncurryThis(Function.toString);\n\n// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper\nif (!isCallable(store.inspectSource)) {\n store.inspectSource = function (it) {\n return functionToString(it);\n };\n}\n\nmodule.exports = store.inspectSource;\n","'use strict';\nvar NATIVE_WEAK_MAP = require('../internals/weak-map-basic-detection');\nvar global = require('../internals/global');\nvar isObject = require('../internals/is-object');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar hasOwn = require('../internals/has-own-property');\nvar shared = require('../internals/shared-store');\nvar sharedKey = require('../internals/shared-key');\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar OBJECT_ALREADY_INITIALIZED = 'Object already initialized';\nvar TypeError = global.TypeError;\nvar WeakMap = global.WeakMap;\nvar set, get, has;\n\nvar enforce = function (it) {\n return has(it) ? get(it) : set(it, {});\n};\n\nvar getterFor = function (TYPE) {\n return function (it) {\n var state;\n if (!isObject(it) || (state = get(it)).type !== TYPE) {\n throw new TypeError('Incompatible receiver, ' + TYPE + ' required');\n } return state;\n };\n};\n\nif (NATIVE_WEAK_MAP || shared.state) {\n var store = shared.state || (shared.state = new WeakMap());\n /* eslint-disable no-self-assign -- prototype methods protection */\n store.get = store.get;\n store.has = store.has;\n store.set = store.set;\n /* eslint-enable no-self-assign -- prototype methods protection */\n set = function (it, metadata) {\n if (store.has(it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n store.set(it, metadata);\n return metadata;\n };\n get = function (it) {\n return store.get(it) || {};\n };\n has = function (it) {\n return store.has(it);\n };\n} else {\n var STATE = sharedKey('state');\n hiddenKeys[STATE] = true;\n set = function (it, metadata) {\n if (hasOwn(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n createNonEnumerableProperty(it, STATE, metadata);\n return metadata;\n };\n get = function (it) {\n return hasOwn(it, STATE) ? it[STATE] : {};\n };\n has = function (it) {\n return hasOwn(it, STATE);\n };\n}\n\nmodule.exports = {\n set: set,\n get: get,\n has: has,\n enforce: enforce,\n getterFor: getterFor\n};\n","'use strict';\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar Iterators = require('../internals/iterators');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar ArrayPrototype = Array.prototype;\n\n// check on default Array iterator\nmodule.exports = function (it) {\n return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it);\n};\n","'use strict';\nvar classof = require('../internals/classof-raw');\n\n// `IsArray` abstract operation\n// https://tc39.es/ecma262/#sec-isarray\n// eslint-disable-next-line es/no-array-isarray -- safe\nmodule.exports = Array.isArray || function isArray(argument) {\n return classof(argument) === 'Array';\n};\n","'use strict';\nvar classof = require('../internals/classof');\n\nmodule.exports = function (it) {\n var klass = classof(it);\n return klass === 'BigInt64Array' || klass === 'BigUint64Array';\n};\n","'use strict';\n// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot\nvar documentAll = typeof document == 'object' && document.all;\n\n// `IsCallable` abstract operation\n// https://tc39.es/ecma262/#sec-iscallable\n// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing\nmodule.exports = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {\n return typeof argument == 'function' || argument === documentAll;\n} : function (argument) {\n return typeof argument == 'function';\n};\n","'use strict';\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\n\nvar replacement = /#|\\.prototype\\./;\n\nvar isForced = function (feature, detection) {\n var value = data[normalize(feature)];\n return value === POLYFILL ? true\n : value === NATIVE ? false\n : isCallable(detection) ? fails(detection)\n : !!detection;\n};\n\nvar normalize = isForced.normalize = function (string) {\n return String(string).replace(replacement, '.').toLowerCase();\n};\n\nvar data = isForced.data = {};\nvar NATIVE = isForced.NATIVE = 'N';\nvar POLYFILL = isForced.POLYFILL = 'P';\n\nmodule.exports = isForced;\n","'use strict';\n// we can't use just `it == null` since of `document.all` special case\n// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec\nmodule.exports = function (it) {\n return it === null || it === undefined;\n};\n","'use strict';\nvar isCallable = require('../internals/is-callable');\n\nmodule.exports = function (it) {\n return typeof it == 'object' ? it !== null : isCallable(it);\n};\n","'use strict';\nvar isObject = require('../internals/is-object');\n\nmodule.exports = function (argument) {\n return isObject(argument) || argument === null;\n};\n","'use strict';\nmodule.exports = false;\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar isCallable = require('../internals/is-callable');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar $Object = Object;\n\nmodule.exports = USE_SYMBOL_AS_UID ? function (it) {\n return typeof it == 'symbol';\n} : function (it) {\n var $Symbol = getBuiltIn('Symbol');\n return isCallable($Symbol) && isPrototypeOf($Symbol.prototype, $Object(it));\n};\n","'use strict';\nvar call = require('../internals/function-call');\n\nmodule.exports = function (record, fn, ITERATOR_INSTEAD_OF_RECORD) {\n var iterator = ITERATOR_INSTEAD_OF_RECORD ? record : record.iterator;\n var next = record.next;\n var step, result;\n while (!(step = call(next, iterator)).done) {\n result = fn(step.value);\n if (result !== undefined) return result;\n }\n};\n","'use strict';\nvar bind = require('../internals/function-bind-context');\nvar call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar tryToString = require('../internals/try-to-string');\nvar isArrayIteratorMethod = require('../internals/is-array-iterator-method');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar getIterator = require('../internals/get-iterator');\nvar getIteratorMethod = require('../internals/get-iterator-method');\nvar iteratorClose = require('../internals/iterator-close');\n\nvar $TypeError = TypeError;\n\nvar Result = function (stopped, result) {\n this.stopped = stopped;\n this.result = result;\n};\n\nvar ResultPrototype = Result.prototype;\n\nmodule.exports = function (iterable, unboundFunction, options) {\n var that = options && options.that;\n var AS_ENTRIES = !!(options && options.AS_ENTRIES);\n var IS_RECORD = !!(options && options.IS_RECORD);\n var IS_ITERATOR = !!(options && options.IS_ITERATOR);\n var INTERRUPTED = !!(options && options.INTERRUPTED);\n var fn = bind(unboundFunction, that);\n var iterator, iterFn, index, length, result, next, step;\n\n var stop = function (condition) {\n if (iterator) iteratorClose(iterator, 'normal', condition);\n return new Result(true, condition);\n };\n\n var callFn = function (value) {\n if (AS_ENTRIES) {\n anObject(value);\n return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);\n } return INTERRUPTED ? fn(value, stop) : fn(value);\n };\n\n if (IS_RECORD) {\n iterator = iterable.iterator;\n } else if (IS_ITERATOR) {\n iterator = iterable;\n } else {\n iterFn = getIteratorMethod(iterable);\n if (!iterFn) throw new $TypeError(tryToString(iterable) + ' is not iterable');\n // optimisation for array iterators\n if (isArrayIteratorMethod(iterFn)) {\n for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {\n result = callFn(iterable[index]);\n if (result && isPrototypeOf(ResultPrototype, result)) return result;\n } return new Result(false);\n }\n iterator = getIterator(iterable, iterFn);\n }\n\n next = IS_RECORD ? iterable.next : iterator.next;\n while (!(step = call(next, iterator)).done) {\n try {\n result = callFn(step.value);\n } catch (error) {\n iteratorClose(iterator, 'throw', error);\n }\n if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;\n } return new Result(false);\n};\n","'use strict';\nvar call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar getMethod = require('../internals/get-method');\n\nmodule.exports = function (iterator, kind, value) {\n var innerResult, innerError;\n anObject(iterator);\n try {\n innerResult = getMethod(iterator, 'return');\n if (!innerResult) {\n if (kind === 'throw') throw value;\n return value;\n }\n innerResult = call(innerResult, iterator);\n } catch (error) {\n innerError = true;\n innerResult = error;\n }\n if (kind === 'throw') throw value;\n if (innerError) throw innerResult;\n anObject(innerResult);\n return value;\n};\n","'use strict';\nvar call = require('../internals/function-call');\nvar create = require('../internals/object-create');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar defineBuiltIns = require('../internals/define-built-ins');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar InternalStateModule = require('../internals/internal-state');\nvar getMethod = require('../internals/get-method');\nvar IteratorPrototype = require('../internals/iterators-core').IteratorPrototype;\nvar createIterResultObject = require('../internals/create-iter-result-object');\nvar iteratorClose = require('../internals/iterator-close');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar ITERATOR_HELPER = 'IteratorHelper';\nvar WRAP_FOR_VALID_ITERATOR = 'WrapForValidIterator';\nvar setInternalState = InternalStateModule.set;\n\nvar createIteratorProxyPrototype = function (IS_ITERATOR) {\n var getInternalState = InternalStateModule.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER);\n\n return defineBuiltIns(create(IteratorPrototype), {\n next: function next() {\n var state = getInternalState(this);\n // for simplification:\n // for `%WrapForValidIteratorPrototype%.next` our `nextHandler` returns `IterResultObject`\n // for `%IteratorHelperPrototype%.next` - just a value\n if (IS_ITERATOR) return state.nextHandler();\n try {\n var result = state.done ? undefined : state.nextHandler();\n return createIterResultObject(result, state.done);\n } catch (error) {\n state.done = true;\n throw error;\n }\n },\n 'return': function () {\n var state = getInternalState(this);\n var iterator = state.iterator;\n state.done = true;\n if (IS_ITERATOR) {\n var returnMethod = getMethod(iterator, 'return');\n return returnMethod ? call(returnMethod, iterator) : createIterResultObject(undefined, true);\n }\n if (state.inner) try {\n iteratorClose(state.inner.iterator, 'normal');\n } catch (error) {\n return iteratorClose(iterator, 'throw', error);\n }\n iteratorClose(iterator, 'normal');\n return createIterResultObject(undefined, true);\n }\n });\n};\n\nvar WrapForValidIteratorPrototype = createIteratorProxyPrototype(true);\nvar IteratorHelperPrototype = createIteratorProxyPrototype(false);\n\ncreateNonEnumerableProperty(IteratorHelperPrototype, TO_STRING_TAG, 'Iterator Helper');\n\nmodule.exports = function (nextHandler, IS_ITERATOR) {\n var IteratorProxy = function Iterator(record, state) {\n if (state) {\n state.iterator = record.iterator;\n state.next = record.next;\n } else state = record;\n state.type = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;\n state.nextHandler = nextHandler;\n state.counter = 0;\n state.done = false;\n setInternalState(this, state);\n };\n\n IteratorProxy.prototype = IS_ITERATOR ? WrapForValidIteratorPrototype : IteratorHelperPrototype;\n\n return IteratorProxy;\n};\n","'use strict';\nvar call = require('../internals/function-call');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar getIteratorDirect = require('../internals/get-iterator-direct');\nvar createIteratorProxy = require('../internals/iterator-create-proxy');\nvar callWithSafeIterationClosing = require('../internals/call-with-safe-iteration-closing');\n\nvar IteratorProxy = createIteratorProxy(function () {\n var iterator = this.iterator;\n var result = anObject(call(this.next, iterator));\n var done = this.done = !!result.done;\n if (!done) return callWithSafeIterationClosing(iterator, this.mapper, [result.value, this.counter++], true);\n});\n\n// `Iterator.prototype.map` method\n// https://github.com/tc39/proposal-iterator-helpers\nmodule.exports = function map(mapper) {\n anObject(this);\n aCallable(mapper);\n return new IteratorProxy(getIteratorDirect(this), {\n mapper: mapper\n });\n};\n","'use strict';\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar create = require('../internals/object-create');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar defineBuiltIn = require('../internals/define-built-in');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar IS_PURE = require('../internals/is-pure');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar BUGGY_SAFARI_ITERATORS = false;\n\n// `%IteratorPrototype%` object\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-object\nvar IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;\n\n/* eslint-disable es/no-array-prototype-keys -- safe */\nif ([].keys) {\n arrayIterator = [].keys();\n // Safari 8 has buggy iterators w/o `next`\n if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;\n else {\n PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));\n if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;\n }\n}\n\nvar NEW_ITERATOR_PROTOTYPE = !isObject(IteratorPrototype) || fails(function () {\n var test = {};\n // FF44- legacy iterators case\n return IteratorPrototype[ITERATOR].call(test) !== test;\n});\n\nif (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {};\nelse if (IS_PURE) IteratorPrototype = create(IteratorPrototype);\n\n// `%IteratorPrototype%[@@iterator]()` method\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator\nif (!isCallable(IteratorPrototype[ITERATOR])) {\n defineBuiltIn(IteratorPrototype, ITERATOR, function () {\n return this;\n });\n}\n\nmodule.exports = {\n IteratorPrototype: IteratorPrototype,\n BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS\n};\n","'use strict';\nmodule.exports = {};\n","'use strict';\nvar toLength = require('../internals/to-length');\n\n// `LengthOfArrayLike` abstract operation\n// https://tc39.es/ecma262/#sec-lengthofarraylike\nmodule.exports = function (obj) {\n return toLength(obj.length);\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar hasOwn = require('../internals/has-own-property');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar CONFIGURABLE_FUNCTION_NAME = require('../internals/function-name').CONFIGURABLE;\nvar inspectSource = require('../internals/inspect-source');\nvar InternalStateModule = require('../internals/internal-state');\n\nvar enforceInternalState = InternalStateModule.enforce;\nvar getInternalState = InternalStateModule.get;\nvar $String = String;\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar defineProperty = Object.defineProperty;\nvar stringSlice = uncurryThis(''.slice);\nvar replace = uncurryThis(''.replace);\nvar join = uncurryThis([].join);\n\nvar CONFIGURABLE_LENGTH = DESCRIPTORS && !fails(function () {\n return defineProperty(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;\n});\n\nvar TEMPLATE = String(String).split('String');\n\nvar makeBuiltIn = module.exports = function (value, name, options) {\n if (stringSlice($String(name), 0, 7) === 'Symbol(') {\n name = '[' + replace($String(name), /^Symbol\\(([^)]*)\\).*$/, '$1') + ']';\n }\n if (options && options.getter) name = 'get ' + name;\n if (options && options.setter) name = 'set ' + name;\n if (!hasOwn(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {\n if (DESCRIPTORS) defineProperty(value, 'name', { value: name, configurable: true });\n else value.name = name;\n }\n if (CONFIGURABLE_LENGTH && options && hasOwn(options, 'arity') && value.length !== options.arity) {\n defineProperty(value, 'length', { value: options.arity });\n }\n try {\n if (options && hasOwn(options, 'constructor') && options.constructor) {\n if (DESCRIPTORS) defineProperty(value, 'prototype', { writable: false });\n // in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable\n } else if (value.prototype) value.prototype = undefined;\n } catch (error) { /* empty */ }\n var state = enforceInternalState(value);\n if (!hasOwn(state, 'source')) {\n state.source = join(TEMPLATE, typeof name == 'string' ? name : '');\n } return value;\n};\n\n// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative\n// eslint-disable-next-line no-extend-native -- required\nFunction.prototype.toString = makeBuiltIn(function toString() {\n return isCallable(this) && getInternalState(this).source || inspectSource(this);\n}, 'toString');\n","'use strict';\nvar ceil = Math.ceil;\nvar floor = Math.floor;\n\n// `Math.trunc` method\n// https://tc39.es/ecma262/#sec-math.trunc\n// eslint-disable-next-line es/no-math-trunc -- safe\nmodule.exports = Math.trunc || function trunc(x) {\n var n = +x;\n return (n > 0 ? floor : ceil)(n);\n};\n","'use strict';\nvar aCallable = require('../internals/a-callable');\n\nvar $TypeError = TypeError;\n\nvar PromiseCapability = function (C) {\n var resolve, reject;\n this.promise = new C(function ($$resolve, $$reject) {\n if (resolve !== undefined || reject !== undefined) throw new $TypeError('Bad Promise constructor');\n resolve = $$resolve;\n reject = $$reject;\n });\n this.resolve = aCallable(resolve);\n this.reject = aCallable(reject);\n};\n\n// `NewPromiseCapability` abstract operation\n// https://tc39.es/ecma262/#sec-newpromisecapability\nmodule.exports.f = function (C) {\n return new PromiseCapability(C);\n};\n","'use strict';\nvar toString = require('../internals/to-string');\n\nmodule.exports = function (argument, $default) {\n return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument);\n};\n","'use strict';\nvar $RangeError = RangeError;\n\nmodule.exports = function (it) {\n // eslint-disable-next-line no-self-compare -- NaN check\n if (it === it) return it;\n throw new $RangeError('NaN is not allowed');\n};\n","'use strict';\n/* global ActiveXObject -- old IE, WSH */\nvar anObject = require('../internals/an-object');\nvar definePropertiesModule = require('../internals/object-define-properties');\nvar enumBugKeys = require('../internals/enum-bug-keys');\nvar hiddenKeys = require('../internals/hidden-keys');\nvar html = require('../internals/html');\nvar documentCreateElement = require('../internals/document-create-element');\nvar sharedKey = require('../internals/shared-key');\n\nvar GT = '>';\nvar LT = '<';\nvar PROTOTYPE = 'prototype';\nvar SCRIPT = 'script';\nvar IE_PROTO = sharedKey('IE_PROTO');\n\nvar EmptyConstructor = function () { /* empty */ };\n\nvar scriptTag = function (content) {\n return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;\n};\n\n// Create object with fake `null` prototype: use ActiveX Object with cleared prototype\nvar NullProtoObjectViaActiveX = function (activeXDocument) {\n activeXDocument.write(scriptTag(''));\n activeXDocument.close();\n var temp = activeXDocument.parentWindow.Object;\n activeXDocument = null; // avoid memory leak\n return temp;\n};\n\n// Create object with fake `null` prototype: use iframe Object with cleared prototype\nvar NullProtoObjectViaIFrame = function () {\n // Thrash, waste and sodomy: IE GC bug\n var iframe = documentCreateElement('iframe');\n var JS = 'java' + SCRIPT + ':';\n var iframeDocument;\n iframe.style.display = 'none';\n html.appendChild(iframe);\n // https://github.com/zloirock/core-js/issues/475\n iframe.src = String(JS);\n iframeDocument = iframe.contentWindow.document;\n iframeDocument.open();\n iframeDocument.write(scriptTag('document.F=Object'));\n iframeDocument.close();\n return iframeDocument.F;\n};\n\n// Check for document.domain and active x support\n// No need to use active x approach when document.domain is not set\n// see https://github.com/es-shims/es5-shim/issues/150\n// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346\n// avoid IE GC bug\nvar activeXDocument;\nvar NullProtoObject = function () {\n try {\n activeXDocument = new ActiveXObject('htmlfile');\n } catch (error) { /* ignore */ }\n NullProtoObject = typeof document != 'undefined'\n ? document.domain && activeXDocument\n ? NullProtoObjectViaActiveX(activeXDocument) // old IE\n : NullProtoObjectViaIFrame()\n : NullProtoObjectViaActiveX(activeXDocument); // WSH\n var length = enumBugKeys.length;\n while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];\n return NullProtoObject();\n};\n\nhiddenKeys[IE_PROTO] = true;\n\n// `Object.create` method\n// https://tc39.es/ecma262/#sec-object.create\n// eslint-disable-next-line es/no-object-create -- safe\nmodule.exports = Object.create || function create(O, Properties) {\n var result;\n if (O !== null) {\n EmptyConstructor[PROTOTYPE] = anObject(O);\n result = new EmptyConstructor();\n EmptyConstructor[PROTOTYPE] = null;\n // add \"__proto__\" for Object.getPrototypeOf polyfill\n result[IE_PROTO] = O;\n } else result = NullProtoObject();\n return Properties === undefined ? result : definePropertiesModule.f(result, Properties);\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar V8_PROTOTYPE_DEFINE_BUG = require('../internals/v8-prototype-define-bug');\nvar definePropertyModule = require('../internals/object-define-property');\nvar anObject = require('../internals/an-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar objectKeys = require('../internals/object-keys');\n\n// `Object.defineProperties` method\n// https://tc39.es/ecma262/#sec-object.defineproperties\n// eslint-disable-next-line es/no-object-defineproperties -- safe\nexports.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {\n anObject(O);\n var props = toIndexedObject(Properties);\n var keys = objectKeys(Properties);\n var length = keys.length;\n var index = 0;\n var key;\n while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);\n return O;\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\nvar V8_PROTOTYPE_DEFINE_BUG = require('../internals/v8-prototype-define-bug');\nvar anObject = require('../internals/an-object');\nvar toPropertyKey = require('../internals/to-property-key');\n\nvar $TypeError = TypeError;\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar $defineProperty = Object.defineProperty;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\nvar ENUMERABLE = 'enumerable';\nvar CONFIGURABLE = 'configurable';\nvar WRITABLE = 'writable';\n\n// `Object.defineProperty` method\n// https://tc39.es/ecma262/#sec-object.defineproperty\nexports.f = DESCRIPTORS ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {\n var current = $getOwnPropertyDescriptor(O, P);\n if (current && current[WRITABLE]) {\n O[P] = Attributes.value;\n Attributes = {\n configurable: CONFIGURABLE in Attributes ? Attributes[CONFIGURABLE] : current[CONFIGURABLE],\n enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],\n writable: false\n };\n }\n } return $defineProperty(O, P, Attributes);\n} : $defineProperty : function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (IE8_DOM_DEFINE) try {\n return $defineProperty(O, P, Attributes);\n } catch (error) { /* empty */ }\n if ('get' in Attributes || 'set' in Attributes) throw new $TypeError('Accessors not supported');\n if ('value' in Attributes) O[P] = Attributes.value;\n return O;\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar call = require('../internals/function-call');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toPropertyKey = require('../internals/to-property-key');\nvar hasOwn = require('../internals/has-own-property');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\n\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor\nexports.f = DESCRIPTORS ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {\n O = toIndexedObject(O);\n P = toPropertyKey(P);\n if (IE8_DOM_DEFINE) try {\n return $getOwnPropertyDescriptor(O, P);\n } catch (error) { /* empty */ }\n if (hasOwn(O, P)) return createPropertyDescriptor(!call(propertyIsEnumerableModule.f, O, P), O[P]);\n};\n","'use strict';\nvar internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\nvar hiddenKeys = enumBugKeys.concat('length', 'prototype');\n\n// `Object.getOwnPropertyNames` method\n// https://tc39.es/ecma262/#sec-object.getownpropertynames\n// eslint-disable-next-line es/no-object-getownpropertynames -- safe\nexports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {\n return internalObjectKeys(O, hiddenKeys);\n};\n","'use strict';\n// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe\nexports.f = Object.getOwnPropertySymbols;\n","'use strict';\nvar hasOwn = require('../internals/has-own-property');\nvar isCallable = require('../internals/is-callable');\nvar toObject = require('../internals/to-object');\nvar sharedKey = require('../internals/shared-key');\nvar CORRECT_PROTOTYPE_GETTER = require('../internals/correct-prototype-getter');\n\nvar IE_PROTO = sharedKey('IE_PROTO');\nvar $Object = Object;\nvar ObjectPrototype = $Object.prototype;\n\n// `Object.getPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.getprototypeof\n// eslint-disable-next-line es/no-object-getprototypeof -- safe\nmodule.exports = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) {\n var object = toObject(O);\n if (hasOwn(object, IE_PROTO)) return object[IE_PROTO];\n var constructor = object.constructor;\n if (isCallable(constructor) && object instanceof constructor) {\n return constructor.prototype;\n } return object instanceof $Object ? ObjectPrototype : null;\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = uncurryThis({}.isPrototypeOf);\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar hasOwn = require('../internals/has-own-property');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar indexOf = require('../internals/array-includes').indexOf;\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar push = uncurryThis([].push);\n\nmodule.exports = function (object, names) {\n var O = toIndexedObject(object);\n var i = 0;\n var result = [];\n var key;\n for (key in O) !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key);\n // Don't enum bug & hidden keys\n while (names.length > i) if (hasOwn(O, key = names[i++])) {\n ~indexOf(result, key) || push(result, key);\n }\n return result;\n};\n","'use strict';\nvar internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\n// `Object.keys` method\n// https://tc39.es/ecma262/#sec-object.keys\n// eslint-disable-next-line es/no-object-keys -- safe\nmodule.exports = Object.keys || function keys(O) {\n return internalObjectKeys(O, enumBugKeys);\n};\n","'use strict';\nvar $propertyIsEnumerable = {}.propertyIsEnumerable;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// Nashorn ~ JDK8 bug\nvar NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({ 1: 2 }, 1);\n\n// `Object.prototype.propertyIsEnumerable` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable\nexports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {\n var descriptor = getOwnPropertyDescriptor(this, V);\n return !!descriptor && descriptor.enumerable;\n} : $propertyIsEnumerable;\n","'use strict';\n/* eslint-disable no-proto -- safe */\nvar uncurryThisAccessor = require('../internals/function-uncurry-this-accessor');\nvar isObject = require('../internals/is-object');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\nvar aPossiblePrototype = require('../internals/a-possible-prototype');\n\n// `Object.setPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.setprototypeof\n// Works with __proto__ only. Old v8 can't work with null proto objects.\n// eslint-disable-next-line es/no-object-setprototypeof -- safe\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n try {\n setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set');\n setter(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) { /* empty */ }\n return function setPrototypeOf(O, proto) {\n requireObjectCoercible(O);\n aPossiblePrototype(proto);\n if (!isObject(O)) return O;\n if (CORRECT_SETTER) setter(O, proto);\n else O.__proto__ = proto;\n return O;\n };\n}() : undefined);\n","'use strict';\nvar call = require('../internals/function-call');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\n\nvar $TypeError = TypeError;\n\n// `OrdinaryToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-ordinarytoprimitive\nmodule.exports = function (input, pref) {\n var fn, val;\n if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n if (isCallable(fn = input.valueOf) && !isObject(val = call(fn, input))) return val;\n if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n throw new $TypeError(\"Can't convert object to primitive value\");\n};\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar getOwnPropertyNamesModule = require('../internals/object-get-own-property-names');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar anObject = require('../internals/an-object');\n\nvar concat = uncurryThis([].concat);\n\n// all object keys, includes non-enumerable and symbols\nmodule.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {\n var keys = getOwnPropertyNamesModule.f(anObject(it));\n var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n return getOwnPropertySymbols ? concat(keys, getOwnPropertySymbols(it)) : keys;\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar hasOwn = require('../internals/has-own-property');\n\nvar $SyntaxError = SyntaxError;\nvar $parseInt = parseInt;\nvar fromCharCode = String.fromCharCode;\nvar at = uncurryThis(''.charAt);\nvar slice = uncurryThis(''.slice);\nvar exec = uncurryThis(/./.exec);\n\nvar codePoints = {\n '\\\\\"': '\"',\n '\\\\\\\\': '\\\\',\n '\\\\/': '/',\n '\\\\b': '\\b',\n '\\\\f': '\\f',\n '\\\\n': '\\n',\n '\\\\r': '\\r',\n '\\\\t': '\\t'\n};\n\nvar IS_4_HEX_DIGITS = /^[\\da-f]{4}$/i;\n// eslint-disable-next-line regexp/no-control-character -- safe\nvar IS_C0_CONTROL_CODE = /^[\\u0000-\\u001F]$/;\n\nmodule.exports = function (source, i) {\n var unterminated = true;\n var value = '';\n while (i < source.length) {\n var chr = at(source, i);\n if (chr === '\\\\') {\n var twoChars = slice(source, i, i + 2);\n if (hasOwn(codePoints, twoChars)) {\n value += codePoints[twoChars];\n i += 2;\n } else if (twoChars === '\\\\u') {\n i += 2;\n var fourHexDigits = slice(source, i, i + 4);\n if (!exec(IS_4_HEX_DIGITS, fourHexDigits)) throw new $SyntaxError('Bad Unicode escape at: ' + i);\n value += fromCharCode($parseInt(fourHexDigits, 16));\n i += 4;\n } else throw new $SyntaxError('Unknown escape sequence: \"' + twoChars + '\"');\n } else if (chr === '\"') {\n unterminated = false;\n i++;\n break;\n } else {\n if (exec(IS_C0_CONTROL_CODE, chr)) throw new $SyntaxError('Bad control character in string literal at: ' + i);\n value += chr;\n i++;\n }\n }\n if (unterminated) throw new $SyntaxError('Unterminated string at: ' + i);\n return { value: value, end: i };\n};\n","'use strict';\nvar isNullOrUndefined = require('../internals/is-null-or-undefined');\n\nvar $TypeError = TypeError;\n\n// `RequireObjectCoercible` abstract operation\n// https://tc39.es/ecma262/#sec-requireobjectcoercible\nmodule.exports = function (it) {\n if (isNullOrUndefined(it)) throw new $TypeError(\"Can't call method on \" + it);\n return it;\n};\n","'use strict';\nvar SetHelpers = require('../internals/set-helpers');\nvar iterate = require('../internals/set-iterate');\n\nvar Set = SetHelpers.Set;\nvar add = SetHelpers.add;\n\nmodule.exports = function (set) {\n var result = new Set();\n iterate(set, function (it) {\n add(result, it);\n });\n return result;\n};\n","'use strict';\nvar aSet = require('../internals/a-set');\nvar SetHelpers = require('../internals/set-helpers');\nvar clone = require('../internals/set-clone');\nvar size = require('../internals/set-size');\nvar getSetRecord = require('../internals/get-set-record');\nvar iterateSet = require('../internals/set-iterate');\nvar iterateSimple = require('../internals/iterate-simple');\n\nvar has = SetHelpers.has;\nvar remove = SetHelpers.remove;\n\n// `Set.prototype.difference` method\n// https://github.com/tc39/proposal-set-methods\nmodule.exports = function difference(other) {\n var O = aSet(this);\n var otherRec = getSetRecord(other);\n var result = clone(O);\n if (size(O) <= otherRec.size) iterateSet(O, function (e) {\n if (otherRec.includes(e)) remove(result, e);\n });\n else iterateSimple(otherRec.getIterator(), function (e) {\n if (has(O, e)) remove(result, e);\n });\n return result;\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\n// eslint-disable-next-line es/no-set -- safe\nvar SetPrototype = Set.prototype;\n\nmodule.exports = {\n // eslint-disable-next-line es/no-set -- safe\n Set: Set,\n add: uncurryThis(SetPrototype.add),\n has: uncurryThis(SetPrototype.has),\n remove: uncurryThis(SetPrototype['delete']),\n proto: SetPrototype\n};\n","'use strict';\nvar aSet = require('../internals/a-set');\nvar SetHelpers = require('../internals/set-helpers');\nvar size = require('../internals/set-size');\nvar getSetRecord = require('../internals/get-set-record');\nvar iterateSet = require('../internals/set-iterate');\nvar iterateSimple = require('../internals/iterate-simple');\n\nvar Set = SetHelpers.Set;\nvar add = SetHelpers.add;\nvar has = SetHelpers.has;\n\n// `Set.prototype.intersection` method\n// https://github.com/tc39/proposal-set-methods\nmodule.exports = function intersection(other) {\n var O = aSet(this);\n var otherRec = getSetRecord(other);\n var result = new Set();\n\n if (size(O) > otherRec.size) {\n iterateSimple(otherRec.getIterator(), function (e) {\n if (has(O, e)) add(result, e);\n });\n } else {\n iterateSet(O, function (e) {\n if (otherRec.includes(e)) add(result, e);\n });\n }\n\n return result;\n};\n","'use strict';\nvar aSet = require('../internals/a-set');\nvar has = require('../internals/set-helpers').has;\nvar size = require('../internals/set-size');\nvar getSetRecord = require('../internals/get-set-record');\nvar iterateSet = require('../internals/set-iterate');\nvar iterateSimple = require('../internals/iterate-simple');\nvar iteratorClose = require('../internals/iterator-close');\n\n// `Set.prototype.isDisjointFrom` method\n// https://tc39.github.io/proposal-set-methods/#Set.prototype.isDisjointFrom\nmodule.exports = function isDisjointFrom(other) {\n var O = aSet(this);\n var otherRec = getSetRecord(other);\n if (size(O) <= otherRec.size) return iterateSet(O, function (e) {\n if (otherRec.includes(e)) return false;\n }, true) !== false;\n var iterator = otherRec.getIterator();\n return iterateSimple(iterator, function (e) {\n if (has(O, e)) return iteratorClose(iterator, 'normal', false);\n }) !== false;\n};\n","'use strict';\nvar aSet = require('../internals/a-set');\nvar size = require('../internals/set-size');\nvar iterate = require('../internals/set-iterate');\nvar getSetRecord = require('../internals/get-set-record');\n\n// `Set.prototype.isSubsetOf` method\n// https://tc39.github.io/proposal-set-methods/#Set.prototype.isSubsetOf\nmodule.exports = function isSubsetOf(other) {\n var O = aSet(this);\n var otherRec = getSetRecord(other);\n if (size(O) > otherRec.size) return false;\n return iterate(O, function (e) {\n if (!otherRec.includes(e)) return false;\n }, true) !== false;\n};\n","'use strict';\nvar aSet = require('../internals/a-set');\nvar has = require('../internals/set-helpers').has;\nvar size = require('../internals/set-size');\nvar getSetRecord = require('../internals/get-set-record');\nvar iterateSimple = require('../internals/iterate-simple');\nvar iteratorClose = require('../internals/iterator-close');\n\n// `Set.prototype.isSupersetOf` method\n// https://tc39.github.io/proposal-set-methods/#Set.prototype.isSupersetOf\nmodule.exports = function isSupersetOf(other) {\n var O = aSet(this);\n var otherRec = getSetRecord(other);\n if (size(O) < otherRec.size) return false;\n var iterator = otherRec.getIterator();\n return iterateSimple(iterator, function (e) {\n if (!has(O, e)) return iteratorClose(iterator, 'normal', false);\n }) !== false;\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar iterateSimple = require('../internals/iterate-simple');\nvar SetHelpers = require('../internals/set-helpers');\n\nvar Set = SetHelpers.Set;\nvar SetPrototype = SetHelpers.proto;\nvar forEach = uncurryThis(SetPrototype.forEach);\nvar keys = uncurryThis(SetPrototype.keys);\nvar next = keys(new Set()).next;\n\nmodule.exports = function (set, fn, interruptible) {\n return interruptible ? iterateSimple({ iterator: keys(set), next: next }, fn) : forEach(set, fn);\n};\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\n\nvar createSetLike = function (size) {\n return {\n size: size,\n has: function () {\n return false;\n },\n keys: function () {\n return {\n next: function () {\n return { done: true };\n }\n };\n }\n };\n};\n\nmodule.exports = function (name) {\n var Set = getBuiltIn('Set');\n try {\n new Set()[name](createSetLike(0));\n try {\n // late spec change, early WebKit ~ Safari 17.0 beta implementation does not pass it\n // https://github.com/tc39/proposal-set-methods/pull/88\n new Set()[name](createSetLike(-1));\n return false;\n } catch (error2) {\n return true;\n }\n } catch (error) {\n return false;\n }\n};\n","'use strict';\nvar uncurryThisAccessor = require('../internals/function-uncurry-this-accessor');\nvar SetHelpers = require('../internals/set-helpers');\n\nmodule.exports = uncurryThisAccessor(SetHelpers.proto, 'size', 'get') || function (set) {\n return set.size;\n};\n","'use strict';\nvar aSet = require('../internals/a-set');\nvar SetHelpers = require('../internals/set-helpers');\nvar clone = require('../internals/set-clone');\nvar getSetRecord = require('../internals/get-set-record');\nvar iterateSimple = require('../internals/iterate-simple');\n\nvar add = SetHelpers.add;\nvar has = SetHelpers.has;\nvar remove = SetHelpers.remove;\n\n// `Set.prototype.symmetricDifference` method\n// https://github.com/tc39/proposal-set-methods\nmodule.exports = function symmetricDifference(other) {\n var O = aSet(this);\n var keysIter = getSetRecord(other).getIterator();\n var result = clone(O);\n iterateSimple(keysIter, function (e) {\n if (has(O, e)) remove(result, e);\n else add(result, e);\n });\n return result;\n};\n","'use strict';\nvar aSet = require('../internals/a-set');\nvar add = require('../internals/set-helpers').add;\nvar clone = require('../internals/set-clone');\nvar getSetRecord = require('../internals/get-set-record');\nvar iterateSimple = require('../internals/iterate-simple');\n\n// `Set.prototype.union` method\n// https://github.com/tc39/proposal-set-methods\nmodule.exports = function union(other) {\n var O = aSet(this);\n var keysIter = getSetRecord(other).getIterator();\n var result = clone(O);\n iterateSimple(keysIter, function (it) {\n add(result, it);\n });\n return result;\n};\n","'use strict';\nvar shared = require('../internals/shared');\nvar uid = require('../internals/uid');\n\nvar keys = shared('keys');\n\nmodule.exports = function (key) {\n return keys[key] || (keys[key] = uid(key));\n};\n","'use strict';\nvar IS_PURE = require('../internals/is-pure');\nvar globalThis = require('../internals/global');\nvar defineGlobalProperty = require('../internals/define-global-property');\n\nvar SHARED = '__core-js_shared__';\nvar store = module.exports = globalThis[SHARED] || defineGlobalProperty(SHARED, {});\n\n(store.versions || (store.versions = [])).push({\n version: '3.37.1',\n mode: IS_PURE ? 'pure' : 'global',\n copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',\n license: 'https://github.com/zloirock/core-js/blob/v3.37.1/LICENSE',\n source: 'https://github.com/zloirock/core-js'\n});\n","'use strict';\nvar store = require('../internals/shared-store');\n\nmodule.exports = function (key, value) {\n return store[key] || (store[key] = value || {});\n};\n","'use strict';\nvar global = require('../internals/global');\nvar fails = require('../internals/fails');\nvar V8 = require('../internals/engine-v8-version');\nvar IS_BROWSER = require('../internals/engine-is-browser');\nvar IS_DENO = require('../internals/engine-is-deno');\nvar IS_NODE = require('../internals/engine-is-node');\n\nvar structuredClone = global.structuredClone;\n\nmodule.exports = !!structuredClone && !fails(function () {\n // prevent V8 ArrayBufferDetaching protector cell invalidation and performance degradation\n // https://github.com/zloirock/core-js/issues/679\n if ((IS_DENO && V8 > 92) || (IS_NODE && V8 > 94) || (IS_BROWSER && V8 > 97)) return false;\n var buffer = new ArrayBuffer(8);\n var clone = structuredClone(buffer, { transfer: [buffer] });\n return buffer.byteLength !== 0 || clone.byteLength !== 8;\n});\n","'use strict';\n/* eslint-disable es/no-symbol -- required for testing */\nvar V8_VERSION = require('../internals/engine-v8-version');\nvar fails = require('../internals/fails');\nvar global = require('../internals/global');\n\nvar $String = global.String;\n\n// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing\nmodule.exports = !!Object.getOwnPropertySymbols && !fails(function () {\n var symbol = Symbol('symbol detection');\n // Chrome 38 Symbol has incorrect toString conversion\n // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances\n // nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,\n // of course, fail.\n return !$String(symbol) || !(Object(symbol) instanceof Symbol) ||\n // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances\n !Symbol.sham && V8_VERSION && V8_VERSION < 41;\n});\n","'use strict';\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar max = Math.max;\nvar min = Math.min;\n\n// Helper for a popular repeating case of the spec:\n// Let integer be ? ToInteger(index).\n// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).\nmodule.exports = function (index, length) {\n var integer = toIntegerOrInfinity(index);\n return integer < 0 ? max(integer + length, 0) : min(integer, length);\n};\n","'use strict';\nvar toPrimitive = require('../internals/to-primitive');\n\nvar $TypeError = TypeError;\n\n// `ToBigInt` abstract operation\n// https://tc39.es/ecma262/#sec-tobigint\nmodule.exports = function (argument) {\n var prim = toPrimitive(argument, 'number');\n if (typeof prim == 'number') throw new $TypeError(\"Can't convert number to bigint\");\n // eslint-disable-next-line es/no-bigint -- safe\n return BigInt(prim);\n};\n","'use strict';\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar toLength = require('../internals/to-length');\n\nvar $RangeError = RangeError;\n\n// `ToIndex` abstract operation\n// https://tc39.es/ecma262/#sec-toindex\nmodule.exports = function (it) {\n if (it === undefined) return 0;\n var number = toIntegerOrInfinity(it);\n var length = toLength(number);\n if (number !== length) throw new $RangeError('Wrong length or index');\n return length;\n};\n","'use strict';\n// toObject with fallback for non-array-like ES3 strings\nvar IndexedObject = require('../internals/indexed-object');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nmodule.exports = function (it) {\n return IndexedObject(requireObjectCoercible(it));\n};\n","'use strict';\nvar trunc = require('../internals/math-trunc');\n\n// `ToIntegerOrInfinity` abstract operation\n// https://tc39.es/ecma262/#sec-tointegerorinfinity\nmodule.exports = function (argument) {\n var number = +argument;\n // eslint-disable-next-line no-self-compare -- NaN check\n return number !== number || number === 0 ? 0 : trunc(number);\n};\n","'use strict';\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar min = Math.min;\n\n// `ToLength` abstract operation\n// https://tc39.es/ecma262/#sec-tolength\nmodule.exports = function (argument) {\n var len = toIntegerOrInfinity(argument);\n return len > 0 ? min(len, 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991\n};\n","'use strict';\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar $Object = Object;\n\n// `ToObject` abstract operation\n// https://tc39.es/ecma262/#sec-toobject\nmodule.exports = function (argument) {\n return $Object(requireObjectCoercible(argument));\n};\n","'use strict';\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar $RangeError = RangeError;\n\nmodule.exports = function (it) {\n var result = toIntegerOrInfinity(it);\n if (result < 0) throw new $RangeError(\"The argument can't be less than 0\");\n return result;\n};\n","'use strict';\nvar call = require('../internals/function-call');\nvar isObject = require('../internals/is-object');\nvar isSymbol = require('../internals/is-symbol');\nvar getMethod = require('../internals/get-method');\nvar ordinaryToPrimitive = require('../internals/ordinary-to-primitive');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar $TypeError = TypeError;\nvar TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\n\n// `ToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-toprimitive\nmodule.exports = function (input, pref) {\n if (!isObject(input) || isSymbol(input)) return input;\n var exoticToPrim = getMethod(input, TO_PRIMITIVE);\n var result;\n if (exoticToPrim) {\n if (pref === undefined) pref = 'default';\n result = call(exoticToPrim, input, pref);\n if (!isObject(result) || isSymbol(result)) return result;\n throw new $TypeError(\"Can't convert object to primitive value\");\n }\n if (pref === undefined) pref = 'number';\n return ordinaryToPrimitive(input, pref);\n};\n","'use strict';\nvar toPrimitive = require('../internals/to-primitive');\nvar isSymbol = require('../internals/is-symbol');\n\n// `ToPropertyKey` abstract operation\n// https://tc39.es/ecma262/#sec-topropertykey\nmodule.exports = function (argument) {\n var key = toPrimitive(argument, 'string');\n return isSymbol(key) ? key : key + '';\n};\n","'use strict';\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar test = {};\n\ntest[TO_STRING_TAG] = 'z';\n\nmodule.exports = String(test) === '[object z]';\n","'use strict';\nvar classof = require('../internals/classof');\n\nvar $String = String;\n\nmodule.exports = function (argument) {\n if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');\n return $String(argument);\n};\n","'use strict';\nvar IS_NODE = require('../internals/engine-is-node');\n\nmodule.exports = function (name) {\n try {\n // eslint-disable-next-line no-new-func -- safe\n if (IS_NODE) return Function('return require(\"' + name + '\")')();\n } catch (error) { /* empty */ }\n};\n","'use strict';\nvar $String = String;\n\nmodule.exports = function (argument) {\n try {\n return $String(argument);\n } catch (error) {\n return 'Object';\n }\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar id = 0;\nvar postfix = Math.random();\nvar toString = uncurryThis(1.0.toString);\n\nmodule.exports = function (key) {\n return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);\n};\n","'use strict';\n/* eslint-disable es/no-symbol -- required for testing */\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\n\nmodule.exports = NATIVE_SYMBOL\n && !Symbol.sham\n && typeof Symbol.iterator == 'symbol';\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\n\n// V8 ~ Chrome 36-\n// https://bugs.chromium.org/p/v8/issues/detail?id=3334\nmodule.exports = DESCRIPTORS && fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(function () { /* empty */ }, 'prototype', {\n value: 42,\n writable: false\n }).prototype !== 42;\n});\n","'use strict';\nvar $TypeError = TypeError;\n\nmodule.exports = function (passed, required) {\n if (passed < required) throw new $TypeError('Not enough arguments');\n return passed;\n};\n","'use strict';\nvar global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar WeakMap = global.WeakMap;\n\nmodule.exports = isCallable(WeakMap) && /native code/.test(String(WeakMap));\n","'use strict';\nvar global = require('../internals/global');\nvar shared = require('../internals/shared');\nvar hasOwn = require('../internals/has-own-property');\nvar uid = require('../internals/uid');\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar Symbol = global.Symbol;\nvar WellKnownSymbolsStore = shared('wks');\nvar createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol['for'] || Symbol : Symbol && Symbol.withoutSetter || uid;\n\nmodule.exports = function (name) {\n if (!hasOwn(WellKnownSymbolsStore, name)) {\n WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn(Symbol, name)\n ? Symbol[name]\n : createWellKnownSymbol('Symbol.' + name);\n } return WellKnownSymbolsStore[name];\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar defineBuiltInAccessor = require('../internals/define-built-in-accessor');\nvar isDetached = require('../internals/array-buffer-is-detached');\n\nvar ArrayBufferPrototype = ArrayBuffer.prototype;\n\nif (DESCRIPTORS && !('detached' in ArrayBufferPrototype)) {\n defineBuiltInAccessor(ArrayBufferPrototype, 'detached', {\n configurable: true,\n get: function detached() {\n return isDetached(this);\n }\n });\n}\n","'use strict';\nvar $ = require('../internals/export');\nvar $transfer = require('../internals/array-buffer-transfer');\n\n// `ArrayBuffer.prototype.transferToFixedLength` method\n// https://tc39.es/proposal-arraybuffer-transfer/#sec-arraybuffer.prototype.transfertofixedlength\nif ($transfer) $({ target: 'ArrayBuffer', proto: true }, {\n transferToFixedLength: function transferToFixedLength() {\n return $transfer(this, arguments.length ? arguments[0] : undefined, false);\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar $transfer = require('../internals/array-buffer-transfer');\n\n// `ArrayBuffer.prototype.transfer` method\n// https://tc39.es/proposal-arraybuffer-transfer/#sec-arraybuffer.prototype.transfer\nif ($transfer) $({ target: 'ArrayBuffer', proto: true }, {\n transfer: function transfer() {\n return $transfer(this, arguments.length ? arguments[0] : undefined, true);\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar toObject = require('../internals/to-object');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar setArrayLength = require('../internals/array-set-length');\nvar doesNotExceedSafeInteger = require('../internals/does-not-exceed-safe-integer');\nvar fails = require('../internals/fails');\n\nvar INCORRECT_TO_LENGTH = fails(function () {\n return [].push.call({ length: 0x100000000 }, 1) !== 4294967297;\n});\n\n// V8 <= 121 and Safari <= 15.4; FF < 23 throws InternalError\n// https://bugs.chromium.org/p/v8/issues/detail?id=12681\nvar properErrorOnNonWritableLength = function () {\n try {\n // eslint-disable-next-line es/no-object-defineproperty -- safe\n Object.defineProperty([], 'length', { writable: false }).push();\n } catch (error) {\n return error instanceof TypeError;\n }\n};\n\nvar FORCED = INCORRECT_TO_LENGTH || !properErrorOnNonWritableLength();\n\n// `Array.prototype.push` method\n// https://tc39.es/ecma262/#sec-array.prototype.push\n$({ target: 'Array', proto: true, arity: 1, forced: FORCED }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n push: function push(item) {\n var O = toObject(this);\n var len = lengthOfArrayLike(O);\n var argCount = arguments.length;\n doesNotExceedSafeInteger(len + argCount);\n for (var i = 0; i < argCount; i++) {\n O[len] = arguments[i];\n len++;\n }\n setArrayLength(O, len);\n return len;\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar newPromiseCapabilityModule = require('../internals/new-promise-capability');\n\n// `Promise.withResolvers` method\n// https://github.com/tc39/proposal-promise-with-resolvers\n$({ target: 'Promise', stat: true }, {\n withResolvers: function withResolvers() {\n var promiseCapability = newPromiseCapabilityModule.f(this);\n return {\n promise: promiseCapability.promise,\n resolve: promiseCapability.resolve,\n reject: promiseCapability.reject\n };\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar difference = require('../internals/set-difference');\nvar setMethodAcceptSetLike = require('../internals/set-method-accept-set-like');\n\n// `Set.prototype.difference` method\n// https://github.com/tc39/proposal-set-methods\n$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('difference') }, {\n difference: difference\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar fails = require('../internals/fails');\nvar intersection = require('../internals/set-intersection');\nvar setMethodAcceptSetLike = require('../internals/set-method-accept-set-like');\n\nvar INCORRECT = !setMethodAcceptSetLike('intersection') || fails(function () {\n // eslint-disable-next-line es/no-array-from, es/no-set -- testing\n return String(Array.from(new Set([1, 2, 3]).intersection(new Set([3, 2])))) !== '3,2';\n});\n\n// `Set.prototype.intersection` method\n// https://github.com/tc39/proposal-set-methods\n$({ target: 'Set', proto: true, real: true, forced: INCORRECT }, {\n intersection: intersection\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar isDisjointFrom = require('../internals/set-is-disjoint-from');\nvar setMethodAcceptSetLike = require('../internals/set-method-accept-set-like');\n\n// `Set.prototype.isDisjointFrom` method\n// https://github.com/tc39/proposal-set-methods\n$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isDisjointFrom') }, {\n isDisjointFrom: isDisjointFrom\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar isSubsetOf = require('../internals/set-is-subset-of');\nvar setMethodAcceptSetLike = require('../internals/set-method-accept-set-like');\n\n// `Set.prototype.isSubsetOf` method\n// https://github.com/tc39/proposal-set-methods\n$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isSubsetOf') }, {\n isSubsetOf: isSubsetOf\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar isSupersetOf = require('../internals/set-is-superset-of');\nvar setMethodAcceptSetLike = require('../internals/set-method-accept-set-like');\n\n// `Set.prototype.isSupersetOf` method\n// https://github.com/tc39/proposal-set-methods\n$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isSupersetOf') }, {\n isSupersetOf: isSupersetOf\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar symmetricDifference = require('../internals/set-symmetric-difference');\nvar setMethodAcceptSetLike = require('../internals/set-method-accept-set-like');\n\n// `Set.prototype.symmetricDifference` method\n// https://github.com/tc39/proposal-set-methods\n$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('symmetricDifference') }, {\n symmetricDifference: symmetricDifference\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar union = require('../internals/set-union');\nvar setMethodAcceptSetLike = require('../internals/set-method-accept-set-like');\n\n// `Set.prototype.union` method\n// https://github.com/tc39/proposal-set-methods\n$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('union') }, {\n union: union\n});\n","'use strict';\nvar arrayToReversed = require('../internals/array-to-reversed');\nvar ArrayBufferViewCore = require('../internals/array-buffer-view-core');\n\nvar aTypedArray = ArrayBufferViewCore.aTypedArray;\nvar exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;\nvar getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;\n\n// `%TypedArray%.prototype.toReversed` method\n// https://tc39.es/ecma262/#sec-%typedarray%.prototype.toreversed\nexportTypedArrayMethod('toReversed', function toReversed() {\n return arrayToReversed(aTypedArray(this), getTypedArrayConstructor(this));\n});\n","'use strict';\nvar ArrayBufferViewCore = require('../internals/array-buffer-view-core');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar aCallable = require('../internals/a-callable');\nvar arrayFromConstructorAndList = require('../internals/array-from-constructor-and-list');\n\nvar aTypedArray = ArrayBufferViewCore.aTypedArray;\nvar getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;\nvar exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;\nvar sort = uncurryThis(ArrayBufferViewCore.TypedArrayPrototype.sort);\n\n// `%TypedArray%.prototype.toSorted` method\n// https://tc39.es/ecma262/#sec-%typedarray%.prototype.tosorted\nexportTypedArrayMethod('toSorted', function toSorted(compareFn) {\n if (compareFn !== undefined) aCallable(compareFn);\n var O = aTypedArray(this);\n var A = arrayFromConstructorAndList(getTypedArrayConstructor(O), O);\n return sort(A, compareFn);\n});\n","'use strict';\nvar arrayWith = require('../internals/array-with');\nvar ArrayBufferViewCore = require('../internals/array-buffer-view-core');\nvar isBigIntArray = require('../internals/is-big-int-array');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar toBigInt = require('../internals/to-big-int');\n\nvar aTypedArray = ArrayBufferViewCore.aTypedArray;\nvar getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;\nvar exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;\n\nvar PROPER_ORDER = !!function () {\n try {\n // eslint-disable-next-line no-throw-literal, es/no-typed-arrays, es/no-array-prototype-with -- required for testing\n new Int8Array(1)['with'](2, { valueOf: function () { throw 8; } });\n } catch (error) {\n // some early implementations, like WebKit, does not follow the final semantic\n // https://github.com/tc39/proposal-change-array-by-copy/pull/86\n return error === 8;\n }\n}();\n\n// `%TypedArray%.prototype.with` method\n// https://tc39.es/ecma262/#sec-%typedarray%.prototype.with\nexportTypedArrayMethod('with', { 'with': function (index, value) {\n var O = aTypedArray(this);\n var relativeIndex = toIntegerOrInfinity(index);\n var actualValue = isBigIntArray(O) ? toBigInt(value) : +value;\n return arrayWith(O, getTypedArrayConstructor(O), relativeIndex, actualValue);\n} }['with'], !PROPER_ORDER);\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar anInstance = require('../internals/an-instance');\nvar anObject = require('../internals/an-object');\nvar isCallable = require('../internals/is-callable');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar defineBuiltInAccessor = require('../internals/define-built-in-accessor');\nvar createProperty = require('../internals/create-property');\nvar fails = require('../internals/fails');\nvar hasOwn = require('../internals/has-own-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar IteratorPrototype = require('../internals/iterators-core').IteratorPrototype;\nvar DESCRIPTORS = require('../internals/descriptors');\nvar IS_PURE = require('../internals/is-pure');\n\nvar CONSTRUCTOR = 'constructor';\nvar ITERATOR = 'Iterator';\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\n\nvar $TypeError = TypeError;\nvar NativeIterator = global[ITERATOR];\n\n// FF56- have non-standard global helper `Iterator`\nvar FORCED = IS_PURE\n || !isCallable(NativeIterator)\n || NativeIterator.prototype !== IteratorPrototype\n // FF44- non-standard `Iterator` passes previous tests\n || !fails(function () { NativeIterator({}); });\n\nvar IteratorConstructor = function Iterator() {\n anInstance(this, IteratorPrototype);\n if (getPrototypeOf(this) === IteratorPrototype) throw new $TypeError('Abstract class Iterator not directly constructable');\n};\n\nvar defineIteratorPrototypeAccessor = function (key, value) {\n if (DESCRIPTORS) {\n defineBuiltInAccessor(IteratorPrototype, key, {\n configurable: true,\n get: function () {\n return value;\n },\n set: function (replacement) {\n anObject(this);\n if (this === IteratorPrototype) throw new $TypeError(\"You can't redefine this property\");\n if (hasOwn(this, key)) this[key] = replacement;\n else createProperty(this, key, replacement);\n }\n });\n } else IteratorPrototype[key] = value;\n};\n\nif (!hasOwn(IteratorPrototype, TO_STRING_TAG)) defineIteratorPrototypeAccessor(TO_STRING_TAG, ITERATOR);\n\nif (FORCED || !hasOwn(IteratorPrototype, CONSTRUCTOR) || IteratorPrototype[CONSTRUCTOR] === Object) {\n defineIteratorPrototypeAccessor(CONSTRUCTOR, IteratorConstructor);\n}\n\nIteratorConstructor.prototype = IteratorPrototype;\n\n// `Iterator` constructor\n// https://github.com/tc39/proposal-iterator-helpers\n$({ global: true, constructor: true, forced: FORCED }, {\n Iterator: IteratorConstructor\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar getIteratorDirect = require('../internals/get-iterator-direct');\nvar notANaN = require('../internals/not-a-nan');\nvar toPositiveInteger = require('../internals/to-positive-integer');\nvar createIteratorProxy = require('../internals/iterator-create-proxy');\nvar IS_PURE = require('../internals/is-pure');\n\nvar IteratorProxy = createIteratorProxy(function () {\n var iterator = this.iterator;\n var next = this.next;\n var result, done;\n while (this.remaining) {\n this.remaining--;\n result = anObject(call(next, iterator));\n done = this.done = !!result.done;\n if (done) return;\n }\n result = anObject(call(next, iterator));\n done = this.done = !!result.done;\n if (!done) return result.value;\n});\n\n// `Iterator.prototype.drop` method\n// https://github.com/tc39/proposal-iterator-helpers\n$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {\n drop: function drop(limit) {\n anObject(this);\n var remaining = toPositiveInteger(notANaN(+limit));\n return new IteratorProxy(getIteratorDirect(this), {\n remaining: remaining\n });\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar iterate = require('../internals/iterate');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar getIteratorDirect = require('../internals/get-iterator-direct');\n\n// `Iterator.prototype.every` method\n// https://github.com/tc39/proposal-iterator-helpers\n$({ target: 'Iterator', proto: true, real: true }, {\n every: function every(predicate) {\n anObject(this);\n aCallable(predicate);\n var record = getIteratorDirect(this);\n var counter = 0;\n return !iterate(record, function (value, stop) {\n if (!predicate(value, counter++)) return stop();\n }, { IS_RECORD: true, INTERRUPTED: true }).stopped;\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar call = require('../internals/function-call');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar getIteratorDirect = require('../internals/get-iterator-direct');\nvar createIteratorProxy = require('../internals/iterator-create-proxy');\nvar callWithSafeIterationClosing = require('../internals/call-with-safe-iteration-closing');\nvar IS_PURE = require('../internals/is-pure');\n\nvar IteratorProxy = createIteratorProxy(function () {\n var iterator = this.iterator;\n var predicate = this.predicate;\n var next = this.next;\n var result, done, value;\n while (true) {\n result = anObject(call(next, iterator));\n done = this.done = !!result.done;\n if (done) return;\n value = result.value;\n if (callWithSafeIterationClosing(iterator, predicate, [value, this.counter++], true)) return value;\n }\n});\n\n// `Iterator.prototype.filter` method\n// https://github.com/tc39/proposal-iterator-helpers\n$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {\n filter: function filter(predicate) {\n anObject(this);\n aCallable(predicate);\n return new IteratorProxy(getIteratorDirect(this), {\n predicate: predicate\n });\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar call = require('../internals/function-call');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar getIteratorDirect = require('../internals/get-iterator-direct');\nvar getIteratorFlattenable = require('../internals/get-iterator-flattenable');\nvar createIteratorProxy = require('../internals/iterator-create-proxy');\nvar iteratorClose = require('../internals/iterator-close');\nvar IS_PURE = require('../internals/is-pure');\n\nvar IteratorProxy = createIteratorProxy(function () {\n var iterator = this.iterator;\n var mapper = this.mapper;\n var result, inner;\n\n while (true) {\n if (inner = this.inner) try {\n result = anObject(call(inner.next, inner.iterator));\n if (!result.done) return result.value;\n this.inner = null;\n } catch (error) { iteratorClose(iterator, 'throw', error); }\n\n result = anObject(call(this.next, iterator));\n\n if (this.done = !!result.done) return;\n\n try {\n this.inner = getIteratorFlattenable(mapper(result.value, this.counter++), false);\n } catch (error) { iteratorClose(iterator, 'throw', error); }\n }\n});\n\n// `Iterator.prototype.flatMap` method\n// https://github.com/tc39/proposal-iterator-helpers\n$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {\n flatMap: function flatMap(mapper) {\n anObject(this);\n aCallable(mapper);\n return new IteratorProxy(getIteratorDirect(this), {\n mapper: mapper,\n inner: null\n });\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar map = require('../internals/iterator-map');\nvar IS_PURE = require('../internals/is-pure');\n\n// `Iterator.prototype.map` method\n// https://github.com/tc39/proposal-iterator-helpers\n$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {\n map: map\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar iterate = require('../internals/iterate');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar getIteratorDirect = require('../internals/get-iterator-direct');\n\n// `Iterator.prototype.some` method\n// https://github.com/tc39/proposal-iterator-helpers\n$({ target: 'Iterator', proto: true, real: true }, {\n some: function some(predicate) {\n anObject(this);\n aCallable(predicate);\n var record = getIteratorDirect(this);\n var counter = 0;\n return iterate(record, function (value, stop) {\n if (predicate(value, counter++)) return stop();\n }, { IS_RECORD: true, INTERRUPTED: true }).stopped;\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar call = require('../internals/function-call');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar isArray = require('../internals/is-array');\nvar hasOwn = require('../internals/has-own-property');\nvar toString = require('../internals/to-string');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar createProperty = require('../internals/create-property');\nvar fails = require('../internals/fails');\nvar parseJSONString = require('../internals/parse-json-string');\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\n\nvar JSON = global.JSON;\nvar Number = global.Number;\nvar SyntaxError = global.SyntaxError;\nvar nativeParse = JSON && JSON.parse;\nvar enumerableOwnProperties = getBuiltIn('Object', 'keys');\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\nvar at = uncurryThis(''.charAt);\nvar slice = uncurryThis(''.slice);\nvar exec = uncurryThis(/./.exec);\nvar push = uncurryThis([].push);\n\nvar IS_DIGIT = /^\\d$/;\nvar IS_NON_ZERO_DIGIT = /^[1-9]$/;\nvar IS_NUMBER_START = /^(?:-|\\d)$/;\nvar IS_WHITESPACE = /^[\\t\\n\\r ]$/;\n\nvar PRIMITIVE = 0;\nvar OBJECT = 1;\n\nvar $parse = function (source, reviver) {\n source = toString(source);\n var context = new Context(source, 0, '');\n var root = context.parse();\n var value = root.value;\n var endIndex = context.skip(IS_WHITESPACE, root.end);\n if (endIndex < source.length) {\n throw new SyntaxError('Unexpected extra character: \"' + at(source, endIndex) + '\" after the parsed data at: ' + endIndex);\n }\n return isCallable(reviver) ? internalize({ '': value }, '', reviver, root) : value;\n};\n\nvar internalize = function (holder, name, reviver, node) {\n var val = holder[name];\n var unmodified = node && val === node.value;\n var context = unmodified && typeof node.source == 'string' ? { source: node.source } : {};\n var elementRecordsLen, keys, len, i, P;\n if (isObject(val)) {\n var nodeIsArray = isArray(val);\n var nodes = unmodified ? node.nodes : nodeIsArray ? [] : {};\n if (nodeIsArray) {\n elementRecordsLen = nodes.length;\n len = lengthOfArrayLike(val);\n for (i = 0; i < len; i++) {\n internalizeProperty(val, i, internalize(val, '' + i, reviver, i < elementRecordsLen ? nodes[i] : undefined));\n }\n } else {\n keys = enumerableOwnProperties(val);\n len = lengthOfArrayLike(keys);\n for (i = 0; i < len; i++) {\n P = keys[i];\n internalizeProperty(val, P, internalize(val, P, reviver, hasOwn(nodes, P) ? nodes[P] : undefined));\n }\n }\n }\n return call(reviver, holder, name, val, context);\n};\n\nvar internalizeProperty = function (object, key, value) {\n if (DESCRIPTORS) {\n var descriptor = getOwnPropertyDescriptor(object, key);\n if (descriptor && !descriptor.configurable) return;\n }\n if (value === undefined) delete object[key];\n else createProperty(object, key, value);\n};\n\nvar Node = function (value, end, source, nodes) {\n this.value = value;\n this.end = end;\n this.source = source;\n this.nodes = nodes;\n};\n\nvar Context = function (source, index) {\n this.source = source;\n this.index = index;\n};\n\n// https://www.json.org/json-en.html\nContext.prototype = {\n fork: function (nextIndex) {\n return new Context(this.source, nextIndex);\n },\n parse: function () {\n var source = this.source;\n var i = this.skip(IS_WHITESPACE, this.index);\n var fork = this.fork(i);\n var chr = at(source, i);\n if (exec(IS_NUMBER_START, chr)) return fork.number();\n switch (chr) {\n case '{':\n return fork.object();\n case '[':\n return fork.array();\n case '\"':\n return fork.string();\n case 't':\n return fork.keyword(true);\n case 'f':\n return fork.keyword(false);\n case 'n':\n return fork.keyword(null);\n } throw new SyntaxError('Unexpected character: \"' + chr + '\" at: ' + i);\n },\n node: function (type, value, start, end, nodes) {\n return new Node(value, end, type ? null : slice(this.source, start, end), nodes);\n },\n object: function () {\n var source = this.source;\n var i = this.index + 1;\n var expectKeypair = false;\n var object = {};\n var nodes = {};\n while (i < source.length) {\n i = this.until(['\"', '}'], i);\n if (at(source, i) === '}' && !expectKeypair) {\n i++;\n break;\n }\n // Parsing the key\n var result = this.fork(i).string();\n var key = result.value;\n i = result.end;\n i = this.until([':'], i) + 1;\n // Parsing value\n i = this.skip(IS_WHITESPACE, i);\n result = this.fork(i).parse();\n createProperty(nodes, key, result);\n createProperty(object, key, result.value);\n i = this.until([',', '}'], result.end);\n var chr = at(source, i);\n if (chr === ',') {\n expectKeypair = true;\n i++;\n } else if (chr === '}') {\n i++;\n break;\n }\n }\n return this.node(OBJECT, object, this.index, i, nodes);\n },\n array: function () {\n var source = this.source;\n var i = this.index + 1;\n var expectElement = false;\n var array = [];\n var nodes = [];\n while (i < source.length) {\n i = this.skip(IS_WHITESPACE, i);\n if (at(source, i) === ']' && !expectElement) {\n i++;\n break;\n }\n var result = this.fork(i).parse();\n push(nodes, result);\n push(array, result.value);\n i = this.until([',', ']'], result.end);\n if (at(source, i) === ',') {\n expectElement = true;\n i++;\n } else if (at(source, i) === ']') {\n i++;\n break;\n }\n }\n return this.node(OBJECT, array, this.index, i, nodes);\n },\n string: function () {\n var index = this.index;\n var parsed = parseJSONString(this.source, this.index + 1);\n return this.node(PRIMITIVE, parsed.value, index, parsed.end);\n },\n number: function () {\n var source = this.source;\n var startIndex = this.index;\n var i = startIndex;\n if (at(source, i) === '-') i++;\n if (at(source, i) === '0') i++;\n else if (exec(IS_NON_ZERO_DIGIT, at(source, i))) i = this.skip(IS_DIGIT, ++i);\n else throw new SyntaxError('Failed to parse number at: ' + i);\n if (at(source, i) === '.') i = this.skip(IS_DIGIT, ++i);\n if (at(source, i) === 'e' || at(source, i) === 'E') {\n i++;\n if (at(source, i) === '+' || at(source, i) === '-') i++;\n var exponentStartIndex = i;\n i = this.skip(IS_DIGIT, i);\n if (exponentStartIndex === i) throw new SyntaxError(\"Failed to parse number's exponent value at: \" + i);\n }\n return this.node(PRIMITIVE, Number(slice(source, startIndex, i)), startIndex, i);\n },\n keyword: function (value) {\n var keyword = '' + value;\n var index = this.index;\n var endIndex = index + keyword.length;\n if (slice(this.source, index, endIndex) !== keyword) throw new SyntaxError('Failed to parse value at: ' + index);\n return this.node(PRIMITIVE, value, index, endIndex);\n },\n skip: function (regex, i) {\n var source = this.source;\n for (; i < source.length; i++) if (!exec(regex, at(source, i))) break;\n return i;\n },\n until: function (array, i) {\n i = this.skip(IS_WHITESPACE, i);\n var chr = at(this.source, i);\n for (var j = 0; j < array.length; j++) if (array[j] === chr) return i;\n throw new SyntaxError('Unexpected character: \"' + chr + '\" at: ' + i);\n }\n};\n\nvar NO_SOURCE_SUPPORT = fails(function () {\n var unsafeInt = '9007199254740993';\n var source;\n nativeParse(unsafeInt, function (key, value, context) {\n source = context.source;\n });\n return source !== unsafeInt;\n});\n\nvar PROPER_BASE_PARSE = NATIVE_SYMBOL && !fails(function () {\n // Safari 9 bug\n return 1 / nativeParse('-0 \\t') !== -Infinity;\n});\n\n// `JSON.parse` method\n// https://tc39.es/ecma262/#sec-json.parse\n// https://github.com/tc39/proposal-json-parse-with-source\n$({ target: 'JSON', stat: true, forced: NO_SOURCE_SUPPORT }, {\n parse: function parse(text, reviver) {\n return PROPER_BASE_PARSE && !isCallable(reviver) ? nativeParse(text) : $parse(text, reviver);\n }\n});\n","'use strict';\n// TODO: Remove from `core-js@4`\nrequire('../modules/es.set.difference.v2');\n","'use strict';\n// TODO: Remove from `core-js@4`\nrequire('../modules/es.set.intersection.v2');\n","'use strict';\n// TODO: Remove from `core-js@4`\nrequire('../modules/es.set.is-disjoint-from.v2');\n","'use strict';\n// TODO: Remove from `core-js@4`\nrequire('../modules/es.set.is-subset-of.v2');\n","'use strict';\n// TODO: Remove from `core-js@4`\nrequire('../modules/es.set.is-superset-of.v2');\n","'use strict';\n// TODO: Remove from `core-js@4`\nrequire('../modules/es.set.symmetric-difference.v2');\n","'use strict';\n// TODO: Remove from `core-js@4`\nrequire('../modules/es.set.union.v2');\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar defineProperty = require('../internals/object-define-property').f;\nvar hasOwn = require('../internals/has-own-property');\nvar anInstance = require('../internals/an-instance');\nvar inheritIfRequired = require('../internals/inherit-if-required');\nvar normalizeStringArgument = require('../internals/normalize-string-argument');\nvar DOMExceptionConstants = require('../internals/dom-exception-constants');\nvar clearErrorStack = require('../internals/error-stack-clear');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar IS_PURE = require('../internals/is-pure');\n\nvar DOM_EXCEPTION = 'DOMException';\nvar Error = getBuiltIn('Error');\nvar NativeDOMException = getBuiltIn(DOM_EXCEPTION);\n\nvar $DOMException = function DOMException() {\n anInstance(this, DOMExceptionPrototype);\n var argumentsLength = arguments.length;\n var message = normalizeStringArgument(argumentsLength < 1 ? undefined : arguments[0]);\n var name = normalizeStringArgument(argumentsLength < 2 ? undefined : arguments[1], 'Error');\n var that = new NativeDOMException(message, name);\n var error = new Error(message);\n error.name = DOM_EXCEPTION;\n defineProperty(that, 'stack', createPropertyDescriptor(1, clearErrorStack(error.stack, 1)));\n inheritIfRequired(that, this, $DOMException);\n return that;\n};\n\nvar DOMExceptionPrototype = $DOMException.prototype = NativeDOMException.prototype;\n\nvar ERROR_HAS_STACK = 'stack' in new Error(DOM_EXCEPTION);\nvar DOM_EXCEPTION_HAS_STACK = 'stack' in new NativeDOMException(1, 2);\n\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar descriptor = NativeDOMException && DESCRIPTORS && Object.getOwnPropertyDescriptor(global, DOM_EXCEPTION);\n\n// Bun ~ 0.1.1 DOMException have incorrect descriptor and we can't redefine it\n// https://github.com/Jarred-Sumner/bun/issues/399\nvar BUGGY_DESCRIPTOR = !!descriptor && !(descriptor.writable && descriptor.configurable);\n\nvar FORCED_CONSTRUCTOR = ERROR_HAS_STACK && !BUGGY_DESCRIPTOR && !DOM_EXCEPTION_HAS_STACK;\n\n// `DOMException` constructor patch for `.stack` where it's required\n// https://webidl.spec.whatwg.org/#es-DOMException-specialness\n$({ global: true, constructor: true, forced: IS_PURE || FORCED_CONSTRUCTOR }, { // TODO: fix export logic\n DOMException: FORCED_CONSTRUCTOR ? $DOMException : NativeDOMException\n});\n\nvar PolyfilledDOMException = getBuiltIn(DOM_EXCEPTION);\nvar PolyfilledDOMExceptionPrototype = PolyfilledDOMException.prototype;\n\nif (PolyfilledDOMExceptionPrototype.constructor !== PolyfilledDOMException) {\n if (!IS_PURE) {\n defineProperty(PolyfilledDOMExceptionPrototype, 'constructor', createPropertyDescriptor(1, PolyfilledDOMException));\n }\n\n for (var key in DOMExceptionConstants) if (hasOwn(DOMExceptionConstants, key)) {\n var constant = DOMExceptionConstants[key];\n var constantName = constant.s;\n if (!hasOwn(PolyfilledDOMException, constantName)) {\n defineProperty(PolyfilledDOMException, constantName, createPropertyDescriptor(6, constant.c));\n }\n }\n}\n","'use strict';\nvar defineBuiltIn = require('../internals/define-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toString = require('../internals/to-string');\nvar validateArgumentsLength = require('../internals/validate-arguments-length');\n\nvar $URLSearchParams = URLSearchParams;\nvar URLSearchParamsPrototype = $URLSearchParams.prototype;\nvar append = uncurryThis(URLSearchParamsPrototype.append);\nvar $delete = uncurryThis(URLSearchParamsPrototype['delete']);\nvar forEach = uncurryThis(URLSearchParamsPrototype.forEach);\nvar push = uncurryThis([].push);\nvar params = new $URLSearchParams('a=1&a=2&b=3');\n\nparams['delete']('a', 1);\n// `undefined` case is a Chromium 117 bug\n// https://bugs.chromium.org/p/v8/issues/detail?id=14222\nparams['delete']('b', undefined);\n\nif (params + '' !== 'a=2') {\n defineBuiltIn(URLSearchParamsPrototype, 'delete', function (name /* , value */) {\n var length = arguments.length;\n var $value = length < 2 ? undefined : arguments[1];\n if (length && $value === undefined) return $delete(this, name);\n var entries = [];\n forEach(this, function (v, k) { // also validates `this`\n push(entries, { key: k, value: v });\n });\n validateArgumentsLength(length, 1);\n var key = toString(name);\n var value = toString($value);\n var index = 0;\n var dindex = 0;\n var found = false;\n var entriesLength = entries.length;\n var entry;\n while (index < entriesLength) {\n entry = entries[index++];\n if (found || entry.key === key) {\n found = true;\n $delete(this, entry.key);\n } else dindex++;\n }\n while (dindex < entriesLength) {\n entry = entries[dindex++];\n if (!(entry.key === key && entry.value === value)) append(this, entry.key, entry.value);\n }\n }, { enumerable: true, unsafe: true });\n}\n","'use strict';\nvar defineBuiltIn = require('../internals/define-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toString = require('../internals/to-string');\nvar validateArgumentsLength = require('../internals/validate-arguments-length');\n\nvar $URLSearchParams = URLSearchParams;\nvar URLSearchParamsPrototype = $URLSearchParams.prototype;\nvar getAll = uncurryThis(URLSearchParamsPrototype.getAll);\nvar $has = uncurryThis(URLSearchParamsPrototype.has);\nvar params = new $URLSearchParams('a=1');\n\n// `undefined` case is a Chromium 117 bug\n// https://bugs.chromium.org/p/v8/issues/detail?id=14222\nif (params.has('a', 2) || !params.has('a', undefined)) {\n defineBuiltIn(URLSearchParamsPrototype, 'has', function has(name /* , value */) {\n var length = arguments.length;\n var $value = length < 2 ? undefined : arguments[1];\n if (length && $value === undefined) return $has(this, name);\n var values = getAll(this, name); // also validates `this`\n validateArgumentsLength(length, 1);\n var value = toString($value);\n var index = 0;\n while (index < values.length) {\n if (values[index++] === value) return true;\n } return false;\n }, { enumerable: true, unsafe: true });\n}\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar defineBuiltInAccessor = require('../internals/define-built-in-accessor');\n\nvar URLSearchParamsPrototype = URLSearchParams.prototype;\nvar forEach = uncurryThis(URLSearchParamsPrototype.forEach);\n\n// `URLSearchParams.prototype.size` getter\n// https://github.com/whatwg/url/pull/734\nif (DESCRIPTORS && !('size' in URLSearchParamsPrototype)) {\n defineBuiltInAccessor(URLSearchParamsPrototype, 'size', {\n get: function size() {\n var count = 0;\n forEach(this, function () { count++; });\n return count;\n },\n configurable: true,\n enumerable: true\n });\n}\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/* globals process */\n\n// NW.js / Electron is a browser context, but copies some Node.js objects; see\n// http://docs.nwjs.io/en/latest/For%20Users/Advanced/JavaScript%20Contexts%20in%20NW.js/#access-nodejs-and-nwjs-api-in-browser-context\n// https://www.electronjs.org/docs/api/process#processversionselectron-readonly\n// https://www.electronjs.org/docs/api/process#processtype-readonly\nconst isNodeJS =\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"GENERIC\")) &&\n typeof process === \"object\" &&\n process + \"\" === \"[object process]\" &&\n !process.versions.nw &&\n !(process.versions.electron && process.type && process.type !== \"browser\");\n\nconst IDENTITY_MATRIX = [1, 0, 0, 1, 0, 0];\nconst FONT_IDENTITY_MATRIX = [0.001, 0, 0, 0.001, 0, 0];\n\nconst MAX_IMAGE_SIZE_TO_CACHE = 10e6; // Ten megabytes.\n\n// Represent the percentage of the height of a single-line field over\n// the font size. Acrobat seems to use this value.\nconst LINE_FACTOR = 1.35;\nconst LINE_DESCENT_FACTOR = 0.35;\nconst BASELINE_FACTOR = LINE_DESCENT_FACTOR / LINE_FACTOR;\n\n/**\n * Refer to the `WorkerTransport.getRenderingIntent`-method in the API, to see\n * how these flags are being used:\n * - ANY, DISPLAY, and PRINT are the normal rendering intents, note the\n * `PDFPageProxy.{render, getOperatorList, getAnnotations}`-methods.\n * - ANNOTATIONS_FORMS, ANNOTATIONS_STORAGE, ANNOTATIONS_DISABLE control which\n * annotations are rendered onto the canvas (i.e. by being included in the\n * operatorList), note the `PDFPageProxy.{render, getOperatorList}`-methods\n * and their `annotationMode`-option.\n * - OPLIST is used with the `PDFPageProxy.getOperatorList`-method, note the\n * `OperatorList`-constructor (on the worker-thread).\n */\nconst RenderingIntentFlag = {\n ANY: 0x01,\n DISPLAY: 0x02,\n PRINT: 0x04,\n SAVE: 0x08,\n ANNOTATIONS_FORMS: 0x10,\n ANNOTATIONS_STORAGE: 0x20,\n ANNOTATIONS_DISABLE: 0x40,\n OPLIST: 0x100,\n};\n\nconst AnnotationMode = {\n DISABLE: 0,\n ENABLE: 1,\n ENABLE_FORMS: 2,\n ENABLE_STORAGE: 3,\n};\n\nconst AnnotationEditorPrefix = \"pdfjs_internal_editor_\";\n\nconst AnnotationEditorType = {\n DISABLE: -1,\n NONE: 0,\n FREETEXT: 3,\n HIGHLIGHT: 9,\n STAMP: 13,\n INK: 15,\n};\n\nconst AnnotationEditorParamsType = {\n RESIZE: 1,\n CREATE: 2,\n FREETEXT_SIZE: 11,\n FREETEXT_COLOR: 12,\n FREETEXT_OPACITY: 13,\n INK_COLOR: 21,\n INK_THICKNESS: 22,\n INK_OPACITY: 23,\n HIGHLIGHT_COLOR: 31,\n HIGHLIGHT_DEFAULT_COLOR: 32,\n HIGHLIGHT_THICKNESS: 33,\n HIGHLIGHT_FREE: 34,\n HIGHLIGHT_SHOW_ALL: 35,\n};\n\n// Permission flags from Table 22, Section 7.6.3.2 of the PDF specification.\nconst PermissionFlag = {\n PRINT: 0x04,\n MODIFY_CONTENTS: 0x08,\n COPY: 0x10,\n MODIFY_ANNOTATIONS: 0x20,\n FILL_INTERACTIVE_FORMS: 0x100,\n COPY_FOR_ACCESSIBILITY: 0x200,\n ASSEMBLE: 0x400,\n PRINT_HIGH_QUALITY: 0x800,\n};\n\nconst TextRenderingMode = {\n FILL: 0,\n STROKE: 1,\n FILL_STROKE: 2,\n INVISIBLE: 3,\n FILL_ADD_TO_PATH: 4,\n STROKE_ADD_TO_PATH: 5,\n FILL_STROKE_ADD_TO_PATH: 6,\n ADD_TO_PATH: 7,\n FILL_STROKE_MASK: 3,\n ADD_TO_PATH_FLAG: 4,\n};\n\nconst ImageKind = {\n GRAYSCALE_1BPP: 1,\n RGB_24BPP: 2,\n RGBA_32BPP: 3,\n};\n\nconst AnnotationType = {\n TEXT: 1,\n LINK: 2,\n FREETEXT: 3,\n LINE: 4,\n SQUARE: 5,\n CIRCLE: 6,\n POLYGON: 7,\n POLYLINE: 8,\n HIGHLIGHT: 9,\n UNDERLINE: 10,\n SQUIGGLY: 11,\n STRIKEOUT: 12,\n STAMP: 13,\n CARET: 14,\n INK: 15,\n POPUP: 16,\n FILEATTACHMENT: 17,\n SOUND: 18,\n MOVIE: 19,\n WIDGET: 20,\n SCREEN: 21,\n PRINTERMARK: 22,\n TRAPNET: 23,\n WATERMARK: 24,\n THREED: 25,\n REDACT: 26,\n};\n\nconst AnnotationReplyType = {\n GROUP: \"Group\",\n REPLY: \"R\",\n};\n\nconst AnnotationFlag = {\n INVISIBLE: 0x01,\n HIDDEN: 0x02,\n PRINT: 0x04,\n NOZOOM: 0x08,\n NOROTATE: 0x10,\n NOVIEW: 0x20,\n READONLY: 0x40,\n LOCKED: 0x80,\n TOGGLENOVIEW: 0x100,\n LOCKEDCONTENTS: 0x200,\n};\n\nconst AnnotationFieldFlag = {\n READONLY: 0x0000001,\n REQUIRED: 0x0000002,\n NOEXPORT: 0x0000004,\n MULTILINE: 0x0001000,\n PASSWORD: 0x0002000,\n NOTOGGLETOOFF: 0x0004000,\n RADIO: 0x0008000,\n PUSHBUTTON: 0x0010000,\n COMBO: 0x0020000,\n EDIT: 0x0040000,\n SORT: 0x0080000,\n FILESELECT: 0x0100000,\n MULTISELECT: 0x0200000,\n DONOTSPELLCHECK: 0x0400000,\n DONOTSCROLL: 0x0800000,\n COMB: 0x1000000,\n RICHTEXT: 0x2000000,\n RADIOSINUNISON: 0x2000000,\n COMMITONSELCHANGE: 0x4000000,\n};\n\nconst AnnotationBorderStyleType = {\n SOLID: 1,\n DASHED: 2,\n BEVELED: 3,\n INSET: 4,\n UNDERLINE: 5,\n};\n\nconst AnnotationActionEventType = {\n E: \"Mouse Enter\",\n X: \"Mouse Exit\",\n D: \"Mouse Down\",\n U: \"Mouse Up\",\n Fo: \"Focus\",\n Bl: \"Blur\",\n PO: \"PageOpen\",\n PC: \"PageClose\",\n PV: \"PageVisible\",\n PI: \"PageInvisible\",\n K: \"Keystroke\",\n F: \"Format\",\n V: \"Validate\",\n C: \"Calculate\",\n};\n\nconst DocumentActionEventType = {\n WC: \"WillClose\",\n WS: \"WillSave\",\n DS: \"DidSave\",\n WP: \"WillPrint\",\n DP: \"DidPrint\",\n};\n\nconst PageActionEventType = {\n O: \"PageOpen\",\n C: \"PageClose\",\n};\n\nconst VerbosityLevel = {\n ERRORS: 0,\n WARNINGS: 1,\n INFOS: 5,\n};\n\nconst CMapCompressionType = {\n NONE: 0,\n BINARY: 1,\n};\n\n// All the possible operations for an operator list.\nconst OPS = {\n // Intentionally start from 1 so it is easy to spot bad operators that will be\n // 0's.\n // PLEASE NOTE: We purposely keep any removed operators commented out, since\n // re-numbering the list would risk breaking third-party users.\n dependency: 1,\n setLineWidth: 2,\n setLineCap: 3,\n setLineJoin: 4,\n setMiterLimit: 5,\n setDash: 6,\n setRenderingIntent: 7,\n setFlatness: 8,\n setGState: 9,\n save: 10,\n restore: 11,\n transform: 12,\n moveTo: 13,\n lineTo: 14,\n curveTo: 15,\n curveTo2: 16,\n curveTo3: 17,\n closePath: 18,\n rectangle: 19,\n stroke: 20,\n closeStroke: 21,\n fill: 22,\n eoFill: 23,\n fillStroke: 24,\n eoFillStroke: 25,\n closeFillStroke: 26,\n closeEOFillStroke: 27,\n endPath: 28,\n clip: 29,\n eoClip: 30,\n beginText: 31,\n endText: 32,\n setCharSpacing: 33,\n setWordSpacing: 34,\n setHScale: 35,\n setLeading: 36,\n setFont: 37,\n setTextRenderingMode: 38,\n setTextRise: 39,\n moveText: 40,\n setLeadingMoveText: 41,\n setTextMatrix: 42,\n nextLine: 43,\n showText: 44,\n showSpacedText: 45,\n nextLineShowText: 46,\n nextLineSetSpacingShowText: 47,\n setCharWidth: 48,\n setCharWidthAndBounds: 49,\n setStrokeColorSpace: 50,\n setFillColorSpace: 51,\n setStrokeColor: 52,\n setStrokeColorN: 53,\n setFillColor: 54,\n setFillColorN: 55,\n setStrokeGray: 56,\n setFillGray: 57,\n setStrokeRGBColor: 58,\n setFillRGBColor: 59,\n setStrokeCMYKColor: 60,\n setFillCMYKColor: 61,\n shadingFill: 62,\n beginInlineImage: 63,\n beginImageData: 64,\n endInlineImage: 65,\n paintXObject: 66,\n markPoint: 67,\n markPointProps: 68,\n beginMarkedContent: 69,\n beginMarkedContentProps: 70,\n endMarkedContent: 71,\n beginCompat: 72,\n endCompat: 73,\n paintFormXObjectBegin: 74,\n paintFormXObjectEnd: 75,\n beginGroup: 76,\n endGroup: 77,\n // beginAnnotations: 78,\n // endAnnotations: 79,\n beginAnnotation: 80,\n endAnnotation: 81,\n // paintJpegXObject: 82,\n paintImageMaskXObject: 83,\n paintImageMaskXObjectGroup: 84,\n paintImageXObject: 85,\n paintInlineImageXObject: 86,\n paintInlineImageXObjectGroup: 87,\n paintImageXObjectRepeat: 88,\n paintImageMaskXObjectRepeat: 89,\n paintSolidColorImageMask: 90,\n constructPath: 91,\n};\n\nconst PasswordResponses = {\n NEED_PASSWORD: 1,\n INCORRECT_PASSWORD: 2,\n};\n\nlet verbosity = VerbosityLevel.WARNINGS;\n\nfunction setVerbosityLevel(level) {\n if (Number.isInteger(level)) {\n verbosity = level;\n }\n}\n\nfunction getVerbosityLevel() {\n return verbosity;\n}\n\n// A notice for devs. These are good for things that are helpful to devs, such\n// as warning that Workers were disabled, which is important to devs but not\n// end users.\nfunction info(msg) {\n if (verbosity >= VerbosityLevel.INFOS) {\n console.log(`Info: ${msg}`);\n }\n}\n\n// Non-fatal warnings.\nfunction warn(msg) {\n if (verbosity >= VerbosityLevel.WARNINGS) {\n console.log(`Warning: ${msg}`);\n }\n}\n\nfunction unreachable(msg) {\n throw new Error(msg);\n}\n\nfunction assert(cond, msg) {\n if (!cond) {\n unreachable(msg);\n }\n}\n\n// Checks if URLs use one of the allowed protocols, e.g. to avoid XSS.\nfunction _isValidProtocol(url) {\n switch (url?.protocol) {\n case \"http:\":\n case \"https:\":\n case \"ftp:\":\n case \"mailto:\":\n case \"tel:\":\n return true;\n default:\n return false;\n }\n}\n\n/**\n * Attempts to create a valid absolute URL.\n *\n * @param {URL|string} url - An absolute, or relative, URL.\n * @param {URL|string} [baseUrl] - An absolute URL.\n * @param {Object} [options]\n * @returns Either a valid {URL}, or `null` otherwise.\n */\nfunction createValidAbsoluteUrl(url, baseUrl = null, options = null) {\n if (!url) {\n return null;\n }\n try {\n if (options && typeof url === \"string\") {\n // Let URLs beginning with \"www.\" default to using the \"http://\" protocol.\n if (options.addDefaultProtocol && url.startsWith(\"www.\")) {\n const dots = url.match(/\\./g);\n // Avoid accidentally matching a *relative* URL pointing to a file named\n // e.g. \"www.pdf\" or similar.\n if (dots?.length >= 2) {\n url = `http://${url}`;\n }\n }\n\n // According to ISO 32000-1:2008, section 12.6.4.7, URIs should be encoded\n // in 7-bit ASCII. Some bad PDFs use UTF-8 encoding; see bug 1122280.\n if (options.tryConvertEncoding) {\n try {\n url = stringToUTF8String(url);\n } catch {}\n }\n }\n\n const absoluteUrl = baseUrl ? new URL(url, baseUrl) : new URL(url);\n if (_isValidProtocol(absoluteUrl)) {\n return absoluteUrl;\n }\n } catch {\n /* `new URL()` will throw on incorrect data. */\n }\n return null;\n}\n\nfunction shadow(obj, prop, value, nonSerializable = false) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n prop in obj,\n `shadow: Property \"${prop && prop.toString()}\" not found in object.`\n );\n }\n Object.defineProperty(obj, prop, {\n value,\n enumerable: !nonSerializable,\n configurable: true,\n writable: false,\n });\n return value;\n}\n\n/**\n * @type {any}\n */\nconst BaseException = (function BaseExceptionClosure() {\n // eslint-disable-next-line no-shadow\n function BaseException(message, name) {\n if (this.constructor === BaseException) {\n unreachable(\"Cannot initialize BaseException.\");\n }\n this.message = message;\n this.name = name;\n }\n BaseException.prototype = new Error();\n BaseException.constructor = BaseException;\n\n return BaseException;\n})();\n\nclass PasswordException extends BaseException {\n constructor(msg, code) {\n super(msg, \"PasswordException\");\n this.code = code;\n }\n}\n\nclass UnknownErrorException extends BaseException {\n constructor(msg, details) {\n super(msg, \"UnknownErrorException\");\n this.details = details;\n }\n}\n\nclass InvalidPDFException extends BaseException {\n constructor(msg) {\n super(msg, \"InvalidPDFException\");\n }\n}\n\nclass MissingPDFException extends BaseException {\n constructor(msg) {\n super(msg, \"MissingPDFException\");\n }\n}\n\nclass UnexpectedResponseException extends BaseException {\n constructor(msg, status) {\n super(msg, \"UnexpectedResponseException\");\n this.status = status;\n }\n}\n\n/**\n * Error caused during parsing PDF data.\n */\nclass FormatError extends BaseException {\n constructor(msg) {\n super(msg, \"FormatError\");\n }\n}\n\n/**\n * Error used to indicate task cancellation.\n */\nclass AbortException extends BaseException {\n constructor(msg) {\n super(msg, \"AbortException\");\n }\n}\n\nfunction bytesToString(bytes) {\n if (typeof bytes !== \"object\" || bytes?.length === undefined) {\n unreachable(\"Invalid argument for bytesToString\");\n }\n const length = bytes.length;\n const MAX_ARGUMENT_COUNT = 8192;\n if (length < MAX_ARGUMENT_COUNT) {\n return String.fromCharCode.apply(null, bytes);\n }\n const strBuf = [];\n for (let i = 0; i < length; i += MAX_ARGUMENT_COUNT) {\n const chunkEnd = Math.min(i + MAX_ARGUMENT_COUNT, length);\n const chunk = bytes.subarray(i, chunkEnd);\n strBuf.push(String.fromCharCode.apply(null, chunk));\n }\n return strBuf.join(\"\");\n}\n\nfunction stringToBytes(str) {\n if (typeof str !== \"string\") {\n unreachable(\"Invalid argument for stringToBytes\");\n }\n const length = str.length;\n const bytes = new Uint8Array(length);\n for (let i = 0; i < length; ++i) {\n bytes[i] = str.charCodeAt(i) & 0xff;\n }\n return bytes;\n}\n\nfunction string32(value) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n typeof value === \"number\" && Math.abs(value) < 2 ** 32,\n `string32: Unexpected input \"${value}\".`\n );\n }\n return String.fromCharCode(\n (value >> 24) & 0xff,\n (value >> 16) & 0xff,\n (value >> 8) & 0xff,\n value & 0xff\n );\n}\n\nfunction objectSize(obj) {\n return Object.keys(obj).length;\n}\n\n// Ensure that the returned Object has a `null` prototype; hence why\n// `Object.fromEntries(...)` is not used.\nfunction objectFromMap(map) {\n const obj = Object.create(null);\n for (const [key, value] of map) {\n obj[key] = value;\n }\n return obj;\n}\n\n// Checks the endianness of the platform.\nfunction isLittleEndian() {\n const buffer8 = new Uint8Array(4);\n buffer8[0] = 1;\n const view32 = new Uint32Array(buffer8.buffer, 0, 1);\n return view32[0] === 1;\n}\n\n// Checks if it's possible to eval JS expressions.\nfunction isEvalSupported() {\n try {\n new Function(\"\"); // eslint-disable-line no-new, no-new-func\n return true;\n } catch {\n return false;\n }\n}\n\nclass FeatureTest {\n static get isLittleEndian() {\n return shadow(this, \"isLittleEndian\", isLittleEndian());\n }\n\n static get isEvalSupported() {\n return shadow(this, \"isEvalSupported\", isEvalSupported());\n }\n\n static get isOffscreenCanvasSupported() {\n return shadow(\n this,\n \"isOffscreenCanvasSupported\",\n typeof OffscreenCanvas !== \"undefined\"\n );\n }\n\n static get platform() {\n if (\n (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) ||\n (typeof navigator !== \"undefined\" &&\n typeof navigator?.platform === \"string\")\n ) {\n return shadow(this, \"platform\", {\n isMac: navigator.platform.includes(\"Mac\"),\n });\n }\n return shadow(this, \"platform\", { isMac: false });\n }\n\n static get isCSSRoundSupported() {\n return shadow(\n this,\n \"isCSSRoundSupported\",\n globalThis.CSS?.supports?.(\"width: round(1.5px, 1px)\")\n );\n }\n}\n\nconst hexNumbers = Array.from(Array(256).keys(), n =>\n n.toString(16).padStart(2, \"0\")\n);\n\nclass Util {\n static makeHexColor(r, g, b) {\n return `#${hexNumbers[r]}${hexNumbers[g]}${hexNumbers[b]}`;\n }\n\n // Apply a scaling matrix to some min/max values.\n // If a scaling factor is negative then min and max must be\n // swapped.\n static scaleMinMax(transform, minMax) {\n let temp;\n if (transform[0]) {\n if (transform[0] < 0) {\n temp = minMax[0];\n minMax[0] = minMax[2];\n minMax[2] = temp;\n }\n minMax[0] *= transform[0];\n minMax[2] *= transform[0];\n\n if (transform[3] < 0) {\n temp = minMax[1];\n minMax[1] = minMax[3];\n minMax[3] = temp;\n }\n minMax[1] *= transform[3];\n minMax[3] *= transform[3];\n } else {\n temp = minMax[0];\n minMax[0] = minMax[1];\n minMax[1] = temp;\n temp = minMax[2];\n minMax[2] = minMax[3];\n minMax[3] = temp;\n\n if (transform[1] < 0) {\n temp = minMax[1];\n minMax[1] = minMax[3];\n minMax[3] = temp;\n }\n minMax[1] *= transform[1];\n minMax[3] *= transform[1];\n\n if (transform[2] < 0) {\n temp = minMax[0];\n minMax[0] = minMax[2];\n minMax[2] = temp;\n }\n minMax[0] *= transform[2];\n minMax[2] *= transform[2];\n }\n minMax[0] += transform[4];\n minMax[1] += transform[5];\n minMax[2] += transform[4];\n minMax[3] += transform[5];\n }\n\n // Concatenates two transformation matrices together and returns the result.\n static transform(m1, m2) {\n return [\n m1[0] * m2[0] + m1[2] * m2[1],\n m1[1] * m2[0] + m1[3] * m2[1],\n m1[0] * m2[2] + m1[2] * m2[3],\n m1[1] * m2[2] + m1[3] * m2[3],\n m1[0] * m2[4] + m1[2] * m2[5] + m1[4],\n m1[1] * m2[4] + m1[3] * m2[5] + m1[5],\n ];\n }\n\n // For 2d affine transforms\n static applyTransform(p, m) {\n const xt = p[0] * m[0] + p[1] * m[2] + m[4];\n const yt = p[0] * m[1] + p[1] * m[3] + m[5];\n return [xt, yt];\n }\n\n static applyInverseTransform(p, m) {\n const d = m[0] * m[3] - m[1] * m[2];\n const xt = (p[0] * m[3] - p[1] * m[2] + m[2] * m[5] - m[4] * m[3]) / d;\n const yt = (-p[0] * m[1] + p[1] * m[0] + m[4] * m[1] - m[5] * m[0]) / d;\n return [xt, yt];\n }\n\n // Applies the transform to the rectangle and finds the minimum axially\n // aligned bounding box.\n static getAxialAlignedBoundingBox(r, m) {\n const p1 = this.applyTransform(r, m);\n const p2 = this.applyTransform(r.slice(2, 4), m);\n const p3 = this.applyTransform([r[0], r[3]], m);\n const p4 = this.applyTransform([r[2], r[1]], m);\n return [\n Math.min(p1[0], p2[0], p3[0], p4[0]),\n Math.min(p1[1], p2[1], p3[1], p4[1]),\n Math.max(p1[0], p2[0], p3[0], p4[0]),\n Math.max(p1[1], p2[1], p3[1], p4[1]),\n ];\n }\n\n static inverseTransform(m) {\n const d = m[0] * m[3] - m[1] * m[2];\n return [\n m[3] / d,\n -m[1] / d,\n -m[2] / d,\n m[0] / d,\n (m[2] * m[5] - m[4] * m[3]) / d,\n (m[4] * m[1] - m[5] * m[0]) / d,\n ];\n }\n\n // This calculation uses Singular Value Decomposition.\n // The SVD can be represented with formula A = USV. We are interested in the\n // matrix S here because it represents the scale values.\n static singularValueDecompose2dScale(m) {\n const transpose = [m[0], m[2], m[1], m[3]];\n\n // Multiply matrix m with its transpose.\n const a = m[0] * transpose[0] + m[1] * transpose[2];\n const b = m[0] * transpose[1] + m[1] * transpose[3];\n const c = m[2] * transpose[0] + m[3] * transpose[2];\n const d = m[2] * transpose[1] + m[3] * transpose[3];\n\n // Solve the second degree polynomial to get roots.\n const first = (a + d) / 2;\n const second = Math.sqrt((a + d) ** 2 - 4 * (a * d - c * b)) / 2;\n const sx = first + second || 1;\n const sy = first - second || 1;\n\n // Scale values are the square roots of the eigenvalues.\n return [Math.sqrt(sx), Math.sqrt(sy)];\n }\n\n // Normalize rectangle rect=[x1, y1, x2, y2] so that (x1,y1) < (x2,y2)\n // For coordinate systems whose origin lies in the bottom-left, this\n // means normalization to (BL,TR) ordering. For systems with origin in the\n // top-left, this means (TL,BR) ordering.\n static normalizeRect(rect) {\n const r = rect.slice(0); // clone rect\n if (rect[0] > rect[2]) {\n r[0] = rect[2];\n r[2] = rect[0];\n }\n if (rect[1] > rect[3]) {\n r[1] = rect[3];\n r[3] = rect[1];\n }\n return r;\n }\n\n // Returns a rectangle [x1, y1, x2, y2] corresponding to the\n // intersection of rect1 and rect2. If no intersection, returns 'null'\n // The rectangle coordinates of rect1, rect2 should be [x1, y1, x2, y2]\n static intersect(rect1, rect2) {\n const xLow = Math.max(\n Math.min(rect1[0], rect1[2]),\n Math.min(rect2[0], rect2[2])\n );\n const xHigh = Math.min(\n Math.max(rect1[0], rect1[2]),\n Math.max(rect2[0], rect2[2])\n );\n if (xLow > xHigh) {\n return null;\n }\n const yLow = Math.max(\n Math.min(rect1[1], rect1[3]),\n Math.min(rect2[1], rect2[3])\n );\n const yHigh = Math.min(\n Math.max(rect1[1], rect1[3]),\n Math.max(rect2[1], rect2[3])\n );\n if (yLow > yHigh) {\n return null;\n }\n\n return [xLow, yLow, xHigh, yHigh];\n }\n\n static #getExtremumOnCurve(x0, x1, x2, x3, y0, y1, y2, y3, t, minMax) {\n if (t <= 0 || t >= 1) {\n return;\n }\n const mt = 1 - t;\n const tt = t * t;\n const ttt = tt * t;\n const x = mt * (mt * (mt * x0 + 3 * t * x1) + 3 * tt * x2) + ttt * x3;\n const y = mt * (mt * (mt * y0 + 3 * t * y1) + 3 * tt * y2) + ttt * y3;\n minMax[0] = Math.min(minMax[0], x);\n minMax[1] = Math.min(minMax[1], y);\n minMax[2] = Math.max(minMax[2], x);\n minMax[3] = Math.max(minMax[3], y);\n }\n\n static #getExtremum(x0, x1, x2, x3, y0, y1, y2, y3, a, b, c, minMax) {\n if (Math.abs(a) < 1e-12) {\n if (Math.abs(b) >= 1e-12) {\n this.#getExtremumOnCurve(\n x0,\n x1,\n x2,\n x3,\n y0,\n y1,\n y2,\n y3,\n -c / b,\n minMax\n );\n }\n return;\n }\n\n const delta = b ** 2 - 4 * c * a;\n if (delta < 0) {\n return;\n }\n const sqrtDelta = Math.sqrt(delta);\n const a2 = 2 * a;\n this.#getExtremumOnCurve(\n x0,\n x1,\n x2,\n x3,\n y0,\n y1,\n y2,\n y3,\n (-b + sqrtDelta) / a2,\n minMax\n );\n this.#getExtremumOnCurve(\n x0,\n x1,\n x2,\n x3,\n y0,\n y1,\n y2,\n y3,\n (-b - sqrtDelta) / a2,\n minMax\n );\n }\n\n // From https://github.com/adobe-webplatform/Snap.svg/blob/b365287722a72526000ac4bfcf0ce4cac2faa015/src/path.js#L852\n static bezierBoundingBox(x0, y0, x1, y1, x2, y2, x3, y3, minMax) {\n if (minMax) {\n minMax[0] = Math.min(minMax[0], x0, x3);\n minMax[1] = Math.min(minMax[1], y0, y3);\n minMax[2] = Math.max(minMax[2], x0, x3);\n minMax[3] = Math.max(minMax[3], y0, y3);\n } else {\n minMax = [\n Math.min(x0, x3),\n Math.min(y0, y3),\n Math.max(x0, x3),\n Math.max(y0, y3),\n ];\n }\n this.#getExtremum(\n x0,\n x1,\n x2,\n x3,\n y0,\n y1,\n y2,\n y3,\n 3 * (-x0 + 3 * (x1 - x2) + x3),\n 6 * (x0 - 2 * x1 + x2),\n 3 * (x1 - x0),\n minMax\n );\n this.#getExtremum(\n x0,\n x1,\n x2,\n x3,\n y0,\n y1,\n y2,\n y3,\n 3 * (-y0 + 3 * (y1 - y2) + y3),\n 6 * (y0 - 2 * y1 + y2),\n 3 * (y1 - y0),\n minMax\n );\n return minMax;\n }\n}\n\nconst PDFStringTranslateTable = [\n 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x2d8,\n 0x2c7, 0x2c6, 0x2d9, 0x2dd, 0x2db, 0x2da, 0x2dc, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n 0, 0, 0, 0, 0, 0, 0, 0, 0x2022, 0x2020, 0x2021, 0x2026, 0x2014, 0x2013, 0x192,\n 0x2044, 0x2039, 0x203a, 0x2212, 0x2030, 0x201e, 0x201c, 0x201d, 0x2018,\n 0x2019, 0x201a, 0x2122, 0xfb01, 0xfb02, 0x141, 0x152, 0x160, 0x178, 0x17d,\n 0x131, 0x142, 0x153, 0x161, 0x17e, 0, 0x20ac,\n];\n\nfunction stringToPDFString(str) {\n // See section 7.9.2.2 Text String Type.\n // The string can contain some language codes bracketed with 0x0b,\n // so we must remove them.\n if (str[0] >= \"\\xEF\") {\n let encoding;\n if (str[0] === \"\\xFE\" && str[1] === \"\\xFF\") {\n encoding = \"utf-16be\";\n if (str.length % 2 === 1) {\n str = str.slice(0, -1);\n }\n } else if (str[0] === \"\\xFF\" && str[1] === \"\\xFE\") {\n encoding = \"utf-16le\";\n if (str.length % 2 === 1) {\n str = str.slice(0, -1);\n }\n } else if (str[0] === \"\\xEF\" && str[1] === \"\\xBB\" && str[2] === \"\\xBF\") {\n encoding = \"utf-8\";\n }\n\n if (encoding) {\n try {\n const decoder = new TextDecoder(encoding, { fatal: true });\n const buffer = stringToBytes(str);\n const decoded = decoder.decode(buffer);\n if (!decoded.includes(\"\\x1b\")) {\n return decoded;\n }\n return decoded.replaceAll(/\\x1b[^\\x1b]*(?:\\x1b|$)/g, \"\");\n } catch (ex) {\n warn(`stringToPDFString: \"${ex}\".`);\n }\n }\n }\n // ISO Latin 1\n const strBuf = [];\n for (let i = 0, ii = str.length; i < ii; i++) {\n const charCode = str.charCodeAt(i);\n if (charCode === 0x1b) {\n // eslint-disable-next-line no-empty\n while (++i < ii && str.charCodeAt(i) !== 0x1b) {}\n continue;\n }\n const code = PDFStringTranslateTable[charCode];\n strBuf.push(code ? String.fromCharCode(code) : str.charAt(i));\n }\n return strBuf.join(\"\");\n}\n\nfunction stringToUTF8String(str) {\n return decodeURIComponent(escape(str));\n}\n\nfunction utf8StringToString(str) {\n return unescape(encodeURIComponent(str));\n}\n\nfunction isArrayEqual(arr1, arr2) {\n if (arr1.length !== arr2.length) {\n return false;\n }\n for (let i = 0, ii = arr1.length; i < ii; i++) {\n if (arr1[i] !== arr2[i]) {\n return false;\n }\n }\n return true;\n}\n\nfunction getModificationDate(date = new Date()) {\n const buffer = [\n date.getUTCFullYear().toString(),\n (date.getUTCMonth() + 1).toString().padStart(2, \"0\"),\n date.getUTCDate().toString().padStart(2, \"0\"),\n date.getUTCHours().toString().padStart(2, \"0\"),\n date.getUTCMinutes().toString().padStart(2, \"0\"),\n date.getUTCSeconds().toString().padStart(2, \"0\"),\n ];\n\n return buffer.join(\"\");\n}\n\nlet NormalizeRegex = null;\nlet NormalizationMap = null;\nfunction normalizeUnicode(str) {\n if (!NormalizeRegex) {\n // In order to generate the following regex:\n // - create a PDF containing all the chars in the range 0000-FFFF with\n // a NFKC which is different of the char.\n // - copy and paste all those chars and get the ones where NFKC is\n // required.\n // It appears that most the chars here contain some ligatures.\n NormalizeRegex =\n /([\\u00a0\\u00b5\\u037e\\u0eb3\\u2000-\\u200a\\u202f\\u2126\\ufb00-\\ufb04\\ufb06\\ufb20-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40-\\ufb41\\ufb43-\\ufb44\\ufb46-\\ufba1\\ufba4-\\ufba9\\ufbae-\\ufbb1\\ufbd3-\\ufbdc\\ufbde-\\ufbe7\\ufbea-\\ufbf8\\ufbfc-\\ufbfd\\ufc00-\\ufc5d\\ufc64-\\ufcf1\\ufcf5-\\ufd3d\\ufd88\\ufdf4\\ufdfa-\\ufdfb\\ufe71\\ufe77\\ufe79\\ufe7b\\ufe7d]+)|(\\ufb05+)/gu;\n NormalizationMap = new Map([[\"ſt\", \"ſt\"]]);\n }\n return str.replaceAll(NormalizeRegex, (_, p1, p2) =>\n p1 ? p1.normalize(\"NFKC\") : NormalizationMap.get(p2)\n );\n}\n\nfunction getUuid() {\n if (\n (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) ||\n (typeof crypto !== \"undefined\" && typeof crypto?.randomUUID === \"function\")\n ) {\n return crypto.randomUUID();\n }\n const buf = new Uint8Array(32);\n if (\n typeof crypto !== \"undefined\" &&\n typeof crypto?.getRandomValues === \"function\"\n ) {\n crypto.getRandomValues(buf);\n } else {\n for (let i = 0; i < 32; i++) {\n buf[i] = Math.floor(Math.random() * 255);\n }\n }\n return bytesToString(buf);\n}\n\nconst AnnotationPrefix = \"pdfjs_internal_id_\";\n\nconst FontRenderOps = {\n BEZIER_CURVE_TO: 0,\n MOVE_TO: 1,\n LINE_TO: 2,\n QUADRATIC_CURVE_TO: 3,\n RESTORE: 4,\n SAVE: 5,\n SCALE: 6,\n TRANSFORM: 7,\n TRANSLATE: 8,\n};\n\nexport {\n AbortException,\n AnnotationActionEventType,\n AnnotationBorderStyleType,\n AnnotationEditorParamsType,\n AnnotationEditorPrefix,\n AnnotationEditorType,\n AnnotationFieldFlag,\n AnnotationFlag,\n AnnotationMode,\n AnnotationPrefix,\n AnnotationReplyType,\n AnnotationType,\n assert,\n BaseException,\n BASELINE_FACTOR,\n bytesToString,\n CMapCompressionType,\n createValidAbsoluteUrl,\n DocumentActionEventType,\n FeatureTest,\n FONT_IDENTITY_MATRIX,\n FontRenderOps,\n FormatError,\n getModificationDate,\n getUuid,\n getVerbosityLevel,\n IDENTITY_MATRIX,\n ImageKind,\n info,\n InvalidPDFException,\n isArrayEqual,\n isNodeJS,\n LINE_DESCENT_FACTOR,\n LINE_FACTOR,\n MAX_IMAGE_SIZE_TO_CACHE,\n MissingPDFException,\n normalizeUnicode,\n objectFromMap,\n objectSize,\n OPS,\n PageActionEventType,\n PasswordException,\n PasswordResponses,\n PermissionFlag,\n RenderingIntentFlag,\n setVerbosityLevel,\n shadow,\n string32,\n stringToBytes,\n stringToPDFString,\n stringToUTF8String,\n TextRenderingMode,\n UnexpectedResponseException,\n UnknownErrorException,\n unreachable,\n utf8StringToString,\n Util,\n VerbosityLevel,\n warn,\n};\n","/* Copyright 2015 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { CMapCompressionType, unreachable } from \"../shared/util.js\";\n\nclass BaseFilterFactory {\n constructor() {\n if (this.constructor === BaseFilterFactory) {\n unreachable(\"Cannot initialize BaseFilterFactory.\");\n }\n }\n\n addFilter(maps) {\n return \"none\";\n }\n\n addHCMFilter(fgColor, bgColor) {\n return \"none\";\n }\n\n addAlphaFilter(map) {\n return \"none\";\n }\n\n addLuminosityFilter(map) {\n return \"none\";\n }\n\n addHighlightHCMFilter(filterName, fgColor, bgColor, newFgColor, newBgColor) {\n return \"none\";\n }\n\n destroy(keepHCM = false) {}\n}\n\nclass BaseCanvasFactory {\n #enableHWA = false;\n\n constructor({ enableHWA = false } = {}) {\n if (this.constructor === BaseCanvasFactory) {\n unreachable(\"Cannot initialize BaseCanvasFactory.\");\n }\n this.#enableHWA = enableHWA;\n }\n\n create(width, height) {\n if (width <= 0 || height <= 0) {\n throw new Error(\"Invalid canvas size\");\n }\n const canvas = this._createCanvas(width, height);\n return {\n canvas,\n context: canvas.getContext(\"2d\", {\n willReadFrequently: !this.#enableHWA,\n }),\n };\n }\n\n reset(canvasAndContext, width, height) {\n if (!canvasAndContext.canvas) {\n throw new Error(\"Canvas is not specified\");\n }\n if (width <= 0 || height <= 0) {\n throw new Error(\"Invalid canvas size\");\n }\n canvasAndContext.canvas.width = width;\n canvasAndContext.canvas.height = height;\n }\n\n destroy(canvasAndContext) {\n if (!canvasAndContext.canvas) {\n throw new Error(\"Canvas is not specified\");\n }\n // Zeroing the width and height cause Firefox to release graphics\n // resources immediately, which can greatly reduce memory consumption.\n canvasAndContext.canvas.width = 0;\n canvasAndContext.canvas.height = 0;\n canvasAndContext.canvas = null;\n canvasAndContext.context = null;\n }\n\n /**\n * @ignore\n */\n _createCanvas(width, height) {\n unreachable(\"Abstract method `_createCanvas` called.\");\n }\n}\n\nclass BaseCMapReaderFactory {\n constructor({ baseUrl = null, isCompressed = true }) {\n if (this.constructor === BaseCMapReaderFactory) {\n unreachable(\"Cannot initialize BaseCMapReaderFactory.\");\n }\n this.baseUrl = baseUrl;\n this.isCompressed = isCompressed;\n }\n\n async fetch({ name }) {\n if (!this.baseUrl) {\n throw new Error(\n 'The CMap \"baseUrl\" parameter must be specified, ensure that ' +\n 'the \"cMapUrl\" and \"cMapPacked\" API parameters are provided.'\n );\n }\n if (!name) {\n throw new Error(\"CMap name must be specified.\");\n }\n const url = this.baseUrl + name + (this.isCompressed ? \".bcmap\" : \"\");\n const compressionType = this.isCompressed\n ? CMapCompressionType.BINARY\n : CMapCompressionType.NONE;\n\n return this._fetchData(url, compressionType).catch(reason => {\n throw new Error(\n `Unable to load ${this.isCompressed ? \"binary \" : \"\"}CMap at: ${url}`\n );\n });\n }\n\n /**\n * @ignore\n */\n _fetchData(url, compressionType) {\n unreachable(\"Abstract method `_fetchData` called.\");\n }\n}\n\nclass BaseStandardFontDataFactory {\n constructor({ baseUrl = null }) {\n if (this.constructor === BaseStandardFontDataFactory) {\n unreachable(\"Cannot initialize BaseStandardFontDataFactory.\");\n }\n this.baseUrl = baseUrl;\n }\n\n async fetch({ filename }) {\n if (!this.baseUrl) {\n throw new Error(\n 'The standard font \"baseUrl\" parameter must be specified, ensure that ' +\n 'the \"standardFontDataUrl\" API parameter is provided.'\n );\n }\n if (!filename) {\n throw new Error(\"Font filename must be specified.\");\n }\n const url = `${this.baseUrl}${filename}`;\n\n return this._fetchData(url).catch(reason => {\n throw new Error(`Unable to load font data at: ${url}`);\n });\n }\n\n /**\n * @ignore\n */\n _fetchData(url) {\n unreachable(\"Abstract method `_fetchData` called.\");\n }\n}\n\nclass BaseSVGFactory {\n constructor() {\n if (this.constructor === BaseSVGFactory) {\n unreachable(\"Cannot initialize BaseSVGFactory.\");\n }\n }\n\n create(width, height, skipDimensions = false) {\n if (width <= 0 || height <= 0) {\n throw new Error(\"Invalid SVG dimensions\");\n }\n const svg = this._createSVG(\"svg:svg\");\n svg.setAttribute(\"version\", \"1.1\");\n\n if (!skipDimensions) {\n svg.setAttribute(\"width\", `${width}px`);\n svg.setAttribute(\"height\", `${height}px`);\n }\n\n svg.setAttribute(\"preserveAspectRatio\", \"none\");\n svg.setAttribute(\"viewBox\", `0 0 ${width} ${height}`);\n\n return svg;\n }\n\n createElement(type) {\n if (typeof type !== \"string\") {\n throw new Error(\"Invalid SVG element type\");\n }\n return this._createSVG(type);\n }\n\n /**\n * @ignore\n */\n _createSVG(type) {\n unreachable(\"Abstract method `_createSVG` called.\");\n }\n}\n\nexport {\n BaseCanvasFactory,\n BaseCMapReaderFactory,\n BaseFilterFactory,\n BaseStandardFontDataFactory,\n BaseSVGFactory,\n};\n","/* Copyright 2015 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n BaseCanvasFactory,\n BaseCMapReaderFactory,\n BaseFilterFactory,\n BaseStandardFontDataFactory,\n BaseSVGFactory,\n} from \"./base_factory.js\";\nimport {\n BaseException,\n FeatureTest,\n shadow,\n stringToBytes,\n Util,\n warn,\n} from \"../shared/util.js\";\n\nconst SVG_NS = \"http://www.w3.org/2000/svg\";\n\nclass PixelsPerInch {\n static CSS = 96.0;\n\n static PDF = 72.0;\n\n static PDF_TO_CSS_UNITS = this.CSS / this.PDF;\n}\n\n/**\n * FilterFactory aims to create some SVG filters we can use when drawing an\n * image (or whatever) on a canvas.\n * Filters aren't applied with ctx.putImageData because it just overwrites the\n * underlying pixels.\n * With these filters, it's possible for example to apply some transfer maps on\n * an image without the need to apply them on the pixel arrays: the renderer\n * does the magic for us.\n */\nclass DOMFilterFactory extends BaseFilterFactory {\n #_cache;\n\n #_defs;\n\n #docId;\n\n #document;\n\n #_hcmCache;\n\n #id = 0;\n\n constructor({ docId, ownerDocument = globalThis.document } = {}) {\n super();\n this.#docId = docId;\n this.#document = ownerDocument;\n }\n\n get #cache() {\n return (this.#_cache ||= new Map());\n }\n\n get #hcmCache() {\n return (this.#_hcmCache ||= new Map());\n }\n\n get #defs() {\n if (!this.#_defs) {\n const div = this.#document.createElement(\"div\");\n const { style } = div;\n style.visibility = \"hidden\";\n style.contain = \"strict\";\n style.width = style.height = 0;\n style.position = \"absolute\";\n style.top = style.left = 0;\n style.zIndex = -1;\n\n const svg = this.#document.createElementNS(SVG_NS, \"svg\");\n svg.setAttribute(\"width\", 0);\n svg.setAttribute(\"height\", 0);\n this.#_defs = this.#document.createElementNS(SVG_NS, \"defs\");\n div.append(svg);\n svg.append(this.#_defs);\n this.#document.body.append(div);\n }\n return this.#_defs;\n }\n\n #createTables(maps) {\n if (maps.length === 1) {\n const mapR = maps[0];\n const buffer = new Array(256);\n for (let i = 0; i < 256; i++) {\n buffer[i] = mapR[i] / 255;\n }\n\n const table = buffer.join(\",\");\n return [table, table, table];\n }\n\n const [mapR, mapG, mapB] = maps;\n const bufferR = new Array(256);\n const bufferG = new Array(256);\n const bufferB = new Array(256);\n for (let i = 0; i < 256; i++) {\n bufferR[i] = mapR[i] / 255;\n bufferG[i] = mapG[i] / 255;\n bufferB[i] = mapB[i] / 255;\n }\n return [bufferR.join(\",\"), bufferG.join(\",\"), bufferB.join(\",\")];\n }\n\n addFilter(maps) {\n if (!maps) {\n return \"none\";\n }\n\n // When a page is zoomed the page is re-drawn but the maps are likely\n // the same.\n let value = this.#cache.get(maps);\n if (value) {\n return value;\n }\n\n const [tableR, tableG, tableB] = this.#createTables(maps);\n const key = maps.length === 1 ? tableR : `${tableR}${tableG}${tableB}`;\n\n value = this.#cache.get(key);\n if (value) {\n this.#cache.set(maps, value);\n return value;\n }\n\n // We create a SVG filter: feComponentTransferElement\n // https://www.w3.org/TR/SVG11/filters.html#feComponentTransferElement\n\n const id = `g_${this.#docId}_transfer_map_${this.#id++}`;\n const url = `url(#${id})`;\n this.#cache.set(maps, url);\n this.#cache.set(key, url);\n\n const filter = this.#createFilter(id);\n this.#addTransferMapConversion(tableR, tableG, tableB, filter);\n\n return url;\n }\n\n addHCMFilter(fgColor, bgColor) {\n const key = `${fgColor}-${bgColor}`;\n const filterName = \"base\";\n let info = this.#hcmCache.get(filterName);\n if (info?.key === key) {\n return info.url;\n }\n\n if (info) {\n info.filter?.remove();\n info.key = key;\n info.url = \"none\";\n info.filter = null;\n } else {\n info = {\n key,\n url: \"none\",\n filter: null,\n };\n this.#hcmCache.set(filterName, info);\n }\n\n if (!fgColor || !bgColor) {\n return info.url;\n }\n\n const fgRGB = this.#getRGB(fgColor);\n fgColor = Util.makeHexColor(...fgRGB);\n const bgRGB = this.#getRGB(bgColor);\n bgColor = Util.makeHexColor(...bgRGB);\n this.#defs.style.color = \"\";\n\n if (\n (fgColor === \"#000000\" && bgColor === \"#ffffff\") ||\n fgColor === bgColor\n ) {\n return info.url;\n }\n\n // https://developer.mozilla.org/en-US/docs/Web/Accessibility/Understanding_Colors_and_Luminance\n //\n // Relative luminance:\n // https://www.w3.org/TR/WCAG20/#relativeluminancedef\n //\n // We compute the rounded luminance of the default background color.\n // Then for every color in the pdf, if its rounded luminance is the\n // same as the background one then it's replaced by the new\n // background color else by the foreground one.\n const map = new Array(256);\n for (let i = 0; i <= 255; i++) {\n const x = i / 255;\n map[i] = x <= 0.03928 ? x / 12.92 : ((x + 0.055) / 1.055) ** 2.4;\n }\n const table = map.join(\",\");\n\n const id = `g_${this.#docId}_hcm_filter`;\n const filter = (info.filter = this.#createFilter(id));\n this.#addTransferMapConversion(table, table, table, filter);\n this.#addGrayConversion(filter);\n\n const getSteps = (c, n) => {\n const start = fgRGB[c] / 255;\n const end = bgRGB[c] / 255;\n const arr = new Array(n + 1);\n for (let i = 0; i <= n; i++) {\n arr[i] = start + (i / n) * (end - start);\n }\n return arr.join(\",\");\n };\n this.#addTransferMapConversion(\n getSteps(0, 5),\n getSteps(1, 5),\n getSteps(2, 5),\n filter\n );\n\n info.url = `url(#${id})`;\n return info.url;\n }\n\n addAlphaFilter(map) {\n // When a page is zoomed the page is re-drawn but the maps are likely\n // the same.\n let value = this.#cache.get(map);\n if (value) {\n return value;\n }\n\n const [tableA] = this.#createTables([map]);\n const key = `alpha_${tableA}`;\n\n value = this.#cache.get(key);\n if (value) {\n this.#cache.set(map, value);\n return value;\n }\n\n const id = `g_${this.#docId}_alpha_map_${this.#id++}`;\n const url = `url(#${id})`;\n this.#cache.set(map, url);\n this.#cache.set(key, url);\n\n const filter = this.#createFilter(id);\n this.#addTransferMapAlphaConversion(tableA, filter);\n\n return url;\n }\n\n addLuminosityFilter(map) {\n // When a page is zoomed the page is re-drawn but the maps are likely\n // the same.\n let value = this.#cache.get(map || \"luminosity\");\n if (value) {\n return value;\n }\n\n let tableA, key;\n if (map) {\n [tableA] = this.#createTables([map]);\n key = `luminosity_${tableA}`;\n } else {\n key = \"luminosity\";\n }\n\n value = this.#cache.get(key);\n if (value) {\n this.#cache.set(map, value);\n return value;\n }\n\n const id = `g_${this.#docId}_luminosity_map_${this.#id++}`;\n const url = `url(#${id})`;\n this.#cache.set(map, url);\n this.#cache.set(key, url);\n\n const filter = this.#createFilter(id);\n this.#addLuminosityConversion(filter);\n if (map) {\n this.#addTransferMapAlphaConversion(tableA, filter);\n }\n\n return url;\n }\n\n addHighlightHCMFilter(filterName, fgColor, bgColor, newFgColor, newBgColor) {\n const key = `${fgColor}-${bgColor}-${newFgColor}-${newBgColor}`;\n let info = this.#hcmCache.get(filterName);\n if (info?.key === key) {\n return info.url;\n }\n\n if (info) {\n info.filter?.remove();\n info.key = key;\n info.url = \"none\";\n info.filter = null;\n } else {\n info = {\n key,\n url: \"none\",\n filter: null,\n };\n this.#hcmCache.set(filterName, info);\n }\n\n if (!fgColor || !bgColor) {\n return info.url;\n }\n\n const [fgRGB, bgRGB] = [fgColor, bgColor].map(this.#getRGB.bind(this));\n let fgGray = Math.round(\n 0.2126 * fgRGB[0] + 0.7152 * fgRGB[1] + 0.0722 * fgRGB[2]\n );\n let bgGray = Math.round(\n 0.2126 * bgRGB[0] + 0.7152 * bgRGB[1] + 0.0722 * bgRGB[2]\n );\n let [newFgRGB, newBgRGB] = [newFgColor, newBgColor].map(\n this.#getRGB.bind(this)\n );\n if (bgGray < fgGray) {\n [fgGray, bgGray, newFgRGB, newBgRGB] = [\n bgGray,\n fgGray,\n newBgRGB,\n newFgRGB,\n ];\n }\n this.#defs.style.color = \"\";\n\n // Now we can create the filters to highlight some canvas parts.\n // The colors in the pdf will almost be Canvas and CanvasText, hence we\n // want to filter them to finally get Highlight and HighlightText.\n // Since we're in HCM the background color and the foreground color should\n // be really different when converted to grayscale (if they're not then it\n // means that we've a poor contrast). Once the canvas colors are converted\n // to grayscale we can easily map them on their new colors.\n // The grayscale step is important because if we've something like:\n // fgColor = #FF....\n // bgColor = #FF....\n // then we are enable to map the red component on the new red components\n // which can be different.\n\n const getSteps = (fg, bg, n) => {\n const arr = new Array(256);\n const step = (bgGray - fgGray) / n;\n const newStart = fg / 255;\n const newStep = (bg - fg) / (255 * n);\n let prev = 0;\n for (let i = 0; i <= n; i++) {\n const k = Math.round(fgGray + i * step);\n const value = newStart + i * newStep;\n for (let j = prev; j <= k; j++) {\n arr[j] = value;\n }\n prev = k + 1;\n }\n for (let i = prev; i < 256; i++) {\n arr[i] = arr[prev - 1];\n }\n return arr.join(\",\");\n };\n\n const id = `g_${this.#docId}_hcm_${filterName}_filter`;\n const filter = (info.filter = this.#createFilter(id));\n\n this.#addGrayConversion(filter);\n this.#addTransferMapConversion(\n getSteps(newFgRGB[0], newBgRGB[0], 5),\n getSteps(newFgRGB[1], newBgRGB[1], 5),\n getSteps(newFgRGB[2], newBgRGB[2], 5),\n filter\n );\n\n info.url = `url(#${id})`;\n return info.url;\n }\n\n destroy(keepHCM = false) {\n if (keepHCM && this.#hcmCache.size !== 0) {\n return;\n }\n if (this.#_defs) {\n this.#_defs.parentNode.parentNode.remove();\n this.#_defs = null;\n }\n if (this.#_cache) {\n this.#_cache.clear();\n this.#_cache = null;\n }\n this.#id = 0;\n }\n\n #addLuminosityConversion(filter) {\n const feColorMatrix = this.#document.createElementNS(\n SVG_NS,\n \"feColorMatrix\"\n );\n feColorMatrix.setAttribute(\"type\", \"matrix\");\n feColorMatrix.setAttribute(\n \"values\",\n \"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.3 0.59 0.11 0 0\"\n );\n filter.append(feColorMatrix);\n }\n\n #addGrayConversion(filter) {\n const feColorMatrix = this.#document.createElementNS(\n SVG_NS,\n \"feColorMatrix\"\n );\n feColorMatrix.setAttribute(\"type\", \"matrix\");\n feColorMatrix.setAttribute(\n \"values\",\n \"0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0.2126 0.7152 0.0722 0 0 0 0 0 1 0\"\n );\n filter.append(feColorMatrix);\n }\n\n #createFilter(id) {\n const filter = this.#document.createElementNS(SVG_NS, \"filter\");\n filter.setAttribute(\"color-interpolation-filters\", \"sRGB\");\n filter.setAttribute(\"id\", id);\n this.#defs.append(filter);\n\n return filter;\n }\n\n #appendFeFunc(feComponentTransfer, func, table) {\n const feFunc = this.#document.createElementNS(SVG_NS, func);\n feFunc.setAttribute(\"type\", \"discrete\");\n feFunc.setAttribute(\"tableValues\", table);\n feComponentTransfer.append(feFunc);\n }\n\n #addTransferMapConversion(rTable, gTable, bTable, filter) {\n const feComponentTransfer = this.#document.createElementNS(\n SVG_NS,\n \"feComponentTransfer\"\n );\n filter.append(feComponentTransfer);\n this.#appendFeFunc(feComponentTransfer, \"feFuncR\", rTable);\n this.#appendFeFunc(feComponentTransfer, \"feFuncG\", gTable);\n this.#appendFeFunc(feComponentTransfer, \"feFuncB\", bTable);\n }\n\n #addTransferMapAlphaConversion(aTable, filter) {\n const feComponentTransfer = this.#document.createElementNS(\n SVG_NS,\n \"feComponentTransfer\"\n );\n filter.append(feComponentTransfer);\n this.#appendFeFunc(feComponentTransfer, \"feFuncA\", aTable);\n }\n\n #getRGB(color) {\n this.#defs.style.color = color;\n return getRGB(getComputedStyle(this.#defs).getPropertyValue(\"color\"));\n }\n}\n\nclass DOMCanvasFactory extends BaseCanvasFactory {\n constructor({ ownerDocument = globalThis.document, enableHWA = false } = {}) {\n super({ enableHWA });\n this._document = ownerDocument;\n }\n\n /**\n * @ignore\n */\n _createCanvas(width, height) {\n const canvas = this._document.createElement(\"canvas\");\n canvas.width = width;\n canvas.height = height;\n return canvas;\n }\n}\n\nasync function fetchData(url, type = \"text\") {\n if (\n (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) ||\n isValidFetchUrl(url, document.baseURI)\n ) {\n const response = await fetch(url);\n if (!response.ok) {\n throw new Error(response.statusText);\n }\n switch (type) {\n case \"arraybuffer\":\n return response.arrayBuffer();\n case \"blob\":\n return response.blob();\n case \"json\":\n return response.json();\n }\n return response.text();\n }\n\n // The Fetch API is not supported.\n return new Promise((resolve, reject) => {\n const request = new XMLHttpRequest();\n request.open(\"GET\", url, /* async = */ true);\n request.responseType = type;\n\n request.onreadystatechange = () => {\n if (request.readyState !== XMLHttpRequest.DONE) {\n return;\n }\n if (request.status === 200 || request.status === 0) {\n switch (type) {\n case \"arraybuffer\":\n case \"blob\":\n case \"json\":\n resolve(request.response);\n return;\n }\n resolve(request.responseText);\n return;\n }\n reject(new Error(request.statusText));\n };\n\n request.send(null);\n });\n}\n\nclass DOMCMapReaderFactory extends BaseCMapReaderFactory {\n /**\n * @ignore\n */\n _fetchData(url, compressionType) {\n return fetchData(\n url,\n /* type = */ this.isCompressed ? \"arraybuffer\" : \"text\"\n ).then(data => ({\n cMapData:\n data instanceof ArrayBuffer\n ? new Uint8Array(data)\n : stringToBytes(data),\n compressionType,\n }));\n }\n}\n\nclass DOMStandardFontDataFactory extends BaseStandardFontDataFactory {\n /**\n * @ignore\n */\n _fetchData(url) {\n return fetchData(url, /* type = */ \"arraybuffer\").then(\n data => new Uint8Array(data)\n );\n }\n}\n\nclass DOMSVGFactory extends BaseSVGFactory {\n /**\n * @ignore\n */\n _createSVG(type) {\n return document.createElementNS(SVG_NS, type);\n }\n}\n\n/**\n * @typedef {Object} PageViewportParameters\n * @property {Array} viewBox - The xMin, yMin, xMax and\n * yMax coordinates.\n * @property {number} scale - The scale of the viewport.\n * @property {number} rotation - The rotation, in degrees, of the viewport.\n * @property {number} [offsetX] - The horizontal, i.e. x-axis, offset. The\n * default value is `0`.\n * @property {number} [offsetY] - The vertical, i.e. y-axis, offset. The\n * default value is `0`.\n * @property {boolean} [dontFlip] - If true, the y-axis will not be flipped.\n * The default value is `false`.\n */\n\n/**\n * @typedef {Object} PageViewportCloneParameters\n * @property {number} [scale] - The scale, overriding the one in the cloned\n * viewport. The default value is `this.scale`.\n * @property {number} [rotation] - The rotation, in degrees, overriding the one\n * in the cloned viewport. The default value is `this.rotation`.\n * @property {number} [offsetX] - The horizontal, i.e. x-axis, offset.\n * The default value is `this.offsetX`.\n * @property {number} [offsetY] - The vertical, i.e. y-axis, offset.\n * The default value is `this.offsetY`.\n * @property {boolean} [dontFlip] - If true, the x-axis will not be flipped.\n * The default value is `false`.\n */\n\n/**\n * PDF page viewport created based on scale, rotation and offset.\n */\nclass PageViewport {\n /**\n * @param {PageViewportParameters}\n */\n constructor({\n viewBox,\n scale,\n rotation,\n offsetX = 0,\n offsetY = 0,\n dontFlip = false,\n }) {\n this.viewBox = viewBox;\n this.scale = scale;\n this.rotation = rotation;\n this.offsetX = offsetX;\n this.offsetY = offsetY;\n\n // creating transform to convert pdf coordinate system to the normal\n // canvas like coordinates taking in account scale and rotation\n const centerX = (viewBox[2] + viewBox[0]) / 2;\n const centerY = (viewBox[3] + viewBox[1]) / 2;\n let rotateA, rotateB, rotateC, rotateD;\n // Normalize the rotation, by clamping it to the [0, 360) range.\n rotation %= 360;\n if (rotation < 0) {\n rotation += 360;\n }\n switch (rotation) {\n case 180:\n rotateA = -1;\n rotateB = 0;\n rotateC = 0;\n rotateD = 1;\n break;\n case 90:\n rotateA = 0;\n rotateB = 1;\n rotateC = 1;\n rotateD = 0;\n break;\n case 270:\n rotateA = 0;\n rotateB = -1;\n rotateC = -1;\n rotateD = 0;\n break;\n case 0:\n rotateA = 1;\n rotateB = 0;\n rotateC = 0;\n rotateD = -1;\n break;\n default:\n throw new Error(\n \"PageViewport: Invalid rotation, must be a multiple of 90 degrees.\"\n );\n }\n\n if (dontFlip) {\n rotateC = -rotateC;\n rotateD = -rotateD;\n }\n\n let offsetCanvasX, offsetCanvasY;\n let width, height;\n if (rotateA === 0) {\n offsetCanvasX = Math.abs(centerY - viewBox[1]) * scale + offsetX;\n offsetCanvasY = Math.abs(centerX - viewBox[0]) * scale + offsetY;\n width = (viewBox[3] - viewBox[1]) * scale;\n height = (viewBox[2] - viewBox[0]) * scale;\n } else {\n offsetCanvasX = Math.abs(centerX - viewBox[0]) * scale + offsetX;\n offsetCanvasY = Math.abs(centerY - viewBox[1]) * scale + offsetY;\n width = (viewBox[2] - viewBox[0]) * scale;\n height = (viewBox[3] - viewBox[1]) * scale;\n }\n // creating transform for the following operations:\n // translate(-centerX, -centerY), rotate and flip vertically,\n // scale, and translate(offsetCanvasX, offsetCanvasY)\n this.transform = [\n rotateA * scale,\n rotateB * scale,\n rotateC * scale,\n rotateD * scale,\n offsetCanvasX - rotateA * scale * centerX - rotateC * scale * centerY,\n offsetCanvasY - rotateB * scale * centerX - rotateD * scale * centerY,\n ];\n\n this.width = width;\n this.height = height;\n }\n\n /**\n * The original, un-scaled, viewport dimensions.\n * @type {Object}\n */\n get rawDims() {\n const { viewBox } = this;\n return shadow(this, \"rawDims\", {\n pageWidth: viewBox[2] - viewBox[0],\n pageHeight: viewBox[3] - viewBox[1],\n pageX: viewBox[0],\n pageY: viewBox[1],\n });\n }\n\n /**\n * Clones viewport, with optional additional properties.\n * @param {PageViewportCloneParameters} [params]\n * @returns {PageViewport} Cloned viewport.\n */\n clone({\n scale = this.scale,\n rotation = this.rotation,\n offsetX = this.offsetX,\n offsetY = this.offsetY,\n dontFlip = false,\n } = {}) {\n return new PageViewport({\n viewBox: this.viewBox.slice(),\n scale,\n rotation,\n offsetX,\n offsetY,\n dontFlip,\n });\n }\n\n /**\n * Converts PDF point to the viewport coordinates. For examples, useful for\n * converting PDF location into canvas pixel coordinates.\n * @param {number} x - The x-coordinate.\n * @param {number} y - The y-coordinate.\n * @returns {Array} Array containing `x`- and `y`-coordinates of the\n * point in the viewport coordinate space.\n * @see {@link convertToPdfPoint}\n * @see {@link convertToViewportRectangle}\n */\n convertToViewportPoint(x, y) {\n return Util.applyTransform([x, y], this.transform);\n }\n\n /**\n * Converts PDF rectangle to the viewport coordinates.\n * @param {Array} rect - The xMin, yMin, xMax and yMax coordinates.\n * @returns {Array} Array containing corresponding coordinates of the\n * rectangle in the viewport coordinate space.\n * @see {@link convertToViewportPoint}\n */\n convertToViewportRectangle(rect) {\n const topLeft = Util.applyTransform([rect[0], rect[1]], this.transform);\n const bottomRight = Util.applyTransform([rect[2], rect[3]], this.transform);\n return [topLeft[0], topLeft[1], bottomRight[0], bottomRight[1]];\n }\n\n /**\n * Converts viewport coordinates to the PDF location. For examples, useful\n * for converting canvas pixel location into PDF one.\n * @param {number} x - The x-coordinate.\n * @param {number} y - The y-coordinate.\n * @returns {Array} Array containing `x`- and `y`-coordinates of the\n * point in the PDF coordinate space.\n * @see {@link convertToViewportPoint}\n */\n convertToPdfPoint(x, y) {\n return Util.applyInverseTransform([x, y], this.transform);\n }\n}\n\nclass RenderingCancelledException extends BaseException {\n constructor(msg, extraDelay = 0) {\n super(msg, \"RenderingCancelledException\");\n this.extraDelay = extraDelay;\n }\n}\n\nfunction isDataScheme(url) {\n const ii = url.length;\n let i = 0;\n while (i < ii && url[i].trim() === \"\") {\n i++;\n }\n return url.substring(i, i + 5).toLowerCase() === \"data:\";\n}\n\nfunction isPdfFile(filename) {\n return typeof filename === \"string\" && /\\.pdf$/i.test(filename);\n}\n\n/**\n * Gets the filename from a given URL.\n * @param {string} url\n * @returns {string}\n */\nfunction getFilenameFromUrl(url) {\n [url] = url.split(/[#?]/, 1);\n return url.substring(url.lastIndexOf(\"/\") + 1);\n}\n\n/**\n * Returns the filename or guessed filename from the url (see issue 3455).\n * @param {string} url - The original PDF location.\n * @param {string} defaultFilename - The value returned if the filename is\n * unknown, or the protocol is unsupported.\n * @returns {string} Guessed PDF filename.\n */\nfunction getPdfFilenameFromUrl(url, defaultFilename = \"document.pdf\") {\n if (typeof url !== \"string\") {\n return defaultFilename;\n }\n if (isDataScheme(url)) {\n warn('getPdfFilenameFromUrl: ignore \"data:\"-URL for performance reasons.');\n return defaultFilename;\n }\n const reURI = /^(?:(?:[^:]+:)?\\/\\/[^/]+)?([^?#]*)(\\?[^#]*)?(#.*)?$/;\n // SCHEME HOST 1.PATH 2.QUERY 3.REF\n // Pattern to get last matching NAME.pdf\n const reFilename = /[^/?#=]+\\.pdf\\b(?!.*\\.pdf\\b)/i;\n const splitURI = reURI.exec(url);\n let suggestedFilename =\n reFilename.exec(splitURI[1]) ||\n reFilename.exec(splitURI[2]) ||\n reFilename.exec(splitURI[3]);\n if (suggestedFilename) {\n suggestedFilename = suggestedFilename[0];\n if (suggestedFilename.includes(\"%\")) {\n // URL-encoded %2Fpath%2Fto%2Ffile.pdf should be file.pdf\n try {\n suggestedFilename = reFilename.exec(\n decodeURIComponent(suggestedFilename)\n )[0];\n } catch {\n // Possible (extremely rare) errors:\n // URIError \"Malformed URI\", e.g. for \"%AA.pdf\"\n // TypeError \"null has no properties\", e.g. for \"%2F.pdf\"\n }\n }\n }\n return suggestedFilename || defaultFilename;\n}\n\nclass StatTimer {\n started = Object.create(null);\n\n times = [];\n\n time(name) {\n if (name in this.started) {\n warn(`Timer is already running for ${name}`);\n }\n this.started[name] = Date.now();\n }\n\n timeEnd(name) {\n if (!(name in this.started)) {\n warn(`Timer has not been started for ${name}`);\n }\n this.times.push({\n name,\n start: this.started[name],\n end: Date.now(),\n });\n // Remove timer from started so it can be called again.\n delete this.started[name];\n }\n\n toString() {\n // Find the longest name for padding purposes.\n const outBuf = [];\n let longest = 0;\n for (const { name } of this.times) {\n longest = Math.max(name.length, longest);\n }\n for (const { name, start, end } of this.times) {\n outBuf.push(`${name.padEnd(longest)} ${end - start}ms\\n`);\n }\n return outBuf.join(\"\");\n }\n}\n\nfunction isValidFetchUrl(url, baseUrl) {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\"Not implemented: isValidFetchUrl\");\n }\n try {\n const { protocol } = baseUrl ? new URL(url, baseUrl) : new URL(url);\n // The Fetch API only supports the http/https protocols, and not file/ftp.\n return protocol === \"http:\" || protocol === \"https:\";\n } catch {\n return false; // `new URL()` will throw on incorrect data.\n }\n}\n\n/**\n * Event handler to suppress context menu.\n */\nfunction noContextMenu(e) {\n e.preventDefault();\n}\n\n// Deprecated API function -- display regardless of the `verbosity` setting.\nfunction deprecated(details) {\n console.log(\"Deprecated API usage: \" + details);\n}\n\nlet pdfDateStringRegex;\n\nclass PDFDateString {\n /**\n * Convert a PDF date string to a JavaScript `Date` object.\n *\n * The PDF date string format is described in section 7.9.4 of the official\n * PDF 32000-1:2008 specification. However, in the PDF 1.7 reference (sixth\n * edition) Adobe describes the same format including a trailing apostrophe.\n * This syntax in incorrect, but Adobe Acrobat creates PDF files that contain\n * them. We ignore all apostrophes as they are not necessary for date parsing.\n *\n * Moreover, Adobe Acrobat doesn't handle changing the date to universal time\n * and doesn't use the user's time zone (effectively ignoring the HH' and mm'\n * parts of the date string).\n *\n * @param {string} input\n * @returns {Date|null}\n */\n static toDateObject(input) {\n if (!input || typeof input !== \"string\") {\n return null;\n }\n\n // Lazily initialize the regular expression.\n pdfDateStringRegex ||= new RegExp(\n \"^D:\" + // Prefix (required)\n \"(\\\\d{4})\" + // Year (required)\n \"(\\\\d{2})?\" + // Month (optional)\n \"(\\\\d{2})?\" + // Day (optional)\n \"(\\\\d{2})?\" + // Hour (optional)\n \"(\\\\d{2})?\" + // Minute (optional)\n \"(\\\\d{2})?\" + // Second (optional)\n \"([Z|+|-])?\" + // Universal time relation (optional)\n \"(\\\\d{2})?\" + // Offset hour (optional)\n \"'?\" + // Splitting apostrophe (optional)\n \"(\\\\d{2})?\" + // Offset minute (optional)\n \"'?\" // Trailing apostrophe (optional)\n );\n\n // Optional fields that don't satisfy the requirements from the regular\n // expression (such as incorrect digit counts or numbers that are out of\n // range) will fall back the defaults from the specification.\n const matches = pdfDateStringRegex.exec(input);\n if (!matches) {\n return null;\n }\n\n // JavaScript's `Date` object expects the month to be between 0 and 11\n // instead of 1 and 12, so we have to correct for that.\n const year = parseInt(matches[1], 10);\n let month = parseInt(matches[2], 10);\n month = month >= 1 && month <= 12 ? month - 1 : 0;\n let day = parseInt(matches[3], 10);\n day = day >= 1 && day <= 31 ? day : 1;\n let hour = parseInt(matches[4], 10);\n hour = hour >= 0 && hour <= 23 ? hour : 0;\n let minute = parseInt(matches[5], 10);\n minute = minute >= 0 && minute <= 59 ? minute : 0;\n let second = parseInt(matches[6], 10);\n second = second >= 0 && second <= 59 ? second : 0;\n const universalTimeRelation = matches[7] || \"Z\";\n let offsetHour = parseInt(matches[8], 10);\n offsetHour = offsetHour >= 0 && offsetHour <= 23 ? offsetHour : 0;\n let offsetMinute = parseInt(matches[9], 10) || 0;\n offsetMinute = offsetMinute >= 0 && offsetMinute <= 59 ? offsetMinute : 0;\n\n // Universal time relation 'Z' means that the local time is equal to the\n // universal time, whereas the relations '+'/'-' indicate that the local\n // time is later respectively earlier than the universal time. Every date\n // is normalized to universal time.\n if (universalTimeRelation === \"-\") {\n hour += offsetHour;\n minute += offsetMinute;\n } else if (universalTimeRelation === \"+\") {\n hour -= offsetHour;\n minute -= offsetMinute;\n }\n\n return new Date(Date.UTC(year, month, day, hour, minute, second));\n }\n}\n\n/**\n * NOTE: This is (mostly) intended to support printing of XFA forms.\n */\nfunction getXfaPageViewport(xfaPage, { scale = 1, rotation = 0 }) {\n const { width, height } = xfaPage.attributes.style;\n const viewBox = [0, 0, parseInt(width), parseInt(height)];\n\n return new PageViewport({\n viewBox,\n scale,\n rotation,\n });\n}\n\nfunction getRGB(color) {\n if (color.startsWith(\"#\")) {\n const colorRGB = parseInt(color.slice(1), 16);\n return [\n (colorRGB & 0xff0000) >> 16,\n (colorRGB & 0x00ff00) >> 8,\n colorRGB & 0x0000ff,\n ];\n }\n\n if (color.startsWith(\"rgb(\")) {\n // getComputedStyle(...).color returns a `rgb(R, G, B)` color.\n return color\n .slice(/* \"rgb(\".length */ 4, -1) // Strip out \"rgb(\" and \")\".\n .split(\",\")\n .map(x => parseInt(x));\n }\n\n if (color.startsWith(\"rgba(\")) {\n return color\n .slice(/* \"rgba(\".length */ 5, -1) // Strip out \"rgba(\" and \")\".\n .split(\",\")\n .map(x => parseInt(x))\n .slice(0, 3);\n }\n\n warn(`Not a valid color format: \"${color}\"`);\n return [0, 0, 0];\n}\n\nfunction getColorValues(colors) {\n const span = document.createElement(\"span\");\n span.style.visibility = \"hidden\";\n document.body.append(span);\n for (const name of colors.keys()) {\n span.style.color = name;\n const computedColor = window.getComputedStyle(span).color;\n colors.set(name, getRGB(computedColor));\n }\n span.remove();\n}\n\nfunction getCurrentTransform(ctx) {\n const { a, b, c, d, e, f } = ctx.getTransform();\n return [a, b, c, d, e, f];\n}\n\nfunction getCurrentTransformInverse(ctx) {\n const { a, b, c, d, e, f } = ctx.getTransform().invertSelf();\n return [a, b, c, d, e, f];\n}\n\n/**\n * @param {HTMLDivElement} div\n * @param {PageViewport} viewport\n * @param {boolean} mustFlip\n * @param {boolean} mustRotate\n */\nfunction setLayerDimensions(\n div,\n viewport,\n mustFlip = false,\n mustRotate = true\n) {\n if (viewport instanceof PageViewport) {\n const { pageWidth, pageHeight } = viewport.rawDims;\n const { style } = div;\n const useRound = FeatureTest.isCSSRoundSupported;\n\n const w = `var(--scale-factor) * ${pageWidth}px`,\n h = `var(--scale-factor) * ${pageHeight}px`;\n const widthStr = useRound ? `round(${w}, 1px)` : `calc(${w})`,\n heightStr = useRound ? `round(${h}, 1px)` : `calc(${h})`;\n\n if (!mustFlip || viewport.rotation % 180 === 0) {\n style.width = widthStr;\n style.height = heightStr;\n } else {\n style.width = heightStr;\n style.height = widthStr;\n }\n }\n\n if (mustRotate) {\n div.setAttribute(\"data-main-rotation\", viewport.rotation);\n }\n}\n\nexport {\n deprecated,\n DOMCanvasFactory,\n DOMCMapReaderFactory,\n DOMFilterFactory,\n DOMStandardFontDataFactory,\n DOMSVGFactory,\n fetchData,\n getColorValues,\n getCurrentTransform,\n getCurrentTransformInverse,\n getFilenameFromUrl,\n getPdfFilenameFromUrl,\n getRGB,\n getXfaPageViewport,\n isDataScheme,\n isPdfFile,\n isValidFetchUrl,\n noContextMenu,\n PageViewport,\n PDFDateString,\n PixelsPerInch,\n RenderingCancelledException,\n setLayerDimensions,\n StatTimer,\n};\n","/* Copyright 2023 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { noContextMenu } from \"../display_utils.js\";\n\nclass EditorToolbar {\n #toolbar = null;\n\n #colorPicker = null;\n\n #editor;\n\n #buttons = null;\n\n constructor(editor) {\n this.#editor = editor;\n }\n\n render() {\n const editToolbar = (this.#toolbar = document.createElement(\"div\"));\n editToolbar.className = \"editToolbar\";\n editToolbar.setAttribute(\"role\", \"toolbar\");\n editToolbar.addEventListener(\"contextmenu\", noContextMenu);\n editToolbar.addEventListener(\"pointerdown\", EditorToolbar.#pointerDown);\n\n const buttons = (this.#buttons = document.createElement(\"div\"));\n buttons.className = \"buttons\";\n editToolbar.append(buttons);\n\n const position = this.#editor.toolbarPosition;\n if (position) {\n const { style } = editToolbar;\n const x =\n this.#editor._uiManager.direction === \"ltr\"\n ? 1 - position[0]\n : position[0];\n style.insetInlineEnd = `${100 * x}%`;\n style.top = `calc(${\n 100 * position[1]\n }% + var(--editor-toolbar-vert-offset))`;\n }\n\n this.#addDeleteButton();\n\n return editToolbar;\n }\n\n static #pointerDown(e) {\n e.stopPropagation();\n }\n\n #focusIn(e) {\n this.#editor._focusEventsAllowed = false;\n e.preventDefault();\n e.stopPropagation();\n }\n\n #focusOut(e) {\n this.#editor._focusEventsAllowed = true;\n e.preventDefault();\n e.stopPropagation();\n }\n\n #addListenersToElement(element) {\n // If we're clicking on a button with the keyboard or with\n // the mouse, we don't want to trigger any focus events on\n // the editor.\n element.addEventListener(\"focusin\", this.#focusIn.bind(this), {\n capture: true,\n });\n element.addEventListener(\"focusout\", this.#focusOut.bind(this), {\n capture: true,\n });\n element.addEventListener(\"contextmenu\", noContextMenu);\n }\n\n hide() {\n this.#toolbar.classList.add(\"hidden\");\n this.#colorPicker?.hideDropdown();\n }\n\n show() {\n this.#toolbar.classList.remove(\"hidden\");\n }\n\n #addDeleteButton() {\n const button = document.createElement(\"button\");\n button.className = \"delete\";\n button.tabIndex = 0;\n button.setAttribute(\n \"data-l10n-id\",\n `pdfjs-editor-remove-${this.#editor.editorType}-button`\n );\n this.#addListenersToElement(button);\n button.addEventListener(\"click\", e => {\n this.#editor._uiManager.delete();\n });\n this.#buttons.append(button);\n }\n\n get #divider() {\n const divider = document.createElement(\"div\");\n divider.className = \"divider\";\n return divider;\n }\n\n addAltTextButton(button) {\n this.#addListenersToElement(button);\n this.#buttons.prepend(button, this.#divider);\n }\n\n addColorPicker(colorPicker) {\n this.#colorPicker = colorPicker;\n const button = colorPicker.renderButton();\n this.#addListenersToElement(button);\n this.#buttons.prepend(button, this.#divider);\n }\n\n remove() {\n this.#toolbar.remove();\n this.#colorPicker?.destroy();\n this.#colorPicker = null;\n }\n}\n\nclass HighlightToolbar {\n #buttons = null;\n\n #toolbar = null;\n\n #uiManager;\n\n constructor(uiManager) {\n this.#uiManager = uiManager;\n }\n\n #render() {\n const editToolbar = (this.#toolbar = document.createElement(\"div\"));\n editToolbar.className = \"editToolbar\";\n editToolbar.setAttribute(\"role\", \"toolbar\");\n editToolbar.addEventListener(\"contextmenu\", noContextMenu);\n\n const buttons = (this.#buttons = document.createElement(\"div\"));\n buttons.className = \"buttons\";\n editToolbar.append(buttons);\n\n this.#addHighlightButton();\n\n return editToolbar;\n }\n\n #getLastPoint(boxes, isLTR) {\n let lastY = 0;\n let lastX = 0;\n for (const box of boxes) {\n const y = box.y + box.height;\n if (y < lastY) {\n continue;\n }\n const x = box.x + (isLTR ? box.width : 0);\n if (y > lastY) {\n lastX = x;\n lastY = y;\n continue;\n }\n if (isLTR) {\n if (x > lastX) {\n lastX = x;\n }\n } else if (x < lastX) {\n lastX = x;\n }\n }\n return [isLTR ? 1 - lastX : lastX, lastY];\n }\n\n show(parent, boxes, isLTR) {\n const [x, y] = this.#getLastPoint(boxes, isLTR);\n const { style } = (this.#toolbar ||= this.#render());\n parent.append(this.#toolbar);\n style.insetInlineEnd = `${100 * x}%`;\n style.top = `calc(${100 * y}% + var(--editor-toolbar-vert-offset))`;\n }\n\n hide() {\n this.#toolbar.remove();\n }\n\n #addHighlightButton() {\n const button = document.createElement(\"button\");\n button.className = \"highlightButton\";\n button.tabIndex = 0;\n button.setAttribute(\"data-l10n-id\", `pdfjs-highlight-floating-button1`);\n const span = document.createElement(\"span\");\n button.append(span);\n span.className = \"visuallyHidden\";\n span.setAttribute(\"data-l10n-id\", \"pdfjs-highlight-floating-button-label\");\n button.addEventListener(\"contextmenu\", noContextMenu);\n button.addEventListener(\"click\", () => {\n this.#uiManager.highlightSelection(\"floating_button\");\n });\n this.#buttons.append(button);\n }\n}\n\nexport { EditorToolbar, HighlightToolbar };\n","/* Copyright 2022 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/** @typedef {import(\"./editor.js\").AnnotationEditor} AnnotationEditor */\n// eslint-disable-next-line max-len\n/** @typedef {import(\"./annotation_editor_layer.js\").AnnotationEditorLayer} AnnotationEditorLayer */\n\nimport {\n AnnotationEditorParamsType,\n AnnotationEditorPrefix,\n AnnotationEditorType,\n FeatureTest,\n getUuid,\n shadow,\n Util,\n warn,\n} from \"../../shared/util.js\";\nimport {\n fetchData,\n getColorValues,\n getRGB,\n PixelsPerInch,\n} from \"../display_utils.js\";\nimport { HighlightToolbar } from \"./toolbar.js\";\n\nfunction bindEvents(obj, element, names) {\n for (const name of names) {\n element.addEventListener(name, obj[name].bind(obj));\n }\n}\n\n/**\n * Convert a number between 0 and 100 into an hex number between 0 and 255.\n * @param {number} opacity\n * @return {string}\n */\nfunction opacityToHex(opacity) {\n return Math.round(Math.min(255, Math.max(1, 255 * opacity)))\n .toString(16)\n .padStart(2, \"0\");\n}\n\n/**\n * Class to create some unique ids for the different editors.\n */\nclass IdManager {\n #id = 0;\n\n constructor() {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"TESTING\")) {\n Object.defineProperty(this, \"reset\", {\n value: () => (this.#id = 0),\n });\n }\n }\n\n /**\n * Get a unique id.\n * @returns {string}\n */\n get id() {\n return `${AnnotationEditorPrefix}${this.#id++}`;\n }\n}\n\n/**\n * Class to manage the images used by the editors.\n * The main idea is to try to minimize the memory used by the images.\n * The images are cached and reused when possible\n * We use a refCounter to know when an image is not used anymore but we need to\n * be able to restore an image after a remove+undo, so we keep a file reference\n * or an url one.\n */\nclass ImageManager {\n #baseId = getUuid();\n\n #id = 0;\n\n #cache = null;\n\n static get _isSVGFittingCanvas() {\n // By default, Firefox doesn't rescale without preserving the aspect ratio\n // when drawing an SVG image on a canvas, see https://bugzilla.mozilla.org/1547776.\n // The \"workaround\" is to append \"svgView(preserveAspectRatio(none))\" to the\n // url, but according to comment #15, it seems that it leads to unexpected\n // behavior in Safari.\n const svg = `data:image/svg+xml;charset=UTF-8,`;\n const canvas = new OffscreenCanvas(1, 3);\n const ctx = canvas.getContext(\"2d\", { willReadFrequently: true });\n const image = new Image();\n image.src = svg;\n const promise = image.decode().then(() => {\n ctx.drawImage(image, 0, 0, 1, 1, 0, 0, 1, 3);\n return new Uint32Array(ctx.getImageData(0, 0, 1, 1).data.buffer)[0] === 0;\n });\n\n return shadow(this, \"_isSVGFittingCanvas\", promise);\n }\n\n async #get(key, rawData) {\n this.#cache ||= new Map();\n let data = this.#cache.get(key);\n if (data === null) {\n // We already tried to load the image but it failed.\n return null;\n }\n if (data?.bitmap) {\n data.refCounter += 1;\n return data;\n }\n try {\n data ||= {\n bitmap: null,\n id: `image_${this.#baseId}_${this.#id++}`,\n refCounter: 0,\n isSvg: false,\n };\n let image;\n if (typeof rawData === \"string\") {\n data.url = rawData;\n image = await fetchData(rawData, \"blob\");\n } else {\n image = data.file = rawData;\n }\n\n if (image.type === \"image/svg+xml\") {\n // Unfortunately, createImageBitmap doesn't work with SVG images.\n // (see https://bugzilla.mozilla.org/1841972).\n const mustRemoveAspectRatioPromise = ImageManager._isSVGFittingCanvas;\n const fileReader = new FileReader();\n const imageElement = new Image();\n const imagePromise = new Promise((resolve, reject) => {\n imageElement.onload = () => {\n data.bitmap = imageElement;\n data.isSvg = true;\n resolve();\n };\n fileReader.onload = async () => {\n const url = (data.svgUrl = fileReader.result);\n // We need to set the preserveAspectRatio to none in order to let\n // the image fits the canvas when resizing.\n imageElement.src = (await mustRemoveAspectRatioPromise)\n ? `${url}#svgView(preserveAspectRatio(none))`\n : url;\n };\n imageElement.onerror = fileReader.onerror = reject;\n });\n fileReader.readAsDataURL(image);\n await imagePromise;\n } else {\n data.bitmap = await createImageBitmap(image);\n }\n data.refCounter = 1;\n } catch (e) {\n console.error(e);\n data = null;\n }\n this.#cache.set(key, data);\n if (data) {\n this.#cache.set(data.id, data);\n }\n return data;\n }\n\n async getFromFile(file) {\n const { lastModified, name, size, type } = file;\n return this.#get(`${lastModified}_${name}_${size}_${type}`, file);\n }\n\n async getFromUrl(url) {\n return this.#get(url, url);\n }\n\n async getFromId(id) {\n this.#cache ||= new Map();\n const data = this.#cache.get(id);\n if (!data) {\n return null;\n }\n if (data.bitmap) {\n data.refCounter += 1;\n return data;\n }\n\n if (data.file) {\n return this.getFromFile(data.file);\n }\n return this.getFromUrl(data.url);\n }\n\n getSvgUrl(id) {\n const data = this.#cache.get(id);\n if (!data?.isSvg) {\n return null;\n }\n return data.svgUrl;\n }\n\n deleteId(id) {\n this.#cache ||= new Map();\n const data = this.#cache.get(id);\n if (!data) {\n return;\n }\n data.refCounter -= 1;\n if (data.refCounter !== 0) {\n return;\n }\n data.bitmap = null;\n }\n\n // We can use the id only if it belongs this manager.\n // We must take care of having the right manager because we can copy/paste\n // some images from other documents, hence it'd be a pity to use an id from an\n // other manager.\n isValidId(id) {\n return id.startsWith(`image_${this.#baseId}_`);\n }\n}\n\n/**\n * Class to handle undo/redo.\n * Commands are just saved in a buffer.\n * If we hit some memory issues we could likely use a circular buffer.\n * It has to be used as a singleton.\n */\nclass CommandManager {\n #commands = [];\n\n #locked = false;\n\n #maxSize;\n\n #position = -1;\n\n constructor(maxSize = 128) {\n this.#maxSize = maxSize;\n }\n\n /**\n * @typedef {Object} addOptions\n * @property {function} cmd\n * @property {function} undo\n * @property {function} [post]\n * @property {boolean} mustExec\n * @property {number} type\n * @property {boolean} overwriteIfSameType\n * @property {boolean} keepUndo\n */\n\n /**\n * Add a new couple of commands to be used in case of redo/undo.\n * @param {addOptions} options\n */\n add({\n cmd,\n undo,\n post,\n mustExec,\n type = NaN,\n overwriteIfSameType = false,\n keepUndo = false,\n }) {\n if (mustExec) {\n cmd();\n }\n\n if (this.#locked) {\n return;\n }\n\n const save = { cmd, undo, post, type };\n if (this.#position === -1) {\n if (this.#commands.length > 0) {\n // All the commands have been undone and then a new one is added\n // hence we clear the queue.\n this.#commands.length = 0;\n }\n this.#position = 0;\n this.#commands.push(save);\n return;\n }\n\n if (overwriteIfSameType && this.#commands[this.#position].type === type) {\n // For example when we change a color we don't want to\n // be able to undo all the steps, hence we only want to\n // keep the last undoable action in this sequence of actions.\n if (keepUndo) {\n save.undo = this.#commands[this.#position].undo;\n }\n this.#commands[this.#position] = save;\n return;\n }\n\n const next = this.#position + 1;\n if (next === this.#maxSize) {\n this.#commands.splice(0, 1);\n } else {\n this.#position = next;\n if (next < this.#commands.length) {\n this.#commands.splice(next);\n }\n }\n\n this.#commands.push(save);\n }\n\n /**\n * Undo the last command.\n */\n undo() {\n if (this.#position === -1) {\n // Nothing to undo.\n return;\n }\n\n // Avoid to insert something during the undo execution.\n this.#locked = true;\n const { undo, post } = this.#commands[this.#position];\n undo();\n post?.();\n this.#locked = false;\n\n this.#position -= 1;\n }\n\n /**\n * Redo the last command.\n */\n redo() {\n if (this.#position < this.#commands.length - 1) {\n this.#position += 1;\n\n // Avoid to insert something during the redo execution.\n this.#locked = true;\n const { cmd, post } = this.#commands[this.#position];\n cmd();\n post?.();\n this.#locked = false;\n }\n }\n\n /**\n * Check if there is something to undo.\n * @returns {boolean}\n */\n hasSomethingToUndo() {\n return this.#position !== -1;\n }\n\n /**\n * Check if there is something to redo.\n * @returns {boolean}\n */\n hasSomethingToRedo() {\n return this.#position < this.#commands.length - 1;\n }\n\n destroy() {\n this.#commands = null;\n }\n}\n\n/**\n * Class to handle the different keyboards shortcuts we can have on mac or\n * non-mac OSes.\n */\nclass KeyboardManager {\n /**\n * Create a new keyboard manager class.\n * @param {Array} callbacks - an array containing an array of shortcuts\n * and a callback to call.\n * A shortcut is a string like `ctrl+c` or `mac+ctrl+c` for mac OS.\n */\n constructor(callbacks) {\n this.buffer = [];\n this.callbacks = new Map();\n this.allKeys = new Set();\n\n const { isMac } = FeatureTest.platform;\n for (const [keys, callback, options = {}] of callbacks) {\n for (const key of keys) {\n const isMacKey = key.startsWith(\"mac+\");\n if (isMac && isMacKey) {\n this.callbacks.set(key.slice(4), { callback, options });\n this.allKeys.add(key.split(\"+\").at(-1));\n } else if (!isMac && !isMacKey) {\n this.callbacks.set(key, { callback, options });\n this.allKeys.add(key.split(\"+\").at(-1));\n }\n }\n }\n }\n\n /**\n * Serialize an event into a string in order to match a\n * potential key for a callback.\n * @param {KeyboardEvent} event\n * @returns {string}\n */\n #serialize(event) {\n if (event.altKey) {\n this.buffer.push(\"alt\");\n }\n if (event.ctrlKey) {\n this.buffer.push(\"ctrl\");\n }\n if (event.metaKey) {\n this.buffer.push(\"meta\");\n }\n if (event.shiftKey) {\n this.buffer.push(\"shift\");\n }\n this.buffer.push(event.key);\n const str = this.buffer.join(\"+\");\n this.buffer.length = 0;\n\n return str;\n }\n\n /**\n * Execute a callback, if any, for a given keyboard event.\n * The self is used as `this` in the callback.\n * @param {Object} self\n * @param {KeyboardEvent} event\n * @returns\n */\n exec(self, event) {\n if (!this.allKeys.has(event.key)) {\n return;\n }\n const info = this.callbacks.get(this.#serialize(event));\n if (!info) {\n return;\n }\n const {\n callback,\n options: { bubbles = false, args = [], checker = null },\n } = info;\n\n if (checker && !checker(self, event)) {\n return;\n }\n callback.bind(self, ...args, event)();\n\n // For example, ctrl+s in a FreeText must be handled by the viewer, hence\n // the event must bubble.\n if (!bubbles) {\n event.stopPropagation();\n event.preventDefault();\n }\n }\n}\n\nclass ColorManager {\n static _colorsMapping = new Map([\n [\"CanvasText\", [0, 0, 0]],\n [\"Canvas\", [255, 255, 255]],\n ]);\n\n get _colors() {\n if (\n typeof PDFJSDev !== \"undefined\" &&\n PDFJSDev.test(\"LIB\") &&\n typeof document === \"undefined\"\n ) {\n return shadow(this, \"_colors\", ColorManager._colorsMapping);\n }\n\n const colors = new Map([\n [\"CanvasText\", null],\n [\"Canvas\", null],\n ]);\n getColorValues(colors);\n return shadow(this, \"_colors\", colors);\n }\n\n /**\n * In High Contrast Mode, the color on the screen is not always the\n * real color used in the pdf.\n * For example in some cases white can appear to be black but when saving\n * we want to have white.\n * @param {string} color\n * @returns {Array}\n */\n convert(color) {\n const rgb = getRGB(color);\n if (!window.matchMedia(\"(forced-colors: active)\").matches) {\n return rgb;\n }\n\n for (const [name, RGB] of this._colors) {\n if (RGB.every((x, i) => x === rgb[i])) {\n return ColorManager._colorsMapping.get(name);\n }\n }\n return rgb;\n }\n\n /**\n * An input element must have its color value as a hex string\n * and not as color name.\n * So this function converts a name into an hex string.\n * @param {string} name\n * @returns {string}\n */\n getHexCode(name) {\n const rgb = this._colors.get(name);\n if (!rgb) {\n return name;\n }\n return Util.makeHexColor(...rgb);\n }\n}\n\n/**\n * A pdf has several pages and each of them when it will rendered\n * will have an AnnotationEditorLayer which will contain the some\n * new Annotations associated to an editor in order to modify them.\n *\n * This class is used to manage all the different layers, editors and\n * some action like copy/paste, undo/redo, ...\n */\nclass AnnotationEditorUIManager {\n #activeEditor = null;\n\n #allEditors = new Map();\n\n #allLayers = new Map();\n\n #altTextManager = null;\n\n #annotationStorage = null;\n\n #changedExistingAnnotations = null;\n\n #commandManager = new CommandManager();\n\n #currentPageIndex = 0;\n\n #deletedAnnotationsElementIds = new Set();\n\n #draggingEditors = null;\n\n #editorTypes = null;\n\n #editorsToRescale = new Set();\n\n #enableHighlightFloatingButton = false;\n\n #filterFactory = null;\n\n #focusMainContainerTimeoutId = null;\n\n #highlightColors = null;\n\n #highlightWhenShiftUp = false;\n\n #highlightToolbar = null;\n\n #idManager = new IdManager();\n\n #isEnabled = false;\n\n #isWaiting = false;\n\n #lastActiveElement = null;\n\n #mainHighlightColorPicker = null;\n\n #mlManager = null;\n\n #mode = AnnotationEditorType.NONE;\n\n #selectedEditors = new Set();\n\n #selectedTextNode = null;\n\n #pageColors = null;\n\n #showAllStates = null;\n\n #boundBlur = this.blur.bind(this);\n\n #boundFocus = this.focus.bind(this);\n\n #boundCopy = this.copy.bind(this);\n\n #boundCut = this.cut.bind(this);\n\n #boundDragOver = this.dragOver.bind(this);\n\n #boundDrop = this.drop.bind(this);\n\n #boundPaste = this.paste.bind(this);\n\n #boundKeydown = this.keydown.bind(this);\n\n #boundKeyup = this.keyup.bind(this);\n\n #boundOnEditingAction = this.onEditingAction.bind(this);\n\n #boundOnPageChanging = this.onPageChanging.bind(this);\n\n #boundOnScaleChanging = this.onScaleChanging.bind(this);\n\n #boundSelectionChange = this.#selectionChange.bind(this);\n\n #boundOnRotationChanging = this.onRotationChanging.bind(this);\n\n #previousStates = {\n isEditing: false,\n isEmpty: true,\n hasSomethingToUndo: false,\n hasSomethingToRedo: false,\n hasSelectedEditor: false,\n hasSelectedText: false,\n };\n\n #translation = [0, 0];\n\n #translationTimeoutId = null;\n\n #container = null;\n\n #viewer = null;\n\n static TRANSLATE_SMALL = 1; // page units.\n\n static TRANSLATE_BIG = 10; // page units.\n\n static get _keyboardManager() {\n const proto = AnnotationEditorUIManager.prototype;\n\n /**\n * If the focused element is an input, we don't want to handle the arrow.\n * For example, sliders can be controlled with the arrow keys.\n */\n const arrowChecker = self =>\n self.#container.contains(document.activeElement) &&\n document.activeElement.tagName !== \"BUTTON\" &&\n self.hasSomethingToControl();\n\n const textInputChecker = (_self, { target: el }) => {\n if (el instanceof HTMLInputElement) {\n const { type } = el;\n return type !== \"text\" && type !== \"number\";\n }\n return true;\n };\n\n const small = this.TRANSLATE_SMALL;\n const big = this.TRANSLATE_BIG;\n\n return shadow(\n this,\n \"_keyboardManager\",\n new KeyboardManager([\n [\n [\"ctrl+a\", \"mac+meta+a\"],\n proto.selectAll,\n { checker: textInputChecker },\n ],\n [[\"ctrl+z\", \"mac+meta+z\"], proto.undo, { checker: textInputChecker }],\n [\n // On mac, depending of the OS version, the event.key is either \"z\" or\n // \"Z\" when the user presses \"meta+shift+z\".\n [\n \"ctrl+y\",\n \"ctrl+shift+z\",\n \"mac+meta+shift+z\",\n \"ctrl+shift+Z\",\n \"mac+meta+shift+Z\",\n ],\n proto.redo,\n { checker: textInputChecker },\n ],\n [\n [\n \"Backspace\",\n \"alt+Backspace\",\n \"ctrl+Backspace\",\n \"shift+Backspace\",\n \"mac+Backspace\",\n \"mac+alt+Backspace\",\n \"mac+ctrl+Backspace\",\n \"Delete\",\n \"ctrl+Delete\",\n \"shift+Delete\",\n \"mac+Delete\",\n ],\n proto.delete,\n { checker: textInputChecker },\n ],\n [\n [\"Enter\", \"mac+Enter\"],\n proto.addNewEditorFromKeyboard,\n {\n // Those shortcuts can be used in the toolbar for some other actions\n // like zooming, hence we need to check if the container has the\n // focus.\n checker: (self, { target: el }) =>\n !(el instanceof HTMLButtonElement) &&\n self.#container.contains(el) &&\n !self.isEnterHandled,\n },\n ],\n [\n [\" \", \"mac+ \"],\n proto.addNewEditorFromKeyboard,\n {\n // Those shortcuts can be used in the toolbar for some other actions\n // like zooming, hence we need to check if the container has the\n // focus.\n checker: (self, { target: el }) =>\n !(el instanceof HTMLButtonElement) &&\n self.#container.contains(document.activeElement),\n },\n ],\n [[\"Escape\", \"mac+Escape\"], proto.unselectAll],\n [\n [\"ArrowLeft\", \"mac+ArrowLeft\"],\n proto.translateSelectedEditors,\n { args: [-small, 0], checker: arrowChecker },\n ],\n [\n [\"ctrl+ArrowLeft\", \"mac+shift+ArrowLeft\"],\n proto.translateSelectedEditors,\n { args: [-big, 0], checker: arrowChecker },\n ],\n [\n [\"ArrowRight\", \"mac+ArrowRight\"],\n proto.translateSelectedEditors,\n { args: [small, 0], checker: arrowChecker },\n ],\n [\n [\"ctrl+ArrowRight\", \"mac+shift+ArrowRight\"],\n proto.translateSelectedEditors,\n { args: [big, 0], checker: arrowChecker },\n ],\n [\n [\"ArrowUp\", \"mac+ArrowUp\"],\n proto.translateSelectedEditors,\n { args: [0, -small], checker: arrowChecker },\n ],\n [\n [\"ctrl+ArrowUp\", \"mac+shift+ArrowUp\"],\n proto.translateSelectedEditors,\n { args: [0, -big], checker: arrowChecker },\n ],\n [\n [\"ArrowDown\", \"mac+ArrowDown\"],\n proto.translateSelectedEditors,\n { args: [0, small], checker: arrowChecker },\n ],\n [\n [\"ctrl+ArrowDown\", \"mac+shift+ArrowDown\"],\n proto.translateSelectedEditors,\n { args: [0, big], checker: arrowChecker },\n ],\n ])\n );\n }\n\n constructor(\n container,\n viewer,\n altTextManager,\n eventBus,\n pdfDocument,\n pageColors,\n highlightColors,\n enableHighlightFloatingButton,\n mlManager\n ) {\n this.#container = container;\n this.#viewer = viewer;\n this.#altTextManager = altTextManager;\n this._eventBus = eventBus;\n this._eventBus._on(\"editingaction\", this.#boundOnEditingAction);\n this._eventBus._on(\"pagechanging\", this.#boundOnPageChanging);\n this._eventBus._on(\"scalechanging\", this.#boundOnScaleChanging);\n this._eventBus._on(\"rotationchanging\", this.#boundOnRotationChanging);\n this.#addSelectionListener();\n this.#addDragAndDropListeners();\n this.#addKeyboardManager();\n this.#annotationStorage = pdfDocument.annotationStorage;\n this.#filterFactory = pdfDocument.filterFactory;\n this.#pageColors = pageColors;\n this.#highlightColors = highlightColors || null;\n this.#enableHighlightFloatingButton = enableHighlightFloatingButton;\n this.#mlManager = mlManager || null;\n this.viewParameters = {\n realScale: PixelsPerInch.PDF_TO_CSS_UNITS,\n rotation: 0,\n };\n this.isShiftKeyDown = false;\n\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"TESTING\")) {\n Object.defineProperty(this, \"reset\", {\n value: () => {\n this.selectAll();\n this.delete();\n this.#idManager.reset();\n },\n });\n }\n }\n\n destroy() {\n this.#removeDragAndDropListeners();\n this.#removeKeyboardManager();\n this.#removeFocusManager();\n this._eventBus._off(\"editingaction\", this.#boundOnEditingAction);\n this._eventBus._off(\"pagechanging\", this.#boundOnPageChanging);\n this._eventBus._off(\"scalechanging\", this.#boundOnScaleChanging);\n this._eventBus._off(\"rotationchanging\", this.#boundOnRotationChanging);\n for (const layer of this.#allLayers.values()) {\n layer.destroy();\n }\n this.#allLayers.clear();\n this.#allEditors.clear();\n this.#editorsToRescale.clear();\n this.#activeEditor = null;\n this.#selectedEditors.clear();\n this.#commandManager.destroy();\n this.#altTextManager?.destroy();\n this.#highlightToolbar?.hide();\n this.#highlightToolbar = null;\n if (this.#focusMainContainerTimeoutId) {\n clearTimeout(this.#focusMainContainerTimeoutId);\n this.#focusMainContainerTimeoutId = null;\n }\n if (this.#translationTimeoutId) {\n clearTimeout(this.#translationTimeoutId);\n this.#translationTimeoutId = null;\n }\n this.#removeSelectionListener();\n }\n\n async mlGuess(data) {\n return this.#mlManager?.guess(data) || null;\n }\n\n get hasMLManager() {\n return !!this.#mlManager;\n }\n\n get hcmFilter() {\n return shadow(\n this,\n \"hcmFilter\",\n this.#pageColors\n ? this.#filterFactory.addHCMFilter(\n this.#pageColors.foreground,\n this.#pageColors.background\n )\n : \"none\"\n );\n }\n\n get direction() {\n return shadow(\n this,\n \"direction\",\n getComputedStyle(this.#container).direction\n );\n }\n\n get highlightColors() {\n return shadow(\n this,\n \"highlightColors\",\n this.#highlightColors\n ? new Map(\n this.#highlightColors\n .split(\",\")\n .map(pair => pair.split(\"=\").map(x => x.trim()))\n )\n : null\n );\n }\n\n get highlightColorNames() {\n return shadow(\n this,\n \"highlightColorNames\",\n this.highlightColors\n ? new Map(Array.from(this.highlightColors, e => e.reverse()))\n : null\n );\n }\n\n setMainHighlightColorPicker(colorPicker) {\n this.#mainHighlightColorPicker = colorPicker;\n }\n\n editAltText(editor) {\n this.#altTextManager?.editAltText(this, editor);\n }\n\n onPageChanging({ pageNumber }) {\n this.#currentPageIndex = pageNumber - 1;\n }\n\n focusMainContainer() {\n this.#container.focus();\n }\n\n findParent(x, y) {\n for (const layer of this.#allLayers.values()) {\n const {\n x: layerX,\n y: layerY,\n width,\n height,\n } = layer.div.getBoundingClientRect();\n if (\n x >= layerX &&\n x <= layerX + width &&\n y >= layerY &&\n y <= layerY + height\n ) {\n return layer;\n }\n }\n return null;\n }\n\n disableUserSelect(value = false) {\n this.#viewer.classList.toggle(\"noUserSelect\", value);\n }\n\n addShouldRescale(editor) {\n this.#editorsToRescale.add(editor);\n }\n\n removeShouldRescale(editor) {\n this.#editorsToRescale.delete(editor);\n }\n\n onScaleChanging({ scale }) {\n this.commitOrRemove();\n this.viewParameters.realScale = scale * PixelsPerInch.PDF_TO_CSS_UNITS;\n for (const editor of this.#editorsToRescale) {\n editor.onScaleChanging();\n }\n }\n\n onRotationChanging({ pagesRotation }) {\n this.commitOrRemove();\n this.viewParameters.rotation = pagesRotation;\n }\n\n #getAnchorElementForSelection({ anchorNode }) {\n return anchorNode.nodeType === Node.TEXT_NODE\n ? anchorNode.parentElement\n : anchorNode;\n }\n\n highlightSelection(methodOfCreation = \"\") {\n const selection = document.getSelection();\n if (!selection || selection.isCollapsed) {\n return;\n }\n const { anchorNode, anchorOffset, focusNode, focusOffset } = selection;\n const text = selection.toString();\n const anchorElement = this.#getAnchorElementForSelection(selection);\n const textLayer = anchorElement.closest(\".textLayer\");\n const boxes = this.getSelectionBoxes(textLayer);\n if (!boxes) {\n return;\n }\n selection.empty();\n if (this.#mode === AnnotationEditorType.NONE) {\n this._eventBus.dispatch(\"showannotationeditorui\", {\n source: this,\n mode: AnnotationEditorType.HIGHLIGHT,\n });\n this.showAllEditors(\"highlight\", true, /* updateButton = */ true);\n }\n for (const layer of this.#allLayers.values()) {\n if (layer.hasTextLayer(textLayer)) {\n layer.createAndAddNewEditor({ x: 0, y: 0 }, false, {\n methodOfCreation,\n boxes,\n anchorNode,\n anchorOffset,\n focusNode,\n focusOffset,\n text,\n });\n break;\n }\n }\n }\n\n #displayHighlightToolbar() {\n const selection = document.getSelection();\n if (!selection || selection.isCollapsed) {\n return;\n }\n const anchorElement = this.#getAnchorElementForSelection(selection);\n const textLayer = anchorElement.closest(\".textLayer\");\n const boxes = this.getSelectionBoxes(textLayer);\n if (!boxes) {\n return;\n }\n this.#highlightToolbar ||= new HighlightToolbar(this);\n this.#highlightToolbar.show(textLayer, boxes, this.direction === \"ltr\");\n }\n\n /**\n * Add an editor in the annotation storage.\n * @param {AnnotationEditor} editor\n */\n addToAnnotationStorage(editor) {\n if (\n !editor.isEmpty() &&\n this.#annotationStorage &&\n !this.#annotationStorage.has(editor.id)\n ) {\n this.#annotationStorage.setValue(editor.id, editor);\n }\n }\n\n #selectionChange() {\n const selection = document.getSelection();\n if (!selection || selection.isCollapsed) {\n if (this.#selectedTextNode) {\n this.#highlightToolbar?.hide();\n this.#selectedTextNode = null;\n this.#dispatchUpdateStates({\n hasSelectedText: false,\n });\n }\n return;\n }\n const { anchorNode } = selection;\n if (anchorNode === this.#selectedTextNode) {\n return;\n }\n\n const anchorElement = this.#getAnchorElementForSelection(selection);\n const textLayer = anchorElement.closest(\".textLayer\");\n if (!textLayer) {\n if (this.#selectedTextNode) {\n this.#highlightToolbar?.hide();\n this.#selectedTextNode = null;\n this.#dispatchUpdateStates({\n hasSelectedText: false,\n });\n }\n return;\n }\n this.#highlightToolbar?.hide();\n this.#selectedTextNode = anchorNode;\n this.#dispatchUpdateStates({\n hasSelectedText: true,\n });\n\n if (\n this.#mode !== AnnotationEditorType.HIGHLIGHT &&\n this.#mode !== AnnotationEditorType.NONE\n ) {\n return;\n }\n\n if (this.#mode === AnnotationEditorType.HIGHLIGHT) {\n this.showAllEditors(\"highlight\", true, /* updateButton = */ true);\n }\n\n this.#highlightWhenShiftUp = this.isShiftKeyDown;\n if (!this.isShiftKeyDown) {\n const pointerup = e => {\n if (e.type === \"pointerup\" && e.button !== 0) {\n // Do nothing on right click.\n return;\n }\n window.removeEventListener(\"pointerup\", pointerup);\n window.removeEventListener(\"blur\", pointerup);\n if (e.type === \"pointerup\") {\n this.#onSelectEnd(\"main_toolbar\");\n }\n };\n window.addEventListener(\"pointerup\", pointerup);\n window.addEventListener(\"blur\", pointerup);\n }\n }\n\n #onSelectEnd(methodOfCreation = \"\") {\n if (this.#mode === AnnotationEditorType.HIGHLIGHT) {\n this.highlightSelection(methodOfCreation);\n } else if (this.#enableHighlightFloatingButton) {\n this.#displayHighlightToolbar();\n }\n }\n\n #addSelectionListener() {\n document.addEventListener(\"selectionchange\", this.#boundSelectionChange);\n }\n\n #removeSelectionListener() {\n document.removeEventListener(\"selectionchange\", this.#boundSelectionChange);\n }\n\n #addFocusManager() {\n window.addEventListener(\"focus\", this.#boundFocus);\n window.addEventListener(\"blur\", this.#boundBlur);\n }\n\n #removeFocusManager() {\n window.removeEventListener(\"focus\", this.#boundFocus);\n window.removeEventListener(\"blur\", this.#boundBlur);\n }\n\n blur() {\n this.isShiftKeyDown = false;\n if (this.#highlightWhenShiftUp) {\n this.#highlightWhenShiftUp = false;\n this.#onSelectEnd(\"main_toolbar\");\n }\n if (!this.hasSelection) {\n return;\n }\n // When several editors are selected and the window loses focus, we want to\n // keep the last active element in order to be able to focus it again when\n // the window gets the focus back but we don't want to trigger any focus\n // callbacks else only one editor will be selected.\n const { activeElement } = document;\n for (const editor of this.#selectedEditors) {\n if (editor.div.contains(activeElement)) {\n this.#lastActiveElement = [editor, activeElement];\n editor._focusEventsAllowed = false;\n break;\n }\n }\n }\n\n focus() {\n if (!this.#lastActiveElement) {\n return;\n }\n const [lastEditor, lastActiveElement] = this.#lastActiveElement;\n this.#lastActiveElement = null;\n lastActiveElement.addEventListener(\n \"focusin\",\n () => {\n lastEditor._focusEventsAllowed = true;\n },\n { once: true }\n );\n lastActiveElement.focus();\n }\n\n #addKeyboardManager() {\n // The keyboard events are caught at the container level in order to be able\n // to execute some callbacks even if the current page doesn't have focus.\n window.addEventListener(\"keydown\", this.#boundKeydown);\n window.addEventListener(\"keyup\", this.#boundKeyup);\n }\n\n #removeKeyboardManager() {\n window.removeEventListener(\"keydown\", this.#boundKeydown);\n window.removeEventListener(\"keyup\", this.#boundKeyup);\n }\n\n #addCopyPasteListeners() {\n document.addEventListener(\"copy\", this.#boundCopy);\n document.addEventListener(\"cut\", this.#boundCut);\n document.addEventListener(\"paste\", this.#boundPaste);\n }\n\n #removeCopyPasteListeners() {\n document.removeEventListener(\"copy\", this.#boundCopy);\n document.removeEventListener(\"cut\", this.#boundCut);\n document.removeEventListener(\"paste\", this.#boundPaste);\n }\n\n #addDragAndDropListeners() {\n document.addEventListener(\"dragover\", this.#boundDragOver);\n document.addEventListener(\"drop\", this.#boundDrop);\n }\n\n #removeDragAndDropListeners() {\n document.removeEventListener(\"dragover\", this.#boundDragOver);\n document.removeEventListener(\"drop\", this.#boundDrop);\n }\n\n addEditListeners() {\n this.#addKeyboardManager();\n this.#addCopyPasteListeners();\n }\n\n removeEditListeners() {\n this.#removeKeyboardManager();\n this.#removeCopyPasteListeners();\n }\n\n dragOver(event) {\n for (const { type } of event.dataTransfer.items) {\n for (const editorType of this.#editorTypes) {\n if (editorType.isHandlingMimeForPasting(type)) {\n event.dataTransfer.dropEffect = \"copy\";\n event.preventDefault();\n return;\n }\n }\n }\n }\n\n /**\n * Drop callback.\n * @param {DragEvent} event\n */\n drop(event) {\n for (const item of event.dataTransfer.items) {\n for (const editorType of this.#editorTypes) {\n if (editorType.isHandlingMimeForPasting(item.type)) {\n editorType.paste(item, this.currentLayer);\n event.preventDefault();\n return;\n }\n }\n }\n }\n\n /**\n * Copy callback.\n * @param {ClipboardEvent} event\n */\n copy(event) {\n event.preventDefault();\n\n // An editor is being edited so just commit it.\n this.#activeEditor?.commitOrRemove();\n\n if (!this.hasSelection) {\n return;\n }\n\n const editors = [];\n for (const editor of this.#selectedEditors) {\n const serialized = editor.serialize(/* isForCopying = */ true);\n if (serialized) {\n editors.push(serialized);\n }\n }\n if (editors.length === 0) {\n return;\n }\n\n event.clipboardData.setData(\"application/pdfjs\", JSON.stringify(editors));\n }\n\n /**\n * Cut callback.\n * @param {ClipboardEvent} event\n */\n cut(event) {\n this.copy(event);\n this.delete();\n }\n\n /**\n * Paste callback.\n * @param {ClipboardEvent} event\n */\n paste(event) {\n event.preventDefault();\n const { clipboardData } = event;\n for (const item of clipboardData.items) {\n for (const editorType of this.#editorTypes) {\n if (editorType.isHandlingMimeForPasting(item.type)) {\n editorType.paste(item, this.currentLayer);\n return;\n }\n }\n }\n\n let data = clipboardData.getData(\"application/pdfjs\");\n if (!data) {\n return;\n }\n\n try {\n data = JSON.parse(data);\n } catch (ex) {\n warn(`paste: \"${ex.message}\".`);\n return;\n }\n\n if (!Array.isArray(data)) {\n return;\n }\n\n this.unselectAll();\n const layer = this.currentLayer;\n\n try {\n const newEditors = [];\n for (const editor of data) {\n const deserializedEditor = layer.deserialize(editor);\n if (!deserializedEditor) {\n return;\n }\n newEditors.push(deserializedEditor);\n }\n\n const cmd = () => {\n for (const editor of newEditors) {\n this.#addEditorToLayer(editor);\n }\n this.#selectEditors(newEditors);\n };\n const undo = () => {\n for (const editor of newEditors) {\n editor.remove();\n }\n };\n this.addCommands({ cmd, undo, mustExec: true });\n } catch (ex) {\n warn(`paste: \"${ex.message}\".`);\n }\n }\n\n /**\n * Keydown callback.\n * @param {KeyboardEvent} event\n */\n keydown(event) {\n if (!this.isShiftKeyDown && event.key === \"Shift\") {\n this.isShiftKeyDown = true;\n }\n if (\n this.#mode !== AnnotationEditorType.NONE &&\n !this.isEditorHandlingKeyboard\n ) {\n AnnotationEditorUIManager._keyboardManager.exec(this, event);\n }\n }\n\n /**\n * Keyup callback.\n * @param {KeyboardEvent} event\n */\n keyup(event) {\n if (this.isShiftKeyDown && event.key === \"Shift\") {\n this.isShiftKeyDown = false;\n if (this.#highlightWhenShiftUp) {\n this.#highlightWhenShiftUp = false;\n this.#onSelectEnd(\"main_toolbar\");\n }\n }\n }\n\n /**\n * Execute an action for a given name.\n * For example, the user can click on the \"Undo\" entry in the context menu\n * and it'll trigger the undo action.\n */\n onEditingAction({ name }) {\n switch (name) {\n case \"undo\":\n case \"redo\":\n case \"delete\":\n case \"selectAll\":\n this[name]();\n break;\n case \"highlightSelection\":\n this.highlightSelection(\"context_menu\");\n break;\n }\n }\n\n /**\n * Update the different possible states of this manager, e.g. is there\n * something to undo, redo, ...\n * @param {Object} details\n */\n #dispatchUpdateStates(details) {\n const hasChanged = Object.entries(details).some(\n ([key, value]) => this.#previousStates[key] !== value\n );\n\n if (hasChanged) {\n this._eventBus.dispatch(\"annotationeditorstateschanged\", {\n source: this,\n details: Object.assign(this.#previousStates, details),\n });\n // We could listen on our own event but it sounds like a bit weird and\n // it's a way to simpler to handle that stuff here instead of having to\n // add something in every place where an editor can be unselected.\n if (\n this.#mode === AnnotationEditorType.HIGHLIGHT &&\n details.hasSelectedEditor === false\n ) {\n this.#dispatchUpdateUI([\n [AnnotationEditorParamsType.HIGHLIGHT_FREE, true],\n ]);\n }\n }\n }\n\n #dispatchUpdateUI(details) {\n this._eventBus.dispatch(\"annotationeditorparamschanged\", {\n source: this,\n details,\n });\n }\n\n /**\n * Set the editing state.\n * It can be useful to temporarily disable it when the user is editing a\n * FreeText annotation.\n * @param {boolean} isEditing\n */\n setEditingState(isEditing) {\n if (isEditing) {\n this.#addFocusManager();\n this.#addCopyPasteListeners();\n this.#dispatchUpdateStates({\n isEditing: this.#mode !== AnnotationEditorType.NONE,\n isEmpty: this.#isEmpty(),\n hasSomethingToUndo: this.#commandManager.hasSomethingToUndo(),\n hasSomethingToRedo: this.#commandManager.hasSomethingToRedo(),\n hasSelectedEditor: false,\n });\n } else {\n this.#removeFocusManager();\n this.#removeCopyPasteListeners();\n this.#dispatchUpdateStates({\n isEditing: false,\n });\n this.disableUserSelect(false);\n }\n }\n\n registerEditorTypes(types) {\n if (this.#editorTypes) {\n return;\n }\n this.#editorTypes = types;\n for (const editorType of this.#editorTypes) {\n this.#dispatchUpdateUI(editorType.defaultPropertiesToUpdate);\n }\n }\n\n /**\n * Get an id.\n * @returns {string}\n */\n getId() {\n return this.#idManager.id;\n }\n\n get currentLayer() {\n return this.#allLayers.get(this.#currentPageIndex);\n }\n\n getLayer(pageIndex) {\n return this.#allLayers.get(pageIndex);\n }\n\n get currentPageIndex() {\n return this.#currentPageIndex;\n }\n\n /**\n * Add a new layer for a page which will contains the editors.\n * @param {AnnotationEditorLayer} layer\n */\n addLayer(layer) {\n this.#allLayers.set(layer.pageIndex, layer);\n if (this.#isEnabled) {\n layer.enable();\n } else {\n layer.disable();\n }\n }\n\n /**\n * Remove a layer.\n * @param {AnnotationEditorLayer} layer\n */\n removeLayer(layer) {\n this.#allLayers.delete(layer.pageIndex);\n }\n\n /**\n * Change the editor mode (None, FreeText, Ink, ...)\n * @param {number} mode\n * @param {string|null} editId\n * @param {boolean} [isFromKeyboard] - true if the mode change is due to a\n * keyboard action.\n */\n updateMode(mode, editId = null, isFromKeyboard = false) {\n if (this.#mode === mode) {\n return;\n }\n this.#mode = mode;\n if (mode === AnnotationEditorType.NONE) {\n this.setEditingState(false);\n this.#disableAll();\n return;\n }\n this.setEditingState(true);\n this.#enableAll();\n this.unselectAll();\n for (const layer of this.#allLayers.values()) {\n layer.updateMode(mode);\n }\n if (!editId && isFromKeyboard) {\n this.addNewEditorFromKeyboard();\n return;\n }\n\n if (!editId) {\n return;\n }\n for (const editor of this.#allEditors.values()) {\n if (editor.annotationElementId === editId) {\n this.setSelected(editor);\n editor.enterInEditMode();\n break;\n }\n }\n }\n\n addNewEditorFromKeyboard() {\n if (this.currentLayer.canCreateNewEmptyEditor()) {\n this.currentLayer.addNewEditor();\n }\n }\n\n /**\n * Update the toolbar if it's required to reflect the tool currently used.\n * @param {number} mode\n * @returns {undefined}\n */\n updateToolbar(mode) {\n if (mode === this.#mode) {\n return;\n }\n this._eventBus.dispatch(\"switchannotationeditormode\", {\n source: this,\n mode,\n });\n }\n\n /**\n * Update a parameter in the current editor or globally.\n * @param {number} type\n * @param {*} value\n */\n updateParams(type, value) {\n if (!this.#editorTypes) {\n return;\n }\n\n switch (type) {\n case AnnotationEditorParamsType.CREATE:\n this.currentLayer.addNewEditor();\n return;\n case AnnotationEditorParamsType.HIGHLIGHT_DEFAULT_COLOR:\n this.#mainHighlightColorPicker?.updateColor(value);\n break;\n case AnnotationEditorParamsType.HIGHLIGHT_SHOW_ALL:\n this._eventBus.dispatch(\"reporttelemetry\", {\n source: this,\n details: {\n type: \"editing\",\n data: {\n type: \"highlight\",\n action: \"toggle_visibility\",\n },\n },\n });\n (this.#showAllStates ||= new Map()).set(type, value);\n this.showAllEditors(\"highlight\", value);\n break;\n }\n\n for (const editor of this.#selectedEditors) {\n editor.updateParams(type, value);\n }\n\n for (const editorType of this.#editorTypes) {\n editorType.updateDefaultParams(type, value);\n }\n }\n\n showAllEditors(type, visible, updateButton = false) {\n for (const editor of this.#allEditors.values()) {\n if (editor.editorType === type) {\n editor.show(visible);\n }\n }\n const state =\n this.#showAllStates?.get(AnnotationEditorParamsType.HIGHLIGHT_SHOW_ALL) ??\n true;\n if (state !== visible) {\n this.#dispatchUpdateUI([\n [AnnotationEditorParamsType.HIGHLIGHT_SHOW_ALL, visible],\n ]);\n }\n }\n\n enableWaiting(mustWait = false) {\n if (this.#isWaiting === mustWait) {\n return;\n }\n this.#isWaiting = mustWait;\n for (const layer of this.#allLayers.values()) {\n if (mustWait) {\n layer.disableClick();\n } else {\n layer.enableClick();\n }\n layer.div.classList.toggle(\"waiting\", mustWait);\n }\n }\n\n /**\n * Enable all the layers.\n */\n #enableAll() {\n if (!this.#isEnabled) {\n this.#isEnabled = true;\n for (const layer of this.#allLayers.values()) {\n layer.enable();\n }\n for (const editor of this.#allEditors.values()) {\n editor.enable();\n }\n }\n }\n\n /**\n * Disable all the layers.\n */\n #disableAll() {\n this.unselectAll();\n if (this.#isEnabled) {\n this.#isEnabled = false;\n for (const layer of this.#allLayers.values()) {\n layer.disable();\n }\n for (const editor of this.#allEditors.values()) {\n editor.disable();\n }\n }\n }\n\n /**\n * Get all the editors belonging to a given page.\n * @param {number} pageIndex\n * @returns {Array}\n */\n getEditors(pageIndex) {\n const editors = [];\n for (const editor of this.#allEditors.values()) {\n if (editor.pageIndex === pageIndex) {\n editors.push(editor);\n }\n }\n return editors;\n }\n\n /**\n * Get an editor with the given id.\n * @param {string} id\n * @returns {AnnotationEditor}\n */\n getEditor(id) {\n return this.#allEditors.get(id);\n }\n\n /**\n * Add a new editor.\n * @param {AnnotationEditor} editor\n */\n addEditor(editor) {\n this.#allEditors.set(editor.id, editor);\n }\n\n /**\n * Remove an editor.\n * @param {AnnotationEditor} editor\n */\n removeEditor(editor) {\n if (editor.div.contains(document.activeElement)) {\n if (this.#focusMainContainerTimeoutId) {\n clearTimeout(this.#focusMainContainerTimeoutId);\n }\n this.#focusMainContainerTimeoutId = setTimeout(() => {\n // When the div is removed from DOM the focus can move on the\n // document.body, so we need to move it back to the main container.\n this.focusMainContainer();\n this.#focusMainContainerTimeoutId = null;\n }, 0);\n }\n this.#allEditors.delete(editor.id);\n this.unselect(editor);\n if (\n !editor.annotationElementId ||\n !this.#deletedAnnotationsElementIds.has(editor.annotationElementId)\n ) {\n this.#annotationStorage?.remove(editor.id);\n }\n }\n\n /**\n * The annotation element with the given id has been deleted.\n * @param {AnnotationEditor} editor\n */\n addDeletedAnnotationElement(editor) {\n this.#deletedAnnotationsElementIds.add(editor.annotationElementId);\n this.addChangedExistingAnnotation(editor);\n editor.deleted = true;\n }\n\n /**\n * Check if the annotation element with the given id has been deleted.\n * @param {string} annotationElementId\n * @returns {boolean}\n */\n isDeletedAnnotationElement(annotationElementId) {\n return this.#deletedAnnotationsElementIds.has(annotationElementId);\n }\n\n /**\n * The annotation element with the given id have been restored.\n * @param {AnnotationEditor} editor\n */\n removeDeletedAnnotationElement(editor) {\n this.#deletedAnnotationsElementIds.delete(editor.annotationElementId);\n this.removeChangedExistingAnnotation(editor);\n editor.deleted = false;\n }\n\n /**\n * Add an editor to the layer it belongs to or add it to the global map.\n * @param {AnnotationEditor} editor\n */\n #addEditorToLayer(editor) {\n const layer = this.#allLayers.get(editor.pageIndex);\n if (layer) {\n layer.addOrRebuild(editor);\n } else {\n this.addEditor(editor);\n this.addToAnnotationStorage(editor);\n }\n }\n\n /**\n * Set the given editor as the active one.\n * @param {AnnotationEditor} editor\n */\n setActiveEditor(editor) {\n if (this.#activeEditor === editor) {\n return;\n }\n\n this.#activeEditor = editor;\n if (editor) {\n this.#dispatchUpdateUI(editor.propertiesToUpdate);\n }\n }\n\n get #lastSelectedEditor() {\n let ed = null;\n for (ed of this.#selectedEditors) {\n // Iterate to get the last element.\n }\n return ed;\n }\n\n /**\n * Update the UI of the active editor.\n * @param {AnnotationEditor} editor\n */\n updateUI(editor) {\n if (this.#lastSelectedEditor === editor) {\n this.#dispatchUpdateUI(editor.propertiesToUpdate);\n }\n }\n\n /**\n * Add or remove an editor the current selection.\n * @param {AnnotationEditor} editor\n */\n toggleSelected(editor) {\n if (this.#selectedEditors.has(editor)) {\n this.#selectedEditors.delete(editor);\n editor.unselect();\n this.#dispatchUpdateStates({\n hasSelectedEditor: this.hasSelection,\n });\n return;\n }\n this.#selectedEditors.add(editor);\n editor.select();\n this.#dispatchUpdateUI(editor.propertiesToUpdate);\n this.#dispatchUpdateStates({\n hasSelectedEditor: true,\n });\n }\n\n /**\n * Set the last selected editor.\n * @param {AnnotationEditor} editor\n */\n setSelected(editor) {\n for (const ed of this.#selectedEditors) {\n if (ed !== editor) {\n ed.unselect();\n }\n }\n this.#selectedEditors.clear();\n\n this.#selectedEditors.add(editor);\n editor.select();\n this.#dispatchUpdateUI(editor.propertiesToUpdate);\n this.#dispatchUpdateStates({\n hasSelectedEditor: true,\n });\n }\n\n /**\n * Check if the editor is selected.\n * @param {AnnotationEditor} editor\n */\n isSelected(editor) {\n return this.#selectedEditors.has(editor);\n }\n\n get firstSelectedEditor() {\n return this.#selectedEditors.values().next().value;\n }\n\n /**\n * Unselect an editor.\n * @param {AnnotationEditor} editor\n */\n unselect(editor) {\n editor.unselect();\n this.#selectedEditors.delete(editor);\n this.#dispatchUpdateStates({\n hasSelectedEditor: this.hasSelection,\n });\n }\n\n get hasSelection() {\n return this.#selectedEditors.size !== 0;\n }\n\n get isEnterHandled() {\n return (\n this.#selectedEditors.size === 1 &&\n this.firstSelectedEditor.isEnterHandled\n );\n }\n\n /**\n * Undo the last command.\n */\n undo() {\n this.#commandManager.undo();\n this.#dispatchUpdateStates({\n hasSomethingToUndo: this.#commandManager.hasSomethingToUndo(),\n hasSomethingToRedo: true,\n isEmpty: this.#isEmpty(),\n });\n }\n\n /**\n * Redo the last undoed command.\n */\n redo() {\n this.#commandManager.redo();\n this.#dispatchUpdateStates({\n hasSomethingToUndo: true,\n hasSomethingToRedo: this.#commandManager.hasSomethingToRedo(),\n isEmpty: this.#isEmpty(),\n });\n }\n\n /**\n * Add a command to execute (cmd) and another one to undo it.\n * @param {Object} params\n */\n addCommands(params) {\n this.#commandManager.add(params);\n this.#dispatchUpdateStates({\n hasSomethingToUndo: true,\n hasSomethingToRedo: false,\n isEmpty: this.#isEmpty(),\n });\n }\n\n #isEmpty() {\n if (this.#allEditors.size === 0) {\n return true;\n }\n\n if (this.#allEditors.size === 1) {\n for (const editor of this.#allEditors.values()) {\n return editor.isEmpty();\n }\n }\n\n return false;\n }\n\n /**\n * Delete the current editor or all.\n */\n delete() {\n this.commitOrRemove();\n if (!this.hasSelection) {\n return;\n }\n\n const editors = [...this.#selectedEditors];\n const cmd = () => {\n for (const editor of editors) {\n editor.remove();\n }\n };\n const undo = () => {\n for (const editor of editors) {\n this.#addEditorToLayer(editor);\n }\n };\n\n this.addCommands({ cmd, undo, mustExec: true });\n }\n\n commitOrRemove() {\n // An editor is being edited so just commit it.\n this.#activeEditor?.commitOrRemove();\n }\n\n hasSomethingToControl() {\n return this.#activeEditor || this.hasSelection;\n }\n\n /**\n * Select the editors.\n * @param {Array} editors\n */\n #selectEditors(editors) {\n for (const editor of this.#selectedEditors) {\n editor.unselect();\n }\n this.#selectedEditors.clear();\n for (const editor of editors) {\n if (editor.isEmpty()) {\n continue;\n }\n this.#selectedEditors.add(editor);\n editor.select();\n }\n this.#dispatchUpdateStates({ hasSelectedEditor: this.hasSelection });\n }\n\n /**\n * Select all the editors.\n */\n selectAll() {\n for (const editor of this.#selectedEditors) {\n editor.commit();\n }\n this.#selectEditors(this.#allEditors.values());\n }\n\n /**\n * Unselect all the selected editors.\n */\n unselectAll() {\n if (this.#activeEditor) {\n // An editor is being edited so just commit it.\n this.#activeEditor.commitOrRemove();\n if (this.#mode !== AnnotationEditorType.NONE) {\n // If the mode is NONE, we want to really unselect the editor, hence we\n // mustn't return here.\n return;\n }\n }\n\n if (!this.hasSelection) {\n return;\n }\n for (const editor of this.#selectedEditors) {\n editor.unselect();\n }\n this.#selectedEditors.clear();\n this.#dispatchUpdateStates({\n hasSelectedEditor: false,\n });\n }\n\n translateSelectedEditors(x, y, noCommit = false) {\n if (!noCommit) {\n this.commitOrRemove();\n }\n if (!this.hasSelection) {\n return;\n }\n\n this.#translation[0] += x;\n this.#translation[1] += y;\n const [totalX, totalY] = this.#translation;\n const editors = [...this.#selectedEditors];\n\n // We don't want to have an undo/redo for each translation so we wait a bit\n // before adding the command to the command manager.\n const TIME_TO_WAIT = 1000;\n\n if (this.#translationTimeoutId) {\n clearTimeout(this.#translationTimeoutId);\n }\n\n this.#translationTimeoutId = setTimeout(() => {\n this.#translationTimeoutId = null;\n this.#translation[0] = this.#translation[1] = 0;\n\n this.addCommands({\n cmd: () => {\n for (const editor of editors) {\n if (this.#allEditors.has(editor.id)) {\n editor.translateInPage(totalX, totalY);\n }\n }\n },\n undo: () => {\n for (const editor of editors) {\n if (this.#allEditors.has(editor.id)) {\n editor.translateInPage(-totalX, -totalY);\n }\n }\n },\n mustExec: false,\n });\n }, TIME_TO_WAIT);\n\n for (const editor of editors) {\n editor.translateInPage(x, y);\n }\n }\n\n /**\n * Set up the drag session for moving the selected editors.\n */\n setUpDragSession() {\n // Note: don't use any references to the editor's parent which can be null\n // if the editor belongs to a destroyed page.\n if (!this.hasSelection) {\n return;\n }\n // Avoid to have spurious text selection in the text layer when dragging.\n this.disableUserSelect(true);\n this.#draggingEditors = new Map();\n for (const editor of this.#selectedEditors) {\n this.#draggingEditors.set(editor, {\n savedX: editor.x,\n savedY: editor.y,\n savedPageIndex: editor.pageIndex,\n newX: 0,\n newY: 0,\n newPageIndex: -1,\n });\n }\n }\n\n /**\n * Ends the drag session.\n * @returns {boolean} true if at least one editor has been moved.\n */\n endDragSession() {\n if (!this.#draggingEditors) {\n return false;\n }\n this.disableUserSelect(false);\n const map = this.#draggingEditors;\n this.#draggingEditors = null;\n let mustBeAddedInUndoStack = false;\n\n for (const [{ x, y, pageIndex }, value] of map) {\n value.newX = x;\n value.newY = y;\n value.newPageIndex = pageIndex;\n mustBeAddedInUndoStack ||=\n x !== value.savedX ||\n y !== value.savedY ||\n pageIndex !== value.savedPageIndex;\n }\n\n if (!mustBeAddedInUndoStack) {\n return false;\n }\n\n const move = (editor, x, y, pageIndex) => {\n if (this.#allEditors.has(editor.id)) {\n // The editor can be undone/redone on a page which is not visible (and\n // which potentially has no annotation editor layer), hence we need to\n // use the pageIndex instead of the parent.\n const parent = this.#allLayers.get(pageIndex);\n if (parent) {\n editor._setParentAndPosition(parent, x, y);\n } else {\n editor.pageIndex = pageIndex;\n editor.x = x;\n editor.y = y;\n }\n }\n };\n\n this.addCommands({\n cmd: () => {\n for (const [editor, { newX, newY, newPageIndex }] of map) {\n move(editor, newX, newY, newPageIndex);\n }\n },\n undo: () => {\n for (const [editor, { savedX, savedY, savedPageIndex }] of map) {\n move(editor, savedX, savedY, savedPageIndex);\n }\n },\n mustExec: true,\n });\n\n return true;\n }\n\n /**\n * Drag the set of selected editors.\n * @param {number} tx\n * @param {number} ty\n */\n dragSelectedEditors(tx, ty) {\n if (!this.#draggingEditors) {\n return;\n }\n for (const editor of this.#draggingEditors.keys()) {\n editor.drag(tx, ty);\n }\n }\n\n /**\n * Rebuild the editor (usually on undo/redo actions) on a potentially\n * non-rendered page.\n * @param {AnnotationEditor} editor\n */\n rebuild(editor) {\n if (editor.parent === null) {\n const parent = this.getLayer(editor.pageIndex);\n if (parent) {\n parent.changeParent(editor);\n parent.addOrRebuild(editor);\n } else {\n this.addEditor(editor);\n this.addToAnnotationStorage(editor);\n editor.rebuild();\n }\n } else {\n editor.parent.addOrRebuild(editor);\n }\n }\n\n get isEditorHandlingKeyboard() {\n return (\n this.getActive()?.shouldGetKeyboardEvents() ||\n (this.#selectedEditors.size === 1 &&\n this.firstSelectedEditor.shouldGetKeyboardEvents())\n );\n }\n\n /**\n * Is the current editor the one passed as argument?\n * @param {AnnotationEditor} editor\n * @returns\n */\n isActive(editor) {\n return this.#activeEditor === editor;\n }\n\n /**\n * Get the current active editor.\n * @returns {AnnotationEditor|null}\n */\n getActive() {\n return this.#activeEditor;\n }\n\n /**\n * Get the current editor mode.\n * @returns {number}\n */\n getMode() {\n return this.#mode;\n }\n\n get imageManager() {\n return shadow(this, \"imageManager\", new ImageManager());\n }\n\n getSelectionBoxes(textLayer) {\n if (!textLayer) {\n return null;\n }\n const selection = document.getSelection();\n for (let i = 0, ii = selection.rangeCount; i < ii; i++) {\n if (\n !textLayer.contains(selection.getRangeAt(i).commonAncestorContainer)\n ) {\n return null;\n }\n }\n\n const {\n x: layerX,\n y: layerY,\n width: parentWidth,\n height: parentHeight,\n } = textLayer.getBoundingClientRect();\n\n // We must rotate the boxes because we want to have them in the non-rotated\n // page coordinates.\n let rotator;\n switch (textLayer.getAttribute(\"data-main-rotation\")) {\n case \"90\":\n rotator = (x, y, w, h) => ({\n x: (y - layerY) / parentHeight,\n y: 1 - (x + w - layerX) / parentWidth,\n width: h / parentHeight,\n height: w / parentWidth,\n });\n break;\n case \"180\":\n rotator = (x, y, w, h) => ({\n x: 1 - (x + w - layerX) / parentWidth,\n y: 1 - (y + h - layerY) / parentHeight,\n width: w / parentWidth,\n height: h / parentHeight,\n });\n break;\n case \"270\":\n rotator = (x, y, w, h) => ({\n x: 1 - (y + h - layerY) / parentHeight,\n y: (x - layerX) / parentWidth,\n width: h / parentHeight,\n height: w / parentWidth,\n });\n break;\n default:\n rotator = (x, y, w, h) => ({\n x: (x - layerX) / parentWidth,\n y: (y - layerY) / parentHeight,\n width: w / parentWidth,\n height: h / parentHeight,\n });\n break;\n }\n\n const boxes = [];\n for (let i = 0, ii = selection.rangeCount; i < ii; i++) {\n const range = selection.getRangeAt(i);\n if (range.collapsed) {\n continue;\n }\n for (const { x, y, width, height } of range.getClientRects()) {\n if (width === 0 || height === 0) {\n continue;\n }\n boxes.push(rotator(x, y, width, height));\n }\n }\n return boxes.length === 0 ? null : boxes;\n }\n\n addChangedExistingAnnotation({ annotationElementId, id }) {\n (this.#changedExistingAnnotations ||= new Map()).set(\n annotationElementId,\n id\n );\n }\n\n removeChangedExistingAnnotation({ annotationElementId }) {\n this.#changedExistingAnnotations?.delete(annotationElementId);\n }\n\n renderAnnotationElement(annotation) {\n const editorId = this.#changedExistingAnnotations?.get(annotation.data.id);\n if (!editorId) {\n return;\n }\n const editor = this.#annotationStorage.getRawValue(editorId);\n if (!editor) {\n return;\n }\n if (this.#mode === AnnotationEditorType.NONE && !editor.hasBeenModified) {\n return;\n }\n editor.renderAnnotationElement(annotation);\n }\n}\n\nexport {\n AnnotationEditorUIManager,\n bindEvents,\n ColorManager,\n CommandManager,\n KeyboardManager,\n opacityToHex,\n};\n","/* Copyright 2023 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { noContextMenu } from \"../display_utils.js\";\n\nclass AltText {\n #altText = \"\";\n\n #altTextDecorative = false;\n\n #altTextButton = null;\n\n #altTextTooltip = null;\n\n #altTextTooltipTimeout = null;\n\n #altTextWasFromKeyBoard = false;\n\n #editor = null;\n\n static _l10nPromise = null;\n\n constructor(editor) {\n this.#editor = editor;\n }\n\n static initialize(l10nPromise) {\n AltText._l10nPromise ||= l10nPromise;\n }\n\n async render() {\n const altText = (this.#altTextButton = document.createElement(\"button\"));\n altText.className = \"altText\";\n const msg = await AltText._l10nPromise.get(\n \"pdfjs-editor-alt-text-button-label\"\n );\n altText.textContent = msg;\n altText.setAttribute(\"aria-label\", msg);\n altText.tabIndex = \"0\";\n altText.addEventListener(\"contextmenu\", noContextMenu);\n altText.addEventListener(\"pointerdown\", event => event.stopPropagation());\n\n const onClick = event => {\n event.preventDefault();\n this.#editor._uiManager.editAltText(this.#editor);\n };\n altText.addEventListener(\"click\", onClick, { capture: true });\n altText.addEventListener(\"keydown\", event => {\n if (event.target === altText && event.key === \"Enter\") {\n this.#altTextWasFromKeyBoard = true;\n onClick(event);\n }\n });\n await this.#setState();\n\n return altText;\n }\n\n finish() {\n if (!this.#altTextButton) {\n return;\n }\n this.#altTextButton.focus({ focusVisible: this.#altTextWasFromKeyBoard });\n this.#altTextWasFromKeyBoard = false;\n }\n\n isEmpty() {\n return !this.#altText && !this.#altTextDecorative;\n }\n\n get data() {\n return {\n altText: this.#altText,\n decorative: this.#altTextDecorative,\n };\n }\n\n /**\n * Set the alt text data.\n */\n set data({ altText, decorative }) {\n if (this.#altText === altText && this.#altTextDecorative === decorative) {\n return;\n }\n this.#altText = altText;\n this.#altTextDecorative = decorative;\n this.#setState();\n }\n\n toggle(enabled = false) {\n if (!this.#altTextButton) {\n return;\n }\n if (!enabled && this.#altTextTooltipTimeout) {\n clearTimeout(this.#altTextTooltipTimeout);\n this.#altTextTooltipTimeout = null;\n }\n this.#altTextButton.disabled = !enabled;\n }\n\n destroy() {\n this.#altTextButton?.remove();\n this.#altTextButton = null;\n this.#altTextTooltip = null;\n }\n\n async #setState() {\n const button = this.#altTextButton;\n if (!button) {\n return;\n }\n if (!this.#altText && !this.#altTextDecorative) {\n button.classList.remove(\"done\");\n this.#altTextTooltip?.remove();\n return;\n }\n button.classList.add(\"done\");\n\n AltText._l10nPromise\n .get(\"pdfjs-editor-alt-text-edit-button-label\")\n .then(msg => {\n button.setAttribute(\"aria-label\", msg);\n });\n let tooltip = this.#altTextTooltip;\n if (!tooltip) {\n this.#altTextTooltip = tooltip = document.createElement(\"span\");\n tooltip.className = \"tooltip\";\n tooltip.setAttribute(\"role\", \"tooltip\");\n const id = (tooltip.id = `alt-text-tooltip-${this.#editor.id}`);\n button.setAttribute(\"aria-describedby\", id);\n\n const DELAY_TO_SHOW_TOOLTIP = 100;\n button.addEventListener(\"mouseenter\", () => {\n this.#altTextTooltipTimeout = setTimeout(() => {\n this.#altTextTooltipTimeout = null;\n this.#altTextTooltip.classList.add(\"show\");\n this.#editor._reportTelemetry({\n action: \"alt_text_tooltip\",\n });\n }, DELAY_TO_SHOW_TOOLTIP);\n });\n button.addEventListener(\"mouseleave\", () => {\n if (this.#altTextTooltipTimeout) {\n clearTimeout(this.#altTextTooltipTimeout);\n this.#altTextTooltipTimeout = null;\n }\n this.#altTextTooltip?.classList.remove(\"show\");\n });\n }\n tooltip.innerText = this.#altTextDecorative\n ? await AltText._l10nPromise.get(\n \"pdfjs-editor-alt-text-decorative-tooltip\"\n )\n : this.#altText;\n\n if (!tooltip.parentNode) {\n button.append(tooltip);\n }\n\n const element = this.#editor.getImageForAltText();\n element?.setAttribute(\"aria-describedby\", tooltip.id);\n }\n}\n\nexport { AltText };\n","/* Copyright 2022 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// eslint-disable-next-line max-len\n/** @typedef {import(\"./annotation_editor_layer.js\").AnnotationEditorLayer} AnnotationEditorLayer */\n\nimport {\n AnnotationEditorUIManager,\n bindEvents,\n ColorManager,\n KeyboardManager,\n} from \"./tools.js\";\nimport { FeatureTest, shadow, unreachable } from \"../../shared/util.js\";\nimport { AltText } from \"./alt_text.js\";\nimport { EditorToolbar } from \"./toolbar.js\";\nimport { noContextMenu } from \"../display_utils.js\";\n\n/**\n * @typedef {Object} AnnotationEditorParameters\n * @property {AnnotationEditorUIManager} uiManager - the global manager\n * @property {AnnotationEditorLayer} parent - the layer containing this editor\n * @property {string} id - editor id\n * @property {number} x - x-coordinate\n * @property {number} y - y-coordinate\n */\n\n/**\n * Base class for editors.\n */\nclass AnnotationEditor {\n #allResizerDivs = null;\n\n #altText = null;\n\n #disabled = false;\n\n #keepAspectRatio = false;\n\n #resizersDiv = null;\n\n #savedDimensions = null;\n\n #boundFocusin = this.focusin.bind(this);\n\n #boundFocusout = this.focusout.bind(this);\n\n #editToolbar = null;\n\n #focusedResizerName = \"\";\n\n #hasBeenClicked = false;\n\n #initialPosition = null;\n\n #isEditing = false;\n\n #isInEditMode = false;\n\n #isResizerEnabledForKeyboard = false;\n\n #moveInDOMTimeout = null;\n\n #prevDragX = 0;\n\n #prevDragY = 0;\n\n #telemetryTimeouts = null;\n\n _initialOptions = Object.create(null);\n\n _isVisible = true;\n\n _uiManager = null;\n\n _focusEventsAllowed = true;\n\n _l10nPromise = null;\n\n #isDraggable = false;\n\n #zIndex = AnnotationEditor._zIndex++;\n\n static _borderLineWidth = -1;\n\n static _colorManager = new ColorManager();\n\n static _zIndex = 1;\n\n // Time to wait (in ms) before sending the telemetry data.\n // We wait a bit to avoid sending too many requests when changing something\n // like the thickness of a line.\n static _telemetryTimeout = 1000;\n\n static get _resizerKeyboardManager() {\n const resize = AnnotationEditor.prototype._resizeWithKeyboard;\n const small = AnnotationEditorUIManager.TRANSLATE_SMALL;\n const big = AnnotationEditorUIManager.TRANSLATE_BIG;\n\n return shadow(\n this,\n \"_resizerKeyboardManager\",\n new KeyboardManager([\n [[\"ArrowLeft\", \"mac+ArrowLeft\"], resize, { args: [-small, 0] }],\n [\n [\"ctrl+ArrowLeft\", \"mac+shift+ArrowLeft\"],\n resize,\n { args: [-big, 0] },\n ],\n [[\"ArrowRight\", \"mac+ArrowRight\"], resize, { args: [small, 0] }],\n [\n [\"ctrl+ArrowRight\", \"mac+shift+ArrowRight\"],\n resize,\n { args: [big, 0] },\n ],\n [[\"ArrowUp\", \"mac+ArrowUp\"], resize, { args: [0, -small] }],\n [[\"ctrl+ArrowUp\", \"mac+shift+ArrowUp\"], resize, { args: [0, -big] }],\n [[\"ArrowDown\", \"mac+ArrowDown\"], resize, { args: [0, small] }],\n [[\"ctrl+ArrowDown\", \"mac+shift+ArrowDown\"], resize, { args: [0, big] }],\n [\n [\"Escape\", \"mac+Escape\"],\n AnnotationEditor.prototype._stopResizingWithKeyboard,\n ],\n ])\n );\n }\n\n /**\n * @param {AnnotationEditorParameters} parameters\n */\n constructor(parameters) {\n if (this.constructor === AnnotationEditor) {\n unreachable(\"Cannot initialize AnnotationEditor.\");\n }\n\n this.parent = parameters.parent;\n this.id = parameters.id;\n this.width = this.height = null;\n this.pageIndex = parameters.parent.pageIndex;\n this.name = parameters.name;\n this.div = null;\n this._uiManager = parameters.uiManager;\n this.annotationElementId = null;\n this._willKeepAspectRatio = false;\n this._initialOptions.isCentered = parameters.isCentered;\n this._structTreeParentId = null;\n\n const {\n rotation,\n rawDims: { pageWidth, pageHeight, pageX, pageY },\n } = this.parent.viewport;\n\n this.rotation = rotation;\n this.pageRotation =\n (360 + rotation - this._uiManager.viewParameters.rotation) % 360;\n this.pageDimensions = [pageWidth, pageHeight];\n this.pageTranslation = [pageX, pageY];\n\n const [width, height] = this.parentDimensions;\n this.x = parameters.x / width;\n this.y = parameters.y / height;\n\n this.isAttachedToDOM = false;\n this.deleted = false;\n }\n\n get editorType() {\n return Object.getPrototypeOf(this).constructor._type;\n }\n\n static get _defaultLineColor() {\n return shadow(\n this,\n \"_defaultLineColor\",\n this._colorManager.getHexCode(\"CanvasText\")\n );\n }\n\n static deleteAnnotationElement(editor) {\n const fakeEditor = new FakeEditor({\n id: editor.parent.getNextId(),\n parent: editor.parent,\n uiManager: editor._uiManager,\n });\n fakeEditor.annotationElementId = editor.annotationElementId;\n fakeEditor.deleted = true;\n fakeEditor._uiManager.addToAnnotationStorage(fakeEditor);\n }\n\n /**\n * Initialize the l10n stuff for this type of editor.\n * @param {Object} l10n\n */\n static initialize(l10n, _uiManager, options) {\n AnnotationEditor._l10nPromise ||= new Map(\n [\n \"pdfjs-editor-alt-text-button-label\",\n \"pdfjs-editor-alt-text-edit-button-label\",\n \"pdfjs-editor-alt-text-decorative-tooltip\",\n \"pdfjs-editor-resizer-label-topLeft\",\n \"pdfjs-editor-resizer-label-topMiddle\",\n \"pdfjs-editor-resizer-label-topRight\",\n \"pdfjs-editor-resizer-label-middleRight\",\n \"pdfjs-editor-resizer-label-bottomRight\",\n \"pdfjs-editor-resizer-label-bottomMiddle\",\n \"pdfjs-editor-resizer-label-bottomLeft\",\n \"pdfjs-editor-resizer-label-middleLeft\",\n ].map(str => [\n str,\n l10n.get(str.replaceAll(/([A-Z])/g, c => `-${c.toLowerCase()}`)),\n ])\n );\n if (options?.strings) {\n for (const str of options.strings) {\n AnnotationEditor._l10nPromise.set(str, l10n.get(str));\n }\n }\n if (AnnotationEditor._borderLineWidth !== -1) {\n return;\n }\n const style = getComputedStyle(document.documentElement);\n AnnotationEditor._borderLineWidth =\n parseFloat(style.getPropertyValue(\"--outline-width\")) || 0;\n }\n\n /**\n * Update the default parameters for this type of editor.\n * @param {number} _type\n * @param {*} _value\n */\n static updateDefaultParams(_type, _value) {}\n\n /**\n * Get the default properties to set in the UI for this type of editor.\n * @returns {Array}\n */\n static get defaultPropertiesToUpdate() {\n return [];\n }\n\n /**\n * Check if this kind of editor is able to handle the given mime type for\n * pasting.\n * @param {string} mime\n * @returns {boolean}\n */\n static isHandlingMimeForPasting(mime) {\n return false;\n }\n\n /**\n * Extract the data from the clipboard item and delegate the creation of the\n * editor to the parent.\n * @param {DataTransferItem} item\n * @param {AnnotationEditorLayer} parent\n */\n static paste(item, parent) {\n unreachable(\"Not implemented\");\n }\n\n /**\n * Get the properties to update in the UI for this editor.\n * @returns {Array}\n */\n get propertiesToUpdate() {\n return [];\n }\n\n get _isDraggable() {\n return this.#isDraggable;\n }\n\n set _isDraggable(value) {\n this.#isDraggable = value;\n this.div?.classList.toggle(\"draggable\", value);\n }\n\n /**\n * @returns {boolean} true if the editor handles the Enter key itself.\n */\n get isEnterHandled() {\n return true;\n }\n\n center() {\n const [pageWidth, pageHeight] = this.pageDimensions;\n switch (this.parentRotation) {\n case 90:\n this.x -= (this.height * pageHeight) / (pageWidth * 2);\n this.y += (this.width * pageWidth) / (pageHeight * 2);\n break;\n case 180:\n this.x += this.width / 2;\n this.y += this.height / 2;\n break;\n case 270:\n this.x += (this.height * pageHeight) / (pageWidth * 2);\n this.y -= (this.width * pageWidth) / (pageHeight * 2);\n break;\n default:\n this.x -= this.width / 2;\n this.y -= this.height / 2;\n break;\n }\n this.fixAndSetPosition();\n }\n\n /**\n * Add some commands into the CommandManager (undo/redo stuff).\n * @param {Object} params\n */\n addCommands(params) {\n this._uiManager.addCommands(params);\n }\n\n get currentLayer() {\n return this._uiManager.currentLayer;\n }\n\n /**\n * This editor will be behind the others.\n */\n setInBackground() {\n this.div.style.zIndex = 0;\n }\n\n /**\n * This editor will be in the foreground.\n */\n setInForeground() {\n this.div.style.zIndex = this.#zIndex;\n }\n\n setParent(parent) {\n if (parent !== null) {\n this.pageIndex = parent.pageIndex;\n this.pageDimensions = parent.pageDimensions;\n } else {\n // The editor is being removed from the DOM, so we need to stop resizing.\n this.#stopResizing();\n }\n this.parent = parent;\n }\n\n /**\n * onfocus callback.\n */\n focusin(event) {\n if (!this._focusEventsAllowed) {\n return;\n }\n if (!this.#hasBeenClicked) {\n this.parent.setSelected(this);\n } else {\n this.#hasBeenClicked = false;\n }\n }\n\n /**\n * onblur callback.\n * @param {FocusEvent} event\n */\n focusout(event) {\n if (!this._focusEventsAllowed) {\n return;\n }\n\n if (!this.isAttachedToDOM) {\n return;\n }\n\n // In case of focusout, the relatedTarget is the element which\n // is grabbing the focus.\n // So if the related target is an element under the div for this\n // editor, then the editor isn't unactive.\n const target = event.relatedTarget;\n if (target?.closest(`#${this.id}`)) {\n return;\n }\n\n event.preventDefault();\n\n if (!this.parent?.isMultipleSelection) {\n this.commitOrRemove();\n }\n }\n\n commitOrRemove() {\n if (this.isEmpty()) {\n this.remove();\n } else {\n this.commit();\n }\n }\n\n /**\n * Commit the data contained in this editor.\n */\n commit() {\n this.addToAnnotationStorage();\n }\n\n addToAnnotationStorage() {\n this._uiManager.addToAnnotationStorage(this);\n }\n\n /**\n * Set the editor position within its parent.\n * @param {number} x\n * @param {number} y\n * @param {number} tx - x-translation in screen coordinates.\n * @param {number} ty - y-translation in screen coordinates.\n */\n setAt(x, y, tx, ty) {\n const [width, height] = this.parentDimensions;\n [tx, ty] = this.screenToPageTranslation(tx, ty);\n\n this.x = (x + tx) / width;\n this.y = (y + ty) / height;\n\n this.fixAndSetPosition();\n }\n\n #translate([width, height], x, y) {\n [x, y] = this.screenToPageTranslation(x, y);\n\n this.x += x / width;\n this.y += y / height;\n\n this.fixAndSetPosition();\n }\n\n /**\n * Translate the editor position within its parent.\n * @param {number} x - x-translation in screen coordinates.\n * @param {number} y - y-translation in screen coordinates.\n */\n translate(x, y) {\n // We don't change the initial position because the move here hasn't been\n // done by the user.\n this.#translate(this.parentDimensions, x, y);\n }\n\n /**\n * Translate the editor position within its page and adjust the scroll\n * in order to have the editor in the view.\n * @param {number} x - x-translation in page coordinates.\n * @param {number} y - y-translation in page coordinates.\n */\n translateInPage(x, y) {\n this.#initialPosition ||= [this.x, this.y];\n this.#translate(this.pageDimensions, x, y);\n this.div.scrollIntoView({ block: \"nearest\" });\n }\n\n drag(tx, ty) {\n this.#initialPosition ||= [this.x, this.y];\n const [parentWidth, parentHeight] = this.parentDimensions;\n this.x += tx / parentWidth;\n this.y += ty / parentHeight;\n if (this.parent && (this.x < 0 || this.x > 1 || this.y < 0 || this.y > 1)) {\n // It's possible to not have a parent: for example, when the user is\n // dragging all the selected editors but this one on a page which has been\n // destroyed.\n // It's why we need to check for it. In such a situation, it isn't really\n // a problem to not find a new parent: it's something which is related to\n // what the user is seeing, hence it depends on how pages are layed out.\n\n // The element will be outside of its parent so change the parent.\n const { x, y } = this.div.getBoundingClientRect();\n if (this.parent.findNewParent(this, x, y)) {\n this.x -= Math.floor(this.x);\n this.y -= Math.floor(this.y);\n }\n }\n\n // The editor can be moved wherever the user wants, so we don't need to fix\n // the position: it'll be done when the user will release the mouse button.\n\n let { x, y } = this;\n const [bx, by] = this.getBaseTranslation();\n x += bx;\n y += by;\n\n this.div.style.left = `${(100 * x).toFixed(2)}%`;\n this.div.style.top = `${(100 * y).toFixed(2)}%`;\n this.div.scrollIntoView({ block: \"nearest\" });\n }\n\n get _hasBeenMoved() {\n return (\n !!this.#initialPosition &&\n (this.#initialPosition[0] !== this.x ||\n this.#initialPosition[1] !== this.y)\n );\n }\n\n /**\n * Get the translation to take into account the editor border.\n * The CSS engine positions the element by taking the border into account so\n * we must apply the opposite translation to have the editor in the right\n * position.\n * @returns {Array}\n */\n getBaseTranslation() {\n const [parentWidth, parentHeight] = this.parentDimensions;\n const { _borderLineWidth } = AnnotationEditor;\n const x = _borderLineWidth / parentWidth;\n const y = _borderLineWidth / parentHeight;\n switch (this.rotation) {\n case 90:\n return [-x, y];\n case 180:\n return [x, y];\n case 270:\n return [x, -y];\n default:\n return [-x, -y];\n }\n }\n\n /**\n * @returns {boolean} true if position must be fixed (i.e. make the x and y\n * living in the page).\n */\n get _mustFixPosition() {\n return true;\n }\n\n /**\n * Fix the position of the editor in order to keep it inside its parent page.\n * @param {number} [rotation] - the rotation of the page.\n */\n fixAndSetPosition(rotation = this.rotation) {\n const [pageWidth, pageHeight] = this.pageDimensions;\n let { x, y, width, height } = this;\n width *= pageWidth;\n height *= pageHeight;\n x *= pageWidth;\n y *= pageHeight;\n\n if (this._mustFixPosition) {\n switch (rotation) {\n case 0:\n x = Math.max(0, Math.min(pageWidth - width, x));\n y = Math.max(0, Math.min(pageHeight - height, y));\n break;\n case 90:\n x = Math.max(0, Math.min(pageWidth - height, x));\n y = Math.min(pageHeight, Math.max(width, y));\n break;\n case 180:\n x = Math.min(pageWidth, Math.max(width, x));\n y = Math.min(pageHeight, Math.max(height, y));\n break;\n case 270:\n x = Math.min(pageWidth, Math.max(height, x));\n y = Math.max(0, Math.min(pageHeight - width, y));\n break;\n }\n }\n\n this.x = x /= pageWidth;\n this.y = y /= pageHeight;\n\n const [bx, by] = this.getBaseTranslation();\n x += bx;\n y += by;\n\n const { style } = this.div;\n style.left = `${(100 * x).toFixed(2)}%`;\n style.top = `${(100 * y).toFixed(2)}%`;\n\n this.moveInDOM();\n }\n\n static #rotatePoint(x, y, angle) {\n switch (angle) {\n case 90:\n return [y, -x];\n case 180:\n return [-x, -y];\n case 270:\n return [-y, x];\n default:\n return [x, y];\n }\n }\n\n /**\n * Convert a screen translation into a page one.\n * @param {number} x\n * @param {number} y\n */\n screenToPageTranslation(x, y) {\n return AnnotationEditor.#rotatePoint(x, y, this.parentRotation);\n }\n\n /**\n * Convert a page translation into a screen one.\n * @param {number} x\n * @param {number} y\n */\n pageTranslationToScreen(x, y) {\n return AnnotationEditor.#rotatePoint(x, y, 360 - this.parentRotation);\n }\n\n #getRotationMatrix(rotation) {\n switch (rotation) {\n case 90: {\n const [pageWidth, pageHeight] = this.pageDimensions;\n return [0, -pageWidth / pageHeight, pageHeight / pageWidth, 0];\n }\n case 180:\n return [-1, 0, 0, -1];\n case 270: {\n const [pageWidth, pageHeight] = this.pageDimensions;\n return [0, pageWidth / pageHeight, -pageHeight / pageWidth, 0];\n }\n default:\n return [1, 0, 0, 1];\n }\n }\n\n get parentScale() {\n return this._uiManager.viewParameters.realScale;\n }\n\n get parentRotation() {\n return (this._uiManager.viewParameters.rotation + this.pageRotation) % 360;\n }\n\n get parentDimensions() {\n const {\n parentScale,\n pageDimensions: [pageWidth, pageHeight],\n } = this;\n const scaledWidth = pageWidth * parentScale;\n const scaledHeight = pageHeight * parentScale;\n return FeatureTest.isCSSRoundSupported\n ? [Math.round(scaledWidth), Math.round(scaledHeight)]\n : [scaledWidth, scaledHeight];\n }\n\n /**\n * Set the dimensions of this editor.\n * @param {number} width\n * @param {number} height\n */\n setDims(width, height) {\n const [parentWidth, parentHeight] = this.parentDimensions;\n this.div.style.width = `${((100 * width) / parentWidth).toFixed(2)}%`;\n if (!this.#keepAspectRatio) {\n this.div.style.height = `${((100 * height) / parentHeight).toFixed(2)}%`;\n }\n }\n\n fixDims() {\n const { style } = this.div;\n const { height, width } = style;\n const widthPercent = width.endsWith(\"%\");\n const heightPercent = !this.#keepAspectRatio && height.endsWith(\"%\");\n if (widthPercent && heightPercent) {\n return;\n }\n\n const [parentWidth, parentHeight] = this.parentDimensions;\n if (!widthPercent) {\n style.width = `${((100 * parseFloat(width)) / parentWidth).toFixed(2)}%`;\n }\n if (!this.#keepAspectRatio && !heightPercent) {\n style.height = `${((100 * parseFloat(height)) / parentHeight).toFixed(\n 2\n )}%`;\n }\n }\n\n /**\n * Get the translation used to position this editor when it's created.\n * @returns {Array}\n */\n getInitialTranslation() {\n return [0, 0];\n }\n\n #createResizers() {\n if (this.#resizersDiv) {\n return;\n }\n this.#resizersDiv = document.createElement(\"div\");\n this.#resizersDiv.classList.add(\"resizers\");\n // When the resizers are used with the keyboard, they're focusable, hence\n // we want to have them in this order (top left, top middle, top right, ...)\n // in the DOM to have the focus order correct.\n const classes = this._willKeepAspectRatio\n ? [\"topLeft\", \"topRight\", \"bottomRight\", \"bottomLeft\"]\n : [\n \"topLeft\",\n \"topMiddle\",\n \"topRight\",\n \"middleRight\",\n \"bottomRight\",\n \"bottomMiddle\",\n \"bottomLeft\",\n \"middleLeft\",\n ];\n for (const name of classes) {\n const div = document.createElement(\"div\");\n this.#resizersDiv.append(div);\n div.classList.add(\"resizer\", name);\n div.setAttribute(\"data-resizer-name\", name);\n div.addEventListener(\n \"pointerdown\",\n this.#resizerPointerdown.bind(this, name)\n );\n div.addEventListener(\"contextmenu\", noContextMenu);\n div.tabIndex = -1;\n }\n this.div.prepend(this.#resizersDiv);\n }\n\n #resizerPointerdown(name, event) {\n event.preventDefault();\n const { isMac } = FeatureTest.platform;\n if (event.button !== 0 || (event.ctrlKey && isMac)) {\n return;\n }\n\n this.#altText?.toggle(false);\n\n const boundResizerPointermove = this.#resizerPointermove.bind(this, name);\n const savedDraggable = this._isDraggable;\n this._isDraggable = false;\n const pointerMoveOptions = { passive: true, capture: true };\n this.parent.togglePointerEvents(false);\n window.addEventListener(\n \"pointermove\",\n boundResizerPointermove,\n pointerMoveOptions\n );\n window.addEventListener(\"contextmenu\", noContextMenu);\n const savedX = this.x;\n const savedY = this.y;\n const savedWidth = this.width;\n const savedHeight = this.height;\n const savedParentCursor = this.parent.div.style.cursor;\n const savedCursor = this.div.style.cursor;\n this.div.style.cursor = this.parent.div.style.cursor =\n window.getComputedStyle(event.target).cursor;\n\n const pointerUpCallback = () => {\n this.parent.togglePointerEvents(true);\n this.#altText?.toggle(true);\n this._isDraggable = savedDraggable;\n window.removeEventListener(\"pointerup\", pointerUpCallback);\n window.removeEventListener(\"blur\", pointerUpCallback);\n window.removeEventListener(\n \"pointermove\",\n boundResizerPointermove,\n pointerMoveOptions\n );\n window.removeEventListener(\"contextmenu\", noContextMenu);\n this.parent.div.style.cursor = savedParentCursor;\n this.div.style.cursor = savedCursor;\n\n this.#addResizeToUndoStack(savedX, savedY, savedWidth, savedHeight);\n };\n window.addEventListener(\"pointerup\", pointerUpCallback);\n // If the user switches to another window (with alt+tab), then we end the\n // resize session.\n window.addEventListener(\"blur\", pointerUpCallback);\n }\n\n #addResizeToUndoStack(savedX, savedY, savedWidth, savedHeight) {\n const newX = this.x;\n const newY = this.y;\n const newWidth = this.width;\n const newHeight = this.height;\n if (\n newX === savedX &&\n newY === savedY &&\n newWidth === savedWidth &&\n newHeight === savedHeight\n ) {\n return;\n }\n\n this.addCommands({\n cmd: () => {\n this.width = newWidth;\n this.height = newHeight;\n this.x = newX;\n this.y = newY;\n const [parentWidth, parentHeight] = this.parentDimensions;\n this.setDims(parentWidth * newWidth, parentHeight * newHeight);\n this.fixAndSetPosition();\n },\n undo: () => {\n this.width = savedWidth;\n this.height = savedHeight;\n this.x = savedX;\n this.y = savedY;\n const [parentWidth, parentHeight] = this.parentDimensions;\n this.setDims(parentWidth * savedWidth, parentHeight * savedHeight);\n this.fixAndSetPosition();\n },\n mustExec: true,\n });\n }\n\n #resizerPointermove(name, event) {\n const [parentWidth, parentHeight] = this.parentDimensions;\n const savedX = this.x;\n const savedY = this.y;\n const savedWidth = this.width;\n const savedHeight = this.height;\n const minWidth = AnnotationEditor.MIN_SIZE / parentWidth;\n const minHeight = AnnotationEditor.MIN_SIZE / parentHeight;\n\n // 10000 because we multiply by 100 and use toFixed(2) in fixAndSetPosition.\n // Without rounding, the positions of the corners other than the top left\n // one can be slightly wrong.\n const round = x => Math.round(x * 10000) / 10000;\n const rotationMatrix = this.#getRotationMatrix(this.rotation);\n const transf = (x, y) => [\n rotationMatrix[0] * x + rotationMatrix[2] * y,\n rotationMatrix[1] * x + rotationMatrix[3] * y,\n ];\n const invRotationMatrix = this.#getRotationMatrix(360 - this.rotation);\n const invTransf = (x, y) => [\n invRotationMatrix[0] * x + invRotationMatrix[2] * y,\n invRotationMatrix[1] * x + invRotationMatrix[3] * y,\n ];\n let getPoint;\n let getOpposite;\n let isDiagonal = false;\n let isHorizontal = false;\n\n switch (name) {\n case \"topLeft\":\n isDiagonal = true;\n getPoint = (w, h) => [0, 0];\n getOpposite = (w, h) => [w, h];\n break;\n case \"topMiddle\":\n getPoint = (w, h) => [w / 2, 0];\n getOpposite = (w, h) => [w / 2, h];\n break;\n case \"topRight\":\n isDiagonal = true;\n getPoint = (w, h) => [w, 0];\n getOpposite = (w, h) => [0, h];\n break;\n case \"middleRight\":\n isHorizontal = true;\n getPoint = (w, h) => [w, h / 2];\n getOpposite = (w, h) => [0, h / 2];\n break;\n case \"bottomRight\":\n isDiagonal = true;\n getPoint = (w, h) => [w, h];\n getOpposite = (w, h) => [0, 0];\n break;\n case \"bottomMiddle\":\n getPoint = (w, h) => [w / 2, h];\n getOpposite = (w, h) => [w / 2, 0];\n break;\n case \"bottomLeft\":\n isDiagonal = true;\n getPoint = (w, h) => [0, h];\n getOpposite = (w, h) => [w, 0];\n break;\n case \"middleLeft\":\n isHorizontal = true;\n getPoint = (w, h) => [0, h / 2];\n getOpposite = (w, h) => [w, h / 2];\n break;\n }\n\n const point = getPoint(savedWidth, savedHeight);\n const oppositePoint = getOpposite(savedWidth, savedHeight);\n let transfOppositePoint = transf(...oppositePoint);\n const oppositeX = round(savedX + transfOppositePoint[0]);\n const oppositeY = round(savedY + transfOppositePoint[1]);\n let ratioX = 1;\n let ratioY = 1;\n\n let [deltaX, deltaY] = this.screenToPageTranslation(\n event.movementX,\n event.movementY\n );\n [deltaX, deltaY] = invTransf(deltaX / parentWidth, deltaY / parentHeight);\n\n if (isDiagonal) {\n const oldDiag = Math.hypot(savedWidth, savedHeight);\n ratioX = ratioY = Math.max(\n Math.min(\n Math.hypot(\n oppositePoint[0] - point[0] - deltaX,\n oppositePoint[1] - point[1] - deltaY\n ) / oldDiag,\n // Avoid the editor to be larger than the page.\n 1 / savedWidth,\n 1 / savedHeight\n ),\n // Avoid the editor to be smaller than the minimum size.\n minWidth / savedWidth,\n minHeight / savedHeight\n );\n } else if (isHorizontal) {\n ratioX =\n Math.max(\n minWidth,\n Math.min(1, Math.abs(oppositePoint[0] - point[0] - deltaX))\n ) / savedWidth;\n } else {\n ratioY =\n Math.max(\n minHeight,\n Math.min(1, Math.abs(oppositePoint[1] - point[1] - deltaY))\n ) / savedHeight;\n }\n\n const newWidth = round(savedWidth * ratioX);\n const newHeight = round(savedHeight * ratioY);\n transfOppositePoint = transf(...getOpposite(newWidth, newHeight));\n const newX = oppositeX - transfOppositePoint[0];\n const newY = oppositeY - transfOppositePoint[1];\n\n this.width = newWidth;\n this.height = newHeight;\n this.x = newX;\n this.y = newY;\n\n this.setDims(parentWidth * newWidth, parentHeight * newHeight);\n this.fixAndSetPosition();\n }\n\n altTextFinish() {\n this.#altText?.finish();\n }\n\n /**\n * Add a toolbar for this editor.\n * @returns {Promise}\n */\n async addEditToolbar() {\n if (this.#editToolbar || this.#isInEditMode) {\n return this.#editToolbar;\n }\n this.#editToolbar = new EditorToolbar(this);\n this.div.append(this.#editToolbar.render());\n if (this.#altText) {\n this.#editToolbar.addAltTextButton(await this.#altText.render());\n }\n\n return this.#editToolbar;\n }\n\n removeEditToolbar() {\n if (!this.#editToolbar) {\n return;\n }\n this.#editToolbar.remove();\n this.#editToolbar = null;\n\n // We destroy the alt text but we don't null it because we want to be able\n // to restore it in case the user undoes the deletion.\n this.#altText?.destroy();\n }\n\n getClientDimensions() {\n return this.div.getBoundingClientRect();\n }\n\n async addAltTextButton() {\n if (this.#altText) {\n return;\n }\n AltText.initialize(AnnotationEditor._l10nPromise);\n this.#altText = new AltText(this);\n await this.addEditToolbar();\n }\n\n get altTextData() {\n return this.#altText?.data;\n }\n\n /**\n * Set the alt text data.\n */\n set altTextData(data) {\n if (!this.#altText) {\n return;\n }\n this.#altText.data = data;\n }\n\n hasAltText() {\n return !this.#altText?.isEmpty();\n }\n\n /**\n * Render this editor in a div.\n * @returns {HTMLDivElement | null}\n */\n render() {\n this.div = document.createElement(\"div\");\n this.div.setAttribute(\"data-editor-rotation\", (360 - this.rotation) % 360);\n this.div.className = this.name;\n this.div.setAttribute(\"id\", this.id);\n this.div.tabIndex = this.#disabled ? -1 : 0;\n if (!this._isVisible) {\n this.div.classList.add(\"hidden\");\n }\n\n this.setInForeground();\n\n this.div.addEventListener(\"focusin\", this.#boundFocusin);\n this.div.addEventListener(\"focusout\", this.#boundFocusout);\n\n const [parentWidth, parentHeight] = this.parentDimensions;\n if (this.parentRotation % 180 !== 0) {\n this.div.style.maxWidth = `${((100 * parentHeight) / parentWidth).toFixed(\n 2\n )}%`;\n this.div.style.maxHeight = `${(\n (100 * parentWidth) /\n parentHeight\n ).toFixed(2)}%`;\n }\n\n const [tx, ty] = this.getInitialTranslation();\n this.translate(tx, ty);\n\n bindEvents(this, this.div, [\"pointerdown\"]);\n\n return this.div;\n }\n\n /**\n * Onpointerdown callback.\n * @param {PointerEvent} event\n */\n pointerdown(event) {\n const { isMac } = FeatureTest.platform;\n if (event.button !== 0 || (event.ctrlKey && isMac)) {\n // Avoid to focus this editor because of a non-left click.\n event.preventDefault();\n return;\n }\n\n this.#hasBeenClicked = true;\n\n if (this._isDraggable) {\n this.#setUpDragSession(event);\n return;\n }\n\n this.#selectOnPointerEvent(event);\n }\n\n #selectOnPointerEvent(event) {\n const { isMac } = FeatureTest.platform;\n if (\n (event.ctrlKey && !isMac) ||\n event.shiftKey ||\n (event.metaKey && isMac)\n ) {\n this.parent.toggleSelected(this);\n } else {\n this.parent.setSelected(this);\n }\n }\n\n #setUpDragSession(event) {\n const isSelected = this._uiManager.isSelected(this);\n this._uiManager.setUpDragSession();\n\n let pointerMoveOptions, pointerMoveCallback;\n if (isSelected) {\n this.div.classList.add(\"moving\");\n pointerMoveOptions = { passive: true, capture: true };\n this.#prevDragX = event.clientX;\n this.#prevDragY = event.clientY;\n pointerMoveCallback = e => {\n const { clientX: x, clientY: y } = e;\n const [tx, ty] = this.screenToPageTranslation(\n x - this.#prevDragX,\n y - this.#prevDragY\n );\n this.#prevDragX = x;\n this.#prevDragY = y;\n this._uiManager.dragSelectedEditors(tx, ty);\n };\n window.addEventListener(\n \"pointermove\",\n pointerMoveCallback,\n pointerMoveOptions\n );\n }\n\n const pointerUpCallback = () => {\n window.removeEventListener(\"pointerup\", pointerUpCallback);\n window.removeEventListener(\"blur\", pointerUpCallback);\n if (isSelected) {\n this.div.classList.remove(\"moving\");\n window.removeEventListener(\n \"pointermove\",\n pointerMoveCallback,\n pointerMoveOptions\n );\n }\n\n this.#hasBeenClicked = false;\n if (!this._uiManager.endDragSession()) {\n this.#selectOnPointerEvent(event);\n }\n };\n window.addEventListener(\"pointerup\", pointerUpCallback);\n // If the user is using alt+tab during the dragging session, the pointerup\n // event could be not fired, but a blur event is fired so we can use it in\n // order to interrupt the dragging session.\n window.addEventListener(\"blur\", pointerUpCallback);\n }\n\n moveInDOM() {\n // Moving the editor in the DOM can be expensive, so we wait a bit before.\n // It's important to not block the UI (for example when changing the font\n // size in a FreeText).\n if (this.#moveInDOMTimeout) {\n clearTimeout(this.#moveInDOMTimeout);\n }\n this.#moveInDOMTimeout = setTimeout(() => {\n this.#moveInDOMTimeout = null;\n this.parent?.moveEditorInDOM(this);\n }, 0);\n }\n\n _setParentAndPosition(parent, x, y) {\n parent.changeParent(this);\n this.x = x;\n this.y = y;\n this.fixAndSetPosition();\n }\n\n /**\n * Convert the current rect into a page one.\n * @param {number} tx - x-translation in screen coordinates.\n * @param {number} ty - y-translation in screen coordinates.\n * @param {number} [rotation] - the rotation of the page.\n */\n getRect(tx, ty, rotation = this.rotation) {\n const scale = this.parentScale;\n const [pageWidth, pageHeight] = this.pageDimensions;\n const [pageX, pageY] = this.pageTranslation;\n const shiftX = tx / scale;\n const shiftY = ty / scale;\n const x = this.x * pageWidth;\n const y = this.y * pageHeight;\n const width = this.width * pageWidth;\n const height = this.height * pageHeight;\n\n switch (rotation) {\n case 0:\n return [\n x + shiftX + pageX,\n pageHeight - y - shiftY - height + pageY,\n x + shiftX + width + pageX,\n pageHeight - y - shiftY + pageY,\n ];\n case 90:\n return [\n x + shiftY + pageX,\n pageHeight - y + shiftX + pageY,\n x + shiftY + height + pageX,\n pageHeight - y + shiftX + width + pageY,\n ];\n case 180:\n return [\n x - shiftX - width + pageX,\n pageHeight - y + shiftY + pageY,\n x - shiftX + pageX,\n pageHeight - y + shiftY + height + pageY,\n ];\n case 270:\n return [\n x - shiftY - height + pageX,\n pageHeight - y - shiftX - width + pageY,\n x - shiftY + pageX,\n pageHeight - y - shiftX + pageY,\n ];\n default:\n throw new Error(\"Invalid rotation\");\n }\n }\n\n getRectInCurrentCoords(rect, pageHeight) {\n const [x1, y1, x2, y2] = rect;\n\n const width = x2 - x1;\n const height = y2 - y1;\n\n switch (this.rotation) {\n case 0:\n return [x1, pageHeight - y2, width, height];\n case 90:\n return [x1, pageHeight - y1, height, width];\n case 180:\n return [x2, pageHeight - y1, width, height];\n case 270:\n return [x2, pageHeight - y2, height, width];\n default:\n throw new Error(\"Invalid rotation\");\n }\n }\n\n /**\n * Executed once this editor has been rendered.\n */\n onceAdded() {}\n\n /**\n * Check if the editor contains something.\n * @returns {boolean}\n */\n isEmpty() {\n return false;\n }\n\n /**\n * Enable edit mode.\n */\n enableEditMode() {\n this.#isInEditMode = true;\n }\n\n /**\n * Disable edit mode.\n */\n disableEditMode() {\n this.#isInEditMode = false;\n }\n\n /**\n * Check if the editor is edited.\n * @returns {boolean}\n */\n isInEditMode() {\n return this.#isInEditMode;\n }\n\n /**\n * If it returns true, then this editor handles the keyboard\n * events itself.\n * @returns {boolean}\n */\n shouldGetKeyboardEvents() {\n return this.#isResizerEnabledForKeyboard;\n }\n\n /**\n * Check if this editor needs to be rebuilt or not.\n * @returns {boolean}\n */\n needsToBeRebuilt() {\n return this.div && !this.isAttachedToDOM;\n }\n\n /**\n * Rebuild the editor in case it has been removed on undo.\n *\n * To implement in subclasses.\n */\n rebuild() {\n this.div?.addEventListener(\"focusin\", this.#boundFocusin);\n this.div?.addEventListener(\"focusout\", this.#boundFocusout);\n }\n\n /**\n * Rotate the editor.\n * @param {number} angle\n */\n rotate(_angle) {}\n\n /**\n * Serialize the editor.\n * The result of the serialization will be used to construct a\n * new annotation to add to the pdf document.\n *\n * To implement in subclasses.\n * @param {boolean} [isForCopying]\n * @param {Object | null} [context]\n * @returns {Object | null}\n */\n serialize(isForCopying = false, context = null) {\n unreachable(\"An editor must be serializable\");\n }\n\n /**\n * Deserialize the editor.\n * The result of the deserialization is a new editor.\n *\n * @param {Object} data\n * @param {AnnotationEditorLayer} parent\n * @param {AnnotationEditorUIManager} uiManager\n * @returns {AnnotationEditor | null}\n */\n static deserialize(data, parent, uiManager) {\n const editor = new this.prototype.constructor({\n parent,\n id: parent.getNextId(),\n uiManager,\n });\n editor.rotation = data.rotation;\n\n const [pageWidth, pageHeight] = editor.pageDimensions;\n const [x, y, width, height] = editor.getRectInCurrentCoords(\n data.rect,\n pageHeight\n );\n editor.x = x / pageWidth;\n editor.y = y / pageHeight;\n editor.width = width / pageWidth;\n editor.height = height / pageHeight;\n\n return editor;\n }\n\n /**\n * Check if an existing annotation associated with this editor has been\n * modified.\n * @returns {boolean}\n */\n get hasBeenModified() {\n return (\n !!this.annotationElementId && (this.deleted || this.serialize() !== null)\n );\n }\n\n /**\n * Remove this editor.\n * It's used on ctrl+backspace action.\n */\n remove() {\n this.div.removeEventListener(\"focusin\", this.#boundFocusin);\n this.div.removeEventListener(\"focusout\", this.#boundFocusout);\n\n if (!this.isEmpty()) {\n // The editor is removed but it can be back at some point thanks to\n // undo/redo so we must commit it before.\n this.commit();\n }\n if (this.parent) {\n this.parent.remove(this);\n } else {\n this._uiManager.removeEditor(this);\n }\n\n if (this.#moveInDOMTimeout) {\n clearTimeout(this.#moveInDOMTimeout);\n this.#moveInDOMTimeout = null;\n }\n this.#stopResizing();\n this.removeEditToolbar();\n if (this.#telemetryTimeouts) {\n for (const timeout of this.#telemetryTimeouts.values()) {\n clearTimeout(timeout);\n }\n this.#telemetryTimeouts = null;\n }\n this.parent = null;\n }\n\n /**\n * @returns {boolean} true if this editor can be resized.\n */\n get isResizable() {\n return false;\n }\n\n /**\n * Add the resizers to this editor.\n */\n makeResizable() {\n if (this.isResizable) {\n this.#createResizers();\n this.#resizersDiv.classList.remove(\"hidden\");\n bindEvents(this, this.div, [\"keydown\"]);\n }\n }\n\n get toolbarPosition() {\n return null;\n }\n\n /**\n * onkeydown callback.\n * @param {KeyboardEvent} event\n */\n keydown(event) {\n if (\n !this.isResizable ||\n event.target !== this.div ||\n event.key !== \"Enter\"\n ) {\n return;\n }\n this._uiManager.setSelected(this);\n this.#savedDimensions = {\n savedX: this.x,\n savedY: this.y,\n savedWidth: this.width,\n savedHeight: this.height,\n };\n const children = this.#resizersDiv.children;\n if (!this.#allResizerDivs) {\n this.#allResizerDivs = Array.from(children);\n const boundResizerKeydown = this.#resizerKeydown.bind(this);\n const boundResizerBlur = this.#resizerBlur.bind(this);\n for (const div of this.#allResizerDivs) {\n const name = div.getAttribute(\"data-resizer-name\");\n div.setAttribute(\"role\", \"spinbutton\");\n div.addEventListener(\"keydown\", boundResizerKeydown);\n div.addEventListener(\"blur\", boundResizerBlur);\n div.addEventListener(\"focus\", this.#resizerFocus.bind(this, name));\n AnnotationEditor._l10nPromise\n .get(`pdfjs-editor-resizer-label-${name}`)\n .then(msg => div.setAttribute(\"aria-label\", msg));\n }\n }\n\n // We want to have the resizers in the visual order, so we move the first\n // (top-left) to the right place.\n const first = this.#allResizerDivs[0];\n let firstPosition = 0;\n for (const div of children) {\n if (div === first) {\n break;\n }\n firstPosition++;\n }\n const nextFirstPosition =\n (((360 - this.rotation + this.parentRotation) % 360) / 90) *\n (this.#allResizerDivs.length / 4);\n\n if (nextFirstPosition !== firstPosition) {\n // We need to reorder the resizers in the DOM in order to have the focus\n // on the top-left one.\n if (nextFirstPosition < firstPosition) {\n for (let i = 0; i < firstPosition - nextFirstPosition; i++) {\n this.#resizersDiv.append(this.#resizersDiv.firstChild);\n }\n } else if (nextFirstPosition > firstPosition) {\n for (let i = 0; i < nextFirstPosition - firstPosition; i++) {\n this.#resizersDiv.firstChild.before(this.#resizersDiv.lastChild);\n }\n }\n\n let i = 0;\n for (const child of children) {\n const div = this.#allResizerDivs[i++];\n const name = div.getAttribute(\"data-resizer-name\");\n AnnotationEditor._l10nPromise\n .get(`pdfjs-editor-resizer-label-${name}`)\n .then(msg => child.setAttribute(\"aria-label\", msg));\n }\n }\n\n this.#setResizerTabIndex(0);\n this.#isResizerEnabledForKeyboard = true;\n this.#resizersDiv.firstChild.focus({ focusVisible: true });\n event.preventDefault();\n event.stopImmediatePropagation();\n }\n\n #resizerKeydown(event) {\n AnnotationEditor._resizerKeyboardManager.exec(this, event);\n }\n\n #resizerBlur(event) {\n if (\n this.#isResizerEnabledForKeyboard &&\n event.relatedTarget?.parentNode !== this.#resizersDiv\n ) {\n this.#stopResizing();\n }\n }\n\n #resizerFocus(name) {\n this.#focusedResizerName = this.#isResizerEnabledForKeyboard ? name : \"\";\n }\n\n #setResizerTabIndex(value) {\n if (!this.#allResizerDivs) {\n return;\n }\n for (const div of this.#allResizerDivs) {\n div.tabIndex = value;\n }\n }\n\n _resizeWithKeyboard(x, y) {\n if (!this.#isResizerEnabledForKeyboard) {\n return;\n }\n this.#resizerPointermove(this.#focusedResizerName, {\n movementX: x,\n movementY: y,\n });\n }\n\n #stopResizing() {\n this.#isResizerEnabledForKeyboard = false;\n this.#setResizerTabIndex(-1);\n if (this.#savedDimensions) {\n const { savedX, savedY, savedWidth, savedHeight } = this.#savedDimensions;\n this.#addResizeToUndoStack(savedX, savedY, savedWidth, savedHeight);\n this.#savedDimensions = null;\n }\n }\n\n _stopResizingWithKeyboard() {\n this.#stopResizing();\n this.div.focus();\n }\n\n /**\n * Select this editor.\n */\n select() {\n this.makeResizable();\n this.div?.classList.add(\"selectedEditor\");\n if (!this.#editToolbar) {\n this.addEditToolbar().then(() => {\n if (this.div?.classList.contains(\"selectedEditor\")) {\n // The editor can have been unselected while we were waiting for the\n // edit toolbar to be created, hence we want to be sure that this\n // editor is still selected.\n this.#editToolbar?.show();\n }\n });\n return;\n }\n this.#editToolbar?.show();\n }\n\n /**\n * Unselect this editor.\n */\n unselect() {\n this.#resizersDiv?.classList.add(\"hidden\");\n this.div?.classList.remove(\"selectedEditor\");\n if (this.div?.contains(document.activeElement)) {\n // Don't use this.div.blur() because we don't know where the focus will\n // go.\n this._uiManager.currentLayer.div.focus({\n preventScroll: true,\n });\n }\n this.#editToolbar?.hide();\n }\n\n /**\n * Update some parameters which have been changed through the UI.\n * @param {number} type\n * @param {*} value\n */\n updateParams(type, value) {}\n\n /**\n * When the user disables the editing mode some editors can change some of\n * their properties.\n */\n disableEditing() {}\n\n /**\n * When the user enables the editing mode some editors can change some of\n * their properties.\n */\n enableEditing() {}\n\n /**\n * The editor is about to be edited.\n */\n enterInEditMode() {}\n\n /**\n * @returns {HTMLElement | null} the element requiring an alt text.\n */\n getImageForAltText() {\n return null;\n }\n\n /**\n * Get the div which really contains the displayed content.\n * @returns {HTMLDivElement | undefined}\n */\n get contentDiv() {\n return this.div;\n }\n\n /**\n * If true then the editor is currently edited.\n * @type {boolean}\n */\n get isEditing() {\n return this.#isEditing;\n }\n\n /**\n * When set to true, it means that this editor is currently edited.\n * @param {boolean} value\n */\n set isEditing(value) {\n this.#isEditing = value;\n if (!this.parent) {\n return;\n }\n if (value) {\n this.parent.setSelected(this);\n this.parent.setActiveEditor(this);\n } else {\n this.parent.setActiveEditor(null);\n }\n }\n\n /**\n * Set the aspect ratio to use when resizing.\n * @param {number} width\n * @param {number} height\n */\n setAspectRatio(width, height) {\n this.#keepAspectRatio = true;\n const aspectRatio = width / height;\n const { style } = this.div;\n style.aspectRatio = aspectRatio;\n style.height = \"auto\";\n }\n\n static get MIN_SIZE() {\n return 16;\n }\n\n static canCreateNewEmptyEditor() {\n return true;\n }\n\n /**\n * Get the data to report to the telemetry when the editor is added.\n * @returns {Object}\n */\n get telemetryInitialData() {\n return { action: \"added\" };\n }\n\n /**\n * The telemetry data to use when saving/printing.\n * @returns {Object|null}\n */\n get telemetryFinalData() {\n return null;\n }\n\n _reportTelemetry(data, mustWait = false) {\n if (mustWait) {\n this.#telemetryTimeouts ||= new Map();\n const { action } = data;\n let timeout = this.#telemetryTimeouts.get(action);\n if (timeout) {\n clearTimeout(timeout);\n }\n timeout = setTimeout(() => {\n this._reportTelemetry(data);\n this.#telemetryTimeouts.delete(action);\n if (this.#telemetryTimeouts.size === 0) {\n this.#telemetryTimeouts = null;\n }\n }, AnnotationEditor._telemetryTimeout);\n this.#telemetryTimeouts.set(action, timeout);\n return;\n }\n data.type ||= this.editorType;\n this._uiManager._eventBus.dispatch(\"reporttelemetry\", {\n source: this,\n details: {\n type: \"editing\",\n data,\n },\n });\n }\n\n /**\n * Show or hide this editor.\n * @param {boolean|undefined} visible\n */\n show(visible = this._isVisible) {\n this.div.classList.toggle(\"hidden\", !visible);\n this._isVisible = visible;\n }\n\n enable() {\n if (this.div) {\n this.div.tabIndex = 0;\n }\n this.#disabled = false;\n }\n\n disable() {\n if (this.div) {\n this.div.tabIndex = -1;\n }\n this.#disabled = true;\n }\n\n /**\n * Render an annotation in the annotation layer.\n * @param {Object} annotation\n * @returns {HTMLElement}\n */\n renderAnnotationElement(annotation) {\n let content = annotation.container.querySelector(\".annotationContent\");\n if (!content) {\n content = document.createElement(\"div\");\n content.classList.add(\"annotationContent\", this.editorType);\n annotation.container.prepend(content);\n } else if (content.nodeName === \"CANVAS\") {\n const canvas = content;\n content = document.createElement(\"div\");\n content.classList.add(\"annotationContent\", this.editorType);\n canvas.before(content);\n }\n\n return content;\n }\n\n resetAnnotationElement(annotation) {\n const { firstChild } = annotation.container;\n if (\n firstChild.nodeName === \"DIV\" &&\n firstChild.classList.contains(\"annotationContent\")\n ) {\n firstChild.remove();\n }\n }\n}\n\n// This class is used to fake an editor which has been deleted.\nclass FakeEditor extends AnnotationEditor {\n constructor(params) {\n super(params);\n this.annotationElementId = params.annotationElementId;\n this.deleted = true;\n }\n\n serialize() {\n return {\n id: this.annotationElementId,\n deleted: true,\n pageIndex: this.pageIndex,\n };\n }\n}\n\nexport { AnnotationEditor };\n","/* Copyright 2014 Opera Software ASA\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n *\n *\n * Based on https://code.google.com/p/smhasher/wiki/MurmurHash3.\n * Hashes roughly 100 KB per millisecond on i7 3.4 GHz.\n */\n\nconst SEED = 0xc3d2e1f0;\n// Workaround for missing math precision in JS.\nconst MASK_HIGH = 0xffff0000;\nconst MASK_LOW = 0xffff;\n\nclass MurmurHash3_64 {\n constructor(seed) {\n this.h1 = seed ? seed & 0xffffffff : SEED;\n this.h2 = seed ? seed & 0xffffffff : SEED;\n }\n\n update(input) {\n let data, length;\n if (typeof input === \"string\") {\n data = new Uint8Array(input.length * 2);\n length = 0;\n for (let i = 0, ii = input.length; i < ii; i++) {\n const code = input.charCodeAt(i);\n if (code <= 0xff) {\n data[length++] = code;\n } else {\n data[length++] = code >>> 8;\n data[length++] = code & 0xff;\n }\n }\n } else if (ArrayBuffer.isView(input)) {\n data = input.slice();\n length = data.byteLength;\n } else {\n throw new Error(\"Invalid data format, must be a string or TypedArray.\");\n }\n\n const blockCounts = length >> 2;\n const tailLength = length - blockCounts * 4;\n // We don't care about endianness here.\n const dataUint32 = new Uint32Array(data.buffer, 0, blockCounts);\n let k1 = 0,\n k2 = 0;\n let h1 = this.h1,\n h2 = this.h2;\n const C1 = 0xcc9e2d51,\n C2 = 0x1b873593;\n const C1_LOW = C1 & MASK_LOW,\n C2_LOW = C2 & MASK_LOW;\n\n for (let i = 0; i < blockCounts; i++) {\n if (i & 1) {\n k1 = dataUint32[i];\n k1 = ((k1 * C1) & MASK_HIGH) | ((k1 * C1_LOW) & MASK_LOW);\n k1 = (k1 << 15) | (k1 >>> 17);\n k1 = ((k1 * C2) & MASK_HIGH) | ((k1 * C2_LOW) & MASK_LOW);\n h1 ^= k1;\n h1 = (h1 << 13) | (h1 >>> 19);\n h1 = h1 * 5 + 0xe6546b64;\n } else {\n k2 = dataUint32[i];\n k2 = ((k2 * C1) & MASK_HIGH) | ((k2 * C1_LOW) & MASK_LOW);\n k2 = (k2 << 15) | (k2 >>> 17);\n k2 = ((k2 * C2) & MASK_HIGH) | ((k2 * C2_LOW) & MASK_LOW);\n h2 ^= k2;\n h2 = (h2 << 13) | (h2 >>> 19);\n h2 = h2 * 5 + 0xe6546b64;\n }\n }\n\n k1 = 0;\n\n switch (tailLength) {\n case 3:\n k1 ^= data[blockCounts * 4 + 2] << 16;\n /* falls through */\n case 2:\n k1 ^= data[blockCounts * 4 + 1] << 8;\n /* falls through */\n case 1:\n k1 ^= data[blockCounts * 4];\n /* falls through */\n\n k1 = ((k1 * C1) & MASK_HIGH) | ((k1 * C1_LOW) & MASK_LOW);\n k1 = (k1 << 15) | (k1 >>> 17);\n k1 = ((k1 * C2) & MASK_HIGH) | ((k1 * C2_LOW) & MASK_LOW);\n if (blockCounts & 1) {\n h1 ^= k1;\n } else {\n h2 ^= k1;\n }\n }\n\n this.h1 = h1;\n this.h2 = h2;\n }\n\n hexdigest() {\n let h1 = this.h1,\n h2 = this.h2;\n\n h1 ^= h2 >>> 1;\n h1 = ((h1 * 0xed558ccd) & MASK_HIGH) | ((h1 * 0x8ccd) & MASK_LOW);\n h2 =\n ((h2 * 0xff51afd7) & MASK_HIGH) |\n (((((h2 << 16) | (h1 >>> 16)) * 0xafd7ed55) & MASK_HIGH) >>> 16);\n h1 ^= h2 >>> 1;\n h1 = ((h1 * 0x1a85ec53) & MASK_HIGH) | ((h1 * 0xec53) & MASK_LOW);\n h2 =\n ((h2 * 0xc4ceb9fe) & MASK_HIGH) |\n (((((h2 << 16) | (h1 >>> 16)) * 0xb9fe1a85) & MASK_HIGH) >>> 16);\n h1 ^= h2 >>> 1;\n\n return (\n (h1 >>> 0).toString(16).padStart(8, \"0\") +\n (h2 >>> 0).toString(16).padStart(8, \"0\")\n );\n }\n}\n\nexport { MurmurHash3_64 };\n","/* Copyright 2020 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { objectFromMap, unreachable } from \"../shared/util.js\";\nimport { AnnotationEditor } from \"./editor/editor.js\";\nimport { MurmurHash3_64 } from \"../shared/murmurhash3.js\";\n\nconst SerializableEmpty = Object.freeze({\n map: null,\n hash: \"\",\n transfer: undefined,\n});\n\n/**\n * Key/value storage for annotation data in forms.\n */\nclass AnnotationStorage {\n #modified = false;\n\n #storage = new Map();\n\n constructor() {\n // Callbacks to signal when the modification state is set or reset.\n // This is used by the viewer to only bind on `beforeunload` if forms\n // are actually edited to prevent doing so unconditionally since that\n // can have undesirable effects.\n this.onSetModified = null;\n this.onResetModified = null;\n this.onAnnotationEditor = null;\n }\n\n /**\n * Get the value for a given key if it exists, or return the default value.\n * @param {string} key\n * @param {Object} defaultValue\n * @returns {Object}\n */\n getValue(key, defaultValue) {\n const value = this.#storage.get(key);\n if (value === undefined) {\n return defaultValue;\n }\n\n return Object.assign(defaultValue, value);\n }\n\n /**\n * Get the value for a given key.\n * @param {string} key\n * @returns {Object}\n */\n getRawValue(key) {\n return this.#storage.get(key);\n }\n\n /**\n * Remove a value from the storage.\n * @param {string} key\n */\n remove(key) {\n this.#storage.delete(key);\n\n if (this.#storage.size === 0) {\n this.resetModified();\n }\n\n if (typeof this.onAnnotationEditor === \"function\") {\n for (const value of this.#storage.values()) {\n if (value instanceof AnnotationEditor) {\n return;\n }\n }\n this.onAnnotationEditor(null);\n }\n }\n\n /**\n * Set the value for a given key\n * @param {string} key\n * @param {Object} value\n */\n setValue(key, value) {\n const obj = this.#storage.get(key);\n let modified = false;\n if (obj !== undefined) {\n for (const [entry, val] of Object.entries(value)) {\n if (obj[entry] !== val) {\n modified = true;\n obj[entry] = val;\n }\n }\n } else {\n modified = true;\n this.#storage.set(key, value);\n }\n if (modified) {\n this.#setModified();\n }\n\n if (\n value instanceof AnnotationEditor &&\n typeof this.onAnnotationEditor === \"function\"\n ) {\n this.onAnnotationEditor(value.constructor._type);\n }\n }\n\n /**\n * Check if the storage contains the given key.\n * @param {string} key\n * @returns {boolean}\n */\n has(key) {\n return this.#storage.has(key);\n }\n\n /**\n * @returns {Object | null}\n */\n getAll() {\n return this.#storage.size > 0 ? objectFromMap(this.#storage) : null;\n }\n\n /**\n * @param {Object} obj\n */\n setAll(obj) {\n for (const [key, val] of Object.entries(obj)) {\n this.setValue(key, val);\n }\n }\n\n get size() {\n return this.#storage.size;\n }\n\n #setModified() {\n if (!this.#modified) {\n this.#modified = true;\n if (typeof this.onSetModified === \"function\") {\n this.onSetModified();\n }\n }\n }\n\n resetModified() {\n if (this.#modified) {\n this.#modified = false;\n if (typeof this.onResetModified === \"function\") {\n this.onResetModified();\n }\n }\n }\n\n /**\n * @returns {PrintAnnotationStorage}\n */\n get print() {\n return new PrintAnnotationStorage(this);\n }\n\n /**\n * PLEASE NOTE: Only intended for usage within the API itself.\n * @ignore\n */\n get serializable() {\n if (this.#storage.size === 0) {\n return SerializableEmpty;\n }\n const map = new Map(),\n hash = new MurmurHash3_64(),\n transfer = [];\n const context = Object.create(null);\n let hasBitmap = false;\n\n for (const [key, val] of this.#storage) {\n const serialized =\n val instanceof AnnotationEditor\n ? val.serialize(/* isForCopying = */ false, context)\n : val;\n if (serialized) {\n map.set(key, serialized);\n\n hash.update(`${key}:${JSON.stringify(serialized)}`);\n hasBitmap ||= !!serialized.bitmap;\n }\n }\n\n if (hasBitmap) {\n // We must transfer the bitmap data separately, since it can be changed\n // during serialization with SVG images.\n for (const value of map.values()) {\n if (value.bitmap) {\n transfer.push(value.bitmap);\n }\n }\n }\n\n return map.size > 0\n ? { map, hash: hash.hexdigest(), transfer }\n : SerializableEmpty;\n }\n\n get editorStats() {\n let stats = null;\n const typeToEditor = new Map();\n for (const value of this.#storage.values()) {\n if (!(value instanceof AnnotationEditor)) {\n continue;\n }\n const editorStats = value.telemetryFinalData;\n if (!editorStats) {\n continue;\n }\n const { type } = editorStats;\n if (!typeToEditor.has(type)) {\n typeToEditor.set(type, Object.getPrototypeOf(value).constructor);\n }\n stats ||= Object.create(null);\n const map = (stats[type] ||= new Map());\n for (const [key, val] of Object.entries(editorStats)) {\n if (key === \"type\") {\n continue;\n }\n let counters = map.get(key);\n if (!counters) {\n counters = new Map();\n map.set(key, counters);\n }\n const count = counters.get(val) ?? 0;\n counters.set(val, count + 1);\n }\n }\n for (const [type, editor] of typeToEditor) {\n stats[type] = editor.computeTelemetryFinalData(stats[type]);\n }\n return stats;\n }\n}\n\n/**\n * A special `AnnotationStorage` for use during printing, where the serializable\n * data is *frozen* upon initialization, to prevent scripting from modifying its\n * contents. (Necessary since printing is triggered synchronously in browsers.)\n */\nclass PrintAnnotationStorage extends AnnotationStorage {\n #serializable;\n\n constructor(parent) {\n super();\n const { map, hash, transfer } = parent.serializable;\n // Create a *copy* of the data, since Objects are passed by reference in JS.\n const clone = structuredClone(map, transfer ? { transfer } : null);\n\n this.#serializable = { map: clone, hash, transfer };\n }\n\n /**\n * @returns {PrintAnnotationStorage}\n */\n // eslint-disable-next-line getter-return\n get print() {\n unreachable(\"Should not call PrintAnnotationStorage.print\");\n }\n\n /**\n * PLEASE NOTE: Only intended for usage within the API itself.\n * @ignore\n */\n get serializable() {\n return this.#serializable;\n }\n}\n\nexport { AnnotationStorage, PrintAnnotationStorage, SerializableEmpty };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n assert,\n bytesToString,\n FontRenderOps,\n isNodeJS,\n shadow,\n string32,\n unreachable,\n warn,\n} from \"../shared/util.js\";\n\nclass FontLoader {\n #systemFonts = new Set();\n\n constructor({\n ownerDocument = globalThis.document,\n styleElement = null, // For testing only.\n }) {\n this._document = ownerDocument;\n\n this.nativeFontFaces = new Set();\n this.styleElement =\n typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")\n ? styleElement\n : null;\n\n if (typeof PDFJSDev === \"undefined\" || !PDFJSDev.test(\"MOZCENTRAL\")) {\n this.loadingRequests = [];\n this.loadTestFontId = 0;\n }\n }\n\n addNativeFontFace(nativeFontFace) {\n this.nativeFontFaces.add(nativeFontFace);\n this._document.fonts.add(nativeFontFace);\n }\n\n removeNativeFontFace(nativeFontFace) {\n this.nativeFontFaces.delete(nativeFontFace);\n this._document.fonts.delete(nativeFontFace);\n }\n\n insertRule(rule) {\n if (!this.styleElement) {\n this.styleElement = this._document.createElement(\"style\");\n this._document.documentElement\n .getElementsByTagName(\"head\")[0]\n .append(this.styleElement);\n }\n const styleSheet = this.styleElement.sheet;\n styleSheet.insertRule(rule, styleSheet.cssRules.length);\n }\n\n clear() {\n for (const nativeFontFace of this.nativeFontFaces) {\n this._document.fonts.delete(nativeFontFace);\n }\n this.nativeFontFaces.clear();\n this.#systemFonts.clear();\n\n if (this.styleElement) {\n // Note: ChildNode.remove doesn't throw if the parentNode is undefined.\n this.styleElement.remove();\n this.styleElement = null;\n }\n }\n\n async loadSystemFont({ systemFontInfo: info, _inspectFont }) {\n if (!info || this.#systemFonts.has(info.loadedName)) {\n return;\n }\n assert(\n !this.disableFontFace,\n \"loadSystemFont shouldn't be called when `disableFontFace` is set.\"\n );\n\n if (this.isFontLoadingAPISupported) {\n const { loadedName, src, style } = info;\n const fontFace = new FontFace(loadedName, src, style);\n this.addNativeFontFace(fontFace);\n try {\n await fontFace.load();\n this.#systemFonts.add(loadedName);\n _inspectFont?.(info);\n } catch {\n warn(\n `Cannot load system font: ${info.baseFontName}, installing it could help to improve PDF rendering.`\n );\n\n this.removeNativeFontFace(fontFace);\n }\n return;\n }\n\n unreachable(\n \"Not implemented: loadSystemFont without the Font Loading API.\"\n );\n }\n\n async bind(font) {\n // Add the font to the DOM only once; skip if the font is already loaded.\n if (font.attached || (font.missingFile && !font.systemFontInfo)) {\n return;\n }\n font.attached = true;\n\n if (font.systemFontInfo) {\n await this.loadSystemFont(font);\n return;\n }\n\n if (this.isFontLoadingAPISupported) {\n const nativeFontFace = font.createNativeFontFace();\n if (nativeFontFace) {\n this.addNativeFontFace(nativeFontFace);\n try {\n await nativeFontFace.loaded;\n } catch (ex) {\n warn(`Failed to load font '${nativeFontFace.family}': '${ex}'.`);\n\n // When font loading failed, fall back to the built-in font renderer.\n font.disableFontFace = true;\n throw ex;\n }\n }\n return; // The font was, asynchronously, loaded.\n }\n\n // !this.isFontLoadingAPISupported\n const rule = font.createFontFaceRule();\n if (rule) {\n this.insertRule(rule);\n\n if (this.isSyncFontLoadingSupported) {\n return; // The font was, synchronously, loaded.\n }\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\"Not implemented: async font loading\");\n }\n await new Promise(resolve => {\n const request = this._queueLoadingCallback(resolve);\n this._prepareFontLoadEvent(font, request);\n });\n // The font was, asynchronously, loaded.\n }\n }\n\n get isFontLoadingAPISupported() {\n const hasFonts = !!this._document?.fonts;\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n return shadow(\n this,\n \"isFontLoadingAPISupported\",\n hasFonts && !this.styleElement\n );\n }\n return shadow(this, \"isFontLoadingAPISupported\", hasFonts);\n }\n\n get isSyncFontLoadingSupported() {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n return shadow(this, \"isSyncFontLoadingSupported\", true);\n }\n\n let supported = false;\n if (typeof PDFJSDev === \"undefined\" || !PDFJSDev.test(\"CHROME\")) {\n if (isNodeJS) {\n // Node.js - we can pretend that sync font loading is supported.\n supported = true;\n } else if (\n typeof navigator !== \"undefined\" &&\n typeof navigator?.userAgent === \"string\" &&\n // User agent string sniffing is bad, but there is no reliable way to\n // tell if the font is fully loaded and ready to be used with canvas.\n /Mozilla\\/5.0.*?rv:\\d+.*? Gecko/.test(navigator.userAgent)\n ) {\n // Firefox, from version 14, supports synchronous font loading.\n supported = true;\n }\n }\n return shadow(this, \"isSyncFontLoadingSupported\", supported);\n }\n\n _queueLoadingCallback(callback) {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\"Not implemented: _queueLoadingCallback\");\n }\n\n function completeRequest() {\n assert(!request.done, \"completeRequest() cannot be called twice.\");\n request.done = true;\n\n // Sending all completed requests in order of how they were queued.\n while (loadingRequests.length > 0 && loadingRequests[0].done) {\n const otherRequest = loadingRequests.shift();\n setTimeout(otherRequest.callback, 0);\n }\n }\n\n const { loadingRequests } = this;\n const request = {\n done: false,\n complete: completeRequest,\n callback,\n };\n loadingRequests.push(request);\n return request;\n }\n\n get _loadTestFont() {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\"Not implemented: _loadTestFont\");\n }\n\n // This is a CFF font with 1 glyph for '.' that fills its entire width\n // and height.\n const testFont = atob(\n \"T1RUTwALAIAAAwAwQ0ZGIDHtZg4AAAOYAAAAgUZGVE1lkzZwAAAEHAAAABxHREVGABQA\" +\n \"FQAABDgAAAAeT1MvMlYNYwkAAAEgAAAAYGNtYXABDQLUAAACNAAAAUJoZWFk/xVFDQAA\" +\n \"ALwAAAA2aGhlYQdkA+oAAAD0AAAAJGhtdHgD6AAAAAAEWAAAAAZtYXhwAAJQAAAAARgA\" +\n \"AAAGbmFtZVjmdH4AAAGAAAAAsXBvc3T/hgAzAAADeAAAACAAAQAAAAEAALZRFsRfDzz1\" +\n \"AAsD6AAAAADOBOTLAAAAAM4KHDwAAAAAA+gDIQAAAAgAAgAAAAAAAAABAAADIQAAAFoD\" +\n \"6AAAAAAD6AABAAAAAAAAAAAAAAAAAAAAAQAAUAAAAgAAAAQD6AH0AAUAAAKKArwAAACM\" +\n \"AooCvAAAAeAAMQECAAACAAYJAAAAAAAAAAAAAQAAAAAAAAAAAAAAAFBmRWQAwAAuAC4D\" +\n \"IP84AFoDIQAAAAAAAQAAAAAAAAAAACAAIAABAAAADgCuAAEAAAAAAAAAAQAAAAEAAAAA\" +\n \"AAEAAQAAAAEAAAAAAAIAAQAAAAEAAAAAAAMAAQAAAAEAAAAAAAQAAQAAAAEAAAAAAAUA\" +\n \"AQAAAAEAAAAAAAYAAQAAAAMAAQQJAAAAAgABAAMAAQQJAAEAAgABAAMAAQQJAAIAAgAB\" +\n \"AAMAAQQJAAMAAgABAAMAAQQJAAQAAgABAAMAAQQJAAUAAgABAAMAAQQJAAYAAgABWABY\" +\n \"AAAAAAAAAwAAAAMAAAAcAAEAAAAAADwAAwABAAAAHAAEACAAAAAEAAQAAQAAAC7//wAA\" +\n \"AC7////TAAEAAAAAAAABBgAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\" +\n \"AAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\" +\n \"AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\" +\n \"AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\" +\n \"AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\" +\n \"AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAD/gwAyAAAAAQAAAAAAAAAAAAAAAAAA\" +\n \"AAABAAQEAAEBAQJYAAEBASH4DwD4GwHEAvgcA/gXBIwMAYuL+nz5tQXkD5j3CBLnEQAC\" +\n \"AQEBIVhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYAAABAQAADwACAQEEE/t3\" +\n \"Dov6fAH6fAT+fPp8+nwHDosMCvm1Cvm1DAz6fBQAAAAAAAABAAAAAMmJbzEAAAAAzgTj\" +\n \"FQAAAADOBOQpAAEAAAAAAAAADAAUAAQAAAABAAAAAgABAAAAAAAAAAAD6AAAAAAAAA==\"\n );\n return shadow(this, \"_loadTestFont\", testFont);\n }\n\n _prepareFontLoadEvent(font, request) {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\"Not implemented: _prepareFontLoadEvent\");\n }\n\n /** Hack begin */\n // There's currently no event when a font has finished downloading so the\n // following code is a dirty hack to 'guess' when a font is ready.\n // It's assumed fonts are loaded in order, so add a known test font after\n // the desired fonts and then test for the loading of that test font.\n\n function int32(data, offset) {\n return (\n (data.charCodeAt(offset) << 24) |\n (data.charCodeAt(offset + 1) << 16) |\n (data.charCodeAt(offset + 2) << 8) |\n (data.charCodeAt(offset + 3) & 0xff)\n );\n }\n function spliceString(s, offset, remove, insert) {\n const chunk1 = s.substring(0, offset);\n const chunk2 = s.substring(offset + remove);\n return chunk1 + insert + chunk2;\n }\n let i, ii;\n\n // The temporary canvas is used to determine if fonts are loaded.\n const canvas = this._document.createElement(\"canvas\");\n canvas.width = 1;\n canvas.height = 1;\n const ctx = canvas.getContext(\"2d\");\n\n let called = 0;\n function isFontReady(name, callback) {\n // With setTimeout clamping this gives the font ~100ms to load.\n if (++called > 30) {\n warn(\"Load test font never loaded.\");\n callback();\n return;\n }\n ctx.font = \"30px \" + name;\n ctx.fillText(\".\", 0, 20);\n const imageData = ctx.getImageData(0, 0, 1, 1);\n if (imageData.data[3] > 0) {\n callback();\n return;\n }\n setTimeout(isFontReady.bind(null, name, callback));\n }\n\n const loadTestFontId = `lt${Date.now()}${this.loadTestFontId++}`;\n // Chromium seems to cache fonts based on a hash of the actual font data,\n // so the font must be modified for each load test else it will appear to\n // be loaded already.\n // TODO: This could maybe be made faster by avoiding the btoa of the full\n // font by splitting it in chunks before hand and padding the font id.\n let data = this._loadTestFont;\n const COMMENT_OFFSET = 976; // has to be on 4 byte boundary (for checksum)\n data = spliceString(\n data,\n COMMENT_OFFSET,\n loadTestFontId.length,\n loadTestFontId\n );\n // CFF checksum is important for IE, adjusting it\n const CFF_CHECKSUM_OFFSET = 16;\n const XXXX_VALUE = 0x58585858; // the \"comment\" filled with 'X'\n let checksum = int32(data, CFF_CHECKSUM_OFFSET);\n for (i = 0, ii = loadTestFontId.length - 3; i < ii; i += 4) {\n checksum = (checksum - XXXX_VALUE + int32(loadTestFontId, i)) | 0;\n }\n if (i < loadTestFontId.length) {\n // align to 4 bytes boundary\n checksum = (checksum - XXXX_VALUE + int32(loadTestFontId + \"XXX\", i)) | 0;\n }\n data = spliceString(data, CFF_CHECKSUM_OFFSET, 4, string32(checksum));\n\n const url = `url(data:font/opentype;base64,${btoa(data)});`;\n const rule = `@font-face {font-family:\"${loadTestFontId}\";src:${url}}`;\n this.insertRule(rule);\n\n const div = this._document.createElement(\"div\");\n div.style.visibility = \"hidden\";\n div.style.width = div.style.height = \"10px\";\n div.style.position = \"absolute\";\n div.style.top = div.style.left = \"0px\";\n\n for (const name of [font.loadedName, loadTestFontId]) {\n const span = this._document.createElement(\"span\");\n span.textContent = \"Hi\";\n span.style.fontFamily = name;\n div.append(span);\n }\n this._document.body.append(div);\n\n isFontReady(loadTestFontId, () => {\n div.remove();\n request.complete();\n });\n /** Hack end */\n }\n}\n\nclass FontFaceObject {\n constructor(translatedData, { disableFontFace = false, inspectFont = null }) {\n this.compiledGlyphs = Object.create(null);\n // importing translated data\n for (const i in translatedData) {\n this[i] = translatedData[i];\n }\n this.disableFontFace = disableFontFace === true;\n this._inspectFont = inspectFont;\n }\n\n createNativeFontFace() {\n if (!this.data || this.disableFontFace) {\n return null;\n }\n let nativeFontFace;\n if (!this.cssFontInfo) {\n nativeFontFace = new FontFace(this.loadedName, this.data, {});\n } else {\n const css = {\n weight: this.cssFontInfo.fontWeight,\n };\n if (this.cssFontInfo.italicAngle) {\n css.style = `oblique ${this.cssFontInfo.italicAngle}deg`;\n }\n nativeFontFace = new FontFace(\n this.cssFontInfo.fontFamily,\n this.data,\n css\n );\n }\n\n this._inspectFont?.(this);\n return nativeFontFace;\n }\n\n createFontFaceRule() {\n if (!this.data || this.disableFontFace) {\n return null;\n }\n const data = bytesToString(this.data);\n // Add the @font-face rule to the document.\n const url = `url(data:${this.mimetype};base64,${btoa(data)});`;\n let rule;\n if (!this.cssFontInfo) {\n rule = `@font-face {font-family:\"${this.loadedName}\";src:${url}}`;\n } else {\n let css = `font-weight: ${this.cssFontInfo.fontWeight};`;\n if (this.cssFontInfo.italicAngle) {\n css += `font-style: oblique ${this.cssFontInfo.italicAngle}deg;`;\n }\n rule = `@font-face {font-family:\"${this.cssFontInfo.fontFamily}\";${css}src:${url}}`;\n }\n\n this._inspectFont?.(this, url);\n return rule;\n }\n\n getPathGenerator(objs, character) {\n if (this.compiledGlyphs[character] !== undefined) {\n return this.compiledGlyphs[character];\n }\n\n let cmds;\n try {\n cmds = objs.get(this.loadedName + \"_path_\" + character);\n } catch (ex) {\n warn(`getPathGenerator - ignoring character: \"${ex}\".`);\n }\n\n if (!Array.isArray(cmds) || cmds.length === 0) {\n return (this.compiledGlyphs[character] = function (c, size) {\n // No-op function, to allow rendering to continue.\n });\n }\n\n const commands = [];\n for (let i = 0, ii = cmds.length; i < ii; ) {\n switch (cmds[i++]) {\n case FontRenderOps.BEZIER_CURVE_TO:\n {\n const [a, b, c, d, e, f] = cmds.slice(i, i + 6);\n commands.push(ctx => ctx.bezierCurveTo(a, b, c, d, e, f));\n i += 6;\n }\n break;\n case FontRenderOps.MOVE_TO:\n {\n const [a, b] = cmds.slice(i, i + 2);\n commands.push(ctx => ctx.moveTo(a, b));\n i += 2;\n }\n break;\n case FontRenderOps.LINE_TO:\n {\n const [a, b] = cmds.slice(i, i + 2);\n commands.push(ctx => ctx.lineTo(a, b));\n i += 2;\n }\n break;\n case FontRenderOps.QUADRATIC_CURVE_TO:\n {\n const [a, b, c, d] = cmds.slice(i, i + 4);\n commands.push(ctx => ctx.quadraticCurveTo(a, b, c, d));\n i += 4;\n }\n break;\n case FontRenderOps.RESTORE:\n commands.push(ctx => ctx.restore());\n break;\n case FontRenderOps.SAVE:\n commands.push(ctx => ctx.save());\n break;\n case FontRenderOps.SCALE:\n // The scale command must be at the third position, after save and\n // transform (for the font matrix) commands (see also\n // font_renderer.js).\n // The goal is to just scale the canvas and then run the commands loop\n // without the need to pass the size parameter to each command.\n assert(\n commands.length === 2,\n \"Scale command is only valid at the third position.\"\n );\n break;\n case FontRenderOps.TRANSFORM:\n {\n const [a, b, c, d, e, f] = cmds.slice(i, i + 6);\n commands.push(ctx => ctx.transform(a, b, c, d, e, f));\n i += 6;\n }\n break;\n case FontRenderOps.TRANSLATE:\n {\n const [a, b] = cmds.slice(i, i + 2);\n commands.push(ctx => ctx.translate(a, b));\n i += 2;\n }\n break;\n }\n }\n\n return (this.compiledGlyphs[character] = function glyphDrawer(ctx, size) {\n commands[0](ctx);\n commands[1](ctx);\n ctx.scale(size, -size);\n for (let i = 2, ii = commands.length; i < ii; i++) {\n commands[i](ctx);\n }\n });\n }\n}\n\nexport { FontFaceObject, FontLoader };\n","/* Copyright 2020 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n BaseCanvasFactory,\n BaseCMapReaderFactory,\n BaseFilterFactory,\n BaseStandardFontDataFactory,\n} from \"./base_factory.js\";\nimport { isNodeJS, warn } from \"../shared/util.js\";\n\nif (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\n 'Module \"./node_utils.js\" shall not be used with MOZCENTRAL builds.'\n );\n}\n\nif (isNodeJS) {\n // eslint-disable-next-line no-var\n var packageCapability = Promise.withResolvers();\n // eslint-disable-next-line no-var\n var packageMap = null;\n\n const loadPackages = async () => {\n // Native packages.\n const fs = await __non_webpack_import__(\"fs\"),\n http = await __non_webpack_import__(\"http\"),\n https = await __non_webpack_import__(\"https\"),\n url = await __non_webpack_import__(\"url\");\n\n // Optional, third-party, packages.\n let canvas, path2d;\n if (typeof PDFJSDev !== \"undefined\" && !PDFJSDev.test(\"SKIP_BABEL\")) {\n try {\n canvas = await __non_webpack_import__(\"canvas\");\n } catch {}\n try {\n path2d = await __non_webpack_import__(\"path2d\");\n } catch {}\n }\n\n return new Map(Object.entries({ fs, http, https, url, canvas, path2d }));\n };\n\n loadPackages().then(\n map => {\n packageMap = map;\n packageCapability.resolve();\n\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"SKIP_BABEL\")) {\n return;\n }\n if (!globalThis.DOMMatrix) {\n const DOMMatrix = map.get(\"canvas\")?.DOMMatrix;\n\n if (DOMMatrix) {\n globalThis.DOMMatrix = DOMMatrix;\n } else {\n warn(\"Cannot polyfill `DOMMatrix`, rendering may be broken.\");\n }\n }\n if (!globalThis.Path2D) {\n const CanvasRenderingContext2D =\n map.get(\"canvas\")?.CanvasRenderingContext2D;\n const applyPath2DToCanvasRenderingContext =\n map.get(\"path2d\")?.applyPath2DToCanvasRenderingContext;\n const Path2D = map.get(\"path2d\")?.Path2D;\n\n if (\n CanvasRenderingContext2D &&\n applyPath2DToCanvasRenderingContext &&\n Path2D\n ) {\n applyPath2DToCanvasRenderingContext(CanvasRenderingContext2D);\n globalThis.Path2D = Path2D;\n } else {\n warn(\"Cannot polyfill `Path2D`, rendering may be broken.\");\n }\n }\n },\n reason => {\n warn(`loadPackages: ${reason}`);\n\n packageMap = new Map();\n packageCapability.resolve();\n }\n );\n}\n\nclass NodePackages {\n static get promise() {\n return packageCapability.promise;\n }\n\n static get(name) {\n return packageMap?.get(name);\n }\n}\n\nconst fetchData = function (url) {\n const fs = NodePackages.get(\"fs\");\n return fs.promises.readFile(url).then(data => new Uint8Array(data));\n};\n\nclass NodeFilterFactory extends BaseFilterFactory {}\n\nclass NodeCanvasFactory extends BaseCanvasFactory {\n /**\n * @ignore\n */\n _createCanvas(width, height) {\n const canvas = NodePackages.get(\"canvas\");\n return canvas.createCanvas(width, height);\n }\n}\n\nclass NodeCMapReaderFactory extends BaseCMapReaderFactory {\n /**\n * @ignore\n */\n _fetchData(url, compressionType) {\n return fetchData(url).then(data => ({ cMapData: data, compressionType }));\n }\n}\n\nclass NodeStandardFontDataFactory extends BaseStandardFontDataFactory {\n /**\n * @ignore\n */\n _fetchData(url) {\n return fetchData(url);\n }\n}\n\nexport {\n NodeCanvasFactory,\n NodeCMapReaderFactory,\n NodeFilterFactory,\n NodePackages,\n NodeStandardFontDataFactory,\n};\n","/* Copyright 2014 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { FormatError, info, unreachable, Util } from \"../shared/util.js\";\nimport { getCurrentTransform } from \"./display_utils.js\";\n\nconst PathType = {\n FILL: \"Fill\",\n STROKE: \"Stroke\",\n SHADING: \"Shading\",\n};\n\nfunction applyBoundingBox(ctx, bbox) {\n if (!bbox) {\n return;\n }\n const width = bbox[2] - bbox[0];\n const height = bbox[3] - bbox[1];\n const region = new Path2D();\n region.rect(bbox[0], bbox[1], width, height);\n ctx.clip(region);\n}\n\nclass BaseShadingPattern {\n constructor() {\n if (this.constructor === BaseShadingPattern) {\n unreachable(\"Cannot initialize BaseShadingPattern.\");\n }\n }\n\n getPattern() {\n unreachable(\"Abstract method `getPattern` called.\");\n }\n}\n\nclass RadialAxialShadingPattern extends BaseShadingPattern {\n constructor(IR) {\n super();\n this._type = IR[1];\n this._bbox = IR[2];\n this._colorStops = IR[3];\n this._p0 = IR[4];\n this._p1 = IR[5];\n this._r0 = IR[6];\n this._r1 = IR[7];\n this.matrix = null;\n }\n\n _createGradient(ctx) {\n let grad;\n if (this._type === \"axial\") {\n grad = ctx.createLinearGradient(\n this._p0[0],\n this._p0[1],\n this._p1[0],\n this._p1[1]\n );\n } else if (this._type === \"radial\") {\n grad = ctx.createRadialGradient(\n this._p0[0],\n this._p0[1],\n this._r0,\n this._p1[0],\n this._p1[1],\n this._r1\n );\n }\n\n for (const colorStop of this._colorStops) {\n grad.addColorStop(colorStop[0], colorStop[1]);\n }\n return grad;\n }\n\n getPattern(ctx, owner, inverse, pathType) {\n let pattern;\n if (pathType === PathType.STROKE || pathType === PathType.FILL) {\n const ownerBBox = owner.current.getClippedPathBoundingBox(\n pathType,\n getCurrentTransform(ctx)\n ) || [0, 0, 0, 0];\n // Create a canvas that is only as big as the current path. This doesn't\n // allow us to cache the pattern, but it generally creates much smaller\n // canvases and saves memory use. See bug 1722807 for an example.\n const width = Math.ceil(ownerBBox[2] - ownerBBox[0]) || 1;\n const height = Math.ceil(ownerBBox[3] - ownerBBox[1]) || 1;\n\n const tmpCanvas = owner.cachedCanvases.getCanvas(\n \"pattern\",\n width,\n height,\n true\n );\n\n const tmpCtx = tmpCanvas.context;\n tmpCtx.clearRect(0, 0, tmpCtx.canvas.width, tmpCtx.canvas.height);\n tmpCtx.beginPath();\n tmpCtx.rect(0, 0, tmpCtx.canvas.width, tmpCtx.canvas.height);\n // Non shading fill patterns are positioned relative to the base transform\n // (usually the page's initial transform), but we may have created a\n // smaller canvas based on the path, so we must account for the shift.\n tmpCtx.translate(-ownerBBox[0], -ownerBBox[1]);\n inverse = Util.transform(inverse, [\n 1,\n 0,\n 0,\n 1,\n ownerBBox[0],\n ownerBBox[1],\n ]);\n\n tmpCtx.transform(...owner.baseTransform);\n if (this.matrix) {\n tmpCtx.transform(...this.matrix);\n }\n applyBoundingBox(tmpCtx, this._bbox);\n\n tmpCtx.fillStyle = this._createGradient(tmpCtx);\n tmpCtx.fill();\n\n pattern = ctx.createPattern(tmpCanvas.canvas, \"no-repeat\");\n const domMatrix = new DOMMatrix(inverse);\n pattern.setTransform(domMatrix);\n } else {\n // Shading fills are applied relative to the current matrix which is also\n // how canvas gradients work, so there's no need to do anything special\n // here.\n applyBoundingBox(ctx, this._bbox);\n pattern = this._createGradient(ctx);\n }\n return pattern;\n }\n}\n\nfunction drawTriangle(data, context, p1, p2, p3, c1, c2, c3) {\n // Very basic Gouraud-shaded triangle rasterization algorithm.\n const coords = context.coords,\n colors = context.colors;\n const bytes = data.data,\n rowSize = data.width * 4;\n let tmp;\n if (coords[p1 + 1] > coords[p2 + 1]) {\n tmp = p1;\n p1 = p2;\n p2 = tmp;\n tmp = c1;\n c1 = c2;\n c2 = tmp;\n }\n if (coords[p2 + 1] > coords[p3 + 1]) {\n tmp = p2;\n p2 = p3;\n p3 = tmp;\n tmp = c2;\n c2 = c3;\n c3 = tmp;\n }\n if (coords[p1 + 1] > coords[p2 + 1]) {\n tmp = p1;\n p1 = p2;\n p2 = tmp;\n tmp = c1;\n c1 = c2;\n c2 = tmp;\n }\n const x1 = (coords[p1] + context.offsetX) * context.scaleX;\n const y1 = (coords[p1 + 1] + context.offsetY) * context.scaleY;\n const x2 = (coords[p2] + context.offsetX) * context.scaleX;\n const y2 = (coords[p2 + 1] + context.offsetY) * context.scaleY;\n const x3 = (coords[p3] + context.offsetX) * context.scaleX;\n const y3 = (coords[p3 + 1] + context.offsetY) * context.scaleY;\n if (y1 >= y3) {\n return;\n }\n const c1r = colors[c1],\n c1g = colors[c1 + 1],\n c1b = colors[c1 + 2];\n const c2r = colors[c2],\n c2g = colors[c2 + 1],\n c2b = colors[c2 + 2];\n const c3r = colors[c3],\n c3g = colors[c3 + 1],\n c3b = colors[c3 + 2];\n\n const minY = Math.round(y1),\n maxY = Math.round(y3);\n let xa, car, cag, cab;\n let xb, cbr, cbg, cbb;\n for (let y = minY; y <= maxY; y++) {\n if (y < y2) {\n const k = y < y1 ? 0 : (y1 - y) / (y1 - y2);\n xa = x1 - (x1 - x2) * k;\n car = c1r - (c1r - c2r) * k;\n cag = c1g - (c1g - c2g) * k;\n cab = c1b - (c1b - c2b) * k;\n } else {\n let k;\n if (y > y3) {\n k = 1;\n } else if (y2 === y3) {\n k = 0;\n } else {\n k = (y2 - y) / (y2 - y3);\n }\n xa = x2 - (x2 - x3) * k;\n car = c2r - (c2r - c3r) * k;\n cag = c2g - (c2g - c3g) * k;\n cab = c2b - (c2b - c3b) * k;\n }\n\n let k;\n if (y < y1) {\n k = 0;\n } else if (y > y3) {\n k = 1;\n } else {\n k = (y1 - y) / (y1 - y3);\n }\n xb = x1 - (x1 - x3) * k;\n cbr = c1r - (c1r - c3r) * k;\n cbg = c1g - (c1g - c3g) * k;\n cbb = c1b - (c1b - c3b) * k;\n const x1_ = Math.round(Math.min(xa, xb));\n const x2_ = Math.round(Math.max(xa, xb));\n let j = rowSize * y + x1_ * 4;\n for (let x = x1_; x <= x2_; x++) {\n k = (xa - x) / (xa - xb);\n if (k < 0) {\n k = 0;\n } else if (k > 1) {\n k = 1;\n }\n bytes[j++] = (car - (car - cbr) * k) | 0;\n bytes[j++] = (cag - (cag - cbg) * k) | 0;\n bytes[j++] = (cab - (cab - cbb) * k) | 0;\n bytes[j++] = 255;\n }\n }\n}\n\nfunction drawFigure(data, figure, context) {\n const ps = figure.coords;\n const cs = figure.colors;\n let i, ii;\n switch (figure.type) {\n case \"lattice\":\n const verticesPerRow = figure.verticesPerRow;\n const rows = Math.floor(ps.length / verticesPerRow) - 1;\n const cols = verticesPerRow - 1;\n for (i = 0; i < rows; i++) {\n let q = i * verticesPerRow;\n for (let j = 0; j < cols; j++, q++) {\n drawTriangle(\n data,\n context,\n ps[q],\n ps[q + 1],\n ps[q + verticesPerRow],\n cs[q],\n cs[q + 1],\n cs[q + verticesPerRow]\n );\n drawTriangle(\n data,\n context,\n ps[q + verticesPerRow + 1],\n ps[q + 1],\n ps[q + verticesPerRow],\n cs[q + verticesPerRow + 1],\n cs[q + 1],\n cs[q + verticesPerRow]\n );\n }\n }\n break;\n case \"triangles\":\n for (i = 0, ii = ps.length; i < ii; i += 3) {\n drawTriangle(\n data,\n context,\n ps[i],\n ps[i + 1],\n ps[i + 2],\n cs[i],\n cs[i + 1],\n cs[i + 2]\n );\n }\n break;\n default:\n throw new Error(\"illegal figure\");\n }\n}\n\nclass MeshShadingPattern extends BaseShadingPattern {\n constructor(IR) {\n super();\n this._coords = IR[2];\n this._colors = IR[3];\n this._figures = IR[4];\n this._bounds = IR[5];\n this._bbox = IR[7];\n this._background = IR[8];\n this.matrix = null;\n }\n\n _createMeshCanvas(combinedScale, backgroundColor, cachedCanvases) {\n // we will increase scale on some weird factor to let antialiasing take\n // care of \"rough\" edges\n const EXPECTED_SCALE = 1.1;\n // MAX_PATTERN_SIZE is used to avoid OOM situation.\n const MAX_PATTERN_SIZE = 3000; // 10in @ 300dpi shall be enough\n // We need to keep transparent border around our pattern for fill():\n // createPattern with 'no-repeat' will bleed edges across entire area.\n const BORDER_SIZE = 2;\n\n const offsetX = Math.floor(this._bounds[0]);\n const offsetY = Math.floor(this._bounds[1]);\n const boundsWidth = Math.ceil(this._bounds[2]) - offsetX;\n const boundsHeight = Math.ceil(this._bounds[3]) - offsetY;\n\n const width = Math.min(\n Math.ceil(Math.abs(boundsWidth * combinedScale[0] * EXPECTED_SCALE)),\n MAX_PATTERN_SIZE\n );\n const height = Math.min(\n Math.ceil(Math.abs(boundsHeight * combinedScale[1] * EXPECTED_SCALE)),\n MAX_PATTERN_SIZE\n );\n const scaleX = boundsWidth / width;\n const scaleY = boundsHeight / height;\n\n const context = {\n coords: this._coords,\n colors: this._colors,\n offsetX: -offsetX,\n offsetY: -offsetY,\n scaleX: 1 / scaleX,\n scaleY: 1 / scaleY,\n };\n\n const paddedWidth = width + BORDER_SIZE * 2;\n const paddedHeight = height + BORDER_SIZE * 2;\n\n const tmpCanvas = cachedCanvases.getCanvas(\n \"mesh\",\n paddedWidth,\n paddedHeight,\n false\n );\n const tmpCtx = tmpCanvas.context;\n\n const data = tmpCtx.createImageData(width, height);\n if (backgroundColor) {\n const bytes = data.data;\n for (let i = 0, ii = bytes.length; i < ii; i += 4) {\n bytes[i] = backgroundColor[0];\n bytes[i + 1] = backgroundColor[1];\n bytes[i + 2] = backgroundColor[2];\n bytes[i + 3] = 255;\n }\n }\n for (const figure of this._figures) {\n drawFigure(data, figure, context);\n }\n tmpCtx.putImageData(data, BORDER_SIZE, BORDER_SIZE);\n const canvas = tmpCanvas.canvas;\n\n return {\n canvas,\n offsetX: offsetX - BORDER_SIZE * scaleX,\n offsetY: offsetY - BORDER_SIZE * scaleY,\n scaleX,\n scaleY,\n };\n }\n\n getPattern(ctx, owner, inverse, pathType) {\n applyBoundingBox(ctx, this._bbox);\n let scale;\n if (pathType === PathType.SHADING) {\n scale = Util.singularValueDecompose2dScale(getCurrentTransform(ctx));\n } else {\n // Obtain scale from matrix and current transformation matrix.\n scale = Util.singularValueDecompose2dScale(owner.baseTransform);\n if (this.matrix) {\n const matrixScale = Util.singularValueDecompose2dScale(this.matrix);\n scale = [scale[0] * matrixScale[0], scale[1] * matrixScale[1]];\n }\n }\n\n // Rasterizing on the main thread since sending/queue large canvases\n // might cause OOM.\n const temporaryPatternCanvas = this._createMeshCanvas(\n scale,\n pathType === PathType.SHADING ? null : this._background,\n owner.cachedCanvases\n );\n\n if (pathType !== PathType.SHADING) {\n ctx.setTransform(...owner.baseTransform);\n if (this.matrix) {\n ctx.transform(...this.matrix);\n }\n }\n\n ctx.translate(\n temporaryPatternCanvas.offsetX,\n temporaryPatternCanvas.offsetY\n );\n ctx.scale(temporaryPatternCanvas.scaleX, temporaryPatternCanvas.scaleY);\n\n return ctx.createPattern(temporaryPatternCanvas.canvas, \"no-repeat\");\n }\n}\n\nclass DummyShadingPattern extends BaseShadingPattern {\n getPattern() {\n return \"hotpink\";\n }\n}\n\nfunction getShadingPattern(IR) {\n switch (IR[0]) {\n case \"RadialAxial\":\n return new RadialAxialShadingPattern(IR);\n case \"Mesh\":\n return new MeshShadingPattern(IR);\n case \"Dummy\":\n return new DummyShadingPattern();\n }\n throw new Error(`Unknown IR type: ${IR[0]}`);\n}\n\nconst PaintType = {\n COLORED: 1,\n UNCOLORED: 2,\n};\n\nclass TilingPattern {\n // 10in @ 300dpi shall be enough.\n static MAX_PATTERN_SIZE = 3000;\n\n constructor(IR, color, ctx, canvasGraphicsFactory, baseTransform) {\n this.operatorList = IR[2];\n this.matrix = IR[3];\n this.bbox = IR[4];\n this.xstep = IR[5];\n this.ystep = IR[6];\n this.paintType = IR[7];\n this.tilingType = IR[8];\n this.color = color;\n this.ctx = ctx;\n this.canvasGraphicsFactory = canvasGraphicsFactory;\n this.baseTransform = baseTransform;\n }\n\n createPatternCanvas(owner) {\n const operatorList = this.operatorList;\n const bbox = this.bbox;\n const xstep = this.xstep;\n const ystep = this.ystep;\n const paintType = this.paintType;\n const tilingType = this.tilingType;\n const color = this.color;\n const canvasGraphicsFactory = this.canvasGraphicsFactory;\n\n info(\"TilingType: \" + tilingType);\n\n // A tiling pattern as defined by PDF spec 8.7.2 is a cell whose size is\n // described by bbox, and may repeat regularly by shifting the cell by\n // xstep and ystep.\n // Because the HTML5 canvas API does not support pattern repetition with\n // gaps in between, we use the xstep/ystep instead of the bbox's size.\n //\n // This has the following consequences (similarly for ystep):\n //\n // - If xstep is the same as bbox, then there is no observable difference.\n //\n // - If xstep is larger than bbox, then the pattern canvas is partially\n // empty: the area bounded by bbox is painted, the outside area is void.\n //\n // - If xstep is smaller than bbox, then the pixels between xstep and the\n // bbox boundary will be missing. This is INCORRECT behavior.\n // \"Figures on adjacent tiles should not overlap\" (PDF spec 8.7.3.1),\n // but overlapping cells without common pixels are still valid.\n // TODO: Fix the implementation, to allow this scenario to be painted\n // correctly.\n\n const x0 = bbox[0],\n y0 = bbox[1],\n x1 = bbox[2],\n y1 = bbox[3];\n\n // Obtain scale from matrix and current transformation matrix.\n const matrixScale = Util.singularValueDecompose2dScale(this.matrix);\n const curMatrixScale = Util.singularValueDecompose2dScale(\n this.baseTransform\n );\n const combinedScale = [\n matrixScale[0] * curMatrixScale[0],\n matrixScale[1] * curMatrixScale[1],\n ];\n\n // Use width and height values that are as close as possible to the end\n // result when the pattern is used. Too low value makes the pattern look\n // blurry. Too large value makes it look too crispy.\n const dimx = this.getSizeAndScale(\n xstep,\n this.ctx.canvas.width,\n combinedScale[0]\n );\n const dimy = this.getSizeAndScale(\n ystep,\n this.ctx.canvas.height,\n combinedScale[1]\n );\n\n const tmpCanvas = owner.cachedCanvases.getCanvas(\n \"pattern\",\n dimx.size,\n dimy.size,\n true\n );\n const tmpCtx = tmpCanvas.context;\n const graphics = canvasGraphicsFactory.createCanvasGraphics(tmpCtx);\n graphics.groupLevel = owner.groupLevel;\n\n this.setFillAndStrokeStyleToContext(graphics, paintType, color);\n\n let adjustedX0 = x0;\n let adjustedY0 = y0;\n let adjustedX1 = x1;\n let adjustedY1 = y1;\n // Some bounding boxes have negative x0/y0 coordinates which will cause the\n // some of the drawing to be off of the canvas. To avoid this shift the\n // bounding box over.\n if (x0 < 0) {\n adjustedX0 = 0;\n adjustedX1 += Math.abs(x0);\n }\n if (y0 < 0) {\n adjustedY0 = 0;\n adjustedY1 += Math.abs(y0);\n }\n tmpCtx.translate(-(dimx.scale * adjustedX0), -(dimy.scale * adjustedY0));\n graphics.transform(dimx.scale, 0, 0, dimy.scale, 0, 0);\n\n // To match CanvasGraphics beginDrawing we must save the context here or\n // else we end up with unbalanced save/restores.\n tmpCtx.save();\n\n this.clipBbox(graphics, adjustedX0, adjustedY0, adjustedX1, adjustedY1);\n\n graphics.baseTransform = getCurrentTransform(graphics.ctx);\n\n graphics.executeOperatorList(operatorList);\n\n graphics.endDrawing();\n\n return {\n canvas: tmpCanvas.canvas,\n scaleX: dimx.scale,\n scaleY: dimy.scale,\n offsetX: adjustedX0,\n offsetY: adjustedY0,\n };\n }\n\n getSizeAndScale(step, realOutputSize, scale) {\n // xstep / ystep may be negative -- normalize.\n step = Math.abs(step);\n // MAX_PATTERN_SIZE is used to avoid OOM situation.\n // Use the destination canvas's size if it is bigger than the hard-coded\n // limit of MAX_PATTERN_SIZE to avoid clipping patterns that cover the\n // whole canvas.\n const maxSize = Math.max(TilingPattern.MAX_PATTERN_SIZE, realOutputSize);\n let size = Math.ceil(step * scale);\n if (size >= maxSize) {\n size = maxSize;\n } else {\n scale = size / step;\n }\n return { scale, size };\n }\n\n clipBbox(graphics, x0, y0, x1, y1) {\n const bboxWidth = x1 - x0;\n const bboxHeight = y1 - y0;\n graphics.ctx.rect(x0, y0, bboxWidth, bboxHeight);\n graphics.current.updateRectMinMax(getCurrentTransform(graphics.ctx), [\n x0,\n y0,\n x1,\n y1,\n ]);\n graphics.clip();\n graphics.endPath();\n }\n\n setFillAndStrokeStyleToContext(graphics, paintType, color) {\n const context = graphics.ctx,\n current = graphics.current;\n switch (paintType) {\n case PaintType.COLORED:\n const ctx = this.ctx;\n context.fillStyle = ctx.fillStyle;\n context.strokeStyle = ctx.strokeStyle;\n current.fillColor = ctx.fillStyle;\n current.strokeColor = ctx.strokeStyle;\n break;\n case PaintType.UNCOLORED:\n const cssColor = Util.makeHexColor(color[0], color[1], color[2]);\n context.fillStyle = cssColor;\n context.strokeStyle = cssColor;\n // Set color needed by image masks (fixes issues 3226 and 8741).\n current.fillColor = cssColor;\n current.strokeColor = cssColor;\n break;\n default:\n throw new FormatError(`Unsupported paint type: ${paintType}`);\n }\n }\n\n getPattern(ctx, owner, inverse, pathType) {\n // PDF spec 8.7.2 NOTE 1: pattern's matrix is relative to initial matrix.\n let matrix = inverse;\n if (pathType !== PathType.SHADING) {\n matrix = Util.transform(matrix, owner.baseTransform);\n if (this.matrix) {\n matrix = Util.transform(matrix, this.matrix);\n }\n }\n\n const temporaryPatternCanvas = this.createPatternCanvas(owner);\n\n let domMatrix = new DOMMatrix(matrix);\n // Rescale and so that the ctx.createPattern call generates a pattern with\n // the desired size.\n domMatrix = domMatrix.translate(\n temporaryPatternCanvas.offsetX,\n temporaryPatternCanvas.offsetY\n );\n domMatrix = domMatrix.scale(\n 1 / temporaryPatternCanvas.scaleX,\n 1 / temporaryPatternCanvas.scaleY\n );\n\n const pattern = ctx.createPattern(temporaryPatternCanvas.canvas, \"repeat\");\n pattern.setTransform(domMatrix);\n\n return pattern;\n }\n}\n\nexport { getShadingPattern, PathType, TilingPattern };\n","/* Copyright 2022 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { FeatureTest, ImageKind } from \"./util.js\";\n\nfunction convertToRGBA(params) {\n switch (params.kind) {\n case ImageKind.GRAYSCALE_1BPP:\n return convertBlackAndWhiteToRGBA(params);\n case ImageKind.RGB_24BPP:\n return convertRGBToRGBA(params);\n }\n\n return null;\n}\n\nfunction convertBlackAndWhiteToRGBA({\n src,\n srcPos = 0,\n dest,\n width,\n height,\n nonBlackColor = 0xffffffff,\n inverseDecode = false,\n}) {\n const black = FeatureTest.isLittleEndian ? 0xff000000 : 0x000000ff;\n const [zeroMapping, oneMapping] = inverseDecode\n ? [nonBlackColor, black]\n : [black, nonBlackColor];\n const widthInSource = width >> 3;\n const widthRemainder = width & 7;\n const srcLength = src.length;\n dest = new Uint32Array(dest.buffer);\n let destPos = 0;\n\n for (let i = 0; i < height; i++) {\n for (const max = srcPos + widthInSource; srcPos < max; srcPos++) {\n const elem = srcPos < srcLength ? src[srcPos] : 255;\n dest[destPos++] = elem & 0b10000000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b1000000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b100000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b10000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b1000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b100 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b10 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b1 ? oneMapping : zeroMapping;\n }\n if (widthRemainder === 0) {\n continue;\n }\n const elem = srcPos < srcLength ? src[srcPos++] : 255;\n for (let j = 0; j < widthRemainder; j++) {\n dest[destPos++] = elem & (1 << (7 - j)) ? oneMapping : zeroMapping;\n }\n }\n return { srcPos, destPos };\n}\n\nfunction convertRGBToRGBA({\n src,\n srcPos = 0,\n dest,\n destPos = 0,\n width,\n height,\n}) {\n let i = 0;\n const len32 = src.length >> 2;\n const src32 = new Uint32Array(src.buffer, srcPos, len32);\n\n if (FeatureTest.isLittleEndian) {\n // It's a way faster to do the shuffle manually instead of working\n // component by component with some Uint8 arrays.\n for (; i < len32 - 2; i += 3, destPos += 4) {\n const s1 = src32[i]; // R2B1G1R1\n const s2 = src32[i + 1]; // G3R3B2G2\n const s3 = src32[i + 2]; // B4G4R4B3\n\n dest[destPos] = s1 | 0xff000000;\n dest[destPos + 1] = (s1 >>> 24) | (s2 << 8) | 0xff000000;\n dest[destPos + 2] = (s2 >>> 16) | (s3 << 16) | 0xff000000;\n dest[destPos + 3] = (s3 >>> 8) | 0xff000000;\n }\n\n for (let j = i * 4, jj = src.length; j < jj; j += 3) {\n dest[destPos++] =\n src[j] | (src[j + 1] << 8) | (src[j + 2] << 16) | 0xff000000;\n }\n } else {\n for (; i < len32 - 2; i += 3, destPos += 4) {\n const s1 = src32[i]; // R1G1B1R2\n const s2 = src32[i + 1]; // G2B2R3G3\n const s3 = src32[i + 2]; // B3R4G4B4\n\n dest[destPos] = s1 | 0xff;\n dest[destPos + 1] = (s1 << 24) | (s2 >>> 8) | 0xff;\n dest[destPos + 2] = (s2 << 16) | (s3 >>> 16) | 0xff;\n dest[destPos + 3] = (s3 << 8) | 0xff;\n }\n\n for (let j = i * 4, jj = src.length; j < jj; j += 3) {\n dest[destPos++] =\n (src[j] << 24) | (src[j + 1] << 16) | (src[j + 2] << 8) | 0xff;\n }\n }\n\n return { srcPos, destPos };\n}\n\nfunction grayToRGBA(src, dest) {\n if (FeatureTest.isLittleEndian) {\n for (let i = 0, ii = src.length; i < ii; i++) {\n dest[i] = (src[i] * 0x10101) | 0xff000000;\n }\n } else {\n for (let i = 0, ii = src.length; i < ii; i++) {\n dest[i] = (src[i] * 0x1010100) | 0x000000ff;\n }\n }\n}\n\nexport { convertBlackAndWhiteToRGBA, convertToRGBA, grayToRGBA };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n FeatureTest,\n FONT_IDENTITY_MATRIX,\n IDENTITY_MATRIX,\n ImageKind,\n info,\n isNodeJS,\n OPS,\n shadow,\n TextRenderingMode,\n unreachable,\n Util,\n warn,\n} from \"../shared/util.js\";\nimport {\n getCurrentTransform,\n getCurrentTransformInverse,\n PixelsPerInch,\n} from \"./display_utils.js\";\nimport {\n getShadingPattern,\n PathType,\n TilingPattern,\n} from \"./pattern_helper.js\";\nimport { convertBlackAndWhiteToRGBA } from \"../shared/image_utils.js\";\n\n// contexts store most of the state we need natively.\n// However, PDF needs a bit more state, which we store here.\n// Minimal font size that would be used during canvas fillText operations.\nconst MIN_FONT_SIZE = 16;\n// Maximum font size that would be used during canvas fillText operations.\nconst MAX_FONT_SIZE = 100;\n\n// Defines the time the `executeOperatorList`-method is going to be executing\n// before it stops and schedules a continue of execution.\nconst EXECUTION_TIME = 15; // ms\n// Defines the number of steps before checking the execution time.\nconst EXECUTION_STEPS = 10;\n\n// To disable Type3 compilation, set the value to `-1`.\nconst MAX_SIZE_TO_COMPILE = 1000;\n\nconst FULL_CHUNK_HEIGHT = 16;\n\n/**\n * Overrides certain methods on a 2d ctx so that when they are called they\n * will also call the same method on the destCtx. The methods that are\n * overridden are all the transformation state modifiers, path creation, and\n * save/restore. We only forward these specific methods because they are the\n * only state modifiers that we cannot copy over when we switch contexts.\n *\n * To remove mirroring call `ctx._removeMirroring()`.\n *\n * @param {Object} ctx - The 2d canvas context that will duplicate its calls on\n * the destCtx.\n * @param {Object} destCtx - The 2d canvas context that will receive the\n * forwarded calls.\n */\nfunction mirrorContextOperations(ctx, destCtx) {\n if (ctx._removeMirroring) {\n throw new Error(\"Context is already forwarding operations.\");\n }\n ctx.__originalSave = ctx.save;\n ctx.__originalRestore = ctx.restore;\n ctx.__originalRotate = ctx.rotate;\n ctx.__originalScale = ctx.scale;\n ctx.__originalTranslate = ctx.translate;\n ctx.__originalTransform = ctx.transform;\n ctx.__originalSetTransform = ctx.setTransform;\n ctx.__originalResetTransform = ctx.resetTransform;\n ctx.__originalClip = ctx.clip;\n ctx.__originalMoveTo = ctx.moveTo;\n ctx.__originalLineTo = ctx.lineTo;\n ctx.__originalBezierCurveTo = ctx.bezierCurveTo;\n ctx.__originalRect = ctx.rect;\n ctx.__originalClosePath = ctx.closePath;\n ctx.__originalBeginPath = ctx.beginPath;\n\n ctx._removeMirroring = () => {\n ctx.save = ctx.__originalSave;\n ctx.restore = ctx.__originalRestore;\n ctx.rotate = ctx.__originalRotate;\n ctx.scale = ctx.__originalScale;\n ctx.translate = ctx.__originalTranslate;\n ctx.transform = ctx.__originalTransform;\n ctx.setTransform = ctx.__originalSetTransform;\n ctx.resetTransform = ctx.__originalResetTransform;\n\n ctx.clip = ctx.__originalClip;\n ctx.moveTo = ctx.__originalMoveTo;\n ctx.lineTo = ctx.__originalLineTo;\n ctx.bezierCurveTo = ctx.__originalBezierCurveTo;\n ctx.rect = ctx.__originalRect;\n ctx.closePath = ctx.__originalClosePath;\n ctx.beginPath = ctx.__originalBeginPath;\n delete ctx._removeMirroring;\n };\n\n ctx.save = function ctxSave() {\n destCtx.save();\n this.__originalSave();\n };\n\n ctx.restore = function ctxRestore() {\n destCtx.restore();\n this.__originalRestore();\n };\n\n ctx.translate = function ctxTranslate(x, y) {\n destCtx.translate(x, y);\n this.__originalTranslate(x, y);\n };\n\n ctx.scale = function ctxScale(x, y) {\n destCtx.scale(x, y);\n this.__originalScale(x, y);\n };\n\n ctx.transform = function ctxTransform(a, b, c, d, e, f) {\n destCtx.transform(a, b, c, d, e, f);\n this.__originalTransform(a, b, c, d, e, f);\n };\n\n ctx.setTransform = function ctxSetTransform(a, b, c, d, e, f) {\n destCtx.setTransform(a, b, c, d, e, f);\n this.__originalSetTransform(a, b, c, d, e, f);\n };\n\n ctx.resetTransform = function ctxResetTransform() {\n destCtx.resetTransform();\n this.__originalResetTransform();\n };\n\n ctx.rotate = function ctxRotate(angle) {\n destCtx.rotate(angle);\n this.__originalRotate(angle);\n };\n\n ctx.clip = function ctxRotate(rule) {\n destCtx.clip(rule);\n this.__originalClip(rule);\n };\n\n ctx.moveTo = function (x, y) {\n destCtx.moveTo(x, y);\n this.__originalMoveTo(x, y);\n };\n\n ctx.lineTo = function (x, y) {\n destCtx.lineTo(x, y);\n this.__originalLineTo(x, y);\n };\n\n ctx.bezierCurveTo = function (cp1x, cp1y, cp2x, cp2y, x, y) {\n destCtx.bezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y);\n this.__originalBezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y);\n };\n\n ctx.rect = function (x, y, width, height) {\n destCtx.rect(x, y, width, height);\n this.__originalRect(x, y, width, height);\n };\n\n ctx.closePath = function () {\n destCtx.closePath();\n this.__originalClosePath();\n };\n\n ctx.beginPath = function () {\n destCtx.beginPath();\n this.__originalBeginPath();\n };\n}\n\nclass CachedCanvases {\n constructor(canvasFactory) {\n this.canvasFactory = canvasFactory;\n this.cache = Object.create(null);\n }\n\n getCanvas(id, width, height) {\n let canvasEntry;\n if (this.cache[id] !== undefined) {\n canvasEntry = this.cache[id];\n this.canvasFactory.reset(canvasEntry, width, height);\n } else {\n canvasEntry = this.canvasFactory.create(width, height);\n this.cache[id] = canvasEntry;\n }\n return canvasEntry;\n }\n\n delete(id) {\n delete this.cache[id];\n }\n\n clear() {\n for (const id in this.cache) {\n const canvasEntry = this.cache[id];\n this.canvasFactory.destroy(canvasEntry);\n delete this.cache[id];\n }\n }\n}\n\nfunction drawImageAtIntegerCoords(\n ctx,\n srcImg,\n srcX,\n srcY,\n srcW,\n srcH,\n destX,\n destY,\n destW,\n destH\n) {\n const [a, b, c, d, tx, ty] = getCurrentTransform(ctx);\n if (b === 0 && c === 0) {\n // top-left corner is at (X, Y) and\n // bottom-right one is at (X + width, Y + height).\n\n // If leftX is 4.321 then it's rounded to 4.\n // If width is 10.432 then it's rounded to 11 because\n // rightX = leftX + width = 14.753 which is rounded to 15\n // so after rounding the total width is 11 (15 - 4).\n // It's why we can't just floor/ceil uniformly, it just depends\n // on the values we've.\n\n const tlX = destX * a + tx;\n const rTlX = Math.round(tlX);\n const tlY = destY * d + ty;\n const rTlY = Math.round(tlY);\n const brX = (destX + destW) * a + tx;\n\n // Some pdf contains images with 1x1 images so in case of 0-width after\n // scaling we must fallback on 1 to be sure there is something.\n const rWidth = Math.abs(Math.round(brX) - rTlX) || 1;\n const brY = (destY + destH) * d + ty;\n const rHeight = Math.abs(Math.round(brY) - rTlY) || 1;\n\n // We must apply a transformation in order to apply it on the image itself.\n // For example if a == 1 && d == -1, it means that the image itself is\n // mirrored w.r.t. the x-axis.\n ctx.setTransform(Math.sign(a), 0, 0, Math.sign(d), rTlX, rTlY);\n ctx.drawImage(srcImg, srcX, srcY, srcW, srcH, 0, 0, rWidth, rHeight);\n ctx.setTransform(a, b, c, d, tx, ty);\n\n return [rWidth, rHeight];\n }\n\n if (a === 0 && d === 0) {\n // This path is taken in issue9462.pdf (page 3).\n const tlX = destY * c + tx;\n const rTlX = Math.round(tlX);\n const tlY = destX * b + ty;\n const rTlY = Math.round(tlY);\n const brX = (destY + destH) * c + tx;\n const rWidth = Math.abs(Math.round(brX) - rTlX) || 1;\n const brY = (destX + destW) * b + ty;\n const rHeight = Math.abs(Math.round(brY) - rTlY) || 1;\n\n ctx.setTransform(0, Math.sign(b), Math.sign(c), 0, rTlX, rTlY);\n ctx.drawImage(srcImg, srcX, srcY, srcW, srcH, 0, 0, rHeight, rWidth);\n ctx.setTransform(a, b, c, d, tx, ty);\n\n return [rHeight, rWidth];\n }\n\n // Not a scale matrix so let the render handle the case without rounding.\n ctx.drawImage(srcImg, srcX, srcY, srcW, srcH, destX, destY, destW, destH);\n\n const scaleX = Math.hypot(a, b);\n const scaleY = Math.hypot(c, d);\n return [scaleX * destW, scaleY * destH];\n}\n\nfunction compileType3Glyph(imgData) {\n const { width, height } = imgData;\n if (width > MAX_SIZE_TO_COMPILE || height > MAX_SIZE_TO_COMPILE) {\n return null;\n }\n\n const POINT_TO_PROCESS_LIMIT = 1000;\n const POINT_TYPES = new Uint8Array([\n 0, 2, 4, 0, 1, 0, 5, 4, 8, 10, 0, 8, 0, 2, 1, 0,\n ]);\n\n const width1 = width + 1;\n let points = new Uint8Array(width1 * (height + 1));\n let i, j, j0;\n\n // decodes bit-packed mask data\n const lineSize = (width + 7) & ~7;\n let data = new Uint8Array(lineSize * height),\n pos = 0;\n for (const elem of imgData.data) {\n let mask = 128;\n while (mask > 0) {\n data[pos++] = elem & mask ? 0 : 255;\n mask >>= 1;\n }\n }\n\n // finding interesting points: every point is located between mask pixels,\n // so there will be points of the (width + 1)x(height + 1) grid. Every point\n // will have flags assigned based on neighboring mask pixels:\n // 4 | 8\n // --P--\n // 2 | 1\n // We are interested only in points with the flags:\n // - outside corners: 1, 2, 4, 8;\n // - inside corners: 7, 11, 13, 14;\n // - and, intersections: 5, 10.\n let count = 0;\n pos = 0;\n if (data[pos] !== 0) {\n points[0] = 1;\n ++count;\n }\n for (j = 1; j < width; j++) {\n if (data[pos] !== data[pos + 1]) {\n points[j] = data[pos] ? 2 : 1;\n ++count;\n }\n pos++;\n }\n if (data[pos] !== 0) {\n points[j] = 2;\n ++count;\n }\n for (i = 1; i < height; i++) {\n pos = i * lineSize;\n j0 = i * width1;\n if (data[pos - lineSize] !== data[pos]) {\n points[j0] = data[pos] ? 1 : 8;\n ++count;\n }\n // 'sum' is the position of the current pixel configuration in the 'TYPES'\n // array (in order 8-1-2-4, so we can use '>>2' to shift the column).\n let sum = (data[pos] ? 4 : 0) + (data[pos - lineSize] ? 8 : 0);\n for (j = 1; j < width; j++) {\n sum =\n (sum >> 2) +\n (data[pos + 1] ? 4 : 0) +\n (data[pos - lineSize + 1] ? 8 : 0);\n if (POINT_TYPES[sum]) {\n points[j0 + j] = POINT_TYPES[sum];\n ++count;\n }\n pos++;\n }\n if (data[pos - lineSize] !== data[pos]) {\n points[j0 + j] = data[pos] ? 2 : 4;\n ++count;\n }\n\n if (count > POINT_TO_PROCESS_LIMIT) {\n return null;\n }\n }\n\n pos = lineSize * (height - 1);\n j0 = i * width1;\n if (data[pos] !== 0) {\n points[j0] = 8;\n ++count;\n }\n for (j = 1; j < width; j++) {\n if (data[pos] !== data[pos + 1]) {\n points[j0 + j] = data[pos] ? 4 : 8;\n ++count;\n }\n pos++;\n }\n if (data[pos] !== 0) {\n points[j0 + j] = 4;\n ++count;\n }\n if (count > POINT_TO_PROCESS_LIMIT) {\n return null;\n }\n\n // building outlines\n const steps = new Int32Array([0, width1, -1, 0, -width1, 0, 0, 0, 1]);\n const path = new Path2D();\n\n for (i = 0; count && i <= height; i++) {\n let p = i * width1;\n const end = p + width;\n while (p < end && !points[p]) {\n p++;\n }\n if (p === end) {\n continue;\n }\n path.moveTo(p % width1, i);\n\n const p0 = p;\n let type = points[p];\n do {\n const step = steps[type];\n do {\n p += step;\n } while (!points[p]);\n\n const pp = points[p];\n if (pp !== 5 && pp !== 10) {\n // set new direction\n type = pp;\n // delete mark\n points[p] = 0;\n } else {\n // type is 5 or 10, ie, a crossing\n // set new direction\n type = pp & ((0x33 * type) >> 4);\n // set new type for \"future hit\"\n points[p] &= (type >> 2) | (type << 2);\n }\n path.lineTo(p % width1, (p / width1) | 0);\n\n if (!points[p]) {\n --count;\n }\n } while (p0 !== p);\n --i;\n }\n\n // Immediately release the, potentially large, `Uint8Array`s after parsing.\n data = null;\n points = null;\n\n const drawOutline = function (c) {\n c.save();\n // the path shall be painted in [0..1]x[0..1] space\n c.scale(1 / width, -1 / height);\n c.translate(0, -height);\n c.fill(path);\n c.beginPath();\n c.restore();\n };\n\n return drawOutline;\n}\n\nclass CanvasExtraState {\n constructor(width, height) {\n // Are soft masks and alpha values shapes or opacities?\n this.alphaIsShape = false;\n this.fontSize = 0;\n this.fontSizeScale = 1;\n this.textMatrix = IDENTITY_MATRIX;\n this.textMatrixScale = 1;\n this.fontMatrix = FONT_IDENTITY_MATRIX;\n this.leading = 0;\n // Current point (in user coordinates)\n this.x = 0;\n this.y = 0;\n // Start of text line (in text coordinates)\n this.lineX = 0;\n this.lineY = 0;\n // Character and word spacing\n this.charSpacing = 0;\n this.wordSpacing = 0;\n this.textHScale = 1;\n this.textRenderingMode = TextRenderingMode.FILL;\n this.textRise = 0;\n // Default fore and background colors\n this.fillColor = \"#000000\";\n this.strokeColor = \"#000000\";\n this.patternFill = false;\n // Note: fill alpha applies to all non-stroking operations\n this.fillAlpha = 1;\n this.strokeAlpha = 1;\n this.lineWidth = 1;\n this.activeSMask = null;\n this.transferMaps = \"none\";\n\n this.startNewPathAndClipBox([0, 0, width, height]);\n }\n\n clone() {\n const clone = Object.create(this);\n clone.clipBox = this.clipBox.slice();\n return clone;\n }\n\n setCurrentPoint(x, y) {\n this.x = x;\n this.y = y;\n }\n\n updatePathMinMax(transform, x, y) {\n [x, y] = Util.applyTransform([x, y], transform);\n this.minX = Math.min(this.minX, x);\n this.minY = Math.min(this.minY, y);\n this.maxX = Math.max(this.maxX, x);\n this.maxY = Math.max(this.maxY, y);\n }\n\n updateRectMinMax(transform, rect) {\n const p1 = Util.applyTransform(rect, transform);\n const p2 = Util.applyTransform(rect.slice(2), transform);\n const p3 = Util.applyTransform([rect[0], rect[3]], transform);\n const p4 = Util.applyTransform([rect[2], rect[1]], transform);\n\n this.minX = Math.min(this.minX, p1[0], p2[0], p3[0], p4[0]);\n this.minY = Math.min(this.minY, p1[1], p2[1], p3[1], p4[1]);\n this.maxX = Math.max(this.maxX, p1[0], p2[0], p3[0], p4[0]);\n this.maxY = Math.max(this.maxY, p1[1], p2[1], p3[1], p4[1]);\n }\n\n updateScalingPathMinMax(transform, minMax) {\n Util.scaleMinMax(transform, minMax);\n this.minX = Math.min(this.minX, minMax[0]);\n this.minY = Math.min(this.minY, minMax[1]);\n this.maxX = Math.max(this.maxX, minMax[2]);\n this.maxY = Math.max(this.maxY, minMax[3]);\n }\n\n updateCurvePathMinMax(transform, x0, y0, x1, y1, x2, y2, x3, y3, minMax) {\n const box = Util.bezierBoundingBox(x0, y0, x1, y1, x2, y2, x3, y3, minMax);\n if (minMax) {\n return;\n }\n this.updateRectMinMax(transform, box);\n }\n\n getPathBoundingBox(pathType = PathType.FILL, transform = null) {\n const box = [this.minX, this.minY, this.maxX, this.maxY];\n if (pathType === PathType.STROKE) {\n if (!transform) {\n unreachable(\"Stroke bounding box must include transform.\");\n }\n // Stroked paths can be outside of the path bounding box by 1/2 the line\n // width.\n const scale = Util.singularValueDecompose2dScale(transform);\n const xStrokePad = (scale[0] * this.lineWidth) / 2;\n const yStrokePad = (scale[1] * this.lineWidth) / 2;\n box[0] -= xStrokePad;\n box[1] -= yStrokePad;\n box[2] += xStrokePad;\n box[3] += yStrokePad;\n }\n return box;\n }\n\n updateClipFromPath() {\n const intersect = Util.intersect(this.clipBox, this.getPathBoundingBox());\n this.startNewPathAndClipBox(intersect || [0, 0, 0, 0]);\n }\n\n isEmptyClip() {\n return this.minX === Infinity;\n }\n\n startNewPathAndClipBox(box) {\n this.clipBox = box;\n this.minX = Infinity;\n this.minY = Infinity;\n this.maxX = 0;\n this.maxY = 0;\n }\n\n getClippedPathBoundingBox(pathType = PathType.FILL, transform = null) {\n return Util.intersect(\n this.clipBox,\n this.getPathBoundingBox(pathType, transform)\n );\n }\n}\n\nfunction putBinaryImageData(ctx, imgData) {\n if (typeof ImageData !== \"undefined\" && imgData instanceof ImageData) {\n ctx.putImageData(imgData, 0, 0);\n return;\n }\n\n // Put the image data to the canvas in chunks, rather than putting the\n // whole image at once. This saves JS memory, because the ImageData object\n // is smaller. It also possibly saves C++ memory within the implementation\n // of putImageData(). (E.g. in Firefox we make two short-lived copies of\n // the data passed to putImageData()). |n| shouldn't be too small, however,\n // because too many putImageData() calls will slow things down.\n //\n // Note: as written, if the last chunk is partial, the putImageData() call\n // will (conceptually) put pixels past the bounds of the canvas. But\n // that's ok; any such pixels are ignored.\n\n const height = imgData.height,\n width = imgData.width;\n const partialChunkHeight = height % FULL_CHUNK_HEIGHT;\n const fullChunks = (height - partialChunkHeight) / FULL_CHUNK_HEIGHT;\n const totalChunks = partialChunkHeight === 0 ? fullChunks : fullChunks + 1;\n\n const chunkImgData = ctx.createImageData(width, FULL_CHUNK_HEIGHT);\n let srcPos = 0,\n destPos;\n const src = imgData.data;\n const dest = chunkImgData.data;\n let i, j, thisChunkHeight, elemsInThisChunk;\n\n // There are multiple forms in which the pixel data can be passed, and\n // imgData.kind tells us which one this is.\n if (imgData.kind === ImageKind.GRAYSCALE_1BPP) {\n // Grayscale, 1 bit per pixel (i.e. black-and-white).\n const srcLength = src.byteLength;\n const dest32 = new Uint32Array(dest.buffer, 0, dest.byteLength >> 2);\n const dest32DataLength = dest32.length;\n const fullSrcDiff = (width + 7) >> 3;\n const white = 0xffffffff;\n const black = FeatureTest.isLittleEndian ? 0xff000000 : 0x000000ff;\n\n for (i = 0; i < totalChunks; i++) {\n thisChunkHeight = i < fullChunks ? FULL_CHUNK_HEIGHT : partialChunkHeight;\n destPos = 0;\n for (j = 0; j < thisChunkHeight; j++) {\n const srcDiff = srcLength - srcPos;\n let k = 0;\n const kEnd = srcDiff > fullSrcDiff ? width : srcDiff * 8 - 7;\n const kEndUnrolled = kEnd & ~7;\n let mask = 0;\n let srcByte = 0;\n for (; k < kEndUnrolled; k += 8) {\n srcByte = src[srcPos++];\n dest32[destPos++] = srcByte & 128 ? white : black;\n dest32[destPos++] = srcByte & 64 ? white : black;\n dest32[destPos++] = srcByte & 32 ? white : black;\n dest32[destPos++] = srcByte & 16 ? white : black;\n dest32[destPos++] = srcByte & 8 ? white : black;\n dest32[destPos++] = srcByte & 4 ? white : black;\n dest32[destPos++] = srcByte & 2 ? white : black;\n dest32[destPos++] = srcByte & 1 ? white : black;\n }\n for (; k < kEnd; k++) {\n if (mask === 0) {\n srcByte = src[srcPos++];\n mask = 128;\n }\n\n dest32[destPos++] = srcByte & mask ? white : black;\n mask >>= 1;\n }\n }\n // We ran out of input. Make all remaining pixels transparent.\n while (destPos < dest32DataLength) {\n dest32[destPos++] = 0;\n }\n\n ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT);\n }\n } else if (imgData.kind === ImageKind.RGBA_32BPP) {\n // RGBA, 32-bits per pixel.\n j = 0;\n elemsInThisChunk = width * FULL_CHUNK_HEIGHT * 4;\n for (i = 0; i < fullChunks; i++) {\n dest.set(src.subarray(srcPos, srcPos + elemsInThisChunk));\n srcPos += elemsInThisChunk;\n\n ctx.putImageData(chunkImgData, 0, j);\n j += FULL_CHUNK_HEIGHT;\n }\n if (i < totalChunks) {\n elemsInThisChunk = width * partialChunkHeight * 4;\n dest.set(src.subarray(srcPos, srcPos + elemsInThisChunk));\n\n ctx.putImageData(chunkImgData, 0, j);\n }\n } else if (imgData.kind === ImageKind.RGB_24BPP) {\n // RGB, 24-bits per pixel.\n thisChunkHeight = FULL_CHUNK_HEIGHT;\n elemsInThisChunk = width * thisChunkHeight;\n for (i = 0; i < totalChunks; i++) {\n if (i >= fullChunks) {\n thisChunkHeight = partialChunkHeight;\n elemsInThisChunk = width * thisChunkHeight;\n }\n\n destPos = 0;\n for (j = elemsInThisChunk; j--; ) {\n dest[destPos++] = src[srcPos++];\n dest[destPos++] = src[srcPos++];\n dest[destPos++] = src[srcPos++];\n dest[destPos++] = 255;\n }\n\n ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT);\n }\n } else {\n throw new Error(`bad image kind: ${imgData.kind}`);\n }\n}\n\nfunction putBinaryImageMask(ctx, imgData) {\n if (imgData.bitmap) {\n // The bitmap has been created in the worker.\n ctx.drawImage(imgData.bitmap, 0, 0);\n return;\n }\n\n // Slow path: OffscreenCanvas isn't available in the worker.\n const height = imgData.height,\n width = imgData.width;\n const partialChunkHeight = height % FULL_CHUNK_HEIGHT;\n const fullChunks = (height - partialChunkHeight) / FULL_CHUNK_HEIGHT;\n const totalChunks = partialChunkHeight === 0 ? fullChunks : fullChunks + 1;\n\n const chunkImgData = ctx.createImageData(width, FULL_CHUNK_HEIGHT);\n let srcPos = 0;\n const src = imgData.data;\n const dest = chunkImgData.data;\n\n for (let i = 0; i < totalChunks; i++) {\n const thisChunkHeight =\n i < fullChunks ? FULL_CHUNK_HEIGHT : partialChunkHeight;\n\n // Expand the mask so it can be used by the canvas. Any required\n // inversion has already been handled.\n\n ({ srcPos } = convertBlackAndWhiteToRGBA({\n src,\n srcPos,\n dest,\n width,\n height: thisChunkHeight,\n nonBlackColor: 0,\n }));\n\n ctx.putImageData(chunkImgData, 0, i * FULL_CHUNK_HEIGHT);\n }\n}\n\nfunction copyCtxState(sourceCtx, destCtx) {\n const properties = [\n \"strokeStyle\",\n \"fillStyle\",\n \"fillRule\",\n \"globalAlpha\",\n \"lineWidth\",\n \"lineCap\",\n \"lineJoin\",\n \"miterLimit\",\n \"globalCompositeOperation\",\n \"font\",\n \"filter\",\n ];\n for (const property of properties) {\n if (sourceCtx[property] !== undefined) {\n destCtx[property] = sourceCtx[property];\n }\n }\n if (sourceCtx.setLineDash !== undefined) {\n destCtx.setLineDash(sourceCtx.getLineDash());\n destCtx.lineDashOffset = sourceCtx.lineDashOffset;\n }\n}\n\nfunction resetCtxToDefault(ctx) {\n ctx.strokeStyle = ctx.fillStyle = \"#000000\";\n ctx.fillRule = \"nonzero\";\n ctx.globalAlpha = 1;\n ctx.lineWidth = 1;\n ctx.lineCap = \"butt\";\n ctx.lineJoin = \"miter\";\n ctx.miterLimit = 10;\n ctx.globalCompositeOperation = \"source-over\";\n ctx.font = \"10px sans-serif\";\n if (ctx.setLineDash !== undefined) {\n ctx.setLineDash([]);\n ctx.lineDashOffset = 0;\n }\n if (\n (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) ||\n !isNodeJS\n ) {\n const { filter } = ctx;\n if (filter !== \"none\" && filter !== \"\") {\n ctx.filter = \"none\";\n }\n }\n}\n\nfunction getImageSmoothingEnabled(transform, interpolate) {\n // In section 8.9.5.3 of the PDF spec, it's mentioned that the interpolate\n // flag should be used when the image is upscaled.\n // In Firefox, smoothing is always used when downscaling images (bug 1360415).\n\n if (interpolate) {\n return true;\n }\n\n const scale = Util.singularValueDecompose2dScale(transform);\n // Round to a 32bit float so that `<=` check below will pass for numbers that\n // are very close, but not exactly the same 64bit floats.\n scale[0] = Math.fround(scale[0]);\n scale[1] = Math.fround(scale[1]);\n const actualScale = Math.fround(\n (globalThis.devicePixelRatio || 1) * PixelsPerInch.PDF_TO_CSS_UNITS\n );\n return scale[0] <= actualScale && scale[1] <= actualScale;\n}\n\nconst LINE_CAP_STYLES = [\"butt\", \"round\", \"square\"];\nconst LINE_JOIN_STYLES = [\"miter\", \"round\", \"bevel\"];\nconst NORMAL_CLIP = {};\nconst EO_CLIP = {};\n\nclass CanvasGraphics {\n constructor(\n canvasCtx,\n commonObjs,\n objs,\n canvasFactory,\n filterFactory,\n { optionalContentConfig, markedContentStack = null },\n annotationCanvasMap,\n pageColors\n ) {\n this.ctx = canvasCtx;\n this.current = new CanvasExtraState(\n this.ctx.canvas.width,\n this.ctx.canvas.height\n );\n this.stateStack = [];\n this.pendingClip = null;\n this.pendingEOFill = false;\n this.res = null;\n this.xobjs = null;\n this.commonObjs = commonObjs;\n this.objs = objs;\n this.canvasFactory = canvasFactory;\n this.filterFactory = filterFactory;\n this.groupStack = [];\n this.processingType3 = null;\n // Patterns are painted relative to the initial page/form transform, see\n // PDF spec 8.7.2 NOTE 1.\n this.baseTransform = null;\n this.baseTransformStack = [];\n this.groupLevel = 0;\n this.smaskStack = [];\n this.smaskCounter = 0;\n this.tempSMask = null;\n this.suspendedCtx = null;\n this.contentVisible = true;\n this.markedContentStack = markedContentStack || [];\n this.optionalContentConfig = optionalContentConfig;\n this.cachedCanvases = new CachedCanvases(this.canvasFactory);\n this.cachedPatterns = new Map();\n this.annotationCanvasMap = annotationCanvasMap;\n this.viewportScale = 1;\n this.outputScaleX = 1;\n this.outputScaleY = 1;\n this.pageColors = pageColors;\n\n this._cachedScaleForStroking = [-1, 0];\n this._cachedGetSinglePixelWidth = null;\n this._cachedBitmapsMap = new Map();\n }\n\n getObject(data, fallback = null) {\n if (typeof data === \"string\") {\n return data.startsWith(\"g_\")\n ? this.commonObjs.get(data)\n : this.objs.get(data);\n }\n return fallback;\n }\n\n beginDrawing({\n transform,\n viewport,\n transparency = false,\n background = null,\n }) {\n // For pdfs that use blend modes we have to clear the canvas else certain\n // blend modes can look wrong since we'd be blending with a white\n // backdrop. The problem with a transparent backdrop though is we then\n // don't get sub pixel anti aliasing on text, creating temporary\n // transparent canvas when we have blend modes.\n const width = this.ctx.canvas.width;\n const height = this.ctx.canvas.height;\n\n const savedFillStyle = this.ctx.fillStyle;\n this.ctx.fillStyle = background || \"#ffffff\";\n this.ctx.fillRect(0, 0, width, height);\n this.ctx.fillStyle = savedFillStyle;\n\n if (transparency) {\n const transparentCanvas = this.cachedCanvases.getCanvas(\n \"transparent\",\n width,\n height\n );\n this.compositeCtx = this.ctx;\n this.transparentCanvas = transparentCanvas.canvas;\n this.ctx = transparentCanvas.context;\n this.ctx.save();\n // The transform can be applied before rendering, transferring it to\n // the new canvas.\n this.ctx.transform(...getCurrentTransform(this.compositeCtx));\n }\n\n this.ctx.save();\n resetCtxToDefault(this.ctx);\n if (transform) {\n this.ctx.transform(...transform);\n this.outputScaleX = transform[0];\n this.outputScaleY = transform[0];\n }\n this.ctx.transform(...viewport.transform);\n this.viewportScale = viewport.scale;\n\n this.baseTransform = getCurrentTransform(this.ctx);\n }\n\n executeOperatorList(\n operatorList,\n executionStartIdx,\n continueCallback,\n stepper\n ) {\n const argsArray = operatorList.argsArray;\n const fnArray = operatorList.fnArray;\n let i = executionStartIdx || 0;\n const argsArrayLen = argsArray.length;\n\n // Sometimes the OperatorList to execute is empty.\n if (argsArrayLen === i) {\n return i;\n }\n\n const chunkOperations =\n argsArrayLen - i > EXECUTION_STEPS &&\n typeof continueCallback === \"function\";\n const endTime = chunkOperations ? Date.now() + EXECUTION_TIME : 0;\n let steps = 0;\n\n const commonObjs = this.commonObjs;\n const objs = this.objs;\n let fnId;\n\n while (true) {\n if (stepper !== undefined && i === stepper.nextBreakPoint) {\n stepper.breakIt(i, continueCallback);\n return i;\n }\n\n fnId = fnArray[i];\n\n if (fnId !== OPS.dependency) {\n // eslint-disable-next-line prefer-spread\n this[fnId].apply(this, argsArray[i]);\n } else {\n for (const depObjId of argsArray[i]) {\n const objsPool = depObjId.startsWith(\"g_\") ? commonObjs : objs;\n\n // If the promise isn't resolved yet, add the continueCallback\n // to the promise and bail out.\n if (!objsPool.has(depObjId)) {\n objsPool.get(depObjId, continueCallback);\n return i;\n }\n }\n }\n\n i++;\n\n // If the entire operatorList was executed, stop as were done.\n if (i === argsArrayLen) {\n return i;\n }\n\n // If the execution took longer then a certain amount of time and\n // `continueCallback` is specified, interrupt the execution.\n if (chunkOperations && ++steps > EXECUTION_STEPS) {\n if (Date.now() > endTime) {\n continueCallback();\n return i;\n }\n steps = 0;\n }\n\n // If the operatorList isn't executed completely yet OR the execution\n // time was short enough, do another execution round.\n }\n }\n\n #restoreInitialState() {\n // Finishing all opened operations such as SMask group painting.\n while (this.stateStack.length || this.inSMaskMode) {\n this.restore();\n }\n\n this.ctx.restore();\n\n if (this.transparentCanvas) {\n this.ctx = this.compositeCtx;\n this.ctx.save();\n this.ctx.setTransform(1, 0, 0, 1, 0, 0); // Avoid apply transform twice\n this.ctx.drawImage(this.transparentCanvas, 0, 0);\n this.ctx.restore();\n this.transparentCanvas = null;\n }\n }\n\n endDrawing() {\n this.#restoreInitialState();\n\n this.cachedCanvases.clear();\n this.cachedPatterns.clear();\n\n for (const cache of this._cachedBitmapsMap.values()) {\n for (const canvas of cache.values()) {\n if (\n typeof HTMLCanvasElement !== \"undefined\" &&\n canvas instanceof HTMLCanvasElement\n ) {\n canvas.width = canvas.height = 0;\n }\n }\n cache.clear();\n }\n this._cachedBitmapsMap.clear();\n this.#drawFilter();\n }\n\n #drawFilter() {\n if (this.pageColors) {\n const hcmFilterId = this.filterFactory.addHCMFilter(\n this.pageColors.foreground,\n this.pageColors.background\n );\n if (hcmFilterId !== \"none\") {\n const savedFilter = this.ctx.filter;\n this.ctx.filter = hcmFilterId;\n this.ctx.drawImage(this.ctx.canvas, 0, 0);\n this.ctx.filter = savedFilter;\n }\n }\n }\n\n _scaleImage(img, inverseTransform) {\n // Vertical or horizontal scaling shall not be more than 2 to not lose the\n // pixels during drawImage operation, painting on the temporary canvas(es)\n // that are twice smaller in size.\n const width = img.width;\n const height = img.height;\n let widthScale = Math.max(\n Math.hypot(inverseTransform[0], inverseTransform[1]),\n 1\n );\n let heightScale = Math.max(\n Math.hypot(inverseTransform[2], inverseTransform[3]),\n 1\n );\n\n let paintWidth = width,\n paintHeight = height;\n let tmpCanvasId = \"prescale1\";\n let tmpCanvas, tmpCtx;\n while (\n (widthScale > 2 && paintWidth > 1) ||\n (heightScale > 2 && paintHeight > 1)\n ) {\n let newWidth = paintWidth,\n newHeight = paintHeight;\n if (widthScale > 2 && paintWidth > 1) {\n // See bug 1820511 (Windows specific bug).\n // TODO: once the above bug is fixed we could revert to:\n // newWidth = Math.ceil(paintWidth / 2);\n newWidth =\n paintWidth >= 16384\n ? Math.floor(paintWidth / 2) - 1 || 1\n : Math.ceil(paintWidth / 2);\n widthScale /= paintWidth / newWidth;\n }\n if (heightScale > 2 && paintHeight > 1) {\n // TODO: see the comment above.\n newHeight =\n paintHeight >= 16384\n ? Math.floor(paintHeight / 2) - 1 || 1\n : Math.ceil(paintHeight) / 2;\n heightScale /= paintHeight / newHeight;\n }\n tmpCanvas = this.cachedCanvases.getCanvas(\n tmpCanvasId,\n newWidth,\n newHeight\n );\n tmpCtx = tmpCanvas.context;\n tmpCtx.clearRect(0, 0, newWidth, newHeight);\n tmpCtx.drawImage(\n img,\n 0,\n 0,\n paintWidth,\n paintHeight,\n 0,\n 0,\n newWidth,\n newHeight\n );\n img = tmpCanvas.canvas;\n paintWidth = newWidth;\n paintHeight = newHeight;\n tmpCanvasId = tmpCanvasId === \"prescale1\" ? \"prescale2\" : \"prescale1\";\n }\n return {\n img,\n paintWidth,\n paintHeight,\n };\n }\n\n _createMaskCanvas(img) {\n const ctx = this.ctx;\n const { width, height } = img;\n const fillColor = this.current.fillColor;\n const isPatternFill = this.current.patternFill;\n const currentTransform = getCurrentTransform(ctx);\n\n let cache, cacheKey, scaled, maskCanvas;\n if ((img.bitmap || img.data) && img.count > 1) {\n const mainKey = img.bitmap || img.data.buffer;\n // We're reusing the same image several times, so we can cache it.\n // In case we've a pattern fill we just keep the scaled version of\n // the image.\n // Only the scaling part matters, the translation part is just used\n // to compute offsets (but not when filling patterns see #15573).\n // TODO: handle the case of a pattern fill if it's possible.\n cacheKey = JSON.stringify(\n isPatternFill\n ? currentTransform\n : [currentTransform.slice(0, 4), fillColor]\n );\n\n cache = this._cachedBitmapsMap.get(mainKey);\n if (!cache) {\n cache = new Map();\n this._cachedBitmapsMap.set(mainKey, cache);\n }\n const cachedImage = cache.get(cacheKey);\n if (cachedImage && !isPatternFill) {\n const offsetX = Math.round(\n Math.min(currentTransform[0], currentTransform[2]) +\n currentTransform[4]\n );\n const offsetY = Math.round(\n Math.min(currentTransform[1], currentTransform[3]) +\n currentTransform[5]\n );\n return {\n canvas: cachedImage,\n offsetX,\n offsetY,\n };\n }\n scaled = cachedImage;\n }\n\n if (!scaled) {\n maskCanvas = this.cachedCanvases.getCanvas(\"maskCanvas\", width, height);\n putBinaryImageMask(maskCanvas.context, img);\n }\n\n // Create the mask canvas at the size it will be drawn at and also set\n // its transform to match the current transform so if there are any\n // patterns applied they will be applied relative to the correct\n // transform.\n\n let maskToCanvas = Util.transform(currentTransform, [\n 1 / width,\n 0,\n 0,\n -1 / height,\n 0,\n 0,\n ]);\n maskToCanvas = Util.transform(maskToCanvas, [1, 0, 0, 1, 0, -height]);\n const [minX, minY, maxX, maxY] = Util.getAxialAlignedBoundingBox(\n [0, 0, width, height],\n maskToCanvas\n );\n const drawnWidth = Math.round(maxX - minX) || 1;\n const drawnHeight = Math.round(maxY - minY) || 1;\n const fillCanvas = this.cachedCanvases.getCanvas(\n \"fillCanvas\",\n drawnWidth,\n drawnHeight\n );\n const fillCtx = fillCanvas.context;\n\n // The offset will be the top-left cordinate mask.\n // If objToCanvas is [a,b,c,d,e,f] then:\n // - offsetX = min(a, c) + e\n // - offsetY = min(b, d) + f\n const offsetX = minX;\n const offsetY = minY;\n fillCtx.translate(-offsetX, -offsetY);\n fillCtx.transform(...maskToCanvas);\n\n if (!scaled) {\n // Pre-scale if needed to improve image smoothing.\n scaled = this._scaleImage(\n maskCanvas.canvas,\n getCurrentTransformInverse(fillCtx)\n );\n scaled = scaled.img;\n if (cache && isPatternFill) {\n cache.set(cacheKey, scaled);\n }\n }\n\n fillCtx.imageSmoothingEnabled = getImageSmoothingEnabled(\n getCurrentTransform(fillCtx),\n img.interpolate\n );\n\n drawImageAtIntegerCoords(\n fillCtx,\n scaled,\n 0,\n 0,\n scaled.width,\n scaled.height,\n 0,\n 0,\n width,\n height\n );\n fillCtx.globalCompositeOperation = \"source-in\";\n\n const inverse = Util.transform(getCurrentTransformInverse(fillCtx), [\n 1,\n 0,\n 0,\n 1,\n -offsetX,\n -offsetY,\n ]);\n fillCtx.fillStyle = isPatternFill\n ? fillColor.getPattern(ctx, this, inverse, PathType.FILL)\n : fillColor;\n\n fillCtx.fillRect(0, 0, width, height);\n\n if (cache && !isPatternFill) {\n // The fill canvas is put in the cache associated to the mask image\n // so we must remove from the cached canvas: it mustn't be used again.\n this.cachedCanvases.delete(\"fillCanvas\");\n cache.set(cacheKey, fillCanvas.canvas);\n }\n\n // Round the offsets to avoid drawing fractional pixels.\n return {\n canvas: fillCanvas.canvas,\n offsetX: Math.round(offsetX),\n offsetY: Math.round(offsetY),\n };\n }\n\n // Graphics state\n setLineWidth(width) {\n if (width !== this.current.lineWidth) {\n this._cachedScaleForStroking[0] = -1;\n }\n this.current.lineWidth = width;\n this.ctx.lineWidth = width;\n }\n\n setLineCap(style) {\n this.ctx.lineCap = LINE_CAP_STYLES[style];\n }\n\n setLineJoin(style) {\n this.ctx.lineJoin = LINE_JOIN_STYLES[style];\n }\n\n setMiterLimit(limit) {\n this.ctx.miterLimit = limit;\n }\n\n setDash(dashArray, dashPhase) {\n const ctx = this.ctx;\n if (ctx.setLineDash !== undefined) {\n ctx.setLineDash(dashArray);\n ctx.lineDashOffset = dashPhase;\n }\n }\n\n setRenderingIntent(intent) {\n // This operation is ignored since we haven't found a use case for it yet.\n }\n\n setFlatness(flatness) {\n // This operation is ignored since we haven't found a use case for it yet.\n }\n\n setGState(states) {\n for (const [key, value] of states) {\n switch (key) {\n case \"LW\":\n this.setLineWidth(value);\n break;\n case \"LC\":\n this.setLineCap(value);\n break;\n case \"LJ\":\n this.setLineJoin(value);\n break;\n case \"ML\":\n this.setMiterLimit(value);\n break;\n case \"D\":\n this.setDash(value[0], value[1]);\n break;\n case \"RI\":\n this.setRenderingIntent(value);\n break;\n case \"FL\":\n this.setFlatness(value);\n break;\n case \"Font\":\n this.setFont(value[0], value[1]);\n break;\n case \"CA\":\n this.current.strokeAlpha = value;\n break;\n case \"ca\":\n this.current.fillAlpha = value;\n this.ctx.globalAlpha = value;\n break;\n case \"BM\":\n this.ctx.globalCompositeOperation = value;\n break;\n case \"SMask\":\n this.current.activeSMask = value ? this.tempSMask : null;\n this.tempSMask = null;\n this.checkSMaskState();\n break;\n case \"TR\":\n this.ctx.filter = this.current.transferMaps =\n this.filterFactory.addFilter(value);\n break;\n }\n }\n }\n\n get inSMaskMode() {\n return !!this.suspendedCtx;\n }\n\n checkSMaskState() {\n const inSMaskMode = this.inSMaskMode;\n if (this.current.activeSMask && !inSMaskMode) {\n this.beginSMaskMode();\n } else if (!this.current.activeSMask && inSMaskMode) {\n this.endSMaskMode();\n }\n // Else, the state is okay and nothing needs to be done.\n }\n\n /**\n * Soft mask mode takes the current main drawing canvas and replaces it with\n * a temporary canvas. Any drawing operations that happen on the temporary\n * canvas need to be composed with the main canvas that was suspended (see\n * `compose()`). The temporary canvas also duplicates many of its operations\n * on the suspended canvas to keep them in sync, so that when the soft mask\n * mode ends any clipping paths or transformations will still be active and in\n * the right order on the canvas' graphics state stack.\n */\n beginSMaskMode() {\n if (this.inSMaskMode) {\n throw new Error(\"beginSMaskMode called while already in smask mode\");\n }\n const drawnWidth = this.ctx.canvas.width;\n const drawnHeight = this.ctx.canvas.height;\n const cacheId = \"smaskGroupAt\" + this.groupLevel;\n const scratchCanvas = this.cachedCanvases.getCanvas(\n cacheId,\n drawnWidth,\n drawnHeight\n );\n this.suspendedCtx = this.ctx;\n this.ctx = scratchCanvas.context;\n const ctx = this.ctx;\n ctx.setTransform(...getCurrentTransform(this.suspendedCtx));\n copyCtxState(this.suspendedCtx, ctx);\n mirrorContextOperations(ctx, this.suspendedCtx);\n\n this.setGState([\n [\"BM\", \"source-over\"],\n [\"ca\", 1],\n [\"CA\", 1],\n ]);\n }\n\n endSMaskMode() {\n if (!this.inSMaskMode) {\n throw new Error(\"endSMaskMode called while not in smask mode\");\n }\n // The soft mask is done, now restore the suspended canvas as the main\n // drawing canvas.\n this.ctx._removeMirroring();\n copyCtxState(this.ctx, this.suspendedCtx);\n this.ctx = this.suspendedCtx;\n\n this.suspendedCtx = null;\n }\n\n compose(dirtyBox) {\n if (!this.current.activeSMask) {\n return;\n }\n\n if (!dirtyBox) {\n dirtyBox = [0, 0, this.ctx.canvas.width, this.ctx.canvas.height];\n } else {\n dirtyBox[0] = Math.floor(dirtyBox[0]);\n dirtyBox[1] = Math.floor(dirtyBox[1]);\n dirtyBox[2] = Math.ceil(dirtyBox[2]);\n dirtyBox[3] = Math.ceil(dirtyBox[3]);\n }\n const smask = this.current.activeSMask;\n const suspendedCtx = this.suspendedCtx;\n\n this.composeSMask(suspendedCtx, smask, this.ctx, dirtyBox);\n // Whatever was drawn has been moved to the suspended canvas, now clear it\n // out of the current canvas.\n this.ctx.save();\n this.ctx.setTransform(1, 0, 0, 1, 0, 0);\n this.ctx.clearRect(0, 0, this.ctx.canvas.width, this.ctx.canvas.height);\n this.ctx.restore();\n }\n\n composeSMask(ctx, smask, layerCtx, layerBox) {\n const layerOffsetX = layerBox[0];\n const layerOffsetY = layerBox[1];\n const layerWidth = layerBox[2] - layerOffsetX;\n const layerHeight = layerBox[3] - layerOffsetY;\n if (layerWidth === 0 || layerHeight === 0) {\n return;\n }\n this.genericComposeSMask(\n smask.context,\n layerCtx,\n layerWidth,\n layerHeight,\n smask.subtype,\n smask.backdrop,\n smask.transferMap,\n layerOffsetX,\n layerOffsetY,\n smask.offsetX,\n smask.offsetY\n );\n ctx.save();\n ctx.globalAlpha = 1;\n ctx.globalCompositeOperation = \"source-over\";\n ctx.setTransform(1, 0, 0, 1, 0, 0);\n ctx.drawImage(layerCtx.canvas, 0, 0);\n ctx.restore();\n }\n\n genericComposeSMask(\n maskCtx,\n layerCtx,\n width,\n height,\n subtype,\n backdrop,\n transferMap,\n layerOffsetX,\n layerOffsetY,\n maskOffsetX,\n maskOffsetY\n ) {\n let maskCanvas = maskCtx.canvas;\n let maskX = layerOffsetX - maskOffsetX;\n let maskY = layerOffsetY - maskOffsetY;\n\n if (backdrop) {\n if (\n maskX < 0 ||\n maskY < 0 ||\n maskX + width > maskCanvas.width ||\n maskY + height > maskCanvas.height\n ) {\n const canvas = this.cachedCanvases.getCanvas(\n \"maskExtension\",\n width,\n height\n );\n const ctx = canvas.context;\n ctx.drawImage(maskCanvas, -maskX, -maskY);\n if (backdrop.some(c => c !== 0)) {\n ctx.globalCompositeOperation = \"destination-atop\";\n ctx.fillStyle = Util.makeHexColor(...backdrop);\n ctx.fillRect(0, 0, width, height);\n ctx.globalCompositeOperation = \"source-over\";\n }\n\n maskCanvas = canvas.canvas;\n maskX = maskY = 0;\n } else if (backdrop.some(c => c !== 0)) {\n maskCtx.save();\n maskCtx.globalAlpha = 1;\n maskCtx.setTransform(1, 0, 0, 1, 0, 0);\n const clip = new Path2D();\n clip.rect(maskX, maskY, width, height);\n maskCtx.clip(clip);\n maskCtx.globalCompositeOperation = \"destination-atop\";\n maskCtx.fillStyle = Util.makeHexColor(...backdrop);\n maskCtx.fillRect(maskX, maskY, width, height);\n maskCtx.restore();\n }\n }\n\n layerCtx.save();\n layerCtx.globalAlpha = 1;\n layerCtx.setTransform(1, 0, 0, 1, 0, 0);\n\n if (subtype === \"Alpha\" && transferMap) {\n layerCtx.filter = this.filterFactory.addAlphaFilter(transferMap);\n } else if (subtype === \"Luminosity\") {\n layerCtx.filter = this.filterFactory.addLuminosityFilter(transferMap);\n }\n\n const clip = new Path2D();\n clip.rect(layerOffsetX, layerOffsetY, width, height);\n layerCtx.clip(clip);\n layerCtx.globalCompositeOperation = \"destination-in\";\n layerCtx.drawImage(\n maskCanvas,\n maskX,\n maskY,\n width,\n height,\n layerOffsetX,\n layerOffsetY,\n width,\n height\n );\n layerCtx.restore();\n }\n\n save() {\n if (this.inSMaskMode) {\n // SMask mode may be turned on/off causing us to lose graphics state.\n // Copy the temporary canvas state to the main(suspended) canvas to keep\n // it in sync.\n copyCtxState(this.ctx, this.suspendedCtx);\n // Don't bother calling save on the temporary canvas since state is not\n // saved there.\n this.suspendedCtx.save();\n } else {\n this.ctx.save();\n }\n const old = this.current;\n this.stateStack.push(old);\n this.current = old.clone();\n }\n\n restore() {\n if (this.stateStack.length === 0 && this.inSMaskMode) {\n this.endSMaskMode();\n }\n if (this.stateStack.length !== 0) {\n this.current = this.stateStack.pop();\n if (this.inSMaskMode) {\n // Graphics state is stored on the main(suspended) canvas. Restore its\n // state then copy it over to the temporary canvas.\n this.suspendedCtx.restore();\n copyCtxState(this.suspendedCtx, this.ctx);\n } else {\n this.ctx.restore();\n }\n this.checkSMaskState();\n\n // Ensure that the clipping path is reset (fixes issue6413.pdf).\n this.pendingClip = null;\n\n this._cachedScaleForStroking[0] = -1;\n this._cachedGetSinglePixelWidth = null;\n }\n }\n\n transform(a, b, c, d, e, f) {\n this.ctx.transform(a, b, c, d, e, f);\n\n this._cachedScaleForStroking[0] = -1;\n this._cachedGetSinglePixelWidth = null;\n }\n\n // Path\n constructPath(ops, args, minMax) {\n const ctx = this.ctx;\n const current = this.current;\n let x = current.x,\n y = current.y;\n let startX, startY;\n const currentTransform = getCurrentTransform(ctx);\n\n // Most of the time the current transform is a scaling matrix\n // so we don't need to transform points before computing min/max:\n // we can compute min/max first and then smartly \"apply\" the\n // transform (see Util.scaleMinMax).\n // For rectangle, moveTo and lineTo, min/max are computed in the\n // worker (see evaluator.js).\n const isScalingMatrix =\n (currentTransform[0] === 0 && currentTransform[3] === 0) ||\n (currentTransform[1] === 0 && currentTransform[2] === 0);\n const minMaxForBezier = isScalingMatrix ? minMax.slice(0) : null;\n\n for (let i = 0, j = 0, ii = ops.length; i < ii; i++) {\n switch (ops[i] | 0) {\n case OPS.rectangle:\n x = args[j++];\n y = args[j++];\n const width = args[j++];\n const height = args[j++];\n\n const xw = x + width;\n const yh = y + height;\n ctx.moveTo(x, y);\n if (width === 0 || height === 0) {\n ctx.lineTo(xw, yh);\n } else {\n ctx.lineTo(xw, y);\n ctx.lineTo(xw, yh);\n ctx.lineTo(x, yh);\n }\n if (!isScalingMatrix) {\n current.updateRectMinMax(currentTransform, [x, y, xw, yh]);\n }\n ctx.closePath();\n break;\n case OPS.moveTo:\n x = args[j++];\n y = args[j++];\n ctx.moveTo(x, y);\n if (!isScalingMatrix) {\n current.updatePathMinMax(currentTransform, x, y);\n }\n break;\n case OPS.lineTo:\n x = args[j++];\n y = args[j++];\n ctx.lineTo(x, y);\n if (!isScalingMatrix) {\n current.updatePathMinMax(currentTransform, x, y);\n }\n break;\n case OPS.curveTo:\n startX = x;\n startY = y;\n x = args[j + 4];\n y = args[j + 5];\n ctx.bezierCurveTo(\n args[j],\n args[j + 1],\n args[j + 2],\n args[j + 3],\n x,\n y\n );\n current.updateCurvePathMinMax(\n currentTransform,\n startX,\n startY,\n args[j],\n args[j + 1],\n args[j + 2],\n args[j + 3],\n x,\n y,\n minMaxForBezier\n );\n j += 6;\n break;\n case OPS.curveTo2:\n startX = x;\n startY = y;\n ctx.bezierCurveTo(\n x,\n y,\n args[j],\n args[j + 1],\n args[j + 2],\n args[j + 3]\n );\n current.updateCurvePathMinMax(\n currentTransform,\n startX,\n startY,\n x,\n y,\n args[j],\n args[j + 1],\n args[j + 2],\n args[j + 3],\n minMaxForBezier\n );\n x = args[j + 2];\n y = args[j + 3];\n j += 4;\n break;\n case OPS.curveTo3:\n startX = x;\n startY = y;\n x = args[j + 2];\n y = args[j + 3];\n ctx.bezierCurveTo(args[j], args[j + 1], x, y, x, y);\n current.updateCurvePathMinMax(\n currentTransform,\n startX,\n startY,\n args[j],\n args[j + 1],\n x,\n y,\n x,\n y,\n minMaxForBezier\n );\n j += 4;\n break;\n case OPS.closePath:\n ctx.closePath();\n break;\n }\n }\n\n if (isScalingMatrix) {\n current.updateScalingPathMinMax(currentTransform, minMaxForBezier);\n }\n\n current.setCurrentPoint(x, y);\n }\n\n closePath() {\n this.ctx.closePath();\n }\n\n stroke(consumePath = true) {\n const ctx = this.ctx;\n const strokeColor = this.current.strokeColor;\n // For stroke we want to temporarily change the global alpha to the\n // stroking alpha.\n ctx.globalAlpha = this.current.strokeAlpha;\n if (this.contentVisible) {\n if (typeof strokeColor === \"object\" && strokeColor?.getPattern) {\n ctx.save();\n ctx.strokeStyle = strokeColor.getPattern(\n ctx,\n this,\n getCurrentTransformInverse(ctx),\n PathType.STROKE\n );\n this.rescaleAndStroke(/* saveRestore */ false);\n ctx.restore();\n } else {\n this.rescaleAndStroke(/* saveRestore */ true);\n }\n }\n if (consumePath) {\n this.consumePath(this.current.getClippedPathBoundingBox());\n }\n // Restore the global alpha to the fill alpha\n ctx.globalAlpha = this.current.fillAlpha;\n }\n\n closeStroke() {\n this.closePath();\n this.stroke();\n }\n\n fill(consumePath = true) {\n const ctx = this.ctx;\n const fillColor = this.current.fillColor;\n const isPatternFill = this.current.patternFill;\n let needRestore = false;\n\n if (isPatternFill) {\n ctx.save();\n ctx.fillStyle = fillColor.getPattern(\n ctx,\n this,\n getCurrentTransformInverse(ctx),\n PathType.FILL\n );\n needRestore = true;\n }\n\n const intersect = this.current.getClippedPathBoundingBox();\n if (this.contentVisible && intersect !== null) {\n if (this.pendingEOFill) {\n ctx.fill(\"evenodd\");\n this.pendingEOFill = false;\n } else {\n ctx.fill();\n }\n }\n\n if (needRestore) {\n ctx.restore();\n }\n if (consumePath) {\n this.consumePath(intersect);\n }\n }\n\n eoFill() {\n this.pendingEOFill = true;\n this.fill();\n }\n\n fillStroke() {\n this.fill(false);\n this.stroke(false);\n\n this.consumePath();\n }\n\n eoFillStroke() {\n this.pendingEOFill = true;\n this.fillStroke();\n }\n\n closeFillStroke() {\n this.closePath();\n this.fillStroke();\n }\n\n closeEOFillStroke() {\n this.pendingEOFill = true;\n this.closePath();\n this.fillStroke();\n }\n\n endPath() {\n this.consumePath();\n }\n\n // Clipping\n clip() {\n this.pendingClip = NORMAL_CLIP;\n }\n\n eoClip() {\n this.pendingClip = EO_CLIP;\n }\n\n // Text\n beginText() {\n this.current.textMatrix = IDENTITY_MATRIX;\n this.current.textMatrixScale = 1;\n this.current.x = this.current.lineX = 0;\n this.current.y = this.current.lineY = 0;\n }\n\n endText() {\n const paths = this.pendingTextPaths;\n const ctx = this.ctx;\n if (paths === undefined) {\n ctx.beginPath();\n return;\n }\n\n ctx.save();\n ctx.beginPath();\n for (const path of paths) {\n ctx.setTransform(...path.transform);\n ctx.translate(path.x, path.y);\n path.addToPath(ctx, path.fontSize);\n }\n ctx.restore();\n ctx.clip();\n ctx.beginPath();\n delete this.pendingTextPaths;\n }\n\n setCharSpacing(spacing) {\n this.current.charSpacing = spacing;\n }\n\n setWordSpacing(spacing) {\n this.current.wordSpacing = spacing;\n }\n\n setHScale(scale) {\n this.current.textHScale = scale / 100;\n }\n\n setLeading(leading) {\n this.current.leading = -leading;\n }\n\n setFont(fontRefName, size) {\n const fontObj = this.commonObjs.get(fontRefName);\n const current = this.current;\n\n if (!fontObj) {\n throw new Error(`Can't find font for ${fontRefName}`);\n }\n current.fontMatrix = fontObj.fontMatrix || FONT_IDENTITY_MATRIX;\n\n // A valid matrix needs all main diagonal elements to be non-zero\n // This also ensures we bypass FF bugzilla bug #719844.\n if (current.fontMatrix[0] === 0 || current.fontMatrix[3] === 0) {\n warn(\"Invalid font matrix for font \" + fontRefName);\n }\n\n // The spec for Tf (setFont) says that 'size' specifies the font 'scale',\n // and in some docs this can be negative (inverted x-y axes).\n if (size < 0) {\n size = -size;\n current.fontDirection = -1;\n } else {\n current.fontDirection = 1;\n }\n\n this.current.font = fontObj;\n this.current.fontSize = size;\n\n if (fontObj.isType3Font) {\n return; // we don't need ctx.font for Type3 fonts\n }\n\n const name = fontObj.loadedName || \"sans-serif\";\n const typeface =\n fontObj.systemFontInfo?.css || `\"${name}\", ${fontObj.fallbackName}`;\n\n let bold = \"normal\";\n if (fontObj.black) {\n bold = \"900\";\n } else if (fontObj.bold) {\n bold = \"bold\";\n }\n const italic = fontObj.italic ? \"italic\" : \"normal\";\n\n // Some font backends cannot handle fonts below certain size.\n // Keeping the font at minimal size and using the fontSizeScale to change\n // the current transformation matrix before the fillText/strokeText.\n // See https://bugzilla.mozilla.org/show_bug.cgi?id=726227\n let browserFontSize = size;\n if (size < MIN_FONT_SIZE) {\n browserFontSize = MIN_FONT_SIZE;\n } else if (size > MAX_FONT_SIZE) {\n browserFontSize = MAX_FONT_SIZE;\n }\n this.current.fontSizeScale = size / browserFontSize;\n\n this.ctx.font = `${italic} ${bold} ${browserFontSize}px ${typeface}`;\n }\n\n setTextRenderingMode(mode) {\n this.current.textRenderingMode = mode;\n }\n\n setTextRise(rise) {\n this.current.textRise = rise;\n }\n\n moveText(x, y) {\n this.current.x = this.current.lineX += x;\n this.current.y = this.current.lineY += y;\n }\n\n setLeadingMoveText(x, y) {\n this.setLeading(-y);\n this.moveText(x, y);\n }\n\n setTextMatrix(a, b, c, d, e, f) {\n this.current.textMatrix = [a, b, c, d, e, f];\n this.current.textMatrixScale = Math.hypot(a, b);\n\n this.current.x = this.current.lineX = 0;\n this.current.y = this.current.lineY = 0;\n }\n\n nextLine() {\n this.moveText(0, this.current.leading);\n }\n\n paintChar(character, x, y, patternTransform) {\n const ctx = this.ctx;\n const current = this.current;\n const font = current.font;\n const textRenderingMode = current.textRenderingMode;\n const fontSize = current.fontSize / current.fontSizeScale;\n const fillStrokeMode =\n textRenderingMode & TextRenderingMode.FILL_STROKE_MASK;\n const isAddToPathSet = !!(\n textRenderingMode & TextRenderingMode.ADD_TO_PATH_FLAG\n );\n const patternFill = current.patternFill && !font.missingFile;\n\n let addToPath;\n if (font.disableFontFace || isAddToPathSet || patternFill) {\n addToPath = font.getPathGenerator(this.commonObjs, character);\n }\n\n if (font.disableFontFace || patternFill) {\n ctx.save();\n ctx.translate(x, y);\n ctx.beginPath();\n addToPath(ctx, fontSize);\n if (patternTransform) {\n ctx.setTransform(...patternTransform);\n }\n if (\n fillStrokeMode === TextRenderingMode.FILL ||\n fillStrokeMode === TextRenderingMode.FILL_STROKE\n ) {\n ctx.fill();\n }\n if (\n fillStrokeMode === TextRenderingMode.STROKE ||\n fillStrokeMode === TextRenderingMode.FILL_STROKE\n ) {\n ctx.stroke();\n }\n ctx.restore();\n } else {\n if (\n fillStrokeMode === TextRenderingMode.FILL ||\n fillStrokeMode === TextRenderingMode.FILL_STROKE\n ) {\n ctx.fillText(character, x, y);\n }\n if (\n fillStrokeMode === TextRenderingMode.STROKE ||\n fillStrokeMode === TextRenderingMode.FILL_STROKE\n ) {\n ctx.strokeText(character, x, y);\n }\n }\n\n if (isAddToPathSet) {\n const paths = (this.pendingTextPaths ||= []);\n paths.push({\n transform: getCurrentTransform(ctx),\n x,\n y,\n fontSize,\n addToPath,\n });\n }\n }\n\n get isFontSubpixelAAEnabled() {\n // Checks if anti-aliasing is enabled when scaled text is painted.\n // On Windows GDI scaled fonts looks bad.\n const { context: ctx } = this.cachedCanvases.getCanvas(\n \"isFontSubpixelAAEnabled\",\n 10,\n 10\n );\n ctx.scale(1.5, 1);\n ctx.fillText(\"I\", 0, 10);\n const data = ctx.getImageData(0, 0, 10, 10).data;\n let enabled = false;\n for (let i = 3; i < data.length; i += 4) {\n if (data[i] > 0 && data[i] < 255) {\n enabled = true;\n break;\n }\n }\n return shadow(this, \"isFontSubpixelAAEnabled\", enabled);\n }\n\n showText(glyphs) {\n const current = this.current;\n const font = current.font;\n if (font.isType3Font) {\n return this.showType3Text(glyphs);\n }\n\n const fontSize = current.fontSize;\n if (fontSize === 0) {\n return undefined;\n }\n\n const ctx = this.ctx;\n const fontSizeScale = current.fontSizeScale;\n const charSpacing = current.charSpacing;\n const wordSpacing = current.wordSpacing;\n const fontDirection = current.fontDirection;\n const textHScale = current.textHScale * fontDirection;\n const glyphsLength = glyphs.length;\n const vertical = font.vertical;\n const spacingDir = vertical ? 1 : -1;\n const defaultVMetrics = font.defaultVMetrics;\n const widthAdvanceScale = fontSize * current.fontMatrix[0];\n\n const simpleFillText =\n current.textRenderingMode === TextRenderingMode.FILL &&\n !font.disableFontFace &&\n !current.patternFill;\n\n ctx.save();\n ctx.transform(...current.textMatrix);\n ctx.translate(current.x, current.y + current.textRise);\n\n if (fontDirection > 0) {\n ctx.scale(textHScale, -1);\n } else {\n ctx.scale(textHScale, 1);\n }\n\n let patternTransform;\n if (current.patternFill) {\n ctx.save();\n const pattern = current.fillColor.getPattern(\n ctx,\n this,\n getCurrentTransformInverse(ctx),\n PathType.FILL\n );\n patternTransform = getCurrentTransform(ctx);\n ctx.restore();\n ctx.fillStyle = pattern;\n }\n\n let lineWidth = current.lineWidth;\n const scale = current.textMatrixScale;\n if (scale === 0 || lineWidth === 0) {\n const fillStrokeMode =\n current.textRenderingMode & TextRenderingMode.FILL_STROKE_MASK;\n if (\n fillStrokeMode === TextRenderingMode.STROKE ||\n fillStrokeMode === TextRenderingMode.FILL_STROKE\n ) {\n lineWidth = this.getSinglePixelWidth();\n }\n } else {\n lineWidth /= scale;\n }\n\n if (fontSizeScale !== 1.0) {\n ctx.scale(fontSizeScale, fontSizeScale);\n lineWidth /= fontSizeScale;\n }\n\n ctx.lineWidth = lineWidth;\n\n if (font.isInvalidPDFjsFont) {\n const chars = [];\n let width = 0;\n for (const glyph of glyphs) {\n chars.push(glyph.unicode);\n width += glyph.width;\n }\n ctx.fillText(chars.join(\"\"), 0, 0);\n current.x += width * widthAdvanceScale * textHScale;\n ctx.restore();\n this.compose();\n\n return undefined;\n }\n\n let x = 0,\n i;\n for (i = 0; i < glyphsLength; ++i) {\n const glyph = glyphs[i];\n if (typeof glyph === \"number\") {\n x += (spacingDir * glyph * fontSize) / 1000;\n continue;\n }\n\n let restoreNeeded = false;\n const spacing = (glyph.isSpace ? wordSpacing : 0) + charSpacing;\n const character = glyph.fontChar;\n const accent = glyph.accent;\n let scaledX, scaledY;\n let width = glyph.width;\n if (vertical) {\n const vmetric = glyph.vmetric || defaultVMetrics;\n const vx =\n -(glyph.vmetric ? vmetric[1] : width * 0.5) * widthAdvanceScale;\n const vy = vmetric[2] * widthAdvanceScale;\n\n width = vmetric ? -vmetric[0] : width;\n scaledX = vx / fontSizeScale;\n scaledY = (x + vy) / fontSizeScale;\n } else {\n scaledX = x / fontSizeScale;\n scaledY = 0;\n }\n\n if (font.remeasure && width > 0) {\n // Some standard fonts may not have the exact width: rescale per\n // character if measured width is greater than expected glyph width\n // and subpixel-aa is enabled, otherwise just center the glyph.\n const measuredWidth =\n ((ctx.measureText(character).width * 1000) / fontSize) *\n fontSizeScale;\n if (width < measuredWidth && this.isFontSubpixelAAEnabled) {\n const characterScaleX = width / measuredWidth;\n restoreNeeded = true;\n ctx.save();\n ctx.scale(characterScaleX, 1);\n scaledX /= characterScaleX;\n } else if (width !== measuredWidth) {\n scaledX +=\n (((width - measuredWidth) / 2000) * fontSize) / fontSizeScale;\n }\n }\n\n // Only attempt to draw the glyph if it is actually in the embedded font\n // file or if there isn't a font file so the fallback font is shown.\n if (this.contentVisible && (glyph.isInFont || font.missingFile)) {\n if (simpleFillText && !accent) {\n // common case\n ctx.fillText(character, scaledX, scaledY);\n } else {\n this.paintChar(character, scaledX, scaledY, patternTransform);\n if (accent) {\n const scaledAccentX =\n scaledX + (fontSize * accent.offset.x) / fontSizeScale;\n const scaledAccentY =\n scaledY - (fontSize * accent.offset.y) / fontSizeScale;\n this.paintChar(\n accent.fontChar,\n scaledAccentX,\n scaledAccentY,\n patternTransform\n );\n }\n }\n }\n\n const charWidth = vertical\n ? width * widthAdvanceScale - spacing * fontDirection\n : width * widthAdvanceScale + spacing * fontDirection;\n x += charWidth;\n\n if (restoreNeeded) {\n ctx.restore();\n }\n }\n if (vertical) {\n current.y -= x;\n } else {\n current.x += x * textHScale;\n }\n ctx.restore();\n this.compose();\n\n return undefined;\n }\n\n showType3Text(glyphs) {\n // Type3 fonts - each glyph is a \"mini-PDF\"\n const ctx = this.ctx;\n const current = this.current;\n const font = current.font;\n const fontSize = current.fontSize;\n const fontDirection = current.fontDirection;\n const spacingDir = font.vertical ? 1 : -1;\n const charSpacing = current.charSpacing;\n const wordSpacing = current.wordSpacing;\n const textHScale = current.textHScale * fontDirection;\n const fontMatrix = current.fontMatrix || FONT_IDENTITY_MATRIX;\n const glyphsLength = glyphs.length;\n const isTextInvisible =\n current.textRenderingMode === TextRenderingMode.INVISIBLE;\n let i, glyph, width, spacingLength;\n\n if (isTextInvisible || fontSize === 0) {\n return;\n }\n this._cachedScaleForStroking[0] = -1;\n this._cachedGetSinglePixelWidth = null;\n\n ctx.save();\n ctx.transform(...current.textMatrix);\n ctx.translate(current.x, current.y);\n\n ctx.scale(textHScale, fontDirection);\n\n for (i = 0; i < glyphsLength; ++i) {\n glyph = glyphs[i];\n if (typeof glyph === \"number\") {\n spacingLength = (spacingDir * glyph * fontSize) / 1000;\n this.ctx.translate(spacingLength, 0);\n current.x += spacingLength * textHScale;\n continue;\n }\n\n const spacing = (glyph.isSpace ? wordSpacing : 0) + charSpacing;\n const operatorList = font.charProcOperatorList[glyph.operatorListId];\n if (!operatorList) {\n warn(`Type3 character \"${glyph.operatorListId}\" is not available.`);\n continue;\n }\n if (this.contentVisible) {\n this.processingType3 = glyph;\n this.save();\n ctx.scale(fontSize, fontSize);\n ctx.transform(...fontMatrix);\n this.executeOperatorList(operatorList);\n this.restore();\n }\n\n const transformed = Util.applyTransform([glyph.width, 0], fontMatrix);\n width = transformed[0] * fontSize + spacing;\n\n ctx.translate(width, 0);\n current.x += width * textHScale;\n }\n ctx.restore();\n this.processingType3 = null;\n }\n\n // Type3 fonts\n setCharWidth(xWidth, yWidth) {\n // We can safely ignore this since the width should be the same\n // as the width in the Widths array.\n }\n\n setCharWidthAndBounds(xWidth, yWidth, llx, lly, urx, ury) {\n this.ctx.rect(llx, lly, urx - llx, ury - lly);\n this.ctx.clip();\n this.endPath();\n }\n\n // Color\n getColorN_Pattern(IR) {\n let pattern;\n if (IR[0] === \"TilingPattern\") {\n const color = IR[1];\n const baseTransform = this.baseTransform || getCurrentTransform(this.ctx);\n const canvasGraphicsFactory = {\n createCanvasGraphics: ctx =>\n new CanvasGraphics(\n ctx,\n this.commonObjs,\n this.objs,\n this.canvasFactory,\n this.filterFactory,\n {\n optionalContentConfig: this.optionalContentConfig,\n markedContentStack: this.markedContentStack,\n }\n ),\n };\n pattern = new TilingPattern(\n IR,\n color,\n this.ctx,\n canvasGraphicsFactory,\n baseTransform\n );\n } else {\n pattern = this._getPattern(IR[1], IR[2]);\n }\n return pattern;\n }\n\n setStrokeColorN() {\n this.current.strokeColor = this.getColorN_Pattern(arguments);\n }\n\n setFillColorN() {\n this.current.fillColor = this.getColorN_Pattern(arguments);\n this.current.patternFill = true;\n }\n\n setStrokeRGBColor(r, g, b) {\n const color = Util.makeHexColor(r, g, b);\n this.ctx.strokeStyle = color;\n this.current.strokeColor = color;\n }\n\n setFillRGBColor(r, g, b) {\n const color = Util.makeHexColor(r, g, b);\n this.ctx.fillStyle = color;\n this.current.fillColor = color;\n this.current.patternFill = false;\n }\n\n _getPattern(objId, matrix = null) {\n let pattern;\n if (this.cachedPatterns.has(objId)) {\n pattern = this.cachedPatterns.get(objId);\n } else {\n pattern = getShadingPattern(this.getObject(objId));\n this.cachedPatterns.set(objId, pattern);\n }\n if (matrix) {\n pattern.matrix = matrix;\n }\n return pattern;\n }\n\n shadingFill(objId) {\n if (!this.contentVisible) {\n return;\n }\n const ctx = this.ctx;\n\n this.save();\n const pattern = this._getPattern(objId);\n ctx.fillStyle = pattern.getPattern(\n ctx,\n this,\n getCurrentTransformInverse(ctx),\n PathType.SHADING\n );\n\n const inv = getCurrentTransformInverse(ctx);\n if (inv) {\n const { width, height } = ctx.canvas;\n const [x0, y0, x1, y1] = Util.getAxialAlignedBoundingBox(\n [0, 0, width, height],\n inv\n );\n\n this.ctx.fillRect(x0, y0, x1 - x0, y1 - y0);\n } else {\n // HACK to draw the gradient onto an infinite rectangle.\n // PDF gradients are drawn across the entire image while\n // Canvas only allows gradients to be drawn in a rectangle\n // The following bug should allow us to remove this.\n // https://bugzilla.mozilla.org/show_bug.cgi?id=664884\n\n this.ctx.fillRect(-1e10, -1e10, 2e10, 2e10);\n }\n\n this.compose(this.current.getClippedPathBoundingBox());\n this.restore();\n }\n\n // Images\n beginInlineImage() {\n unreachable(\"Should not call beginInlineImage\");\n }\n\n beginImageData() {\n unreachable(\"Should not call beginImageData\");\n }\n\n paintFormXObjectBegin(matrix, bbox) {\n if (!this.contentVisible) {\n return;\n }\n this.save();\n this.baseTransformStack.push(this.baseTransform);\n\n if (matrix) {\n this.transform(...matrix);\n }\n this.baseTransform = getCurrentTransform(this.ctx);\n\n if (bbox) {\n const width = bbox[2] - bbox[0];\n const height = bbox[3] - bbox[1];\n this.ctx.rect(bbox[0], bbox[1], width, height);\n this.current.updateRectMinMax(getCurrentTransform(this.ctx), bbox);\n this.clip();\n this.endPath();\n }\n }\n\n paintFormXObjectEnd() {\n if (!this.contentVisible) {\n return;\n }\n this.restore();\n this.baseTransform = this.baseTransformStack.pop();\n }\n\n beginGroup(group) {\n if (!this.contentVisible) {\n return;\n }\n\n this.save();\n // If there's an active soft mask we don't want it enabled for the group, so\n // clear it out. The mask and suspended canvas will be restored in endGroup.\n if (this.inSMaskMode) {\n this.endSMaskMode();\n this.current.activeSMask = null;\n }\n\n const currentCtx = this.ctx;\n // TODO non-isolated groups - according to Rik at adobe non-isolated\n // group results aren't usually that different and they even have tools\n // that ignore this setting. Notes from Rik on implementing:\n // - When you encounter an transparency group, create a new canvas with\n // the dimensions of the bbox\n // - copy the content from the previous canvas to the new canvas\n // - draw as usual\n // - remove the backdrop alpha:\n // alphaNew = 1 - (1 - alpha)/(1 - alphaBackdrop) with 'alpha' the alpha\n // value of your transparency group and 'alphaBackdrop' the alpha of the\n // backdrop\n // - remove background color:\n // colorNew = color - alphaNew *colorBackdrop /(1 - alphaNew)\n if (!group.isolated) {\n info(\"TODO: Support non-isolated groups.\");\n }\n\n // TODO knockout - supposedly possible with the clever use of compositing\n // modes.\n if (group.knockout) {\n warn(\"Knockout groups not supported.\");\n }\n\n const currentTransform = getCurrentTransform(currentCtx);\n if (group.matrix) {\n currentCtx.transform(...group.matrix);\n }\n if (!group.bbox) {\n throw new Error(\"Bounding box is required.\");\n }\n\n // Based on the current transform figure out how big the bounding box\n // will actually be.\n let bounds = Util.getAxialAlignedBoundingBox(\n group.bbox,\n getCurrentTransform(currentCtx)\n );\n // Clip the bounding box to the current canvas.\n const canvasBounds = [\n 0,\n 0,\n currentCtx.canvas.width,\n currentCtx.canvas.height,\n ];\n bounds = Util.intersect(bounds, canvasBounds) || [0, 0, 0, 0];\n // Use ceil in case we're between sizes so we don't create canvas that is\n // too small and make the canvas at least 1x1 pixels.\n const offsetX = Math.floor(bounds[0]);\n const offsetY = Math.floor(bounds[1]);\n const drawnWidth = Math.max(Math.ceil(bounds[2]) - offsetX, 1);\n const drawnHeight = Math.max(Math.ceil(bounds[3]) - offsetY, 1);\n\n this.current.startNewPathAndClipBox([0, 0, drawnWidth, drawnHeight]);\n\n let cacheId = \"groupAt\" + this.groupLevel;\n if (group.smask) {\n // Using two cache entries is case if masks are used one after another.\n cacheId += \"_smask_\" + (this.smaskCounter++ % 2);\n }\n const scratchCanvas = this.cachedCanvases.getCanvas(\n cacheId,\n drawnWidth,\n drawnHeight\n );\n const groupCtx = scratchCanvas.context;\n\n // Since we created a new canvas that is just the size of the bounding box\n // we have to translate the group ctx.\n groupCtx.translate(-offsetX, -offsetY);\n groupCtx.transform(...currentTransform);\n\n if (group.smask) {\n // Saving state and cached mask to be used in setGState.\n this.smaskStack.push({\n canvas: scratchCanvas.canvas,\n context: groupCtx,\n offsetX,\n offsetY,\n subtype: group.smask.subtype,\n backdrop: group.smask.backdrop,\n transferMap: group.smask.transferMap || null,\n startTransformInverse: null, // used during suspend operation\n });\n } else {\n // Setup the current ctx so when the group is popped we draw it at the\n // right location.\n currentCtx.setTransform(1, 0, 0, 1, 0, 0);\n currentCtx.translate(offsetX, offsetY);\n currentCtx.save();\n }\n // The transparency group inherits all off the current graphics state\n // except the blend mode, soft mask, and alpha constants.\n copyCtxState(currentCtx, groupCtx);\n this.ctx = groupCtx;\n this.setGState([\n [\"BM\", \"source-over\"],\n [\"ca\", 1],\n [\"CA\", 1],\n ]);\n this.groupStack.push(currentCtx);\n this.groupLevel++;\n }\n\n endGroup(group) {\n if (!this.contentVisible) {\n return;\n }\n this.groupLevel--;\n const groupCtx = this.ctx;\n const ctx = this.groupStack.pop();\n this.ctx = ctx;\n // Turn off image smoothing to avoid sub pixel interpolation which can\n // look kind of blurry for some pdfs.\n this.ctx.imageSmoothingEnabled = false;\n\n if (group.smask) {\n this.tempSMask = this.smaskStack.pop();\n this.restore();\n } else {\n this.ctx.restore();\n const currentMtx = getCurrentTransform(this.ctx);\n this.restore();\n this.ctx.save();\n this.ctx.setTransform(...currentMtx);\n const dirtyBox = Util.getAxialAlignedBoundingBox(\n [0, 0, groupCtx.canvas.width, groupCtx.canvas.height],\n currentMtx\n );\n this.ctx.drawImage(groupCtx.canvas, 0, 0);\n this.ctx.restore();\n this.compose(dirtyBox);\n }\n }\n\n beginAnnotation(id, rect, transform, matrix, hasOwnCanvas) {\n // The annotations are drawn just after the page content.\n // The page content drawing can potentially have set a transform,\n // a clipping path, whatever...\n // So in order to have something clean, we restore the initial state.\n this.#restoreInitialState();\n resetCtxToDefault(this.ctx);\n\n this.ctx.save();\n this.save();\n\n if (this.baseTransform) {\n this.ctx.setTransform(...this.baseTransform);\n }\n\n if (rect) {\n const width = rect[2] - rect[0];\n const height = rect[3] - rect[1];\n\n if (hasOwnCanvas && this.annotationCanvasMap) {\n transform = transform.slice();\n transform[4] -= rect[0];\n transform[5] -= rect[1];\n\n rect = rect.slice();\n rect[0] = rect[1] = 0;\n rect[2] = width;\n rect[3] = height;\n\n const [scaleX, scaleY] = Util.singularValueDecompose2dScale(\n getCurrentTransform(this.ctx)\n );\n const { viewportScale } = this;\n const canvasWidth = Math.ceil(\n width * this.outputScaleX * viewportScale\n );\n const canvasHeight = Math.ceil(\n height * this.outputScaleY * viewportScale\n );\n\n this.annotationCanvas = this.canvasFactory.create(\n canvasWidth,\n canvasHeight\n );\n const { canvas, context } = this.annotationCanvas;\n this.annotationCanvasMap.set(id, canvas);\n this.annotationCanvas.savedCtx = this.ctx;\n this.ctx = context;\n this.ctx.save();\n this.ctx.setTransform(scaleX, 0, 0, -scaleY, 0, height * scaleY);\n\n resetCtxToDefault(this.ctx);\n } else {\n resetCtxToDefault(this.ctx);\n\n this.ctx.rect(rect[0], rect[1], width, height);\n this.ctx.clip();\n this.endPath();\n }\n }\n\n this.current = new CanvasExtraState(\n this.ctx.canvas.width,\n this.ctx.canvas.height\n );\n\n this.transform(...transform);\n this.transform(...matrix);\n }\n\n endAnnotation() {\n if (this.annotationCanvas) {\n this.ctx.restore();\n this.#drawFilter();\n\n this.ctx = this.annotationCanvas.savedCtx;\n delete this.annotationCanvas.savedCtx;\n delete this.annotationCanvas;\n }\n }\n\n paintImageMaskXObject(img) {\n if (!this.contentVisible) {\n return;\n }\n const count = img.count;\n img = this.getObject(img.data, img);\n img.count = count;\n\n const ctx = this.ctx;\n const glyph = this.processingType3;\n\n if (glyph) {\n if (glyph.compiled === undefined) {\n glyph.compiled = compileType3Glyph(img);\n }\n\n if (glyph.compiled) {\n glyph.compiled(ctx);\n return;\n }\n }\n const mask = this._createMaskCanvas(img);\n const maskCanvas = mask.canvas;\n\n ctx.save();\n // The mask is drawn with the transform applied. Reset the current\n // transform to draw to the identity.\n ctx.setTransform(1, 0, 0, 1, 0, 0);\n ctx.drawImage(maskCanvas, mask.offsetX, mask.offsetY);\n ctx.restore();\n this.compose();\n }\n\n paintImageMaskXObjectRepeat(\n img,\n scaleX,\n skewX = 0,\n skewY = 0,\n scaleY,\n positions\n ) {\n if (!this.contentVisible) {\n return;\n }\n\n img = this.getObject(img.data, img);\n\n const ctx = this.ctx;\n ctx.save();\n const currentTransform = getCurrentTransform(ctx);\n ctx.transform(scaleX, skewX, skewY, scaleY, 0, 0);\n const mask = this._createMaskCanvas(img);\n\n ctx.setTransform(\n 1,\n 0,\n 0,\n 1,\n mask.offsetX - currentTransform[4],\n mask.offsetY - currentTransform[5]\n );\n for (let i = 0, ii = positions.length; i < ii; i += 2) {\n const trans = Util.transform(currentTransform, [\n scaleX,\n skewX,\n skewY,\n scaleY,\n positions[i],\n positions[i + 1],\n ]);\n\n const [x, y] = Util.applyTransform([0, 0], trans);\n ctx.drawImage(mask.canvas, x, y);\n }\n ctx.restore();\n this.compose();\n }\n\n paintImageMaskXObjectGroup(images) {\n if (!this.contentVisible) {\n return;\n }\n const ctx = this.ctx;\n\n const fillColor = this.current.fillColor;\n const isPatternFill = this.current.patternFill;\n\n for (const image of images) {\n const { data, width, height, transform } = image;\n\n const maskCanvas = this.cachedCanvases.getCanvas(\n \"maskCanvas\",\n width,\n height\n );\n const maskCtx = maskCanvas.context;\n maskCtx.save();\n\n const img = this.getObject(data, image);\n putBinaryImageMask(maskCtx, img);\n\n maskCtx.globalCompositeOperation = \"source-in\";\n\n maskCtx.fillStyle = isPatternFill\n ? fillColor.getPattern(\n maskCtx,\n this,\n getCurrentTransformInverse(ctx),\n PathType.FILL\n )\n : fillColor;\n maskCtx.fillRect(0, 0, width, height);\n\n maskCtx.restore();\n\n ctx.save();\n ctx.transform(...transform);\n ctx.scale(1, -1);\n drawImageAtIntegerCoords(\n ctx,\n maskCanvas.canvas,\n 0,\n 0,\n width,\n height,\n 0,\n -1,\n 1,\n 1\n );\n ctx.restore();\n }\n this.compose();\n }\n\n paintImageXObject(objId) {\n if (!this.contentVisible) {\n return;\n }\n const imgData = this.getObject(objId);\n if (!imgData) {\n warn(\"Dependent image isn't ready yet\");\n return;\n }\n\n this.paintInlineImageXObject(imgData);\n }\n\n paintImageXObjectRepeat(objId, scaleX, scaleY, positions) {\n if (!this.contentVisible) {\n return;\n }\n const imgData = this.getObject(objId);\n if (!imgData) {\n warn(\"Dependent image isn't ready yet\");\n return;\n }\n\n const width = imgData.width;\n const height = imgData.height;\n const map = [];\n for (let i = 0, ii = positions.length; i < ii; i += 2) {\n map.push({\n transform: [scaleX, 0, 0, scaleY, positions[i], positions[i + 1]],\n x: 0,\n y: 0,\n w: width,\n h: height,\n });\n }\n this.paintInlineImageXObjectGroup(imgData, map);\n }\n\n applyTransferMapsToCanvas(ctx) {\n if (this.current.transferMaps !== \"none\") {\n ctx.filter = this.current.transferMaps;\n ctx.drawImage(ctx.canvas, 0, 0);\n ctx.filter = \"none\";\n }\n return ctx.canvas;\n }\n\n applyTransferMapsToBitmap(imgData) {\n if (this.current.transferMaps === \"none\") {\n return imgData.bitmap;\n }\n const { bitmap, width, height } = imgData;\n const tmpCanvas = this.cachedCanvases.getCanvas(\n \"inlineImage\",\n width,\n height\n );\n const tmpCtx = tmpCanvas.context;\n tmpCtx.filter = this.current.transferMaps;\n tmpCtx.drawImage(bitmap, 0, 0);\n tmpCtx.filter = \"none\";\n\n return tmpCanvas.canvas;\n }\n\n paintInlineImageXObject(imgData) {\n if (!this.contentVisible) {\n return;\n }\n const width = imgData.width;\n const height = imgData.height;\n const ctx = this.ctx;\n\n this.save();\n\n if (\n (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) ||\n !isNodeJS\n ) {\n // The filter, if any, will be applied in applyTransferMapsToBitmap.\n // It must be applied to the image before rescaling else some artifacts\n // could appear.\n // The final restore will reset it to its value.\n const { filter } = ctx;\n if (filter !== \"none\" && filter !== \"\") {\n ctx.filter = \"none\";\n }\n }\n\n // scale the image to the unit square\n ctx.scale(1 / width, -1 / height);\n\n let imgToPaint;\n if (imgData.bitmap) {\n imgToPaint = this.applyTransferMapsToBitmap(imgData);\n } else if (\n (typeof HTMLElement === \"function\" && imgData instanceof HTMLElement) ||\n !imgData.data\n ) {\n // typeof check is needed due to node.js support, see issue #8489\n imgToPaint = imgData;\n } else {\n const tmpCanvas = this.cachedCanvases.getCanvas(\n \"inlineImage\",\n width,\n height\n );\n const tmpCtx = tmpCanvas.context;\n putBinaryImageData(tmpCtx, imgData);\n imgToPaint = this.applyTransferMapsToCanvas(tmpCtx);\n }\n\n const scaled = this._scaleImage(\n imgToPaint,\n getCurrentTransformInverse(ctx)\n );\n ctx.imageSmoothingEnabled = getImageSmoothingEnabled(\n getCurrentTransform(ctx),\n imgData.interpolate\n );\n\n drawImageAtIntegerCoords(\n ctx,\n scaled.img,\n 0,\n 0,\n scaled.paintWidth,\n scaled.paintHeight,\n 0,\n -height,\n width,\n height\n );\n this.compose();\n this.restore();\n }\n\n paintInlineImageXObjectGroup(imgData, map) {\n if (!this.contentVisible) {\n return;\n }\n const ctx = this.ctx;\n let imgToPaint;\n if (imgData.bitmap) {\n imgToPaint = imgData.bitmap;\n } else {\n const w = imgData.width;\n const h = imgData.height;\n\n const tmpCanvas = this.cachedCanvases.getCanvas(\"inlineImage\", w, h);\n const tmpCtx = tmpCanvas.context;\n putBinaryImageData(tmpCtx, imgData);\n imgToPaint = this.applyTransferMapsToCanvas(tmpCtx);\n }\n\n for (const entry of map) {\n ctx.save();\n ctx.transform(...entry.transform);\n ctx.scale(1, -1);\n drawImageAtIntegerCoords(\n ctx,\n imgToPaint,\n entry.x,\n entry.y,\n entry.w,\n entry.h,\n 0,\n -1,\n 1,\n 1\n );\n ctx.restore();\n }\n this.compose();\n }\n\n paintSolidColorImageMask() {\n if (!this.contentVisible) {\n return;\n }\n this.ctx.fillRect(0, 0, 1, 1);\n this.compose();\n }\n\n // Marked content\n\n markPoint(tag) {\n // TODO Marked content.\n }\n\n markPointProps(tag, properties) {\n // TODO Marked content.\n }\n\n beginMarkedContent(tag) {\n this.markedContentStack.push({\n visible: true,\n });\n }\n\n beginMarkedContentProps(tag, properties) {\n if (tag === \"OC\") {\n this.markedContentStack.push({\n visible: this.optionalContentConfig.isVisible(properties),\n });\n } else {\n this.markedContentStack.push({\n visible: true,\n });\n }\n this.contentVisible = this.isContentVisible();\n }\n\n endMarkedContent() {\n this.markedContentStack.pop();\n this.contentVisible = this.isContentVisible();\n }\n\n // Compatibility\n\n beginCompat() {\n // TODO ignore undefined operators (should we do that anyway?)\n }\n\n endCompat() {\n // TODO stop ignoring undefined operators\n }\n\n // Helper functions\n\n consumePath(clipBox) {\n const isEmpty = this.current.isEmptyClip();\n if (this.pendingClip) {\n this.current.updateClipFromPath();\n }\n if (!this.pendingClip) {\n this.compose(clipBox);\n }\n const ctx = this.ctx;\n if (this.pendingClip) {\n if (!isEmpty) {\n if (this.pendingClip === EO_CLIP) {\n ctx.clip(\"evenodd\");\n } else {\n ctx.clip();\n }\n }\n this.pendingClip = null;\n }\n this.current.startNewPathAndClipBox(this.current.clipBox);\n ctx.beginPath();\n }\n\n getSinglePixelWidth() {\n if (!this._cachedGetSinglePixelWidth) {\n const m = getCurrentTransform(this.ctx);\n if (m[1] === 0 && m[2] === 0) {\n // Fast path\n this._cachedGetSinglePixelWidth =\n 1 / Math.min(Math.abs(m[0]), Math.abs(m[3]));\n } else {\n const absDet = Math.abs(m[0] * m[3] - m[2] * m[1]);\n const normX = Math.hypot(m[0], m[2]);\n const normY = Math.hypot(m[1], m[3]);\n this._cachedGetSinglePixelWidth = Math.max(normX, normY) / absDet;\n }\n }\n return this._cachedGetSinglePixelWidth;\n }\n\n getScaleForStroking() {\n // A pixel has thicknessX = thicknessY = 1;\n // A transformed pixel is a parallelogram and the thicknesses\n // corresponds to the heights.\n // The goal of this function is to rescale before setting the\n // lineWidth in order to have both thicknesses greater or equal\n // to 1 after transform.\n if (this._cachedScaleForStroking[0] === -1) {\n const { lineWidth } = this.current;\n const { a, b, c, d } = this.ctx.getTransform();\n let scaleX, scaleY;\n\n if (b === 0 && c === 0) {\n // Fast path\n const normX = Math.abs(a);\n const normY = Math.abs(d);\n if (normX === normY) {\n if (lineWidth === 0) {\n scaleX = scaleY = 1 / normX;\n } else {\n const scaledLineWidth = normX * lineWidth;\n scaleX = scaleY = scaledLineWidth < 1 ? 1 / scaledLineWidth : 1;\n }\n } else if (lineWidth === 0) {\n scaleX = 1 / normX;\n scaleY = 1 / normY;\n } else {\n const scaledXLineWidth = normX * lineWidth;\n const scaledYLineWidth = normY * lineWidth;\n scaleX = scaledXLineWidth < 1 ? 1 / scaledXLineWidth : 1;\n scaleY = scaledYLineWidth < 1 ? 1 / scaledYLineWidth : 1;\n }\n } else {\n // A pixel (base (x, y)) is transformed by M into a parallelogram:\n // - its area is |det(M)|;\n // - heightY (orthogonal to Mx) has a length: |det(M)| / norm(Mx);\n // - heightX (orthogonal to My) has a length: |det(M)| / norm(My).\n // heightX and heightY are the thicknesses of the transformed pixel\n // and they must be both greater or equal to 1.\n const absDet = Math.abs(a * d - b * c);\n const normX = Math.hypot(a, b);\n const normY = Math.hypot(c, d);\n if (lineWidth === 0) {\n scaleX = normY / absDet;\n scaleY = normX / absDet;\n } else {\n const baseArea = lineWidth * absDet;\n scaleX = normY > baseArea ? normY / baseArea : 1;\n scaleY = normX > baseArea ? normX / baseArea : 1;\n }\n }\n this._cachedScaleForStroking[0] = scaleX;\n this._cachedScaleForStroking[1] = scaleY;\n }\n return this._cachedScaleForStroking;\n }\n\n // Rescale before stroking in order to have a final lineWidth\n // with both thicknesses greater or equal to 1.\n rescaleAndStroke(saveRestore) {\n const { ctx } = this;\n const { lineWidth } = this.current;\n const [scaleX, scaleY] = this.getScaleForStroking();\n\n ctx.lineWidth = lineWidth || 1;\n\n if (scaleX === 1 && scaleY === 1) {\n ctx.stroke();\n return;\n }\n\n const dashes = ctx.getLineDash();\n if (saveRestore) {\n ctx.save();\n }\n\n ctx.scale(scaleX, scaleY);\n\n // How the dashed line is rendered depends on the current transform...\n // so we added a rescale to handle too thin lines and consequently\n // the way the line is dashed will be modified.\n // If scaleX === scaleY, the dashed lines will be rendered correctly\n // else we'll have some bugs (but only with too thin lines).\n // Here we take the max... why not taking the min... or something else.\n // Anyway, as said it's buggy when scaleX !== scaleY.\n if (dashes.length > 0) {\n const scale = Math.max(scaleX, scaleY);\n ctx.setLineDash(dashes.map(x => x / scale));\n ctx.lineDashOffset /= scale;\n }\n\n ctx.stroke();\n\n if (saveRestore) {\n ctx.restore();\n }\n }\n\n isContentVisible() {\n for (let i = this.markedContentStack.length - 1; i >= 0; i--) {\n if (!this.markedContentStack[i].visible) {\n return false;\n }\n }\n return true;\n }\n}\n\nfor (const op in OPS) {\n if (CanvasGraphics.prototype[op] !== undefined) {\n CanvasGraphics.prototype[OPS[op]] = CanvasGraphics.prototype[op];\n }\n}\n\nexport { CanvasGraphics };\n","/* Copyright 2018 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nclass GlobalWorkerOptions {\n static #port = null;\n\n static #src = \"\";\n\n /**\n * @type {Worker | null}\n */\n static get workerPort() {\n return this.#port;\n }\n\n /**\n * @param {Worker | null} workerPort - Defines global port for worker process.\n * Overrides the `workerSrc` option.\n */\n static set workerPort(val) {\n if (\n !(typeof Worker !== \"undefined\" && val instanceof Worker) &&\n val !== null\n ) {\n throw new Error(\"Invalid `workerPort` type.\");\n }\n this.#port = val;\n }\n\n /**\n * @type {string}\n */\n static get workerSrc() {\n return this.#src;\n }\n\n /**\n * @param {string} workerSrc - A string containing the path and filename of\n * the worker file.\n *\n * NOTE: The `workerSrc` option should always be set, in order to prevent\n * any issues when using the PDF.js library.\n */\n static set workerSrc(val) {\n if (typeof val !== \"string\") {\n throw new Error(\"Invalid `workerSrc` type.\");\n }\n this.#src = val;\n }\n}\n\nexport { GlobalWorkerOptions };\n","/* Copyright 2018 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n AbortException,\n assert,\n MissingPDFException,\n PasswordException,\n UnexpectedResponseException,\n UnknownErrorException,\n unreachable,\n} from \"./util.js\";\n\nconst CallbackKind = {\n UNKNOWN: 0,\n DATA: 1,\n ERROR: 2,\n};\n\nconst StreamKind = {\n UNKNOWN: 0,\n CANCEL: 1,\n CANCEL_COMPLETE: 2,\n CLOSE: 3,\n ENQUEUE: 4,\n ERROR: 5,\n PULL: 6,\n PULL_COMPLETE: 7,\n START_COMPLETE: 8,\n};\n\nfunction wrapReason(reason) {\n if (\n !(\n reason instanceof Error ||\n (typeof reason === \"object\" && reason !== null)\n )\n ) {\n unreachable(\n 'wrapReason: Expected \"reason\" to be a (possibly cloned) Error.'\n );\n }\n switch (reason.name) {\n case \"AbortException\":\n return new AbortException(reason.message);\n case \"MissingPDFException\":\n return new MissingPDFException(reason.message);\n case \"PasswordException\":\n return new PasswordException(reason.message, reason.code);\n case \"UnexpectedResponseException\":\n return new UnexpectedResponseException(reason.message, reason.status);\n case \"UnknownErrorException\":\n return new UnknownErrorException(reason.message, reason.details);\n default:\n return new UnknownErrorException(reason.message, reason.toString());\n }\n}\n\nclass MessageHandler {\n constructor(sourceName, targetName, comObj) {\n this.sourceName = sourceName;\n this.targetName = targetName;\n this.comObj = comObj;\n this.callbackId = 1;\n this.streamId = 1;\n this.streamSinks = Object.create(null);\n this.streamControllers = Object.create(null);\n this.callbackCapabilities = Object.create(null);\n this.actionHandler = Object.create(null);\n\n this._onComObjOnMessage = event => {\n const data = event.data;\n if (data.targetName !== this.sourceName) {\n return;\n }\n if (data.stream) {\n this.#processStreamMessage(data);\n return;\n }\n if (data.callback) {\n const callbackId = data.callbackId;\n const capability = this.callbackCapabilities[callbackId];\n if (!capability) {\n throw new Error(`Cannot resolve callback ${callbackId}`);\n }\n delete this.callbackCapabilities[callbackId];\n\n if (data.callback === CallbackKind.DATA) {\n capability.resolve(data.data);\n } else if (data.callback === CallbackKind.ERROR) {\n capability.reject(wrapReason(data.reason));\n } else {\n throw new Error(\"Unexpected callback case\");\n }\n return;\n }\n const action = this.actionHandler[data.action];\n if (!action) {\n throw new Error(`Unknown action from worker: ${data.action}`);\n }\n if (data.callbackId) {\n const cbSourceName = this.sourceName;\n const cbTargetName = data.sourceName;\n\n new Promise(function (resolve) {\n resolve(action(data.data));\n }).then(\n function (result) {\n comObj.postMessage({\n sourceName: cbSourceName,\n targetName: cbTargetName,\n callback: CallbackKind.DATA,\n callbackId: data.callbackId,\n data: result,\n });\n },\n function (reason) {\n comObj.postMessage({\n sourceName: cbSourceName,\n targetName: cbTargetName,\n callback: CallbackKind.ERROR,\n callbackId: data.callbackId,\n reason: wrapReason(reason),\n });\n }\n );\n return;\n }\n if (data.streamId) {\n this.#createStreamSink(data);\n return;\n }\n action(data.data);\n };\n comObj.addEventListener(\"message\", this._onComObjOnMessage);\n }\n\n on(actionName, handler) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n typeof handler === \"function\",\n 'MessageHandler.on: Expected \"handler\" to be a function.'\n );\n }\n const ah = this.actionHandler;\n if (ah[actionName]) {\n throw new Error(`There is already an actionName called \"${actionName}\"`);\n }\n ah[actionName] = handler;\n }\n\n /**\n * Sends a message to the comObj to invoke the action with the supplied data.\n * @param {string} actionName - Action to call.\n * @param {JSON} data - JSON data to send.\n * @param {Array} [transfers] - List of transfers/ArrayBuffers.\n */\n send(actionName, data, transfers) {\n this.comObj.postMessage(\n {\n sourceName: this.sourceName,\n targetName: this.targetName,\n action: actionName,\n data,\n },\n transfers\n );\n }\n\n /**\n * Sends a message to the comObj to invoke the action with the supplied data.\n * Expects that the other side will callback with the response.\n * @param {string} actionName - Action to call.\n * @param {JSON} data - JSON data to send.\n * @param {Array} [transfers] - List of transfers/ArrayBuffers.\n * @returns {Promise} Promise to be resolved with response data.\n */\n sendWithPromise(actionName, data, transfers) {\n const callbackId = this.callbackId++;\n const capability = Promise.withResolvers();\n this.callbackCapabilities[callbackId] = capability;\n try {\n this.comObj.postMessage(\n {\n sourceName: this.sourceName,\n targetName: this.targetName,\n action: actionName,\n callbackId,\n data,\n },\n transfers\n );\n } catch (ex) {\n capability.reject(ex);\n }\n return capability.promise;\n }\n\n /**\n * Sends a message to the comObj to invoke the action with the supplied data.\n * Expect that the other side will callback to signal 'start_complete'.\n * @param {string} actionName - Action to call.\n * @param {JSON} data - JSON data to send.\n * @param {Object} queueingStrategy - Strategy to signal backpressure based on\n * internal queue.\n * @param {Array} [transfers] - List of transfers/ArrayBuffers.\n * @returns {ReadableStream} ReadableStream to read data in chunks.\n */\n sendWithStream(actionName, data, queueingStrategy, transfers) {\n const streamId = this.streamId++,\n sourceName = this.sourceName,\n targetName = this.targetName,\n comObj = this.comObj;\n\n return new ReadableStream(\n {\n start: controller => {\n const startCapability = Promise.withResolvers();\n this.streamControllers[streamId] = {\n controller,\n startCall: startCapability,\n pullCall: null,\n cancelCall: null,\n isClosed: false,\n };\n comObj.postMessage(\n {\n sourceName,\n targetName,\n action: actionName,\n streamId,\n data,\n desiredSize: controller.desiredSize,\n },\n transfers\n );\n // Return Promise for Async process, to signal success/failure.\n return startCapability.promise;\n },\n\n pull: controller => {\n const pullCapability = Promise.withResolvers();\n this.streamControllers[streamId].pullCall = pullCapability;\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.PULL,\n streamId,\n desiredSize: controller.desiredSize,\n });\n // Returning Promise will not call \"pull\"\n // again until current pull is resolved.\n return pullCapability.promise;\n },\n\n cancel: reason => {\n assert(reason instanceof Error, \"cancel must have a valid reason\");\n const cancelCapability = Promise.withResolvers();\n this.streamControllers[streamId].cancelCall = cancelCapability;\n this.streamControllers[streamId].isClosed = true;\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.CANCEL,\n streamId,\n reason: wrapReason(reason),\n });\n // Return Promise to signal success or failure.\n return cancelCapability.promise;\n },\n },\n queueingStrategy\n );\n }\n\n #createStreamSink(data) {\n const streamId = data.streamId,\n sourceName = this.sourceName,\n targetName = data.sourceName,\n comObj = this.comObj;\n const self = this,\n action = this.actionHandler[data.action];\n\n const streamSink = {\n enqueue(chunk, size = 1, transfers) {\n if (this.isCancelled) {\n return;\n }\n const lastDesiredSize = this.desiredSize;\n this.desiredSize -= size;\n // Enqueue decreases the desiredSize property of sink,\n // so when it changes from positive to negative,\n // set ready as unresolved promise.\n if (lastDesiredSize > 0 && this.desiredSize <= 0) {\n this.sinkCapability = Promise.withResolvers();\n this.ready = this.sinkCapability.promise;\n }\n comObj.postMessage(\n {\n sourceName,\n targetName,\n stream: StreamKind.ENQUEUE,\n streamId,\n chunk,\n },\n transfers\n );\n },\n\n close() {\n if (this.isCancelled) {\n return;\n }\n this.isCancelled = true;\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.CLOSE,\n streamId,\n });\n delete self.streamSinks[streamId];\n },\n\n error(reason) {\n assert(reason instanceof Error, \"error must have a valid reason\");\n if (this.isCancelled) {\n return;\n }\n this.isCancelled = true;\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.ERROR,\n streamId,\n reason: wrapReason(reason),\n });\n },\n\n sinkCapability: Promise.withResolvers(),\n onPull: null,\n onCancel: null,\n isCancelled: false,\n desiredSize: data.desiredSize,\n ready: null,\n };\n\n streamSink.sinkCapability.resolve();\n streamSink.ready = streamSink.sinkCapability.promise;\n this.streamSinks[streamId] = streamSink;\n\n new Promise(function (resolve) {\n resolve(action(data.data, streamSink));\n }).then(\n function () {\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.START_COMPLETE,\n streamId,\n success: true,\n });\n },\n function (reason) {\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.START_COMPLETE,\n streamId,\n reason: wrapReason(reason),\n });\n }\n );\n }\n\n #processStreamMessage(data) {\n const streamId = data.streamId,\n sourceName = this.sourceName,\n targetName = data.sourceName,\n comObj = this.comObj;\n const streamController = this.streamControllers[streamId],\n streamSink = this.streamSinks[streamId];\n\n switch (data.stream) {\n case StreamKind.START_COMPLETE:\n if (data.success) {\n streamController.startCall.resolve();\n } else {\n streamController.startCall.reject(wrapReason(data.reason));\n }\n break;\n case StreamKind.PULL_COMPLETE:\n if (data.success) {\n streamController.pullCall.resolve();\n } else {\n streamController.pullCall.reject(wrapReason(data.reason));\n }\n break;\n case StreamKind.PULL:\n // Ignore any pull after close is called.\n if (!streamSink) {\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.PULL_COMPLETE,\n streamId,\n success: true,\n });\n break;\n }\n // Pull increases the desiredSize property of sink, so when it changes\n // from negative to positive, set ready property as resolved promise.\n if (streamSink.desiredSize <= 0 && data.desiredSize > 0) {\n streamSink.sinkCapability.resolve();\n }\n // Reset desiredSize property of sink on every pull.\n streamSink.desiredSize = data.desiredSize;\n\n new Promise(function (resolve) {\n resolve(streamSink.onPull?.());\n }).then(\n function () {\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.PULL_COMPLETE,\n streamId,\n success: true,\n });\n },\n function (reason) {\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.PULL_COMPLETE,\n streamId,\n reason: wrapReason(reason),\n });\n }\n );\n break;\n case StreamKind.ENQUEUE:\n assert(streamController, \"enqueue should have stream controller\");\n if (streamController.isClosed) {\n break;\n }\n streamController.controller.enqueue(data.chunk);\n break;\n case StreamKind.CLOSE:\n assert(streamController, \"close should have stream controller\");\n if (streamController.isClosed) {\n break;\n }\n streamController.isClosed = true;\n streamController.controller.close();\n this.#deleteStreamController(streamController, streamId);\n break;\n case StreamKind.ERROR:\n assert(streamController, \"error should have stream controller\");\n streamController.controller.error(wrapReason(data.reason));\n this.#deleteStreamController(streamController, streamId);\n break;\n case StreamKind.CANCEL_COMPLETE:\n if (data.success) {\n streamController.cancelCall.resolve();\n } else {\n streamController.cancelCall.reject(wrapReason(data.reason));\n }\n this.#deleteStreamController(streamController, streamId);\n break;\n case StreamKind.CANCEL:\n if (!streamSink) {\n break;\n }\n\n new Promise(function (resolve) {\n resolve(streamSink.onCancel?.(wrapReason(data.reason)));\n }).then(\n function () {\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.CANCEL_COMPLETE,\n streamId,\n success: true,\n });\n },\n function (reason) {\n comObj.postMessage({\n sourceName,\n targetName,\n stream: StreamKind.CANCEL_COMPLETE,\n streamId,\n reason: wrapReason(reason),\n });\n }\n );\n streamSink.sinkCapability.reject(wrapReason(data.reason));\n streamSink.isCancelled = true;\n delete this.streamSinks[streamId];\n break;\n default:\n throw new Error(\"Unexpected stream case\");\n }\n }\n\n async #deleteStreamController(streamController, streamId) {\n // Delete the `streamController` only when the start, pull, and cancel\n // capabilities have settled, to prevent `TypeError`s.\n await Promise.allSettled([\n streamController.startCall?.promise,\n streamController.pullCall?.promise,\n streamController.cancelCall?.promise,\n ]);\n delete this.streamControllers[streamId];\n }\n\n destroy() {\n this.comObj.removeEventListener(\"message\", this._onComObjOnMessage);\n }\n}\n\nexport { MessageHandler };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { objectFromMap } from \"../shared/util.js\";\n\nclass Metadata {\n #metadataMap;\n\n #data;\n\n constructor({ parsedData, rawData }) {\n this.#metadataMap = parsedData;\n this.#data = rawData;\n }\n\n getRaw() {\n return this.#data;\n }\n\n get(name) {\n return this.#metadataMap.get(name) ?? null;\n }\n\n getAll() {\n return objectFromMap(this.#metadataMap);\n }\n\n has(name) {\n return this.#metadataMap.has(name);\n }\n}\n\nexport { Metadata };\n","/* Copyright 2020 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n info,\n objectFromMap,\n RenderingIntentFlag,\n unreachable,\n warn,\n} from \"../shared/util.js\";\nimport { MurmurHash3_64 } from \"../shared/murmurhash3.js\";\n\nconst INTERNAL = Symbol(\"INTERNAL\");\n\nclass OptionalContentGroup {\n #isDisplay = false;\n\n #isPrint = false;\n\n #userSet = false;\n\n #visible = true;\n\n constructor(renderingIntent, { name, intent, usage }) {\n this.#isDisplay = !!(renderingIntent & RenderingIntentFlag.DISPLAY);\n this.#isPrint = !!(renderingIntent & RenderingIntentFlag.PRINT);\n\n this.name = name;\n this.intent = intent;\n this.usage = usage;\n }\n\n /**\n * @type {boolean}\n */\n get visible() {\n if (this.#userSet) {\n return this.#visible;\n }\n if (!this.#visible) {\n return false;\n }\n const { print, view } = this.usage;\n\n if (this.#isDisplay) {\n return view?.viewState !== \"OFF\";\n } else if (this.#isPrint) {\n return print?.printState !== \"OFF\";\n }\n return true;\n }\n\n /**\n * @ignore\n */\n _setVisible(internal, visible, userSet = false) {\n if (internal !== INTERNAL) {\n unreachable(\"Internal method `_setVisible` called.\");\n }\n this.#userSet = userSet;\n this.#visible = visible;\n }\n}\n\nclass OptionalContentConfig {\n #cachedGetHash = null;\n\n #groups = new Map();\n\n #initialHash = null;\n\n #order = null;\n\n constructor(data, renderingIntent = RenderingIntentFlag.DISPLAY) {\n this.renderingIntent = renderingIntent;\n\n this.name = null;\n this.creator = null;\n\n if (data === null) {\n return;\n }\n this.name = data.name;\n this.creator = data.creator;\n this.#order = data.order;\n for (const group of data.groups) {\n this.#groups.set(\n group.id,\n new OptionalContentGroup(renderingIntent, group)\n );\n }\n\n if (data.baseState === \"OFF\") {\n for (const group of this.#groups.values()) {\n group._setVisible(INTERNAL, false);\n }\n }\n\n for (const on of data.on) {\n this.#groups.get(on)._setVisible(INTERNAL, true);\n }\n\n for (const off of data.off) {\n this.#groups.get(off)._setVisible(INTERNAL, false);\n }\n\n // The following code must always run *last* in the constructor.\n this.#initialHash = this.getHash();\n }\n\n #evaluateVisibilityExpression(array) {\n const length = array.length;\n if (length < 2) {\n return true;\n }\n const operator = array[0];\n for (let i = 1; i < length; i++) {\n const element = array[i];\n let state;\n if (Array.isArray(element)) {\n state = this.#evaluateVisibilityExpression(element);\n } else if (this.#groups.has(element)) {\n state = this.#groups.get(element).visible;\n } else {\n warn(`Optional content group not found: ${element}`);\n return true;\n }\n switch (operator) {\n case \"And\":\n if (!state) {\n return false;\n }\n break;\n case \"Or\":\n if (state) {\n return true;\n }\n break;\n case \"Not\":\n return !state;\n default:\n return true;\n }\n }\n return operator === \"And\";\n }\n\n isVisible(group) {\n if (this.#groups.size === 0) {\n return true;\n }\n if (!group) {\n info(\"Optional content group not defined.\");\n return true;\n }\n if (group.type === \"OCG\") {\n if (!this.#groups.has(group.id)) {\n warn(`Optional content group not found: ${group.id}`);\n return true;\n }\n return this.#groups.get(group.id).visible;\n } else if (group.type === \"OCMD\") {\n // Per the spec, the expression should be preferred if available.\n if (group.expression) {\n return this.#evaluateVisibilityExpression(group.expression);\n }\n if (!group.policy || group.policy === \"AnyOn\") {\n // Default\n for (const id of group.ids) {\n if (!this.#groups.has(id)) {\n warn(`Optional content group not found: ${id}`);\n return true;\n }\n if (this.#groups.get(id).visible) {\n return true;\n }\n }\n return false;\n } else if (group.policy === \"AllOn\") {\n for (const id of group.ids) {\n if (!this.#groups.has(id)) {\n warn(`Optional content group not found: ${id}`);\n return true;\n }\n if (!this.#groups.get(id).visible) {\n return false;\n }\n }\n return true;\n } else if (group.policy === \"AnyOff\") {\n for (const id of group.ids) {\n if (!this.#groups.has(id)) {\n warn(`Optional content group not found: ${id}`);\n return true;\n }\n if (!this.#groups.get(id).visible) {\n return true;\n }\n }\n return false;\n } else if (group.policy === \"AllOff\") {\n for (const id of group.ids) {\n if (!this.#groups.has(id)) {\n warn(`Optional content group not found: ${id}`);\n return true;\n }\n if (this.#groups.get(id).visible) {\n return false;\n }\n }\n return true;\n }\n warn(`Unknown optional content policy ${group.policy}.`);\n return true;\n }\n warn(`Unknown group type ${group.type}.`);\n return true;\n }\n\n setVisibility(id, visible = true) {\n const group = this.#groups.get(id);\n if (!group) {\n warn(`Optional content group not found: ${id}`);\n return;\n }\n group._setVisible(INTERNAL, !!visible, /* userSet = */ true);\n\n this.#cachedGetHash = null;\n }\n\n setOCGState({ state, preserveRB }) {\n let operator;\n\n for (const elem of state) {\n switch (elem) {\n case \"ON\":\n case \"OFF\":\n case \"Toggle\":\n operator = elem;\n continue;\n }\n\n const group = this.#groups.get(elem);\n if (!group) {\n continue;\n }\n switch (operator) {\n case \"ON\":\n group._setVisible(INTERNAL, true);\n break;\n case \"OFF\":\n group._setVisible(INTERNAL, false);\n break;\n case \"Toggle\":\n group._setVisible(INTERNAL, !group.visible);\n break;\n }\n }\n\n this.#cachedGetHash = null;\n }\n\n get hasInitialVisibility() {\n return this.#initialHash === null || this.getHash() === this.#initialHash;\n }\n\n getOrder() {\n if (!this.#groups.size) {\n return null;\n }\n if (this.#order) {\n return this.#order.slice();\n }\n return [...this.#groups.keys()];\n }\n\n getGroups() {\n return this.#groups.size > 0 ? objectFromMap(this.#groups) : null;\n }\n\n getGroup(id) {\n return this.#groups.get(id) || null;\n }\n\n getHash() {\n if (this.#cachedGetHash !== null) {\n return this.#cachedGetHash;\n }\n const hash = new MurmurHash3_64();\n\n for (const [id, group] of this.#groups) {\n hash.update(`${id}:${group.visible}`);\n }\n return (this.#cachedGetHash = hash.hexdigest());\n }\n}\n\nexport { OptionalContentConfig };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/** @typedef {import(\"../interfaces\").IPDFStream} IPDFStream */\n/** @typedef {import(\"../interfaces\").IPDFStreamReader} IPDFStreamReader */\n// eslint-disable-next-line max-len\n/** @typedef {import(\"../interfaces\").IPDFStreamRangeReader} IPDFStreamRangeReader */\n\nimport { assert } from \"../shared/util.js\";\nimport { isPdfFile } from \"./display_utils.js\";\n\n/** @implements {IPDFStream} */\nclass PDFDataTransportStream {\n constructor(\n pdfDataRangeTransport,\n { disableRange = false, disableStream = false }\n ) {\n assert(\n pdfDataRangeTransport,\n 'PDFDataTransportStream - missing required \"pdfDataRangeTransport\" argument.'\n );\n const { length, initialData, progressiveDone, contentDispositionFilename } =\n pdfDataRangeTransport;\n\n this._queuedChunks = [];\n this._progressiveDone = progressiveDone;\n this._contentDispositionFilename = contentDispositionFilename;\n\n if (initialData?.length > 0) {\n // Prevent any possible issues by only transferring a Uint8Array that\n // completely \"utilizes\" its underlying ArrayBuffer.\n const buffer =\n initialData instanceof Uint8Array &&\n initialData.byteLength === initialData.buffer.byteLength\n ? initialData.buffer\n : new Uint8Array(initialData).buffer;\n this._queuedChunks.push(buffer);\n }\n\n this._pdfDataRangeTransport = pdfDataRangeTransport;\n this._isStreamingSupported = !disableStream;\n this._isRangeSupported = !disableRange;\n this._contentLength = length;\n\n this._fullRequestReader = null;\n this._rangeReaders = [];\n\n pdfDataRangeTransport.addRangeListener((begin, chunk) => {\n this._onReceiveData({ begin, chunk });\n });\n\n pdfDataRangeTransport.addProgressListener((loaded, total) => {\n this._onProgress({ loaded, total });\n });\n\n pdfDataRangeTransport.addProgressiveReadListener(chunk => {\n this._onReceiveData({ chunk });\n });\n\n pdfDataRangeTransport.addProgressiveDoneListener(() => {\n this._onProgressiveDone();\n });\n\n pdfDataRangeTransport.transportReady();\n }\n\n _onReceiveData({ begin, chunk }) {\n // Prevent any possible issues by only transferring a Uint8Array that\n // completely \"utilizes\" its underlying ArrayBuffer.\n const buffer =\n chunk instanceof Uint8Array &&\n chunk.byteLength === chunk.buffer.byteLength\n ? chunk.buffer\n : new Uint8Array(chunk).buffer;\n\n if (begin === undefined) {\n if (this._fullRequestReader) {\n this._fullRequestReader._enqueue(buffer);\n } else {\n this._queuedChunks.push(buffer);\n }\n } else {\n const found = this._rangeReaders.some(function (rangeReader) {\n if (rangeReader._begin !== begin) {\n return false;\n }\n rangeReader._enqueue(buffer);\n return true;\n });\n assert(\n found,\n \"_onReceiveData - no `PDFDataTransportStreamRangeReader` instance found.\"\n );\n }\n }\n\n get _progressiveDataLength() {\n return this._fullRequestReader?._loaded ?? 0;\n }\n\n _onProgress(evt) {\n if (evt.total === undefined) {\n // Reporting to first range reader, if it exists.\n this._rangeReaders[0]?.onProgress?.({ loaded: evt.loaded });\n } else {\n this._fullRequestReader?.onProgress?.({\n loaded: evt.loaded,\n total: evt.total,\n });\n }\n }\n\n _onProgressiveDone() {\n this._fullRequestReader?.progressiveDone();\n this._progressiveDone = true;\n }\n\n _removeRangeReader(reader) {\n const i = this._rangeReaders.indexOf(reader);\n if (i >= 0) {\n this._rangeReaders.splice(i, 1);\n }\n }\n\n getFullReader() {\n assert(\n !this._fullRequestReader,\n \"PDFDataTransportStream.getFullReader can only be called once.\"\n );\n const queuedChunks = this._queuedChunks;\n this._queuedChunks = null;\n return new PDFDataTransportStreamReader(\n this,\n queuedChunks,\n this._progressiveDone,\n this._contentDispositionFilename\n );\n }\n\n getRangeReader(begin, end) {\n if (end <= this._progressiveDataLength) {\n return null;\n }\n const reader = new PDFDataTransportStreamRangeReader(this, begin, end);\n this._pdfDataRangeTransport.requestDataRange(begin, end);\n this._rangeReaders.push(reader);\n return reader;\n }\n\n cancelAllRequests(reason) {\n this._fullRequestReader?.cancel(reason);\n\n for (const reader of this._rangeReaders.slice(0)) {\n reader.cancel(reason);\n }\n this._pdfDataRangeTransport.abort();\n }\n}\n\n/** @implements {IPDFStreamReader} */\nclass PDFDataTransportStreamReader {\n constructor(\n stream,\n queuedChunks,\n progressiveDone = false,\n contentDispositionFilename = null\n ) {\n this._stream = stream;\n this._done = progressiveDone || false;\n this._filename = isPdfFile(contentDispositionFilename)\n ? contentDispositionFilename\n : null;\n this._queuedChunks = queuedChunks || [];\n this._loaded = 0;\n for (const chunk of this._queuedChunks) {\n this._loaded += chunk.byteLength;\n }\n this._requests = [];\n this._headersReady = Promise.resolve();\n stream._fullRequestReader = this;\n\n this.onProgress = null;\n }\n\n _enqueue(chunk) {\n if (this._done) {\n return; // Ignore new data.\n }\n if (this._requests.length > 0) {\n const requestCapability = this._requests.shift();\n requestCapability.resolve({ value: chunk, done: false });\n } else {\n this._queuedChunks.push(chunk);\n }\n this._loaded += chunk.byteLength;\n }\n\n get headersReady() {\n return this._headersReady;\n }\n\n get filename() {\n return this._filename;\n }\n\n get isRangeSupported() {\n return this._stream._isRangeSupported;\n }\n\n get isStreamingSupported() {\n return this._stream._isStreamingSupported;\n }\n\n get contentLength() {\n return this._stream._contentLength;\n }\n\n async read() {\n if (this._queuedChunks.length > 0) {\n const chunk = this._queuedChunks.shift();\n return { value: chunk, done: false };\n }\n if (this._done) {\n return { value: undefined, done: true };\n }\n const requestCapability = Promise.withResolvers();\n this._requests.push(requestCapability);\n return requestCapability.promise;\n }\n\n cancel(reason) {\n this._done = true;\n for (const requestCapability of this._requests) {\n requestCapability.resolve({ value: undefined, done: true });\n }\n this._requests.length = 0;\n }\n\n progressiveDone() {\n if (this._done) {\n return;\n }\n this._done = true;\n }\n}\n\n/** @implements {IPDFStreamRangeReader} */\nclass PDFDataTransportStreamRangeReader {\n constructor(stream, begin, end) {\n this._stream = stream;\n this._begin = begin;\n this._end = end;\n this._queuedChunk = null;\n this._requests = [];\n this._done = false;\n\n this.onProgress = null;\n }\n\n _enqueue(chunk) {\n if (this._done) {\n return; // ignore new data\n }\n if (this._requests.length === 0) {\n this._queuedChunk = chunk;\n } else {\n const requestsCapability = this._requests.shift();\n requestsCapability.resolve({ value: chunk, done: false });\n for (const requestCapability of this._requests) {\n requestCapability.resolve({ value: undefined, done: true });\n }\n this._requests.length = 0;\n }\n this._done = true;\n this._stream._removeRangeReader(this);\n }\n\n get isStreamingSupported() {\n return false;\n }\n\n async read() {\n if (this._queuedChunk) {\n const chunk = this._queuedChunk;\n this._queuedChunk = null;\n return { value: chunk, done: false };\n }\n if (this._done) {\n return { value: undefined, done: true };\n }\n const requestCapability = Promise.withResolvers();\n this._requests.push(requestCapability);\n return requestCapability.promise;\n }\n\n cancel(reason) {\n this._done = true;\n for (const requestCapability of this._requests) {\n requestCapability.resolve({ value: undefined, done: true });\n }\n this._requests.length = 0;\n this._stream._removeRangeReader(this);\n }\n}\n\nexport { PDFDataTransportStream };\n","/* Copyright 2017 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { stringToBytes } from \"../shared/util.js\";\n\n// This getFilenameFromContentDispositionHeader function is adapted from\n// https://github.com/Rob--W/open-in-browser/blob/7e2e35a38b8b4e981b11da7b2f01df0149049e92/extension/content-disposition.js\n// with the following changes:\n// - Modified to conform to PDF.js's coding style.\n// - Move return to the end of the function to prevent Babel from dropping the\n// function declarations.\n\n/**\n * Extract file name from the Content-Disposition HTTP response header.\n *\n * @param {string} contentDisposition\n * @returns {string} Filename, if found in the Content-Disposition header.\n */\nfunction getFilenameFromContentDispositionHeader(contentDisposition) {\n let needsEncodingFixup = true;\n\n // filename*=ext-value (\"ext-value\" from RFC 5987, referenced by RFC 6266).\n let tmp = toParamRegExp(\"filename\\\\*\", \"i\").exec(contentDisposition);\n if (tmp) {\n tmp = tmp[1];\n let filename = rfc2616unquote(tmp);\n filename = unescape(filename);\n filename = rfc5987decode(filename);\n filename = rfc2047decode(filename);\n return fixupEncoding(filename);\n }\n\n // Continuations (RFC 2231 section 3, referenced by RFC 5987 section 3.1).\n // filename*n*=part\n // filename*n=part\n tmp = rfc2231getparam(contentDisposition);\n if (tmp) {\n // RFC 2047, section\n const filename = rfc2047decode(tmp);\n return fixupEncoding(filename);\n }\n\n // filename=value (RFC 5987, section 4.1).\n tmp = toParamRegExp(\"filename\", \"i\").exec(contentDisposition);\n if (tmp) {\n tmp = tmp[1];\n let filename = rfc2616unquote(tmp);\n filename = rfc2047decode(filename);\n return fixupEncoding(filename);\n }\n\n // After this line there are only function declarations. We cannot put\n // \"return\" here for readability because babel would then drop the function\n // declarations...\n function toParamRegExp(attributePattern, flags) {\n return new RegExp(\n \"(?:^|;)\\\\s*\" +\n attributePattern +\n \"\\\\s*=\\\\s*\" +\n // Captures: value = token | quoted-string\n // (RFC 2616, section 3.6 and referenced by RFC 6266 4.1)\n \"(\" +\n '[^\";\\\\s][^;\\\\s]*' +\n \"|\" +\n '\"(?:[^\"\\\\\\\\]|\\\\\\\\\"?)+\"?' +\n \")\",\n flags\n );\n }\n function textdecode(encoding, value) {\n if (encoding) {\n if (!/^[\\x00-\\xFF]+$/.test(value)) {\n return value;\n }\n try {\n const decoder = new TextDecoder(encoding, { fatal: true });\n const buffer = stringToBytes(value);\n value = decoder.decode(buffer);\n needsEncodingFixup = false;\n } catch {\n // TextDecoder constructor threw - unrecognized encoding.\n }\n }\n return value;\n }\n function fixupEncoding(value) {\n if (needsEncodingFixup && /[\\x80-\\xff]/.test(value)) {\n // Maybe multi-byte UTF-8.\n value = textdecode(\"utf-8\", value);\n if (needsEncodingFixup) {\n // Try iso-8859-1 encoding.\n value = textdecode(\"iso-8859-1\", value);\n }\n }\n return value;\n }\n function rfc2231getparam(contentDispositionStr) {\n const matches = [];\n let match;\n // Iterate over all filename*n= and filename*n*= with n being an integer\n // of at least zero. Any non-zero number must not start with '0'.\n const iter = toParamRegExp(\"filename\\\\*((?!0\\\\d)\\\\d+)(\\\\*?)\", \"ig\");\n while ((match = iter.exec(contentDispositionStr)) !== null) {\n let [, n, quot, part] = match; // eslint-disable-line prefer-const\n n = parseInt(n, 10);\n if (n in matches) {\n // Ignore anything after the invalid second filename*0.\n if (n === 0) {\n break;\n }\n continue;\n }\n matches[n] = [quot, part];\n }\n const parts = [];\n for (let n = 0; n < matches.length; ++n) {\n if (!(n in matches)) {\n // Numbers must be consecutive. Truncate when there is a hole.\n break;\n }\n let [quot, part] = matches[n]; // eslint-disable-line prefer-const\n part = rfc2616unquote(part);\n if (quot) {\n part = unescape(part);\n if (n === 0) {\n part = rfc5987decode(part);\n }\n }\n parts.push(part);\n }\n return parts.join(\"\");\n }\n function rfc2616unquote(value) {\n if (value.startsWith('\"')) {\n const parts = value.slice(1).split('\\\\\"');\n // Find the first unescaped \" and terminate there.\n for (let i = 0; i < parts.length; ++i) {\n const quotindex = parts[i].indexOf('\"');\n if (quotindex !== -1) {\n parts[i] = parts[i].slice(0, quotindex);\n parts.length = i + 1; // Truncates and stop the iteration.\n }\n parts[i] = parts[i].replaceAll(/\\\\(.)/g, \"$1\");\n }\n value = parts.join('\"');\n }\n return value;\n }\n function rfc5987decode(extvalue) {\n // Decodes \"ext-value\" from RFC 5987.\n const encodingend = extvalue.indexOf(\"'\");\n if (encodingend === -1) {\n // Some servers send \"filename*=\" without encoding 'language' prefix,\n // e.g. in https://github.com/Rob--W/open-in-browser/issues/26\n // Let's accept the value like Firefox (57) (Chrome 62 rejects it).\n return extvalue;\n }\n const encoding = extvalue.slice(0, encodingend);\n const langvalue = extvalue.slice(encodingend + 1);\n // Ignore language (RFC 5987 section 3.2.1, and RFC 6266 section 4.1 ).\n const value = langvalue.replace(/^[^']*'/, \"\");\n return textdecode(encoding, value);\n }\n function rfc2047decode(value) {\n // RFC 2047-decode the result. Firefox tried to drop support for it, but\n // backed out because some servers use it - https://bugzil.la/875615\n // Firefox's condition for decoding is here: https://searchfox.org/mozilla-central/rev/4a590a5a15e35d88a3b23dd6ac3c471cf85b04a8/netwerk/mime/nsMIMEHeaderParamImpl.cpp#742-748\n\n // We are more strict and only recognize RFC 2047-encoding if the value\n // starts with \"=?\", since then it is likely that the full value is\n // RFC 2047-encoded.\n\n // Firefox also decodes words even where RFC 2047 section 5 states:\n // \"An 'encoded-word' MUST NOT appear within a 'quoted-string'.\"\n if (!value.startsWith(\"=?\") || /[\\x00-\\x19\\x80-\\xff]/.test(value)) {\n return value;\n }\n // RFC 2047, section 2.4\n // encoded-word = \"=?\" charset \"?\" encoding \"?\" encoded-text \"?=\"\n // charset = token (but let's restrict to characters that denote a\n // possibly valid encoding).\n // encoding = q or b\n // encoded-text = any printable ASCII character other than ? or space.\n // ... but Firefox permits ? and space.\n return value.replaceAll(\n /=\\?([\\w-]*)\\?([QqBb])\\?((?:[^?]|\\?(?!=))*)\\?=/g,\n function (matches, charset, encoding, text) {\n if (encoding === \"q\" || encoding === \"Q\") {\n // RFC 2047 section 4.2.\n text = text.replaceAll(\"_\", \" \");\n text = text.replaceAll(/=([0-9a-fA-F]{2})/g, function (match, hex) {\n return String.fromCharCode(parseInt(hex, 16));\n });\n return textdecode(charset, text);\n } // else encoding is b or B - base64 (RFC 2047 section 4.1)\n try {\n text = atob(text);\n } catch {}\n return textdecode(charset, text);\n }\n );\n }\n\n return \"\";\n}\n\nexport { getFilenameFromContentDispositionHeader };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n assert,\n MissingPDFException,\n UnexpectedResponseException,\n} from \"../shared/util.js\";\nimport { getFilenameFromContentDispositionHeader } from \"./content_disposition.js\";\nimport { isPdfFile } from \"./display_utils.js\";\n\nfunction validateRangeRequestCapabilities({\n getResponseHeader,\n isHttp,\n rangeChunkSize,\n disableRange,\n}) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n Number.isInteger(rangeChunkSize) && rangeChunkSize > 0,\n \"rangeChunkSize must be an integer larger than zero.\"\n );\n }\n const returnValues = {\n allowRangeRequests: false,\n suggestedLength: undefined,\n };\n\n const length = parseInt(getResponseHeader(\"Content-Length\"), 10);\n if (!Number.isInteger(length)) {\n return returnValues;\n }\n\n returnValues.suggestedLength = length;\n\n if (length <= 2 * rangeChunkSize) {\n // The file size is smaller than the size of two chunks, so it does not\n // make any sense to abort the request and retry with a range request.\n return returnValues;\n }\n\n if (disableRange || !isHttp) {\n return returnValues;\n }\n if (getResponseHeader(\"Accept-Ranges\") !== \"bytes\") {\n return returnValues;\n }\n\n const contentEncoding = getResponseHeader(\"Content-Encoding\") || \"identity\";\n if (contentEncoding !== \"identity\") {\n return returnValues;\n }\n\n returnValues.allowRangeRequests = true;\n return returnValues;\n}\n\nfunction extractFilenameFromHeader(getResponseHeader) {\n const contentDisposition = getResponseHeader(\"Content-Disposition\");\n if (contentDisposition) {\n let filename = getFilenameFromContentDispositionHeader(contentDisposition);\n if (filename.includes(\"%\")) {\n try {\n filename = decodeURIComponent(filename);\n } catch {}\n }\n if (isPdfFile(filename)) {\n return filename;\n }\n }\n return null;\n}\n\nfunction createResponseStatusError(status, url) {\n if (status === 404 || (status === 0 && url.startsWith(\"file:\"))) {\n return new MissingPDFException('Missing PDF \"' + url + '\".');\n }\n return new UnexpectedResponseException(\n `Unexpected server response (${status}) while retrieving PDF \"${url}\".`,\n status\n );\n}\n\nfunction validateResponseStatus(status) {\n return status === 200 || status === 206;\n}\n\nexport {\n createResponseStatusError,\n extractFilenameFromHeader,\n validateRangeRequestCapabilities,\n validateResponseStatus,\n};\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { AbortException, assert, warn } from \"../shared/util.js\";\nimport {\n createResponseStatusError,\n extractFilenameFromHeader,\n validateRangeRequestCapabilities,\n validateResponseStatus,\n} from \"./network_utils.js\";\n\nif (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\n 'Module \"./fetch_stream.js\" shall not be used with MOZCENTRAL builds.'\n );\n}\n\nfunction createFetchOptions(headers, withCredentials, abortController) {\n return {\n method: \"GET\",\n headers,\n signal: abortController.signal,\n mode: \"cors\",\n credentials: withCredentials ? \"include\" : \"same-origin\",\n redirect: \"follow\",\n };\n}\n\nfunction createHeaders(httpHeaders) {\n const headers = new Headers();\n for (const property in httpHeaders) {\n const value = httpHeaders[property];\n if (value === undefined) {\n continue;\n }\n headers.append(property, value);\n }\n return headers;\n}\n\nfunction getArrayBuffer(val) {\n if (val instanceof Uint8Array) {\n return val.buffer;\n }\n if (val instanceof ArrayBuffer) {\n return val;\n }\n warn(`getArrayBuffer - unexpected data format: ${val}`);\n return new Uint8Array(val).buffer;\n}\n\n/** @implements {IPDFStream} */\nclass PDFFetchStream {\n constructor(source) {\n this.source = source;\n this.isHttp = /^https?:/i.test(source.url);\n this.httpHeaders = (this.isHttp && source.httpHeaders) || {};\n\n this._fullRequestReader = null;\n this._rangeRequestReaders = [];\n }\n\n get _progressiveDataLength() {\n return this._fullRequestReader?._loaded ?? 0;\n }\n\n getFullReader() {\n assert(\n !this._fullRequestReader,\n \"PDFFetchStream.getFullReader can only be called once.\"\n );\n this._fullRequestReader = new PDFFetchStreamReader(this);\n return this._fullRequestReader;\n }\n\n getRangeReader(begin, end) {\n if (end <= this._progressiveDataLength) {\n return null;\n }\n const reader = new PDFFetchStreamRangeReader(this, begin, end);\n this._rangeRequestReaders.push(reader);\n return reader;\n }\n\n cancelAllRequests(reason) {\n this._fullRequestReader?.cancel(reason);\n\n for (const reader of this._rangeRequestReaders.slice(0)) {\n reader.cancel(reason);\n }\n }\n}\n\n/** @implements {IPDFStreamReader} */\nclass PDFFetchStreamReader {\n constructor(stream) {\n this._stream = stream;\n this._reader = null;\n this._loaded = 0;\n this._filename = null;\n const source = stream.source;\n this._withCredentials = source.withCredentials || false;\n this._contentLength = source.length;\n this._headersCapability = Promise.withResolvers();\n this._disableRange = source.disableRange || false;\n this._rangeChunkSize = source.rangeChunkSize;\n if (!this._rangeChunkSize && !this._disableRange) {\n this._disableRange = true;\n }\n\n this._abortController = new AbortController();\n this._isStreamingSupported = !source.disableStream;\n this._isRangeSupported = !source.disableRange;\n\n this._headers = createHeaders(this._stream.httpHeaders);\n\n const url = source.url;\n fetch(\n url,\n createFetchOptions(\n this._headers,\n this._withCredentials,\n this._abortController\n )\n )\n .then(response => {\n if (!validateResponseStatus(response.status)) {\n throw createResponseStatusError(response.status, url);\n }\n this._reader = response.body.getReader();\n this._headersCapability.resolve();\n\n const getResponseHeader = name => response.headers.get(name);\n\n const { allowRangeRequests, suggestedLength } =\n validateRangeRequestCapabilities({\n getResponseHeader,\n isHttp: this._stream.isHttp,\n rangeChunkSize: this._rangeChunkSize,\n disableRange: this._disableRange,\n });\n\n this._isRangeSupported = allowRangeRequests;\n // Setting right content length.\n this._contentLength = suggestedLength || this._contentLength;\n\n this._filename = extractFilenameFromHeader(getResponseHeader);\n\n // We need to stop reading when range is supported and streaming is\n // disabled.\n if (!this._isStreamingSupported && this._isRangeSupported) {\n this.cancel(new AbortException(\"Streaming is disabled.\"));\n }\n })\n .catch(this._headersCapability.reject);\n\n this.onProgress = null;\n }\n\n get headersReady() {\n return this._headersCapability.promise;\n }\n\n get filename() {\n return this._filename;\n }\n\n get contentLength() {\n return this._contentLength;\n }\n\n get isRangeSupported() {\n return this._isRangeSupported;\n }\n\n get isStreamingSupported() {\n return this._isStreamingSupported;\n }\n\n async read() {\n await this._headersCapability.promise;\n const { value, done } = await this._reader.read();\n if (done) {\n return { value, done };\n }\n this._loaded += value.byteLength;\n this.onProgress?.({\n loaded: this._loaded,\n total: this._contentLength,\n });\n\n return { value: getArrayBuffer(value), done: false };\n }\n\n cancel(reason) {\n this._reader?.cancel(reason);\n this._abortController.abort();\n }\n}\n\n/** @implements {IPDFStreamRangeReader} */\nclass PDFFetchStreamRangeReader {\n constructor(stream, begin, end) {\n this._stream = stream;\n this._reader = null;\n this._loaded = 0;\n const source = stream.source;\n this._withCredentials = source.withCredentials || false;\n this._readCapability = Promise.withResolvers();\n this._isStreamingSupported = !source.disableStream;\n\n this._abortController = new AbortController();\n this._headers = createHeaders(this._stream.httpHeaders);\n this._headers.append(\"Range\", `bytes=${begin}-${end - 1}`);\n\n const url = source.url;\n fetch(\n url,\n createFetchOptions(\n this._headers,\n this._withCredentials,\n this._abortController\n )\n )\n .then(response => {\n if (!validateResponseStatus(response.status)) {\n throw createResponseStatusError(response.status, url);\n }\n this._readCapability.resolve();\n this._reader = response.body.getReader();\n })\n .catch(this._readCapability.reject);\n\n this.onProgress = null;\n }\n\n get isStreamingSupported() {\n return this._isStreamingSupported;\n }\n\n async read() {\n await this._readCapability.promise;\n const { value, done } = await this._reader.read();\n if (done) {\n return { value, done };\n }\n this._loaded += value.byteLength;\n this.onProgress?.({ loaded: this._loaded });\n\n return { value: getArrayBuffer(value), done: false };\n }\n\n cancel(reason) {\n this._reader?.cancel(reason);\n this._abortController.abort();\n }\n}\n\nexport { PDFFetchStream };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { assert, stringToBytes } from \"../shared/util.js\";\nimport {\n createResponseStatusError,\n extractFilenameFromHeader,\n validateRangeRequestCapabilities,\n} from \"./network_utils.js\";\n\nif (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\n 'Module \"./network.js\" shall not be used with MOZCENTRAL builds.'\n );\n}\n\nconst OK_RESPONSE = 200;\nconst PARTIAL_CONTENT_RESPONSE = 206;\n\nfunction getArrayBuffer(xhr) {\n const data = xhr.response;\n if (typeof data !== \"string\") {\n return data;\n }\n return stringToBytes(data).buffer;\n}\n\nclass NetworkManager {\n constructor(url, args = {}) {\n this.url = url;\n this.isHttp = /^https?:/i.test(url);\n this.httpHeaders = (this.isHttp && args.httpHeaders) || Object.create(null);\n this.withCredentials = args.withCredentials || false;\n\n this.currXhrId = 0;\n this.pendingRequests = Object.create(null);\n }\n\n requestRange(begin, end, listeners) {\n const args = {\n begin,\n end,\n };\n for (const prop in listeners) {\n args[prop] = listeners[prop];\n }\n return this.request(args);\n }\n\n requestFull(listeners) {\n return this.request(listeners);\n }\n\n request(args) {\n const xhr = new XMLHttpRequest();\n const xhrId = this.currXhrId++;\n const pendingRequest = (this.pendingRequests[xhrId] = { xhr });\n\n xhr.open(\"GET\", this.url);\n xhr.withCredentials = this.withCredentials;\n for (const property in this.httpHeaders) {\n const value = this.httpHeaders[property];\n if (value === undefined) {\n continue;\n }\n xhr.setRequestHeader(property, value);\n }\n if (this.isHttp && \"begin\" in args && \"end\" in args) {\n xhr.setRequestHeader(\"Range\", `bytes=${args.begin}-${args.end - 1}`);\n pendingRequest.expectedStatus = PARTIAL_CONTENT_RESPONSE;\n } else {\n pendingRequest.expectedStatus = OK_RESPONSE;\n }\n xhr.responseType = \"arraybuffer\";\n\n if (args.onError) {\n xhr.onerror = function (evt) {\n args.onError(xhr.status);\n };\n }\n xhr.onreadystatechange = this.onStateChange.bind(this, xhrId);\n xhr.onprogress = this.onProgress.bind(this, xhrId);\n\n pendingRequest.onHeadersReceived = args.onHeadersReceived;\n pendingRequest.onDone = args.onDone;\n pendingRequest.onError = args.onError;\n pendingRequest.onProgress = args.onProgress;\n\n xhr.send(null);\n\n return xhrId;\n }\n\n onProgress(xhrId, evt) {\n const pendingRequest = this.pendingRequests[xhrId];\n if (!pendingRequest) {\n return; // Maybe abortRequest was called...\n }\n pendingRequest.onProgress?.(evt);\n }\n\n onStateChange(xhrId, evt) {\n const pendingRequest = this.pendingRequests[xhrId];\n if (!pendingRequest) {\n return; // Maybe abortRequest was called...\n }\n\n const xhr = pendingRequest.xhr;\n if (xhr.readyState >= 2 && pendingRequest.onHeadersReceived) {\n pendingRequest.onHeadersReceived();\n delete pendingRequest.onHeadersReceived;\n }\n\n if (xhr.readyState !== 4) {\n return;\n }\n\n if (!(xhrId in this.pendingRequests)) {\n // The XHR request might have been aborted in onHeadersReceived()\n // callback, in which case we should abort request.\n return;\n }\n\n delete this.pendingRequests[xhrId];\n\n // Success status == 0 can be on ftp, file and other protocols.\n if (xhr.status === 0 && this.isHttp) {\n pendingRequest.onError?.(xhr.status);\n return;\n }\n const xhrStatus = xhr.status || OK_RESPONSE;\n\n // From http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.35.2:\n // \"A server MAY ignore the Range header\". This means it's possible to\n // get a 200 rather than a 206 response from a range request.\n const ok_response_on_range_request =\n xhrStatus === OK_RESPONSE &&\n pendingRequest.expectedStatus === PARTIAL_CONTENT_RESPONSE;\n\n if (\n !ok_response_on_range_request &&\n xhrStatus !== pendingRequest.expectedStatus\n ) {\n pendingRequest.onError?.(xhr.status);\n return;\n }\n\n const chunk = getArrayBuffer(xhr);\n if (xhrStatus === PARTIAL_CONTENT_RESPONSE) {\n const rangeHeader = xhr.getResponseHeader(\"Content-Range\");\n const matches = /bytes (\\d+)-(\\d+)\\/(\\d+)/.exec(rangeHeader);\n pendingRequest.onDone({\n begin: parseInt(matches[1], 10),\n chunk,\n });\n } else if (chunk) {\n pendingRequest.onDone({\n begin: 0,\n chunk,\n });\n } else {\n pendingRequest.onError?.(xhr.status);\n }\n }\n\n getRequestXhr(xhrId) {\n return this.pendingRequests[xhrId].xhr;\n }\n\n isPendingRequest(xhrId) {\n return xhrId in this.pendingRequests;\n }\n\n abortRequest(xhrId) {\n const xhr = this.pendingRequests[xhrId].xhr;\n delete this.pendingRequests[xhrId];\n xhr.abort();\n }\n}\n\n/** @implements {IPDFStream} */\nclass PDFNetworkStream {\n constructor(source) {\n this._source = source;\n this._manager = new NetworkManager(source.url, {\n httpHeaders: source.httpHeaders,\n withCredentials: source.withCredentials,\n });\n this._rangeChunkSize = source.rangeChunkSize;\n this._fullRequestReader = null;\n this._rangeRequestReaders = [];\n }\n\n _onRangeRequestReaderClosed(reader) {\n const i = this._rangeRequestReaders.indexOf(reader);\n if (i >= 0) {\n this._rangeRequestReaders.splice(i, 1);\n }\n }\n\n getFullReader() {\n assert(\n !this._fullRequestReader,\n \"PDFNetworkStream.getFullReader can only be called once.\"\n );\n this._fullRequestReader = new PDFNetworkStreamFullRequestReader(\n this._manager,\n this._source\n );\n return this._fullRequestReader;\n }\n\n getRangeReader(begin, end) {\n const reader = new PDFNetworkStreamRangeRequestReader(\n this._manager,\n begin,\n end\n );\n reader.onClosed = this._onRangeRequestReaderClosed.bind(this);\n this._rangeRequestReaders.push(reader);\n return reader;\n }\n\n cancelAllRequests(reason) {\n this._fullRequestReader?.cancel(reason);\n\n for (const reader of this._rangeRequestReaders.slice(0)) {\n reader.cancel(reason);\n }\n }\n}\n\n/** @implements {IPDFStreamReader} */\nclass PDFNetworkStreamFullRequestReader {\n constructor(manager, source) {\n this._manager = manager;\n\n const args = {\n onHeadersReceived: this._onHeadersReceived.bind(this),\n onDone: this._onDone.bind(this),\n onError: this._onError.bind(this),\n onProgress: this._onProgress.bind(this),\n };\n this._url = source.url;\n this._fullRequestId = manager.requestFull(args);\n this._headersReceivedCapability = Promise.withResolvers();\n this._disableRange = source.disableRange || false;\n this._contentLength = source.length; // Optional\n this._rangeChunkSize = source.rangeChunkSize;\n if (!this._rangeChunkSize && !this._disableRange) {\n this._disableRange = true;\n }\n\n this._isStreamingSupported = false;\n this._isRangeSupported = false;\n\n this._cachedChunks = [];\n this._requests = [];\n this._done = false;\n this._storedError = undefined;\n this._filename = null;\n\n this.onProgress = null;\n }\n\n _onHeadersReceived() {\n const fullRequestXhrId = this._fullRequestId;\n const fullRequestXhr = this._manager.getRequestXhr(fullRequestXhrId);\n\n const getResponseHeader = name => fullRequestXhr.getResponseHeader(name);\n\n const { allowRangeRequests, suggestedLength } =\n validateRangeRequestCapabilities({\n getResponseHeader,\n isHttp: this._manager.isHttp,\n rangeChunkSize: this._rangeChunkSize,\n disableRange: this._disableRange,\n });\n\n if (allowRangeRequests) {\n this._isRangeSupported = true;\n }\n // Setting right content length.\n this._contentLength = suggestedLength || this._contentLength;\n\n this._filename = extractFilenameFromHeader(getResponseHeader);\n\n if (this._isRangeSupported) {\n // NOTE: by cancelling the full request, and then issuing range\n // requests, there will be an issue for sites where you can only\n // request the pdf once. However, if this is the case, then the\n // server should not be returning that it can support range requests.\n this._manager.abortRequest(fullRequestXhrId);\n }\n\n this._headersReceivedCapability.resolve();\n }\n\n _onDone(data) {\n if (data) {\n if (this._requests.length > 0) {\n const requestCapability = this._requests.shift();\n requestCapability.resolve({ value: data.chunk, done: false });\n } else {\n this._cachedChunks.push(data.chunk);\n }\n }\n this._done = true;\n if (this._cachedChunks.length > 0) {\n return;\n }\n for (const requestCapability of this._requests) {\n requestCapability.resolve({ value: undefined, done: true });\n }\n this._requests.length = 0;\n }\n\n _onError(status) {\n this._storedError = createResponseStatusError(status, this._url);\n this._headersReceivedCapability.reject(this._storedError);\n for (const requestCapability of this._requests) {\n requestCapability.reject(this._storedError);\n }\n this._requests.length = 0;\n this._cachedChunks.length = 0;\n }\n\n _onProgress(evt) {\n this.onProgress?.({\n loaded: evt.loaded,\n total: evt.lengthComputable ? evt.total : this._contentLength,\n });\n }\n\n get filename() {\n return this._filename;\n }\n\n get isRangeSupported() {\n return this._isRangeSupported;\n }\n\n get isStreamingSupported() {\n return this._isStreamingSupported;\n }\n\n get contentLength() {\n return this._contentLength;\n }\n\n get headersReady() {\n return this._headersReceivedCapability.promise;\n }\n\n async read() {\n if (this._storedError) {\n throw this._storedError;\n }\n if (this._cachedChunks.length > 0) {\n const chunk = this._cachedChunks.shift();\n return { value: chunk, done: false };\n }\n if (this._done) {\n return { value: undefined, done: true };\n }\n const requestCapability = Promise.withResolvers();\n this._requests.push(requestCapability);\n return requestCapability.promise;\n }\n\n cancel(reason) {\n this._done = true;\n this._headersReceivedCapability.reject(reason);\n for (const requestCapability of this._requests) {\n requestCapability.resolve({ value: undefined, done: true });\n }\n this._requests.length = 0;\n if (this._manager.isPendingRequest(this._fullRequestId)) {\n this._manager.abortRequest(this._fullRequestId);\n }\n this._fullRequestReader = null;\n }\n}\n\n/** @implements {IPDFStreamRangeReader} */\nclass PDFNetworkStreamRangeRequestReader {\n constructor(manager, begin, end) {\n this._manager = manager;\n\n const args = {\n onDone: this._onDone.bind(this),\n onError: this._onError.bind(this),\n onProgress: this._onProgress.bind(this),\n };\n this._url = manager.url;\n this._requestId = manager.requestRange(begin, end, args);\n this._requests = [];\n this._queuedChunk = null;\n this._done = false;\n this._storedError = undefined;\n\n this.onProgress = null;\n this.onClosed = null;\n }\n\n _close() {\n this.onClosed?.(this);\n }\n\n _onDone(data) {\n const chunk = data.chunk;\n if (this._requests.length > 0) {\n const requestCapability = this._requests.shift();\n requestCapability.resolve({ value: chunk, done: false });\n } else {\n this._queuedChunk = chunk;\n }\n this._done = true;\n for (const requestCapability of this._requests) {\n requestCapability.resolve({ value: undefined, done: true });\n }\n this._requests.length = 0;\n this._close();\n }\n\n _onError(status) {\n this._storedError = createResponseStatusError(status, this._url);\n for (const requestCapability of this._requests) {\n requestCapability.reject(this._storedError);\n }\n this._requests.length = 0;\n this._queuedChunk = null;\n }\n\n _onProgress(evt) {\n if (!this.isStreamingSupported) {\n this.onProgress?.({ loaded: evt.loaded });\n }\n }\n\n get isStreamingSupported() {\n return false;\n }\n\n async read() {\n if (this._storedError) {\n throw this._storedError;\n }\n if (this._queuedChunk !== null) {\n const chunk = this._queuedChunk;\n this._queuedChunk = null;\n return { value: chunk, done: false };\n }\n if (this._done) {\n return { value: undefined, done: true };\n }\n const requestCapability = Promise.withResolvers();\n this._requests.push(requestCapability);\n return requestCapability.promise;\n }\n\n cancel(reason) {\n this._done = true;\n for (const requestCapability of this._requests) {\n requestCapability.resolve({ value: undefined, done: true });\n }\n this._requests.length = 0;\n if (this._manager.isPendingRequest(this._requestId)) {\n this._manager.abortRequest(this._requestId);\n }\n this._close();\n }\n}\n\nexport { PDFNetworkStream };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { AbortException, assert, MissingPDFException } from \"../shared/util.js\";\nimport {\n extractFilenameFromHeader,\n validateRangeRequestCapabilities,\n} from \"./network_utils.js\";\nimport { NodePackages } from \"./node_utils.js\";\n\nif (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\n 'Module \"./node_stream.js\" shall not be used with MOZCENTRAL builds.'\n );\n}\n\nconst fileUriRegex = /^file:\\/\\/\\/[a-zA-Z]:\\//;\n\nfunction parseUrl(sourceUrl) {\n const url = NodePackages.get(\"url\");\n const parsedUrl = url.parse(sourceUrl);\n if (parsedUrl.protocol === \"file:\" || parsedUrl.host) {\n return parsedUrl;\n }\n // Prepending 'file:///' to Windows absolute path.\n if (/^[a-z]:[/\\\\]/i.test(sourceUrl)) {\n return url.parse(`file:///${sourceUrl}`);\n }\n // Changes protocol to 'file:' if url refers to filesystem.\n if (!parsedUrl.host) {\n parsedUrl.protocol = \"file:\";\n }\n return parsedUrl;\n}\n\nclass PDFNodeStream {\n constructor(source) {\n this.source = source;\n this.url = parseUrl(source.url);\n this.isHttp =\n this.url.protocol === \"http:\" || this.url.protocol === \"https:\";\n // Check if url refers to filesystem.\n this.isFsUrl = this.url.protocol === \"file:\";\n this.httpHeaders = (this.isHttp && source.httpHeaders) || {};\n\n this._fullRequestReader = null;\n this._rangeRequestReaders = [];\n }\n\n get _progressiveDataLength() {\n return this._fullRequestReader?._loaded ?? 0;\n }\n\n getFullReader() {\n assert(\n !this._fullRequestReader,\n \"PDFNodeStream.getFullReader can only be called once.\"\n );\n this._fullRequestReader = this.isFsUrl\n ? new PDFNodeStreamFsFullReader(this)\n : new PDFNodeStreamFullReader(this);\n return this._fullRequestReader;\n }\n\n getRangeReader(start, end) {\n if (end <= this._progressiveDataLength) {\n return null;\n }\n const rangeReader = this.isFsUrl\n ? new PDFNodeStreamFsRangeReader(this, start, end)\n : new PDFNodeStreamRangeReader(this, start, end);\n this._rangeRequestReaders.push(rangeReader);\n return rangeReader;\n }\n\n cancelAllRequests(reason) {\n this._fullRequestReader?.cancel(reason);\n\n for (const reader of this._rangeRequestReaders.slice(0)) {\n reader.cancel(reason);\n }\n }\n}\n\nclass BaseFullReader {\n constructor(stream) {\n this._url = stream.url;\n this._done = false;\n this._storedError = null;\n this.onProgress = null;\n const source = stream.source;\n this._contentLength = source.length; // optional\n this._loaded = 0;\n this._filename = null;\n\n this._disableRange = source.disableRange || false;\n this._rangeChunkSize = source.rangeChunkSize;\n if (!this._rangeChunkSize && !this._disableRange) {\n this._disableRange = true;\n }\n\n this._isStreamingSupported = !source.disableStream;\n this._isRangeSupported = !source.disableRange;\n\n this._readableStream = null;\n this._readCapability = Promise.withResolvers();\n this._headersCapability = Promise.withResolvers();\n }\n\n get headersReady() {\n return this._headersCapability.promise;\n }\n\n get filename() {\n return this._filename;\n }\n\n get contentLength() {\n return this._contentLength;\n }\n\n get isRangeSupported() {\n return this._isRangeSupported;\n }\n\n get isStreamingSupported() {\n return this._isStreamingSupported;\n }\n\n async read() {\n await this._readCapability.promise;\n if (this._done) {\n return { value: undefined, done: true };\n }\n if (this._storedError) {\n throw this._storedError;\n }\n\n const chunk = this._readableStream.read();\n if (chunk === null) {\n this._readCapability = Promise.withResolvers();\n return this.read();\n }\n this._loaded += chunk.length;\n this.onProgress?.({\n loaded: this._loaded,\n total: this._contentLength,\n });\n\n // Ensure that `read()` method returns ArrayBuffer.\n const buffer = new Uint8Array(chunk).buffer;\n return { value: buffer, done: false };\n }\n\n cancel(reason) {\n // Call `this._error()` method when cancel is called\n // before _readableStream is set.\n if (!this._readableStream) {\n this._error(reason);\n return;\n }\n this._readableStream.destroy(reason);\n }\n\n _error(reason) {\n this._storedError = reason;\n this._readCapability.resolve();\n }\n\n _setReadableStream(readableStream) {\n this._readableStream = readableStream;\n readableStream.on(\"readable\", () => {\n this._readCapability.resolve();\n });\n\n readableStream.on(\"end\", () => {\n // Destroy readable to minimize resource usage.\n readableStream.destroy();\n this._done = true;\n this._readCapability.resolve();\n });\n\n readableStream.on(\"error\", reason => {\n this._error(reason);\n });\n\n // We need to stop reading when range is supported and streaming is\n // disabled.\n if (!this._isStreamingSupported && this._isRangeSupported) {\n this._error(new AbortException(\"streaming is disabled\"));\n }\n\n // Destroy ReadableStream if already in errored state.\n if (this._storedError) {\n this._readableStream.destroy(this._storedError);\n }\n }\n}\n\nclass BaseRangeReader {\n constructor(stream) {\n this._url = stream.url;\n this._done = false;\n this._storedError = null;\n this.onProgress = null;\n this._loaded = 0;\n this._readableStream = null;\n this._readCapability = Promise.withResolvers();\n const source = stream.source;\n this._isStreamingSupported = !source.disableStream;\n }\n\n get isStreamingSupported() {\n return this._isStreamingSupported;\n }\n\n async read() {\n await this._readCapability.promise;\n if (this._done) {\n return { value: undefined, done: true };\n }\n if (this._storedError) {\n throw this._storedError;\n }\n\n const chunk = this._readableStream.read();\n if (chunk === null) {\n this._readCapability = Promise.withResolvers();\n return this.read();\n }\n this._loaded += chunk.length;\n this.onProgress?.({ loaded: this._loaded });\n\n // Ensure that `read()` method returns ArrayBuffer.\n const buffer = new Uint8Array(chunk).buffer;\n return { value: buffer, done: false };\n }\n\n cancel(reason) {\n // Call `this._error()` method when cancel is called\n // before _readableStream is set.\n if (!this._readableStream) {\n this._error(reason);\n return;\n }\n this._readableStream.destroy(reason);\n }\n\n _error(reason) {\n this._storedError = reason;\n this._readCapability.resolve();\n }\n\n _setReadableStream(readableStream) {\n this._readableStream = readableStream;\n readableStream.on(\"readable\", () => {\n this._readCapability.resolve();\n });\n\n readableStream.on(\"end\", () => {\n // Destroy readableStream to minimize resource usage.\n readableStream.destroy();\n this._done = true;\n this._readCapability.resolve();\n });\n\n readableStream.on(\"error\", reason => {\n this._error(reason);\n });\n\n // Destroy readableStream if already in errored state.\n if (this._storedError) {\n this._readableStream.destroy(this._storedError);\n }\n }\n}\n\nfunction createRequestOptions(parsedUrl, headers) {\n return {\n protocol: parsedUrl.protocol,\n auth: parsedUrl.auth,\n host: parsedUrl.hostname,\n port: parsedUrl.port,\n path: parsedUrl.path,\n method: \"GET\",\n headers,\n };\n}\n\nclass PDFNodeStreamFullReader extends BaseFullReader {\n constructor(stream) {\n super(stream);\n\n const handleResponse = response => {\n if (response.statusCode === 404) {\n const error = new MissingPDFException(`Missing PDF \"${this._url}\".`);\n this._storedError = error;\n this._headersCapability.reject(error);\n return;\n }\n this._headersCapability.resolve();\n this._setReadableStream(response);\n\n // Make sure that headers name are in lower case, as mentioned\n // here: https://nodejs.org/api/http.html#http_message_headers.\n const getResponseHeader = name =>\n this._readableStream.headers[name.toLowerCase()];\n\n const { allowRangeRequests, suggestedLength } =\n validateRangeRequestCapabilities({\n getResponseHeader,\n isHttp: stream.isHttp,\n rangeChunkSize: this._rangeChunkSize,\n disableRange: this._disableRange,\n });\n\n this._isRangeSupported = allowRangeRequests;\n // Setting right content length.\n this._contentLength = suggestedLength || this._contentLength;\n\n this._filename = extractFilenameFromHeader(getResponseHeader);\n };\n\n this._request = null;\n if (this._url.protocol === \"http:\") {\n const http = NodePackages.get(\"http\");\n this._request = http.request(\n createRequestOptions(this._url, stream.httpHeaders),\n handleResponse\n );\n } else {\n const https = NodePackages.get(\"https\");\n this._request = https.request(\n createRequestOptions(this._url, stream.httpHeaders),\n handleResponse\n );\n }\n\n this._request.on(\"error\", reason => {\n this._storedError = reason;\n this._headersCapability.reject(reason);\n });\n // Note: `request.end(data)` is used to write `data` to request body\n // and notify end of request. But one should always call `request.end()`\n // even if there is no data to write -- (to notify the end of request).\n this._request.end();\n }\n}\n\nclass PDFNodeStreamRangeReader extends BaseRangeReader {\n constructor(stream, start, end) {\n super(stream);\n\n this._httpHeaders = {};\n for (const property in stream.httpHeaders) {\n const value = stream.httpHeaders[property];\n if (value === undefined) {\n continue;\n }\n this._httpHeaders[property] = value;\n }\n this._httpHeaders.Range = `bytes=${start}-${end - 1}`;\n\n const handleResponse = response => {\n if (response.statusCode === 404) {\n const error = new MissingPDFException(`Missing PDF \"${this._url}\".`);\n this._storedError = error;\n return;\n }\n this._setReadableStream(response);\n };\n\n this._request = null;\n if (this._url.protocol === \"http:\") {\n const http = NodePackages.get(\"http\");\n this._request = http.request(\n createRequestOptions(this._url, this._httpHeaders),\n handleResponse\n );\n } else {\n const https = NodePackages.get(\"https\");\n this._request = https.request(\n createRequestOptions(this._url, this._httpHeaders),\n handleResponse\n );\n }\n\n this._request.on(\"error\", reason => {\n this._storedError = reason;\n });\n this._request.end();\n }\n}\n\nclass PDFNodeStreamFsFullReader extends BaseFullReader {\n constructor(stream) {\n super(stream);\n\n let path = decodeURIComponent(this._url.path);\n\n // Remove the extra slash to get right path from url like `file:///C:/`\n if (fileUriRegex.test(this._url.href)) {\n path = path.replace(/^\\//, \"\");\n }\n\n const fs = NodePackages.get(\"fs\");\n fs.promises.lstat(path).then(\n stat => {\n // Setting right content length.\n this._contentLength = stat.size;\n\n this._setReadableStream(fs.createReadStream(path));\n this._headersCapability.resolve();\n },\n error => {\n if (error.code === \"ENOENT\") {\n error = new MissingPDFException(`Missing PDF \"${path}\".`);\n }\n this._storedError = error;\n this._headersCapability.reject(error);\n }\n );\n }\n}\n\nclass PDFNodeStreamFsRangeReader extends BaseRangeReader {\n constructor(stream, start, end) {\n super(stream);\n\n let path = decodeURIComponent(this._url.path);\n\n // Remove the extra slash to get right path from url like `file:///C:/`\n if (fileUriRegex.test(this._url.href)) {\n path = path.replace(/^\\//, \"\");\n }\n\n const fs = NodePackages.get(\"fs\");\n this._setReadableStream(fs.createReadStream(path, { start, end: end - 1 }));\n }\n}\n\nexport { PDFNodeStream };\n","/* Copyright 2015 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/** @typedef {import(\"./display_utils\").PageViewport} PageViewport */\n/** @typedef {import(\"./api\").TextContent} TextContent */\n\nimport { AbortException, Util, warn } from \"../shared/util.js\";\nimport { deprecated, setLayerDimensions } from \"./display_utils.js\";\n\n/**\n * @typedef {Object} TextLayerParameters\n * @property {ReadableStream | TextContent} textContentSource - Text content to\n * render, i.e. the value returned by the page's `streamTextContent` or\n * `getTextContent` method.\n * @property {HTMLElement} container - The DOM node that will contain the text\n * runs.\n * @property {PageViewport} viewport - The target viewport to properly layout\n * the text runs.\n */\n\n/**\n * @typedef {Object} TextLayerUpdateParameters\n * @property {PageViewport} viewport - The target viewport to properly layout\n * the text runs.\n * @property {function} [onBefore] - Callback invoked before the textLayer is\n * updated in the DOM.\n */\n\nconst MAX_TEXT_DIVS_TO_RENDER = 100000;\nconst DEFAULT_FONT_SIZE = 30;\nconst DEFAULT_FONT_ASCENT = 0.8;\n\nclass TextLayer {\n #capability = Promise.withResolvers();\n\n #container = null;\n\n #disableProcessItems = false;\n\n #fontInspectorEnabled = !!globalThis.FontInspector?.enabled;\n\n #lang = null;\n\n #layoutTextParams = null;\n\n #pageHeight = 0;\n\n #pageWidth = 0;\n\n #reader = null;\n\n #rootContainer = null;\n\n #rotation = 0;\n\n #scale = 0;\n\n #styleCache = Object.create(null);\n\n #textContentItemsStr = [];\n\n #textContentSource = null;\n\n #textDivs = [];\n\n #textDivProperties = new WeakMap();\n\n #transform = null;\n\n static #ascentCache = new Map();\n\n static #canvasContexts = new Map();\n\n static #pendingTextLayers = new Set();\n\n /**\n * @param {TextLayerParameters} options\n */\n constructor({ textContentSource, container, viewport }) {\n if (textContentSource instanceof ReadableStream) {\n this.#textContentSource = textContentSource;\n } else if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"GENERIC\")) &&\n typeof textContentSource === \"object\"\n ) {\n this.#textContentSource = new ReadableStream({\n start(controller) {\n controller.enqueue(textContentSource);\n controller.close();\n },\n });\n } else {\n throw new Error('No \"textContentSource\" parameter specified.');\n }\n this.#container = this.#rootContainer = container;\n\n this.#scale = viewport.scale * (globalThis.devicePixelRatio || 1);\n this.#rotation = viewport.rotation;\n this.#layoutTextParams = {\n prevFontSize: null,\n prevFontFamily: null,\n div: null,\n properties: null,\n ctx: null,\n };\n const { pageWidth, pageHeight, pageX, pageY } = viewport.rawDims;\n this.#transform = [1, 0, 0, -1, -pageX, pageY + pageHeight];\n this.#pageWidth = pageWidth;\n this.#pageHeight = pageHeight;\n\n setLayerDimensions(container, viewport);\n\n // Always clean-up the temporary canvas once rendering is no longer pending.\n this.#capability.promise\n .catch(() => {\n // Avoid \"Uncaught promise\" messages in the console.\n })\n .then(() => {\n TextLayer.#pendingTextLayers.delete(this);\n this.#layoutTextParams = null;\n this.#styleCache = null;\n });\n\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n // For testing purposes.\n Object.defineProperty(this, \"pageWidth\", {\n get() {\n return this.#pageWidth;\n },\n });\n Object.defineProperty(this, \"pageHeight\", {\n get() {\n return this.#pageHeight;\n },\n });\n }\n }\n\n /**\n * Render the textLayer.\n * @returns {Promise}\n */\n render() {\n const pump = () => {\n this.#reader.read().then(({ value, done }) => {\n if (done) {\n this.#capability.resolve();\n return;\n }\n this.#lang ??= value.lang;\n Object.assign(this.#styleCache, value.styles);\n this.#processItems(value.items);\n pump();\n }, this.#capability.reject);\n };\n this.#reader = this.#textContentSource.getReader();\n TextLayer.#pendingTextLayers.add(this);\n pump();\n\n return this.#capability.promise;\n }\n\n /**\n * Update a previously rendered textLayer, if necessary.\n * @param {TextLayerUpdateParameters} options\n * @returns {undefined}\n */\n update({ viewport, onBefore = null }) {\n const scale = viewport.scale * (globalThis.devicePixelRatio || 1);\n const rotation = viewport.rotation;\n\n if (rotation !== this.#rotation) {\n onBefore?.();\n this.#rotation = rotation;\n setLayerDimensions(this.#rootContainer, { rotation });\n }\n\n if (scale !== this.#scale) {\n onBefore?.();\n this.#scale = scale;\n const params = {\n prevFontSize: null,\n prevFontFamily: null,\n div: null,\n properties: null,\n ctx: TextLayer.#getCtx(this.#lang),\n };\n for (const div of this.#textDivs) {\n params.properties = this.#textDivProperties.get(div);\n params.div = div;\n this.#layout(params);\n }\n }\n }\n\n /**\n * Cancel rendering of the textLayer.\n * @returns {undefined}\n */\n cancel() {\n const abortEx = new AbortException(\"TextLayer task cancelled.\");\n\n this.#reader?.cancel(abortEx).catch(() => {\n // Avoid \"Uncaught promise\" messages in the console.\n });\n this.#reader = null;\n\n this.#capability.reject(abortEx);\n }\n\n /**\n * @type {Array} HTML elements that correspond to the text items\n * of the textContent input.\n * This is output and will initially be set to an empty array.\n */\n get textDivs() {\n return this.#textDivs;\n }\n\n /**\n * @type {Array} Strings that correspond to the `str` property of\n * the text items of the textContent input.\n * This is output and will initially be set to an empty array\n */\n get textContentItemsStr() {\n return this.#textContentItemsStr;\n }\n\n #processItems(items) {\n if (this.#disableProcessItems) {\n return;\n }\n this.#layoutTextParams.ctx ||= TextLayer.#getCtx(this.#lang);\n\n const textDivs = this.#textDivs,\n textContentItemsStr = this.#textContentItemsStr;\n\n for (const item of items) {\n // No point in rendering many divs as it would make the browser\n // unusable even after the divs are rendered.\n if (textDivs.length > MAX_TEXT_DIVS_TO_RENDER) {\n warn(\"Ignoring additional textDivs for performance reasons.\");\n\n this.#disableProcessItems = true; // Avoid multiple warnings for one page.\n return;\n }\n\n if (item.str === undefined) {\n if (\n item.type === \"beginMarkedContentProps\" ||\n item.type === \"beginMarkedContent\"\n ) {\n const parent = this.#container;\n this.#container = document.createElement(\"span\");\n this.#container.classList.add(\"markedContent\");\n if (item.id !== null) {\n this.#container.setAttribute(\"id\", `${item.id}`);\n }\n parent.append(this.#container);\n } else if (item.type === \"endMarkedContent\") {\n this.#container = this.#container.parentNode;\n }\n continue;\n }\n textContentItemsStr.push(item.str);\n this.#appendText(item);\n }\n }\n\n #appendText(geom) {\n // Initialize all used properties to keep the caches monomorphic.\n const textDiv = document.createElement(\"span\");\n const textDivProperties = {\n angle: 0,\n canvasWidth: 0,\n hasText: geom.str !== \"\",\n hasEOL: geom.hasEOL,\n fontSize: 0,\n };\n this.#textDivs.push(textDiv);\n\n const tx = Util.transform(this.#transform, geom.transform);\n let angle = Math.atan2(tx[1], tx[0]);\n const style = this.#styleCache[geom.fontName];\n if (style.vertical) {\n angle += Math.PI / 2;\n }\n\n const fontFamily =\n (this.#fontInspectorEnabled && style.fontSubstitution) ||\n style.fontFamily;\n const fontHeight = Math.hypot(tx[2], tx[3]);\n const fontAscent =\n fontHeight * TextLayer.#getAscent(fontFamily, this.#lang);\n\n let left, top;\n if (angle === 0) {\n left = tx[4];\n top = tx[5] - fontAscent;\n } else {\n left = tx[4] + fontAscent * Math.sin(angle);\n top = tx[5] - fontAscent * Math.cos(angle);\n }\n\n const scaleFactorStr = \"calc(var(--scale-factor)*\";\n const divStyle = textDiv.style;\n // Setting the style properties individually, rather than all at once,\n // should be OK since the `textDiv` isn't appended to the document yet.\n if (this.#container === this.#rootContainer) {\n divStyle.left = `${((100 * left) / this.#pageWidth).toFixed(2)}%`;\n divStyle.top = `${((100 * top) / this.#pageHeight).toFixed(2)}%`;\n } else {\n // We're in a marked content span, hence we can't use percents.\n divStyle.left = `${scaleFactorStr}${left.toFixed(2)}px)`;\n divStyle.top = `${scaleFactorStr}${top.toFixed(2)}px)`;\n }\n divStyle.fontSize = `${scaleFactorStr}${fontHeight.toFixed(2)}px)`;\n divStyle.fontFamily = fontFamily;\n\n textDivProperties.fontSize = fontHeight;\n\n // Keeps screen readers from pausing on every new text span.\n textDiv.setAttribute(\"role\", \"presentation\");\n\n textDiv.textContent = geom.str;\n // geom.dir may be 'ttb' for vertical texts.\n textDiv.dir = geom.dir;\n\n // `fontName` is only used by the FontInspector, and we only use `dataset`\n // here to make the font name available in the debugger.\n if (this.#fontInspectorEnabled) {\n textDiv.dataset.fontName =\n style.fontSubstitutionLoadedName || geom.fontName;\n }\n if (angle !== 0) {\n textDivProperties.angle = angle * (180 / Math.PI);\n }\n // We don't bother scaling single-char text divs, because it has very\n // little effect on text highlighting. This makes scrolling on docs with\n // lots of such divs a lot faster.\n let shouldScaleText = false;\n if (geom.str.length > 1) {\n shouldScaleText = true;\n } else if (geom.str !== \" \" && geom.transform[0] !== geom.transform[3]) {\n const absScaleX = Math.abs(geom.transform[0]),\n absScaleY = Math.abs(geom.transform[3]);\n // When the horizontal/vertical scaling differs significantly, also scale\n // even single-char text to improve highlighting (fixes issue11713.pdf).\n if (\n absScaleX !== absScaleY &&\n Math.max(absScaleX, absScaleY) / Math.min(absScaleX, absScaleY) > 1.5\n ) {\n shouldScaleText = true;\n }\n }\n if (shouldScaleText) {\n textDivProperties.canvasWidth = style.vertical ? geom.height : geom.width;\n }\n this.#textDivProperties.set(textDiv, textDivProperties);\n\n // Finally, layout and append the text to the DOM.\n this.#layoutTextParams.div = textDiv;\n this.#layoutTextParams.properties = textDivProperties;\n this.#layout(this.#layoutTextParams);\n\n if (textDivProperties.hasText) {\n this.#container.append(textDiv);\n }\n if (textDivProperties.hasEOL) {\n const br = document.createElement(\"br\");\n br.setAttribute(\"role\", \"presentation\");\n this.#container.append(br);\n }\n }\n\n #layout(params) {\n const { div, properties, ctx, prevFontSize, prevFontFamily } = params;\n const { style } = div;\n let transform = \"\";\n if (properties.canvasWidth !== 0 && properties.hasText) {\n const { fontFamily } = style;\n const { canvasWidth, fontSize } = properties;\n\n if (prevFontSize !== fontSize || prevFontFamily !== fontFamily) {\n ctx.font = `${fontSize * this.#scale}px ${fontFamily}`;\n params.prevFontSize = fontSize;\n params.prevFontFamily = fontFamily;\n }\n\n // Only measure the width for multi-char text divs, see `appendText`.\n const { width } = ctx.measureText(div.textContent);\n\n if (width > 0) {\n transform = `scaleX(${(canvasWidth * this.#scale) / width})`;\n }\n }\n if (properties.angle !== 0) {\n transform = `rotate(${properties.angle}deg) ${transform}`;\n }\n if (transform.length > 0) {\n style.transform = transform;\n }\n }\n\n /**\n * Clean-up global textLayer data.\n * @returns {undefined}\n */\n static cleanup() {\n if (this.#pendingTextLayers.size > 0) {\n return;\n }\n this.#ascentCache.clear();\n\n for (const { canvas } of this.#canvasContexts.values()) {\n canvas.remove();\n }\n this.#canvasContexts.clear();\n }\n\n static #getCtx(lang = null) {\n let canvasContext = this.#canvasContexts.get((lang ||= \"\"));\n if (!canvasContext) {\n // We don't use an OffscreenCanvas here because we use serif/sans serif\n // fonts with it and they depends on the locale.\n // In Firefox, the element get a lang attribute that depends on\n // what Fluent returns for the locale and the OffscreenCanvas uses\n // the OS locale.\n // Those two locales can be different and consequently the used fonts will\n // be different (see bug 1869001).\n // Ideally, we should use in the text layer the fonts we've in the pdf (or\n // their replacements when they aren't embedded) and then we can use an\n // OffscreenCanvas.\n const canvas = document.createElement(\"canvas\");\n canvas.className = \"hiddenCanvasElement\";\n canvas.lang = lang;\n document.body.append(canvas);\n canvasContext = canvas.getContext(\"2d\", {\n alpha: false,\n willReadFrequently: true,\n });\n this.#canvasContexts.set(lang, canvasContext);\n }\n return canvasContext;\n }\n\n static #getAscent(fontFamily, lang) {\n const cachedAscent = this.#ascentCache.get(fontFamily);\n if (cachedAscent) {\n return cachedAscent;\n }\n const ctx = this.#getCtx(lang);\n\n const savedFont = ctx.font;\n ctx.canvas.width = ctx.canvas.height = DEFAULT_FONT_SIZE;\n ctx.font = `${DEFAULT_FONT_SIZE}px ${fontFamily}`;\n const metrics = ctx.measureText(\"\");\n\n // Both properties aren't available by default in Firefox.\n let ascent = metrics.fontBoundingBoxAscent;\n let descent = Math.abs(metrics.fontBoundingBoxDescent);\n if (ascent) {\n const ratio = ascent / (ascent + descent);\n this.#ascentCache.set(fontFamily, ratio);\n\n ctx.canvas.width = ctx.canvas.height = 0;\n ctx.font = savedFont;\n return ratio;\n }\n\n // Try basic heuristic to guess ascent/descent.\n // Draw a g with baseline at 0,0 and then get the line\n // number where a pixel has non-null red component (starting\n // from bottom).\n ctx.strokeStyle = \"red\";\n ctx.clearRect(0, 0, DEFAULT_FONT_SIZE, DEFAULT_FONT_SIZE);\n ctx.strokeText(\"g\", 0, 0);\n let pixels = ctx.getImageData(\n 0,\n 0,\n DEFAULT_FONT_SIZE,\n DEFAULT_FONT_SIZE\n ).data;\n descent = 0;\n for (let i = pixels.length - 1 - 3; i >= 0; i -= 4) {\n if (pixels[i] > 0) {\n descent = Math.ceil(i / 4 / DEFAULT_FONT_SIZE);\n break;\n }\n }\n\n // Draw an A with baseline at 0,DEFAULT_FONT_SIZE and then get the line\n // number where a pixel has non-null red component (starting\n // from top).\n ctx.clearRect(0, 0, DEFAULT_FONT_SIZE, DEFAULT_FONT_SIZE);\n ctx.strokeText(\"A\", 0, DEFAULT_FONT_SIZE);\n pixels = ctx.getImageData(0, 0, DEFAULT_FONT_SIZE, DEFAULT_FONT_SIZE).data;\n ascent = 0;\n for (let i = 0, ii = pixels.length; i < ii; i += 4) {\n if (pixels[i] > 0) {\n ascent = DEFAULT_FONT_SIZE - Math.floor(i / 4 / DEFAULT_FONT_SIZE);\n break;\n }\n }\n\n ctx.canvas.width = ctx.canvas.height = 0;\n ctx.font = savedFont;\n\n const ratio = ascent ? ascent / (ascent + descent) : DEFAULT_FONT_ASCENT;\n this.#ascentCache.set(fontFamily, ratio);\n return ratio;\n }\n}\n\nfunction renderTextLayer() {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n return;\n }\n deprecated(\"`renderTextLayer`, please use `TextLayer` instead.\");\n\n const { textContentSource, container, viewport, ...rest } = arguments[0];\n const restKeys = Object.keys(rest);\n if (restKeys.length > 0) {\n warn(\"Ignoring `renderTextLayer` parameters: \" + restKeys.join(\", \"));\n }\n\n const textLayer = new TextLayer({\n textContentSource,\n container,\n viewport,\n });\n\n const { textDivs, textContentItemsStr } = textLayer;\n const promise = textLayer.render();\n\n // eslint-disable-next-line consistent-return\n return {\n promise,\n textDivs,\n textContentItemsStr,\n };\n}\n\nfunction updateTextLayer() {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n return;\n }\n deprecated(\"`updateTextLayer`, please use `TextLayer` instead.\");\n}\n\nexport { renderTextLayer, TextLayer, updateTextLayer };\n","/* Copyright 2021 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/** @typedef {import(\"./api\").TextContent} TextContent */\n\nclass XfaText {\n /**\n * Walk an XFA tree and create an array of text nodes that is compatible\n * with a regular PDFs TextContent. Currently, only TextItem.str is supported,\n * all other fields and styles haven't been implemented.\n *\n * @param {Object} xfa - An XFA fake DOM object.\n *\n * @returns {TextContent}\n */\n static textContent(xfa) {\n const items = [];\n const output = {\n items,\n styles: Object.create(null),\n };\n function walk(node) {\n if (!node) {\n return;\n }\n let str = null;\n const name = node.name;\n if (name === \"#text\") {\n str = node.value;\n } else if (!XfaText.shouldBuildText(name)) {\n return;\n } else if (node?.attributes?.textContent) {\n str = node.attributes.textContent;\n } else if (node.value) {\n str = node.value;\n }\n if (str !== null) {\n items.push({\n str,\n });\n }\n if (!node.children) {\n return;\n }\n for (const child of node.children) {\n walk(child);\n }\n }\n walk(xfa);\n return output;\n }\n\n /**\n * @param {string} name - DOM node name. (lower case)\n *\n * @returns {boolean} true if the DOM node should have a corresponding text\n * node.\n */\n static shouldBuildText(name) {\n return !(\n name === \"textarea\" ||\n name === \"input\" ||\n name === \"option\" ||\n name === \"select\"\n );\n }\n}\n\nexport { XfaText };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * @module pdfjsLib\n */\n\nimport {\n AbortException,\n AnnotationMode,\n assert,\n getVerbosityLevel,\n info,\n InvalidPDFException,\n isNodeJS,\n MAX_IMAGE_SIZE_TO_CACHE,\n MissingPDFException,\n PasswordException,\n RenderingIntentFlag,\n setVerbosityLevel,\n shadow,\n stringToBytes,\n UnexpectedResponseException,\n UnknownErrorException,\n unreachable,\n warn,\n} from \"../shared/util.js\";\nimport {\n AnnotationStorage,\n PrintAnnotationStorage,\n SerializableEmpty,\n} from \"./annotation_storage.js\";\nimport {\n DOMCanvasFactory,\n DOMCMapReaderFactory,\n DOMFilterFactory,\n DOMStandardFontDataFactory,\n isDataScheme,\n isValidFetchUrl,\n PageViewport,\n RenderingCancelledException,\n StatTimer,\n} from \"./display_utils.js\";\nimport { FontFaceObject, FontLoader } from \"./font_loader.js\";\nimport {\n NodeCanvasFactory,\n NodeCMapReaderFactory,\n NodeFilterFactory,\n NodePackages,\n NodeStandardFontDataFactory,\n} from \"display-node_utils\";\nimport { CanvasGraphics } from \"./canvas.js\";\nimport { GlobalWorkerOptions } from \"./worker_options.js\";\nimport { MessageHandler } from \"../shared/message_handler.js\";\nimport { Metadata } from \"./metadata.js\";\nimport { OptionalContentConfig } from \"./optional_content_config.js\";\nimport { PDFDataTransportStream } from \"./transport_stream.js\";\nimport { PDFFetchStream } from \"display-fetch_stream\";\nimport { PDFNetworkStream } from \"display-network\";\nimport { PDFNodeStream } from \"display-node_stream\";\nimport { TextLayer } from \"./text_layer.js\";\nimport { XfaText } from \"./xfa_text.js\";\n\nconst DEFAULT_RANGE_CHUNK_SIZE = 65536; // 2^16 = 65536\nconst RENDERING_CANCELLED_TIMEOUT = 100; // ms\nconst DELAYED_CLEANUP_TIMEOUT = 5000; // ms\n\nconst DefaultCanvasFactory =\n typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"GENERIC\") && isNodeJS\n ? NodeCanvasFactory\n : DOMCanvasFactory;\nconst DefaultCMapReaderFactory =\n typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"GENERIC\") && isNodeJS\n ? NodeCMapReaderFactory\n : DOMCMapReaderFactory;\nconst DefaultFilterFactory =\n typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"GENERIC\") && isNodeJS\n ? NodeFilterFactory\n : DOMFilterFactory;\nconst DefaultStandardFontDataFactory =\n typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"GENERIC\") && isNodeJS\n ? NodeStandardFontDataFactory\n : DOMStandardFontDataFactory;\n\n/**\n * @typedef { Int8Array | Uint8Array | Uint8ClampedArray |\n * Int16Array | Uint16Array |\n * Int32Array | Uint32Array | Float32Array |\n * Float64Array\n * } TypedArray\n */\n\n/**\n * @typedef {Object} RefProxy\n * @property {number} num\n * @property {number} gen\n */\n\n/**\n * Document initialization / loading parameters object.\n *\n * @typedef {Object} DocumentInitParameters\n * @property {string | URL} [url] - The URL of the PDF.\n * @property {TypedArray | ArrayBuffer | Array | string} [data] -\n * Binary PDF data.\n * Use TypedArrays (Uint8Array) to improve the memory usage. If PDF data is\n * BASE64-encoded, use `atob()` to convert it to a binary string first.\n *\n * NOTE: If TypedArrays are used they will generally be transferred to the\n * worker-thread. This will help reduce main-thread memory usage, however\n * it will take ownership of the TypedArrays.\n * @property {Object} [httpHeaders] - Basic authentication headers.\n * @property {boolean} [withCredentials] - Indicates whether or not\n * cross-site Access-Control requests should be made using credentials such\n * as cookies or authorization headers. The default is `false`.\n * @property {string} [password] - For decrypting password-protected PDFs.\n * @property {number} [length] - The PDF file length. It's used for progress\n * reports and range requests operations.\n * @property {PDFDataRangeTransport} [range] - Allows for using a custom range\n * transport implementation.\n * @property {number} [rangeChunkSize] - Specify maximum number of bytes fetched\n * per range request. The default value is {@link DEFAULT_RANGE_CHUNK_SIZE}.\n * @property {PDFWorker} [worker] - The worker that will be used for loading and\n * parsing the PDF data.\n * @property {number} [verbosity] - Controls the logging level; the constants\n * from {@link VerbosityLevel} should be used.\n * @property {string} [docBaseUrl] - The base URL of the document, used when\n * attempting to recover valid absolute URLs for annotations, and outline\n * items, that (incorrectly) only specify relative URLs.\n * @property {string} [cMapUrl] - The URL where the predefined Adobe CMaps are\n * located. Include the trailing slash.\n * @property {boolean} [cMapPacked] - Specifies if the Adobe CMaps are binary\n * packed or not. The default value is `true`.\n * @property {Object} [CMapReaderFactory] - The factory that will be used when\n * reading built-in CMap files. Providing a custom factory is useful for\n * environments without Fetch API or `XMLHttpRequest` support, such as\n * Node.js. The default value is {DOMCMapReaderFactory}.\n * @property {boolean} [useSystemFonts] - When `true`, fonts that aren't\n * embedded in the PDF document will fallback to a system font.\n * The default value is `true` in web environments and `false` in Node.js;\n * unless `disableFontFace === true` in which case this defaults to `false`\n * regardless of the environment (to prevent completely broken fonts).\n * @property {string} [standardFontDataUrl] - The URL where the standard font\n * files are located. Include the trailing slash.\n * @property {Object} [StandardFontDataFactory] - The factory that will be used\n * when reading the standard font files. Providing a custom factory is useful\n * for environments without Fetch API or `XMLHttpRequest` support, such as\n * Node.js. The default value is {DOMStandardFontDataFactory}.\n * @property {boolean} [useWorkerFetch] - Enable using the Fetch API in the\n * worker-thread when reading CMap and standard font files. When `true`,\n * the `CMapReaderFactory` and `StandardFontDataFactory` options are ignored.\n * The default value is `true` in web environments and `false` in Node.js.\n * @property {boolean} [stopAtErrors] - Reject certain promises, e.g.\n * `getOperatorList`, `getTextContent`, and `RenderTask`, when the associated\n * PDF data cannot be successfully parsed, instead of attempting to recover\n * whatever possible of the data. The default value is `false`.\n * @property {number} [maxImageSize] - The maximum allowed image size in total\n * pixels, i.e. width * height. Images above this value will not be rendered.\n * Use -1 for no limit, which is also the default value.\n * @property {boolean} [isEvalSupported] - Determines if we can evaluate strings\n * as JavaScript. Primarily used to improve performance of PDF functions.\n * The default value is `true`.\n * @property {boolean} [isOffscreenCanvasSupported] - Determines if we can use\n * `OffscreenCanvas` in the worker. Primarily used to improve performance of\n * image conversion/rendering.\n * The default value is `true` in web environments and `false` in Node.js.\n * @property {number} [canvasMaxAreaInBytes] - The integer value is used to\n * know when an image must be resized (uses `OffscreenCanvas` in the worker).\n * If it's -1 then a possibly slow algorithm is used to guess the max value.\n * @property {boolean} [disableFontFace] - By default fonts are converted to\n * OpenType fonts and loaded via the Font Loading API or `@font-face` rules.\n * If disabled, fonts will be rendered using a built-in font renderer that\n * constructs the glyphs with primitive path commands.\n * The default value is `false` in web environments and `true` in Node.js.\n * @property {boolean} [fontExtraProperties] - Include additional properties,\n * which are unused during rendering of PDF documents, when exporting the\n * parsed font data from the worker-thread. This may be useful for debugging\n * purposes (and backwards compatibility), but note that it will lead to\n * increased memory usage. The default value is `false`.\n * @property {boolean} [enableXfa] - Render Xfa forms if any.\n * The default value is `false`.\n * @property {HTMLDocument} [ownerDocument] - Specify an explicit document\n * context to create elements with and to load resources, such as fonts,\n * into. Defaults to the current document.\n * @property {boolean} [disableRange] - Disable range request loading of PDF\n * files. When enabled, and if the server supports partial content requests,\n * then the PDF will be fetched in chunks. The default value is `false`.\n * @property {boolean} [disableStream] - Disable streaming of PDF file data.\n * By default PDF.js attempts to load PDF files in chunks. The default value\n * is `false`.\n * @property {boolean} [disableAutoFetch] - Disable pre-fetching of PDF file\n * data. When range requests are enabled PDF.js will automatically keep\n * fetching more data even if it isn't needed to display the current page.\n * The default value is `false`.\n *\n * NOTE: It is also necessary to disable streaming, see above, in order for\n * disabling of pre-fetching to work correctly.\n * @property {boolean} [pdfBug] - Enables special hooks for debugging PDF.js\n * (see `web/debugger.js`). The default value is `false`.\n * @property {Object} [canvasFactory] - The factory instance that will be used\n * when creating canvases. The default value is {new DOMCanvasFactory()}.\n * @property {Object} [filterFactory] - A factory instance that will be used\n * to create SVG filters when rendering some images on the main canvas.\n * @property {boolean} [enableHWA] - Enables hardware acceleration for\n * rendering. The default value is `false`.\n */\n\n/**\n * This is the main entry point for loading a PDF and interacting with it.\n *\n * NOTE: If a URL is used to fetch the PDF data a standard Fetch API call (or\n * XHR as fallback) is used, which means it must follow same origin rules,\n * e.g. no cross-domain requests without CORS.\n *\n * @param {string | URL | TypedArray | ArrayBuffer | DocumentInitParameters}\n * src - Can be a URL where a PDF file is located, a typed array (Uint8Array)\n * already populated with data, or a parameter object.\n * @returns {PDFDocumentLoadingTask}\n */\nfunction getDocument(src = {}) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"GENERIC\")) {\n if (typeof src === \"string\" || src instanceof URL) {\n src = { url: src };\n } else if (src instanceof ArrayBuffer || ArrayBuffer.isView(src)) {\n src = { data: src };\n }\n }\n const task = new PDFDocumentLoadingTask();\n const { docId } = task;\n\n const url = src.url ? getUrlProp(src.url) : null;\n const data = src.data ? getDataProp(src.data) : null;\n const httpHeaders = src.httpHeaders || null;\n const withCredentials = src.withCredentials === true;\n const password = src.password ?? null;\n const rangeTransport =\n src.range instanceof PDFDataRangeTransport ? src.range : null;\n const rangeChunkSize =\n Number.isInteger(src.rangeChunkSize) && src.rangeChunkSize > 0\n ? src.rangeChunkSize\n : DEFAULT_RANGE_CHUNK_SIZE;\n let worker = src.worker instanceof PDFWorker ? src.worker : null;\n const verbosity = src.verbosity;\n // Ignore \"data:\"-URLs, since they can't be used to recover valid absolute\n // URLs anyway. We want to avoid sending them to the worker-thread, since\n // they contain the *entire* PDF document and can thus be arbitrarily long.\n const docBaseUrl =\n typeof src.docBaseUrl === \"string\" && !isDataScheme(src.docBaseUrl)\n ? src.docBaseUrl\n : null;\n const cMapUrl = typeof src.cMapUrl === \"string\" ? src.cMapUrl : null;\n const cMapPacked = src.cMapPacked !== false;\n const CMapReaderFactory = src.CMapReaderFactory || DefaultCMapReaderFactory;\n const standardFontDataUrl =\n typeof src.standardFontDataUrl === \"string\"\n ? src.standardFontDataUrl\n : null;\n const StandardFontDataFactory =\n src.StandardFontDataFactory || DefaultStandardFontDataFactory;\n const ignoreErrors = src.stopAtErrors !== true;\n const maxImageSize =\n Number.isInteger(src.maxImageSize) && src.maxImageSize > -1\n ? src.maxImageSize\n : -1;\n const isEvalSupported = src.isEvalSupported !== false;\n const isOffscreenCanvasSupported =\n typeof src.isOffscreenCanvasSupported === \"boolean\"\n ? src.isOffscreenCanvasSupported\n : !isNodeJS;\n const canvasMaxAreaInBytes = Number.isInteger(src.canvasMaxAreaInBytes)\n ? src.canvasMaxAreaInBytes\n : -1;\n const disableFontFace =\n typeof src.disableFontFace === \"boolean\" ? src.disableFontFace : isNodeJS;\n const fontExtraProperties = src.fontExtraProperties === true;\n const enableXfa = src.enableXfa === true;\n const ownerDocument = src.ownerDocument || globalThis.document;\n const disableRange = src.disableRange === true;\n const disableStream = src.disableStream === true;\n const disableAutoFetch = src.disableAutoFetch === true;\n const pdfBug = src.pdfBug === true;\n const enableHWA = src.enableHWA === true;\n\n // Parameters whose default values depend on other parameters.\n const length = rangeTransport ? rangeTransport.length : src.length ?? NaN;\n const useSystemFonts =\n typeof src.useSystemFonts === \"boolean\"\n ? src.useSystemFonts\n : !isNodeJS && !disableFontFace;\n const useWorkerFetch =\n typeof src.useWorkerFetch === \"boolean\"\n ? src.useWorkerFetch\n : (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) ||\n (CMapReaderFactory === DOMCMapReaderFactory &&\n StandardFontDataFactory === DOMStandardFontDataFactory &&\n cMapUrl &&\n standardFontDataUrl &&\n isValidFetchUrl(cMapUrl, document.baseURI) &&\n isValidFetchUrl(standardFontDataUrl, document.baseURI));\n const canvasFactory =\n src.canvasFactory || new DefaultCanvasFactory({ ownerDocument, enableHWA });\n const filterFactory =\n src.filterFactory || new DefaultFilterFactory({ docId, ownerDocument });\n\n // Parameters only intended for development/testing purposes.\n const styleElement =\n typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")\n ? src.styleElement\n : null;\n\n // Set the main-thread verbosity level.\n setVerbosityLevel(verbosity);\n\n // Ensure that the various factories can be initialized, when necessary,\n // since the user may provide *custom* ones.\n const transportFactory = {\n canvasFactory,\n filterFactory,\n };\n if (!useWorkerFetch) {\n transportFactory.cMapReaderFactory = new CMapReaderFactory({\n baseUrl: cMapUrl,\n isCompressed: cMapPacked,\n });\n transportFactory.standardFontDataFactory = new StandardFontDataFactory({\n baseUrl: standardFontDataUrl,\n });\n }\n\n if (!worker) {\n const workerParams = {\n verbosity,\n port: GlobalWorkerOptions.workerPort,\n };\n // Worker was not provided -- creating and owning our own. If message port\n // is specified in global worker options, using it.\n worker = workerParams.port\n ? PDFWorker.fromPort(workerParams)\n : new PDFWorker(workerParams);\n task._worker = worker;\n }\n\n const docParams = {\n docId,\n apiVersion:\n typeof PDFJSDev !== \"undefined\" && !PDFJSDev.test(\"TESTING\")\n ? PDFJSDev.eval(\"BUNDLE_VERSION\")\n : null,\n data,\n password,\n disableAutoFetch,\n rangeChunkSize,\n length,\n docBaseUrl,\n enableXfa,\n evaluatorOptions: {\n maxImageSize,\n disableFontFace,\n ignoreErrors,\n isEvalSupported,\n isOffscreenCanvasSupported,\n canvasMaxAreaInBytes,\n fontExtraProperties,\n useSystemFonts,\n cMapUrl: useWorkerFetch ? cMapUrl : null,\n standardFontDataUrl: useWorkerFetch ? standardFontDataUrl : null,\n },\n };\n const transportParams = {\n disableFontFace,\n fontExtraProperties,\n ownerDocument,\n pdfBug,\n styleElement,\n loadingParams: {\n disableAutoFetch,\n enableXfa,\n },\n };\n\n worker.promise\n .then(function () {\n if (task.destroyed) {\n throw new Error(\"Loading aborted\");\n }\n if (worker.destroyed) {\n throw new Error(\"Worker was destroyed\");\n }\n\n const workerIdPromise = worker.messageHandler.sendWithPromise(\n \"GetDocRequest\",\n docParams,\n data ? [data.buffer] : null\n );\n\n let networkStream;\n if (rangeTransport) {\n networkStream = new PDFDataTransportStream(rangeTransport, {\n disableRange,\n disableStream,\n });\n } else if (!data) {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\"Not implemented: createPDFNetworkStream\");\n }\n if (!url) {\n throw new Error(\"getDocument - no `url` parameter provided.\");\n }\n const createPDFNetworkStream = params => {\n if (\n typeof PDFJSDev !== \"undefined\" &&\n PDFJSDev.test(\"GENERIC\") &&\n isNodeJS\n ) {\n const isFetchSupported = function () {\n return (\n typeof fetch !== \"undefined\" &&\n typeof Response !== \"undefined\" &&\n \"body\" in Response.prototype\n );\n };\n return isFetchSupported() && isValidFetchUrl(params.url)\n ? new PDFFetchStream(params)\n : new PDFNodeStream(params);\n }\n return isValidFetchUrl(params.url)\n ? new PDFFetchStream(params)\n : new PDFNetworkStream(params);\n };\n\n networkStream = createPDFNetworkStream({\n url,\n length,\n httpHeaders,\n withCredentials,\n rangeChunkSize,\n disableRange,\n disableStream,\n });\n }\n\n return workerIdPromise.then(workerId => {\n if (task.destroyed) {\n throw new Error(\"Loading aborted\");\n }\n if (worker.destroyed) {\n throw new Error(\"Worker was destroyed\");\n }\n\n const messageHandler = new MessageHandler(docId, workerId, worker.port);\n const transport = new WorkerTransport(\n messageHandler,\n task,\n networkStream,\n transportParams,\n transportFactory\n );\n task._transport = transport;\n messageHandler.send(\"Ready\", null);\n });\n })\n .catch(task._capability.reject);\n\n return task;\n}\n\nfunction getUrlProp(val) {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n return null; // The 'url' is unused with `PDFDataRangeTransport`.\n }\n if (val instanceof URL) {\n return val.href;\n }\n try {\n // The full path is required in the 'url' field.\n return new URL(val, window.location).href;\n } catch {\n if (\n typeof PDFJSDev !== \"undefined\" &&\n PDFJSDev.test(\"GENERIC\") &&\n isNodeJS &&\n typeof val === \"string\"\n ) {\n return val; // Use the url as-is in Node.js environments.\n }\n }\n throw new Error(\n \"Invalid PDF url data: \" +\n \"either string or URL-object is expected in the url property.\"\n );\n}\n\nfunction getDataProp(val) {\n // Converting string or array-like data to Uint8Array.\n if (\n typeof PDFJSDev !== \"undefined\" &&\n PDFJSDev.test(\"GENERIC\") &&\n isNodeJS &&\n typeof Buffer !== \"undefined\" && // eslint-disable-line no-undef\n val instanceof Buffer // eslint-disable-line no-undef\n ) {\n throw new Error(\n \"Please provide binary data as `Uint8Array`, rather than `Buffer`.\"\n );\n }\n if (val instanceof Uint8Array && val.byteLength === val.buffer.byteLength) {\n // Use the data as-is when it's already a Uint8Array that completely\n // \"utilizes\" its underlying ArrayBuffer, to prevent any possible\n // issues when transferring it to the worker-thread.\n return val;\n }\n if (typeof val === \"string\") {\n return stringToBytes(val);\n }\n if (\n val instanceof ArrayBuffer ||\n ArrayBuffer.isView(val) ||\n (typeof val === \"object\" && !isNaN(val?.length))\n ) {\n return new Uint8Array(val);\n }\n throw new Error(\n \"Invalid PDF binary data: either TypedArray, \" +\n \"string, or array-like object is expected in the data property.\"\n );\n}\n\nfunction isRefProxy(ref) {\n return (\n typeof ref === \"object\" &&\n Number.isInteger(ref?.num) &&\n ref.num >= 0 &&\n Number.isInteger(ref?.gen) &&\n ref.gen >= 0\n );\n}\n\n/**\n * @typedef {Object} OnProgressParameters\n * @property {number} loaded - Currently loaded number of bytes.\n * @property {number} total - Total number of bytes in the PDF file.\n */\n\n/**\n * The loading task controls the operations required to load a PDF document\n * (such as network requests) and provides a way to listen for completion,\n * after which individual pages can be rendered.\n */\nclass PDFDocumentLoadingTask {\n static #docId = 0;\n\n constructor() {\n this._capability = Promise.withResolvers();\n this._transport = null;\n this._worker = null;\n\n /**\n * Unique identifier for the document loading task.\n * @type {string}\n */\n this.docId = `d${PDFDocumentLoadingTask.#docId++}`;\n\n /**\n * Whether the loading task is destroyed or not.\n * @type {boolean}\n */\n this.destroyed = false;\n\n /**\n * Callback to request a password if a wrong or no password was provided.\n * The callback receives two parameters: a function that should be called\n * with the new password, and a reason (see {@link PasswordResponses}).\n * @type {function}\n */\n this.onPassword = null;\n\n /**\n * Callback to be able to monitor the loading progress of the PDF file\n * (necessary to implement e.g. a loading bar).\n * The callback receives an {@link OnProgressParameters} argument.\n * @type {function}\n */\n this.onProgress = null;\n }\n\n /**\n * Promise for document loading task completion.\n * @type {Promise}\n */\n get promise() {\n return this._capability.promise;\n }\n\n /**\n * Abort all network requests and destroy the worker.\n * @returns {Promise} A promise that is resolved when destruction is\n * completed.\n */\n async destroy() {\n this.destroyed = true;\n try {\n if (this._worker?.port) {\n this._worker._pendingDestroy = true;\n }\n await this._transport?.destroy();\n } catch (ex) {\n if (this._worker?.port) {\n delete this._worker._pendingDestroy;\n }\n throw ex;\n }\n\n this._transport = null;\n if (this._worker) {\n this._worker.destroy();\n this._worker = null;\n }\n }\n}\n\n/**\n * Abstract class to support range requests file loading.\n *\n * NOTE: The TypedArrays passed to the constructor and relevant methods below\n * will generally be transferred to the worker-thread. This will help reduce\n * main-thread memory usage, however it will take ownership of the TypedArrays.\n */\nclass PDFDataRangeTransport {\n /**\n * @param {number} length\n * @param {Uint8Array|null} initialData\n * @param {boolean} [progressiveDone]\n * @param {string} [contentDispositionFilename]\n */\n constructor(\n length,\n initialData,\n progressiveDone = false,\n contentDispositionFilename = null\n ) {\n this.length = length;\n this.initialData = initialData;\n this.progressiveDone = progressiveDone;\n this.contentDispositionFilename = contentDispositionFilename;\n\n this._rangeListeners = [];\n this._progressListeners = [];\n this._progressiveReadListeners = [];\n this._progressiveDoneListeners = [];\n this._readyCapability = Promise.withResolvers();\n }\n\n /**\n * @param {function} listener\n */\n addRangeListener(listener) {\n this._rangeListeners.push(listener);\n }\n\n /**\n * @param {function} listener\n */\n addProgressListener(listener) {\n this._progressListeners.push(listener);\n }\n\n /**\n * @param {function} listener\n */\n addProgressiveReadListener(listener) {\n this._progressiveReadListeners.push(listener);\n }\n\n /**\n * @param {function} listener\n */\n addProgressiveDoneListener(listener) {\n this._progressiveDoneListeners.push(listener);\n }\n\n /**\n * @param {number} begin\n * @param {Uint8Array|null} chunk\n */\n onDataRange(begin, chunk) {\n for (const listener of this._rangeListeners) {\n listener(begin, chunk);\n }\n }\n\n /**\n * @param {number} loaded\n * @param {number|undefined} total\n */\n onDataProgress(loaded, total) {\n this._readyCapability.promise.then(() => {\n for (const listener of this._progressListeners) {\n listener(loaded, total);\n }\n });\n }\n\n /**\n * @param {Uint8Array|null} chunk\n */\n onDataProgressiveRead(chunk) {\n this._readyCapability.promise.then(() => {\n for (const listener of this._progressiveReadListeners) {\n listener(chunk);\n }\n });\n }\n\n onDataProgressiveDone() {\n this._readyCapability.promise.then(() => {\n for (const listener of this._progressiveDoneListeners) {\n listener();\n }\n });\n }\n\n transportReady() {\n this._readyCapability.resolve();\n }\n\n /**\n * @param {number} begin\n * @param {number} end\n */\n requestDataRange(begin, end) {\n unreachable(\"Abstract method PDFDataRangeTransport.requestDataRange\");\n }\n\n abort() {}\n}\n\n/**\n * Proxy to a `PDFDocument` in the worker thread.\n */\nclass PDFDocumentProxy {\n constructor(pdfInfo, transport) {\n this._pdfInfo = pdfInfo;\n this._transport = transport;\n\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n // For testing purposes.\n Object.defineProperty(this, \"getNetworkStreamName\", {\n value: () => this._transport.getNetworkStreamName(),\n });\n Object.defineProperty(this, \"getXFADatasets\", {\n value: () => this._transport.getXFADatasets(),\n });\n Object.defineProperty(this, \"getXRefPrevValue\", {\n value: () => this._transport.getXRefPrevValue(),\n });\n Object.defineProperty(this, \"getStartXRefPos\", {\n value: () => this._transport.getStartXRefPos(),\n });\n Object.defineProperty(this, \"getAnnotArray\", {\n value: pageIndex => this._transport.getAnnotArray(pageIndex),\n });\n }\n }\n\n /**\n * @type {AnnotationStorage} Storage for annotation data in forms.\n */\n get annotationStorage() {\n return this._transport.annotationStorage;\n }\n\n /**\n * @type {Object} The filter factory instance.\n */\n get filterFactory() {\n return this._transport.filterFactory;\n }\n\n /**\n * @type {number} Total number of pages in the PDF file.\n */\n get numPages() {\n return this._pdfInfo.numPages;\n }\n\n /**\n * @type {Array} A (not guaranteed to be) unique ID to\n * identify the PDF document.\n * NOTE: The first element will always be defined for all PDF documents,\n * whereas the second element is only defined for *modified* PDF documents.\n */\n get fingerprints() {\n return this._pdfInfo.fingerprints;\n }\n\n /**\n * @type {boolean} True if only XFA form.\n */\n get isPureXfa() {\n return shadow(this, \"isPureXfa\", !!this._transport._htmlForXfa);\n }\n\n /**\n * NOTE: This is (mostly) intended to support printing of XFA forms.\n *\n * @type {Object | null} An object representing a HTML tree structure\n * to render the XFA, or `null` when no XFA form exists.\n */\n get allXfaHtml() {\n return this._transport._htmlForXfa;\n }\n\n /**\n * @param {number} pageNumber - The page number to get. The first page is 1.\n * @returns {Promise} A promise that is resolved with\n * a {@link PDFPageProxy} object.\n */\n getPage(pageNumber) {\n return this._transport.getPage(pageNumber);\n }\n\n /**\n * @param {RefProxy} ref - The page reference.\n * @returns {Promise} A promise that is resolved with the page index,\n * starting from zero, that is associated with the reference.\n */\n getPageIndex(ref) {\n return this._transport.getPageIndex(ref);\n }\n\n /**\n * @returns {Promise>>} A promise that is resolved\n * with a mapping from named destinations to references.\n *\n * This can be slow for large documents. Use `getDestination` instead.\n */\n getDestinations() {\n return this._transport.getDestinations();\n }\n\n /**\n * @param {string} id - The named destination to get.\n * @returns {Promise | null>} A promise that is resolved with all\n * information of the given named destination, or `null` when the named\n * destination is not present in the PDF file.\n */\n getDestination(id) {\n return this._transport.getDestination(id);\n }\n\n /**\n * @returns {Promise | null>} A promise that is resolved with\n * an {Array} containing the page labels that correspond to the page\n * indexes, or `null` when no page labels are present in the PDF file.\n */\n getPageLabels() {\n return this._transport.getPageLabels();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with a {string}\n * containing the page layout name.\n */\n getPageLayout() {\n return this._transport.getPageLayout();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with a {string}\n * containing the page mode name.\n */\n getPageMode() {\n return this._transport.getPageMode();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with an\n * {Object} containing the viewer preferences, or `null` when no viewer\n * preferences are present in the PDF file.\n */\n getViewerPreferences() {\n return this._transport.getViewerPreferences();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with an {Array}\n * containing the destination, or `null` when no open action is present\n * in the PDF.\n */\n getOpenAction() {\n return this._transport.getOpenAction();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with a lookup table\n * for mapping named attachments to their content.\n */\n getAttachments() {\n return this._transport.getAttachments();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with\n * an {Object} with the JavaScript actions:\n * - from the name tree.\n * - from A or AA entries in the catalog dictionary.\n * , or `null` if no JavaScript exists.\n */\n getJSActions() {\n return this._transport.getDocJSActions();\n }\n\n /**\n * @typedef {Object} OutlineNode\n * @property {string} title\n * @property {boolean} bold\n * @property {boolean} italic\n * @property {Uint8ClampedArray} color - The color in RGB format to use for\n * display purposes.\n * @property {string | Array | null} dest\n * @property {string | null} url\n * @property {string | undefined} unsafeUrl\n * @property {boolean | undefined} newWindow\n * @property {number | undefined} count\n * @property {Array} items\n */\n\n /**\n * @returns {Promise>} A promise that is resolved with an\n * {Array} that is a tree outline (if it has one) of the PDF file.\n */\n getOutline() {\n return this._transport.getOutline();\n }\n\n /**\n * @typedef {Object} GetOptionalContentConfigParameters\n * @property {string} [intent] - Determines the optional content groups that\n * are visible by default; valid values are:\n * - 'display' (viewable groups).\n * - 'print' (printable groups).\n * - 'any' (all groups).\n * The default value is 'display'.\n */\n\n /**\n * @param {GetOptionalContentConfigParameters} [params] - Optional content\n * config parameters.\n * @returns {Promise} A promise that is resolved with\n * an {@link OptionalContentConfig} that contains all the optional content\n * groups (assuming that the document has any).\n */\n getOptionalContentConfig({ intent = \"display\" } = {}) {\n const { renderingIntent } = this._transport.getRenderingIntent(intent);\n\n return this._transport.getOptionalContentConfig(renderingIntent);\n }\n\n /**\n * @returns {Promise | null>} A promise that is resolved with\n * an {Array} that contains the permission flags for the PDF document, or\n * `null` when no permissions are present in the PDF file.\n */\n getPermissions() {\n return this._transport.getPermissions();\n }\n\n /**\n * @returns {Promise<{ info: Object, metadata: Metadata }>} A promise that is\n * resolved with an {Object} that has `info` and `metadata` properties.\n * `info` is an {Object} filled with anything available in the information\n * dictionary and similarly `metadata` is a {Metadata} object with\n * information from the metadata section of the PDF.\n */\n getMetadata() {\n return this._transport.getMetadata();\n }\n\n /**\n * @typedef {Object} MarkInfo\n * Properties correspond to Table 321 of the PDF 32000-1:2008 spec.\n * @property {boolean} Marked\n * @property {boolean} UserProperties\n * @property {boolean} Suspects\n */\n\n /**\n * @returns {Promise} A promise that is resolved with\n * a {MarkInfo} object that contains the MarkInfo flags for the PDF\n * document, or `null` when no MarkInfo values are present in the PDF file.\n */\n getMarkInfo() {\n return this._transport.getMarkInfo();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with a\n * {Uint8Array} containing the raw data of the PDF document.\n */\n getData() {\n return this._transport.getData();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with a\n * {Uint8Array} containing the full data of the saved document.\n */\n saveDocument() {\n return this._transport.saveDocument();\n }\n\n /**\n * @returns {Promise<{ length: number }>} A promise that is resolved when the\n * document's data is loaded. It is resolved with an {Object} that contains\n * the `length` property that indicates size of the PDF data in bytes.\n */\n getDownloadInfo() {\n return this._transport.downloadInfoCapability.promise;\n }\n\n /**\n * Cleans up resources allocated by the document on both the main and worker\n * threads.\n *\n * NOTE: Do not, under any circumstances, call this method when rendering is\n * currently ongoing since that may lead to rendering errors.\n *\n * @param {boolean} [keepLoadedFonts] - Let fonts remain attached to the DOM.\n * NOTE: This will increase persistent memory usage, hence don't use this\n * option unless absolutely necessary. The default value is `false`.\n * @returns {Promise} A promise that is resolved when clean-up has finished.\n */\n cleanup(keepLoadedFonts = false) {\n return this._transport.startCleanup(keepLoadedFonts || this.isPureXfa);\n }\n\n /**\n * Destroys the current document instance and terminates the worker.\n */\n destroy() {\n return this.loadingTask.destroy();\n }\n\n /**\n * @param {RefProxy} ref - The page reference.\n * @returns {number | null} The page number, if it's cached.\n */\n cachedPageNumber(ref) {\n return this._transport.cachedPageNumber(ref);\n }\n\n /**\n * @type {DocumentInitParameters} A subset of the current\n * {DocumentInitParameters}, which are needed in the viewer.\n */\n get loadingParams() {\n return this._transport.loadingParams;\n }\n\n /**\n * @type {PDFDocumentLoadingTask} The loadingTask for the current document.\n */\n get loadingTask() {\n return this._transport.loadingTask;\n }\n\n /**\n * @returns {Promise> | null>} A promise that is\n * resolved with an {Object} containing /AcroForm field data for the JS\n * sandbox, or `null` when no field data is present in the PDF file.\n */\n getFieldObjects() {\n return this._transport.getFieldObjects();\n }\n\n /**\n * @returns {Promise} A promise that is resolved with `true`\n * if some /AcroForm fields have JavaScript actions.\n */\n hasJSActions() {\n return this._transport.hasJSActions();\n }\n\n /**\n * @returns {Promise | null>} A promise that is resolved with an\n * {Array} containing IDs of annotations that have a calculation\n * action, or `null` when no such annotations are present in the PDF file.\n */\n getCalculationOrderIds() {\n return this._transport.getCalculationOrderIds();\n }\n}\n\n/**\n * Page getViewport parameters.\n *\n * @typedef {Object} GetViewportParameters\n * @property {number} scale - The desired scale of the viewport.\n * @property {number} [rotation] - The desired rotation, in degrees, of\n * the viewport. If omitted it defaults to the page rotation.\n * @property {number} [offsetX] - The horizontal, i.e. x-axis, offset.\n * The default value is `0`.\n * @property {number} [offsetY] - The vertical, i.e. y-axis, offset.\n * The default value is `0`.\n * @property {boolean} [dontFlip] - If true, the y-axis will not be\n * flipped. The default value is `false`.\n */\n\n/**\n * Page getTextContent parameters.\n *\n * @typedef {Object} getTextContentParameters\n * @property {boolean} [includeMarkedContent] - When true include marked\n * content items in the items array of TextContent. The default is `false`.\n * @property {boolean} [disableNormalization] - When true the text is *not*\n * normalized in the worker-thread. The default is `false`.\n */\n\n/**\n * Page text content.\n *\n * @typedef {Object} TextContent\n * @property {Array} items - Array of\n * {@link TextItem} and {@link TextMarkedContent} objects. TextMarkedContent\n * items are included when includeMarkedContent is true.\n * @property {Object} styles - {@link TextStyle} objects,\n * indexed by font name.\n * @property {string | null} lang - The document /Lang attribute.\n */\n\n/**\n * Page text content part.\n *\n * @typedef {Object} TextItem\n * @property {string} str - Text content.\n * @property {string} dir - Text direction: 'ttb', 'ltr' or 'rtl'.\n * @property {Array} transform - Transformation matrix.\n * @property {number} width - Width in device space.\n * @property {number} height - Height in device space.\n * @property {string} fontName - Font name used by PDF.js for converted font.\n * @property {boolean} hasEOL - Indicating if the text content is followed by a\n * line-break.\n */\n\n/**\n * Page text marked content part.\n *\n * @typedef {Object} TextMarkedContent\n * @property {string} type - Either 'beginMarkedContent',\n * 'beginMarkedContentProps', or 'endMarkedContent'.\n * @property {string} id - The marked content identifier. Only used for type\n * 'beginMarkedContentProps'.\n */\n\n/**\n * Text style.\n *\n * @typedef {Object} TextStyle\n * @property {number} ascent - Font ascent.\n * @property {number} descent - Font descent.\n * @property {boolean} vertical - Whether or not the text is in vertical mode.\n * @property {string} fontFamily - The possible font family.\n */\n\n/**\n * Page annotation parameters.\n *\n * @typedef {Object} GetAnnotationsParameters\n * @property {string} [intent] - Determines the annotations that are fetched,\n * can be 'display' (viewable annotations), 'print' (printable annotations),\n * or 'any' (all annotations). The default value is 'display'.\n */\n\n/**\n * Page render parameters.\n *\n * @typedef {Object} RenderParameters\n * @property {CanvasRenderingContext2D} canvasContext - A 2D context of a DOM\n * Canvas object.\n * @property {PageViewport} viewport - Rendering viewport obtained by calling\n * the `PDFPageProxy.getViewport` method.\n * @property {string} [intent] - Rendering intent, can be 'display', 'print',\n * or 'any'. The default value is 'display'.\n * @property {number} [annotationMode] Controls which annotations are rendered\n * onto the canvas, for annotations with appearance-data; the values from\n * {@link AnnotationMode} should be used. The following values are supported:\n * - `AnnotationMode.DISABLE`, which disables all annotations.\n * - `AnnotationMode.ENABLE`, which includes all possible annotations (thus\n * it also depends on the `intent`-option, see above).\n * - `AnnotationMode.ENABLE_FORMS`, which excludes annotations that contain\n * interactive form elements (those will be rendered in the display layer).\n * - `AnnotationMode.ENABLE_STORAGE`, which includes all possible annotations\n * (as above) but where interactive form elements are updated with data\n * from the {@link AnnotationStorage}-instance; useful e.g. for printing.\n * The default value is `AnnotationMode.ENABLE`.\n * @property {Array} [transform] - Additional transform, applied just\n * before viewport transform.\n * @property {CanvasGradient | CanvasPattern | string} [background] - Background\n * to use for the canvas.\n * Any valid `canvas.fillStyle` can be used: a `DOMString` parsed as CSS\n * value, a `CanvasGradient` object (a linear or radial gradient) or\n * a `CanvasPattern` object (a repetitive image). The default value is\n * 'rgb(255,255,255)'.\n *\n * NOTE: This option may be partially, or completely, ignored when the\n * `pageColors`-option is used.\n * @property {Object} [pageColors] - Overwrites background and foreground colors\n * with user defined ones in order to improve readability in high contrast\n * mode.\n * @property {Promise} [optionalContentConfigPromise] -\n * A promise that should resolve with an {@link OptionalContentConfig}\n * created from `PDFDocumentProxy.getOptionalContentConfig`. If `null`,\n * the configuration will be fetched automatically with the default visibility\n * states set.\n * @property {Map} [annotationCanvasMap] - Map some\n * annotation ids with canvases used to render them.\n * @property {PrintAnnotationStorage} [printAnnotationStorage]\n */\n\n/**\n * Page getOperatorList parameters.\n *\n * @typedef {Object} GetOperatorListParameters\n * @property {string} [intent] - Rendering intent, can be 'display', 'print',\n * or 'any'. The default value is 'display'.\n * @property {number} [annotationMode] Controls which annotations are included\n * in the operatorList, for annotations with appearance-data; the values from\n * {@link AnnotationMode} should be used. The following values are supported:\n * - `AnnotationMode.DISABLE`, which disables all annotations.\n * - `AnnotationMode.ENABLE`, which includes all possible annotations (thus\n * it also depends on the `intent`-option, see above).\n * - `AnnotationMode.ENABLE_FORMS`, which excludes annotations that contain\n * interactive form elements (those will be rendered in the display layer).\n * - `AnnotationMode.ENABLE_STORAGE`, which includes all possible annotations\n * (as above) but where interactive form elements are updated with data\n * from the {@link AnnotationStorage}-instance; useful e.g. for printing.\n * The default value is `AnnotationMode.ENABLE`.\n * @property {PrintAnnotationStorage} [printAnnotationStorage]\n */\n\n/**\n * Structure tree node. The root node will have a role \"Root\".\n *\n * @typedef {Object} StructTreeNode\n * @property {Array} children - Array of\n * {@link StructTreeNode} and {@link StructTreeContent} objects.\n * @property {string} role - element's role, already mapped if a role map exists\n * in the PDF.\n */\n\n/**\n * Structure tree content.\n *\n * @typedef {Object} StructTreeContent\n * @property {string} type - either \"content\" for page and stream structure\n * elements or \"object\" for object references.\n * @property {string} id - unique id that will map to the text layer.\n */\n\n/**\n * PDF page operator list.\n *\n * @typedef {Object} PDFOperatorList\n * @property {Array} fnArray - Array containing the operator functions.\n * @property {Array} argsArray - Array containing the arguments of the\n * functions.\n */\n\n/**\n * Proxy to a `PDFPage` in the worker thread.\n */\nclass PDFPageProxy {\n #delayedCleanupTimeout = null;\n\n #pendingCleanup = false;\n\n constructor(pageIndex, pageInfo, transport, pdfBug = false) {\n this._pageIndex = pageIndex;\n this._pageInfo = pageInfo;\n this._transport = transport;\n this._stats = pdfBug ? new StatTimer() : null;\n this._pdfBug = pdfBug;\n /** @type {PDFObjects} */\n this.commonObjs = transport.commonObjs;\n this.objs = new PDFObjects();\n\n this._maybeCleanupAfterRender = false;\n this._intentStates = new Map();\n this.destroyed = false;\n }\n\n /**\n * @type {number} Page number of the page. First page is 1.\n */\n get pageNumber() {\n return this._pageIndex + 1;\n }\n\n /**\n * @type {number} The number of degrees the page is rotated clockwise.\n */\n get rotate() {\n return this._pageInfo.rotate;\n }\n\n /**\n * @type {RefProxy | null} The reference that points to this page.\n */\n get ref() {\n return this._pageInfo.ref;\n }\n\n /**\n * @type {number} The default size of units in 1/72nds of an inch.\n */\n get userUnit() {\n return this._pageInfo.userUnit;\n }\n\n /**\n * @type {Array} An array of the visible portion of the PDF page in\n * user space units [x1, y1, x2, y2].\n */\n get view() {\n return this._pageInfo.view;\n }\n\n /**\n * @param {GetViewportParameters} params - Viewport parameters.\n * @returns {PageViewport} Contains 'width' and 'height' properties\n * along with transforms required for rendering.\n */\n getViewport({\n scale,\n rotation = this.rotate,\n offsetX = 0,\n offsetY = 0,\n dontFlip = false,\n } = {}) {\n return new PageViewport({\n viewBox: this.view,\n scale,\n rotation,\n offsetX,\n offsetY,\n dontFlip,\n });\n }\n\n /**\n * @param {GetAnnotationsParameters} [params] - Annotation parameters.\n * @returns {Promise>} A promise that is resolved with an\n * {Array} of the annotation objects.\n */\n getAnnotations({ intent = \"display\" } = {}) {\n const { renderingIntent } = this._transport.getRenderingIntent(intent);\n\n return this._transport.getAnnotations(this._pageIndex, renderingIntent);\n }\n\n /**\n * @returns {Promise} A promise that is resolved with an\n * {Object} with JS actions.\n */\n getJSActions() {\n return this._transport.getPageJSActions(this._pageIndex);\n }\n\n /**\n * @type {Object} The filter factory instance.\n */\n get filterFactory() {\n return this._transport.filterFactory;\n }\n\n /**\n * @type {boolean} True if only XFA form.\n */\n get isPureXfa() {\n return shadow(this, \"isPureXfa\", !!this._transport._htmlForXfa);\n }\n\n /**\n * @returns {Promise} A promise that is resolved with\n * an {Object} with a fake DOM object (a tree structure where elements\n * are {Object} with a name, attributes (class, style, ...), value and\n * children, very similar to a HTML DOM tree), or `null` if no XFA exists.\n */\n async getXfa() {\n return this._transport._htmlForXfa?.children[this._pageIndex] || null;\n }\n\n /**\n * Begins the process of rendering a page to the desired context.\n *\n * @param {RenderParameters} params - Page render parameters.\n * @returns {RenderTask} An object that contains a promise that is\n * resolved when the page finishes rendering.\n */\n render({\n canvasContext,\n viewport,\n intent = \"display\",\n annotationMode = AnnotationMode.ENABLE,\n transform = null,\n background = null,\n optionalContentConfigPromise = null,\n annotationCanvasMap = null,\n pageColors = null,\n printAnnotationStorage = null,\n }) {\n this._stats?.time(\"Overall\");\n\n const intentArgs = this._transport.getRenderingIntent(\n intent,\n annotationMode,\n printAnnotationStorage\n );\n const { renderingIntent, cacheKey } = intentArgs;\n // If there was a pending destroy, cancel it so no cleanup happens during\n // this call to render...\n this.#pendingCleanup = false;\n // ... and ensure that a delayed cleanup is always aborted.\n this.#abortDelayedCleanup();\n\n optionalContentConfigPromise ||=\n this._transport.getOptionalContentConfig(renderingIntent);\n\n let intentState = this._intentStates.get(cacheKey);\n if (!intentState) {\n intentState = Object.create(null);\n this._intentStates.set(cacheKey, intentState);\n }\n\n // Ensure that a pending `streamReader` cancel timeout is always aborted.\n if (intentState.streamReaderCancelTimeout) {\n clearTimeout(intentState.streamReaderCancelTimeout);\n intentState.streamReaderCancelTimeout = null;\n }\n\n const intentPrint = !!(renderingIntent & RenderingIntentFlag.PRINT);\n\n // If there's no displayReadyCapability yet, then the operatorList\n // was never requested before. Make the request and create the promise.\n if (!intentState.displayReadyCapability) {\n intentState.displayReadyCapability = Promise.withResolvers();\n intentState.operatorList = {\n fnArray: [],\n argsArray: [],\n lastChunk: false,\n separateAnnots: null,\n };\n\n this._stats?.time(\"Page Request\");\n this._pumpOperatorList(intentArgs);\n }\n\n const complete = error => {\n intentState.renderTasks.delete(internalRenderTask);\n\n // Attempt to reduce memory usage during *printing*, by always running\n // cleanup immediately once rendering has finished.\n if (this._maybeCleanupAfterRender || intentPrint) {\n this.#pendingCleanup = true;\n }\n this.#tryCleanup(/* delayed = */ !intentPrint);\n\n if (error) {\n internalRenderTask.capability.reject(error);\n\n this._abortOperatorList({\n intentState,\n reason: error instanceof Error ? error : new Error(error),\n });\n } else {\n internalRenderTask.capability.resolve();\n }\n\n if (this._stats) {\n this._stats.timeEnd(\"Rendering\");\n this._stats.timeEnd(\"Overall\");\n\n if (globalThis.Stats?.enabled) {\n globalThis.Stats.add(this.pageNumber, this._stats);\n }\n }\n };\n\n const internalRenderTask = new InternalRenderTask({\n callback: complete,\n // Only include the required properties, and *not* the entire object.\n params: {\n canvasContext,\n viewport,\n transform,\n background,\n },\n objs: this.objs,\n commonObjs: this.commonObjs,\n annotationCanvasMap,\n operatorList: intentState.operatorList,\n pageIndex: this._pageIndex,\n canvasFactory: this._transport.canvasFactory,\n filterFactory: this._transport.filterFactory,\n useRequestAnimationFrame: !intentPrint,\n pdfBug: this._pdfBug,\n pageColors,\n });\n\n (intentState.renderTasks ||= new Set()).add(internalRenderTask);\n const renderTask = internalRenderTask.task;\n\n Promise.all([\n intentState.displayReadyCapability.promise,\n optionalContentConfigPromise,\n ])\n .then(([transparency, optionalContentConfig]) => {\n if (this.destroyed) {\n complete();\n return;\n }\n this._stats?.time(\"Rendering\");\n\n if (!(optionalContentConfig.renderingIntent & renderingIntent)) {\n throw new Error(\n \"Must use the same `intent`-argument when calling the `PDFPageProxy.render` \" +\n \"and `PDFDocumentProxy.getOptionalContentConfig` methods.\"\n );\n }\n internalRenderTask.initializeGraphics({\n transparency,\n optionalContentConfig,\n });\n internalRenderTask.operatorListChanged();\n })\n .catch(complete);\n\n return renderTask;\n }\n\n /**\n * @param {GetOperatorListParameters} params - Page getOperatorList\n * parameters.\n * @returns {Promise} A promise resolved with an\n * {@link PDFOperatorList} object that represents the page's operator list.\n */\n getOperatorList({\n intent = \"display\",\n annotationMode = AnnotationMode.ENABLE,\n printAnnotationStorage = null,\n } = {}) {\n if (typeof PDFJSDev !== \"undefined\" && !PDFJSDev.test(\"GENERIC\")) {\n throw new Error(\"Not implemented: getOperatorList\");\n }\n function operatorListChanged() {\n if (intentState.operatorList.lastChunk) {\n intentState.opListReadCapability.resolve(intentState.operatorList);\n\n intentState.renderTasks.delete(opListTask);\n }\n }\n\n const intentArgs = this._transport.getRenderingIntent(\n intent,\n annotationMode,\n printAnnotationStorage,\n /* isOpList = */ true\n );\n let intentState = this._intentStates.get(intentArgs.cacheKey);\n if (!intentState) {\n intentState = Object.create(null);\n this._intentStates.set(intentArgs.cacheKey, intentState);\n }\n let opListTask;\n\n if (!intentState.opListReadCapability) {\n opListTask = Object.create(null);\n opListTask.operatorListChanged = operatorListChanged;\n intentState.opListReadCapability = Promise.withResolvers();\n (intentState.renderTasks ||= new Set()).add(opListTask);\n intentState.operatorList = {\n fnArray: [],\n argsArray: [],\n lastChunk: false,\n separateAnnots: null,\n };\n\n this._stats?.time(\"Page Request\");\n this._pumpOperatorList(intentArgs);\n }\n return intentState.opListReadCapability.promise;\n }\n\n /**\n * NOTE: All occurrences of whitespace will be replaced by\n * standard spaces (0x20).\n *\n * @param {getTextContentParameters} params - getTextContent parameters.\n * @returns {ReadableStream} Stream for reading text content chunks.\n */\n streamTextContent({\n includeMarkedContent = false,\n disableNormalization = false,\n } = {}) {\n const TEXT_CONTENT_CHUNK_SIZE = 100;\n\n return this._transport.messageHandler.sendWithStream(\n \"GetTextContent\",\n {\n pageIndex: this._pageIndex,\n includeMarkedContent: includeMarkedContent === true,\n disableNormalization: disableNormalization === true,\n },\n {\n highWaterMark: TEXT_CONTENT_CHUNK_SIZE,\n size(textContent) {\n return textContent.items.length;\n },\n }\n );\n }\n\n /**\n * NOTE: All occurrences of whitespace will be replaced by\n * standard spaces (0x20).\n *\n * @param {getTextContentParameters} params - getTextContent parameters.\n * @returns {Promise} A promise that is resolved with a\n * {@link TextContent} object that represents the page's text content.\n */\n getTextContent(params = {}) {\n if (this._transport._htmlForXfa) {\n // TODO: We need to revisit this once the XFA foreground patch lands and\n // only do this for non-foreground XFA.\n return this.getXfa().then(xfa => XfaText.textContent(xfa));\n }\n const readableStream = this.streamTextContent(params);\n\n return new Promise(function (resolve, reject) {\n function pump() {\n reader.read().then(function ({ value, done }) {\n if (done) {\n resolve(textContent);\n return;\n }\n textContent.lang ??= value.lang;\n Object.assign(textContent.styles, value.styles);\n textContent.items.push(...value.items);\n pump();\n }, reject);\n }\n\n const reader = readableStream.getReader();\n const textContent = {\n items: [],\n styles: Object.create(null),\n lang: null,\n };\n pump();\n });\n }\n\n /**\n * @returns {Promise} A promise that is resolved with a\n * {@link StructTreeNode} object that represents the page's structure tree,\n * or `null` when no structure tree is present for the current page.\n */\n getStructTree() {\n return this._transport.getStructTree(this._pageIndex);\n }\n\n /**\n * Destroys the page object.\n * @private\n */\n _destroy() {\n this.destroyed = true;\n\n const waitOn = [];\n for (const intentState of this._intentStates.values()) {\n this._abortOperatorList({\n intentState,\n reason: new Error(\"Page was destroyed.\"),\n force: true,\n });\n\n if (intentState.opListReadCapability) {\n // Avoid errors below, since the renderTasks are just stubs.\n continue;\n }\n for (const internalRenderTask of intentState.renderTasks) {\n waitOn.push(internalRenderTask.completed);\n internalRenderTask.cancel();\n }\n }\n this.objs.clear();\n this.#pendingCleanup = false;\n this.#abortDelayedCleanup();\n\n return Promise.all(waitOn);\n }\n\n /**\n * Cleans up resources allocated by the page.\n *\n * @param {boolean} [resetStats] - Reset page stats, if enabled.\n * The default value is `false`.\n * @returns {boolean} Indicates if clean-up was successfully run.\n */\n cleanup(resetStats = false) {\n this.#pendingCleanup = true;\n const success = this.#tryCleanup(/* delayed = */ false);\n\n if (resetStats && success) {\n this._stats &&= new StatTimer();\n }\n return success;\n }\n\n /**\n * Attempts to clean up if rendering is in a state where that's possible.\n * @param {boolean} [delayed] - Delay the cleanup, to e.g. improve zooming\n * performance in documents with large images.\n * The default value is `false`.\n * @returns {boolean} Indicates if clean-up was successfully run.\n */\n #tryCleanup(delayed = false) {\n this.#abortDelayedCleanup();\n\n if (!this.#pendingCleanup || this.destroyed) {\n return false;\n }\n if (delayed) {\n this.#delayedCleanupTimeout = setTimeout(() => {\n this.#delayedCleanupTimeout = null;\n this.#tryCleanup(/* delayed = */ false);\n }, DELAYED_CLEANUP_TIMEOUT);\n\n return false;\n }\n for (const { renderTasks, operatorList } of this._intentStates.values()) {\n if (renderTasks.size > 0 || !operatorList.lastChunk) {\n return false;\n }\n }\n this._intentStates.clear();\n this.objs.clear();\n this.#pendingCleanup = false;\n return true;\n }\n\n #abortDelayedCleanup() {\n if (this.#delayedCleanupTimeout) {\n clearTimeout(this.#delayedCleanupTimeout);\n this.#delayedCleanupTimeout = null;\n }\n }\n\n /**\n * @private\n */\n _startRenderPage(transparency, cacheKey) {\n const intentState = this._intentStates.get(cacheKey);\n if (!intentState) {\n return; // Rendering was cancelled.\n }\n this._stats?.timeEnd(\"Page Request\");\n\n // TODO Refactor RenderPageRequest to separate rendering\n // and operator list logic\n intentState.displayReadyCapability?.resolve(transparency);\n }\n\n /**\n * @private\n */\n _renderPageChunk(operatorListChunk, intentState) {\n // Add the new chunk to the current operator list.\n for (let i = 0, ii = operatorListChunk.length; i < ii; i++) {\n intentState.operatorList.fnArray.push(operatorListChunk.fnArray[i]);\n intentState.operatorList.argsArray.push(operatorListChunk.argsArray[i]);\n }\n intentState.operatorList.lastChunk = operatorListChunk.lastChunk;\n intentState.operatorList.separateAnnots = operatorListChunk.separateAnnots;\n\n // Notify all the rendering tasks there are more operators to be consumed.\n for (const internalRenderTask of intentState.renderTasks) {\n internalRenderTask.operatorListChanged();\n }\n\n if (operatorListChunk.lastChunk) {\n this.#tryCleanup(/* delayed = */ true);\n }\n }\n\n /**\n * @private\n */\n _pumpOperatorList({\n renderingIntent,\n cacheKey,\n annotationStorageSerializable,\n }) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n Number.isInteger(renderingIntent) && renderingIntent > 0,\n '_pumpOperatorList: Expected valid \"renderingIntent\" argument.'\n );\n }\n const { map, transfer } = annotationStorageSerializable;\n\n const readableStream = this._transport.messageHandler.sendWithStream(\n \"GetOperatorList\",\n {\n pageIndex: this._pageIndex,\n intent: renderingIntent,\n cacheKey,\n annotationStorage: map,\n },\n transfer\n );\n const reader = readableStream.getReader();\n\n const intentState = this._intentStates.get(cacheKey);\n intentState.streamReader = reader;\n\n const pump = () => {\n reader.read().then(\n ({ value, done }) => {\n if (done) {\n intentState.streamReader = null;\n return;\n }\n if (this._transport.destroyed) {\n return; // Ignore any pending requests if the worker was terminated.\n }\n this._renderPageChunk(value, intentState);\n pump();\n },\n reason => {\n intentState.streamReader = null;\n\n if (this._transport.destroyed) {\n return; // Ignore any pending requests if the worker was terminated.\n }\n if (intentState.operatorList) {\n // Mark operator list as complete.\n intentState.operatorList.lastChunk = true;\n\n for (const internalRenderTask of intentState.renderTasks) {\n internalRenderTask.operatorListChanged();\n }\n this.#tryCleanup(/* delayed = */ true);\n }\n\n if (intentState.displayReadyCapability) {\n intentState.displayReadyCapability.reject(reason);\n } else if (intentState.opListReadCapability) {\n intentState.opListReadCapability.reject(reason);\n } else {\n throw reason;\n }\n }\n );\n };\n pump();\n }\n\n /**\n * @private\n */\n _abortOperatorList({ intentState, reason, force = false }) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n reason instanceof Error,\n '_abortOperatorList: Expected valid \"reason\" argument.'\n );\n }\n\n if (!intentState.streamReader) {\n return;\n }\n // Ensure that a pending `streamReader` cancel timeout is always aborted.\n if (intentState.streamReaderCancelTimeout) {\n clearTimeout(intentState.streamReaderCancelTimeout);\n intentState.streamReaderCancelTimeout = null;\n }\n\n if (!force) {\n // Ensure that an Error occurring in *only* one `InternalRenderTask`, e.g.\n // multiple render() calls on the same canvas, won't break all rendering.\n if (intentState.renderTasks.size > 0) {\n return;\n }\n // Don't immediately abort parsing on the worker-thread when rendering is\n // cancelled, since that will unnecessarily delay re-rendering when (for\n // partially parsed pages) e.g. zooming/rotation occurs in the viewer.\n if (reason instanceof RenderingCancelledException) {\n let delay = RENDERING_CANCELLED_TIMEOUT;\n if (reason.extraDelay > 0 && reason.extraDelay < /* ms = */ 1000) {\n // Above, we prevent the total delay from becoming arbitrarily large.\n delay += reason.extraDelay;\n }\n\n intentState.streamReaderCancelTimeout = setTimeout(() => {\n intentState.streamReaderCancelTimeout = null;\n this._abortOperatorList({ intentState, reason, force: true });\n }, delay);\n return;\n }\n }\n intentState.streamReader\n .cancel(new AbortException(reason.message))\n .catch(() => {\n // Avoid \"Uncaught promise\" messages in the console.\n });\n intentState.streamReader = null;\n\n if (this._transport.destroyed) {\n return; // Ignore any pending requests if the worker was terminated.\n }\n // Remove the current `intentState`, since a cancelled `getOperatorList`\n // call on the worker-thread cannot be re-started...\n for (const [curCacheKey, curIntentState] of this._intentStates) {\n if (curIntentState === intentState) {\n this._intentStates.delete(curCacheKey);\n break;\n }\n }\n // ... and force clean-up to ensure that any old state is always removed.\n this.cleanup();\n }\n\n /**\n * @type {StatTimer | null} Returns page stats, if enabled; returns `null`\n * otherwise.\n */\n get stats() {\n return this._stats;\n }\n}\n\nclass LoopbackPort {\n #listeners = new Set();\n\n #deferred = Promise.resolve();\n\n postMessage(obj, transfer) {\n const event = {\n data: structuredClone(obj, transfer ? { transfer } : null),\n };\n\n this.#deferred.then(() => {\n for (const listener of this.#listeners) {\n listener.call(this, event);\n }\n });\n }\n\n addEventListener(name, listener) {\n this.#listeners.add(listener);\n }\n\n removeEventListener(name, listener) {\n this.#listeners.delete(listener);\n }\n\n terminate() {\n this.#listeners.clear();\n }\n}\n\n/**\n * @typedef {Object} PDFWorkerParameters\n * @property {string} [name] - The name of the worker.\n * @property {Worker} [port] - The `workerPort` object.\n * @property {number} [verbosity] - Controls the logging level;\n * the constants from {@link VerbosityLevel} should be used.\n */\n\nconst PDFWorkerUtil = {\n isWorkerDisabled: false,\n fakeWorkerId: 0,\n};\nif (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"GENERIC\")) {\n if (isNodeJS) {\n // Workers aren't supported in Node.js, force-disabling them there.\n PDFWorkerUtil.isWorkerDisabled = true;\n\n GlobalWorkerOptions.workerSrc ||= PDFJSDev.test(\"LIB\")\n ? \"../pdf.worker.js\"\n : \"./pdf.worker.mjs\";\n }\n\n // Check if URLs have the same origin. For non-HTTP based URLs, returns false.\n PDFWorkerUtil.isSameOrigin = function (baseUrl, otherUrl) {\n let base;\n try {\n base = new URL(baseUrl);\n if (!base.origin || base.origin === \"null\") {\n return false; // non-HTTP url\n }\n } catch {\n return false;\n }\n\n const other = new URL(otherUrl, base);\n return base.origin === other.origin;\n };\n\n PDFWorkerUtil.createCDNWrapper = function (url) {\n // We will rely on blob URL's property to specify origin.\n // We want this function to fail in case if createObjectURL or Blob do not\n // exist or fail for some reason -- our Worker creation will fail anyway.\n const wrapper = `await import(\"${url}\");`;\n return URL.createObjectURL(\n new Blob([wrapper], { type: \"text/javascript\" })\n );\n };\n}\n\n/**\n * PDF.js web worker abstraction that controls the instantiation of PDF\n * documents. Message handlers are used to pass information from the main\n * thread to the worker thread and vice versa. If the creation of a web\n * worker is not possible, a \"fake\" worker will be used instead.\n *\n * @param {PDFWorkerParameters} params - The worker initialization parameters.\n */\nclass PDFWorker {\n static #workerPorts;\n\n constructor({\n name = null,\n port = null,\n verbosity = getVerbosityLevel(),\n } = {}) {\n this.name = name;\n this.destroyed = false;\n this.verbosity = verbosity;\n\n this._readyCapability = Promise.withResolvers();\n this._port = null;\n this._webWorker = null;\n this._messageHandler = null;\n\n if (\n (typeof PDFJSDev === \"undefined\" || !PDFJSDev.test(\"MOZCENTRAL\")) &&\n port\n ) {\n if (PDFWorker.#workerPorts?.has(port)) {\n throw new Error(\"Cannot use more than one PDFWorker per port.\");\n }\n (PDFWorker.#workerPorts ||= new WeakMap()).set(port, this);\n this._initializeFromPort(port);\n return;\n }\n this._initialize();\n }\n\n /**\n * Promise for worker initialization completion.\n * @type {Promise}\n */\n get promise() {\n if (\n typeof PDFJSDev !== \"undefined\" &&\n PDFJSDev.test(\"GENERIC\") &&\n isNodeJS\n ) {\n // Ensure that all Node.js packages/polyfills have loaded.\n return Promise.all([NodePackages.promise, this._readyCapability.promise]);\n }\n return this._readyCapability.promise;\n }\n\n #resolve() {\n this._readyCapability.resolve();\n // Send global setting, e.g. verbosity level.\n this._messageHandler.send(\"configure\", {\n verbosity: this.verbosity,\n });\n }\n\n /**\n * The current `workerPort`, when it exists.\n * @type {Worker}\n */\n get port() {\n return this._port;\n }\n\n /**\n * The current MessageHandler-instance.\n * @type {MessageHandler}\n */\n get messageHandler() {\n return this._messageHandler;\n }\n\n _initializeFromPort(port) {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\"Not implemented: _initializeFromPort\");\n }\n this._port = port;\n this._messageHandler = new MessageHandler(\"main\", \"worker\", port);\n this._messageHandler.on(\"ready\", function () {\n // Ignoring \"ready\" event -- MessageHandler should already be initialized\n // and ready to accept messages.\n });\n this.#resolve();\n }\n\n _initialize() {\n // If worker support isn't disabled explicit and the browser has worker\n // support, create a new web worker and test if it/the browser fulfills\n // all requirements to run parts of pdf.js in a web worker.\n // Right now, the requirement is, that an Uint8Array is still an\n // Uint8Array as it arrives on the worker.\n if (\n PDFWorkerUtil.isWorkerDisabled ||\n PDFWorker.#mainThreadWorkerMessageHandler\n ) {\n this._setupFakeWorker();\n return;\n }\n let { workerSrc } = PDFWorker;\n\n try {\n // Wraps workerSrc path into blob URL, if the former does not belong\n // to the same origin.\n if (\n typeof PDFJSDev !== \"undefined\" &&\n PDFJSDev.test(\"GENERIC\") &&\n !PDFWorkerUtil.isSameOrigin(window.location.href, workerSrc)\n ) {\n workerSrc = PDFWorkerUtil.createCDNWrapper(\n new URL(workerSrc, window.location).href\n );\n }\n\n const worker = new Worker(workerSrc, { type: \"module\" });\n const messageHandler = new MessageHandler(\"main\", \"worker\", worker);\n const terminateEarly = () => {\n ac.abort();\n messageHandler.destroy();\n worker.terminate();\n if (this.destroyed) {\n this._readyCapability.reject(new Error(\"Worker was destroyed\"));\n } else {\n // Fall back to fake worker if the termination is caused by an\n // error (e.g. NetworkError / SecurityError).\n this._setupFakeWorker();\n }\n };\n\n const ac = new AbortController();\n worker.addEventListener(\n \"error\",\n () => {\n if (!this._webWorker) {\n // Worker failed to initialize due to an error. Clean up and fall\n // back to the fake worker.\n terminateEarly();\n }\n },\n { signal: ac.signal }\n );\n\n messageHandler.on(\"test\", data => {\n ac.abort();\n if (this.destroyed || !data) {\n terminateEarly();\n return;\n }\n this._messageHandler = messageHandler;\n this._port = worker;\n this._webWorker = worker;\n\n this.#resolve();\n });\n\n messageHandler.on(\"ready\", data => {\n ac.abort();\n if (this.destroyed) {\n terminateEarly();\n return;\n }\n try {\n sendTest();\n } catch {\n // We need fallback to a faked worker.\n this._setupFakeWorker();\n }\n });\n\n const sendTest = () => {\n const testObj = new Uint8Array();\n // Ensure that we can use `postMessage` transfers.\n messageHandler.send(\"test\", testObj, [testObj.buffer]);\n };\n\n // It might take time for the worker to initialize. We will try to send\n // the \"test\" message immediately, and once the \"ready\" message arrives.\n // The worker shall process only the first received \"test\" message.\n sendTest();\n return;\n } catch {\n info(\"The worker has been disabled.\");\n }\n // Either workers are not supported or have thrown an exception.\n // Thus, we fallback to a faked worker.\n this._setupFakeWorker();\n }\n\n _setupFakeWorker() {\n if (!PDFWorkerUtil.isWorkerDisabled) {\n warn(\"Setting up fake worker.\");\n PDFWorkerUtil.isWorkerDisabled = true;\n }\n\n PDFWorker._setupFakeWorkerGlobal\n .then(WorkerMessageHandler => {\n if (this.destroyed) {\n this._readyCapability.reject(new Error(\"Worker was destroyed\"));\n return;\n }\n const port = new LoopbackPort();\n this._port = port;\n\n // All fake workers use the same port, making id unique.\n const id = `fake${PDFWorkerUtil.fakeWorkerId++}`;\n\n // If the main thread is our worker, setup the handling for the\n // messages -- the main thread sends to it self.\n const workerHandler = new MessageHandler(id + \"_worker\", id, port);\n WorkerMessageHandler.setup(workerHandler, port);\n\n this._messageHandler = new MessageHandler(id, id + \"_worker\", port);\n this.#resolve();\n })\n .catch(reason => {\n this._readyCapability.reject(\n new Error(`Setting up fake worker failed: \"${reason.message}\".`)\n );\n });\n }\n\n /**\n * Destroys the worker instance.\n */\n destroy() {\n this.destroyed = true;\n if (this._webWorker) {\n // We need to terminate only web worker created resource.\n this._webWorker.terminate();\n this._webWorker = null;\n }\n PDFWorker.#workerPorts?.delete(this._port);\n this._port = null;\n if (this._messageHandler) {\n this._messageHandler.destroy();\n this._messageHandler = null;\n }\n }\n\n /**\n * @param {PDFWorkerParameters} params - The worker initialization parameters.\n */\n static fromPort(params) {\n if (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) {\n throw new Error(\"Not implemented: fromPort\");\n }\n if (!params?.port) {\n throw new Error(\"PDFWorker.fromPort - invalid method signature.\");\n }\n const cachedPort = this.#workerPorts?.get(params.port);\n if (cachedPort) {\n if (cachedPort._pendingDestroy) {\n throw new Error(\n \"PDFWorker.fromPort - the worker is being destroyed.\\n\" +\n \"Please remember to await `PDFDocumentLoadingTask.destroy()`-calls.\"\n );\n }\n return cachedPort;\n }\n return new PDFWorker(params);\n }\n\n /**\n * The current `workerSrc`, when it exists.\n * @type {string}\n */\n static get workerSrc() {\n if (GlobalWorkerOptions.workerSrc) {\n return GlobalWorkerOptions.workerSrc;\n }\n throw new Error('No \"GlobalWorkerOptions.workerSrc\" specified.');\n }\n\n static get #mainThreadWorkerMessageHandler() {\n try {\n return globalThis.pdfjsWorker?.WorkerMessageHandler || null;\n } catch {\n return null;\n }\n }\n\n // Loads worker code into the main-thread.\n static get _setupFakeWorkerGlobal() {\n const loader = async () => {\n if (this.#mainThreadWorkerMessageHandler) {\n // The worker was already loaded using e.g. a ` - - - - - diff --git a/static/txt.js/txt.js b/static/txt.js/txt.js deleted file mode 100644 index b4cc1e65..00000000 --- a/static/txt.js/txt.js +++ /dev/null @@ -1,516 +0,0 @@ -let txtjs = {} - -Ox.load({UI: {loadCSS: false}}, function() { - Ox.$parent.bindMessage(function(data, event) { - txtjs.onMessage(data, event) - }) -}) - -txtjs.open = function(url) { - fetch(url).then(function(response) { - return response.text() - }).then(txtjs.renderText) -} - -txtjs.mark = function(notes) { - notes.forEach(function(note) { - if (!txtjs.notes.includes(note)) { - txtjs.notes.push(note) - } - txtjs.renderNote(note) - }) -} - -txtjs.notes = [] - -txtjs.addNoteFromSelection = function() { - let note = txtjs.getNoteFromSelection() - if (!note || txtjs.noteExists(note)) { - return - } - txtjs.renderNote(note) - txtjs.notes.push(note) - txtjs.selectNote(note.id) - getSelection().removeAllRanges() - txtjs.postMessage('addNote', note) -} - -txtjs.beginEdit = function() { - let selected = txtjs.getSelectedNote() - if (!selected || !selected.elements[0].classList.contains('editable')) { - return - } - selected.elements.forEach(function(element) { - element.classList.add('editing') - }) -} - -txtjs.cancelEdit = function() { - let editing = Array.from(document.querySelectorAll('g.editing')) - editing.forEach(function(element) { - element.classList.remove('editing') - }) -} - -txtjs.createSVGElement = function(name) { - return document.createElementNS('http://www.w3.org/2000/svg', name) -} - -txtjs.editNote = function() { - let editing = Array.from(document.querySelectorAll('g.editing')) - let note = txtjs.getNoteFromSelection() - if (editing.length == 0 || !note) { - return - } - let id = txtjs.getNoteId(editing[0]) - note = Object.assign(Ox.getObjectById(txtjs.notes, id), { - position: note.position, - text: note.text - }) - editing.forEach(function(element) { - element.parentElement.removeChild(element) - }) - txtjs.renderNote(note) - getSelection().removeAllRanges() - txtjs.postMessage('editNote', { - id: id, - position: note.position, - text: note.text - }) - txtjs.selectNote(note.id) -} - -txtjs.getNewId = function() { - let ids = txtjs.notes.map(function(note) { - return note.id - }) - let i = 1 - while (ids.includes(Ox.encodeBase26(i))) { - i++ - } - return Ox.encodeBase26(i) -} - -txtjs.getNoteId = function(element) { - let classNames = Array.from(element.classList).filter(function(className) { - return className.startsWith('note-') - }) - if (classNames.length == 0) { - return - } - return classNames[0].substr(5) -} - -txtjs.getNoteFromSelection = function() { - let selection = getSelection() - try { - var range = selection.getRangeAt(0) - } catch(e) { - return - } - if (range.collapsed) { - return - } - let container = range.commonAncestorContainer - if (container.id != 'txt') { - while (container != document.body) { - container = container.parentElement - if (container.id == 'txt') { - break - } - } - } - if (container.id != 'txt') { - return - } - let position = txtjs.getPosition(range) - let pos = position.split(',').map(function(v) { - return parseInt(v) - }) - let note = { - id: txtjs.getNewId(), - position: position, - text: txtjs.text.substr(pos[0], pos[1] - pos[0]), - editable: true - } - if (txtjs.noteExists(note)) { - return - } - return note -} - -txtjs.getPosition = function(range) { - let container = document.querySelector('#txt') - let nodes = Array.from(container.childNodes) - let startNodeIndex = range.startContainer == container - ? range.startOffset : nodes.indexOf(range.startContainer) - let endNodeIndex = range.endContainer == container - ? range.endOffset : nodes.indexOf(range.endContainer) - let startOffset = range.startContainer == container ? 0 : range.startOffset - let endOffset = range.endContainer == container ? 0 : range.endOffset - let index = 0 - let start = 0 - let end = 0 - for (let i = 0; i <= endNodeIndex; i++) { - if (i == startNodeIndex) { - start = index + startOffset - } - if (i == endNodeIndex) { - end = index + endOffset - } - if (nodes[i].nodeType == 1) { //
- index++ - } else { - index += nodes[i].textContent.length - } - } - while (' \n'.includes(txtjs.text.substr(start, 1))) { - start++ - } - while (' \n'.includes(txtjs.text.substr(end - 1, 1))) { - end-- - } - return start + ',' + end -} - -txtjs.getRange = function(id, start, end) { - let startContainer, startOffset, endContainer, endOffset - let container = document.querySelector('#' + id) - let nodes = Array.from(container.childNodes) - let index = 0 - for (let i = 0; i < nodes.length; i++) { - if (start < index + nodes[i].textContent.length && startOffset === void 0) { - startContainer = nodes[i] - startOffset = start - index - } - if (end <= index + nodes[i].textContent.length) { - endContainer = nodes[i] - endOffset = end - index - break - } - if (nodes[i].nodeType == 1) { //
- index++ - } else { - index += nodes[i].textContent.length - } - } - let range = document.createRange() - range.setStart(startContainer, startOffset) - range.setEnd(endContainer, endOffset) - return range -} - -txtjs.getSelectedNote = function() { - let elements = Array.from(document.querySelectorAll('g.selected')) - if (elements.length == 0) { - return - } - let id = txtjs.getNoteId(elements[0]) - return Object.assign(Ox.getObjectById(txtjs.notes, id), { - elements: elements - }) -} - -txtjs.noteExists = function(note) { - return txtjs.notes.some(function(note_) { - return note_.position == note.position - }) -} - -txtjs.onMessage = function(data, event) { - console.log('onMessage', event, data) - if (event == 'selectAnnotation') { - txtjs.selectNote(data.id, false) - } else if (event == 'addAnnotation') { - txtjs.addNoteFromSelection() - } else if (event == 'addAnnotations') { - if (data.reset) { - // fixme - } - data.annotations.forEach(function(note) { - //// - note.position = note.position.replace(':', ',') - //// - txtjs.renderNote(note) - txtjs.notes.push(note) - }) - } else if (event == 'removeAnnotation') { - txtjs.selectNote(data.id) - txtjs.removeNote() - } -} - -txtjs.postMessage = function(action, data) { - console.log('postMessage', action, data) - Ox.$parent.postMessage(action.replace('Note', 'Annotation'), data) -} - -txtjs.removeNote = function() { - let selected = txtjs.getSelectedNote() - if (!selected) { - return - } - let id = txtjs.getNoteId(selected.elements[0]) - selected.elements.forEach(function(element) { - element.parentElement.removeChild(element) - }) - let index = txtjs.notes.map(function(note) { - return note.id - }).indexOf(id) - txtjs.notes.splice(index, 1) - txtjs.postMessage('removeNote', { - id: id - }) -} - -txtjs.renderNote = function(note) { - let pos = note.position.split(',').map(function(v) { - return parseInt(v) - }) - let ids = ['txt', 'txt-scroll'] - ids.forEach(function(id) { - let range = txtjs.getRange(id, pos[0], pos[1]) - let rects = Array.from(range.getClientRects()) - let size = rects.reduce(function(width, rect) { - return width + rect.width - }, 0) - let maxHeight = 8192 - let firstIndex = Math.floor((rects[0].top + window.pageYOffset) / maxHeight) - let lastIndex = Math.floor((rects[rects.length - 1].top + window.pageYOffset + rects[rects.length - 1].height) / maxHeight) - for (let index = firstIndex; index <= lastIndex; index++) { - let g = txtjs.createSVGElement('g') - g.classList.add('note-' + note.id) - g.classList.add('selectable') - if (note.editable) { - g.classList.add('editable') - } - g.setAttribute('data-size', size) - g.setAttribute('pointer-events', id == 'txt' ? 'all' : 'none') - rects.forEach(function(rect) { - let element = txtjs.createSVGElement('rect') - let x = id == 'txt' ? rect.left - : rect.left - document.querySelector('#scroll').getBoundingClientRect().left + 8 - let y = id == 'txt' ? rect.top + window.pageYOffset - index * maxHeight - : rect.top + document.querySelector('#scroll').scrollTop - 16 - index * maxHeight - element.setAttribute('x', x) - element.setAttribute('y', y) - element.setAttribute('width', rect.width) - element.setAttribute('height', rect.height) - g.appendChild(element) - }) - let svg = document.querySelector('svg#svg-' + id + '-' + index) - for (let i = 0; i < svg.children.length; i++) { - let childSize = parseInt(svg.children[i].getAttribute('data-size')) - if (size > childSize) { - svg.insertBefore(g, svg.children[i]) - break - } - } - if (!g.parentElement) { - svg.appendChild(g) - } - } - }) -} - -txtjs.renderSVG = function(id, index, width, height) { - function mousedown(e) { - svg.addEventListener('mouseup', mouseup) - timeout = setTimeout(function() { - svg.removeEventListener('mouseup', mouseup) - e.target.classList.remove('selectable') - e.target.setAttribute('pointer-events', 'none') - document.addEventListener('mouseup', function() { - e.target.classList.add('selectable') - e.target.setAttribute('pointer-events', 'all') - }) - }, 250) - } - function mouseup(e) { - clearTimeout(timeout) - txtjs.selectNote(txtjs.getNoteId(e.target.parentElement)) - } - let timeout - let svg = txtjs.createSVGElement('svg') - svg.setAttribute('id', 'svg-' + id + '-' + index) - svg.setAttribute('pointer-events', 'none') - if (id == 'txt') { - svg.style.left = 0 - } else { - svg.style.right = '8px' - } - svg.style.top = index * 8192 + 'px' - svg.style.width = width + 'px' - svg.style.height = height + 'px' - if (id == 'txt') { - svg.addEventListener('mousedown', mousedown) - } - let parentElement = id == 'txt' ? document.body : document.querySelector('#scroll') - parentElement.appendChild(svg) -} - -txtjs.renderSVGs = function() { - let maxHeight = 8192 - let ids = ['txt', 'txt-scroll'] - ids.forEach(function(id) { - let rect = document.querySelector('#' + id).getBoundingClientRect() - let lastHeight = rect.height % maxHeight - let n = Math.ceil(rect.height / maxHeight) - for (let i = 0; i < n; i++) { - txtjs.renderSVG(id, i, rect.width, i < n - 1 ? maxHeight : lastHeight) - } - }) -} - -txtjs.renderText = function(text) { - txtjs.text = text - html = text.replace(//g, '>') - html = html.replace().replace(/\r\n/g, '\n').replace(/[\r\n]/g, '
') - txtjs.html = Ox.encodeHTMLEntities(text).replace(/\r\n/g, '\n').replace(/[\r\n]/g, '
') - window.addEventListener('mouseup', onMouseup) - window.addEventListener('resize', onResize) - window.addEventListener('scroll', onScroll) - document.addEventListener('keydown', function(e) { - console.log(e.keyCode) - if (e.keyCode == 8 || e.keyCode == 46) { // BACKSPACE || DELETE - txtjs.removeNote() - } else if (e.keyCode == 13) { // ENTER - if (e.shiftKey) { - txtjs.beginEdit() - } else if (document.querySelector('g.editing')) { - txtjs.editNote() - } else { - txtjs.addNoteFromSelection() - } - } else if (e.keyCode == 27) { // ESCAPE - if (document.querySelector('g.editing')) { - txtjs.cancelEdit() - } - if (document.querySelector('g.selected')) { - txtjs.selectNote(null) - } - } else if (e.keyCode == 37) { // LEFT - txtjs.selectNextNote(-1) - } else if (e.keyCode == 39) { // RIGHT - txtjs.selectNextNote(1) - } - }) - let style = document.createElement('style') - style.innerText = [ - 'svg { mix-blend-mode: multiply; position: absolute }', - 'g { fill: rgb(255, 255, 192); fill-opacity: 0.5 }', - 'g.selectable { cursor: pointer }', - 'g.editable { fill: rgb(255, 255, 0) }', - 'g.selected { fill: rgb(224, 240, 255) }', - 'g.editable.selected { fill: rgb(128, 192, 255) }', - 'g.editable.editing { fill: rgb(128, 255, 128) }', - '::selection { background: rgb(192, 192, 192) }' - ].join('\n') - document.head.appendChild(style) - document.body.style.backgroundColor = 'rgb(255, 255, 255)' - document.body.style.margin = 0 - document.body.style.overflowX = 'hidden' - let textElement = document.createElement('div') - textElement.id = 'txt' - textElement.style.fontFamily = 'Georgia, Palatino, DejaVu Serif, Book Antiqua, Palatino Linotype, Times New Roman, serif', - textElement.style.fontSize = '20px' - textElement.style.lineHeight = '30px' - textElement.style.padding = '10% 20% 10% 10%' - textElement.innerHTML = txtjs.html - textElement.addEventListener('mousedown', function() { - txtjs.selectNote(null) - }) - document.body.appendChild(textElement) - let scrollElement = document.createElement('div') - scrollElement.id = 'scroll' - scrollElement.style.bottom = '16px' - scrollElement.style.overflow = 'hidden' - scrollElement.style.position = 'fixed' - scrollElement.style.right = '24px' - scrollElement.style.width = '7%' - scrollElement.style.top = '16px' - document.body.appendChild(scrollElement) - let scrollTextElement = document.createElement('div') - scrollTextElement.id = 'txt-scroll' - scrollTextElement.style.cursor = 'pointer' - scrollTextElement.style.fontFamily = 'Georgia, Palatino, DejaVu Serif, Book Antiqua, Palatino Linotype, Times New Roman, serif', - scrollTextElement.style.fontSize = '2px' - scrollTextElement.style.lineHeight = '3px' - scrollTextElement.style.MozUserSelect = 'none' - scrollTextElement.style.WebkitUserSelect = 'none' - scrollTextElement.innerHTML = txtjs.html - scrollTextElement.addEventListener('mousedown', function(e) { - let offset = 'offsetY' in e ? e.offsetY : e.layerY - document.documentElement.scrollTop = offset / factor + margin - 16 - }) - scrollElement.appendChild(scrollTextElement) - txtjs.renderSVGs() - let factor, margin - onResize() - function onMouseup() { - let note = txtjs.getNoteFromSelection() - if (!note || txtjs.noteExists(note)) { - txtjs.postMessage('selectText', null) - } else { - txtjs.postMessage('selectText', note) - } - } - function onResize() { - factor = scrollTextElement.clientHeight / textElement.clientHeight - margin = textElement.offsetWidth * 0.1 - setTimeout(function() { - Array.from(document.querySelectorAll('svg')).forEach(function(svg) { - svg.parentElement.removeChild(svg) - }) - txtjs.renderSVGs() - txtjs.mark(txtjs.notes) - }) - } - function onScroll() { - scrollElement.scrollTop = (window.pageYOffset - margin + 16) * factor - } -} - -txtjs.selectNextNote = function(direction) { - let selected = txtjs.getSelectedNote() - if (!selected) { - return - } - let id = txtjs.getNoteId(selected.elements[0]) - let ids = txtjs.notes.sort(function(a, b) { - return parseInt(a.position.split()[0]) - parseInt(b.position.split()[0]) - }).map(function(note) { - return note.id - }) - txtjs.selectNote(ids[Ox.mod(ids.indexOf(id) + direction, ids.length)]) -} - -txtjs.selectNote = function(id, trigger) { - let selected = txtjs.getSelectedNote() - if (selected) { - selected.elements.forEach(function(element) { - element.classList.remove('selected') - }) - } - if (id) { - let editing = Array.from(document.querySelectorAll('g.editing')) - if (editing.length && txtjs.getNoteId(editing[0]) != id) { - editing.forEach(function(element) { - element.classList.remove('editing') - }) - } - let elements = Array.from(document.querySelectorAll('g.note-' + id)) - elements.forEach(function(element) { - element.classList.add('selected') - }) - for (let i = 0; i < elements.length; i++) { - if (!elements[i].parentNode.id.includes('scroll')) { - elements[i].scrollIntoViewIfNeeded && elements[i].scrollIntoViewIfNeeded() - break - } - } - } - if (trigger !== false) { - txtjs.postMessage('selectNote', {id: id}) - } -} diff --git a/update.py b/update.py index 3d9a66fc..3a2c7a40 100755 --- a/update.py +++ b/update.py @@ -13,19 +13,19 @@ from os.path import join, exists repos = { "pandora": { - "url": "https://code.0x2620.org/0x2620/pandora.git", + "url": "https://git.0x2620.org/pandora.git", "path": ".", }, "oxjs": { - "url": "https://code.0x2620.org/0x2620/oxjs.git", + "url": "https://git.0x2620.org/oxjs.git", "path": "./static/oxjs", }, "oxtimelines": { - "url": "https://code.0x2620.org/0x2620/oxtimelines.git", + "url": "https://git.0x2620.org/oxtimelines.git", "path": "./src/oxtimelines", }, "python-ox": { - "url": "https://code.0x2620.org/0x2620/python-ox.git", + "url": "https://git.0x2620.org/python-ox.git", "path": "./src/python-ox", } } @@ -80,7 +80,7 @@ def get_release(): def reload_notice(base): - print('\nPlease restart pan.do/ra to finish the update:\n\tsudo pandoractl reload\n') + print('\nPlease restart pan.do/ra to finish the update:\n\tsudo %s/ctl reload\n' % base) def check_services(base): @@ -207,12 +207,12 @@ if __name__ == "__main__": for component in ('oxtimelines', 'python-ox'): if not os.path.exists('./src/%s/.git' % component): run('./bin/pip', 'install', '-e', - 'git+https://code.0x2620.org/0x2620/%s.git#egg=%s' % (component, component), + 'git+https://git.0x2620.org/%s.git#egg=%s' % (component, component), '--exists-action', 'w') if not os.path.exists('./static/oxjs/.git'): if os.path.exists('static/oxjs'): shutil.move('static/oxjs', 'static/oxjs_bzr') - run('git', 'clone', '--depth', '1', 'https://code.0x2620.org/0x2620/oxjs.git', 'static/oxjs') + run('git', 'clone', '--depth', '1', 'https://git.0x2620.org/oxjs.git', 'static/oxjs') run('./pandora/manage.py', 'update_static') if os.path.exists('static/oxjs_bzr'): shutil.rmtree('static/oxjs_bzr') @@ -297,17 +297,6 @@ if __name__ == "__main__": run_sql(sql) run(join(base, 'pandora/manage.py'), 'migrate', 'system') run(join(base, 'pandora/manage.py'), 'update_geoip') - if old < 6442: - run('./bin/pip', 'install', 'yt-dlp>=2022.3.8.2') - if old <= 6581: - run('./bin/pip', 'install', '-U', 'pip') - run('./bin/pip', 'install', '-r', 'requirements.txt') - if old <= 6659: - run('./bin/pip', 'install', '-r', 'requirements.txt') - if old <= 6688: - run('./bin/pip', 'install', '-r', 'requirements.txt') - if old <= 6704: - run('./bin/pip', 'install', 'yt-dlp>=2024.10.22') else: if len(sys.argv) == 1: branch = get_branch() @@ -328,7 +317,6 @@ if __name__ == "__main__": current_branch = get_branch(path) revno = get_version(path) if repo == 'pandora': - print("Pandora Version pre update: ", revno) pandora_old_revno = revno current += revno if current_branch != branch: @@ -352,7 +340,6 @@ if __name__ == "__main__": new += '+' os.chdir(join(base, 'pandora')) if pandora_old_revno != pandora_new_revno: - print("Pandora Version post update: ", pandora_new_revno) os.chdir(base) run('./update.py', 'postupdate', pandora_old_revno, pandora_new_revno) os.chdir(join(base, 'pandora')) @@ -360,16 +347,26 @@ if __name__ == "__main__": run('./manage.py', 'update_static') run('./manage.py', 'compile_pyc', '-p', '.') os.chdir(join(base, 'pandora')) - diff = get('./manage.py', 'sqldiff', '-a').strip().split('\n') - diff = [ - row for row in diff - if not row.strip().startswith('ALTER "id" TYPE') - and not row.startswith('--') - and not row.startswith('ALTER TABLE') - and row not in ['BEGIN;', 'COMMIT;'] - ] - if diff: - print('Database has changed, please make a backup and run: sudo pandoractl update db') + diff = get('./manage.py', 'sqldiff', '-a').strip() + for row in [ + '-- Model missing for table: djcelery_periodictasks\n', + '-- Model missing for table: celery_taskmeta\n', + '-- Model missing for table: celery_tasksetmeta\n', + '-- Model missing for table: djcelery_crontabschedule\n', + '-- Model missing for table: djcelery_periodictask\n', + '-- Model missing for table: djcelery_intervalschedule\n', + '-- Model missing for table: djcelery_workerstate\n', + '-- Model missing for table: djcelery_taskstate\n', + '-- Model missing for table: south_migrationhistory\n', + '-- Model missing for table: cache\n', + ]: + if row in diff: + diff = diff.replace(row, '') + if diff not in [ + '-- No differences', + 'BEGIN;\nCOMMIT;' + ]: + print('Database has changed, please make a backup and run %s db' % sys.argv[0]) elif branch != 'master': print('pan.do/ra is at the latest release,\nyou can run "%s switch master" to switch to the development version' % sys.argv[0]) elif current != new: diff --git a/vm/LXC_README.md b/vm/LXC_README.md new file mode 100644 index 00000000..440d412a --- /dev/null +++ b/vm/LXC_README.md @@ -0,0 +1,46 @@ +# Preparations + + you will need at least 2GB of free disk space to install pan.do/ra + +# Installing pan.do/ra inside LXC + +1) Install lxc on the host (Ubuntu 18.04): + + sudo apt-get install lxc + +1.1) On Debian you have to configure the a network for LXC before creating a container + + Simplest setup is this one here: + https://wiki.debian.org/LXC/SimpleBridge#Using_lxc-net + +2) Create a new container, use different names if installing multiple instances: + + sudo lxc-create -n pandora -t ubuntu-cloud -- -r focal + + or + + sudo lxc-create -n pandora -t debian -- -r buster + +3) Install pan.do/ra in container: + + sudo lxc-start -n pandora -d + +4) Attach to container and install pan.do/ra + + sudo lxc-attach -n pandora --clear-env + sed -i s/ubuntu/pandora/g /etc/passwd /etc/shadow /etc/group + mv /home/ubuntu /home/pandora + echo "pandora:pandora" | chpasswd + echo PasswordAuthentication no >> /etc/ssh/sshd_config + apt-get update -qq && apt-get upgrade -y + apt-get -y install curl ca-certificates + locale-gen en_US.UTF-8 + update-locale LANG=en_US.UTF-8 + export LANG=en_US.UTF-8 + + cd /root + curl -sL https://pan.do/ra-install > pandora_install.sh + chmod +x pandora_install.sh + export BRANCH=stable # or master + ./pandora_install.sh 2>&1 | tee pandora_install.log + diff --git a/vm/INCUS_README.md b/vm/LXD_README.md similarity index 61% rename from vm/INCUS_README.md rename to vm/LXD_README.md index c5dc37f0..9aa78a25 100644 --- a/vm/INCUS_README.md +++ b/vm/LXD_README.md @@ -2,21 +2,28 @@ you will need at least 2GB of free disk space to install pan.do/ra -# Installing pan.do/ra inside Incus +# Installing pan.do/ra inside LXD -1) Install incus on the host (Debian/12 with backports): +1) Install lxd on the host (Ubuntu 18.04 or later, Debian/10): - sudo apt install incus + sudo snap install lxd 2) Create a new container, use different names if installing multiple instances: - sudo incus launch images:debian/12 pandora + sudo lxc launch ubuntu:20.04 pandora + + or + + sudo lxc launch images:debian/10 pandora 3) Attach to container and install pan.do/ra - sudo incus exec pandora bash + sudo lxc exec pandora bash apt-get update -qq && apt-get upgrade -y apt-get -y install curl ca-certificates + sed -i s/ubuntu/pandora/g /etc/passwd /etc/shadow /etc/group + mv /home/ubuntu /home/pandora + echo "pandora:pandora" | chpasswd echo PasswordAuthentication no >> /etc/ssh/sshd_config locale-gen en_US.UTF-8 update-locale LANG=en_US.UTF-8 diff --git a/vm/README.md b/vm/README.md index 6f935dd1..ff055e0c 100644 --- a/vm/README.md +++ b/vm/README.md @@ -42,5 +42,5 @@ Pan.do/ra is installed in /srv/pandora and is served with nginx on http://pandor to get the latest version of pan.do/ra cd /srv/pandora - pandoractl update + ./update.py diff --git a/vm/install_elasticsearch.sh b/vm/install_elasticsearch.sh index 594e4628..87e7a0ba 100755 --- a/vm/install_elasticsearch.sh +++ b/vm/install_elasticsearch.sh @@ -1,16 +1,8 @@ #!/bin/sh -curl -sL https://artifacts.elastic.co/GPG-KEY-elasticsearch > /etc/apt/trusted.gpg.d/elasticsearch.asc +curl -sL https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add - echo "deb https://artifacts.elastic.co/packages/7.x/apt stable main" > /etc/apt/sources.list.d/elasticsearch.list apt-get update -qq apt-get -y install elasticsearch -cat >> /etc/elasticsearch/elasticsearch.yml << EOF -xpack.security.enabled: false -discovery.type: single-node -EOF -cat > /etc/elasticsearch/jvm.options.d/mem.options << EOF --Xms8g --Xmx8g -EOF systemctl enable elasticsearch.service systemctl start elasticsearch.service #curl -X GET "http://localhost:9200/?pretty" diff --git a/vm/pandora_install.sh b/vm/pandora_install.sh index 4d5d0a6e..75adf3d0 100755 --- a/vm/pandora_install.sh +++ b/vm/pandora_install.sh @@ -25,20 +25,29 @@ LXC=`grep -q lxc /proc/1/environ && echo 'yes' || echo 'no'` if [ -e /etc/os-release ]; then . /etc/os-release fi +if [ -z "$UBUNTU_CODENAME" ]; then + UBUNTU_CODENAME=bionic +fi export DEBIAN_FRONTEND=noninteractive +echo "deb http://ppa.launchpad.net/j/pandora/ubuntu ${UBUNTU_CODENAME} main" > /etc/apt/sources.list.d/j-pandora.list -apt-get install -y gnupg curl +apt-get install -y gnupg -distribution=bookworm -for version in bookworm trixie bionic focal jammy noble; do - if [ "$VERSION_CODENAME" = $version ]; then - distribution=$VERSION_CODENAME - fi -done - -curl -Ls https://code.0x2620.org/api/packages/0x2620/debian/repository.key -o /etc/apt/keyrings/pandora.asc -echo "deb [signed-by=/etc/apt/keyrings/pandora.asc] https://code.0x2620.org/api/packages/0x2620/debian $distribution main" > /etc/apt/sources.list.d/pandora.list +apt-key add - < /etc/apt/apt.conf.d/99languages apt-get update -qq @@ -78,15 +87,16 @@ apt-get install -y \ python3-numpy \ python3-psycopg2 \ python3-pyinotify \ - python3-maxminddb \ - libmaxminddb-dev \ + python3-simplejson \ python3-lxml \ python3-cssselect \ python3-html5lib \ python3-ox \ python3-elasticsearch \ + oxframe \ ffmpeg \ mkvtoolnix \ + gpac \ imagemagick \ poppler-utils \ ipython3 \ @@ -95,10 +105,7 @@ apt-get install -y \ postfix \ postgresql-client $EXTRA -apt-get install -y oxframe apt-get install -y --no-install-recommends youtube-dl rtmpdump -apt-get install -y python3-unrardll - # setup database @@ -121,7 +128,7 @@ else fi # checkout pandora from git -git clone https://code.0x2620.org/0x2620/pandora.git /srv/pandora +git clone https://git.0x2620.org/pandora.git /srv/pandora cd /srv/pandora git checkout $BRANCH chown -R $PANDORA:$PANDORA /srv/pandora @@ -208,8 +215,6 @@ EOI sed -i -e "s#gzip_disable \"msie6\";#${GZIP}#g" /etc/nginx/nginx.conf -echo "types { application/javascript js mjs; }" > /etc/nginx/conf.d/mjs.conf - service nginx restart fi