You've already forked LibreTranslate
							
							
				mirror of
				https://github.com/LibreTranslate/LibreTranslate.git
				synced 2025-10-30 23:37:48 +02:00 
			
		
		
		
	Remove Google Analytics
This commit is contained in:
		| @@ -219,7 +219,6 @@ Los argumentos que se pasan al proceso o se configuran mediante variables de ent | ||||
| | --req-limit-storage        | URI de almacenamiento para limitar el almacenamiento de datos de solicitudes. Ver [Flask Limiter](https://flask-limiter.readthedocs.io/en/stable/configuration.html)                                                                   | `memoria://`                           | LT_REQ_LIMIT_STORAGE        | | ||||
| | --req-time-cost            | Considera el coste de tiempo (en segundos) para limitar las solicitudes. Si una solicitud tarda 10 segundos y este valor se establece en 5, el coste de la solicitud es 2 o el coste real de la solicitud (el que sea mayor). | `Sin costo de tiempo`                        | LT_REQ_TIME_COST            | | ||||
| | --batch-limit              | Establecer el número máximo de textos a traducir en una solicitud por lotes                                                                                                                                                 | `Sin Limite`                            | LT_BATCH_LIMIT              | | ||||
| | --ga-id                    | Habilite Google Analytics en la página del cliente API proporcionando una identificación                                                                                                                                          | `Vacío (sin seguimiento)`                 | LT_GA_ID                    | | ||||
| | --frontend-language-source | Establecer el idioma predeterminado del frontend - fuente                                                                                                                                                                      | `auto`                                | LT_FRONTEND_LANGUAGE_SOURCE | | ||||
| | --frontend-language-target | Establecer el idioma predeterminado del frontend - objetivo                                                                                                                                                                      | `locale` (coincide con la configuración regional del sitio)        | LT_FRONTEND_LANGUAGE_TARGET | | ||||
| | --frontend-timeout         | Establecer el tiempo de espera de traducción del frontend                                                                                                                                                                            | `500`                                 | LT_FRONTEND_TIMEOUT         | | ||||
|   | ||||
| @@ -435,7 +435,6 @@ def create_app(args): | ||||
|  | ||||
|         resp = make_response(render_template( | ||||
|             "index.html", | ||||
|             gaId=args.ga_id, | ||||
|             frontendTimeout=args.frontend_timeout, | ||||
|             api_keys=args.api_keys, | ||||
|             get_api_key_link=args.get_api_key_link, | ||||
|   | ||||
| @@ -91,11 +91,6 @@ _default_options_objects = [ | ||||
|         'default_value': -1, | ||||
|         'value_type': 'int' | ||||
|     }, | ||||
|     { | ||||
|         'name': 'GA_ID', | ||||
|         'default_value': None, | ||||
|         'value_type': 'str' | ||||
|     }, | ||||
|     { | ||||
|         'name': 'DEBUG', | ||||
|         'default_value': False, | ||||
|   | ||||
| @@ -79,13 +79,6 @@ def get_args(): | ||||
|         metavar="<number of texts>", | ||||
|         help="Set maximum number of texts to translate in a batch request (%(default)s)", | ||||
|     ) | ||||
|     parser.add_argument( | ||||
|         "--ga-id", | ||||
|         type=str, | ||||
|         default=DEFARGS['GA_ID'], | ||||
|         metavar="<GA ID>", | ||||
|         help="Enable Google Analytics on the API client page by providing an ID (%(default)s)", | ||||
|     ) | ||||
|     parser.add_argument( | ||||
|         "--debug", default=DEFARGS['DEBUG'], action="store_true", help="Enable debug environment" | ||||
|     ) | ||||
|   | ||||
| @@ -35,17 +35,6 @@ | ||||
| 	<script src="{{ url_for('static', filename='js/vue@2.js') }}"></script> | ||||
|  | ||||
|  | ||||
| 	{% if gaId %} | ||||
| 	<!-- Global site tag (gtag.js) - Google Analytics --> | ||||
| 	<script async src="https://www.googletagmanager.com/gtag/js?id={{ gaId }}"></script> | ||||
| 	<script> | ||||
| 		window.dataLayer = window.dataLayer || []; | ||||
| 		function gtag(){dataLayer.push(arguments);} | ||||
| 		gtag('js', new Date()); | ||||
| 		gtag('config', '{{ gaId }}'); | ||||
| 	</script> | ||||
| 	{% endif %} | ||||
|  | ||||
| 	<!-- Compiled and minified CSS --> | ||||
| 	<link rel="stylesheet" href="{{ url_for('static', filename='css/materialize.min.css') }}"> | ||||
| 	<link rel="stylesheet" href="{{ url_for('static', filename='css/material-icons.css') }}" /> | ||||
|   | ||||
		Reference in New Issue
	
	Block a user