odahcam/bootoast

All Supported Positions are not in effect(always appears in bottom-center)

Closed this issue · 2 comments

my code is this

bootoast.toast({
	message: 'This is a success toast message', 
	type: 'success', 
	position:'top-right', 
	timeout:2 
})

However, the prompt message appears in the middle of the bottom, i debugged, find this
in line 320:

positionFor: function (position) {

			// se esta posição é padrão
			if (this.positions[position]) return position;

positions is a array, cant use positions[position], Unless it is a json object

Try to use the synonims, there's a bug with the default position names.

Synonims

  • bottom for bottom-center
  • leftBottom for bottom-left
  • rightBottom for bottom-right
  • top for top-center
  • rightTop for top-right
  • leftTop for top-left