jQuery(function($) {
	var fileGalleryText = {
		buttonAcceptLabel : "Aceptar",
		buttonCancelLabel : "Cancelar",
		buttonEditLabel : "Editar",
		buttonRemoveLabel : "Eliminar",
		editDialogTitle : "Recortar imagen",
		errorInvalidExtension : "El fichero tiene una extensi\u00F3n inv\u00E1lida o no permitida.",
		errorMaxImages : "N\u00FAmero m\u00E1ximo de ficheros de esta galer\u00EDa alcanzado:",
		errorUnexistingMethod : "Funci\u00F3n inexistente en jQuery.fileGallery:",
		errorUnknownGalleryType : "Tipo de galer\u00EDa desconocido",
		fileGalleryText : "Haz clic o arrastra para adjuntar ficheros.",
		imageGalleryText : "Haz clic o arrastra para insertar im\u00E1genes.",
		imageNotFoundError : "Imagen no encontrada",
		infoMessageLoadingFile : "Cargando fichero:",
		profileGalleryText : "Arrastra o haz clic para insertar tu foto de perfil.",
		titlePlaceHolder: "T\u00EDtulo de la imagen"
	};
	$('.file-gallery').fileGalleryText(fileGalleryText);
});

jQuery(function($) {
	var positionPanelText = {
		errorUnexistingMethod : "Funci\u00F3n inexistente en jQuery.positionPanel:",
		newElementText : "Nueva categor\u00EDa",
	};
	$('.position-panel').positionPanelText(positionPanelText);
});

jQuery(function($) {
	var htmlEditorText = {
		htmlEditor: "Editor HTML",
		buttonAcceptLabel: "Aceptar",
		buttonCancelLabel: "Cancelar",
		buttonEditLabel: "EDITAR",
		buttonHtmlLabel: "Html",
		buttonPreviewLabel: "Vista previa",
		errorUnexistingMethod: "Método inexistente!",
		invalidHTMLError: "El código HTML tiene errores de sintaxis.",
		emptyHTMLError: "El código HTML no puede estar vacío."
	};
	$('.editable').editableHtmlText(htmlEditorText);
});

$.extend( $.cv.i18n.prototype.options.texts, {
	okText: "Aplicar",
	closeText: "Cancelar",
	clearText: "Borrar todo",
	btnRemove: "Borrar contenido" 
} );

$.extend( $.cv.placesautocomplete.prototype.options.texts, {
	buttonDetectLocation: "Detectar ubicaci\u00F3n",
	labelAutodetectedLocation: "Ubicaci\u00F3n autodetectada",
	categoryPredefinedPlaces: "Ubicaciones predeterminadas",
	categorySuggestedPlaces: "Ubicaciones sugeridas"
} );	

$.extend( $.cv.paginator.prototype.options.texts, {
	btnPrevious: "Anterior",
	btnNext: "Siguiente",
	textResults: "Resultados: $RESULTS",
	ariaBtnPageLabel: "Ir a la p\u00E1gina $PAGE_NUM"
} );

$.extend( $.cv.selectwithcheckboxes.prototype.options.texts, {
	searchInputPlaceholder: "Buscar...",
	selectAllCheckboxText: "Todo",
	msgNoResults: "No hay opciones coincidentes con tu b\u00FAsqueda.",
	btnApply: "Aplicar",
	btnCancel: "Cancelar"
} );

$.extend($.cv.reactions.prototype.options.texts, {
	react: "Reaccionar",
	reactions: {
		heart: "Me encanta",
		celebration: "Celebrar",
		fire: "Imparable",
		clap: "Aplausos",
		stareyes: "Genial",
		like: "Me gusta",
		dislike: "No me gusta",
		"face-frowning": "Triste",
		"face-confused": "Confusi\u00F3n",
		"face-neutral": "Neutral",
		"face-smiling": "Sonrisa",
		"face-grinning": "Feliz",
	}
});

$.extend( $.cv.selectrange.prototype.options.texts, {
	labelMin: "M\u00EDn",
	labelMax: "Max",
	btnApply: "Aplicar",
	btnCancel: "Cancelar"
} );

$.extend( $.cv.formbystep.prototype.options.texts, {
	btnPrevious: "Atr\u00E1s",
	btnNext: "Siguiente",
	btnCancel: "Cancelar",
	btnPost: "Publicar"
} );

$.extend( $.cv.icongallery.prototype.options.texts, {
	title: "Galer\u00EDa de iconos",
	buttonApplyLabel: "Aplicar",
	buttonCloseLabel: "Cerrar",
	categoryFilterTitle: "Todas las categor\u00EDas",
	categoryLabels: {
		activities: "Actividades",
		food: "Alimentaci\u00F3n",
		people: "Caras y personas",
		shopping: "Compras",
		communication: "Comunicaci\u00F3n y documentos",
		holidays: "Festividades y estaciones",
		education: "Formaci\u00F3n",
		misc: "Miscel\u00E1nea",
		nature: "Naturaleza",
		money: "Negocio y finanzas",
		security: "Legal y seguridad",
		incentives: "Reconocimiento e incentivos",
		health: "Salud y bienestar",
		symbols: "S\u00EDmbolos",
		multimedia: "Social y multimedia",
		transport: "Transporte y lugares"
	}
});

$.extend( $.cv.appdialog.prototype.options.texts, {
	title: "plugin.js.appdialog.title",
	subtitle: "\u00A1Disfruta de tu portal y de todas sus ventajas donde quieras!",
	bulletAlert: "Recibe alertas para no perderte nada",
	bulletLocation: "Contenido personalizado seg\u00FAn tu ubicaci\u00F3n",
	bulletLogin: "Accede ahora a la app sin tener que identificarte de nuevo",
	more: "Y mucho m\u00E1s...",
	buttonGo:  "Ir a la app",
	buttonClose: "Cerrar"
});

$.extend( AutoSaver.prototype, {
	dialogTitle: "Datos anteriores detectados",
	dialogText: "Se han detectado datos anteriores. \u00BFQuieres restaurarlos?",
	cancelText: "Cancelar",
	okText: "Aceptar"
});
