Skip to content

Commit

Permalink
Merge pull request #27 from BuildFire/fix/messing-language
Browse files Browse the repository at this point in the history
Fix/messing language
  • Loading branch information
mas-iota authored Dec 19, 2024
2 parents 0834539 + 1241493 commit e9e6d00
Show file tree
Hide file tree
Showing 12 changed files with 436 additions and 154 deletions.
11 changes: 6 additions & 5 deletions control/content/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@

<!-- JS -->
<script src="../../../../scripts/buildfire.min.js"></script>
<!-- build:bundleJSFiles -->

<!-- build:bundleSharedJSFiles -->
<script src="../../widget/assets/js/Analytics.js"></script>
<script src="../../widget/assets/js/analyticsKeys.js"></script>
<!-- endbuild -->
Expand All @@ -21,7 +22,7 @@

<link href="../../../../styles/control/bf-base.css" rel="stylesheet">
<script>
Analytics.init();
Analytics.init();

const debounce = (func, wait) => {
let timeout;
Expand All @@ -37,7 +38,7 @@
executedFunction();
};

tinymce.init({
tinymce.init({
selector: "#text",
max_chars: 800,
toolbar: "",
Expand Down Expand Up @@ -88,10 +89,10 @@
<body>
<div>
<h1>Introduction</h1>
<textarea id="text" ui-tinymce="editorOptions" class="form-control" rows="5" width="100%" height="300px"></textarea>
<textarea id="text" ui-tinymce="editorOptions" class="form-control" rows="5" width="100%" height="300px"></textarea>

</div>


<script>
function save(data) {
Expand Down
15 changes: 10 additions & 5 deletions control/settings/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,27 @@
<link href="../../../../styles/helper.css" rel="stylesheet" />
<link rel="stylesheet" href="../assets/control.css" />
<link href="../../../../styles/control/bf-base.css" rel="stylesheet" />
<!-- build:bundleCSSFiles -->
<link href="./styles.css" rel="stylesheet" />
<!-- endbuild -->
<link href="../../../../styles/control/siteIcons-control.css" rel="stylesheet" />
<script src="../../../../scripts/buildfire.min.js"></script>
<script src="../../../../scripts/buildfire/services/commerce/inAppPurchase.js"></script>
<!-- build:bundleJSFiles -->

<!-- build:bundleSharedJSFiles -->
<script src="../../widget/assets/js/settings.js"></script>
<!-- endbuild -->
<!-- endbuild -->



<link href="../../../../styles/components/control/tagsInput/tagsInput.min.css" rel="stylesheet"/>

<script src="../../../../scripts/buildfire/components/control/tagsInput/tagsInput.min.js"></script>
</head>

<body>
<div class="settings-container">


<div class="row margin-bottom-sixteen">

<div class="item clearfix row flex-center">
Expand Down Expand Up @@ -227,5 +230,7 @@
</div>
</div>
</body>
<!-- build:bundleJSFiles -->
<script src="./app.js"></script>
<!-- endbuild -->
</html>
5 changes: 4 additions & 1 deletion control/tests/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,15 @@
<script src="./Jasmine-Project/lib/jasmine-html.js"></script>
<script src="./Jasmine-Project/lib/boot.js"></script>

<!-- build:bundleSharedJSFiles -->
<script src="../../widget/assets/js/settings.js"></script>
<script src="../../widget/assets/js/suggestions.js"></script>
<!-- endbuild -->

<script src="./spec/settings.spec.js"></script>
<script src="./spec/suggestion.spec.js"></script>

</head>
<body>
</body>
</html>
</html>
21 changes: 17 additions & 4 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ cssTasks.forEach(function(task){
});

const jsTasks=[
{name:"widgetJS",src:["widget/assets/**/*.js", "widget/*.js" ,"widget/controllers/*.js"],dest:"/widget"}
{name:"widgetJS",src:["!widget/assets/**/*.js", "widget/*.js" ,"widget/controllers/*.js"],dest:"/widget"}
,{name:"sharedJS",src:["widget/assets/**/*.js"],dest:"/widget/shared"}
,{name:"controlContentJS",src:"control/content/**/*.js",dest:"/control/content"}
,{name:"controlDesignJS",src:"control/design/**/*.js",dest:"/control/design"}
,{name:"controlSettingsJS",src:"control/settings/**/*.js",dest:"/control/settings"}
Expand Down Expand Up @@ -101,6 +102,7 @@ gulp.task('html', function(){
.pipe(htmlReplace({
bundleJSFiles:"scripts.min.js?v=" + (new Date().getTime())
,bundleCSSFiles:"styles.min.css?v=" + (new Date().getTime())
,bundleSharedJSFiles:"./shared/scripts.min.js?v=" + (new Date().getTime())
}))

/// then strip the html from any comments
Expand All @@ -115,7 +117,8 @@ gulp.task('Controlhtml', function(){
/// replace all the <!-- build:bundleJSFiles --> comment bodies
/// with scripts.min.js with cache buster
.pipe(htmlReplace({
bundleJSFiles:"../../widget/scripts.min.js?v=" + (new Date().getTime())
bundleJSFiles:"./scripts.min.js?v=" + (new Date().getTime())
,bundleSharedJSFiles:"../../widget/shared/scripts.min.js?v=" + (new Date().getTime())
,bundleCSSFiles:"styles.min.css?v=" + (new Date().getTime())
}))

Expand Down Expand Up @@ -143,6 +146,16 @@ gulp.task('fonts', function(){
.pipe(gulp.dest(destinationFolder));
});

gulp.task('assets', function(){
return gulp.src(['widget/assets/**/*.{css,png,svg}', 'control/assets/**'],{base: '.'})
.pipe(gulp.dest(destinationFolder));
});

gulp.task('tests', function(){
return gulp.src(['control/tests/**'],{base: '.'})
.pipe(gulp.dest(destinationFolder));
});

gulp.task('icons', function(){
return gulp.src(['widget/css/fonts/**/*.{ttf,woff,eot,svg}'])
.pipe(gulp.dest(destinationFolder + '/widget/fonts'));
Expand All @@ -155,10 +168,10 @@ gulp.task('zip', function () {
.pipe(gulp.dest('..'));
});

var buildTasksToRun=['html', 'Controlhtml','resources','images','fonts','icons'];
var buildTasksToRun=['html', 'Controlhtml','resources','images','fonts','icons', 'assets', 'tests'];

cssTasks.forEach(function(task){ buildTasksToRun.push(task.name)});
jsTasks.forEach(function(task){ buildTasksToRun.push(task.name)});

gulp.task('build', gulpSequence('clean',buildTasksToRun) );
gulp.task('zipit', gulpSequence('zip'));// run by 'gulp zip' (191001 - Marcela)
gulp.task('zipit', gulpSequence('zip'));// run by 'gulp zip' (191001 - Marcela)
139 changes: 139 additions & 0 deletions resources/languages.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@
"toolTip": "The word Comment in the comment button",
"placeholder": "Comment"
},
"updateStatus": {
"title": "Update Status",
"defaultValue": "Update Status",
"inputType": "text",
"maxLength": 20,
"toolTip": "",
"placeholder": "Update Status"
},
"backlog": {
"title": "Backlog",
"defaultValue": "Backlog",
Expand Down Expand Up @@ -50,6 +58,49 @@
"inputType": "text",
"toolTip": "",
"placeholder": "Getting your purchase ready, please wait..."
},
"suggestionSuccessfullyAdded": {
"title": "Suggestion Successfully Added",
"defaultValue": "Your suggestion has been successfully added.",
"inputType": "text",
"toolTip": "",
"placeholder": "Your suggestion has been successfully added."
},
"somethingWentWrong": {
"title": "Something went wrong",
"defaultValue": "Something went wrong, please try again later.",
"inputType": "text",
"toolTip": "",
"placeholder": "Something went wrong, please try again later."
},
"purchaseWasCancelled": {
"title": "Purchase Was Cancelled",
"defaultValue": "The purchase was cancelled",
"inputType": "text",
"toolTip": "",
"placeholder": "The purchase was cancelled"
},
"upvotes": {
"title": "Upvotes",
"defaultValue": "Upvotes",
"inputType": "text",
"toolTip": "",
"placeholder": "Upvotes"
},
"purchaseNotAvailable": {
"title": "Purchase Not Available",
"defaultValue": "Purchase Not Available On Browser",
"inputType": "text",
"toolTip": "",
"placeholder": "Purchase Not Available On Browser"
},
"unknownUser": {
"title": "Unknown User",
"defaultValue": "Someone",
"inputType": "text",
"maxLength": 20,
"toolTip": "",
"placeholder": "Someone"
}
}
},
Expand Down Expand Up @@ -197,6 +248,94 @@
"placeholder": "Remove"
}
}
},
"notifications": {
"title": "Notifications",
"labels": {
"newItemTitle": {
"title": "New Item Created Title",
"defaultValue": "A new item has been created",
"inputType": "text",
"toolTip": "",
"maxLength": 50,
"placeholder": "A new item has been created"
},
"newItemBody": {
"title": "New Item Created Message",
"defaultValue": "A ${context.plugin.itemTitle} has been created",
"inputType": "text",
"toolTip": "",
"maxLength": 150,
"placeholder": "A ${context.plugin.itemTitle} has been created"
},

"backlogItemTitle": {
"title": "Task In Backlog Title",
"defaultValue": "Task In Backlog",
"inputType": "text",
"toolTip": "",
"maxLength": 50,
"placeholder": "Task In Backlog"
},
"backlogItemBody": {
"title": "Task In Backlog Message",
"defaultValue": "${context.plugin.itemTitle} has been marked as In Backlog",
"inputType": "text",
"toolTip": "",
"maxLength": 150,
"placeholder": "${context.plugin.itemTitle} has been marked as In Backlog"
},

"inProgressItemTitle": {
"title": "Task In Progress Title",
"defaultValue": "Task In Progress",
"inputType": "text",
"toolTip": "",
"maxLength": 50,
"placeholder": "Task In Progress"
},
"inProgressItemBody": {
"title": "Task In Progress Message",
"defaultValue": "${context.plugin.itemTitle} has been marked as In Progress",
"inputType": "text",
"toolTip": "",
"maxLength": 150,
"placeholder": "${context.plugin.itemTitle} has been marked as In Progress"
},

"completedItemBody": {
"title": "Task Completed",
"defaultValue": "Task Completed",
"inputType": "text",
"toolTip": "",
"maxLength": 50,
"placeholder": "Task Completed"
},
"completedItemMessageInputPlaceholder": {
"title": "Completed Task Message Input",
"defaultValue": "${context.plugin.itemTitle} has been marked as completed",
"inputType": "text",
"toolTip": "",
"maxLength": 150,
"placeholder": "${context.plugin.itemTitle} has been marked as completed"
},
"completedItemMessageSendText": {
"title": "Completed Task Message Send Text",
"defaultValue": "Send",
"inputType": "text",
"toolTip": "",
"maxLength": 9,
"placeholder": "Send"
},
"completedItemMessageCancelText": {
"title": "Completed Task Message Cancel Text",
"defaultValue": "Cancel",
"inputType": "text",
"toolTip": "",
"maxLength": 9,
"placeholder": "Cancel"
}
}
}
}
}
13 changes: 1 addition & 12 deletions widget/app.services.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,4 @@
}
};
}])
.filter('getUserImage', function () {
return function (user) {
var url = './assets/images/avatar.png';
if (user) {
url = buildfire.auth.getUserPictureUrl({ userId: user._id });
url = buildfire.imageLib.cropImage(url,{ size: "xs", aspect: "1:1" });
return url;
}
return url;
};
})
})(window.angular, window.buildfire);
})(window.angular, window.buildfire);
22 changes: 22 additions & 0 deletions widget/assets/css/animations.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,28 @@
animation-fill-mode: both;
}

.user-image-container {
min-width: 40px;
min-height: 40px;
width: 40px;
height: 40px;
overflow: hidden;
position: relative;
border-radius: 100%;
}

.loading-image::after {
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
transform: translateX(-100%);
background-image: linear-gradient(90deg, rgba(var(--bf-theme-background-rgb), 0) 0, rgba(var(--bf-theme-background-rgb), 0.2) 20%, rgba(var(--bf-theme-background-rgb), 0.5) 60%, rgba(var(--bf-theme-background-rgb), 0));
-webkit-animation: shimmer 2s infinite;
animation: shimmer 2s infinite;
content: "";
}

@-webkit-keyframes fadeInRight {
from {
Expand Down
Loading

0 comments on commit e9e6d00

Please sign in to comment.